Koha/koha-tmpl/intranet-tmpl/prog/en/includes/catalog-strings.inc
Marcel de Rooy 21c87aeb15
Bug 36018: biblio->active_orders should be ->uncancelled_orders
Active orders are more than just not cancelled. See filter_by_active
in Koha::Acquisition::Orders. They are still in the acq process; we
still need to receive items on those orders.

When we cancel and want to delete a biblio, we should check for not
cancelled orders (broader than active orders as in Orders.pm).

Test plan:
Git grep active_orders.
Run t/db_dependent/Koha/Biblio.t
Run t/db_dependent/Koha/Acquisition/Order.t
Add two order lines in a basket referring to same biblio. Try to
cancel with delete biblio. Should not be possible.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Janusz Kaczmarek <januszop@gmail.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 16:45:46 +02:00

25 lines
1 KiB
PHP

[% USE Context %]
<!-- catalog-strings.inc -->
<script>
/* Some required variables from the template */
var biblionumber = [% biblionumber | html %];
var count = [% count || 0 | html %];
var holdcount = [% holdcount || 0 | html %];
[% SET orders = biblio.orders %]
[% SET current = Context.Scalar(orders, "filter_out_cancelled") %]
[% SET cancelled = Context.Scalar(orders, "filter_by_cancelled") %]
var countorders = [% current.count || 0 | html %];
var countdeletedorders = [% cancelled.count || 0 | html %];
var subscriptionscount = [% biblio.subscriptions.count || 0 | html %];
var searchid = '[% searchid | html %]';
/* provide Z3950 search points */
function GetZ3950Terms(){
var strQuery="&frameworkcode=";
[% FOREACH z3950_search_param IN z3950_search_params %]
strQuery += "&" + "[% z3950_search_param.name |uri %]" + "=" + "[% z3950_search_param.value |uri %]";
[% END %]
return strQuery;
}
</script>
<!-- / catalog-strings.inc -->