Add missing unique key

This commit is contained in:
Laurent Destailleur 2021-11-07 12:38:44 +01:00
parent 11bb7428ce
commit 09d9d1ac42
3 changed files with 22 additions and 1 deletions

View File

@ -80,6 +80,8 @@ INSERT INTO llx_c_email_templates (entity, module, type_template, lang, private,
-- v15
ALTER TABLE llx_c_partnership_type ADD UNIQUE INDEX uk_c_partnership_type(entity, code);
ALTER TABLE llx_c_holiday_types CHANGE COLUMN newByMonth newbymonth double(8,5) DEFAULT 0 NOT NULL;
ALTER TABLE llx_product ADD COLUMN mandatory_period tinyint NULL DEFAULT 0;

View File

@ -0,0 +1,19 @@
-- ========================================================================
-- Copyright (C) 2021 Laurent Destailleur <eldy@users.sourceforge.net>
--
-- 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 3 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, see <https://www.gnu.org/licenses/>.
--
-- ========================================================================
ALTER TABLE llx_c_partnership_type ADD UNIQUE INDEX uk_c_partnership_type(entity, code);

View File

@ -30,6 +30,6 @@ create table llx_c_partnership_type
entity integer DEFAULT 1 NOT NULL,
code varchar(32) NOT NULL,
label varchar(64) NOT NULL,
active tinyint DEFAULT 1 NOT NULL
active tinyint DEFAULT 1 NOT NULL
)ENGINE=innodb;