@@ -, +, @@ - delete warns - add a missing } - add a condition in template of avoiding asking to suppress orders or records if the basket is void --- acqui/basket.pl | 4 +- .../intranet-tmpl/prog/en/modules/acqui/basket.tt | 40 ++++++++++++-------- 2 files changed, 26 insertions(+), 18 deletions(-) --- a/acqui/basket.pl +++ a/acqui/basket.pl @@ -102,7 +102,6 @@ if ( $op eq 'delete_confirm' ) { #Delete all orders included in that basket, and all items received. foreach my $myorder (@orders){ DelOrder($myorder->{biblionumber},$myorder->{ordernumber}); - warn "suppression de ".$myorder->{biblionumber}.' '.$myorder->{ordernumber}; } # if $delbiblio = 1, delete the records if possible if ((defined $delbiblio)and ($delbiblio ==1)){ @@ -113,9 +112,8 @@ if ( $op eq 'delete_confirm' ) { my @subscriptions = GetSubscriptionsId ($biblionumber); my $itemcount = GetItemsCount($biblionumber); DelBiblio($myorder->{biblionumber}) if ($countbiblio == 0 && $itemcount == 0 && !(@subscriptions)); - warn "suppression de la notice ".$myorder->{biblionumber}}; + } } - # delete the basket DelBasket($basketno,); $template->param( delete_confirmed => 1 ); --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt +++ a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt @@ -153,26 +153,36 @@ [% END %]
- + + [% UNLESS book_foot_loop.size > 0 %] +Are you sure you want to delete this basket?
+Are you sure you want to delete this basket?
+Warning:
+All orders of this basket will be cancelled and used funds will be refunded.
+If items have been created when ordering or receiving, they will be deleted.
+You can choose to delete records if possible (if they don't have any item attached, any subscription and are not used in any other order).
+