#7202 added new field in InvoiceOut module #3034

Open
jon wants to merge 13 commits from 7202-AddCustomAgentFkColumn into dev
1 changed files with 7 additions and 4 deletions
Showing only changes of commit a6799cba0f - Show all commits

View File

@ -105,7 +105,8 @@ BEGIN
clientFk, clientFk,
dued, dued,
companyFk, companyFk,
siiTypeInvoiceOutFk siiTypeInvoiceOutFk,
customsAgentFk
) )
SELECT SELECT
1, 1,
@ -118,9 +119,11 @@ BEGIN
vCplusCorrectingInvoiceTypeFk, vCplusCorrectingInvoiceTypeFk,
IF(vSerial = vSimplifiedSerial, IF(vSerial = vSimplifiedSerial,
vCplusSimplifiedInvoiceTypeFk, vCplusSimplifiedInvoiceTypeFk,
vCplusStandardInvoiceTypeFk)) vCplusStandardInvoiceTypeFk)),
FROM client a.customsAgentFk
WHERE id = vClientFk; FROM client c

no de debe de coger del defaultAddressFk del cliente, se debería de coger del addres de los tickets a facturar

no de debe de coger del defaultAddressFk del cliente, se debería de coger del addres de los tickets a facturar
JOIN address a ON a.id = c.defaultAddressFk
WHERE c.id = vClientFk;
SET vNewInvoiceId = LAST_INSERT_ID(); SET vNewInvoiceId = LAST_INSERT_ID();

Si se va a guardar el customsAgentFk en la factura se deben de cambiar las consultas de los informes(report) de facturas

Si se va a guardar el customsAgentFk en la factura se deben de cambiar las consultas de los informes(report) de facturas