From 2b5746aec38d620a683d3cd24ff332d73704c1e7 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Thu, 29 Oct 2015 21:05:47 +0100 Subject: [PATCH] Add field position into some dictionaries tables --- htdocs/install/mysql/data/llx_c_typent.sql | 2 ++ htdocs/install/mysql/migration/3.8.0-3.9.0.sql | 3 +++ htdocs/install/mysql/tables/llx_c_forme_juridique.sql | 3 ++- htdocs/install/mysql/tables/llx_c_type_fees.sql | 3 ++- htdocs/install/mysql/tables/llx_c_typent.sql | 3 ++- 5 files changed, 11 insertions(+), 3 deletions(-) diff --git a/htdocs/install/mysql/data/llx_c_typent.sql b/htdocs/install/mysql/data/llx_c_typent.sql index 918230cc5a3..11b512f26c2 100644 --- a/htdocs/install/mysql/data/llx_c_typent.sql +++ b/htdocs/install/mysql/data/llx_c_typent.sql @@ -31,6 +31,7 @@ -- delete from llx_c_typent; +-- Entries for all countries insert into llx_c_typent (id,code,libelle,fk_country,active) values ( 0, 'TE_UNKNOWN', '-', NULL, 1); insert into llx_c_typent (id,code,libelle,fk_country,active) values ( 1, 'TE_STARTUP', 'Start-up', NULL, 0); insert into llx_c_typent (id,code,libelle,fk_country,active) values ( 2, 'TE_GROUP', 'Grand groupe', NULL, 1); @@ -41,6 +42,7 @@ insert into llx_c_typent (id,code,libelle,fk_country,active) values ( 6, 'TE_WH insert into llx_c_typent (id,code,libelle,fk_country,active) values ( 7, 'TE_RETAIL', 'Revendeur', NULL, 0); insert into llx_c_typent (id,code,libelle,fk_country,active) values ( 8, 'TE_PRIVATE', 'Particulier', NULL, 1); insert into llx_c_typent (id,code,libelle,fk_country,active) values (100, 'TE_OTHER', 'Autres', NULL, 1); +-- Argentina (country 23) insert into llx_c_typent (id,code,libelle,fk_country,active) values (231, 'TE_A_RI', 'Responsable Inscripto', 23, 0); insert into llx_c_typent (id,code,libelle,fk_country,active) values (232, 'TE_B_RNI', 'Responsable No Inscripto', 23, 0); insert into llx_c_typent (id,code,libelle,fk_country,active) values (233, 'TE_C_FE', 'Consumidor Final/Exento', 23, 0); diff --git a/htdocs/install/mysql/migration/3.8.0-3.9.0.sql b/htdocs/install/mysql/migration/3.8.0-3.9.0.sql index 94d7cd53314..82dff688eda 100755 --- a/htdocs/install/mysql/migration/3.8.0-3.9.0.sql +++ b/htdocs/install/mysql/migration/3.8.0-3.9.0.sql @@ -224,3 +224,6 @@ create table llx_budget_lines import_key integer )ENGINE=innodb; +ALTER TABLE llx_c_typent ADD COLUMN position integer NOT NULL DEFAULT 0; +ALTER TABLE llx_c_forme_juridique ADD COLUMN position integer NOT NULL DEFAULT 0; +ALTER TABLE llx_c_type_fees ADD COLUMN position integer NOT NULL DEFAULT 0; diff --git a/htdocs/install/mysql/tables/llx_c_forme_juridique.sql b/htdocs/install/mysql/tables/llx_c_forme_juridique.sql index 0087f371092..ea8b45bf2d7 100644 --- a/htdocs/install/mysql/tables/llx_c_forme_juridique.sql +++ b/htdocs/install/mysql/tables/llx_c_forme_juridique.sql @@ -25,6 +25,7 @@ create table llx_c_forme_juridique libelle varchar(255), isvatexempted tinyint DEFAULT 0 NOT NULL, active tinyint DEFAULT 1 NOT NULL, - module varchar(32) NULL + module varchar(32) NULL, + position integer NOT NULL DEFAULT 0 )ENGINE=innodb; diff --git a/htdocs/install/mysql/tables/llx_c_type_fees.sql b/htdocs/install/mysql/tables/llx_c_type_fees.sql index e980562aff2..80bb3d9109d 100644 --- a/htdocs/install/mysql/tables/llx_c_type_fees.sql +++ b/htdocs/install/mysql/tables/llx_c_type_fees.sql @@ -25,5 +25,6 @@ create table llx_c_type_fees label varchar(30), accountancy_code varchar(32) NULL, active tinyint DEFAULT 1 NOT NULL, - module varchar(32) NULL + module varchar(32) NULL, + position integer NOT NULL DEFAULT 0 )ENGINE=innodb; diff --git a/htdocs/install/mysql/tables/llx_c_typent.sql b/htdocs/install/mysql/tables/llx_c_typent.sql index 06a41727b69..d492c41ff13 100644 --- a/htdocs/install/mysql/tables/llx_c_typent.sql +++ b/htdocs/install/mysql/tables/llx_c_typent.sql @@ -24,5 +24,6 @@ create table llx_c_typent libelle varchar(30), fk_country integer NULL, -- Defined only to have specific list for countries that can't use generic list (like argentina that need type A or B) active tinyint DEFAULT 1 NOT NULL, - module varchar(32) NULL + module varchar(32) NULL, + position integer NOT NULL DEFAULT 0 )ENGINE=innodb;