feat: Turn issues into calculated columns refs#7213
gitea/salix/pipeline/pr-dev This commit looks good
Details
gitea/salix/pipeline/pr-dev This commit looks good
Details
This commit is contained in:
parent
f89ca786df
commit
3ce43909e2
|
@ -8,7 +8,6 @@ BEGIN
|
||||||
*
|
*
|
||||||
* @param vSelf Id ticket, if NULL ALL tickets
|
* @param vSelf Id ticket, if NULL ALL tickets
|
||||||
*/
|
*/
|
||||||
|
|
||||||
CREATE OR REPLACE TEMPORARY TABLE tmp.ticket
|
CREATE OR REPLACE TEMPORARY TABLE tmp.ticket
|
||||||
(INDEX(ticketFk))
|
(INDEX(ticketFk))
|
||||||
ENGINE = MEMORY
|
ENGINE = MEMORY
|
||||||
|
@ -17,7 +16,6 @@ BEGIN
|
||||||
WHERE t.shipped >= util.midnight()
|
WHERE t.shipped >= util.midnight()
|
||||||
AND (vSelf IS NULL OR t.id = vSelf);
|
AND (vSelf IS NULL OR t.id = vSelf);
|
||||||
|
|
||||||
|
|
||||||
UPDATE tmp.ticket t
|
UPDATE tmp.ticket t
|
||||||
JOIN ticketRequest tr ON tr.ticketFk = t.ticketFk
|
JOIN ticketRequest tr ON tr.ticketFk = t.ticketFk
|
||||||
SET t.hasProblem = TRUE
|
SET t.hasProblem = TRUE
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
DELIMITER $$
|
DELIMITER $$
|
||||||
CREATE OR REPLACE DEFINER=`root`@`localhost`
|
CREATE OR REPLACE DEFINER=`root`@`localhost`
|
||||||
PROCEDURE `vn`.`ticket_setProblemTaxDataChecked`(vSelf INT)
|
PROCEDURE `vn`.`ticket_setProblemTaxDataChecked`(vClientFk INT)
|
||||||
BEGIN
|
BEGIN
|
||||||
/**
|
/**
|
||||||
* Update the problem of tickets, depending on whether
|
* Update the problem of tickets, depending on whether
|
||||||
* the client taxDataCheched is verified or not
|
* the client taxDataCheched is verified or not
|
||||||
*
|
*
|
||||||
* @param vSelf Id ticket, if NULL all tickets
|
* @param vClientFk Id cliente, if NULL all clients
|
||||||
*/
|
*/
|
||||||
CREATE OR REPLACE TEMPORARY TABLE tmp.ticket
|
CREATE OR REPLACE TEMPORARY TABLE tmp.ticket
|
||||||
(INDEX(ticketFk))
|
(INDEX(ticketFk))
|
||||||
|
|
|
@ -17,7 +17,7 @@ BEGIN
|
||||||
FROM vn.ticket t
|
FROM vn.ticket t
|
||||||
JOIN vn.sale s ON s.ticketFk = t.id
|
JOIN vn.sale s ON s.ticketFk = t.id
|
||||||
WHERE t.shipped >= util.midnight()
|
WHERE t.shipped >= util.midnight()
|
||||||
AND (s.itemFk = vItemFk OR vItemFk IS NULL)
|
AND (s.itemFk = vItemFk OR vItemFk IS NULL)
|
||||||
GROUP BY t.id
|
GROUP BY t.id
|
||||||
)SELECT ticketFk, ticket_isTooLittle(ticketFk) hasProblem
|
)SELECT ticketFk, ticket_isTooLittle(ticketFk) hasProblem
|
||||||
FROM tickets;
|
FROM tickets;
|
||||||
|
|
Loading…
Reference in New Issue