Merge branch 'test' into dev
gitea/salix/pipeline/head This commit looks good
Details
gitea/salix/pipeline/head This commit looks good
Details
This commit is contained in:
commit
403252ac39
|
@ -10,11 +10,6 @@ BEGIN
|
|||
* @param vSaleGroupFk id de la preparación previa
|
||||
* @param vParkingFk id del parking
|
||||
*/
|
||||
DECLARE EXIT HANDLER FOR SQLEXCEPTION
|
||||
BEGIN
|
||||
RESIGNAL;
|
||||
END;
|
||||
|
||||
UPDATE saleGroup sg
|
||||
SET sg.parkingFk = vParkingFk
|
||||
WHERE sg.id = vSaleGroupFk
|
||||
|
|
|
@ -13,12 +13,6 @@ BEGIN
|
|||
DECLARE vParkingFk INT;
|
||||
DECLARE vLastWeek DATE;
|
||||
|
||||
DECLARE EXIT HANDLER FOR SQLEXCEPTION
|
||||
BEGIN
|
||||
ROLLBACK;
|
||||
RESIGNAL;
|
||||
END;
|
||||
|
||||
SET vParkingCode = REPLACE(vParkingCode, ' ', '');
|
||||
|
||||
SELECT id INTO vParkingFk
|
||||
|
@ -29,8 +23,6 @@ BEGIN
|
|||
CALL util.throw('parkingNotExist');
|
||||
END IF;
|
||||
|
||||
START TRANSACTION;
|
||||
|
||||
SET vLastWeek = util.VN_CURDATE() - INTERVAL 1 WEEK;
|
||||
|
||||
-- Comprobamos si es una prep. previa, ticket, colección o shelving
|
||||
|
@ -45,7 +37,5 @@ BEGIN
|
|||
ELSE
|
||||
CALL util.throw('paramNotExist');
|
||||
END IF;
|
||||
|
||||
COMMIT;
|
||||
END$$
|
||||
DELIMITER ;
|
||||
|
|
|
@ -1,20 +1,20 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `vn`.`shelving_setParking`(IN `vShelvingCode` VARCHAR(8), IN `vParkingFk` INT)
|
||||
proc: BEGIN
|
||||
BEGIN
|
||||
/**
|
||||
* Aparca una matrícula en un parking
|
||||
*
|
||||
* @param vShelvingCode code de la matrícula
|
||||
* @param vParkingFk id del parking
|
||||
*/
|
||||
INSERT INTO vn.shelvingLog (originFk, userFk, action , description,changedModel,changedModelId)
|
||||
INSERT INTO shelvingLog (originFk, userFk, action , description,changedModel,changedModelId)
|
||||
SELECT s.id, account.myUser_getId(), 'update', CONCAT("Cambio parking ",vShelvingCode," de ", p.code," a ", pNew.code),'Shelving',s.id
|
||||
FROM parking p
|
||||
JOIN shelving s ON s.parkingFk = p.id
|
||||
JOIN parking pNew ON pNew.id = vParkingFk
|
||||
WHERE s.code = vShelvingCode COLLATE utf8_unicode_ci;
|
||||
|
||||
UPDATE vn.shelving
|
||||
UPDATE shelving
|
||||
SET parkingFk = vParkingFk,
|
||||
parked = util.VN_NOW(),
|
||||
isPrinted = TRUE
|
||||
|
|
|
@ -21,11 +21,6 @@ BEGIN
|
|||
|
||||
DECLARE CONTINUE HANDLER FOR NOT FOUND SET vDone = TRUE;
|
||||
|
||||
DECLARE EXIT HANDLER FOR SQLEXCEPTION
|
||||
BEGIN
|
||||
RESIGNAL;
|
||||
END;
|
||||
|
||||
INSERT INTO vn.ticketParking(ticketFk, parkingFk)
|
||||
SELECT IFNULL(tc2.ticketFk, t.id), vParkingFk
|
||||
FROM ticket t
|
||||
|
|
Loading…
Reference in New Issue