New: Add barcode fields into user database.
This commit is contained in:
parent
07ac9d3922
commit
3c842f9b6f
@ -31,6 +31,7 @@ For users:
|
||||
- New: Created {line_price_ht_locale}, {line_price_vat_locale} and {line_price_ttc_locale} ODT tags.
|
||||
- New: Add filter on project status into task list. By default, only "opened" project are visible.
|
||||
- New: Status "validated" for project are renamed into "opened".
|
||||
- New: Add barcode fields into user database.
|
||||
- Fix: Project Task numbering customs rule works.
|
||||
|
||||
TODO
|
||||
|
||||
@ -991,11 +991,13 @@ ALTER TABLE llx_product_customer_price ADD UNIQUE INDEX uk_customer_price_fk_pro
|
||||
ALTER TABLE llx_product_customer_price ADD CONSTRAINT fk_customer_price_fk_product FOREIGN KEY (fk_product) REFERENCES llx_product(rowid) ON DELETE CASCADE;
|
||||
ALTER TABLE llx_product_customer_price ADD CONSTRAINT fk_customer_price_fk_soc FOREIGN KEY (fk_soc) REFERENCES llx_societe(rowid) ON DELETE CASCADE;
|
||||
|
||||
ALTER TABLE llx_user ADD COLUMN barcode varchar(255) DEFAULT NULL;
|
||||
ALTER TABLE llx_user ADD COLUMN fk_barcode_type integer DEFAULT 0;
|
||||
|
||||
create table llx_product_customer_price_log
|
||||
(
|
||||
rowid integer AUTO_INCREMENT PRIMARY KEY,
|
||||
entity integer DEFAULT 1 NOT NULL, -- multi company id
|
||||
entity integer DEFAULT 1 NOT NULL, -- multi company id
|
||||
datec datetime,
|
||||
fk_product integer NOT NULL,
|
||||
fk_soc integer NOT NULL,
|
||||
@ -1015,43 +1017,43 @@ create table llx_product_customer_price_log
|
||||
--Batch number managment
|
||||
ALTER TABLE llx_product ADD COLUMN tobatch tinyint DEFAULT 0 NOT NULL;
|
||||
|
||||
CREATE TABLE IF NOT EXISTS `llx_product_batch` (
|
||||
`rowid` int(11) NOT NULL AUTO_INCREMENT PRIMARY KEY,
|
||||
`tms` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
`fk_product_stock` int(11) NOT NULL,
|
||||
`eatby` datetime DEFAULT NULL,
|
||||
`sellby` datetime DEFAULT NULL,
|
||||
`batch` varchar(30) DEFAULT NULL,
|
||||
`qty` double NOT NULL DEFAULT '0',
|
||||
`import_key` varchar(14) DEFAULT NULL,
|
||||
KEY `ix_fk_product_stock` (`fk_product_stock`)
|
||||
CREATE TABLE IF NOT EXISTS llx_product_batch (
|
||||
rowid int(11) NOT NULL AUTO_INCREMENT PRIMARY KEY,
|
||||
tms timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
fk_product_stock int(11) NOT NULL,
|
||||
eatby datetime DEFAULT NULL,
|
||||
sellby datetime DEFAULT NULL,
|
||||
batch varchar(30) DEFAULT NULL,
|
||||
qty double NOT NULL DEFAULT '0',
|
||||
import_key varchar(14) DEFAULT NULL,
|
||||
KEY ix_fk_product_stock (fk_product_stock)
|
||||
) ENGINE=InnoDB;
|
||||
|
||||
CREATE TABLE IF NOT EXISTS `llx_expeditiondet_batch` (
|
||||
`rowid` int(11) NOT NULL AUTO_INCREMENT PRIMARY KEY,
|
||||
`fk_expeditiondet` int(11) NOT NULL,
|
||||
`eatby` date DEFAULT NULL,
|
||||
`sellby` date DEFAULT NULL,
|
||||
`batch` varchar(30) DEFAULT NULL,
|
||||
`qty` double NOT NULL DEFAULT '0',
|
||||
`fk_origin_stock` int(11) NOT NULL,
|
||||
KEY `ix_fk_expeditiondet` (`fk_expeditiondet`)
|
||||
CREATE TABLE IF NOT EXISTS llx_expeditiondet_batch (
|
||||
rowid int(11) NOT NULL AUTO_INCREMENT PRIMARY KEY,
|
||||
fk_expeditiondet int(11) NOT NULL,
|
||||
eatby date DEFAULT NULL,
|
||||
sellby date DEFAULT NULL,
|
||||
batch varchar(30) DEFAULT NULL,
|
||||
qty double NOT NULL DEFAULT '0',
|
||||
fk_origin_stock int(11) NOT NULL,
|
||||
KEY ix_fk_expeditiondet (fk_expeditiondet)
|
||||
) ENGINE=InnoDB;
|
||||
|
||||
--Salary payment in tax module
|
||||
CREATE TABLE IF NOT EXISTS `llx_payment_salary` (
|
||||
`rowid` integer AUTO_INCREMENT PRIMARY KEY,
|
||||
`tms` timestamp,
|
||||
`fk_user` integer NOT NULL,
|
||||
`datep` date,
|
||||
`datev` date,
|
||||
`amount` real NOT NULL DEFAULT 0,
|
||||
`label` varchar(255),
|
||||
`datesp` date, -- date de début de la période
|
||||
`dateep` date, -- date de fin de la période
|
||||
`entity` integer DEFAULT 1 NOT NULL, -- multi company id
|
||||
`note` text,
|
||||
`fk_bank` integer,
|
||||
`fk_user_creat` integer,
|
||||
`fk_user_modif` integer
|
||||
CREATE TABLE IF NOT EXISTS llx_payment_salary (
|
||||
rowid integer AUTO_INCREMENT PRIMARY KEY,
|
||||
tms timestamp,
|
||||
fk_user integer NOT NULL,
|
||||
datep date,
|
||||
datev date,
|
||||
amount real NOT NULL DEFAULT 0,
|
||||
label varchar(255),
|
||||
datesp date, -- date de début de la période
|
||||
dateep date, -- date de fin de la période
|
||||
entity integer DEFAULT 1 NOT NULL, -- multi company id
|
||||
note text,
|
||||
fk_bank integer,
|
||||
fk_user_creat integer,
|
||||
fk_user_modif integer
|
||||
)ENGINE=innodb;
|
||||
@ -43,21 +43,21 @@ create table llx_product
|
||||
price_min double(24,8) DEFAULT 0,
|
||||
price_min_ttc double(24,8) DEFAULT 0,
|
||||
price_base_type varchar(3) DEFAULT 'HT',
|
||||
tva_tx double(6,3),
|
||||
recuperableonly integer NOT NULL DEFAULT '0', -- French NPR VAT
|
||||
tva_tx double(6,3), -- Default VAT rate of product
|
||||
recuperableonly integer NOT NULL DEFAULT '0', -- French NPR VAT
|
||||
localtax1_tx double(6,3) DEFAULT 0, -- Spanish local VAT 1
|
||||
localtax2_tx double(6,3) DEFAULT 0, -- Spanish local VAT 2
|
||||
fk_user_author integer,
|
||||
tosell tinyint DEFAULT 1,
|
||||
tobuy tinyint DEFAULT 1,
|
||||
tobatch tinyint DEFAULT 0 NOT NULL,
|
||||
fk_product_type integer DEFAULT 0, -- Type 0 for regular product, 1 for service, 9 for other (used by external module)
|
||||
tosell tinyint DEFAULT 1, -- Product you sell
|
||||
tobuy tinyint DEFAULT 1, -- Product you buy
|
||||
tobatch tinyint DEFAULT 0 NOT NULL, -- Is it a product that need a batch or eat-by management
|
||||
fk_product_type integer DEFAULT 0, -- Type of product: 0 for regular product, 1 for service, 9 for other (used by external module)
|
||||
duration varchar(6),
|
||||
seuil_stock_alerte integer DEFAULT 0,
|
||||
barcode varchar(255) DEFAULT NULL,
|
||||
fk_barcode_type integer DEFAULT 0,
|
||||
accountancy_code_sell varchar(15), -- Selling accountancy code
|
||||
accountancy_code_buy varchar(15), -- Buying accountancy code
|
||||
accountancy_code_sell varchar(15), -- Selling accountancy code
|
||||
accountancy_code_buy varchar(15), -- Buying accountancy code
|
||||
partnumber varchar(32), -- Not used. Used by external modules.
|
||||
weight float DEFAULT NULL,
|
||||
weight_units tinyint DEFAULT NULL,
|
||||
@ -71,7 +71,7 @@ create table llx_product
|
||||
pmp double(24,8) DEFAULT 0 NOT NULL,
|
||||
canvas varchar(32) DEFAULT NULL,
|
||||
finished tinyint DEFAULT NULL,
|
||||
hidden tinyint DEFAULT 0, -- Need permission see also hidden products
|
||||
hidden tinyint DEFAULT 0, -- Not used. Deprecated.
|
||||
import_key varchar(14), -- Import key
|
||||
desiredstock integer DEFAULT 0
|
||||
)ENGINE=innodb;
|
||||
|
||||
@ -64,5 +64,7 @@ create table llx_user
|
||||
photo varchar(255), -- filename or url of photo
|
||||
lang varchar(6),
|
||||
color varchar(6),
|
||||
barcode varchar(255) DEFAULT NULL,
|
||||
fk_barcode_type integer DEFAULT 0,
|
||||
accountancy_code varchar(24) NULL
|
||||
)ENGINE=innodb;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user