7489-testToMaster #2515

Merged
alexm merged 329 commits from 7489-testToMaster into master 2024-05-28 05:30:19 +00:00
2 changed files with 5 additions and 5 deletions
Showing only changes of commit 53f49531b7 - Show all commits

View File

@ -44,7 +44,7 @@ BEGIN
hasComponentLack INTEGER(1),
hasRounding VARCHAR(255),
isTooLittle BOOL DEFAULT FALSE,
isVIP BOOL DEFAULT FALSE,
isVip BOOL DEFAULT FALSE,
PRIMARY KEY (ticketFk, saleFk)
) ENGINE = MEMORY;
@ -82,12 +82,12 @@ BEGIN
AND sub.totalWithoutVat < vc.minTicketValue;
-- VIP
INSERT INTO tmp.sale_problems(ticketFk, isVIP)
INSERT INTO tmp.sale_problems(ticketFk, isVip)
SELECT DISTINCT tl.ticketFk, TRUE
FROM tmp.ticket_list tl
JOIN client c ON c.id = tl.clientFk
WHERE c.businessTypeFk = 'VIP'
ON DUPLICATE KEY UPDATE isVIP = TRUE;
ON DUPLICATE KEY UPDATE isVip = TRUE;
-- Faltan componentes
INSERT INTO tmp.sale_problems(ticketFk, hasComponentLack, saleFk)

View File

@ -25,7 +25,7 @@ BEGIN
MAX(itemDelay) itemDelay,
MAX(hasRounding) hasRounding,
MAX(itemLost) itemLost,
MAX(isVIP) isVIP,
MAX(isVip) isVip,
0 totalProblems
FROM tmp.sale_problems
GROUP BY ticketFk;
@ -42,7 +42,7 @@ BEGIN
(tp.itemLost) +
(tp.hasRounding) +
(tp.itemShortage) +
(tp.isVIP)
(tp.isVip)
);
DROP TEMPORARY TABLE tmp.sale_problems;