Koha/acqui
Alex Buckley 7b66b90fe7 Bug 25750: fix fallback to ecost_tax_included/ecost_tax_excluded
If 'Actual cost' has not been set then it has the value of 0.00 which
Perl evaluates to true so this patchset resets it to 0, so the fallback
to ecost_tax_included/ecost_tax_excluded happens.

Test plan:
1. Add item to acquisition basket (make sure the vendor has: tax rate: 15%, 'List prices: Include tax', 'Invoice prices: Include tax')
2. Set 'Vendor price' = 10 and do not set 'Actual cost'
3. Save order
4. Observe basket.pl shows 'Total tax exc.' has a value of 0.00 and GST
column has value of -8.70

5. Jump into the database:
select tax_value_on_ordering from aqorders where
ordernumber=<ordernumber>;
[You can get the ordernumber from clicking on the 'Modify' line the item
is listed in]
6. Observe a negative value: -8.70

7. Apply patch and restart plack
8. Add a second item to the basket
9. Set 'Vendor price' = 10 and don't set 'Actual cost'
10. Save order
11. Observe basket.pl shows 'Total tax exc' has value of 8.70 and GST
has value of 1.30
12. Repeat step 5 and observe tax_value_on_ordering = 1.30
13. Run t/Prices.t unit test:
sudo koha-shell <instancename>
prove t/Prices.t

Sponsored-by: Horowhenua District Council, NZ

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2020-07-09 11:50:42 +02:00
..
acqui-home.pl
add_user_search.pl
addorder.pl Bug 24347: (follow-up) Remove custom catalog search from acquisitions 2020-01-30 10:59:27 +00:00
addorderiso2709.pl Bug 23463: Replace AddItem calls with Koha::Item->store 2020-03-23 09:26:26 +00:00
ajax-getauthvaluedropbox.pl
basket.pl Bug 25750: fix fallback to ecost_tax_included/ecost_tax_excluded 2020-07-09 11:50:42 +02:00
basketgroup.pl Bug 9993: On editing basket group delivery place resets to logged in branch 2020-02-04 10:21:38 +00:00
basketheader.pl Bug 25611: Use selected vendor when creating a basket 2020-06-24 14:31:37 +02:00
booksellers.pl Bug 19809: Re-allow to call Koha::Objects::find in list context 2020-01-23 10:27:28 +00:00
cancelorder.pl
check_budget_total.pl
check_uniqueness.pl Bug 23463: Replace SearchItemsByField by SearchItems 2020-03-23 09:26:09 +00:00
duplicate_orders.pl Bug 24733: created_by param should be an arrayref 2020-02-26 20:38:46 +00:00
edi_ean.pl Bug 24545: Fix license statements 2020-02-24 13:31:26 +00:00
edifactmsgs.pl Bug 24545: Fix license statements 2020-02-24 13:31:26 +00:00
edimsg.pl Bug 24545: Fix license statements 2020-02-24 13:31:26 +00:00
finishreceive.pl Bug 23596: Edit suggestion's reason when receiving 2020-04-14 16:30:16 +01:00
histsearch.pl
invoice-files.pl
invoice.pl
invoices.pl
lateorders-export.pl Bug 24163: UTF-8 encode the output 2020-05-05 11:08:44 +01:00
lateorders.pl Bug 25266: Remove uneeded var 2020-06-15 10:32:20 +02:00
modordernotes.pl
neworderempty.pl Bug 25599: Fix default value placeholders for UseACQFrameworkForBiblioRecords 2020-06-15 10:30:13 +02:00
newordersubscription.pl
newordersuggestion.pl
ordered.pl Bug 25223: Make join of aqbasket and aqorders explicit 2020-04-22 09:29:13 +01:00
orderreceive.pl Bug 23596: Edit suggestion's reason when receiving 2020-04-14 16:30:16 +01:00
parcel.pl Bug 24672: (bug 24430 follow-up) Do not get active orders on deleted biblio record 2020-03-24 09:31:34 +00:00
parcels.pl
showorder.pl Bug 24545: Fix license statements 2020-02-24 13:31:26 +00:00
spent.pl
supplier.pl
transferorder.pl
uncertainprice.pl Bug 18177: remove aqbooksellers.booksellerurl 2020-03-27 12:15:47 +00:00
updatesupplier.pl
z3950_search.pl Bug 21921: Add date publication year to biblio Z39.50 search form in acquisition 2020-02-17 13:44:34 +00:00