Omnibus for the plumbing part of the GST / VAT rewrite. This is the preparation step before the rewrite. Some inconsistencies need to be fixed.
Created attachment 31161 [details] [review] Bug 12827: NewOrder should not return basketno Since the basketno parameter is needed to insert an order, it is useless to return it. This patch changes the prototype for the C4::Acquisition::NewOrder subroutine. The return value is now a scalar containing the ordernumber created.
Created attachment 31162 [details] [review] Bug 12827: NewOrder needs more unit tests NewOrder should be more tested! This patch moves the existing unit tests into a new file and adds some unit tests. Note that there is no DB field aqorders.subscription, so the test in NewOrder can be removed. Test plan: prove t/db_dependent/Acquisition/NewOrder.t and prove t/db_dependent/Acquisition.t should return green.
These 2 patches should have been submitted on bug 12827...
I would like to refactor some codes related to order and bookseller. It would be great to move this related code from C4::Acquisition to Koha::Acquisition::* A POC is available on bug 12830. Some plumbing patches will be marked as depend on this bug. The goal is to refactor/clean/add unit tests without adding any regression/functionality. Like that, no need to wait for the entire feature (bug 12825) to start to push patches into master.
The plumbing is done!