4 [% PROCESS 'i18n.inc' %]
6 <div class="btn-group">
7 <a id="exportbutton" class="btn btn-default" href="[% script_name | url %]?op=export&basketno=[% basketno | uri %]&booksellerid=[% booksellerid | uri %]"><i class="fa fa-download"></i> Export as CSV</a>
8 <a class="btn btn-default dropdown-toggle" data-toggle="dropdown"><span class="caret"></span></a>
9 <ul class="dropdown-menu" id="export-csv-menu">
10 <li><a href="#">Default</a></li>
11 [% IF csv_profiles.count %]
12 [% FOR csv IN csv_profiles %]
13 <li><a href="#" data-value="[% csv.export_format_id | html %]">[% csv.profile | html %]</a></li>
22 [% USE AuthorisedValues %]
23 [% USE TablesSettings %]
24 [% SET footerjs = 1 %]
25 [% INCLUDE 'doc-head-open.inc' %]
26 <title>[% UNLESS ( basketno ) %]New [% END %]Basket [% basketname | html %] ([% basketno | html %]) for [% booksellername | html %] › Acquisitions › Koha</title>
27 [% INCLUDE 'doc-head-close.inc' %]
29 .sortmsg {font-size: 80%;}
33 <body id="acq_basket" class="acq">
34 [% WRAPPER 'header.inc' %]
35 [% INCLUDE 'acquisitions-search.inc' %]
38 [% WRAPPER 'sub-header.inc' %]
39 [% WRAPPER breadcrumbs %]
40 [% WRAPPER breadcrumb_item %]
41 <a href="/cgi-bin/koha/acqui/acqui-home.pl">Acquisitions</a>
43 [% WRAPPER breadcrumb_item %]
44 <a href="/cgi-bin/koha/acqui/supplier.pl?booksellerid=[% booksellerid | uri %]">[% booksellername | html %]</a>
46 [% WRAPPER breadcrumb_item bc_active= 1 %]
47 [% UNLESS ( basketno ) %]
48 [% IF ( delete_confirmed ) %]
55 <span>Basket [% basketname | html %] ([% basketno | html %]) for [% booksellername | html %]</span>
57 <span>Basket [% basketname | html %] for [% booksellername | html %]</span>
60 [% END #/ WRAPPER breadcrumbs %]
61 [% END #/ WRAPPER sub-header.inc %]
63 <div class="main container-fluid">
65 <div class="col-sm-10 col-sm-push-2">
68 [% IF (cannot_manage_basket) %]
69 <div class="dialog alert">You are not authorised to manage this basket.</div>
72 [% IF !confirm_close && !edi_confirm %]
73 [% UNLESS ( selectbasketg ) %]
74 [% UNLESS ( closedate ) %]
75 [% UNLESS ( delete_confirmed ) %]
76 <div id="toolbar" class="btn-toolbar fh-fixedHeader">
78 <div class="btn-group"><a href="#addtoBasket" role="button" class="btn btn-default" data-toggle="modal"><i class="fa fa-plus"></i> Add to basket</a></div>
80 <div class="btn-group"><a href="basketheader.pl?booksellerid=[% booksellerid | uri %]&basketno=[% basketno | uri %]&op=add_form" class="btn btn-default" id="basketheadbutton"><i class="fa fa-pencil"></i> Edit basket</a></div>
81 [% IF CAN_user_acquisition_delete_baskets %]
82 <div class="btn-group"><a href="#deleteBasketModal" role="button" class="btn btn-default" data-toggle="modal" id="delbasketbutton"><i class="fa fa-trash"></i> Delete basket</a></div>
84 [% IF ( unclosable ) %]
85 [% ELSIF ( uncertainprices ) %]
86 <div class="btn-group"><a href="/cgi-bin/koha/acqui/uncertainprice.pl?booksellerid=[% booksellerid | uri %]&owner=1" class="btn btn-default" id="uncertpricesbutton"><i class="fa fa-usd"></i> Uncertain prices</a></div>
87 <div title="Can not close baskets that have items with uncertain prices in them." class="btn-group">
88 <a href="" class="btn btn-default disabled" id="closebutton"><i class="fa fa-times-circle"></i> Close basket</a>
91 <div class="btn-group">
92 <a href="/cgi-bin/koha/acqui/basket.pl?op=close&basketno=[% basketno | uri %]&booksellerid=[% booksellerid | uri %]" class="btn btn-default" id="closebutton"><i class="fa fa-times-circle"></i> Close basket</a>
96 [% PROCESS csv_export %]
98 [% IF Koha.Preference('EDIFACT') && ediaccount %]
99 <div class="btn-group"><a href="/cgi-bin/koha/acqui/edi_ean.pl?op=ediorder&basketno=[% basketno | uri %]&booksellerid=[% booksellerid | uri %]" class="btn btn-default" id="ediorderbutton"><i class="fa fa-download"></i> Create EDIFACT order</a></div>
102 [% IF ( active && books_loop ) %]
103 <div class="btn-group">
104 <form action="/cgi-bin/koha/acqui/basket.pl" method="post">
105 <input type="hidden" name="op" value="email" />
106 <input type="hidden" name="basketno" value="[% basketno | html %]" />
107 <button type="submit" class="btn btn-default" id="emailvendorbutton"><i class="fa fa-envelope"></i> E-mail order</button>
111 </div> <!-- /#toolbar -->
112 [% END # / UNLESS ( delete_confirmed ) %]
114 <!-- Modal for confirm deletion box-->
115 <div class="modal" id="deleteBasketModal" tabindex="-1" role="dialog" aria-labelledby="delbasketModalLabel" aria-hidden="true">
116 <div class="modal-dialog">
117 <div class="modal-content">
118 <div class="modal-header">
119 <button type="button" class="closebtn" data-dismiss="modal" aria-hidden="true">×</button>
120 <h3>Confirm deletion</h3>
122 [% UNLESS book_foot_loop %]
123 <div class="modal-body">
124 <p>Are you sure you want to delete this basket?</p>
126 <div class="modal-footer">
127 <button type="button" class="btn btn-primary" data-dismiss="modal">Cancel</button>
128 <form action="/cgi-bin/koha/acqui/basket.pl" method="get">
129 <input type="hidden" name="op" value="delete_confirm" />
130 <input type="hidden" name="basketno" value="[% basketno | html %]" />
131 <input type="hidden" name="booksellerid" value="[% booksellerid | html %]" />
132 <input type="hidden" name="delbiblio" value="0" />
133 <button type="submit" class="btn btn-default btn-default">Delete basket</button>
137 <div class="modal-body">
138 <p>Are you sure you want to delete this basket?</p>
140 <p>All orders of this basket will be cancelled and used funds will be refunded.</p>
141 <p>If items have been created when ordering or receiving, they will be deleted.</p>
142 <p>You can choose to delete bibliographic records if possible (bibliographic records that have other items or that are used in a subscription or another order will not be deleted).</p>
144 <div class="modal-footer">
145 <button type="button" class="btn btn-primary" data-dismiss="modal">Cancel</button>
146 <form action="/cgi-bin/koha/acqui/basket.pl" method="get">
147 <input type="hidden" name="op" value="delete_confirm" />
148 <input type="hidden" name="basketno" value="[% basketno | html %]" />
149 <input type="hidden" name="booksellerid" value="[% booksellerid | html %]" />
150 <input type="hidden" name="delbiblio" value="0" />
151 <button type="submit" class="btn btn-default btn-default">Delete basket and orders</button>
154 <form action="/cgi-bin/koha/acqui/basket.pl" method="get">
155 <input type="hidden" name="op" value="delete_confirm" />
156 <input type="hidden" name="basketno" value="[% basketno | html %]" />
157 <input type="hidden" name="booksellerid" value="[% booksellerid | html %]" />
158 <input type="hidden" name="delbiblio" value="1" />
159 <button type="submit" class="btn btn-default btn-default">Delete basket, orders, and records</button>
161 </div> <!-- /.modal-footer -->
162 [% END # /UNLESS book_foot_loop %]
163 </div> <!-- /.modal-content -->
164 </div> <!-- /.modal-dialog -->
165 </div> <!-- /.modal#deleteBasketModal -->
167 [% ELSE # UNLESS ( closedate ) %]
168 <div id="toolbar" class="btn-toolbar">
170 <div title="Can not reopen baskets that are part of a basket group." class="btn-group">
171 <div class="btn-group"><a href="#" class="btn btn-default disabled" id="reopenbutton"><i class="fa fa-refresh"></i> Reopen basket</a></div>
174 <div class="btn-group"><a href="#" class="btn btn-default" id="reopenbutton"><i class="fa fa-refresh"></i> Reopen basket</a></div>
176 [% PROCESS csv_export %]
179 [% END # /UNLESS ( closedate ) %]
180 [% END # /UNLESS ( selectbasketg ) %]
182 [% IF ( NO_BOOKSELLER ) %]
183 <h1>Vendor not found</h1>
185 [% IF ( delete_confirmed ) %]
186 <div class="dialog message">
187 <h3>Basket deleted</h3>
189 [% IF (cannotdelbiblios) %]
190 <div class="dialog alert">
191 <p><strong>Warning:</strong></p>
192 <p><strong>The following records could not be deleted:</strong></p>
194 [% FOREACH cannotdelbiblio IN cannotdelbiblios %]
196 <a href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=[% cannotdelbiblio.biblionumber | uri %]">[% cannotdelbiblio.title | html %]</a> by [% cannotdelbiblio.author | html %]:
198 [% IF (cannotdelbiblio.itemcount) %]<li>[% cannotdelbiblio.itemcount | html %] item(s) attached.</li>[% END %]
199 [% IF (cannotdelbiblio.subscriptions) %]<li>[% cannotdelbiblio.subscriptions | html %] subscription(s) attached.</li>[% END %]
200 [% IF (cannotdelbiblio.countbiblio) %]<li>[% cannotdelbiblio.countbiblio | html %] order(s) attached.</li>[% END %]
201 [% IF (cannotdelbiblio.othererror) %]<li>Unknown error.</li>[% END %]
207 <a href="booksellers.pl">Go back to vendor page</a>
209 <a href="/cgi-bin/koha/acqui/booksellers.pl?booksellerid=[% booksellerid | uri %]" class="btn btn-default btn-sm">Show baskets for vendor [% booksellername | html %]</a> <a href="/cgi-bin/koha/acqui/booksellers.pl" class="btn btn-default btn-sm">Show all active baskets</a>
210 [% END # /IF (cannotdelbiblios) %]
211 [% ELSE # IF ( delete_confirmed ) %]
213 [% FOR m IN messages %]
214 <div class="dialog [% m.type | html %]">
216 [% CASE 'no_email' %]
217 <span>This vendor has no contact selected for sending orders to or is missing an e-mail address.</span>
218 [% CASE 'no_basketno' %]
219 <span>No basket given.</span>
220 [% CASE 'no_letter' %]
221 <span>There is no notice template with code ACQORDER defined.</span>
222 [% CASE 'email_sent' %]
223 <span>Order e-mail was sent to the vendor.</span>
225 <span>ERROR! - [% m.code | html %]</span>
230 <h1>[% UNLESS ( basketno ) %]New [% END %]Basket [% basketname | html %] ([% basketno | html %]) for <a href="supplier.pl?booksellerid=[% booksellerid | uri %]">[% booksellername | html %]</a></h1>
232 [% IF ( basketno ) %]
233 <div id="acqui_basket_summary" class="row">
235 <div class="col-sm-6">
236 <div class="page-section">
237 <h2>General information</h3>
239 [% IF ( basketnote ) %]
240 <li><span class="label">Internal note:</span> [% basketnote | html %]</li>
242 [% IF ( basketbooksellernote ) %]
243 <li><span class="label">Vendor note:</span> [% basketbooksellernote | html %]</li>
245 [% IF ( basketcontractno ) %]
246 <li><span class="label">Contract name:</span> <a href="../admin/aqcontract.pl?op=add_form&contractnumber=[% basketcontractno | uri %]&booksellerid=[% booksellerid | uri %]">[% basketcontractname | html %]</a></li>
248 [% IF deliveryplace %]
249 <li><span class="label">Delivery place:</span> [% Branches.GetName( deliveryplace ) | html %]</li>
251 [% IF billingplace %]
252 <li><span class="label">Billing place:</span> [% Branches.GetName( billingplace ) | html %]</li>
254 [% IF ( authorisedbyname ) %]
255 <li><span class="label">[% tp('basket created by', 'Created by:') | html %]</span> [% authorisedbyname | html %]</li>
258 [% IF ( creationdate ) %]
259 <li><span class="label">Opened on:</span> [% creationdate | $KohaDates %]</li>
261 [% IF ( closedate ) %]
262 <li><span class="label">Closed on:</span> [% closedate | $KohaDates %]</li>
265 [% IF ( ediaccount ) %]
266 [%- BLOCK edi_status -%]
267 [%- SWITCH edi_order.status -%]
268 [%- CASE 'Pending' -%]<span>Pending</span>
269 [%- CASE 'Sent' -%]<span>Sent</span>
270 [%- CASE 'Processed' -%]<span>Processed</span>
273 [% IF ( edi_order ) %]
274 <li><span class="label">EDI status:</span> [%- PROCESS edi_status edi_order=edi_order -%] ([% edi_order.transfer_date | $KohaDates %])</li>
276 <li><span class="label">EDI status:</span> Not ordered</li>
279 [% IF ( estimateddeliverydate ) %]
280 <li><span class="label">Estimated delivery date:</span> [% estimateddeliverydate | $KohaDates %]</li>
282 <li><span class="label">Orders are standing:</span> [% IF is_standing %]Yes[% ELSE %]No[% END %]</li>
284 [% IF basket.create_items %]
286 <span class="label">Create items when:</span>
287 [% SWITCH basket.create_items %]
288 [% CASE 'receiving' %]<span>Receiving items</span>
289 [% CASE 'cataloguing' %]<span>Cataloguing items</span>
290 [% CASE %]<span>Placing orders</span>
295 [% INCLUDE 'additional-fields-display.inc' available=available_additional_fields values=additional_field_values %]
298 </div> <!-- /.page-section -->
299 </div> <!-- /.col-sm-6 -->
301 <div class="col-sm-6">
302 <div class="page-section">
307 <form action="/cgi-bin/koha/acqui/basket.pl" method="post">
308 <span class="label">Managed by:</span>
309 <div style="display:inline-block">
310 <ul id="users_names" style="padding-left:0">
311 [% FOREACH user IN users %]
312 <li id="user_[% user.borrowernumber | html %]">
313 [% user.firstname | html %] [% user.surname | html %]
314 <a href="#" data-borrowernumber="[% user.borrowernumber | html %]" class="del_user"><i class="fa fa-trash"></i> Delete user</a>
318 <a href="#" id="add_user"><i class="fa fa-plus"></i> Add user</a>
320 <li id="add_user_submit" style="display:none;">
321 <button type="submit" class="btn btn-default btn-xs">Save changes</button>
325 <input type="hidden" id="basketno" name="basketno" value="[% basketno | html %]" />
326 <input type="hidden" id="users_ids" name="users_ids" value="[% users_ids | html %]" />
327 <input type="hidden" id="op" name="op" value="mod_users" />
330 </li> <!-- /#managedby -->
332 <span class="label">Managing library:</span>
333 [% IF basketbranchcode %]
334 [% Branches.GetName( basketbranchcode ) | html %]
335 <a href="#" id="set_managing_library"><i class="fa fa-pencil"></i> Change library</a>
338 <a href="#" id="set_managing_library"><i class="fa fa-pencil"></i> Set library</a>
340 </li> <!-- /#branch -->
341 [% IF branches_loop.size %]
342 <li id="managing_library_entry" style="display:none;">
343 <span class="label"> </span>
345 <form action="/cgi-bin/koha/acqui/basket.pl" method="post">
346 <select id="select_managing_library" name="branch">
347 <option value="">(no library)</option>
348 [% FOREACH branch IN branches_loop %]
349 [% IF ( basketbranchcode == branch.branchcode ) %]
350 <option selected="selected" value="[% branch.branchcode | html %]"> [% branch.branchname | html %]</option>
352 <option value="[% branch.branchcode | html %]"> [% branch.branchname | html %]</option>
356 <a id="library_entry_cancel" href="#" class="cancel">Cancel</a>
357 <input type="hidden" id="basketno" name="basketno" value="[% basketno | html %]" />
358 <input type="hidden" id="op" name="op" value="mod_branch" />
361 </li> <!-- #/managing_library_entry -->
362 [% END # /IF branches_loop.size %]
366 [% IF ( closedate ) %]
369 <span class="label">Basket group:</span>
370 [% IF basketgroup.id and not basketgroup.name %]
371 [% SET basketgroup.name = "Basket group no. " _ basketgroup.id %]
374 [% IF basketgroup.closed %]
375 [% IF ( CAN_user_acquisition_group_manage ) %]
376 <a href="basketgroup.pl?op=add&booksellerid=[% booksellerid | uri %]&basketgroupid=[% basketgroup.id | uri %]" title="basketgroup">[% basketgroup.name | html %] <span>(closed)</span></a>
378 [% basketgroup.name | html %] <span>(closed)</span>
380 [% ELSIF ( ! CAN_user_acquisition_group_manage ) %]
381 [%- IF basketgroup.id -%]
382 [% basketgroup.name | html %]
384 <span>No group</span>
387 [% IF ( CAN_user_acquisition_group_manage ) %]
388 [% IF ( basketgroup.id ) %]
389 [% basketgroup.name | html %]
390 <a href="#" id="set_basket_group"><i class="fa fa-pencil"></i> Change basket group</a>
393 <a href="#" id="set_basket_group"><i class="fa fa-pencil"></i> Set basket group</a>
398 [% IF ( CAN_user_acquisition_group_manage ) %]
399 <li id="basket_grouping" style="display:none;">
400 <span class="label"> </span>
401 <div style="float:left">
402 <form action="/cgi-bin/koha/acqui/basketgroup.pl" method="post">
403 <select id="basketgroupid" name="basketgroupid">
404 <option value="">No group</option>
405 [% FOREACH bg IN basketgroups %]
406 [% IF ( bg.default ) %]
407 <option value="[% bg.id | html %]" selected="selected">[% bg.name | html %]</option>
409 [% UNLESS bg.closed %]
410 <option value="[% bg.id | html %]">[% bg.name | html %]</option>
412 <option value="[% bg.id | html %]" disabled="disabled">[% bg.name | html %] <span>(closed)</span></option>
416 <option value="new">Add new group</option>
418 <a href="#" id="basket_group_cancel" class="cancel">Cancel</a>
419 <input type="hidden" id="basketno" value="[% basketno | html %]" name="basketno" />
420 <input type="hidden" value="mod_basket" name="op" />
421 <input type="hidden" name="booksellerid" value="[% booksellerid | html %]" />
425 [% END # /IF ( CAN_user_acquisition_group_manage ) %]
426 [% IF basketgroup.deliveryplace %]
428 <span class="label">Basket group delivery placename:</span> [% Branches.GetName( basketgroup.deliveryplace ) | html %]
431 [% IF basketgroup.billingplace %]
433 <span class="label">Basket group billing place:</span> [% Branches.GetName( basketgroup.billingplace ) | html %]
437 [% END # /IF closeddate %]
438 </div> <!-- /.page-section -->
439 </div> <!-- /.rows -->
440 </div> <!-- /.col-sm-6 -->
441 </div> <!-- /#acqui_basket_summary.row -->
442 [% END # /IF ( basketno ) %]
444 [% IF ( duplinbatch ) %]
445 <div class="dialog alert">
446 <h4>Duplicate warning</h4>
447 <p>Some records have not been automatically added because they match an existing record in your catalog:<a href="/cgi-bin/koha/acqui/addorderiso2709.pl?import_batch_id=[% duplinbatch | uri %]&basketno=[% basketno | uri %]&booksellerid=[% booksellerid | uri %]" title="Open in new window" target="_blank" style="margin-left:10px"><i class="fa fa-window-restore"></i> Display them</a></p>
451 <div id="acqui_basket_content" class="page-section">
452 [% IF ( books_loop ) %]
458 <th>[% tp('noun', 'Order') | html %]</th>
459 <th>RRP tax exc.</th>
460 <th>Actual cost tax exc.</th>
461 <th>Budgeted cost tax exc.</th>
462 <th>RRP tax inc.</th>
463 <th>Actual cost tax inc.</th>
464 <th>Budgeted cost tax inc.</th>
465 <th>Replacement price</th>
467 <th>Total tax exc. ([% currency | html %])</th>
468 <th>Total tax inc. ([% currency | html %])</th>
472 <th>Estimated delivery date</th>
473 [% IF Koha.Preference('EDIFACT') && ediaccount %]
474 <th>Supplier report</th>
477 [% UNLESS ( closedate ) %]
478 <th class="NoSort">Modify</th>
479 <th class="NoSort">Cancel order</th>
485 [% FOREACH foot_loo IN book_foot_loop %]
488 <th>Total (GST [% foot_loo.tax_rate * 100 | html %])</th>
496 <th>[% foot_loo.quantity | html %]</th>
497 <th>[% foot_loo.total_tax_excluded | $Price %]</th>
498 <th>[% foot_loo.total_tax_included | $Price %]</th>
500 <th>[% foot_loo.tax_value | $Price %]</th>
503 [% IF Koha.Preference('EDIFACT') && ediaccount %]
507 [% UNLESS ( closedate ) %]
516 <th>Total ([% currency | html %])</th>
524 <th>[% total_quantity | html %]</th>
525 <th>[% total_tax_excluded | $Price %]</th>
526 <th>[% total_tax_included | $Price %]</th>
528 <th>[% total_tax_value | $Price %]</th>
531 [% IF Koha.Preference('EDIFACT') && ediaccount %]
535 [% UNLESS ( closedate ) %]
543 [% FOREACH books_loo IN books_loop %]
544 [% IF ( books_loo.order_received ) %]
545 <tr class="disabled">
550 [% books_loo.ordernumber | html %]
554 [% IF ( books_loo.order_received ) %] <span class="order-received">(received)</span>[% END %]
555 [% IF books_loo.title %]
556 [% INCLUDE 'biblio-title.inc' biblio=books_loo link = 1 %] [% IF books_loo.author %] by [% books_loo.author | html %][% END %]
558 <em>Deleted bibliographic record, can't find title</em><br />
561 [%- IF ( books_loo.isbn ) %] - [% books_loo.isbn | html %][% END -%]
562 [%- IF ( books_loo.issn ) %] - [% books_loo.issn | html %][% END -%]
563 [%- IF ( books_loo.publishercode ) %], [% books_loo.publishercode | html %][% END -%]
564 [%- IF ( books_loo.publicationyear ) %], [% books_loo.publicationyear | html -%]
565 [%- ELSIF ( books_loo.copyrightdate ) %] [% books_loo.copyrightdate | html %][% END -%]
566 [%- IF ( books_loo.editionstatement ) %], [% books_loo.editionstatement | html %][% END -%]
567 [%- IF ( books_loo.suggestionid ) %]
569 Suggested by: [% books_loo.surnamesuggestedby | html %][% IF ( books_loo.firstnamesuggestedby ) %], [% books_loo.firstnamesuggestedby | html %] [% END %]
570 (<a href="/cgi-bin/koha/suggestion/suggestion.pl?suggestionid=[% books_loo.suggestionid | uri %]&op=show">suggestion #[% books_loo.suggestionid | html %]</a>)
573 [% IF ( books_loo.order_internalnote ) %]
574 <p class="ordernote"><strong>Internal note: </strong><span id="internal-note-[% books_loo.ordernumber | html %]">[% books_loo.order_internalnote | html %]</span> <a class="edit_note noExport" data-ordernumber="[% books_loo.ordernumber | html %]" data-note_type="internal" href="/cgi-bin/koha/acqui/modordernotes.pl?ordernumber=[% books_loo.ordernumber | html %]&type=internal" title="Edit internal note"><i class="fa fa-pencil"></i> Edit internal note</a></p>
576 <a class="edit_note noExport" data-ordernumber="[% books_loo.ordernumber | html %]" data-note_type="internal" href="/cgi-bin/koha/acqui/modordernotes.pl?ordernumber=[% books_loo.ordernumber | html %]&type=internal" title="Add internal note"><i class="fa fa-plus"></i> Add internal note</a>
578 [% IF ( books_loo.order_vendornote ) %]
579 <p class="ordernote"><strong>Vendor note: </strong> <span id="vendor-note-[% books_loo.ordernumber | html %]">[% books_loo.order_vendornote | html %]</span> <a class="edit_note noExport" data-ordernumber="[% books_loo.ordernumber | html %]" data-note_type="vendor" href="/cgi-bin/koha/acqui/modordernotes.pl?ordernumber=[% books_loo.ordernumber | html %]&type=vendor" title="Edit vendor note"><i class="fa fa-pencil"></i> Edit vendor note</a></p>
581 <a class="edit_note noExport" data-ordernumber="[% books_loo.ordernumber | html %]" data-note_type="vendor" href="/cgi-bin/koha/acqui/modordernotes.pl?ordernumber=[% books_loo.ordernumber | html %]&type=vendor" title="Add vendor note"><i class="fa fa-plus"></i> Add vendor note</a>
583 [% IF (books_loo.transferred_from) %]
584 [% basket = books_loo.transferred_from.basket %]
585 [% bookseller = books_loo.transferred_from.bookseller %]
586 [% timestamp = books_loo.transferred_from.timestamp %]
588 Transferred from basket:
589 <a href="/cgi-bin/koha/acqui/basket.pl?basketno=[% basket.basketno | uri %]"> [% basket.basketname | html %]</a>
590 (<a href="/cgi-bin/koha/acqui/supplier.pl?booksellerid=[% bookseller.id | uri %]">[% bookseller.name | html %]</a>)
591 on <span title="[% timestamp | $KohaDates with_hours = 1 %]">
592 [% timestamp | $KohaDates %]
596 [% SET claims = books_loo.order_object.claims %]
597 [% IF claims.count %]
599 This order has been claimed [% claims.count | html %] times. On [% FOR c IN claims %][% c.claimed_on | $KohaDates %][% UNLESS loop.last %], [% END %][% END %]
603 [% SET zero_regex = "^0{1,}\.?0{1,}[^1-9]" %] [%# 0 or 0.0 or 0.00 or 00 or 00.0 or 00.00 or 0.000 ... %]
604 [%# FIXME: use of a regexp is not ideal; bugs 9410 and 10929 suggest better way of handling this %]
605 <td class="number [% IF books_loo.rrp_tax_excluded.search(zero_regex) %]error[% END %]">
606 [% books_loo.rrp_tax_excluded | $Price %] [% IF ( books_loo.uncertainprice ) %] <span>(Uncertain)</span> [% END %]
608 <td class="number [% IF books_loo.unitprice_tax_excluded.search(zero_regex) %]error[% END %]">
609 [% books_loo.unitprice_tax_excluded | $Price %]
611 <td class="number [% IF books_loo.ecost_tax_excluded.search(zero_regex) %]error[% END %]">
612 [% books_loo.ecost_tax_excluded | $Price %]
614 <td class="number [% IF books_loo.rrp_tax_included.search(zero_regex) %]error[% END %]">
615 [% books_loo.rrp_tax_included | $Price %]
617 <td class="number [% IF books_loo.unitprice_tax_included.search(zero_regex) %]error[% END %]">
618 [% books_loo.unitprice_tax_included | $Price %]
620 <td class="number [% IF books_loo.ecost_tax_included.search(zero_regex) %]error[% END %]">
621 [% books_loo.ecost_tax_included | $Price %]
623 <td class="number [% IF books_loo.replacementprice.search(zero_regex) %]error[% END %]">
624 [% books_loo.replacementprice | $Price %]
626 <td class="number [% IF books_loo.quantity.search(zero_regex) %]error[% END %]">
627 [% books_loo.quantity | html %]
629 <td class="number [% IF books_loo.total_tax_excluded.search(zero_regex) %]error[% END %]">
630 [% books_loo.total_tax_excluded | $Price %]
632 <td class="number [% IF books_loo.total_tax_included.search(zero_regex) %]error[% END %]">
633 [% books_loo.total_tax_included | $Price %]
636 [% books_loo.tax_rate * 100 | html %]
638 <td class="number [% IF books_loo.tax_value.search(zero_regex) %]error[% END %]">
639 [% books_loo.tax_value | $Price %]
642 [% books_loo.budget_name | html %]
644 <td data-order="[% books_loo.estimated_delivery_date | html %]" class="actions">
645 [% books_loo.estimated_delivery_date | $KohaDates %]
646 [% IF CAN_user_acquisition_order_manage %]
647 <a class="edit_delivery_date" href="/cgi-bin/koha/acqui/moddeliverydate.pl?ordernumber=[% books_loo.ordernumber | html %]" title="Edit delivery date" data-ordernumber="[% books_loo.ordernumber | html %]" id="delivery_date_[% books_loo.ordernumber | html %]" data-delivery_date="[% books_loo.estimated_delivery_date | html %]">
648 <i class="fa fa-pencil"></i> Edit</a>
651 [% IF Koha.Preference('EDIFACT') && ediaccount %]
652 <td>[% books_loo.suppliers_report | html %]</td>
655 [% UNLESS ( closedate ) %]
657 [% UNLESS (books_loo.order_received) %]
658 <a href="neworderempty.pl?ordernumber=[% books_loo.ordernumber | uri %]&booksellerid=[% booksellerid | uri %]&basketno=[% basketno | uri %]">Modify</a>
660 <a href="#" class="transfer_order" data-ordernumber="[% books_loo.ordernumber | html %]">Transfer</a>
664 [% IF ( books_loo.orderstatus != "complete") %]
665 [% IF ( books_loo.left_holds_on_order ) %]
666 <span class="button" title="Can't cancel order, ([% books_loo.holds_on_order | html %]) holds are linked with this order. Cancel holds first">Can't cancel order</span><br>
668 <a href="/cgi-bin/koha/acqui/cancelorder.pl?ordernumber=[% books_loo.ordernumber | uri %]&biblionumber=[% books_loo.biblionumber | uri %]&basketno=[% basketno | uri %]&referrer=/cgi-bin/koha/acqui/basket.pl%3Fbasketno=[% basketno | uri %]" class="button">Cancel order</a><br>
670 [% IF ( books_loo.can_del_bib ) %]
671 <a href="/cgi-bin/koha/acqui/cancelorder.pl?ordernumber=[% books_loo.ordernumber | uri %]&biblionumber=[% books_loo.biblionumber | uri %]&basketno=[% basketno | uri %]&del_biblio=1&referrer=/cgi-bin/koha/acqui/basket.pl%3Fbasketno=[% basketno | uri %]" class="button">Cancel order and delete catalog record</a><br>
673 <span class="button" title="Can't delete catalog record, see constraints below">Can't cancel order and delete catalog record</span><br>
675 [% IF ( books_loo.left_item ) %]
676 <strong title="Can't delete catalog record, because of [% books_loo.items | html %] existing hold(s)" >[% books_loo.items | html %] item(s) left</strong><br>
678 [% IF ( books_loo.left_biblio ) %]
679 <strong title="Can't delete catalog record, delete other orders linked to it first">[% books_loo.biblios | html %] order(s) left</strong><br>
681 [% IF ( books_loo.left_subscription ) %]
682 <strong title="Can't delete catalog record, delete subscriptions first">[% books_loo.subscriptions | html %] subscription(s) left</strong><br>
684 [% IF ( books_loo.left_holds ) %]
685 <strong title="Can't delete catalog record or order, cancel holds first">[% books_loo.holds | html %] hold(s) left</strong>
694 </table> <!-- /#orders -->
695 [% END # / IF ( books_loop ) %]
696 [% IF ( listincgst ) %]<small class="highlight">** Vendor's listings already include tax.</small>[% END %]
697 </div> <!-- /#acqui_basket_content -->
699 [% IF (cancelledorders_loop) %]
700 <div id="cancelledorders" class="page-section">
701 <h2>Cancelled orders</h2>
702 <table id="cancelledorderst">
706 <th>[% tp('noun', 'Order') | html %]</th>
707 <th class="tax_excluded">RRP tax exc.</th>
708 <th class="tax_excluded">ecost tax exc.</th>
709 <th class="tax_included">RRP tax inc.</th>
710 <th class="tax_included">ecost tax inc.</th>
711 <th class="replacementprice">Replacement price</th>
713 <th class="tax_excluded">Total tax exc. ([% currency | html %])</th>
714 <th class="tax_included">Total tax inc. ([% currency | html %])</th>
721 [% FOREACH order IN cancelledorders_loop %]
722 <tr style="color:grey">
724 [% order.ordernumber | html %]
728 [% IF ( order.order_received ) %] <span class="order-received">(received)</span>[% END %]
729 [% IF (order.title) %]
730 [% order.title | html %][% IF order.author %] by [% order.author | html %][% END %]
732 <em>Deleted bibliographic record, can't find title</em>
735 [% IF ( order.order_internalnote ) %] [% order.order_internalnote | html %][% END %]
736 [% IF ( order.isbn ) %] - [% order.isbn | html %][% END %]
737 [% IF ( order.issn ) %] - [% order.issn | html %][% END %]
738 [% IF ( order.publishercode ) %], [% order.publishercode | html %][% END %]
739 [% IF ( order.publicationyear ) %]
740 , [% order.publicationyear | html %]
741 [% ELSIF ( order.copyrightdate ) %]
742 [% order.copyrightdate | html %]
744 [% IF ( books_loo.editionstatement ) %], [% books_loo.editionstatement | html %][% END %]
745 [% IF ( order.cancellationreason ) %]
747 Cancellation reason: [% AuthorisedValues.GetByCode( 'ORDER_CANCELLATION_REASON', order.cancellationreason ) | html %]
750 [% IF order.transferred_to %]
751 [% basket = order.transferred_to.basket %]
752 [% bookseller = order.transferred_to.bookseller %]
753 [% timestamp = order.transferred_to.timestamp %]
754 <p>Transferred to basket:
755 <a href="/cgi-bin/koha/acqui/basket.pl?basketno=[% basket.basketno | uri %]"> [% basket.basketname | html %]</a>
756 (<a href="/cgi-bin/koha/acqui/supplier.pl?booksellerid=[% bookseller.id | uri %]">[% bookseller.name | html %]</a>)
757 on <span title="[% timestamp | $KohaDates with_hours = 1 %]">
758 [% timestamp | $KohaDates %]
764 [% order.rrp_tax_excluded | $Price %]
765 [% IF ( order.uncertain ) %]
766 <span>(Uncertain)</span>
769 <td class="number">[% order.ecost_tax_excluded | $Price %]</td>
770 <td class="number">[% order.rrp_tax_included | $Price %]</td>
771 <td class="number">[% order.ecost_tax_included | $Price %]</td>
772 <td class="number">[% order.replacementprice | $Price %]</td>
773 <td class="number">[% order.quantity | html %]</td>
774 <td class="number">[% order.total_tax_excluded | $Price %]</td>
775 <td class="number">[% order.total_tax_included | $Price %]</td>
776 <td class="number">[% order.tax_rate * 100 | html %]</td>
777 <td class="number">[% order.tax_value | $Price %]</td>
778 <td>[% order.budget_name | html %]
780 [% END # /FOREACH order %]
782 </table> <!-- /#cancelledorderst -->
783 </div> <!-- /#cancelledorders -->
784 [% END # /IF (cancelledorders_loop) %]
787 [% UNLESS ( closedate ) %]
789 <div id="addtoBasket" class="modal" tabindex="-1" role="dialog" aria-labelledby="addtoBasketLabel" aria-hidden="true" data-basketno="[% basket.basketname | html %]">
790 <div class="modal-dialog" role="document">
791 <div class="modal-content">
792 <div class="modal-header">
793 <button type="button" class="closebtn" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
794 <h4 class="modal-title" id="addtoBasketLabel">Add order to basket</h4>
796 <div class="modal-body">
798 [% INCLUDE 'acquisitions-add-to-basket.inc' %]
801 <div class="modal-footer">
802 <a href="#" class="cancel" data-dismiss="modal" aria-hidden="true">Cancel</a>
804 </div><!-- /.modal-content -->
805 </div><!-- /.modal-dialog -->
806 </div><!-- /.modal#addtoBasket -->
807 [% END # /UNLESS ( closedate ) %]
809 [% END # /IF ( delete_confirmed ) %]
810 [% END # /IF ( NO_BOOKSELLER ) %]
812 <!-- if we want just to select a basketgroup for a closed basket -->
813 [% END #/IF !confirm_close && !edi_confirm %]
815 [% IF ( confirm_close ) %]
816 <div id="closebasket_needsconfirmation" class="dialog alert">
818 <form action="/cgi-bin/koha/acqui/basket.pl">
819 <h1>Are you sure you want to close basket [% basketname | html %]?</h1>
820 [% IF ( CAN_user_acquisition_group_manage ) %]
822 <label for="createbasketgroup">Attach this basket to a new basket group with the same name</label>
823 <input type="checkbox" id="createbasketgroup" name="createbasketgroup"/>
826 <input type="hidden" id="basketno" value="[% basketno | html %]" name="basketno" />
827 <input type="hidden" value="close" name="op" />
828 <input type="hidden" name="booksellerid" value="[% booksellerid | html %]" />
829 <input type="hidden" name="confirm" value="1" />
830 <input type="hidden" name="basketgroupname" value="[% basketgroupname | html %]" />
831 <button type="submit" class="approve" accesskey="y"><i class="fa fa-fw fa-check"></i> Yes, close (Y)</button>
833 <form action="/cgi-bin/koha/acqui/basket.pl" method="get">
834 <input type="hidden" name="basketno" value="[% basketno | html %]" />
835 <button type="submit" class="deny" accesskey="n"><i class="fa fa-fw fa-remove"></i> No, don't close (N)</button>
838 [% END # /IF ( confirm_close ) %]
841 <div id="closebasket_needsconfirmation" class="dialog alert">
842 <form action="/cgi-bin/koha/acqui/basket.pl">
843 <h1>Are you sure you want to generate an EDIFACT order and close basket [% basketname | html %]?</h1>
844 [% IF CAN_user_acquisition_group_manage %]
846 <label for="createbasketgroup">Attach this basket to a new basket group with the same name</label>
847 <input type="checkbox" id="createbasketgroup" name="createbasketgroup"/>
850 <input type="hidden" id="basketno" value="[% basketno | html %]" name="basketno" />
851 <input type="hidden" value="ediorder" name="op" />
852 <input type="hidden" name="ean" value="[% ean | html %]" />
853 <input type="hidden" name="booksellerid" value="[% booksellerid | html %]" />
854 <input type="hidden" name="confirm" value="1" />
855 <input type="hidden" name="basketgroupname" value="[% basketgroupname | html %]" />
856 <button type="submit" class="approve" accesskey="Y"><i class="fa fa-fw fa-check"></i> Yes, close (Y)</button>
858 <form action="/cgi-bin/koha/acqui/basket.pl" method="get">
859 <input type="hidden" name="basketno" value="[% basketno | html %]" />
860 <button type="submit" class="deny" accesskey="N"><i class="fa fa-fw fa-remove"></i> No, don't close (N)</button>
862 </div> <!-- /#closebasket_needsconfirmation -->
863 [% END # /IF edi_confirm %]
864 [% END # /IF (cannot_manage_basket) %]
866 </div> <!-- /.col-sm-10.col-sm-push-2 -->
868 <div class="col-sm-2 col-sm-pull-10">
870 [% INCLUDE 'vendor-menu.inc' %]
871 [% INCLUDE 'acquisitions-menu.inc' %]
873 </div> <!-- /.col-sm-2.col-sm-pull-10 -->
874 </div> <!-- /.row -->
877 <!-- Modal for editing vendor and internal notes -->
878 <div class="modal" id="noteEditor" tabindex="-1" role="dialog" aria-labelledby="noteEditorLabel">
879 <div class="modal-dialog" role="document">
880 <form id="modify_order_notes" action="/cgi-bin/koha/acqui/modordernotes.pl" method="post">
881 <div class="modal-content">
882 <div class="modal-header">
883 <button type="button" class="closebtn" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
884 <h4 class="modal-title" id="noteEditorLabel">Order note</h4>
886 <div class="modal-body">
887 <textarea id="ordernotes" name="ordernotes" rows="3" cols="30" class="focus">[% ordernotes | html %]</textarea>
888 <input type="hidden" id="ordernumber" name="ordernumber" value="" />
889 <input type="hidden" name="op" value="save" />
890 <input type="hidden" id="type" name="type" value="" />
892 <div class="modal-footer">
893 <button type="submit" class="btn btn-default">Save</button>
894 <button type="button" class="btn btn-link cancel" data-dismiss="modal">Cancel</button>
896 </div> <!-- /.modal-content -->
897 </form> <!-- /#modify_order_notes -->
898 </div> <!-- /.modal-dialog -->
899 </div> <!-- /.modal#noteEditor -->
901 <!-- Modal for editing estimated delivery date -->
902 <div class="modal" id="dateEditor" tabindex="-1" role="dialog" aria-labelledby="dateEditorLabel">
903 <div class="modal-dialog" role="document">
904 <form id="modify_estimated_delivery_date" action="/cgi-bin/koha/acqui/moddeliverydate.pl" method="post">
905 <div class="modal-content">
906 <div class="modal-header">
907 <button type="button" class="closebtn" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
908 <h4 class="modal-title" id="dateEditorLabel">Estimated delivery date</h4>
910 <div class="modal-body">
911 <input type="text" id="estimated_delivery_date" size="10" name="estimated_delivery_date" class="flatpickr" value="[% books_loo.estimated_delivery_date | html %]"/>
912 <div class="hint">[% INCLUDE 'date-format.inc' %]</div>
913 <input type="hidden" id="date_ordernumber" name="ordernumber" value="" />
914 <input type="hidden" name="op" value="save" />
916 <div class="modal-footer">
917 <button type="submit" class="btn btn-default">Save</button>
918 <button type="button" class="btn btn-link cancel" data-dismiss="modal">Cancel</button>
920 </div> <!-- /.modal-content -->
921 </form> <!-- /#modify_estimated_delivery_date -->
922 </div> <!-- /.modal-dialog -->
923 </div> <!-- /.modal#dateEditor -->
925 [% MACRO jsinclude BLOCK %]
926 [% Asset.js("js/acquisitions-menu.js") | $raw %]
927 [% INCLUDE 'datatables.inc' %]
928 [% INCLUDE 'columns_settings.inc' %]
929 [% Asset.js("lib/hc-sticky.js") | $raw %]
930 [% Asset.js("js/acq.js") | $raw %]
931 [% INCLUDE 'calendar.inc' %]
933 function updateColumnsVisibility(visible) {
935 $("table .tax_excluded, .tax_included").show();
937 [% IF ( listincgst ) %]
938 $("table .tax_excluded").hide();
940 $("table .tax_included").hide();
947 $(document).ready(function() {
948 if ( $('#toolbar').length ) {
949 Sticky = $("#toolbar");
952 stickyClass: "floating"
956 [% UNLESS ( closedate ) %]
957 $('#addtoBasket').on('show', function () {
958 $(this).find(".modal-body").html($(".acqui_basket_add")[0].outerHTML);
962 $("body").on("click", ".del_user", function(e){
964 del_user( $(this).data("borrowernumber") );
967 $("#add_user").on("click",function(e){
972 $(".transfer_order").on("click",function(e){
974 transfer_order_popup( $(this).data("ordernumber"));
977 $(".edit_note").on("click", function(e) {
979 var ordernumber = $(this).data("ordernumber");
980 var note_type = $(this).data("note_type");
981 var order_number_text = _(" (order number %s)").format(ordernumber);
982 var modalTitle = $(this).attr("title") + " " + order_number_text;
983 var note_text = $( "#" + note_type + "-note-" + ordernumber ).html();
984 $("#noteEditor .modal-title").text(modalTitle);
985 $("#ordernumber").val( ordernumber );
986 $("#ordernotes").html( note_text );
987 $("#type").val( note_type );
988 $("#noteEditor").modal("show");
989 $("#ordernotes").focus();
992 $("#noteEditor").on('hidden.bs.modal', function (e) {
993 $("#noteEditorLabel").html("");
994 $("#noteEditor .modal-title").text("");
995 $("#ordernotes").html( "" );
996 $("#ordernumber").val("");
1000 $("#set_managing_library").on("click", function(e){
1003 $("#managing_library_entry").show();
1006 $("#library_entry_cancel").on("click", function(e){
1008 $("#managing_library_entry").hide();
1009 $("#set_managing_library").show();
1012 $("#set_basket_group").on("click", function(e){
1015 $("#basket_grouping").show();
1018 $("#basket_group_cancel").on("click", function(e){
1020 $("#basket_grouping").hide();
1021 $("#set_basket_group").show();
1024 $("#addtoBasket").on("shown.bs.modal", function(){
1025 var basket = $(this).data("basketno");
1026 var legend = _("Add order to basket %s").format(basket);
1027 $(this).find("h4").text( legend );
1028 $(this).find("legend").html(legend);
1029 $(this).find("input:text").focus();
1034 [% UNLESS ( closedate ) %]
1036 function transfer_order_popup(ordernumber) {
1037 var url = "/cgi-bin/koha/acqui/transferorder.pl?"
1038 + "ordernumber=" + ordernumber
1039 window.open(url, 'TransferOrder','width=600,height=400,toolbar=false,scrollbars=yes');
1042 function confirm_ediorder() {
1043 var is_confirmed = confirm(_("Are you sure you want to close this basket and generate an EDIFACT order?"));
1045 window.location = "/cgi-bin/koha/acqui/basket.pl?op=edi_confirm&basketno=[% basketno | html %]";
1051 $(document).ready(function(){
1052 $("#basketgroupid").change(function(){
1053 if($(this).val() == "new"){
1054 location.href="/cgi-bin/koha/acqui/basketgroup.pl?op=add&booksellerid=[% booksellerid | html %]";
1056 $(this).parent().submit();
1061 [% UNLESS ( grouped ) %]
1063 function confirm_reopen() {
1064 var skip = [% IF ( skip_confirm_reopen ) %] 1 [% ELSE %] 0 [% END %];
1065 var is_confirmed = skip || confirm(_("Are you sure you want to reopen this basket?"));
1067 window.location = "/cgi-bin/koha/acqui/basket.pl?op=reopen&basketno=[% basketno | html %]";
1071 [% END # /UNLESS grouped %]
1072 [% END # /UNLESS (closedate) %]
1074 $(document).ready(function() {
1075 var table_settings = [% TablesSettings.GetTableSettings( 'acqui', 'basket', 'orders', 'json' ) | $raw %];
1076 [% IF !(Koha.Preference('EDIFACT') && ediaccount) %]
1077 table_settings['columns'].splice(16, 1);
1079 KohaTable("orders", {
1080 "sPaginationType": "full",
1082 "exportColumns": [0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15[% IF (Koha.Preference('EDIFACT') && ediaccount) %],16[% END %]],
1085 var cancelledorderst = $("#cancelledorderst").dataTable($.extend(true, {}, dataTablesDefaults, {
1086 "sPaginationType": "full"
1088 $("#reopenbutton").on("click",function(e){
1092 // Generates a dynamic link for exporting the selections data as CSV
1093 $("#exportbutton, #export-csv-menu a").click(function() {
1094 // Building the url from currently checked boxes
1095 var url = '/cgi-bin/koha/acqui/basket.pl';
1096 url += $('#exportbutton').attr('href');
1097 if($(this).attr("data-value")) {
1098 url += '&csv_profile=' + $(this).attr("data-value");
1100 // And redirecting to the CSV page
1101 location.href = url;
1104 $("#select_managing_library").on("change", function(){
1105 $(this).parent().submit();
1108 $(".edit_delivery_date").on("click", function(e) {
1110 var ordernumber = $(this).data("ordernumber");
1111 var order_number_text = _(" (order number %s)").format(ordernumber);
1112 var modalTitle = $(this).attr("title") + " " + order_number_text;
1113 var delivery_date = $( "#delivery_date_" + ordernumber ).data("delivery_date");
1114 const estimated_delivery_date = document.querySelector("#estimated_delivery_date")._flatpickr;
1115 estimated_delivery_date.setDate( delivery_date );
1116 $("#dateEditor .modal-title").text(modalTitle);
1117 $("#date_ordernumber").val(ordernumber);
1118 $("#dateEditor").modal("show");
1121 $("#dateEditor").on('hidden.bs.modal', function (e) {
1122 $("#dateEditorLabel").html("");
1123 $("#dateEditor .modal-title").text("");
1124 $("#estimated_delivery_date").html( "" );
1125 $("#date_ordernumber").val("");
1129 function UserSearchPopup(f) {
1131 "/cgi-bin/koha/members/search.pl?columns=cardnumber,name,category,branch,action&selection_type=add&filter=baskets_managers",
1133 'width=1024, height=768, scrollbars=yes, toolbar=no,'
1137 function add_user(borrowernumber, borrowername) {
1138 var ids = $("#users_ids").val();
1139 if(ids.length > 0) {
1140 ids = ids.split(':');
1144 if (ids.indexOf(borrowernumber.toString()) < 0) {
1145 ids.push(borrowernumber);
1146 $("#users_ids").val(ids.join(':'));
1147 var li = '<li id="user_'+borrowernumber+'">'+borrowername
1148 + ' <a href="#" data-borrowernumber="'+borrowernumber+'" class="del_user"><i class="fa fa-trash"></i> '
1149 + _("Delete user") + '</a></li>';
1150 $("#users_names").prepend(li);
1151 $("#add_user_submit").show();
1157 function del_user(borrowernumber) {
1158 $("#user_"+borrowernumber).remove();
1159 var ids = $("#users_ids").val().split(':');
1160 ids.splice(ids.indexOf(borrowernumber.toString()), 1);
1161 $("#users_ids").val(ids.join(':'));
1162 $("#add_user_submit").show();
1167 [% INCLUDE 'intranet-bottom.inc' %]