diff --git a/htdocs/install/mysql/migration/20.0.0-21.0.0.sql b/htdocs/install/mysql/migration/20.0.0-21.0.0.sql index ddefc5b15d5..48029144088 100644 --- a/htdocs/install/mysql/migration/20.0.0-21.0.0.sql +++ b/htdocs/install/mysql/migration/20.0.0-21.0.0.sql @@ -174,6 +174,12 @@ ALTER TABLE llx_societe_perentity MODIFY COLUMN accountancy_code_customer varcha ALTER TABLE llx_societe_perentity MODIFY COLUMN accountancy_code_supplier varchar(32); +ALTER TABLE llx_multicurrency ADD COLUMN tms timestamp DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP; + +ALTER TABLE llx_multicurrency_rate ADD COLUMN tms timestamp DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP; + + + -- Copy categories from llx_category_bank into llx_categorie INSERT INTO llx_categorie (entity, fk_parent, label, type, description, color, position, visible, date_creation) diff --git a/htdocs/install/mysql/tables/llx_multicurrency.sql b/htdocs/install/mysql/tables/llx_multicurrency.sql index 6a5a92f9fd4..9d8feb0adc5 100644 --- a/htdocs/install/mysql/tables/llx_multicurrency.sql +++ b/htdocs/install/mysql/tables/llx_multicurrency.sql @@ -18,11 +18,12 @@ -- ======================================================================== CREATE TABLE llx_multicurrency -( - rowid integer AUTO_INCREMENT PRIMARY KEY, - date_create datetime DEFAULT NULL, - code varchar(255) DEFAULT NULL, - name varchar(255) DEFAULT NULL, - entity integer DEFAULT 1, - fk_user integer DEFAULT NULL +( + rowid integer AUTO_INCREMENT PRIMARY KEY, + date_create datetime DEFAULT NULL, + code varchar(255) DEFAULT NULL, + name varchar(255) DEFAULT NULL, + entity integer DEFAULT 1, + fk_user integer DEFAULT NULL, + tms timestamp DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP ) ENGINE=innodb; diff --git a/htdocs/install/mysql/tables/llx_multicurrency_rate.sql b/htdocs/install/mysql/tables/llx_multicurrency_rate.sql index a99d1e911e0..77eab1c47fd 100644 --- a/htdocs/install/mysql/tables/llx_multicurrency_rate.sql +++ b/htdocs/install/mysql/tables/llx_multicurrency_rate.sql @@ -18,11 +18,12 @@ -- ======================================================================== CREATE TABLE llx_multicurrency_rate -( - rowid integer AUTO_INCREMENT PRIMARY KEY, - date_sync datetime DEFAULT NULL, - rate double NOT NULL DEFAULT 0, - rate_indirect double DEFAULT 0, - fk_multicurrency integer NOT NULL, - entity integer DEFAULT 1 +( + rowid integer AUTO_INCREMENT PRIMARY KEY, + date_sync datetime DEFAULT NULL, + rate double NOT NULL DEFAULT 0, + rate_indirect double DEFAULT 0, + fk_multicurrency integer NOT NULL, + entity integer DEFAULT 1, + tms timestamp DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP ) ENGINE=innodb;