fix: modificar company_getSuppliersDebt
gitea/salix/pipeline/pr-master This commit looks good
Details
gitea/salix/pipeline/pr-master This commit looks good
Details
This commit is contained in:
parent
1f819ab16a
commit
063745167e
|
@ -187,8 +187,10 @@ BEGIN
|
||||||
FROM tPendingDuedates vp
|
FROM tPendingDuedates vp
|
||||||
LEFT JOIN supplier s ON s.id = vp.supplierFk
|
LEFT JOIN supplier s ON s.id = vp.supplierFk
|
||||||
LEFT JOIN client c ON c.fi = s.nif
|
LEFT JOIN client c ON c.fi = s.nif
|
||||||
JOIN clientRisk cr ON cr.clientFk = c.id
|
JOIN clientRisk cr ON cr.clientFk = c.id AND cr.companyFk = vp.companyFk
|
||||||
AND cr.companyFk = vp.companyFk;
|
LEFT JOIN supplierAccount sa ON sa.supplierFk = s.id
|
||||||
|
LEFT JOIN bankEntity be ON be.id = sa.bankEntityFk
|
||||||
|
LEFT JOIN country co ON co.id = be.countryFk;
|
||||||
|
|
||||||
DROP TEMPORARY TABLE tOpeningBalances;
|
DROP TEMPORARY TABLE tOpeningBalances;
|
||||||
DROP TEMPORARY TABLE tPendingDuedates;
|
DROP TEMPORARY TABLE tPendingDuedates;
|
||||||
|
|
Loading…
Reference in New Issue