|
|
|
@ -122,17 +122,17 @@ INSERT INTO `vn`.`currency`(`id`, `code`, `name`, `ratio`)
|
|
|
|
|
(3, 'GBP', 'Libra', 1),
|
|
|
|
|
(4, 'JPY', 'Yen Japones', 1);
|
|
|
|
|
|
|
|
|
|
INSERT INTO `vn`.`country`(`id`, `country`, `isUeeMember`, `code`, `currencyFk`, `ibanLength`, `continentFk`, `hasDailyInvoice`, `CEE`)
|
|
|
|
|
INSERT INTO `vn`.`country`(`id`, `country`, `isUeeMember`, `code`, `currencyFk`, `politicalCountryFk`, `ibanLength`, `continentFk`, `hasDailyInvoice`, `CEE`)
|
|
|
|
|
VALUES
|
|
|
|
|
(1, 'España', 1, 'ES', 1, 24, 4, 0, 1),
|
|
|
|
|
(2, 'Italia', 1, 'IT', 1, 27, 4, 0, 1),
|
|
|
|
|
(3, 'Alemania', 1, 'DE', 1, 22, 4, 0, 1),
|
|
|
|
|
(4, 'Rumania', 1, 'RO', 1, 24, 4, 0, 1),
|
|
|
|
|
(5, 'Holanda', 1, 'NL', 1, 18, 4, 0, 1),
|
|
|
|
|
(8, 'Portugal', 1, 'PT', 1, 27, 4, 0, 1),
|
|
|
|
|
(13,'Ecuador', 0, 'EC', 1, 24, 2, 1, 2),
|
|
|
|
|
(19,'Francia', 1, 'FR', 1, 27, 4, 0, 1),
|
|
|
|
|
(30,'Canarias', 1, 'IC', 1, 24, 4, 1, 2);
|
|
|
|
|
(1, 'España', 1, 'ES', 1, 1, 24, 4, 0, 1),
|
|
|
|
|
(2, 'Italia', 1, 'IT', 1, 2, 27, 4, 0, 1),
|
|
|
|
|
(3, 'Alemania', 1, 'DE', 1, 3, 22, 4, 0, 1),
|
|
|
|
|
(4, 'Rumania', 1, 'RO', 1, 4, 24, 4, 0, 1),
|
|
|
|
|
(5, 'Holanda', 1, 'NL', 1, 5, 18, 4, 0, 1),
|
|
|
|
|
(8, 'Portugal', 1, 'PT', 1, 8, 27, 4, 0, 1),
|
|
|
|
|
(13,'Ecuador', 0, 'EC', 1, 13, 24, 2, 1, 2),
|
|
|
|
|
(19,'Francia', 1, 'FR', 1, 19, 27, 4, 0, 1),
|
|
|
|
|
(30,'Canarias', 1, 'IC', 1, 1, 24, 4, 1, 2);
|
|
|
|
|
|
|
|
|
|
INSERT INTO `vn`.`warehouseAlias`(`id`, `name`)
|
|
|
|
|
VALUES
|
|
|
|
@ -148,10 +148,10 @@ INSERT INTO `vn`.`warehouse`(`id`, `name`, `code`, `isComparative`, `isInventory
|
|
|
|
|
(5, 'Warehouse Five', NULL, 1, 1, 1, 1, 0, 0, 0, 2, 1, 1),
|
|
|
|
|
(13, 'Inventory', NULL, 1, 1, 1, 0, 0, 0, 0, 2, 1, 0);
|
|
|
|
|
|
|
|
|
|
INSERT INTO `vn`.`sector`(`id`, `description`, `warehouseFk`, `isPreviousPreparedByPacking`, `code`, `pickingPlacement`, `path`)
|
|
|
|
|
INSERT INTO `vn`.`sector`(`id`, `description`, `warehouseFk`, `isPreviousPreparedByPacking`, `code`)
|
|
|
|
|
VALUES
|
|
|
|
|
(1, 'First sector', 1, 1, 'FIRST', 999, 999),
|
|
|
|
|
(2, 'Second sector', 2, 0, 'SECOND', 100, 150);
|
|
|
|
|
(1, 'First sector', 1, 1, 'FIRST'),
|
|
|
|
|
(2, 'Second sector', 2, 0, 'SECOND');
|
|
|
|
|
|
|
|
|
|
INSERT INTO `vn`.`parking` (`id`, `column`, `row`, `sectorFk`, `code`, `pickingOrder`)
|
|
|
|
|
VALUES
|
|
|
|
@ -175,14 +175,18 @@ INSERT INTO `vn`.`accountingType`(`id`, `description`, `receiptDescription`,`cod
|
|
|
|
|
(7, 'Leasing', NULL, NULL, NULL, 0),
|
|
|
|
|
(8, 'Compensations', 'Compensations', 'compensation', NULL, 0);
|
|
|
|
|
|
|
|
|
|
INSERT INTO `vn`.`bankEntity`(`id`, `countryFk`, `name`, `bic`)
|
|
|
|
|
VALUES
|
|
|
|
|
(128, 1, 'The Best Bank', 'BBKKESMMMMMM'),
|
|
|
|
|
(2100, 1, 'Caixa Bank', 'CAIXESBB');
|
|
|
|
|
|
|
|
|
|
INSERT INTO `vn`.`bank`(`id`, `bank`, `account`, `cash`, `entityFk`, `isActive`, `currencyFk`)
|
|
|
|
|
VALUES
|
|
|
|
|
(1, 'Pay on receipt', '5720000001', 3, 0, 1, 1),
|
|
|
|
|
(2, 'Cash', '5700000001', 2, 0, 1, 1),
|
|
|
|
|
(3, 'Compensation', '4000000000', 8, 0, 1, 1),
|
|
|
|
|
(4, 'Transfers', '4000000001', 1, 0, 1, 1),
|
|
|
|
|
(3117, 'Caixa Rural d''Algemesi', '5720000000', 8, 3117, 1, 1);
|
|
|
|
|
|
|
|
|
|
(1, 'Pay on receipt', '5720000001', 3, 128, 1, 1),
|
|
|
|
|
(2, 'Cash', '5700000001', 2, 128, 1, 1),
|
|
|
|
|
(3, 'Compensation', '4000000000', 8, 128, 1, 1),
|
|
|
|
|
(4, 'Transfers', '4000000001', 1, 128, 1, 1),
|
|
|
|
|
(3117, 'Caixa Rural d''Algemesi', '5720000000', 8, 2100, 1, 1);
|
|
|
|
|
|
|
|
|
|
INSERT INTO `vn`.`deliveryMethod`(`id`, `code`, `description`)
|
|
|
|
|
VALUES
|
|
|
|
@ -191,18 +195,18 @@ INSERT INTO `vn`.`deliveryMethod`(`id`, `code`, `description`)
|
|
|
|
|
(3, 'PICKUP', 'Recogida'),
|
|
|
|
|
(4, 'OTHER', 'Otros');
|
|
|
|
|
|
|
|
|
|
INSERT INTO `vn`.`agency`(`id`, `name`, `warehouseFk`, `isVolumetric`, `bankFk`, `warehouseAliasFk`)
|
|
|
|
|
INSERT INTO `vn`.`agency`(`id`, `name`, `warehouseFk`, `bankFk__`, `warehouseAliasFk`)
|
|
|
|
|
VALUES
|
|
|
|
|
(1, 'inhouse pickup' , 1, 0, 1, 1),
|
|
|
|
|
(2, 'Super-Man delivery' , 1, 0, 1, 1),
|
|
|
|
|
(3, 'Teleportation device' , 1, 0, 1, 1),
|
|
|
|
|
(4, 'Entanglement' , 1, 0, 1, 1),
|
|
|
|
|
(5, 'Quantum break device' , 1, 0, 1, 1),
|
|
|
|
|
(6, 'Walking' , 1, 0, 1, 1),
|
|
|
|
|
(7, 'Gotham247' , 1, 0, 1, 1),
|
|
|
|
|
(8, 'Gotham247Expensive' , 1, 0, 1, 1),
|
|
|
|
|
(9, 'Refund' , 1, 0, 1, 1),
|
|
|
|
|
(10, 'Other agency' , 1, 0, 1, 1);
|
|
|
|
|
(1, 'inhouse pickup' , 1, 1, 1),
|
|
|
|
|
(2, 'Super-Man delivery' , 1, 1, 1),
|
|
|
|
|
(3, 'Teleportation device' , 1, 1, 1),
|
|
|
|
|
(4, 'Entanglement' , 1, 1, 1),
|
|
|
|
|
(5, 'Quantum break device' , 1, 1, 1),
|
|
|
|
|
(6, 'Walking' , 1, 1, 1),
|
|
|
|
|
(7, 'Gotham247' , 1, 1, 1),
|
|
|
|
|
(8, 'Gotham247Expensive' , 1, 1, 1),
|
|
|
|
|
(9, 'Refund' , 1, 1, 1),
|
|
|
|
|
(10, 'Other agency' , 1, 1, 1);
|
|
|
|
|
|
|
|
|
|
UPDATE `vn`.`agencyMode` SET `id` = 1 WHERE `name` = 'inhouse pickup';
|
|
|
|
|
UPDATE `vn`.`agencyMode` SET `id` = 2 WHERE `name` = 'Super-Man delivery';
|
|
|
|
@ -471,10 +475,18 @@ INSERT INTO `vn`.`companyGroup`(`id`, `code`)
|
|
|
|
|
(1, 'wayneIndustries'),
|
|
|
|
|
(2, 'verdnatura');
|
|
|
|
|
|
|
|
|
|
INSERT INTO `vn`.`bankEntity`(`id`, `countryFk`, `name`, `bic`)
|
|
|
|
|
INSERT INTO `vn`.`supplierActivity`(`code`, `name`)
|
|
|
|
|
VALUES
|
|
|
|
|
(128, 1, 'The Best Bank', 'BBKKESMMMMMM'),
|
|
|
|
|
(2100, 1, 'Caixa Bank', 'CAIXESBB');
|
|
|
|
|
('animals', 'Food and complements for pets'),
|
|
|
|
|
('complements', 'Other complements'),
|
|
|
|
|
('flowerPlants', 'Wholesale of flowers and plants'),
|
|
|
|
|
('vegetablesFruits', 'Fruit and vegetable trade');
|
|
|
|
|
|
|
|
|
|
INSERT INTO `vn`.`supplier`(`id`, `name`, `nickname`,`account`,`countryFk`,`nif`, `commission`, `created`, `isActive`, `street`, `city`, `provinceFk`, `postCode`, `payMethodFk`, `payDemFk`, `payDay`, `taxTypeSageFk`, `withholdingSageFk`, `transactionTypeSageFk`, `workerFk`, `supplierActivityFk`, `isPayMethodChecked`, `healthRegister`)
|
|
|
|
|
VALUES
|
|
|
|
|
(1, 'Plants SL', 'Plants nick', 4100000001, 1, '06089160W', 0, util.VN_CURDATE(), 1, 'supplier address 1', 'PONTEVEDRA', 1, 15214, 1, 1, 15, 4, 1, 1, 18, 'flowerPlants', 1, '400664487V'),
|
|
|
|
|
(2, 'Farmer King', 'The farmer', 4000020002, 1, '87945234L', 0, util.VN_CURDATE(), 1, 'supplier address 2', 'GOTHAM', 2, 43022, 1, 2, 10, 93, 2, 8, 18, 'animals', 1, '400664487V'),
|
|
|
|
|
(442, 'Verdnatura Levante SL', 'Verdnatura', 5115000442, 1, '06815934E', 0, util.VN_CURDATE(), 1, 'supplier address 3', 'GOTHAM', 1, 43022, 1, 2, 15, 6, 9, 3, 18, 'complements', 1, '400664487V');
|
|
|
|
|
|
|
|
|
|
INSERT INTO `vn`.`supplierAccount`(`id`, `supplierFk`, `iban`, `bankEntityFk`)
|
|
|
|
|
VALUES
|
|
|
|
@ -875,18 +887,18 @@ INSERT INTO `vn`.`expeditionStateType`(`id`, `description`, `code`)
|
|
|
|
|
(3, 'Perdida', 'LOST');
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
INSERT INTO `vn`.`expedition`(`id`, `agencyModeFk`, `ticketFk`, `isBox`, `created`, `itemFk`, `counter`, `checked`, `workerFk`, `externalId`, `packagingFk`, `stateTypeFk`)
|
|
|
|
|
INSERT INTO `vn`.`expedition`(`id`, `agencyModeFk`, `ticketFk`, `isBox`, `created`, `itemFk`, `counter`, `workerFk`, `externalId`, `packagingFk`, `stateTypeFk`)
|
|
|
|
|
VALUES
|
|
|
|
|
(1, 1, 1, 71, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), 15, 1, 1, 18, 'UR9000006041', 94, 1),
|
|
|
|
|
(2, 1, 1, 71, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), 16, 2, 1, 18, 'UR9000006041', 94, 1),
|
|
|
|
|
(3, 1, 1, 71, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), NULL, 3, 1, 18, 'UR9000006041', 94, 2),
|
|
|
|
|
(4, 1, 1, 71, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), NULL, 4, 1, 18, 'UR9000006041', 94, 2),
|
|
|
|
|
(5, 1, 2, 71, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), NULL, 1, 1, 18, NULL, 94, 3),
|
|
|
|
|
(6, 7, 3, 71, DATE_ADD(util.VN_CURDATE(), INTERVAL -2 MONTH), NULL, 1, 1, 18, NULL, 94, 3),
|
|
|
|
|
(7, 2, 4, 71, DATE_ADD(util.VN_CURDATE(), INTERVAL -3 MONTH), NULL, 1, 1, 18, NULL, 94, NULL),
|
|
|
|
|
(8, 3, 5, 71, DATE_ADD(util.VN_CURDATE(), INTERVAL -4 MONTH), NULL, 1, 1, 18, NULL, 94, 1),
|
|
|
|
|
(9, 3, 6, 71, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), NULL, 1, 1, 18, NULL, 94, 2),
|
|
|
|
|
(10, 7, 7, 71, NOW(), NULL, 1, 1, 18, NULL, 94, 3);
|
|
|
|
|
(1, 1, 1, 71, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), 15, 1, 18, 'UR9000006041', 94, 1),
|
|
|
|
|
(2, 1, 1, 71, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), 16, 2, 18, 'UR9000006041', 94, 1),
|
|
|
|
|
(3, 1, 1, 71, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), NULL, 3, 18, 'UR9000006041', 94, 2),
|
|
|
|
|
(4, 1, 1, 71, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), NULL, 4, 18, 'UR9000006041', 94, 2),
|
|
|
|
|
(5, 1, 2, 71, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), NULL, 1, 18, NULL, 94, 3),
|
|
|
|
|
(6, 7, 3, 71, DATE_ADD(util.VN_CURDATE(), INTERVAL -2 MONTH), NULL, 1, 18, NULL, 94, 3),
|
|
|
|
|
(7, 2, 4, 71, DATE_ADD(util.VN_CURDATE(), INTERVAL -3 MONTH), NULL, 1, 18, NULL, 94, NULL),
|
|
|
|
|
(8, 3, 5, 71, DATE_ADD(util.VN_CURDATE(), INTERVAL -4 MONTH), NULL, 1, 18, NULL, 94, 1),
|
|
|
|
|
(9, 3, 6, 71, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), NULL, 1, 18, NULL, 94, 2),
|
|
|
|
|
(10, 7, 7, 71, NOW(), NULL, 1, 18, NULL, 94, 3);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
INSERT INTO `vn`.`expeditionState`(`id`, `created`, `expeditionFk`, `typeFk`, `userFk`)
|
|
|
|
@ -1112,13 +1124,6 @@ INSERT INTO `vn`.`itemBarcode`(`id`, `itemFk`, `code`)
|
|
|
|
|
(3, 1, 3333333333),
|
|
|
|
|
(4, 2, 4444444444);
|
|
|
|
|
|
|
|
|
|
INSERT INTO `vn`.`itemPlacement`(`id`, `itemFk`, `warehouseFk`, `code`)
|
|
|
|
|
VALUES
|
|
|
|
|
(1, 1, 1, 'A11'),
|
|
|
|
|
(2, 1, 2, 'A22'),
|
|
|
|
|
(3, 1, 3, 'A33'),
|
|
|
|
|
(4, 2, 1, 'A44');
|
|
|
|
|
|
|
|
|
|
INSERT INTO `vn`.`train`(`id`, `name`)
|
|
|
|
|
VALUES
|
|
|
|
|
(1, 'Train1'),
|
|
|
|
@ -1284,9 +1289,9 @@ INSERT INTO `vn`.`itemTypeTag`(`id`, `itemTypeFk`, `tagFk`, `priority`)
|
|
|
|
|
VALUES
|
|
|
|
|
(1, 1, 1, 0),
|
|
|
|
|
(2, 2, 2, 0),
|
|
|
|
|
(3, 3, 3, 1),
|
|
|
|
|
(4, 1, 4, 1),
|
|
|
|
|
(5, 1, 5, 1);
|
|
|
|
|
(3, 3, 3, 0),
|
|
|
|
|
(4, 1, 4, 4),
|
|
|
|
|
(5, 1, 5, 5);
|
|
|
|
|
|
|
|
|
|
CALL `vn`.`itemRefreshTags`(NULL);
|
|
|
|
|
|
|
|
|
@ -1309,13 +1314,6 @@ INSERT INTO `vn`.`annualAverageInvoiced`(`clientFk`, `invoiced`)
|
|
|
|
|
(1104, 500),
|
|
|
|
|
(1105, 5000);
|
|
|
|
|
|
|
|
|
|
INSERT INTO `vn`.`supplierActivity`(`code`, `name`)
|
|
|
|
|
VALUES
|
|
|
|
|
('animals', 'Food and complements for pets'),
|
|
|
|
|
('complements', 'Other complements'),
|
|
|
|
|
('flowerPlants', 'Wholesale of flowers and plants'),
|
|
|
|
|
('vegetablesFruits', 'Fruit and vegetable trade');
|
|
|
|
|
|
|
|
|
|
INSERT INTO `vn`.`supplierAddress`(`id`, `supplierFk`, `nickname`, `street`, `provinceFk`, `postalCode`, `city`, `phone`, `mobile`)
|
|
|
|
|
VALUES
|
|
|
|
|
(1, 1, 'Ace Chemicals', 'The Midtown', 1, '46000', 'Gotham', '111111111', '222222222'),
|
|
|
|
@ -1325,12 +1323,6 @@ INSERT INTO `vn`.`supplierAddress`(`id`, `supplierFk`, `nickname`, `street`, `pr
|
|
|
|
|
(5, 442, 'GCR building', 'Bristol district', 1, '46000', 'Gotham', '111111111', '222222222'),
|
|
|
|
|
(6, 442, 'The Gotham Tonight building', 'Bristol district', 1, '46000', 'Gotham', '111111111', '222222222');
|
|
|
|
|
|
|
|
|
|
INSERT INTO `vn`.`supplier`(`id`, `name`, `nickname`,`account`,`countryFk`,`nif`, `commission`, `created`, `isActive`, `street`, `city`, `provinceFk`, `postCode`, `payMethodFk`, `payDemFk`, `payDay`, `taxTypeSageFk`, `withholdingSageFk`, `transactionTypeSageFk`, `workerFk`, `supplierActivityFk`, `isPayMethodChecked`, `healthRegister`)
|
|
|
|
|
VALUES
|
|
|
|
|
(1, 'Plants SL', 'Plants nick', 4100000001, 1, '06089160W', 0, util.VN_CURDATE(), 1, 'supplier address 1', 'PONTEVEDRA', 1, 15214, 1, 1, 15, 4, 1, 1, 18, 'flowerPlants', 1, '400664487V'),
|
|
|
|
|
(2, 'Farmer King', 'The farmer', 4000020002, 1, '87945234L', 0, util.VN_CURDATE(), 1, 'supplier address 2', 'GOTHAM', 2, 43022, 1, 2, 10, 93, 2, 8, 18, 'animals', 1, '400664487V'),
|
|
|
|
|
(442, 'Verdnatura Levante SL', 'Verdnatura', 5115000442, 1, '06815934E', 0, util.VN_CURDATE(), 1, 'supplier address 3', 'GOTHAM', 1, 43022, 1, 2, 15, 6, 9, 3, 18, 'complements', 1, '400664487V');
|
|
|
|
|
|
|
|
|
|
INSERT INTO `vn`.`supplierContact`(`id`, `supplierFk`, `phone`, `mobile`, `email`, `observation`, `name`)
|
|
|
|
|
VALUES
|
|
|
|
|
(1, 1, 123121212, 654789123, 'supplier1@email.es', 'observation1', 'the boss'),
|
|
|
|
@ -1928,11 +1920,6 @@ INSERT INTO `postgresql`.`profile_media`(`profile_media_id`, `profile_id`, `medi
|
|
|
|
|
(1, 1106, 1),
|
|
|
|
|
(2, 1107, 2);
|
|
|
|
|
|
|
|
|
|
INSERT INTO `vn`.`workCenter` (`id`, `name`, `warehouseFk`)
|
|
|
|
|
VALUES
|
|
|
|
|
('1', 'Gotham', '1'),
|
|
|
|
|
('5', 'Madrid', '5');
|
|
|
|
|
|
|
|
|
|
INSERT INTO `vn`.`workCenterHoliday` (`workCenterFk`, `days`, `year`)
|
|
|
|
|
VALUES
|
|
|
|
|
('1', '27.5', YEAR(util.VN_CURDATE())),
|
|
|
|
@ -1940,7 +1927,7 @@ INSERT INTO `vn`.`workCenterHoliday` (`workCenterFk`, `days`, `year`)
|
|
|
|
|
('1', '24.5', YEAR(DATE_ADD(util.VN_CURDATE(), INTERVAL -1 YEAR))),
|
|
|
|
|
('5', '23', YEAR(DATE_ADD(util.VN_CURDATE(), INTERVAL -1 YEAR)));
|
|
|
|
|
|
|
|
|
|
INSERT INTO `postgresql`.`calendar_state` (`calendar_state_id`, `type`, `rgb`, `code`, `holidayEntitlementRate`, `discountRate`)
|
|
|
|
|
INSERT INTO `vn`.`absenceType` (`id`, `name`, `rgb`, `code`, `holidayEntitlementRate`, `discountRate`)
|
|
|
|
|
VALUES
|
|
|
|
|
(1, 'Holidays', '#FF4444', 'holiday', 0, 0),
|
|
|
|
|
(2, 'Leave of absence', '#C71585', 'absence', 0, 1),
|
|
|
|
|