Compare commits

...

5 Commits

Author SHA1 Message Date
Robert Ferrús 5f12e498d5 Merge pull request 'fix: riesgos' (!2225) from hotFixCompany_getSuppliersDebt into master
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #2225
Reviewed-by: Carlos Andrés <carlosap@verdnatura.es>
2024-03-28 14:10:44 +00:00
Robert Ferrús 9a7bcdf104 fix: company_getSuppliersDebt
gitea/salix/pipeline/pr-master This commit looks good Details
2024-03-28 13:26:09 +01:00
Robert Ferrús 1c18b09531 fix: company_getSuppliersDebt
gitea/salix/pipeline/pr-master This commit looks good Details
2024-03-28 10:47:47 +01:00
Robert Ferrús 063745167e fix: modificar company_getSuppliersDebt
gitea/salix/pipeline/pr-master This commit looks good Details
2024-03-28 10:30:41 +01:00
Robert Ferrús 1f819ab16a fix: riesgos
gitea/salix/pipeline/pr-master This commit looks good Details
2024-03-27 19:02:05 +01:00
1 changed files with 55 additions and 52 deletions

View File

@ -169,7 +169,7 @@ BEGIN
AND vp.supplierFk = rd.supplierFk AND vp.supplierFk = rd.supplierFk
AND vp.companyFk = rd.companyFk AND vp.companyFk = rd.companyFk
AND vp.currencyFk = rd.currencyFk AND vp.currencyFk = rd.currencyFk
WHERE vp.isPayment = FALSE; WHERE NOT vp.isPayment;
SELECT vp.expirationId, SELECT vp.expirationId,
vp.dated, vp.dated,
@ -183,12 +183,15 @@ BEGIN
vp.isPayment, vp.isPayment,
vp.isReconciled, vp.isReconciled,
vp.endingBalance, vp.endingBalance,
cr.amount clientRiskAmount cr.amount clientRiskAmount,
co.CEE
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
LEFT 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;