refactor fixtures and delete outdated files

This commit is contained in:
Bernat 2018-04-16 15:16:30 +02:00
parent bfad7a9a83
commit ae9c545796
20 changed files with 75306 additions and 75887 deletions

File diff suppressed because it is too large Load Diff

View File

@ -144,12 +144,12 @@ INSERT INTO `vn`.`client`(`id`,`name`,`fi`,`socialName`,`contact`,`street`,`city
(102, 'Petter Parker', '87945234L', 'Spider-Man', 'Aunt May', '20 Ingram Street', 'Silla', 46460, 1111111111, 222222222, 333333333, 1, 'PetterParker@verdnatura.es', NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1,NULL, 10, 5,CURDATE(), 1, 5, 1, 1, 1,'0000-00-00', 1, NULL, 1, 1, 0, 1, NULL, 0, 0, 18, 0, 1),
(103, 'Clark Kent', '06815934E', 'Super-Man', 'lois lane', '344 Clinton Street', 'Silla', 46460, 1111111111, 222222222, 333333333, 1, 'ClarkKent@verdnatura.es', NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1,NULL, 10, 5,CURDATE(), 1, 5, 1, 1, 1,'0000-00-00', 1, NULL, 1, 1, 1, 1, NULL, 0, 0, 18, 0, 1),
(104, 'Tony Stark', '06089160W', 'Iron-Man', 'Pepper Potts', '10880 Malibu Point', 'Silla', 46460, 1111111111, 222222222, 333333333, 1, 'TonyStark@verdnatura.es', NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1,NULL, 10, 5,CURDATE(), 1, 5, 1, 1, 1,'0000-00-00', 1, NULL, 1, 1, 1, 1, NULL, 0, 0, 18, 0, 1),
(105, 'Max Eisenhardt', '39182496H', 'Magneto', 'Rogue', 'Unknown Whereabouts', 'Silla', 46460, 1111111111, 222222222, 333333333, 1, 'MaxEisenhardt@verdnatura.es', NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1,NULL, 10, 5,CURDATE(), 1, 5, 1, 1, 1,'0000-00-00', 1, NULL, 1, 1, 1, 1, NULL, 0, 0, 18, 0, 1),
(105, 'Max Eisenhardt', '39182496H', 'Magneto', 'Rogue', 'Unknown Whereabouts', 'Silla', 46460, 1111111111, 222222222, 333333333, 1, 'MaxEisenhardt@verdnatura.es', NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1,NULL, 10, 5,CURDATE(), 1, 5, 1, 1, 1,'0000-00-00', 1, NULL, 1, 1, 1, 1, NULL, 0, 0, NULL, 0, 1),
(106, 'DavidCharlesHaller', '53136686Q', 'Legion', 'Charles Xavier', 'Evil hideout', 'Silla', 46460, 1111111111, 222222222, 333333333, 1, 'DavidCharlesHaller@verdnatura.es', NULL, 0, 1234567890, 0, 1, 1, 300, 1, 0,NULL, 10, 5,CURDATE(), 1, 5, 1, 1, 1,'0000-00-00', 1, NULL, 1, 1, 1, 1, NULL, 0, 0, 19, 0, 1),
(107, 'Hank Pym', '09854837G', 'Ant-Man', 'Hawk', 'Anthill', 'Silla', 46460, 1111111111, 222222222, 333333333, 1, 'HankPym@verdnatura.es', NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1,NULL, 10, 5,CURDATE(), 1, 5, 1, 1, 1,'0000-00-00', 1, NULL, 1, 1, 1, 1, NULL, 0, 0, 19, 0, 1),
(108, 'Charles Xavier', '22641921P', 'Professor X', 'Beast', '3800 Victory Pkwy, Cincinnati, OH 45207, USA', 'Silla', 46460, 1111111111, 222222222, 333333333, 1, 'CharlesXavier@verdnatura.es', NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1,NULL, 10, 5,CURDATE(), 1, 5, 1, 1, 1,'0000-00-00', 1, NULL, 1, 1, 1, 1, NULL, 0, 0, 19, 0, 1),
(109, 'Bruce Banner', '16104829E', 'Hulk', 'Black widow', 'Somewhere in New York', 'Silla', 46460, 1111111111, 222222222, 333333333, 1, 'BruceBanner@verdnatura.es', NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1,NULL, 10, 5,CURDATE(), 1, 5, 1, 1, 1,'0000-00-00', 1, NULL, 1, 1, 0, 1, NULL, 0, 0, 19, 0, 1),
(110, 'Jessica Jones', '58282869H', 'Jessica Jones', 'Luke Cage', 'NYCC 2015 Poster', 'Silla', 46460, 1111111111, 222222222, 333333333, 1, 'JessicaJones@verdnatura.es', NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1,NULL, 10, 5,CURDATE(), 1, 5, 1, 1, 1,'0000-00-00', 1, NULL, 1, 1, 0, 1, NULL, 0, 0, 19, 0, 1);
(110, 'Jessica Jones', '58282869H', 'Jessica Jones', 'Luke Cage', 'NYCC 2015 Poster', 'Silla', 46460, 1111111111, 222222222, 333333333, 1, 'JessicaJones@verdnatura.es', NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1,NULL, 10, 5,CURDATE(), 1, 5, 1, 1, 1,'0000-00-00', 1, NULL, 1, 1, 0, 1, NULL, 0, 0, NULL, 0, 1);
INSERT INTO `vn`.`address`(`id`, `nickname`, `street`, `city`, `postalCode`, `provinceFk`, `phone`, `mobile`, `isActive`, `isDefaultAddress`, `clientFk`, `agencyModeFk`, `longitude`, `latitude`, `isEqualizated`)
VALUES
@ -274,18 +274,35 @@ INSERT INTO `vn2008`.`empresa_grupo`(`empresa_grupo_id`, `grupo`)
( 791, 'FTH', NULL, 30, NULL, 4),
( 1381, 'ORN', NULL, 30, NULL,5);
INSERT INTO `vn`.`ticket`(`id`, `agencyModeFk`,`warehouseFk`,`routeFk`, `shipped`, `clientFk`,`nickname`, `addressFk`)
INSERT INTO `vn`.`invoiceOut`(`id`, `ref`, `serial`, `amount`, `clientFk`, `created`, `companyFk`, `dued`, `booked`, `bankFk`, `pdf`)
VALUES
(1, 1, 1, NULL, CURDATE(), 101, 'Batman', 101),
(2, 1, 1, NULL, CURDATE(), 101, 'Spider-Man', 102),
(3, 2, 2, NULL, CURDATE(), 102, 'Super-Man', 103),
(4, 2, 2, NULL, CURDATE(), 102, 'Iron-Man', 104),
(5, 3, 3, NULL, CURDATE(), 103, 'Magneto', 105),
(6, 3, 3, NULL, CURDATE(), 103, 'Legion', 106),
(7, 4, 4, NULL, CURDATE(), 104, 'Ant-Man', 107),
(8, 4, 4, NULL, CURDATE(), 104, 'Professor X', 108),
(9, 5, 5, NULL, CURDATE(), 105, 'Hulk', 109),
(10, 6, 5, NULL, CURDATE(), 105, 'Jessica Jones', 110);
( 1, 'T1111111' , 'T', 500 , 101, CURDATE(), 442, CURDATE(), CURDATE(), 8, 1),
( 2, 'V2222222' , 'V', 350.50 , 102, CURDATE(), 442, CURDATE(), CURDATE(), 8, 1),
( 3, 'E3333333' , 'E', 90.30 , 103, CURDATE(), 442, CURDATE(), CURDATE(), 8, 1);
INSERT INTO `vn`.`ticket`(`id`, `agencyModeFk`,`warehouseFk`,`routeFk`, `shipped`, `clientFk`,`nickname`, `addressFk`, `refFk`)
VALUES
(1, 1, 1, 1, DATE_ADD(CURDATE(), INTERVAL -15 DAY), 101, 'Batman', 101, NULL),
(2, 1, 1, 1, DATE_ADD(CURDATE(), INTERVAL -10 DAY), 101, 'Spider-Man', 102, NULL),
(3, 2, 2, 2, DATE_ADD(CURDATE(), INTERVAL -5 DAY), 102, 'Super-Man', 103, NULL),
(4, 2, 2, 2, DATE_ADD(CURDATE(), INTERVAL -4 DAY), 102, 'Iron-Man', 104, NULL),
(5, 3, 3, 3, DATE_ADD(CURDATE(), INTERVAL -3 DAY), 103, 'Magneto', 105, NULL),
(6, 3, 3, 4, DATE_ADD(CURDATE(), INTERVAL -2 DAY), 103, 'Legion', 106, NULL),
(7, 4, 4, 4, DATE_ADD(CURDATE(), INTERVAL -1 DAY), 104, 'Ant-Man', 107, NULL),
(8, 4, 4, 4, DATE_ADD(CURDATE(), INTERVAL -1 MONTH), 104, 'Professor X', 108, NULL),
(9, 5, 5, 4, DATE_ADD(CURDATE(), INTERVAL -2 MONTH), 105, 'Hulk', 109, NULL),
(10, 6, 5, 5, DATE_ADD(CURDATE(), INTERVAL -3 MONTH), 105, 'Jessica Jones', 110, NULL),
(11, 1, 1, 1, DATE_ADD(CURDATE(), INTERVAL +1 DAY), 101, 'Batman', 101, NULL),
(12, 1, 1, 1, DATE_ADD(CURDATE(), INTERVAL +1 DAY), 101, 'Spider-Man', 102, NULL),
(13, 2, 2, 2, CURDATE(), 102, 'Super-Man', 103, NULL),
(14, 2, 2, 2, CURDATE(), 102, 'Iron-Man', 104, NULL),
(15, 3, 3, 3, CURDATE(), 103, 'Magneto', 105, NULL),
(16, 3, 3, 4, CURDATE(), 103, 'Legion', 106, NULL),
(17, 4, 4, 4, CURDATE(), 104, 'Ant-Man', 107, NULL),
(18, 4, 4, 4, CURDATE(), 104, 'Professor X', 108, NULL),
(19, 5, 5, 4, CURDATE(), 105, 'Hulk', 109, NULL),
(20, 5, 5, 4, CURDATE(), 105, 'Hulk', 109, NULL),
(21, 5, 5, 4, CURDATE(), 105, 'Hulk', 109, NULL);
INSERT INTO `vn`.`ticketObservation`(`id`, `ticketFk`, `observationTypeFk`, `description`)
VALUES
@ -299,12 +316,12 @@ INSERT INTO `vn`.`ticketTracking`(`id`, `ticketFk`, `stateFk`, `workerFk`, `crea
(2, 2, 2, 5, CURDATE()),
(3, 3, 3, 5, CURDATE()),
(4, 4, 1, 5, CURDATE()),
(5, 5, 2, 5, CURDATE()),
(6, 6, 3, 5, CURDATE()),
(7, 7, 1, 5, CURDATE()),
(8, 8, 2, 5, CURDATE()),
(9, 9, 3, 5, CURDATE()),
(10, 10, 1, 5, CURDATE());
(5, 5, 2, 18, CURDATE()),
(6, 6, 3, 18, CURDATE()),
(7, 7, 1, 18, CURDATE()),
(8, 8, 2, 19, CURDATE()),
(9, 9, 3, 19, CURDATE()),
(10, 10, 1, 19, CURDATE());
INSERT INTO `vn`.`vehicle`(`id`, `numberPlate`, `tradeMark`, `model`, `companyFk`, `warehouseFk`, `description`, `m3`, `isActive`)
VALUES
@ -447,7 +464,7 @@ INSERT INTO `vn`.`saleComponent`(`saleFk`, `componentFk`, `value`)
( 1, 17, 4.5),
( 1, 21, 5),
( 1, 23, 6.5),
( 1, 28, 3),
( 1, 28, 1),
( 2, 28, 1 );
INSERT INTO `vn`.`itemBarcode`(`id`, `itemFk`, `code`)
@ -504,12 +521,6 @@ INSERT INTO `vn`.`itemLog` (`id`, `originFk`, `userFk`, `action`, `description`)
VALUES
('1', '1', '1', 'insert', 'We made a change!');
INSERT INTO `vn`.`invoiceOut`(`id`, `ref`, `serial`, `amount`, `clientFk`, `created`, `companyFk`, `dued`, `booked`, `bankFk`, `pdf`)
VALUES
( 1, 'T1111111' , 'T', 500 , 101, CURDATE(), 442, CURDATE(), CURDATE(), 8, 1),
( 2, 'V2222222' , 'V', 350.50 , 102, CURDATE(), 442, CURDATE(), CURDATE(), 8, 1),
( 3, 'E3333333' , 'E', 90.30 , 103, CURDATE(), 442, CURDATE(), CURDATE(), 8, 1);
INSERT INTO `vn`.`recovery`(`id`, `clientFk`, `started`, `finished`, `amount`, `period`)
VALUES
( 1, 101, CURDATE(), date_add(CURDATE(),INTERVAL 1 MONTH), 50, 7),

View File

@ -1 +0,0 @@
update vn2008.Consignatarios set predeterminada = 1 where predeterminada = -1;

View File

@ -1,3 +0,0 @@
UPDATE vn.client
SET email = REPLACE(REPLACE(email, ' ', ''), ';', ',')
WHERE email REGEXP '[ |;]';

View File

@ -1,5 +0,0 @@
INSERT INTO account.user (id,name,role,password,active)
select c.Id_Cliente,c.Id_Cliente,2,'no_tiene',FALSE
FROM vn2008.Clientes c
LEFT JOIN account.user u ON u.id = c.id_cliente
where u.id is NULL

View File

@ -1,15 +0,0 @@
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES ('Ticket', '*', '*', 'ALLOW', 'ROLE', 'employee');
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES ('TicketObservation', '*', '*', 'ALLOW', 'ROLE', 'employee');
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES ('Route', '*', 'READ', 'ALLOW', 'ROLE', 'employee');
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES ('Sale', '*', '*', 'ALLOW', 'ROLE', 'employee');
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES ('TicketTracking', '*', '*', 'ALLOW', 'ROLE', 'employee');
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES ('TicketState', '*', '*', 'ALLOW', 'ROLE', 'employee');
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES ('TicketPackaging', '*', '*', 'ALLOW', 'ROLE', 'employee');
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES ('Packaging', '*', 'READ', 'ALLOW', 'ROLE', 'employee');
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES ('Packaging', '*', 'WRITE', 'ALLOW', 'ROLE', 'logistic');
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES ('SaleChecked', '*', 'READ', 'ALLOW', 'ROLE', 'employee');
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES ('SaleComponent', '*', 'READ', 'ALLOW', 'ROLE', 'employee');
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES ('Expedition', '*', 'READ', 'ALLOW', 'ROLE', 'employee');
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES ('Expedition', '*', 'READ', 'ALLOW', 'ROLE', 'employee');
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES ('Expedition', '*', 'WRITE', 'ALLOW', 'ROLE', 'production');
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES ('AnnualAverageInvoiced', '*', 'READ', 'ALLOW', 'ROLE', 'employee');

View File

@ -1,18 +0,0 @@
USE `vn`;
CREATE
OR REPLACE ALGORITHM = UNDEFINED
DEFINER = `root`@`%`
SQL SECURITY DEFINER
VIEW `vn`.`packaging` AS
SELECT
`c`.`Id_Cubo` AS `id`,
`c`.`Volumen` AS `volume`,
`c`.`X` AS `width`,
`c`.`Y` AS `height`,
`c`.`Z` AS `depth`,
`c`.`Retornable` AS `isPackageReturnable`,
`c`.`odbc_date` AS `created`,
`c`.`item_id` AS `itemFk`,
`c`.`pvp` AS `price`
FROM
`vn2008`.`Cubos` `c`;

View File

@ -1,11 +0,0 @@
USE `vn`;
CREATE
OR REPLACE ALGORITHM = UNDEFINED
DEFINER = `root`@`%`
SQL SECURITY DEFINER
VIEW `vn`.`saleChecked` AS
SELECT
`m`.`Id_Movimiento` AS `saleFk`,
`m`.`checked` AS `isChecked`
FROM
`vn2008`.`Movimientos_checked` `m`;

View File

@ -1,30 +0,0 @@
USE `vn`;
DROP procedure IF EXISTS `ticketVolume`;
DELIMITER $$
USE `vn`$$
CREATE DEFINER=`root`@`%` PROCEDURE `vn`.`ticketVolume`(IN vTicketId INT)
BEGIN
DECLARE vWarehouseId INTEGER;
DECLARE vShippedDate DATE;
DROP TEMPORARY TABLE IF EXISTS ticketVolume;
SELECT warehouseFk, shipped INTO vWarehouseId,vShippedDate FROM vn.ticket WHERE id = vTicketId;
CREATE TEMPORARY TABLE IF NOT EXISTS ticketVolume ENGINE MEMORY
SELECT itemFk,quantity, concept, VolUd as m3_uni, volume as m3, @m3:= @m3 + ifnull(volume,0) as m3_total
FROM
(
SELECT round(r.cm3 / 1000000,3) as VolUd ,s.quantity, round(r.cm3 * s.quantity / 1000000,3) as volume,
s.itemFk, s.concept, @m3:= 0, @vol:=0, t.agencyModeFk
FROM sale s
JOIN vn.ticket t on t.id = s.ticketFk
JOIN bi.rotacion r ON r.Id_Article = s.itemFk AND r.warehouse_id = t.warehouseFk
WHERE s.ticketFk = vTicketId
) sub;
END$$
DELIMITER ;

View File

@ -1,19 +0,0 @@
USE `vn`;
CREATE
OR REPLACE ALGORITHM = UNDEFINED
DEFINER = `root`@`%`
SQL SECURITY DEFINER
VIEW `vn`.`expedition` AS
SELECT
`e`.`expeditions_id` AS `id`,
`e`.`agency_id` AS `agencyModeFk`,
`e`.`ticket_id` AS `ticketFk`,
`e`.`EsBulto` AS `isBox`,
`e`.`odbc_date` AS `created`,
`e`.`Id_Article` AS `itemFk`,
`e`.`counter` AS `counter`,
`e`.`checked` AS `checked`,
`e`.`workerFk` AS `workerFk`
FROM
`vn2008`.`expeditions` `e`

View File

@ -1,10 +0,0 @@
USE `vn`;
CREATE
OR REPLACE ALGORITHM = UNDEFINED
DEFINER = `root`@`%`
SQL SECURITY DEFINER
VIEW `vn`.`annualAverageInvoiced` AS
SELECT
`e`.`Id_Cliente` AS `clientFk`, `e`.`Consumo` AS `invoiced`
FROM
`bi`.`facturacion_media_anual` `e`;

View File

@ -1,22 +0,0 @@
USE `vn`;
CREATE
OR REPLACE ALGORITHM = UNDEFINED
DEFINER = `root`@`%`
SQL SECURITY DEFINER
VIEW `agencyMode` AS
SELECT
`a`.`Id_Agencia` AS `id`,
`a`.`Agencia` AS `name`,
`a`.`description` AS `description`,
`a`.`Vista` AS `deliveryMethodFk`,
`a`.`m3` AS `m3`,
`a`.`cod71` AS `cod71`,
`a`.`web` AS `web`,
`a`.`agency_id` AS `agencyFk`,
`a`.`agency_service_id` AS `agencyServiceFk`,
`a`.`inflacion` AS `inflation`,
`a`.`is_volumetric` AS `isVolumetric`,
`a`.`send_mail` AS `reportMail`,
`a`.`tpv` AS `isActive`
FROM
`vn2008`.`Agencias` `a`;

View File

@ -1,28 +0,0 @@
USE `vn`;
DROP procedure IF EXISTS `ticketVolume`;
DELIMITER $$
USE `vn`$$
CREATE DEFINER=`root`@`%` PROCEDURE `ticketVolume`(IN vTicketId INT)
BEGIN
DECLARE vWarehouseId INTEGER;
DECLARE vShippedDate DATE;
DROP TEMPORARY TABLE IF EXISTS ticketVolume;
SELECT warehouseFk, shipped INTO vWarehouseId,vShippedDate FROM vn.ticket WHERE id = vTicketId;
CREATE TEMPORARY TABLE IF NOT EXISTS ticketVolume ENGINE MEMORY
SELECT itemFk, saleFk, quantity, concept, VolUd as m3_uni, volume as m3, volume * quantity as volumeTimesQuantity, @m3:= @m3 + ifnull(volume,0) as m3_total
FROM
(
SELECT round(r.cm3 / 1000000,3) as VolUd ,s.quantity, round(r.cm3 * s.quantity / 1000000,3) as volume,
s.itemFk, s.id AS saleFk, s.concept, @m3:= 0, @vol:=0, t.agencyModeFk
FROM sale s
JOIN vn.ticket t on t.id = s.ticketFk
JOIN bi.rotacion r ON r.Id_Article = s.itemFk AND r.warehouse_id = t.warehouseFk
WHERE s.ticketFk = vTicketId
) sub;
END$$
DELIMITER ;

View File

@ -1,26 +0,0 @@
USE `vn`;
CREATE
OR REPLACE ALGORITHM = UNDEFINED
DEFINER = `root`@`%`
SQL SECURITY DEFINER
VIEW `vn`.`supplier` AS
SELECT
`p`.`Id_Proveedor` AS `id`,
`p`.`Proveedor` AS `name`,
`p`.`cuenta` AS `account`,
`p`.`pais_id` AS `countryFk`,
`p`.`NIF` AS `nif`,
`p`.`Agricola` AS `isFarmer`,
`p`.`cuentaret` AS `retAccount`,
`p`.`ComisionProveedor` AS `commission`,
`p`.`odbc_time` AS `created`,
`p`.`postcode_id` AS `postcodeFk`,
`p`.`active` AS `isActive`,
`p`.`Domicilio` AS `street`,
`p`.`Localidad` AS `city`,
`p`.`province_id` AS `provinceFk`,
`p`.`codpos` AS `postCode`,
`p`.`pay_met_id` AS `payMethodFk`,
`p`.`pay_dem_id` AS `payDemFk`
FROM
`vn2008`.`Proveedores` `p`;

View File

@ -1,10 +0,0 @@
USE `vn`;
CREATE
OR REPLACE ALGORITHM = UNDEFINED
DEFINER = `root`@`%`
SQL SECURITY DEFINER
VIEW `vn`.`payDem` AS
SELECT
`t`.`id` AS `id`, `t`.`pay_dem` AS `payDem`
FROM
`vn2008`.`pay_dem` `t`;

View File

@ -1,15 +0,0 @@
USE `vn`;
DROP procedure IF EXISTS `ticketListVolume`;
DELIMITER $$
USE `vn`$$
CREATE DEFINER=`root`@`%` PROCEDURE `ticketListVolume`(IN vTicketId INT)
BEGIN
CALL vn.ticketVolume(vTicketId);
SELECT * FROM vn.ticketVolume;
END$$
DELIMITER ;

View File

@ -1,15 +0,0 @@
USE `vn`;
CREATE
OR REPLACE ALGORITHM = UNDEFINED
DEFINER = `root`@`%`
SQL SECURITY DEFINER
VIEW `vn`.`company` AS
SELECT
`e`.`id` AS `id`,
`e`.`abbreviation` AS `code`,
`e`.`Id_Proveedores_account` AS `supplierAccountFk`,
`e`.`gerente_id` AS `workerManagerFk`,
`e`.`digito_factura` AS `sage200Company`,
`e`.`CodigoEmpresa` AS `companyCode`
FROM
`vn2008`.`empresa` `e`;

View File

@ -1,4 +1,4 @@
::IMPORTANT Any changes in this file are to applyed to mirror file export-data.sh
echo USE `account`; > 02-dumpedFixtures.sql
mysqldump --defaults-file=connect.ini --no-create-info account role roleRole roleInherit >> 02-dumpedFixtures.sql
echo USE `salix`; >> 02-dumpedFixtures.sql

View File

@ -1,2 +1,2 @@
mysqldump --defaults-file=connect.ini --default-character-set=utf8 --no-data --triggers --routines --events --databases account util vn2008 vn edi bs bi pbx cache salix vncontrol hedera stock > 01-structure.sql
::IMPORTANT Any changes in this file are to applyed to mirror file export-structure.sh
mysqldump --defaults-file=connect.ini --default-character-set=utf8 --no-data --comments --triggers --routines --events --databases account util vn2008 vn edi bs bi pbx cache salix vncontrol hedera stock > 01-structure.sql

View File

@ -0,0 +1,3 @@
#!/bin/bash
#IMPORTANT Any changes in this file are to applyed to mirror file export-structure.cmd
mysqldump --defaults-file=connect.ini --default-character-set=utf8 --no-data --comments --triggers --routines --events --databases account util vn2008 vn edi bs bi pbx cache salix vncontrol hedera stock > 01-structure.sql