From 38ef9e2947afb2afe9291140a4056d5d1d0c14d9 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 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 --- acqui/invoice.pl | 4 ++-- 1 file changed, 2 insertions(+), 2 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 ); -- 1.7.10.4