From d3998336d5a344f6975d8b0d768a65dce2042d82 Mon Sep 17 00:00:00 2001 From: Regis Houssin <regis@dolibarr.fr> Date: Tue, 23 Feb 2010 10:48:48 +0000 Subject: [PATCH] Fix: move to dolibarrmod --- .../install/mysql/migration/2.8.0-2.9.0.sql | 57 ------------------- .../mysql/tables/llx_product_variant.key.sql | 23 -------- .../mysql/tables/llx_product_variant.sql | 29 ---------- .../llx_product_variant_combination.key.sql | 26 --------- .../llx_product_variant_combination.sql | 25 -------- .../tables/llx_product_variant_lang.key.sql | 26 --------- .../mysql/tables/llx_product_variant_lang.sql | 27 --------- .../tables/llx_product_variant_values.key.sql | 25 -------- .../tables/llx_product_variant_values.sql | 28 --------- .../llx_product_variant_values_lang.key.sql | 26 --------- .../llx_product_variant_values_lang.sql | 27 --------- 11 files changed, 319 deletions(-) delete mode 100644 htdocs/install/mysql/tables/llx_product_variant.key.sql delete mode 100644 htdocs/install/mysql/tables/llx_product_variant.sql delete mode 100644 htdocs/install/mysql/tables/llx_product_variant_combination.key.sql delete mode 100644 htdocs/install/mysql/tables/llx_product_variant_combination.sql delete mode 100644 htdocs/install/mysql/tables/llx_product_variant_lang.key.sql delete mode 100644 htdocs/install/mysql/tables/llx_product_variant_lang.sql delete mode 100644 htdocs/install/mysql/tables/llx_product_variant_values.key.sql delete mode 100644 htdocs/install/mysql/tables/llx_product_variant_values.sql delete mode 100644 htdocs/install/mysql/tables/llx_product_variant_values_lang.key.sql delete mode 100644 htdocs/install/mysql/tables/llx_product_variant_values_lang.sql diff --git a/htdocs/install/mysql/migration/2.8.0-2.9.0.sql b/htdocs/install/mysql/migration/2.8.0-2.9.0.sql index c4ae0a983d1..a083174b781 100755 --- a/htdocs/install/mysql/migration/2.8.0-2.9.0.sql +++ b/htdocs/install/mysql/migration/2.8.0-2.9.0.sql @@ -11,65 +11,8 @@ ALTER TABLE llx_product_det RENAME TO llx_product_lang; ALTER TABLE llx_product_lang ADD UNIQUE INDEX uk_product_lang (fk_product, lang); ALTER TABLE llx_product_lang ADD CONSTRAINT fk_product_lang_fk_product FOREIGN KEY (fk_product) REFERENCES llx_product (rowid); --- add products variants ability ALTER TABLE llx_product ADD COLUMN virtual tinyint DEFAULT 0 NOT NULL AFTER tms; ALTER TABLE llx_product ADD COLUMN fk_parent integer DEFAULT 0 AFTER virtual; -create table llx_product_variant -( - rowid integer AUTO_INCREMENT PRIMARY KEY, - tms timestamp, - ref varchar(64) NOT NULL, - entity integer DEFAULT 1 NOT NULL, -- multi company id - active tinyint DEFAULT 1 NOT NULL, - rang integer DEFAULT 0 -)type=innodb; - -ALTER TABLE llx_product_variant ADD UNIQUE INDEX uk_product_variant_ref (ref, entity); - -create table llx_product_variant_lang -( - rowid integer AUTO_INCREMENT PRIMARY KEY, - fk_product_variant integer DEFAULT 0 NOT NULL, - lang varchar(5) NOT NULL, - label varchar(64) NOT NULL -)type=innodb; - -ALTER TABLE llx_product_variant_lang ADD UNIQUE INDEX uk_product_variant_lang (fk_product_variant, lang); -ALTER TABLE llx_product_variant_lang ADD CONSTRAINT fk_product_variant_lang_fk_product_variant FOREIGN KEY (fk_product_variant) REFERENCES llx_product_variant (rowid); - -create table llx_product_variant_values -( - rowid integer AUTO_INCREMENT PRIMARY KEY, - tms timestamp, - fk_product_variant integer NOT NULL, - active tinyint DEFAULT 1 NOT NULL, - rang integer DEFAULT 0 -)type=innodb; - -ALTER TABLE llx_product_variant_values ADD UNIQUE INDEX idx_product_variant_values_fk_product_variant (fk_product_variant); -ALTER TABLE llx_product_variant_values ADD CONSTRAINT fk_product_variant_values_fk_product_variant FOREIGN KEY (fk_product_variant) REFERENCES llx_product_variant (rowid); - -create table llx_product_variant_values_lang -( - rowid integer AUTO_INCREMENT PRIMARY KEY, - fk_product_variant_values integer DEFAULT 0 NOT NULL, - lang varchar(5) NOT NULL, - label varchar(64) NOT NULL -)type=innodb; - -ALTER TABLE llx_product_variant_values_lang ADD UNIQUE INDEX uk_product_variant_values_lang (fk_product_variant_values, lang); -ALTER TABLE llx_product_variant_values_lang ADD CONSTRAINT fk_product_variant_values_lang_fk_product_variant_values FOREIGN KEY (fk_product_variant_values) REFERENCES llx_product_variant_values (rowid); - -create table llx_product_variant_combination -( - fk_product integer PRIMARY KEY, - fk_product_variant_values integer DEFAULT 0 NOT NULL -)type=innodb; - -ALTER TABLE llx_product_variant_combination ADD INDEX idx_product_variant_values_fk_product (fk_product, fk_product_variant_values); -ALTER TABLE llx_product_variant_combination ADD CONSTRAINT fk_product_variant_combination_fk_product FOREIGN KEY (fk_product) REFERENCES llx_product (rowid); -ALTER TABLE llx_product_variant_combination ADD CONSTRAINT fk_product_variant_combination_fk_product_variant_values FOREIGN KEY (fk_product_variant_values) REFERENCES llx_product_variant_values (rowid); - alter table llx_societe add column default_lang varchar(6) after price_level; alter table llx_socpeople add column default_lang varchar(6) after note; diff --git a/htdocs/install/mysql/tables/llx_product_variant.key.sql b/htdocs/install/mysql/tables/llx_product_variant.key.sql deleted file mode 100644 index e5fa9390446..00000000000 --- a/htdocs/install/mysql/tables/llx_product_variant.key.sql +++ /dev/null @@ -1,23 +0,0 @@ --- ============================================================================ --- Copyright (C) 2010 Regis Houssin <regis@dolibarr.fr> --- --- This program is free software; you can redistribute it and/or modify --- it under the terms of the GNU General Public License as published by --- the Free Software Foundation; either version 2 of the License, or --- (at your option) any later version. --- --- This program is distributed in the hope that it will be useful, --- but WITHOUT ANY WARRANTY; without even the implied warranty of --- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the --- GNU General Public License for more details. --- --- You should have received a copy of the GNU General Public License --- along with this program; if not, write to the Free Software --- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. --- --- $Id$ --- ============================================================================ - - -ALTER TABLE llx_product_variant ADD UNIQUE INDEX uk_product_variant_ref (ref, entity); - diff --git a/htdocs/install/mysql/tables/llx_product_variant.sql b/htdocs/install/mysql/tables/llx_product_variant.sql deleted file mode 100644 index 4bd42d74ebe..00000000000 --- a/htdocs/install/mysql/tables/llx_product_variant.sql +++ /dev/null @@ -1,29 +0,0 @@ --- ============================================================================ --- Copyright (C) 2010 Regis Houssin <regis@dolibarr.fr> --- --- This program is free software; you can redistribute it and/or modify --- it under the terms of the GNU General Public License as published by --- the Free Software Foundation; either version 2 of the License, or --- (at your option) any later version. --- --- This program is distributed in the hope that it will be useful, --- but WITHOUT ANY WARRANTY; without even the implied warranty of --- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the --- GNU General Public License for more details. --- --- You should have received a copy of the GNU General Public License --- along with this program; if not, write to the Free Software --- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. --- --- $Id$ --- ============================================================================ - -create table llx_product_variant -( - rowid integer AUTO_INCREMENT PRIMARY KEY, - tms timestamp, - ref varchar(64) NOT NULL, - entity integer DEFAULT 1 NOT NULL, -- multi company id - active tinyint DEFAULT 1 NOT NULL, - rang integer DEFAULT 0 -)type=innodb; diff --git a/htdocs/install/mysql/tables/llx_product_variant_combination.key.sql b/htdocs/install/mysql/tables/llx_product_variant_combination.key.sql deleted file mode 100644 index 665f0fd39e4..00000000000 --- a/htdocs/install/mysql/tables/llx_product_variant_combination.key.sql +++ /dev/null @@ -1,26 +0,0 @@ --- ============================================================================ --- Copyright (C) 2010 Regis Houssin <regis@dolibarr.fr> --- --- This program is free software; you can redistribute it and/or modify --- it under the terms of the GNU General Public License as published by --- the Free Software Foundation; either version 2 of the License, or --- (at your option) any later version. --- --- This program is distributed in the hope that it will be useful, --- but WITHOUT ANY WARRANTY; without even the implied warranty of --- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the --- GNU General Public License for more details. --- --- You should have received a copy of the GNU General Public License --- along with this program; if not, write to the Free Software --- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. --- --- $Id$ --- ============================================================================ - - -ALTER TABLE llx_product_variant_combination ADD INDEX idx_product_variant_values_fk_product (fk_product, fk_product_variant_values); - - -ALTER TABLE llx_product_variant_combination ADD CONSTRAINT fk_product_variant_combination_fk_product FOREIGN KEY (fk_product) REFERENCES llx_product (rowid); -ALTER TABLE llx_product_variant_combination ADD CONSTRAINT fk_product_variant_combination_fk_product_variant_values FOREIGN KEY (fk_product_variant_values) REFERENCES llx_product_variant_values (rowid); diff --git a/htdocs/install/mysql/tables/llx_product_variant_combination.sql b/htdocs/install/mysql/tables/llx_product_variant_combination.sql deleted file mode 100644 index 265d6dcb379..00000000000 --- a/htdocs/install/mysql/tables/llx_product_variant_combination.sql +++ /dev/null @@ -1,25 +0,0 @@ --- ============================================================================ --- Copyright (C) 2010 Regis Houssin <regis@dolibarr.fr> --- --- This program is free software; you can redistribute it and/or modify --- it under the terms of the GNU General Public License as published by --- the Free Software Foundation; either version 2 of the License, or --- (at your option) any later version. --- --- This program is distributed in the hope that it will be useful, --- but WITHOUT ANY WARRANTY; without even the implied warranty of --- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the --- GNU General Public License for more details. --- --- You should have received a copy of the GNU General Public License --- along with this program; if not, write to the Free Software --- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. --- --- $Id$ --- ============================================================================ - -create table llx_product_variant_combination -( - fk_product integer PRIMARY KEY, - fk_product_variant_values integer DEFAULT 0 NOT NULL -)type=innodb; diff --git a/htdocs/install/mysql/tables/llx_product_variant_lang.key.sql b/htdocs/install/mysql/tables/llx_product_variant_lang.key.sql deleted file mode 100644 index 6818083d2ca..00000000000 --- a/htdocs/install/mysql/tables/llx_product_variant_lang.key.sql +++ /dev/null @@ -1,26 +0,0 @@ --- ============================================================================ --- Copyright (C) 2010 Regis Houssin <regis@dolibarr.fr> --- --- This program is free software; you can redistribute it and/or modify --- it under the terms of the GNU General Public License as published by --- the Free Software Foundation; either version 2 of the License, or --- (at your option) any later version. --- --- This program is distributed in the hope that it will be useful, --- but WITHOUT ANY WARRANTY; without even the implied warranty of --- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the --- GNU General Public License for more details. --- --- You should have received a copy of the GNU General Public License --- along with this program; if not, write to the Free Software --- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. --- --- $Id$ --- ============================================================================ - - -ALTER TABLE llx_product_variant_lang ADD UNIQUE INDEX uk_product_variant_lang (fk_product_variant, lang); - - -ALTER TABLE llx_product_variant_lang ADD CONSTRAINT fk_product_variant_lang_fk_product_variant FOREIGN KEY (fk_product_variant) REFERENCES llx_product_variant (rowid); - diff --git a/htdocs/install/mysql/tables/llx_product_variant_lang.sql b/htdocs/install/mysql/tables/llx_product_variant_lang.sql deleted file mode 100644 index 53fc09f6ca6..00000000000 --- a/htdocs/install/mysql/tables/llx_product_variant_lang.sql +++ /dev/null @@ -1,27 +0,0 @@ --- ============================================================================ --- Copyright (C) 2010 Regis Houssin <regis@dolibarr.fr> --- --- This program is free software; you can redistribute it and/or modify --- it under the terms of the GNU General Public License as published by --- the Free Software Foundation; either version 2 of the License, or --- (at your option) any later version. --- --- This program is distributed in the hope that it will be useful, --- but WITHOUT ANY WARRANTY; without even the implied warranty of --- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the --- GNU General Public License for more details. --- --- You should have received a copy of the GNU General Public License --- along with this program; if not, write to the Free Software --- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. --- --- $Id$ --- ============================================================================ - -create table llx_product_variant_lang -( - rowid integer AUTO_INCREMENT PRIMARY KEY, - fk_product_variant integer DEFAULT 0 NOT NULL, - lang varchar(5) NOT NULL, - label varchar(64) NOT NULL -)type=innodb; diff --git a/htdocs/install/mysql/tables/llx_product_variant_values.key.sql b/htdocs/install/mysql/tables/llx_product_variant_values.key.sql deleted file mode 100644 index aebd2febcd3..00000000000 --- a/htdocs/install/mysql/tables/llx_product_variant_values.key.sql +++ /dev/null @@ -1,25 +0,0 @@ --- ============================================================================ --- Copyright (C) 2010 Regis Houssin <regis@dolibarr.fr> --- --- This program is free software; you can redistribute it and/or modify --- it under the terms of the GNU General Public License as published by --- the Free Software Foundation; either version 2 of the License, or --- (at your option) any later version. --- --- This program is distributed in the hope that it will be useful, --- but WITHOUT ANY WARRANTY; without even the implied warranty of --- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the --- GNU General Public License for more details. --- --- You should have received a copy of the GNU General Public License --- along with this program; if not, write to the Free Software --- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. --- --- $Id$ --- ============================================================================ - - -ALTER TABLE llx_product_variant_values ADD UNIQUE INDEX idx_product_variant_values_fk_product_variant (fk_product_variant); - - -ALTER TABLE llx_product_variant_values ADD CONSTRAINT fk_product_variant_values_fk_product_variant FOREIGN KEY (fk_product_variant) REFERENCES llx_product_variant (rowid); diff --git a/htdocs/install/mysql/tables/llx_product_variant_values.sql b/htdocs/install/mysql/tables/llx_product_variant_values.sql deleted file mode 100644 index 6292be6134a..00000000000 --- a/htdocs/install/mysql/tables/llx_product_variant_values.sql +++ /dev/null @@ -1,28 +0,0 @@ --- ============================================================================ --- Copyright (C) 2010 Regis Houssin <regis@dolibarr.fr> --- --- This program is free software; you can redistribute it and/or modify --- it under the terms of the GNU General Public License as published by --- the Free Software Foundation; either version 2 of the License, or --- (at your option) any later version. --- --- This program is distributed in the hope that it will be useful, --- but WITHOUT ANY WARRANTY; without even the implied warranty of --- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the --- GNU General Public License for more details. --- --- You should have received a copy of the GNU General Public License --- along with this program; if not, write to the Free Software --- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. --- --- $Id$ --- ============================================================================ - -create table llx_product_variant_values -( - rowid integer AUTO_INCREMENT PRIMARY KEY, - tms timestamp, - fk_product_variant integer NOT NULL, - active tinyint DEFAULT 1 NOT NULL, - rang integer DEFAULT 0 -)type=innodb; diff --git a/htdocs/install/mysql/tables/llx_product_variant_values_lang.key.sql b/htdocs/install/mysql/tables/llx_product_variant_values_lang.key.sql deleted file mode 100644 index d4e50183b79..00000000000 --- a/htdocs/install/mysql/tables/llx_product_variant_values_lang.key.sql +++ /dev/null @@ -1,26 +0,0 @@ --- ============================================================================ --- Copyright (C) 2010 Regis Houssin <regis@dolibarr.fr> --- --- This program is free software; you can redistribute it and/or modify --- it under the terms of the GNU General Public License as published by --- the Free Software Foundation; either version 2 of the License, or --- (at your option) any later version. --- --- This program is distributed in the hope that it will be useful, --- but WITHOUT ANY WARRANTY; without even the implied warranty of --- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the --- GNU General Public License for more details. --- --- You should have received a copy of the GNU General Public License --- along with this program; if not, write to the Free Software --- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. --- --- $Id$ --- ============================================================================ - - -ALTER TABLE llx_product_variant_values_lang ADD UNIQUE INDEX uk_product_variant_values_lang (fk_product_variant_values, lang); - - -ALTER TABLE llx_product_variant_values_lang ADD CONSTRAINT fk_product_variant_values_lang_fk_product_variant_values FOREIGN KEY (fk_product_variant_values) REFERENCES llx_product_variant_values (rowid); - diff --git a/htdocs/install/mysql/tables/llx_product_variant_values_lang.sql b/htdocs/install/mysql/tables/llx_product_variant_values_lang.sql deleted file mode 100644 index 70b28a938b5..00000000000 --- a/htdocs/install/mysql/tables/llx_product_variant_values_lang.sql +++ /dev/null @@ -1,27 +0,0 @@ --- ============================================================================ --- Copyright (C) 2010 Regis Houssin <regis@dolibarr.fr> --- --- This program is free software; you can redistribute it and/or modify --- it under the terms of the GNU General Public License as published by --- the Free Software Foundation; either version 2 of the License, or --- (at your option) any later version. --- --- This program is distributed in the hope that it will be useful, --- but WITHOUT ANY WARRANTY; without even the implied warranty of --- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the --- GNU General Public License for more details. --- --- You should have received a copy of the GNU General Public License --- along with this program; if not, write to the Free Software --- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. --- --- $Id$ --- ============================================================================ - -create table llx_product_variant_values_lang -( - rowid integer AUTO_INCREMENT PRIMARY KEY, - fk_product_variant_values integer DEFAULT 0 NOT NULL, - lang varchar(5) NOT NULL, - label varchar(64) NOT NULL -)type=innodb; -- GitLab