https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15165
Lari Taskula <[email protected]> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #50790|0 |1 is obsolete| | --- Comment #14 from Lari Taskula <[email protected]> --- Created attachment 52683 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=52683&action=edit Bug 15165 - Add API routes to pay accountlines PUT /accountlines/(:accountlines_id)/payment (pay towards accountline) PUT /accountlines/(:borrowernumber)/amountpayment (pay towards borrower) PUT /accountlines/(:accountlines_id)/partialpayment (pay accountline partially) Test plan: 1. Open a browser tab on Koha staff and log in (to create CGISESSID cookie). You should have permission updatecharges. 2. Create a fine to any patron and get the accountlines_id. 3. Send PUT request to http://yourlibrary/api/v1/accountlines/YYY/payment without body where YYY is the accountlines_id you created in step 2. 4. Check that the accountline that you created in step 2 is paid. 5. Create two payments with amount 5.00 (with no other outstanding payments) 6. Send PUT request to http://yourlibrary/api/v1/accountlines/ZZZ/amountpayment with body defined in definitions/partialpayAccountlineBody.json. Replace ZZZ with the borrowernumber that you created two fines to. Set amount to 10. 7. Check that the two accountlines are paid. 8. Repeat step 2. 9. Send PUT request to http://yourlibrary/api/v1/accountlines/YYY/partialpayment with body defined in definitions/partialpayAccountlineBody.json. Replace YYY with the accountlines_id you created in step 8. Set amount to half of the amount of fine you created in step 8. 10. Check that the fine is still outstanding with half of the original amount. 11. Run unit tests at t/db_dependent/api/v1/accountlines.t -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list [email protected] http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
