From 236260613e0324fd5924e1d6a1f30bde4d1fc81e Mon Sep 17 00:00:00 2001 From: Katrin Fischer Date: Sun, 18 Oct 2020 22:53:53 +0000 Subject: [PATCH] Bug 6819: Hide individual cancel order links when order line has been received MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This is to prevent mistakes - a received order should not be cancelled, but 'undo receive' needs to be done first for things to turn out correctly. To test: - Create a basket with at least 2 orders - Close basket - Receive one of your orders at least - Go back to the basket - Reopen basket - The cancel links should only show on the "not received" orders Signed-off-by: Séverine QUEUNE Signed-off-by: Martin Renvoize --- .../prog/en/modules/acqui/basket.tt | 44 ++++++++++--------- 1 file changed, 23 insertions(+), 21 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt index 651a232162..3eb48e2ab2 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt @@ -558,27 +558,29 @@ [% END %] - [% IF ( books_loo.left_holds_on_order ) %] - Can't cancel order
- [% ELSE %] - Cancel order
- [% END %] - [% IF ( books_loo.can_del_bib ) %] - Cancel order and delete catalog record
- [% ELSE %] - Can't cancel order and delete catalog record
- [% END %] - [% IF ( books_loo.left_item ) %] - [% books_loo.items | html %] item(s) left
- [% END %] - [% IF ( books_loo.left_biblio ) %] - [% books_loo.biblios | html %] order(s) left
- [% END %] - [% IF ( books_loo.left_subscription ) %] - [% books_loo.subscriptions | html %] subscription(s) left
- [% END %] - [% IF ( books_loo.left_holds ) %] - [% books_loo.holds | html %] hold(s) left + [% IF ( books_loo.orderstatus != "complete") %] + [% IF ( books_loo.left_holds_on_order ) %] + Can't cancel order
+ [% ELSE %] + Cancel order
+ [% END %] + [% IF ( books_loo.can_del_bib ) %] + Cancel order and delete catalog record
+ [% ELSE %] + Can't cancel order and delete catalog record
+ [% END %] + [% IF ( books_loo.left_item ) %] + [% books_loo.items | html %] item(s) left
+ [% END %] + [% IF ( books_loo.left_biblio ) %] + [% books_loo.biblios | html %] order(s) left
+ [% END %] + [% IF ( books_loo.left_subscription ) %] + [% books_loo.subscriptions | html %] subscription(s) left
+ [% END %] + [% IF ( books_loo.left_holds ) %] + [% books_loo.holds | html %] hold(s) left + [% END %] [% END %] [% END %] -- 2.20.1