Skip to content

Commit

Permalink
Merge branch 'develop' into write_file_issues
Browse files Browse the repository at this point in the history
  • Loading branch information
eldy authored Nov 13, 2024
2 parents e153c45 + e259ffb commit 74f0d9b
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 16 deletions.
2 changes: 1 addition & 1 deletion htdocs/ecm/class/ecmfiles.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -1007,7 +1007,7 @@ public function getNomUrl($withpicto = 0, $option = '', $notooltip = 0, $maxlen
}

if ($option) {
$url = DOL_URL_ROOT.'/document.php?modulepart='.$option.'&file='.urlencode(preg_replace('/[a-zA-Z]+\//', '', $this->filepath).'/'.$this->filename).'&entity='.$this->entity;
$url = DOL_URL_ROOT.'/document.php?modulepart='.$option.'&file='.urlencode(preg_replace('/^[^\/]+\//', '', $this->filepath).'/'.$this->filename).'&entity='.$this->entity;
} else {
$url = DOL_URL_ROOT.'/ecm/file_card.php?id='.$this->id;
}
Expand Down
32 changes: 17 additions & 15 deletions htdocs/install/mysql/migration/20.0.0-21.0.0.sql
Original file line number Diff line number Diff line change
Expand Up @@ -32,20 +32,6 @@
-- -- VPGSQL8.2 SELECT dol_util_rebuild_sequences();


-- new fichinter categorie
create table llx_categorie_fichinter
(
fk_categorie integer NOT NULL,
fk_fichinter integer NOT NULL,
import_key varchar(14)
)ENGINE=innodb;

ALTER TABLE llx_categorie_fichinter ADD PRIMARY KEY pk_categorie_fichinter (fk_categorie, fk_fichinter);
ALTER TABLE llx_categorie_fichinter ADD INDEX idx_categorie_fichinter_fk_categorie (fk_categorie);
ALTER TABLE llx_categorie_fichinter ADD INDEX idx_categorie_fichinter_fk_fichinter (fk_fichinter);
ALTER TABLE llx_categorie_fichinter ADD CONSTRAINT fk_categorie_fichinter_categorie_rowid FOREIGN KEY (fk_categorie) REFERENCES llx_categorie (rowid);
ALTER TABLE llx_categorie_fichinter ADD CONSTRAINT fk_categorie_fichinter_fk_fichinter FOREIGN KEY (fk_fichinter) REFERENCES llx_fichinter (rowid);

-- Clean very old temporary tables (created during v9 migration or repair)

DROP TABLE tmp_llx_accouting_account;
Expand All @@ -65,6 +51,23 @@ ALTER TABLE llx_hrm_evaluation MODIFY COLUMN modelpdf varchar(255) DEFAULT NULL;

-- V21 migration

CREATE TABLE llx_categorie_fichinter
(
fk_categorie integer NOT NULL,
fk_fichinter integer NOT NULL,
import_key varchar(14)
)ENGINE=innodb;

-- VMYSQL4.3 ALTER TABLE llx_categorie_fichinter ADD PRIMARY KEY pk_categorie_fichinter(fk_categorie, fk_fichinter);
-- VPGSQL8.2 ALTER TABLE llx_categorie_fichinter ADD PRIMARY KEY pk_categorie_fichinter (fk_categorie, fk_fichinter);

ALTER TABLE llx_categorie_fichinter ADD INDEX idx_categorie_fichinter_fk_categorie (fk_categorie);
ALTER TABLE llx_categorie_fichinter ADD INDEX idx_categorie_fichinter_fk_fichinter (fk_fichinter);

ALTER TABLE llx_categorie_fichinter ADD CONSTRAINT fk_categorie_fichinter_categorie_rowid FOREIGN KEY (fk_categorie) REFERENCES llx_categorie (rowid);
ALTER TABLE llx_categorie_fichinter ADD CONSTRAINT fk_categorie_fichinter_fk_fichinter FOREIGN KEY (fk_fichinter) REFERENCES llx_fichinter (rowid);


ALTER TABLE llx_blockedlog DROP INDEX entity_action;
ALTER TABLE llx_blockedlog ADD INDEX entity_rowid (entity, rowid);

Expand Down Expand Up @@ -345,4 +348,3 @@ INSERT INTO llx_c_type_contact (element, source, code, libelle, active ) values
ALTER TABLE llx_facture_rec ADD COLUMN fk_societe_rib integer DEFAULT NULL;

ALTER TABLE llx_facture ADD COLUMN is_also_delivery_note tinyint DEFAULT 0 NOT NULL;

0 comments on commit 74f0d9b

Please sign in to comment.