https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40871 --- Comment #11 from Martin Renvoize (ashimema) <martin.renvoize@openfifth.co.uk> --- I have reworked this against current main. Summary of what I found and what I did. Why this failed QA: the first patch (192331) is titled as a change to outstanding_accountlines, but the hunk is in Koha::Cash::Register->cashups. That method searches cash_register_actions, which has no status or debit_type_code columns, so with the patch applied every call dies with "Unknown column 'debit_type_code' in 'WHERE'". That is the 500 David saw in comment 4, and it also makes most of t/db_dependent/Koha/Cash/Register.t fail (8 of its 12 subtests). The patch does not change the bankable amount. The second patch (192332) no longer applies to current main, because Cashup::summary has since gained the CASHUP_DEFICIT and CASHUP_SURPLUS conditions. I have rebased it, merging both sets of conditions. I have added a follow-up on top of the two patches. It: - removes the filter from cashups() - applies it in outstanding_accountlines, so voided payments are left out of the transactions list, the bankable amount, the cashup totals and the expected amount for a cashup - adds Koha::Cash::Register->voided_accountlines, and on pos/register.pl a collapsed "Voided transactions (N)" section under both the current and the older transactions, so voided payments stay reachable - leaves voided payments out of the "Older transactions" list and total A void only happens before the money is banked, so excluding voids from the live figures and from the summary of a completed cashup cannot change what was reconciled. This also covers the "total income" concern in comment 7: voided payments are no longer in that total, and they are listed separately. Test plan is in the follow-up commit message. Two payments of 10.00 with one voided give a bankable amount of 10.00, and a cashup of 10.00 balances. Comment 5 (a voided card payment shown in the summary) should be covered by the second patch, but I have not tested it. -- You are receiving this mail because: You are watching all bug changes.