~inddiana/sisb/sisb_fix_invoice_islr

« back to all changes in this revision

Viewing changes to l10n_ve_account_financial_report/report/account_mayor_analitico.py


[FIX] se valida que el debito y credito sean 0 en caso de ser nulos.

Show diffs side-by-side

added added

removed removed

Lines of Context:
194
194
                    case when tbl.debit is null and tbl.credit is null then 0 else tbl.debit-tbl.credit end as balance
195
195
                FROM account_account aa
196
196
                LEFT OUTER JOIN (
197
 
                    SELECT aml.account_id, sum(aml.debit) as debit, sum(aml.credit) as credit
 
197
                    SELECT aml.account_id, sum(COALESCE(aml.debit, 0.00)) as debit, sum(COALESCE(aml.credit, 0.00)) as credit
198
198
                    FROM account_move_line aml
199
199
                    WHERE %s
200
200
                    GROUP BY aml.account_id) tbl on aa.id = tbl.account_id