From 8af58bc399b288c4199f1622637646f8e6653371 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc=20V=C3=A9ron?= Date: Tue, 15 Dec 2015 15:14:47 +0100 Subject: [PATCH] Bug 15376: Edit invoices: Can not change Shipping cost MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit To reproduce: - Go to Home > Acquisitions - Edit an invoice that has no shipping date - Change shipment cost. Leave shipping date empty - Save Result: Page reloads, shipment cost keeps old value. Warnings in intranet-error.log To test: - Apply patch - Follow steps above Result: Shipment costs are changed as expected No warnings in intrante-error.log Additionally, verify that the input field 'Shipping cost' is properly formatted and that in invoice details 'Shipment cost' is replaced by 'Shipping cost' Signed-off-by: Frédéric Demians Confirm bug and solution --- acqui/invoice.pl | 4 ++-- koha-tmpl/intranet-tmpl/prog/en/modules/acqui/invoice.tt | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/acqui/invoice.pl b/acqui/invoice.pl index f56afcc..05b3689 100755 --- a/acqui/invoice.pl +++ b/acqui/invoice.pl @@ -81,8 +81,8 @@ elsif ( $op && $op eq 'mod' ) { my $shipment_budget_id = $input->param('shipment_budget_id'); ModInvoice( invoiceid => $invoiceid, - shipmentdate => output_pref( { str => $input->param('shipmentdate'), dateformat => 'iso', dateonly => 1 } ), - billingdate => output_pref( { str => $input->param('billingdate'), dateformat => 'iso', dateonly => 1 } ), + shipmentdate => output_pref( { str => $input->param('shipmentdate'), dateformat => 'iso', dateonly => 1 } ) || '', + billingdate => output_pref( { str => $input->param('billingdate'), dateformat => 'iso', dateonly => 1 } ) || '', shipmentcost => $shipmentcost, shipmentcost_budgetid => $shipment_budget_id ); diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/invoice.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/invoice.tt index 6a0c9cf..71cacfb 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/invoice.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/invoice.tt @@ -80,7 +80,7 @@
  • -
  • +