[Koha-bugs] [Bug 21969] Koha::Account->outstanding_* should look for debits/credits by checking 'amount'

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Mon Dec 10 13:15:58 CET 2018


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21969

Martin Renvoize <martin.renvoize at ptfs-europe.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #82940|0                           |1
        is obsolete|                            |

--- Comment #4 from Martin Renvoize <martin.renvoize at ptfs-europe.com> ---
Created attachment 83012
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=83012&action=edit
Bug 21969: Fix Koha::Account->outstanding_* matching the opposite on
pathological cases

This patch makes outstanding_* methods be safe regarding pathological
account lines that get converted into another type because of the value
of amountoutstanding

To test:
- Run:
  $ kshell
 k$ prove t/db_dependent/Koha/Account.t
=> FAIL: Tests fail because pathological account lines are wrongly
picked.
- Apply this patch
- Run:
 k$ prove t/db_dependent/Koha/Account.t
=>SUCCESS: All green!

Signed-off-by: Martin Renvoize <martin.renvoize at ptfs-europe.com>

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list