diff --git a/db/versions/10836-limeCordyline/03-gastos_resumen.sql b/db/versions/10836-limeCordyline/03-gastos_resumen.sql deleted file mode 100644 index bfec006fa..000000000 --- a/db/versions/10836-limeCordyline/03-gastos_resumen.sql +++ /dev/null @@ -1,17 +0,0 @@ -ALTER TABLE IF EXISTS `vn2008`.`gastos_resumen` RENAME `vn`.`expenseSummary`; - -ALTER TABLE IF EXISTS `vn`.`expenseSummary` -CHANGE COLUMN IF EXISTS `Id_Gasto` `expenseFk` varchar(10) NOT NULL, -CHANGE COLUMN IF EXISTS `importe` `amount` decimal(10,2) DEFAULT NULL, -CHANGE COLUMN IF EXISTS `empresa_id` `companyFk` int(11) NOT NULL; - -ALTER TABLE IF EXISTS vn.expenseSummary COLLATE=utf8mb3_general_ci; - -ALTER TABLE IF EXISTS vn.expenseSummary MODIFY COLUMN expenseFk varchar(10) CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci NOT NULL; - -ALTER TABLE IF EXISTS vn.expenseSummary ADD CONSTRAINT expenseSummary_expense_FK FOREIGN KEY (expenseFk) REFERENCES vn.expense(id) ON DELETE CASCADE ON UPDATE CASCADE; - -ALTER TABLE IF EXISTS vn.expenseSummary MODIFY COLUMN companyFk int(10) unsigned NOT NULL; - -ALTER TABLE IF EXISTS vn.expenseSummary ADD CONSTRAINT expenseSummary_company_FK FOREIGN KEY (companyFk) REFERENCES vn.company(id) ON DELETE CASCADE ON UPDATE CASCADE; - diff --git a/db/versions/10836-limeCordyline/01-financialProductType.sql b/db/versions/10896-salmonOrchid/01-financialProductType.sql similarity index 100% rename from db/versions/10836-limeCordyline/01-financialProductType.sql rename to db/versions/10896-salmonOrchid/01-financialProductType.sql diff --git a/db/versions/10836-limeCordyline/02-flight.sql b/db/versions/10896-salmonOrchid/02-flight.sql similarity index 100% rename from db/versions/10836-limeCordyline/02-flight.sql rename to db/versions/10896-salmonOrchid/02-flight.sql diff --git a/db/versions/10896-salmonOrchid/03-gastos_resumen.sql b/db/versions/10896-salmonOrchid/03-gastos_resumen.sql new file mode 100644 index 000000000..ea14364d5 --- /dev/null +++ b/db/versions/10896-salmonOrchid/03-gastos_resumen.sql @@ -0,0 +1,18 @@ +ALTER TABLE IF EXISTS vn2008.gastos_resumen DROP FOREIGN KEY IF EXISTS gastos_resumen_expense_FK; +ALTER TABLE IF EXISTS `vn2008`.`gastos_resumen` RENAME `vn`.`expenseSummary`; + +ALTER TABLE IF EXISTS `vn`.`expenseSummary` +CHANGE COLUMN IF EXISTS `Id_Gasto` `expenseFk` varchar(10) NOT NULL, +CHANGE COLUMN IF EXISTS `importe` `amount` decimal(10,2) DEFAULT NULL, +CHANGE COLUMN IF EXISTS `empresa_id` `companyFk` int(11) NOT NULL; + +ALTER TABLE IF EXISTS vn.expenseSummary COLLATE=utf8mb3_general_ci; + +ALTER TABLE IF EXISTS vn.expenseSummary MODIFY COLUMN IF EXISTS expenseFk varchar(10) CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci NOT NULL; + +ALTER TABLE IF EXISTS vn.expenseSummary ADD CONSTRAINT expenseSummary_expense_FK FOREIGN KEY IF NOT EXISTS (expenseFk) REFERENCES vn.expense(id) ON DELETE CASCADE ON UPDATE CASCADE; + +ALTER TABLE IF EXISTS vn.expenseSummary MODIFY COLUMN IF EXISTS companyFk int(10) unsigned NOT NULL; + +ALTER TABLE IF EXISTS vn.expenseSummary ADD CONSTRAINT expenseSummary_company_FK FOREIGN KEY IF NOT EXISTS (companyFk) REFERENCES vn.company(id) ON DELETE CASCADE ON UPDATE CASCADE; + diff --git a/db/versions/10836-limeCordyline/04-integra2.sql b/db/versions/10896-salmonOrchid/04-integra2.sql similarity index 100% rename from db/versions/10836-limeCordyline/04-integra2.sql rename to db/versions/10896-salmonOrchid/04-integra2.sql diff --git a/db/versions/10836-limeCordyline/05-integra2_province.sql b/db/versions/10896-salmonOrchid/05-integra2_province.sql similarity index 100% rename from db/versions/10836-limeCordyline/05-integra2_province.sql rename to db/versions/10896-salmonOrchid/05-integra2_province.sql diff --git a/db/versions/10836-limeCordyline/06-intervalos__delete.sql b/db/versions/10896-salmonOrchid/06-intervalos__delete.sql similarity index 100% rename from db/versions/10836-limeCordyline/06-intervalos__delete.sql rename to db/versions/10896-salmonOrchid/06-intervalos__delete.sql diff --git a/db/versions/10836-limeCordyline/10-mail_templates__delete.sql b/db/versions/10896-salmonOrchid/10-mail_templates__delete.sql similarity index 100% rename from db/versions/10836-limeCordyline/10-mail_templates__delete.sql rename to db/versions/10896-salmonOrchid/10-mail_templates__delete.sql diff --git a/db/versions/10836-limeCordyline/12-ticket_location__delete.sql b/db/versions/10896-salmonOrchid/12-ticket_location__delete.sql similarity index 100% rename from db/versions/10836-limeCordyline/12-ticket_location__delete.sql rename to db/versions/10896-salmonOrchid/12-ticket_location__delete.sql diff --git a/db/versions/10836-limeCordyline/13-turn__delete.sql b/db/versions/10896-salmonOrchid/13-turn__delete.sql similarity index 100% rename from db/versions/10836-limeCordyline/13-turn__delete.sql rename to db/versions/10896-salmonOrchid/13-turn__delete.sql diff --git a/db/versions/10836-limeCordyline/14-movement_label.sql b/db/versions/10896-salmonOrchid/14-movement_label.sql similarity index 100% rename from db/versions/10836-limeCordyline/14-movement_label.sql rename to db/versions/10896-salmonOrchid/14-movement_label.sql diff --git a/db/versions/10836-limeCordyline/15-pago_sdc.sql b/db/versions/10896-salmonOrchid/15-pago_sdc.sql similarity index 100% rename from db/versions/10836-limeCordyline/15-pago_sdc.sql rename to db/versions/10896-salmonOrchid/15-pago_sdc.sql diff --git a/db/versions/10836-limeCordyline/25-warehouse_pickup.sql b/db/versions/10896-salmonOrchid/25-warehouse_pickup.sql similarity index 100% rename from db/versions/10836-limeCordyline/25-warehouse_pickup.sql rename to db/versions/10896-salmonOrchid/25-warehouse_pickup.sql diff --git a/db/versions/10836-limeCordyline/29-kk.sql b/db/versions/10896-salmonOrchid/29-kk.sql similarity index 100% rename from db/versions/10836-limeCordyline/29-kk.sql rename to db/versions/10896-salmonOrchid/29-kk.sql diff --git a/db/versions/10836-limeCordyline/30-permissions.sql b/db/versions/10896-salmonOrchid/30-permissions.sql similarity index 100% rename from db/versions/10836-limeCordyline/30-permissions.sql rename to db/versions/10896-salmonOrchid/30-permissions.sql