Prepare database for more localtax types.
This commit is contained in:
parent
72749bfc5f
commit
01b2a6a79b
@ -105,3 +105,21 @@ CREATE TABLE llx_c_revenuestamp
|
|||||||
insert into llx_c_revenuestamp(rowid,fk_pays,taux,note,active) values (101, 10, '0.4', 'Timbre fiscal', 1);
|
insert into llx_c_revenuestamp(rowid,fk_pays,taux,note,active) values (101, 10, '0.4', 'Timbre fiscal', 1);
|
||||||
|
|
||||||
ALTER TABLE llx_actioncomm ADD COLUMN code varchar(32) NULL after fk_action;
|
ALTER TABLE llx_actioncomm ADD COLUMN code varchar(32) NULL after fk_action;
|
||||||
|
|
||||||
|
ALTER TABLE llx_c_tva MODIFY COLUMN localtax1_type varchar(10) NOT NULL DEFAULT '0';
|
||||||
|
ALTER TABLE llx_c_tva MODIFY COLUMN localtax2_type varchar(10) NOT NULL DEFAULT '0';
|
||||||
|
ALTER TABLE llx_commande_fournisseurdet MODIFY COLUMN localtax1_type varchar(10) NOT NULL DEFAULT '0';
|
||||||
|
ALTER TABLE llx_commande_fournisseurdet MODIFY COLUMN localtax2_type varchar(10) NOT NULL DEFAULT '0';
|
||||||
|
ALTER TABLE llx_commandedet MODIFY COLUMN localtax1_type varchar(10) NOT NULL DEFAULT '0';
|
||||||
|
ALTER TABLE llx_commandedet MODIFY COLUMN localtax2_type varchar(10) NOT NULL DEFAULT '0';
|
||||||
|
ALTER TABLE llx_contratdet MODIFY COLUMN localtax1_type varchar(10) NOT NULL DEFAULT '0';
|
||||||
|
ALTER TABLE llx_contratdet MODIFY COLUMN localtax2_type varchar(10) NOT NULL DEFAULT '0';
|
||||||
|
ALTER TABLE llx_facture_fourn_det MODIFY COLUMN localtax1_type varchar(10) NOT NULL DEFAULT '0';
|
||||||
|
ALTER TABLE llx_facture_fourn_det MODIFY COLUMN localtax2_type varchar(10) NOT NULL DEFAULT '0';
|
||||||
|
ALTER TABLE llx_facturedet_rec MODIFY COLUMN localtax1_type varchar(10) NOT NULL DEFAULT '0';
|
||||||
|
ALTER TABLE llx_facturedet_rec MODIFY COLUMN localtax2_type varchar(10) NOT NULL DEFAULT '0';
|
||||||
|
ALTER TABLE llx_facturedet MODIFY COLUMN localtax1_type varchar(10) NOT NULL DEFAULT '0';
|
||||||
|
ALTER TABLE llx_facturedet MODIFY COLUMN localtax2_type varchar(10) NOT NULL DEFAULT '0';
|
||||||
|
ALTER TABLE llx_propaldet MODIFY COLUMN localtax1_type varchar(10) NOT NULL DEFAULT '0';
|
||||||
|
ALTER TABLE llx_propaldet MODIFY COLUMN localtax2_type varchar(10) NOT NULL DEFAULT '0';
|
||||||
|
|
||||||
|
|||||||
@ -24,9 +24,9 @@ create table llx_c_tva
|
|||||||
fk_pays integer NOT NULL,
|
fk_pays integer NOT NULL,
|
||||||
taux double NOT NULL,
|
taux double NOT NULL,
|
||||||
localtax1 double NOT NULL DEFAULT 0,
|
localtax1 double NOT NULL DEFAULT 0,
|
||||||
localtax1_type varchar(1) NOT NULL DEFAULT '0',
|
localtax1_type varchar(10) NOT NULL DEFAULT '0',
|
||||||
localtax2 double NOT NULL DEFAULT 0,
|
localtax2 double NOT NULL DEFAULT 0,
|
||||||
localtax2_type varchar(1) NOT NULL DEFAULT '0',
|
localtax2_type varchar(10) NOT NULL DEFAULT '0',
|
||||||
recuperableonly integer NOT NULL DEFAULT 0,
|
recuperableonly integer NOT NULL DEFAULT 0,
|
||||||
note varchar(128),
|
note varchar(128),
|
||||||
active tinyint DEFAULT 1 NOT NULL,
|
active tinyint DEFAULT 1 NOT NULL,
|
||||||
|
|||||||
@ -28,9 +28,9 @@ create table llx_commande_fournisseurdet
|
|||||||
description text,
|
description text,
|
||||||
tva_tx double(6,3) DEFAULT 0, -- taux tva
|
tva_tx double(6,3) DEFAULT 0, -- taux tva
|
||||||
localtax1_tx double(6,3) DEFAULT 0, -- localtax1 rate
|
localtax1_tx double(6,3) DEFAULT 0, -- localtax1 rate
|
||||||
localtax1_type varchar(1) NULL, -- localtax1 type
|
localtax1_type varchar(10) NULL, -- localtax1 type
|
||||||
localtax2_tx double(6,3) DEFAULT 0, -- localtax2 rate
|
localtax2_tx double(6,3) DEFAULT 0, -- localtax2 rate
|
||||||
localtax2_type varchar(1) NULL, -- localtax2 type
|
localtax2_type varchar(10) NULL, -- localtax2 type
|
||||||
qty real, -- quantity
|
qty real, -- quantity
|
||||||
remise_percent real DEFAULT 0, -- pourcentage de remise
|
remise_percent real DEFAULT 0, -- pourcentage de remise
|
||||||
remise real DEFAULT 0, -- montant de la remise
|
remise real DEFAULT 0, -- montant de la remise
|
||||||
|
|||||||
@ -29,9 +29,9 @@ create table llx_commandedet
|
|||||||
description text,
|
description text,
|
||||||
tva_tx double(6,3), -- vat rate
|
tva_tx double(6,3), -- vat rate
|
||||||
localtax1_tx double(6,3) DEFAULT 0, -- localtax1 rate
|
localtax1_tx double(6,3) DEFAULT 0, -- localtax1 rate
|
||||||
localtax1_type varchar(1) NULL, -- localtax1 type
|
localtax1_type varchar(10) NULL, -- localtax1 type
|
||||||
localtax2_tx double(6,3) DEFAULT 0, -- localtax2 rate
|
localtax2_tx double(6,3) DEFAULT 0, -- localtax2 rate
|
||||||
localtax2_type varchar(1) NULL, -- localtax2 type
|
localtax2_type varchar(10) NULL, -- localtax2 type
|
||||||
qty real, -- quantity
|
qty real, -- quantity
|
||||||
remise_percent real DEFAULT 0, -- pourcentage de remise
|
remise_percent real DEFAULT 0, -- pourcentage de remise
|
||||||
remise real DEFAULT 0, -- montant de la remise
|
remise real DEFAULT 0, -- montant de la remise
|
||||||
|
|||||||
@ -39,9 +39,9 @@ create table llx_contratdet
|
|||||||
|
|
||||||
tva_tx double(6,3) DEFAULT 0, -- taux tva
|
tva_tx double(6,3) DEFAULT 0, -- taux tva
|
||||||
localtax1_tx double(6,3) DEFAULT 0, -- local tax 1 rate
|
localtax1_tx double(6,3) DEFAULT 0, -- local tax 1 rate
|
||||||
localtax1_type varchar(1) NULL, -- localtax1 type
|
localtax1_type varchar(10) NULL, -- localtax1 type
|
||||||
localtax2_tx double(6,3) DEFAULT 0, -- local tax 2 rate
|
localtax2_tx double(6,3) DEFAULT 0, -- local tax 2 rate
|
||||||
localtax2_type varchar(1) NULL, -- localtax2 type
|
localtax2_type varchar(10) NULL, -- localtax2 type
|
||||||
qty real NOT NULL, -- quantity
|
qty real NOT NULL, -- quantity
|
||||||
remise_percent real DEFAULT 0, -- pourcentage de remise
|
remise_percent real DEFAULT 0, -- pourcentage de remise
|
||||||
subprice double(24,8) DEFAULT 0, -- prix unitaire
|
subprice double(24,8) DEFAULT 0, -- prix unitaire
|
||||||
|
|||||||
@ -32,9 +32,9 @@ create table llx_facture_fourn_det
|
|||||||
remise_percent real DEFAULT 0, -- % de la remise ligne (exemple 20%)
|
remise_percent real DEFAULT 0, -- % de la remise ligne (exemple 20%)
|
||||||
tva_tx double(6,3), -- TVA taux product/service
|
tva_tx double(6,3), -- TVA taux product/service
|
||||||
localtax1_tx double(6,3) DEFAULT 0, -- localtax1 rate
|
localtax1_tx double(6,3) DEFAULT 0, -- localtax1 rate
|
||||||
localtax1_type varchar(1) NULL, -- localtax1 type
|
localtax1_type varchar(10) NULL, -- localtax1 type
|
||||||
localtax2_tx double(6,3) DEFAULT 0, -- localtax2 rate
|
localtax2_tx double(6,3) DEFAULT 0, -- localtax2 rate
|
||||||
localtax2_type varchar(1) NULL, -- localtax2 type
|
localtax2_type varchar(10) NULL, -- localtax2 type
|
||||||
total_ht double(24,8), -- Total line price of product excluding tax
|
total_ht double(24,8), -- Total line price of product excluding tax
|
||||||
tva double(24,8), -- Total TVA of line
|
tva double(24,8), -- Total TVA of line
|
||||||
total_localtax1 double(24,8) DEFAULT 0, -- Total LocalTax1 for total quantity of line
|
total_localtax1 double(24,8) DEFAULT 0, -- Total LocalTax1 for total quantity of line
|
||||||
|
|||||||
@ -30,9 +30,9 @@ create table llx_facturedet
|
|||||||
description text,
|
description text,
|
||||||
tva_tx double(6,3), -- Taux tva produit/service (exemple 19.6)
|
tva_tx double(6,3), -- Taux tva produit/service (exemple 19.6)
|
||||||
localtax1_tx double(6,3) DEFAULT 0, -- localtax1 rate
|
localtax1_tx double(6,3) DEFAULT 0, -- localtax1 rate
|
||||||
localtax1_type varchar(1) NULL, -- localtax1 type
|
localtax1_type varchar(10) NULL, -- localtax1 type
|
||||||
localtax2_tx double(6,3) DEFAULT 0, -- localtax2 rate
|
localtax2_tx double(6,3) DEFAULT 0, -- localtax2 rate
|
||||||
localtax2_type varchar(1) NULL, -- localtax2 type
|
localtax2_type varchar(10) NULL, -- localtax2 type
|
||||||
qty real, -- Quantity (exemple 2)
|
qty real, -- Quantity (exemple 2)
|
||||||
remise_percent real DEFAULT 0, -- % de la remise ligne (exemple 20%)
|
remise_percent real DEFAULT 0, -- % de la remise ligne (exemple 20%)
|
||||||
remise real DEFAULT 0, -- Montant calcule de la remise % sur PU HT (exemple 20)
|
remise real DEFAULT 0, -- Montant calcule de la remise % sur PU HT (exemple 20)
|
||||||
|
|||||||
@ -30,9 +30,9 @@ create table llx_facturedet_rec
|
|||||||
description text,
|
description text,
|
||||||
tva_tx double(6,3) DEFAULT 19.6, -- taux tva
|
tva_tx double(6,3) DEFAULT 19.6, -- taux tva
|
||||||
localtax1_tx double(6,3) DEFAULT 0, -- localtax1 rate
|
localtax1_tx double(6,3) DEFAULT 0, -- localtax1 rate
|
||||||
localtax1_type varchar(1) NULL, -- localtax1 type
|
localtax1_type varchar(10) NULL, -- localtax1 type
|
||||||
localtax2_tx double(6,3) DEFAULT 0, -- localtax2 rate
|
localtax2_tx double(6,3) DEFAULT 0, -- localtax2 rate
|
||||||
localtax2_type varchar(1) NULL, -- localtax2 type
|
localtax2_type varchar(10) NULL, -- localtax2 type
|
||||||
qty real, -- quantity
|
qty real, -- quantity
|
||||||
remise_percent real DEFAULT 0, -- pourcentage de remise
|
remise_percent real DEFAULT 0, -- pourcentage de remise
|
||||||
remise real DEFAULT 0, -- montant de la remise
|
remise real DEFAULT 0, -- montant de la remise
|
||||||
|
|||||||
@ -29,9 +29,9 @@ create table llx_propaldet
|
|||||||
fk_remise_except integer NULL, -- Lien vers table des remises fixes
|
fk_remise_except integer NULL, -- Lien vers table des remises fixes
|
||||||
tva_tx double(6,3) DEFAULT 0, -- taux tva
|
tva_tx double(6,3) DEFAULT 0, -- taux tva
|
||||||
localtax1_tx double(6,3) DEFAULT 0, -- localtax1 rate
|
localtax1_tx double(6,3) DEFAULT 0, -- localtax1 rate
|
||||||
localtax1_type varchar(1) NULL, -- localtax1 type
|
localtax1_type varchar(10) NULL, -- localtax1 type
|
||||||
localtax2_tx double(6,3) DEFAULT 0, -- localtax2 rate
|
localtax2_tx double(6,3) DEFAULT 0, -- localtax2 rate
|
||||||
localtax2_type varchar(1) NULL, -- localtax2 type
|
localtax2_type varchar(10) NULL, -- localtax2 type
|
||||||
qty real, -- quantity
|
qty real, -- quantity
|
||||||
remise_percent real DEFAULT 0, -- pourcentage de remise
|
remise_percent real DEFAULT 0, -- pourcentage de remise
|
||||||
remise real DEFAULT 0, -- montant de la remise (obsolete)
|
remise real DEFAULT 0, -- montant de la remise (obsolete)
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user