delete deprecated files
This commit is contained in:
parent
d89fdbcdd1
commit
b301d07cd6
|
@ -1,29 +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 ;
|
||||
|
|
@ -1,10 +0,0 @@
|
|||
USE `vn`;
|
||||
CREATE
|
||||
OR REPLACE ALGORITHM = UNDEFINED
|
||||
DEFINER = `root`@`%`
|
||||
SQL SECURITY DEFINER
|
||||
VIEW `vn`.`ticketUpdateAction` AS
|
||||
SELECT
|
||||
`b`.`buo_id` AS `id`, `b`.`description` AS `description`
|
||||
FROM
|
||||
`vn2008`.`bionic_updating_options` `b`;
|
|
@ -1,10 +0,0 @@
|
|||
USE `bs`;
|
||||
CREATE
|
||||
OR REPLACE ALGORITHM = UNDEFINED
|
||||
DEFINER = `root`@`%`
|
||||
SQL SECURITY DEFINER
|
||||
VIEW `bs`.`workerMana` AS
|
||||
SELECT
|
||||
`m`.`Id_Trabajador` AS `workerFk`, `m`.`used` AS `amount`
|
||||
FROM
|
||||
`bs`.`mana_spellers` `m`;
|
|
@ -1,10 +0,0 @@
|
|||
USE `vn`;
|
||||
CREATE
|
||||
OR REPLACE ALGORITHM = UNDEFINED
|
||||
DEFINER = `root`@`%`
|
||||
SQL SECURITY DEFINER
|
||||
VIEW `ticketWeekly` AS
|
||||
SELECT
|
||||
`t`.`Id_Ticket` AS `ticketFk`, `t`.`weekDay` AS `weekDay`
|
||||
FROM
|
||||
`vn2008`.`Tickets_turno` `t`;
|
|
@ -1,16 +0,0 @@
|
|||
USE `vn`;
|
||||
CREATE
|
||||
OR REPLACE ALGORITHM = UNDEFINED
|
||||
DEFINER = `root`@`%`
|
||||
SQL SECURITY DEFINER
|
||||
VIEW `vn`.`warehouse` AS
|
||||
SELECT
|
||||
`t`.`id` AS `id`,
|
||||
`t`.`name` AS `name`,
|
||||
`t`.`inventario` AS `isInventory`,
|
||||
`t`.`is_comparative` AS `isComparative`,
|
||||
`t`.`comisionantes` AS `hasComission`,
|
||||
`t`.`reserve` AS `hasAvailable`,
|
||||
`t`.`isManaged` AS `isManaged`
|
||||
FROM
|
||||
`vn2008`.`warehouse` `t`;
|
|
@ -1,32 +0,0 @@
|
|||
USE `vn`;
|
||||
CREATE
|
||||
OR REPLACE ALGORITHM = UNDEFINED
|
||||
DEFINER = `root`@`%`
|
||||
SQL SECURITY DEFINER
|
||||
VIEW `buy` AS
|
||||
SELECT
|
||||
`c`.`Id_Compra` AS `id`,
|
||||
`c`.`Id_Entrada` AS `entryFk`,
|
||||
`c`.`Id_Article` AS `itemFk`,
|
||||
`c`.`Cantidad` AS `amount`,
|
||||
`c`.`Costefijo` AS `buyingValue`,
|
||||
`c`.`Cantidad` AS `quantity`,
|
||||
`c`.`Id_Cubo` AS `packageFk`,
|
||||
`c`.`Etiquetas` AS `stickers`,
|
||||
`c`.`Portefijo` AS `freightValue`,
|
||||
`c`.`Embalajefijo` AS `packageValue`,
|
||||
`c`.`Comisionfija` AS `comissionValue`,
|
||||
`c`.`Packing` AS `packing`,
|
||||
`c`.`grouping` AS `grouping`,
|
||||
`c`.`caja` AS `groupingMode`,
|
||||
`c`.`Nicho` AS `location`,
|
||||
`c`.`Tarifa1` AS `price1`,
|
||||
`c`.`Tarifa2` AS `price2`,
|
||||
`c`.`Tarifa3` AS `price3`,
|
||||
`c`.`PVP` AS `minPrice`,
|
||||
`c`.`Productor` AS `producer`,
|
||||
`c`.`Vida` AS `printedStickers`,
|
||||
`c`.`punteo` AS `isChecked`,
|
||||
`c`.`Novincular` AS `isIgnored`
|
||||
FROM
|
||||
`vn2008`.`Compres` `c`;
|
|
@ -1,31 +0,0 @@
|
|||
USE `vn`;
|
||||
CREATE
|
||||
OR REPLACE ALGORITHM = UNDEFINED
|
||||
DEFINER = `root`@`%`
|
||||
SQL SECURITY DEFINER
|
||||
VIEW `vn`.`item` AS
|
||||
SELECT
|
||||
`t`.`Id_Article` AS `id`,
|
||||
`t`.`Article` AS `name`,
|
||||
`t`.`tipo_id` AS `typeFk`,
|
||||
`t`.`Medida` AS `size`,
|
||||
`t`.`Color` AS `inkFk`,
|
||||
`t`.`Categoria` AS `category`,
|
||||
`t`.`Tallos` AS `stems`,
|
||||
`t`.`id_origen` AS `originFk`,
|
||||
`t`.`description` AS `description`,
|
||||
`t`.`producer_id` AS `producerFk`,
|
||||
`t`.`Codintrastat` AS `intrastatFk`,
|
||||
`t`.`offer` AS `isOnOffer`,
|
||||
`t`.`expenceFk` AS `expenceFk`,
|
||||
`t`.`bargain` AS `isBargain`,
|
||||
`t`.`comments` AS `comment`,
|
||||
`t`.`relevancy` AS `relevancy`,
|
||||
`t`.`Foto` AS `image`,
|
||||
`t`.`generic` AS `generic`,
|
||||
`t`.`density` AS `density`,
|
||||
`t`.`iva_group_id` AS `taxClassFk`,
|
||||
`t`.`PVP` AS `minPrice`,
|
||||
`t`.`Min` AS `hasMinPrice`
|
||||
FROM
|
||||
`vn2008`.`Articles` `t`;
|
|
@ -1,22 +0,0 @@
|
|||
USE `vn`;
|
||||
CREATE
|
||||
OR REPLACE ALGORITHM = UNDEFINED
|
||||
DEFINER = `root`@`%`
|
||||
SQL SECURITY DEFINER
|
||||
VIEW `vn`.`travel` AS
|
||||
SELECT
|
||||
`t`.`id` AS `id`,
|
||||
`t`.`shipment` AS `shipped`,
|
||||
`t`.`shipment_hour` AS `shipmentHour`,
|
||||
`t`.`landing` AS `landed`,
|
||||
`t`.`landing_hour` AS `landingHour`,
|
||||
`t`.`warehouse_id` AS `warehouseInFk`,
|
||||
`t`.`warehouse_id_out` AS `warehouseOutFk`,
|
||||
`t`.`agency_id` AS `agencyFk`,
|
||||
`t`.`ref` AS `ref`,
|
||||
`t`.`delivered` AS `isDelivered`,
|
||||
`t`.`received` AS `isReceived`,
|
||||
`t`.`m3` AS `m3`,
|
||||
`t`.`kg` AS `kg`
|
||||
FROM
|
||||
`vn2008`.`travel` `t`;
|
|
@ -1,22 +0,0 @@
|
|||
USE `vn`;
|
||||
DROP function IF EXISTS `getSpecialPrice`;
|
||||
|
||||
DELIMITER $$
|
||||
USE `vn`$$
|
||||
CREATE DEFINER=`root`@`%` FUNCTION `getSpecialPrice`(vItemFk int(11),vClientFk int(11)) RETURNS decimal(10,2)
|
||||
BEGIN
|
||||
DECLARE price DECIMAL(10,2);
|
||||
|
||||
SELECT rate3 INTO price
|
||||
FROM vn.priceFixed
|
||||
WHERE itemFk = vItemFk
|
||||
AND CURDATE() BETWEEN started AND ended ORDER BY created DESC LIMIT 1;
|
||||
|
||||
SELECT `value` INTO price
|
||||
FROM vn.specialPrice
|
||||
WHERE itemFk = vItemFk
|
||||
AND clientFk = vClientFk ;
|
||||
RETURN price;
|
||||
END$$
|
||||
|
||||
DELIMITER ;
|
|
@ -1,13 +0,0 @@
|
|||
USE `vn`;
|
||||
CREATE
|
||||
OR REPLACE ALGORITHM = UNDEFINED
|
||||
DEFINER = `root`@`%`
|
||||
SQL SECURITY DEFINER
|
||||
VIEW `vn`.`specialPrice` AS
|
||||
SELECT
|
||||
`p`.`Id_PrecioEspecial` AS `id`,
|
||||
`p`.`Id_Cliente` AS `clientFk`,
|
||||
`p`.`Id_Article` AS `itemFk`,
|
||||
`p`.`PrecioEspecial` AS `value`
|
||||
FROM
|
||||
`vn2008`.`PreciosEspeciales` `p`;
|
|
@ -1,11 +0,0 @@
|
|||
CREATE TABLE vn.ticketComponentTemplate
|
||||
|
||||
SELECT * FROM vn2008.template_bionic_component;
|
||||
|
||||
ALTER TABLE `vn`.`ticketComponentTemplate`
|
||||
|
||||
CHANGE COLUMN `warehouse_id` `warehouseFk` SMALLINT(5) UNSIGNED NOT NULL ,
|
||||
|
||||
CHANGE COLUMN `item_id` `itemFk` INT(11) NOT NULL ,
|
||||
|
||||
CHANGE COLUMN `component_id` `componentFk` INT(10) UNSIGNED NOT NULL;
|
|
@ -1,14 +0,0 @@
|
|||
USE `vn`;
|
||||
CREATE
|
||||
OR REPLACE ALGORITHM = UNDEFINED
|
||||
DEFINER = `root`@`%`
|
||||
SQL SECURITY DEFINER
|
||||
VIEW `vn`.`agencyProvince` AS
|
||||
SELECT
|
||||
`a`.`province_id` AS `provinceFk`,
|
||||
`a`.`agency_id` AS `agencyFk`,
|
||||
`a`.`zona` AS `zone`,
|
||||
`a`.`warehouse_id` AS `warehouseFk`,
|
||||
`a`.`route` AS `route`
|
||||
FROM
|
||||
`vn2008`.`Agencias_province` `a`;
|
|
@ -1,16 +0,0 @@
|
|||
USE `vn`;
|
||||
CREATE
|
||||
OR REPLACE ALGORITHM = UNDEFINED
|
||||
DEFINER = `root`@`%`
|
||||
SQL SECURITY DEFINER
|
||||
VIEW `vn`.`agencyModeZone` AS
|
||||
SELECT
|
||||
`a`.`Id_Agencia` AS `agencyModeFk`,
|
||||
`a`.`zona` AS `zone`,
|
||||
`a`.`price` AS `price`,
|
||||
`a`.`Id_Article` AS `itemFk`,
|
||||
`a`.`warehouse_id` AS `warehouseFk`,
|
||||
`a`.`porte_minimo` AS `minimCost`,
|
||||
`a`.`inflacion` AS `inflation`
|
||||
FROM
|
||||
`vn2008`.`Agencias_zonas` `a`;
|
|
@ -1,15 +0,0 @@
|
|||
USE `vn`;
|
||||
CREATE
|
||||
OR REPLACE ALGORITHM = UNDEFINED
|
||||
DEFINER = `root`@`%`
|
||||
SQL SECURITY DEFINER
|
||||
VIEW `vn`.`agencyWeekdayBonus` AS
|
||||
SELECT
|
||||
`a`.`id` AS `id`,
|
||||
`a`.`warehouse_id` AS `warehouseFk`,
|
||||
`a`.`agency_id` AS `agencyFk`,
|
||||
`a`.`weekDay` AS `weekDay`,
|
||||
`a`.`zona` AS `zone`,
|
||||
`a`.`bonus` AS `bonus`
|
||||
FROM
|
||||
`vn2008`.`agency_weekday_bonus` `a`;
|
|
@ -1,12 +0,0 @@
|
|||
USE `vn`;
|
||||
CREATE
|
||||
OR REPLACE ALGORITHM = UNDEFINED
|
||||
DEFINER = `root`@`%`
|
||||
SQL SECURITY DEFINER
|
||||
VIEW `vn`.`preparationPercentage` AS
|
||||
SELECT
|
||||
`p`.`week_day` AS `weekDay`,
|
||||
`p`.`warehouse_id` AS `warehouseFk`,
|
||||
`p`.`percentage` AS `percentage`
|
||||
FROM
|
||||
`vn2008`.`preparation_percentage` `p`;
|
|
@ -1,12 +0,0 @@
|
|||
USE `vn`;
|
||||
CREATE
|
||||
OR REPLACE ALGORITHM = UNDEFINED
|
||||
DEFINER = `root`@`%`
|
||||
SQL SECURITY DEFINER
|
||||
VIEW `vn`.`preparationException` AS
|
||||
SELECT
|
||||
`p`.`exception_day` AS `exceptionDay`,
|
||||
`p`.`warehouse_id` AS `warehouseFk`,
|
||||
`p`.`percentage` AS `percentage`
|
||||
FROM
|
||||
`vn2008`.`preparation_exception` `p`;
|
|
@ -1,2 +0,0 @@
|
|||
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`) VALUES ('WorkerMana', '*', 'READ', 'ALLOW', 'ROLE');
|
||||
UPDATE `salix`.`ACL` SET `principalId`='employee' WHERE `id`='77';
|
Loading…
Reference in New Issue