6 [% PROCESS 'i18n.inc' %]
8 [% INCLUDE 'doc-head-open.inc' %]
9 <title>[% FILTER collapse %]
10 [% IF ( invoiceclosedate ) %]
12 [% tx("Receipt summary for {vendor}, invoice {invoice_number}", { vendor = name, invoice_number = invoice }) | html %]
14 [% tx("Receipt summary for {vendor}", { vendor = name }) | html %]
17 [% tx("Receive orders from {vendor}", { vendor = name }) | html %]
19 [% t("Acquisitions") | html %] ›
20 [% t("Koha") | html %]
22 [% INCLUDE 'doc-head-close.inc' %]
25 <body id="acq_parcel" class="acq">
26 [% WRAPPER 'header.inc' %]
27 [% INCLUDE 'acquisitions-search.inc' %]
30 [% WRAPPER 'sub-header.inc' %]
31 [% WRAPPER breadcrumbs %]
32 [% WRAPPER breadcrumb_item %]
33 <a href="/cgi-bin/koha/acqui/acqui-home.pl">Acquisitions</a>
35 [% IF invoiceclosedate %]
36 [% WRAPPER breadcrumb_item bc_active= 1 %]
38 <span>Receipt summary for <em>[% name | html %] [ [% invoice | html %] ]</em></span>
40 <span>Receipt summary for <em>[% name | html %]</em></span>
44 [% WRAPPER breadcrumb_item %]
45 <a href="/cgi-bin/koha/acqui/supplier.pl?booksellerid=[% booksellerid | uri %]">[% name | html %]</a>
47 [% WRAPPER breadcrumb_item bc_active= 1 %]
48 <span>Receive orders from [% name | html %]</span>
51 [% END #/ WRAPPER breadcrumbs %]
52 [% END #/ WRAPPER sub-header.inc %]
54 <div class="main container-fluid">
56 <div class="col-sm-10 col-sm-push-2">
59 [% IF ( receive_error ) %]
60 <div class="dialog alert">
61 <h3>Error adding items:</h3>
63 [% FOREACH error_loo IN error_loop %]
64 <li>[% error_loo.error_param | html %][% IF ( error_loo.error_duplicate_barcode ) %]Duplicate barcode[% END %] <!-- todo: other error conditions come here. --></li>
70 [% IF ( invoiceclosedate ) %]
71 <span>Receipt summary for <em>[% name | html %]</em></span> [% IF ( invoice ) %] <em> [ [% invoice | html %] ] </em>[% END %]
73 <span>Receive orders from [% name | html %]</span>
77 [% IF ( success_delorder ) %]
78 <div class="dialog message">The order has been successfully canceled.</div>
80 [% IF ( error_delitem ) %]
81 <div class="dialog alert">The order has been canceled, although one or more items could not have been deleted.</div>
83 [% IF ( error_delbiblio ) %]
84 <div class="dialog alert">The order has been canceled, although the record has not been deleted.</div>
88 [% IF (error_cancelling_receipt) %]
89 <div class="dialog alert">
90 <span>Cannot cancel receipt. Possible reasons:</span>
93 The order line you are trying to cancel was created from a partial receipt
94 of another order line which is already received. Try to cancel this
98 The order line you are trying to cancel was created from a partial receipt
99 of another order line which has been deleted. Cancellation is not
106 [% IF error_invoice_not_known %]
107 <div class="dialog alert">
108 The invoice referenced by this invoiceid does not exist.
112 [% UNLESS no_orders_to_display %]
113 <div id="acqui_receive_summary">
114 <p><strong>Invoice number:</strong> [% invoice | html %] <strong>Shipment date:</strong> [% shipmentdate | $KohaDates %]</p>
116 [% UNLESS (invoiceclosedate) %]
117 <div id="acqui_receive_search" class="page-section">
118 <h3>Pending orders</h3>
119 <table id="pending_orders" class="table table-bordered table-striped">
124 <th>Basket group</th>
128 <th>Replacement price</th>
138 <fieldset class="action">
139 <button id="select_multiple" class="btn btn-primary"></button>
144 <span>Invoice is closed, so you can't receive orders anymore.</span>
145 [% IF CAN_user_acquisition_reopen_closed_invoices %]
146 <a href="/cgi-bin/koha/acqui/invoice.pl?op=reopen&invoiceid=[% invoiceid | uri %]&referer=/cgi-bin/koha/acqui/parcel.pl%3Finvoiceid=[% invoiceid | uri %]">Reopen it</a>.
151 <div id="acqui_receive_receivelist" class="page-section">
152 <h3>Already received</h3>
154 [% IF ( loop_received ) %]
155 <form action="/cgi-bin/koha/acqui/parcel.pl" method="get" name="orderform">
156 <table id="receivedt">
160 <th>Basket group</th>
162 <th title="Item holds / Total holds">Holds</th>
165 <th>Replacement price</th>
175 [% FOREACH key IN subtotal_for_funds.keys.sort %]
177 [% IF invoiceincgst %]
178 <td colspan="6" class="total">(Tax inc.)</td>
180 <td colspan="6" class="total">(Tax exc.)</td>
182 <td colspan="3"><em>Subtotal for</em> [% key | html %]</td>
183 <td>[% subtotal_for_funds.$key.ecost | $Price %]</td>
184 <td>[% subtotal_for_funds.$key.unitprice | $Price %]</td>
190 <th colspan="11" class="total">Total tax exc.</th>
191 <th>[% total_tax_excluded | $Price %]</th>
194 [% FOREACH book_foot IN book_foot_loop %]
196 <th colspan="11">Total (GST [% book_foot.tax_rate * 100 | html %]%)</th>
197 <th>[% book_foot.tax_value | $Price %]</th>
202 <th colspan="11" class="total">Total tax inc.</th>
203 <th>[% total_tax_included | $Price %]</th>
207 <tbody class="filterclass">
208 [% FOREACH order IN loop_received %]
210 <td><a href="/cgi-bin/koha/acqui/basket.pl?basketno=[% order.basketno | uri %]"> [% order.basketname | html %] ([% order.basketno | html %])</a></td>
212 [% IF order.basketgroupid %]
213 <a href="/cgi-bin/koha/acqui/basketgroup.pl?op=add&booksellerid=[% booksellerid | uri %]">[% order.basketgroupname | html %] ([% order.basketgroupid | html %])</a>
219 <a href="neworderempty.pl?ordernumber=[% order.ordernumber | uri %]&booksellerid=[% booksellerid | uri %]">[% order.ordernumber | html %]</a>
220 [% IF (order.parent_ordernumber && (order.parent_ordernumber != order.ordernumber)) %]
221 (<a href="neworderempty.pl?ordernumber=[% order.parent_ordernumber | uri %]&booksellerid=[% booksellerid | uri %]" title="Original order line">[% order.parent_ordernumber | html %]</a>)
225 [% IF order.total_holds > 0 %]
226 [% IF order.item_holds > 0 %]
227 <span class="error"><a href="/cgi-bin/koha/reserve/request.pl?biblionumber=[% order.biblionumber | uri %]">[% order.item_holds | html %]</a></span>
232 <span class="error"><a href="/cgi-bin/koha/reserve/request.pl?biblionumber=[% order.biblionumber | uri %]">[% order.total_holds | html %]</a></span>
238 [% INCLUDE 'biblio-title.inc' biblio=order link = 1 %]
239 [% IF ( order.author ) %] / [% order.author | html %][% END %]
240 [% IF ( order.isbn ) %] - [% order.isbn | html %][% END %]
241 [% IF ( order.publishercode ) %]
242 <br />Publisher: [% order.publishercode | html %]
243 [%- IF ( order.publicationyear > 0) -%], [% order.publicationyear | html %]
244 [%- ELSIF ( order.copyrightdate > 0) -%] [% order.copyrightdate | html %]
247 [% IF ( order.suggestionid ) %]
249 Suggested by: [% order.surnamesuggestedby | html %][% IF ( order.firstnamesuggestedby ) %], [% order.firstnamesuggestedby | html %] [% END %]
250 (<a href="/cgi-bin/koha/suggestion/suggestion.pl?suggestionid=[% order.suggestionid | uri %]&op=show">suggestion #[% order.suggestionid | html %]</a>)
253 [% IF ( order.order_internalnote ) %]
254 <p class="ordernote"><strong>Internal note: </strong>[% order.order_internalnote | html %] [<a href="/cgi-bin/koha/acqui/modordernotes.pl?ordernumber=[% order.ordernumber | uri %]&referrer=/cgi-bin/koha/acqui/parcel.pl%3Finvoiceid=[% invoiceid | uri %]&type=internal">Change internal note</a>]</p>
256 [<a href="/cgi-bin/koha/acqui/modordernotes.pl?ordernumber=[% order.ordernumber | uri %]&referrer=/cgi-bin/koha/acqui/parcel.pl%3Finvoiceid=[% invoiceid | uri %]&type=internal">Add internal note</a>]
258 [% IF ( order.order_vendornote ) %]
259 <p class="ordernote"><strong>Vendor note: </strong>[% order.order_vendornote | html %]</p>
261 [<a href="/cgi-bin/koha/acqui/modordernotes.pl?ordernumber=[% order.ordernumber | uri %]&referrer=/cgi-bin/koha/acqui/parcel.pl%3Finvoiceid=[% invoiceid | uri %]&type=vendor">Add vendor note</a>]
265 <a href="/cgi-bin/koha/acqui/showorder.pl?ordernumber=[% order.ordernumber | uri %]" class="previewData">[% tp('noun', 'Order') | html %]</a><br>
266 <a href="/cgi-bin/koha/catalogue/showmarc.pl?id=[% order.biblionumber | uri %]" class="previewData">MARC</a><br>
267 <a href="/cgi-bin/koha/catalogue/showmarc.pl?viewas=card&id=[% order.biblionumber | uri %]" class="previewData">Card</a>
269 <td>[% order.replacementprice | $Price %]</td>
270 <td>[% order.quantityreceived | html %]</td>
271 <td>[% order.budget.budget_name | html %]</td>
272 <td>[% order.ecost | $Price %]</td>
273 <td>[% order.unitprice | $Price %]</td>
274 <td>[% order.total | $Price %]</td>
276 [% IF loop_receive.cannot_cancel or ( order.basket.effective_create_items == "receiving" and loop_receive.holds > 0 ) %]
277 [% IF loop_receive.cannot_cancel %]
278 [% span_title = BLOCK %]
279 <span>Cannot cancel receipt of this order line because it
280 was created from a partial receipt of order line no.
281 [% order.parent_ordernumber | html %], which is
282 already received. Try cancelling this one first and
286 [%# FIXME Here we block the cancellation if holds exist. Actually it could be possible if items will be exist after the deletion %]
287 [%# Some additional checks should be added in the pl file %]
288 [% span_title = BLOCK %]
289 <span>Cannot cancel receipt of this order line because at least one hold exists on the records.</span>
292 <span title="[% span_title | collapse | html %]">
296 <a href="/cgi-bin/koha/acqui/parcel.pl?invoiceid=[% invoiceid | uri %]&op=cancelreceipt&ordernumber=[% order.ordernumber | uri %]">Cancel receipt</a>
305 [% ELSE %]There are no received orders.[% END %]
308 <div class="modal" id="dataPreview" tabindex="-1" role="dialog" aria-labelledby="dataPreviewLabel">
309 <div class="modal-dialog modal-wide" role="document">
310 <div class="modal-content">
311 <div class="modal-header">
312 <button type="button" class="closebtn" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
313 <h3 id="dataPreviewLabel">MARC previews</h3>
315 <div class="modal-body">
316 <div id="loading"> <img src="[% interface | html %]/[% theme | html %]/img/spinner-small.gif" alt="" /> Loading </div>
318 <div class="modal-footer">
319 <button class="btn btn-default" data-dismiss="modal" aria-hidden="true">Close</button>
321 </div> <!-- /.modal-content -->
322 </div> <!-- /.modal-dialog -->
323 </div> <!-- /.modal -->
325 [% IF (invoiceclosedate) %]
326 <a href="/cgi-bin/koha/acqui/invoice.pl?invoiceid=[% invoiceid | uri %]">View invoice</a>
328 <form action="/cgi-bin/koha/acqui/invoice.pl" method="get">
329 <input type="hidden" name="invoiceid" value="[% invoiceid | html %]" />
330 <fieldset class="action">
331 <input type="submit" class="btn btn-primary" value="Finish receiving" />
339 </div> <!-- /.col-sm-10.col-sm-push-2 -->
341 <div class="col-sm-2 col-sm-pull-10">
344 [% INCLUDE 'acquisitions-menu.inc' %]
346 </div> <!-- /.col-sm-2.col-sm-pull-10 -->
347 </div> <!-- /.row -->
349 [% MACRO jsinclude BLOCK %]
350 [% Asset.js("js/acquisitions-menu.js") | $raw %]
351 [% INCLUDE 'datatables.inc' %]
352 [% Asset.js("lib/jquery/plugins/jquery.dataTables.columnFilter.js") | $raw %]
353 <style>fieldset.action { margin-bottom: 20px }</style>
355 dt_overwrite_html_sorting_localeCompare();
356 var PENDING_MULTI_SELECTION = _("Receive selected (%s)");
357 var columns_filter = {};
359 $(document).ready(function(){
361 if ( $("#receivedt").length ) {
362 var receivedt = $("#receivedt").dataTable($.extend(true, {}, dataTablesDefaults, {
365 "lengthMenu": [[5, 10, 20, 50, 100, -1], [5, 10, 20, 50, 100, _("All")]],
367 { "targets": [ 5, -1 ], "orderable": false, "searchable": false },
373 { "type": "num-html" },
374 { "type": "anti-the" },
390 "url": '/api/v1/acquisitions/orders?only_active=1'
393 "basket.basket_group",
394 "biblio.active_orders+count",
395 "biblio.holds+count",
396 "biblio.items+count",
397 "biblio.suggestions.suggester",
399 "current_item_level_holds+count",
402 "stateSave": true, // remember state on page reload
403 "drawCallback": function (settings) {
404 $(".previewData").on("click", function(e){
406 var ltitle = $(this).text();
407 var page = $(this).attr("href");
408 $("#dataPreviewLabel").text(ltitle);
409 $("#dataPreview .modal-body").load(page + " div");
410 $('#dataPreview').modal({show:true});
414 { "data": "basket.name",
417 "render": function(data, type, row, meta) {
418 if (type != 'display') return escape_str(data);
419 return "<a href=\"/cgi-bin/koha/acqui/basket.pl?basketno=" + encodeURIComponent(row.basket.basket_id) + "\">" + escape_str(data) + " (" + escape_str(row.basket.basket_id) + ")</a>";
422 { "data": "basket.basket_group.name",
424 "render": function(data, type, row, meta) {
425 if ( type != 'display' ) {
426 return escape_str(data);
428 if ( row.basket.basket_group_id == null ) {
429 return _("No basket group");
432 return "<a href=\"/cgi-bin/koha/acqui/basketgroup.pl?op=add&booksellerid="
433 + encodeURIComponent(row.basket.vendor_id) + "&basketgroupid="
434 + encodeURIComponent(row.basket.basket_group_id) + "\">"
435 + escape_str(row.basket.basket_group.name) + " (" + escape_str(row.basket.basket_group_id) + ")</a>";
441 "render": function(data, type, row, meta) {
442 if (type != 'display') return escape_str(data);
443 return "<a href=\"neworderempty.pl?ordernumber="+encodeURIComponent(data)+"&booksellerid="+encodeURIComponent(row.basket.vendor_id)+"\">"+escape_str(data)+"</a>";
447 [% SET summary_fields = "biblio.title:biblio.author:biblio.isbn:biblio.publisher:me.internal_note:me.vendor_note" %]
448 [% IF Koha.Preference('marcflavour')=='UNIMARC' %][% SET summary_fields = summary_fields _ ":biblio.ean" %][% END %]
449 "data": "[% summary_fields | html %]",
450 "render": function(data, type, row, meta) {
452 if ( row && row.biblio_id != null ) {
453 result = "<p><a href=\"/cgi-bin/koha/catalogue/detail.pl?biblionumber="+encodeURIComponent(row.biblio_id)+"\">"+escape_str(row.biblio.title)+"</a>";
454 if ( row.biblio.author != null )
455 result += _(" by ") + escape_str(row.biblio.author);
456 if ( row.biblio.isbn != null )
457 result += " – " + escape_str(row.biblio.isbn);
458 [% IF Koha.Preference('marcflavour')=='UNIMARC' %]
459 if ( row.biblio.ean != null )
460 result += " – EAN:" + escape_str(row.biblio.ean);
462 if ( row.biblio.publisher != null ) {
463 result += "<br/>" + _("Publisher: ") + escape_str(row.biblio.publisher);
464 if ( row.biblio.publication_year != null ) {
465 result += ", " + escape_str(row.biblio.publication_year);
467 else if ( row.biblio.copyright_date != null ) {
468 result += escape_str(row.biblio.copyright_date);
471 var suggestions = row.biblio.suggestions;
472 if ( suggestions != null && suggestions.length > 0 ) {
473 var suggestion = suggestions[0];
474 if ( suggestion.suggester != null ) {
475 var suggester = suggestion.suggester;
476 var suggested_by = [];
477 if ( suggester.surname != null ) {
478 suggested_by.push(escape_str(suggester.surname));
480 if ( suggester.firstname != null ) {
481 suggested_by.push(escape_str(suggester.firstname));
484 result += "<br/>" + _("Suggested by: ") +
485 '<a href="/cgi-bin/koha/suggestion/suggestion.pl?suggestionid='
486 + encodeURIComponent(suggestion.suggestionid)
488 + suggested_by.join(", ")
489 + " (#" + escape_str(suggestions[0].suggestionid) + ")</a>"; // FIXME: could be changed if we allow matching multiple suggestions
495 var internal_note = row.internal_note;
496 if ( internal_note != null && internal_note != '' ) {
497 result += '<p class="ordernote"><strong>'
498 + _("Internal note: ")
499 + '</strong>' + escape_str(internal_note)
500 + ' [<a href="/cgi-bin/koha/acqui/modordernotes.pl?ordernumber='
501 + encodeURIComponent(row.order_id) + '&referrer=/cgi-bin/koha/acqui/parcel.pl%3Finvoiceid=[% invoiceid | uri %]'
502 + '&type=internal">' + _("Change internal note") + '</a>]</p>';
505 result += ' [<a href="/cgi-bin/koha/acqui/modordernotes.pl?ordernumber='
506 + encodeURIComponent(row.order_id) + '&referrer=/cgi-bin/koha/acqui/parcel.pl%3Finvoiceid=[% invoiceid | uri %]'
507 + '&type=internal">' + _("Add internal note") + '</a>]';
510 var vendor_note = row.vendor_note;
511 if ( vendor_note != null && vendor_note != '' ) {
512 result += '<p class="ordernote"><strong>'
514 + '</strong>' + escape_str(vendor_note) + '</p>';
517 result += ' [<a href="/cgi-bin/koha/acqui/modordernotes.pl?ordernumber='
518 + encodeURIComponent(row.order_id) + '&referrer=/cgi-bin/koha/acqui/parcel.pl%3Finvoiceid=[% invoiceid | uri %]'
519 + '&type=vendor">' + _("Add vendor note") + '</a>]';
528 "render": function(data, type, row, meta) {
529 var result = '<div class="btn-group dropup">';
530 result += '<button id="view' + row.order_id + '" type="button" class="btn btn-default btn-xs" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">';
531 result += ' <i class="fa-solid fa-eye aria-hidden="true"></i> ' + _("View");
532 result += ' <span class="caret"></span> ';
533 result += '</button>';
534 result += '<ul class="dropdown-menu" aria-labelledby="view' + row.order_id + '">';
535 result += '<li><a href="/cgi-bin/koha/acqui/showorder.pl?ordernumber=' + encodeURIComponent(row.order_id) + '" class="previewData">[% tp("noun", "Order") | html %]</a></li>';
536 result += '<li><a href="/cgi-bin/koha/catalogue/showmarc.pl?id=' + encodeURIComponent(row.biblio_id) + '" class="previewData">' + _("MARC") + '</a></li>';
537 result += '<li><a href="/cgi-bin/koha/catalogue/showmarc.pl?viewas=card&id=' + encodeURIComponent(row.biblio_id) + '" class="previewData">' + _("Card") + '</a></li>';
546 "data": "replacement_price",
547 "render": function(data, type, row, meta) {
548 return escape_price(row.replacement_price);
557 "render": function(data, type, row, meta) {
558 return escape_price(row.ecost);
563 "render": function(data, type, row, meta) {
564 return escape_price(row.quantity * row.ecost);
566 "orderable": false, // FIXME: How can we do it in DBIC?
571 "render": function(data, type, row, meta) {
572 if (type != 'display') return escape_str(data);
573 return escape_str(row.fund.name);
578 "render": function(data, type, row, meta) {
579 return '<a href="orderreceive.pl?multiple_orders='
580 + encodeURIComponent(row.order_id) + '&invoiceid=[% invoiceid | uri %]' + '">'
581 + _("Receive") + '</a><br/>'
582 + '<a href="#" onclick="transfer_order_popup(' + escape_str(row.order_id) + '); return false;">'
583 + _("Transfer") + '</a>';
590 "render": function(data, type, row, meta) {
593 if ( row.current_holds_count > 0 ) {
594 result += '<span class="button" title="'
595 + _("Can't cancel order, (%s) holds are linked with this order. Cancel holds first").format( escape_str(row.holds_count) ) + '">'
596 + _("Can't cancel order") + '</span><br/>';
599 result += '<a href="/cgi-bin/koha/acqui/cancelorder.pl?ordernumber='
600 + encodeURIComponent(row.order_id)
601 + '&biblionumber=' + encodeURIComponent(row.biblio_id)
602 + '&referrer=/cgi-bin/koha/acqui/parcel.pl?invoiceid=[% invoiceid | uri %]">'
603 + _("Cancel order") + '</a><br/>';
606 if ( row.biblio != null ) {
607 if ( row.biblio.items_count - row.items.length > 0 ||
608 row.biblio.active_orders_count > 1 ||
609 row.biblio.subscriptions_count > 0 ||
610 row.biblio.holds_count > 0 ) { // biblio can be deleted
611 result += '<span class="button" title="'
612 + _("Can't delete catalog record, see constraints below") + '">'
613 + _("Can't cancel order and delete catalog record") + '</span><br>';
616 result += '<a href="/cgi-bin/koha/acqui/cancelorder.pl?ordernumber='
617 + encodeURIComponent(row.order_id) + '&biblionumber=' + encodeURIComponent(row.biblio_id)
618 + '&del_biblio=1&referrer="/cgi-bin/koha/acqui/parcel.pl?invoiceid=[$ invoiceid | uri ]">'
619 + _("Cancel order and catalog record") + '</a><br/>';
622 if ( row.biblio.items_count - row.items.length > 0 ) {
623 result += '<strong title="'
624 + _("Can't delete catalog record, because of %s existing item(s)").format(row.items.length)
625 +'">' + (row.biblio.items_count - row.items.length) + _(" item(s) left") + '</strong><br/>';
628 if ( row.biblio.active_orders_count > 1 ) {
629 result += '<strong title="'
630 + _("Can't delete catalog record, delete other orders linked to it first") + '">'
631 + (row.biblio.active_orders_count - 1) + _(" order(s) left") + '</strong><br/>';
634 if ( row.biblio.subscriptions_count > 0 ) {
635 result += '<strong title="' + _("Can't delete catalog record, delete subscriptions first") + '">'
636 + _("%s subscription(s) left").format(row.biblio.subscriptions_count)
640 if ( row.biblio.holds_count > 0 ) {
641 result += '<strong title="' + _("Can't delete catalog record or order, cancel holds first") + '">'
642 + _("%s hold(s) left").format(row.biblio.holds_count) + '</strong>';
654 var selected_rows = {};
655 $('#select_multiple').click(function () {
656 var ids = Object.keys(selected_rows);
657 if (!ids.length) return;
658 location.href = 'orderreceive.pl?multiple_orders=' + ids.join(',') + '&invoiceid=[% invoiceid | uri %]';
659 }).html(PENDING_MULTI_SELECTION.format('0'))
660 options.order = [[1, 'asc']];
661 options.columns.unshift({
662 "data": function (row, type, val, meta) {
663 return '<input type="checkbox" class="selOrder" />';
669 var pending_orders_table = $("#pending_orders").kohaTable(options, {}, 1, { "basket.vendor_id": [% booksellerid | html %] });
671 var api = pending_orders_table.api();
672 api.on('draw', function () {
673 api.rows().every(function () {
675 var data = row.data();
676 $('.selOrder', row.node()).on('click', function (event) {
677 if ($(this).prop('checked')) {
678 selected_rows[data.order_id] = data;
680 delete selected_rows[data.order_id];
682 $('#select_multiple').html(PENDING_MULTI_SELECTION.format(Object.keys(selected_rows).length));
684 if (selected_rows[data.order_id]) {
685 $('.selOrder', row.node()).prop('checked', true);
691 $(".previewData").on("click", function(e){
693 var ltitle = $(this).text();
694 var page = $(this).attr("href");
695 $("#dataPreviewLabel").text(ltitle);
696 $("#dataPreview .modal-body").load(page + " div");
697 $('#dataPreview').modal("show");
700 $("#dataPreview").on("hidden.bs.modal", function(){
701 $("#dataPreviewLabel").html("");
702 $("#dataPreview .modal-body").html("<div id=\"loading\"><img src=\"[% interface | html %]/[% theme | html %]/img/spinner-small.gif\" alt=\"\" /> "+_("Loading")+"</div>");
706 // Case-insensitive version of jquery's contains function
707 jQuery.extend(jQuery.expr[':'], {
708 icontains : "jQuery(a).text().toUpperCase().indexOf(m[3].toUpperCase())>=0"
711 // Contains exactly function
712 jQuery.extend(jQuery.expr[':'], {
713 containsExactly: "$(a).text() == m[3]"
716 function transfer_order_popup(ordernumber) {
717 var url = "/cgi-bin/koha/acqui/transferorder.pl?"
718 + "ordernumber=" + ordernumber
719 window.open(url, 'TransferOrder');
724 [% INCLUDE 'intranet-bottom.inc' %]