Add a reversed
flag to the posting_journal
and general_ledger
#7904
Labels
reversed
flag to the posting_journal
and general_ledger
#7904
Based on this comment: https://github.com/Third-Culture-Software/bhima/pull/7900/files#r1863945522
Some of our reports rely on filtering out transactions that have been reversed. To do that, we often need to JOIN the voucher, cash, and invoice tables with additional date filtering and check their
reversed
fields. Here are some examples:a. https://github.com/Third-Culture-Software/bhima/blob/master/server/controllers/finance/reports/configurable_analysis_report/index.js#L206
b. https://github.com/Third-Culture-Software/bhima/blob/master/server/controllers/finance/reports/configurable_analysis_report/index.js#L231
a. https://github.com/Third-Culture-Software/bhima/blob/master/server/controllers/finance/reports/analysis_auxiliary_cashboxes/index.js#L118
We might consider adding the
reversed
flag to theposting_journal
andgeneral_ledger
that will limit the JOINs from the journal. It would need to be updated when credit notes/reversals are created and deleted.I think this issue is relatively low priority since there are only two instances in the codebase, but it is something to keep in mind.
The text was updated successfully, but these errors were encountered: