#7202 added new field in InvoiceOut module #3034
|
@ -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
|
||||||
|
|||||||
|
JOIN address a ON a.id = c.defaultAddressFk
|
||||||
|
WHERE c.id = vClientFk;
|
||||||
|
|
||||||
SET vNewInvoiceId = LAST_INSERT_ID();
|
SET vNewInvoiceId = LAST_INSERT_ID();
|
||||||
|
|
||||||
carlosap
commented
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
|
|||||||
|
|
Loading…
Reference in New Issue
no de debe de coger del defaultAddressFk del cliente, se debería de coger del addres de los tickets a facturar