From e9c799e94239f1e533eb075bc0a347138b32ae75 Mon Sep 17 00:00:00 2001 From: Agustin Moyano Date: Thu, 8 Oct 2020 11:35:14 -0300 Subject: [PATCH] Bug 23376: (follow-up) Fix subscription bug in orderreceive.tt When order has subscription, general order variable gets replaced by other order variable in FOR loop Signed-off-by: Jonathan Druart --- .../prog/en/modules/acqui/orderreceive.tt | 26 +++++++++---------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/orderreceive.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/orderreceive.tt index c18cefc43a..fcf1d6eee5 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/orderreceive.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/orderreceive.tt @@ -104,24 +104,24 @@ - [% FOR order IN orders %] + [% FOR suborder IN orders %] - [% IF order.invoice %] + [% IF suborder.invoice %] [% IF CAN_user_acquisition %] - - [% order.invoice.invoicenumber | html %] + + [% suborder.invoice.invoicenumber | html %] [% ELSE %] - [% order.invoice.invoicenumber | html %] + [% suborder.invoice.invoicenumber | html %] [% END %] [% END %] - [% order.ordernumber | html %] - [% order.basket.creationdate | $KohaDates%] - [% IF order.datereceived %][% order.datereceived | $KohaDates %][% END %] - [% order.quantityreceived | html %] + [% suborder.ordernumber | html %] + [% suborder.basket.creationdate | $KohaDates%] + [% IF suborder.datereceived %][% suborder.datereceived | $KohaDates %][% END %] + [% suborder.quantityreceived | html %] - [% SWITCH order.orderstatus %] + [% SWITCH suborder.orderstatus %] [%# FIXME We should only see/display Complete here, right? %] [% CASE 'new' %]New [% CASE 'ordered' %]Ordered @@ -131,12 +131,12 @@ [% END %] - [% IF order.datereceived %][%# FIXME Should only be true, right? %] + [% IF suborder.datereceived %][%# FIXME Should only be true, right? %] [%# FIXME What if unitprice has not been filled? %] - [% order.unitprice_tax_excluded * order.quantity | $Price %] / [% order.unitprice_tax_included * order.quantity | $Price %] + [% suborder.unitprice_tax_excluded * suborder.quantity | $Price %] / [% suborder.unitprice_tax_included * suborder.quantity | $Price %] [% END %] - [% order.order_internalnote | html %] + [% suborder.order_internalnote | html %] [% END %] -- 2.39.5