7489-testToMaster #2515
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `vn`.`sale_setComponentLackProblem`(
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `vn`.`sale_setProblemComponentLack`(
|
||||
vSelf INT
|
||||
)
|
||||
BEGIN
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `vn`.`sale_setComponentLackProblemComponent`(
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `vn`.`sale_setProblemComponentLackByComponent`(
|
||||
vComponentFk INT
|
||||
)
|
||||
BEGIN
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `vn`.`sale_setRoundingProblem`(
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `vn`.`sale_setProblemRounding`(
|
||||
vSelf INT
|
||||
)
|
||||
BEGIN
|
|
@ -1,5 +1,5 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `vn`.`ticket_setTaxDataCheckedProblemByClient`(
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `vn`.`tticket_setProblemTaxDataCheckedByClient`(
|
||||
vClientFk INT
|
||||
)
|
||||
proc: BEGIN
|
|
@ -1,20 +0,0 @@
|
|||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `vn`.`ticket_setProblemTooLittleConfig`()
|
||||
BEGIN
|
||||
/**
|
||||
* Update the problems when the ticket is too small or is no longer so,
|
||||
* derived from changes in the volumeConfig table
|
||||
*
|
||||
*/
|
||||
CREATE OR REPLACE TEMPORARY TABLE tmp.ticket
|
||||
(INDEX(ticketFk))
|
||||
ENGINE = MEMORY
|
||||
SELECT t.id ticketFk, ticket_isTooLittle(t.id) hasProblem
|
||||
FROM ticket t
|
||||
WHERE t.shipped >= util.midnight();
|
||||
|
||||
CALL ticket_setProblem('isTooLittle');
|
||||
|
||||
DROP TEMPORARY TABLE tmp.ticket;
|
||||
END$$
|
||||
DELIMITER ;
|
|
@ -7,7 +7,7 @@ BEGIN
|
|||
* Update the problems when the ticket is too small or is no longer so,
|
||||
* derived from changes in the itemCost table
|
||||
*
|
||||
* @param vItemFk Id del item
|
||||
* @param vItemFk Id del item, NULL ALL items
|
||||
*/
|
||||
CREATE OR REPLACE TEMPORARY TABLE tmp.ticket
|
||||
(INDEX(ticketFk))
|
||||
|
@ -16,8 +16,8 @@ BEGIN
|
|||
SELECT t.id ticketFk
|
||||
FROM vn.ticket t
|
||||
JOIN vn.sale s ON s.ticketFk = t.id
|
||||
WHERE s.itemFk = vItemFk
|
||||
AND t.shipped >= util.midnight()
|
||||
WHERE t.shipped >= util.midnight()
|
||||
AND (s.itemFk = vItemFk OR vItemFk IS NULL)
|
||||
GROUP BY t.id
|
||||
)SELECT ticketFk, ticket_isTooLittle(ticketFk) hasProblem
|
||||
FROM tickets;
|
||||
|
|
Loading…
Reference in New Issue