7226-testToMaster_2416 #2320

Merged
alexm merged 188 commits from 7226-testToMaster_2416 into master 2024-04-18 05:39:36 +00:00
1 changed files with 19 additions and 19 deletions
Showing only changes of commit 9fcad457a7 - Show all commits

View File

@ -69,7 +69,8 @@ module.exports = Self => {
'reason',
LEFT(reason,LENGTH(reason) - 2)
)
))errors
)
)errors
FROM (
SELECT ticketFk,
CONCAT_WS('',
@ -107,14 +108,13 @@ module.exports = Self => {
AND itc.countryFk = su.countryFk
LEFT JOIN vn.invoiceOutSerial ios ON ios.taxAreaFk = 'WORLD'
AND ios.code = invoiceSerial(t.clientFk, t.companyFk, 'M')
WHERE (al.code = 'PACKED'
OR (am.code = 'refund' AND al.code != 'delivered'))
WHERE (al.code = 'PACKED' OR (am.code = 'refund' AND al.code <> 'delivered'))
AND DATE(t.shipped) BETWEEN DATE_ADD(?, INTERVAL -2 DAY) AND util.dayEnd(?)
AND t.refFk IS NULL
AND IFNULL(a.hasDailyInvoice, co.hasDailyInvoice)
GROUP BY ticketFk
HAVING hasErrorToInvoice
OR NOT hasErrorTaxDataChecked
OR hasErrorTaxDataChecked
OR hasErrorDeleted
OR hasErrorItemTaxCountry
OR hasErrorAddress