8 [% INCLUDE 'doc-head-open.inc' %]
9 <title>[% IF ( ordernumber ) %]Modify order details (line #[% ordernumber | html %])[% ELSE %]New order[% END %] › Basket [% basketno | html %] › Acquisitions › Koha</title>
10 [% INCLUDE 'doc-head-close.inc' %]
13 <body id="acq_neworderempty" class="acq">
15 [% INCLUDE 'header.inc' %]
16 [% INCLUDE 'acquisitions-search.inc' %]
18 <nav id="breadcrumbs" aria-label="Breadcrumb" class="breadcrumb">
21 <a href="/cgi-bin/koha/mainpage.pl">Home</a>
24 <a href="/cgi-bin/koha/acqui/acqui-home.pl">Acquisitions</a>
27 <a href="/cgi-bin/koha/acqui/supplier.pl?booksellerid=[% booksellerid | uri %]">[% name | html %]</a>
30 <a href="/cgi-bin/koha/acqui/basket.pl?basketno=[% basketno | uri %]">Basket [% basketno | html %]</a>
33 [% IF ( ordernumber ) %]
35 <a href="#" aria-current="page">
36 Modify order details (line #[% ordernumber | html %])
41 <a href="#" aria-current="page">
49 [% INCLUDE 'blocking_errors.inc' %]
51 <div class="main container-fluid">
53 <div class="col-sm-10 col-sm-push-2">
57 [% IF ( ordernumber ) %]
64 <div class="dialog alert order_error" style="display:none"></div>
67 <div id="acqui_basket_summary">
68 <fieldset class="rows">
69 <legend>Basket details</legend>
71 [% IF ( basketnote ) %]<li><span class="label">Internal note:</span> [% basketnote | html %]</li>[% END %]
72 [% IF ( basketbooksellernote ) %]<li><span class="label">Vendor note:</span> [% basketbooksellernote | html %]</li>[% END %]
73 [% IF ( basketcontractno ) %]
74 <li><span class="label">Contract number: </span>[% basketcontractno | html %]</li>
75 <li><span class="label">Contract name:</span> <a href="/cgi-bin/koha/admin/aqcontract.pl?op=add_form&contractnumber=[% basketcontractno | uri %]">[% basketcontractname | html %]</a></li>
77 [% IF ( authorisedbyname ) %]<li><span class="label">Managed by:</span> [% authorisedbyname | html %]</li>[% END %]
78 [% IF ( creationdate ) %]<li><span class="label">Open on:</span> [% creationdate | $KohaDates %]</li>[% END %]
79 [% IF ( closedate ) %]
80 <form action="/cgi-bin/koha/acqui/basketgroup.pl" method="post">
81 <li><span class="label">Closed on:</span> [% closedate | $KohaDates %]</li>
82 [% IF ( basketgroups ) %]
83 <li>Basketgroup: <select id="basketgroupid" name="basketgroupid">
84 [% FOREACH basketgroup IN basketgroups %]
85 [% IF ( basketgroup.default ) %]
86 <option value="[% basketgroup.id | html %]" selected="selected">[% basketgroup.name | html %]</option>
88 <option value="[% basketgroup.id | html %]">[% basketgroup.name | html %]</option>
92 <input type="hidden" id="basketno" value="[% basketno | html %]" name="basketno" />
93 <input type="hidden" value="mod_basket" name="op" />
94 <input type="hidden" name="booksellerid" value="[% booksellerid | html %]" />
96 <fieldset class="action"><input type="submit" value="Change basketgroup" /></fieldset>
105 <form action="/cgi-bin/koha/acqui/addorder.pl" method="post" class="validated noEnterSubmit" id="Aform" onsubmit="return Check(this);" >
107 <fieldset class="rows">
108 <legend>Patrons</legend>
111 <span class="label">To notify on receiving:</span>
112 <div style="float:left">
113 <ul id="users_names" style="padding-left:0">
114 [% FOREACH user IN users %]
115 <li id="user_[% user.borrowernumber | html %]">
116 [% user.firstname | html %] [% user.surname | html %]
117 [<a onclick="del_user([% user.borrowernumber | html %]);" style="cursor:pointer">Delete user</a>]
121 <input type="hidden" id="users_ids" name="users_ids" value="[% users_ids | html %]" />
122 <input type="hidden" id="op" name="op" value="mod_users" />
123 <input type="button" id="add_user" onclick="UserSearchPopup();" value="Add user" />
129 <fieldset class="rows">
132 [% IF ( biblionumber ) %]
133 <span><a href="/cgi-bin/koha/cataloguing/addbiblio.pl?biblionumber=[% biblionumber | uri %]"> Edit record</a></span>
136 [% UNLESS ( existing ) %]
137 <input type="hidden" name="existing" value="no" />
139 <input type="hidden" name="ordernumber" value="[% ordernumber | html %]" />
140 <input type="hidden" name="basketno" value="[% basketno | html %]" />
141 <input type="hidden" name="booksellerid" value="[% booksellerid | html %]" />
142 <input type="hidden" name="biblionumber" value="[% biblionumber | html %]" />
143 <input type="hidden" name="listinc" id="listinc" value="[% listincgst | html %]" />
144 <input type="hidden" name="invoiceincgst" id="invoiceincgst" value="[% invoiceincgst | html %]" />
145 <input type="hidden" name="suggestionid" value="[% suggestionid | html %]" />
146 <input type="hidden" name="import_batch_id" value="[% import_batch_id | html %]" />
148 [% FOREACH c IN currencies %]
149 <input type="hidden" id="currency_rate_[% c.currency | html %]" name="[% c.currency | html %]" value="[% c.rate | html %]" />
152 [% IF NOT Koha.Preference('UseACQFrameworkForBiblioRecords') OR NoACQframework %]
154 [% IF ( biblionumber ) %]
155 <span class="label">Title</span>
156 <input type="hidden" name="title" value="[% title | html %]" /> <span class="title">[% title | html %]</span>
158 <label for="entertitle">Title: </label>
159 <input type="text" id="entertitle" size="50" name="title" value="[% title | html %]" class="focus" required="required" />
160 <span class="required">Required</span>
164 [% IF ( biblionumber ) %]
165 <span class="label">Author: </span>
166 <input type="hidden" name="author" id="author" value="[% author | html %]" />[% author | html %]
168 <label for="author">Author: </label>
169 <input type="text" size="50" name="author" id="author" value="[% author | html %]" />
173 [% IF ( biblionumber ) %]
174 <span class="label">Publisher: </span>
175 <input type="hidden" name="publishercode" id="publishercode" value="[% publishercode | html %]" />[% publishercode | html %]
177 <label for="publishercode"> Publisher: </label>
178 <input type="text" size="50" name="publishercode" id="publishercode" value="[% publishercode | html %]" />
182 [% IF ( biblionumber ) %]
183 <span class="label">Edition: </span>
184 <input type="hidden" name="editionstatement" id="editionstatement" value="[% editionstatement | html %]" />[% editionstatement | html %]
187 <label for="editionstatement">Edition: </label>
188 <input type="text" size="20" name="editionstatement" id="editionstatement" value="[% editionstatement | html %]" />
192 [% IF ( biblionumber ) %]
193 <span class="label">Publication year: </span>
194 <input type="hidden" name="publicationyear" id="publicationyear" value="[% publicationyear | html %]" />[% publicationyear | html %]
196 <label for="publicationyear">Publication year: </label>
197 <input type="text" size="10" name="publicationyear" id="publicationyear" value="[% publicationyear | html %]" />
201 [% IF ( biblionumber ) %]
202 <span class="label">ISBN: </span>
203 <input type="hidden" name="isbn" id="ISBN" value="[% isbn | html %]" />[% isbn | html %]
205 <label for="ISBN">ISBN: </label>
206 <input type="text" size="50" name="isbn" id="ISBN" value="[% isbn | html %]" />
211 [% IF ( biblionumber ) %]
212 <span class="label">EAN: </span>
213 <input type="hidden" name="ean" id="EAN" value="[% ean | html %]" />[% ean | html %]
215 <label for="EAN">EAN: </label>
216 <input type="text" size="20" name="ean" id="EAN" value="[% ean | html %]" />
221 [% IF ( biblionumber ) %]
222 <span class="label">Series: </span>
223 <input type="hidden" name="series" id="series" value="[% seriestitle | html %]" />[% seriestitle | html %]
225 <label for="series">Series: </label>
226 <input type="text" size="50" name="series" id="series" value="[% seriestitle | html %]" />
229 [% UNLESS ( biblionumber ) %]
230 [% IF ( itemtypeloop ) %]
232 <span class="label">Item type:</span>
233 <select name="itemtype" style="width:12em;">
234 [% FOREACH itemtype IN itemtypeloop %]
235 <option value="[% itemtype.itemtype | html %]">[% itemtype.description | html %]</option>
243 <input type="hidden" name="use_ACQ_framework" value="1" />
244 [% IF biblionumber %]
246 [% FOREACH field IN catalog_details %]
248 <div class="subfield_line">
249 <label>[% field.lib | html %] ([% field.tag | html %][% field.subfield | html %])</label>
250 [% field.value | html %]
257 [% FOREACH field IN catalog_details %]
259 <div class="subfield_line">
260 [% PROCESS display_subfield field=field %]
269 [% IF ( suggestionid ) %]
270 <fieldset class="rows">
271 <legend>Suggestion</legend>
274 <span class="label">Suggested by: </span>
275 [% surnamesuggestedby | html %][% IF ( firstnamesuggestedby ) %], [% firstnamesuggestedby | html %][% END %] (<a href="/cgi-bin/koha/suggestion/suggestion.pl?suggestionid=[% suggestionid | uri %]&op=show">suggestion #[% suggestionid | html %]</a>)
281 [% UNLESS subscriptionid || basket.is_standing %][% # it is a suggestion, we have not items %]
282 [% IF (AcqCreateItemOrdering) %]
284 <div id="items_list" style="display:none">
285 <p><strong>Items list</strong></p>
286 <div style="width:100%;overflow:auto;">
290 <th class="noExport">Actions</th>
292 <th>Home library</th>
293 <th>Holding library</th>
294 <th>Not for loan</th>
299 <th>Inventory number</th>
312 <fieldset class="rows" id="itemfieldset">
313 <legend>Item</legend>
314 [% IF ( NoACQframework ) %]
315 <div class="dialog message">No ACQ framework, using default. You should create a framework with code ACQ, the items framework would be used</div>
318 [% UNLESS Koha.Preference('autoBarcode') == 'OFF' %]
319 <div class="dialog message">The autoBarcode system preference is set to [% Koha.Preference('autoBarcode') | html %] and items with blank barcodes will have barcodes generated upon save to database</div>
322 <div id="outeritemblock"></div>
325 [% END %][%# | html UNLESS subscriptionid %]
326 [% END %][%# IF (AcqCreateItemOrdering) %]
327 <fieldset class="rows">
328 <legend>Accounting details</legend>
331 <label class="required" for="quantity">Quantity: </label>
332 [% IF subscriptionid %]
333 <input type="text" size="20" id="quantity" name="quantity" value="1" onchange="updateCosts();" />
334 [% ELSIF AcqCreateItemOrdering %]
335 [% IF basket.is_standing %]
336 <input type="text" readonly="readonly" size="20" id="quantity" name="quantity" value="1" />
338 <input type="text" readonly="readonly" size="20" id="quantity" name="quantity" value="0" />
341 [% IF basket.is_standing %]
342 <input type="text" readonly="readonly" size="20" id="quantity" name="quantity" value="1" />
344 <input type="text" size="20" id="quantity" name="quantity" value="[% quantityrec | html %]" onchange="updateCosts();" />
347 <span class="required">Required</span>
348 <!-- origquantityrec only here for javascript compatibility (additem.js needs it, useless here, useful when receiveing an order -->
349 <input id="origquantityrec" readonly="readonly" type="hidden" name="origquantityrec" value="1" />
351 [% IF subscription %]
354 Frequency: [% subscription.frequency.description | html %] |
355 [% IF subscription.numberlength %]Number of issues: [% subscription.numberlength | html %][% END %]
356 [% IF subscription.weeklength %]Number of weeks: [% subscription.weeklength | html %][% END %]
357 [% IF subscription.monthlength %]Number of months: [% subscription.monthlength | html %][% END %]
362 <label class="required" for="budget_id">Fund: </label>
363 [% active_count = 0 %]
364 [% IF !ordernumber %]
365 [% FOREACH budget_loo IN budget_loop %]
366 [% active_count= active_count + budget_loo.b_active %]
369 <select id="budget_id" name="budget_id">
370 <option value="">Select a fund</option>
371 [% FOREACH budget_loo IN budget_loop %]
372 [% level_indent_cnt = 0 %]
373 [% level_indent = "" %]
374 [% WHILE level_indent_cnt < budget_loo.b_level %]
375 [% level_indent = level_indent _ " -- " %]
376 [% level_indent_cnt = level_indent_cnt +1 %]
379 [% IF ( budget_loo.b_sel ) %]
380 [% active_count = 0 #select no other fund %]
381 <option value="[% budget_loo.b_id | html %]" selected="selected" data-sort1-authcat="[% budget_loo.b_sort1_authcat | html %]" data-sort2-authcat="[% budget_loo.b_sort2_authcat | html %]"
383 [% ELSIF active_count==1 && budget_loo.b_active %]
384 <option value="[% budget_loo.b_id | html %]" selected="selected" data-sort1-authcat="[% budget_loo.b_sort1_authcat | html %]" data-sort2-authcat="[% budget_loo.b_sort2_authcat | html %]"
387 [% bdgclass=budget_loo.b_active? "": "b_inactive" | html %]
388 <option value="[% budget_loo.b_id | html %]" class="[% bdgclass | html %]" data-sort1-authcat="[% budget_loo.b_sort1_authcat | html %]" data-sort2-authcat="[% budget_loo.b_sort2_authcat | html %]"
391 [% level_indent | html %][% budget_loo.b_txt | html %][% IF !budget_loo.b_active %] (inactive)[% END %]
395 <span class="required">Required</span>
396 <label for="showallbudgets" style="float:none;"> Show inactive:</label>
397 <input type="checkbox" id="showallbudgets" />
400 <label for="currency">Currency:</label>
401 <select name="currency" id="currency" onchange="updateCosts();">
402 [% FOREACH c IN currencies %]
403 [% IF ordernumber and c.currency == currency or not ordernumber and c.currency == vendor_currency %]
404 <option value="[% c.currency | html %]" selected="selected">[% c.currency | html %]</option>
405 [% ELSIF not c.archived %]
406 <option value="[% c.currency | html %]">[% c.currency | html %]</option>
412 <label for="listprice">Vendor price: </label>
413 <input type="text" size="20" name="listprice" id="listprice" value="[% listprice | html %]" onchange="updateCosts()" /> [% IF (listincgst == 1) %](tax inclusive)[% ELSE %](tax exclusive)[% END %]
416 <label for="uncertainprice">Uncertain price: </label>
417 [% IF ( uncertainprice ) %]
418 <input type="checkbox" name="uncertainprice" id="uncertainprice" value="1" checked="checked" />
420 <input type="checkbox" name="uncertainprice" id="uncertainprice" value="1" />
423 [% IF ( gst_values ) %]
425 <label for="tax_rate">Tax rate: </label>
426 <select name="tax_rate" id="tax_rate" onchange="updateCosts();">
427 [% SET gst_found = 0 %]
428 [% FOREACH gst IN gst_values %]
429 [% IF ( gst.option == tax_rate ) %]
430 <option value="[% gst.option | html %]" selected="selected">[% gst.option * 100 | html %]%</option>
431 [% SET gst_found = 1 %]
433 <option value="[% gst.option | html %]">[% gst.option * 100 | html %]%</option>
438 <option value="[% tax_rate | html %]" selected="selected">[% tax_rate * 100 | html %]%</option>
442 [% IF !gst_found %]<span class="required">Tax rate not defined in system preference TaxRates!</span>[% END %]
444 <input type="hidden" name="tax_rate" value="0" />
448 <label for="discount">Discount: </label>
449 [% IF ( orderdiscount ) %]
450 <input type="text" size="6" name="discount" id="discount" value="[% orderdiscount | html %]" onchange="updateCosts();" />%
452 <input type="text" size="6" name="discount" id="discount" value="[% discount | html %]" onchange="updateCosts();" />%
456 <label for="rrp">Retail price: </label>
457 <input type="text" size="20" name="rrp" id="rrp" value="[% rrp | html %]" /> (adjusted for [% cur_active | html %], [% IF (listincgst == 1) %]tax inclusive[% ELSE %]tax exclusive[% END %])
460 <label for="replacementprice">Replacement cost: </label>
461 <input type="text" size="20" name="replacementprice" id="replacementprice" value="[% replacementprice | html | $Price on_editing => 1 %]" />
464 <label for="ecost">Budgeted cost: </label>
465 <input type="text" size="20" name="ecost" id="ecost" value="[% ecost | html %]" readonly="readonly" /> [% IF (listincgst == 1) %](tax inclusive)[% ELSE %](tax exclusive)[% END %]
468 <label for="total">Total: </label>
469 <input type="text" id="total" size="20" name="total" value="[% total | html %]" readonly="readonly" /> (budgeted cost * quantity)
471 <li class="ordering_unitprice">
472 <label for="unitprice">Actual cost: </label>
473 <input type="text" id="unitprice" size="20" name="unitprice" value="[% unitprice | html %]" />
474 [% IF (invoiceincgst == 1) %](tax inc.)[% ELSE %](tax exc.)[% END %]
477 <label for="order_internalnote">Internal note: </label>
478 <textarea id="order_internalnote" cols="30" rows="3" name="order_internalnote" >[% IF ( order_internalnote ) %][% order_internalnote | html %][% END %]</textarea>
481 <label for="order_vendornote">Vendor note: </label>
482 <textarea id="order_vendornote" cols="30" rows="3" name="order_vendornote" >[% IF ( order_vendornote ) %][% order_vendornote | html %][% END %]</textarea>
484 <li><div class="hint">The 2 following fields are available for your own usage. They can be useful for statistical purposes</div>
485 <label for="sort1">Statistic 1: </label>
486 <input id="sort1" type="text" id="sort1" size="20" name="sort1" value="[% sort1 | html %]" />
488 <label for="sort2">Statistic 2: </label>
489 <input id="sort2" type="text" id="sort2" size="20" name="sort2" value="[% sort2 | html %]" />
493 <fieldset class="action">
494 <input type="hidden" name="subscriptionid" value="[% subscriptionid | html %]" />
495 <input type="submit" value="Save" />
496 [% IF (suggestionid) %]
497 <a class="cancel" href="/cgi-bin/koha/acqui/newordersuggestion.pl?booksellerid=[% booksellerid | html %]&basketno=[% basketno | html %]">Cancel</a>
499 [% IF subscriptionid %]
500 <a class="cancel" href="/cgi-bin/koha/acqui/newordersubscription.pl?booksellerid=[% booksellerid | html %]&basketno=[% basketno | html %]">Cancel</a>
502 <a class="cancel" href="/cgi-bin/koha/acqui/basket.pl?basketno=[% basketno | html %]">Cancel</a>
508 <div id="procModal" data-backdrop="static" class="modal fade" aria-labelledby="procModal" aria-hidden="true">
509 <div class="modal-dialog">
510 <div class="modal-content">
511 <div class="modal-body">
512 <h3>Processing multiple items</h3>
518 <div id="multiCountModal" class="modal fade" aria-labelledby="multiCountModal" aria-hidden="true">
519 <div class="modal-dialog">
520 <div class="modal-content">
521 <h3>Invalid number of copies</h3>
522 <p>Please enter a <strong>number</strong>, greater than or equal to 1</p>
528 </div> <!-- /.col-sm-10.col-sm-push-2 -->
530 <div class="col-sm-2 col-sm-pull-10">
532 [% INCLUDE 'acquisitions-menu.inc' %]
534 </div> <!-- /.col-sm-2.col-sm-pull-10 -->
535 </div> <!-- /.row -->
537 [% MACRO jsinclude BLOCK %]
538 [% Asset.js("js/acquisitions-menu.js") | $raw %]
539 [% Asset.js("js/acq.js") | $raw %]
540 [% Asset.js("js/additem.js") | $raw %]
541 [% Asset.js("js/cataloging.js") | $raw %]
542 [% INCLUDE 'calendar.inc' %]
547 [% IF (AcqCreateItemOrdering) %]
548 // Remove last itemblock if it is not in items_list
549 var lastitemblock = $("#outeritemblock > div:last");
550 var tobedeleted = true;
551 var listitems = $("#items_list tr");
552 $(listitems).each(function(){
553 if($(this).attr('idblock') == $(lastitemblock).attr('id')){
558 $(lastitemblock).remove();
563 var _alertString= _("Form not submitted because of the following problem(s)")+"\n";
565 _alertString +="-------------------------------------------------------------------\n\n";
567 if(isNull(ff.budget_id,1)){
569 _alertString += "\n- "+ _("You must select a fund");
572 if (!(isNum(ff.quantity,0)) || ff.quantity.value == 0){
574 _alertString += "\n- " + _("Quantity must be greater than '0'");
577 if (!(isNum(ff.listprice,0))){
579 _alertString += "\n- " + _("Vendor price must be a number");
582 if (!(isNum(ff.total,0))){
584 _alertString += "\n- " + _("Total must be a number");
587 if (totalExceedsBudget(ff.budget_id.value, ff.total.value ) ) {
589 _alertString += "\n- " + _("Order total (%s) exceeds budget available (%s)").format(ff.total.value, actTotal);
592 if ( ff.field_value ) {
593 var empty_item_mandatory = CheckMandatorySubfields(ff);
594 if (empty_item_mandatory > 0) {
597 "\n- " + _("%s item mandatory fields empty").format(empty_item_mandatory);
604 [% IF (AcqCreateItemOrdering) %]
606 $(lastitemblock).appendTo('#outeritemblock');
612 [% IF (AcqCreateItemOrdering) %]
613 if(check_additem('[% UniqueItemFields | html %]') == false) {
614 alert(_("Duplicate values detected. Please correct the errors and resubmit.") );
616 $(lastitemblock).appendTo('#outeritemblock');
623 $(document).ready(function(){
624 [% IF AcqCreateItemOrdering and not basket.is_standing %]
625 cloneItemBlock(0, '[% UniqueItemFields | html %]');
628 [% IF ( suggestionid ) %]updateCosts();[% END %]
629 $("#quantity").change(function() {
633 //We apply the fonction only for modify option
634 [% IF ( quantityrec and not subscriptionid ) %]
635 [% IF ( acqcreate ) %]
636 $('#quantity').blur(function(){
637 // if user decreases the quantity
638 if($(this).val() < [% quantityrec | html %]){
639 alert(_("You have deleted item(s) in the order, don't forget to delete it(them) in the catalog"));
642 // if user increases the quantity
643 alert(_("You can't add a new item, please create a new order line"));
644 // and we replace the original value
645 $(this).val([% quantityrec | html %])
646 updateCosts(); // blur is invoked after change which updated values
653 //keep a copy of all budgets before removing the inactives
654 disabledBudgetsCopy = $('#budget_id').html();
655 $('#budget_id .b_inactive').remove();
657 $('#showallbudgets').click(function() {
658 if ($(this).is(":checked")) {
659 $('#budget_id').html(disabledBudgetsCopy); //Puts back all the funds
662 $('#budget_id .b_inactive').remove();
666 $("#budget_id").change(function(){
667 var destination_sort1 = $(this).parents('fieldset.rows').find('input[name="sort1"]');
668 var sort1_authcat = $(this).find("option:selected").attr('data-sort1-authcat');
669 var sort1 = $(destination_sort1).val() || "";
670 if ( destination_sort1.length < 1 ) {
671 destination_sort1 = $(this).parents('fieldset.rows').find('select[name="sort1"]');
673 var destination_sort2 = $(this).parents('fieldset.rows').find('input[name="sort2"]');
674 var sort2_authcat = $(this).find("option:selected").attr('data-sort2-authcat');
675 var sort2 = $(destination_sort2).val() || "";
676 if ( destination_sort2.length < 1 ) {
677 destination_sort2 = $(this).parents('fieldset.rows').find('select[name="sort2"]');
679 getAuthValueDropbox( 'sort1', sort1_authcat, destination_sort1, sort1 );
680 getAuthValueDropbox( 'sort2', sort2_authcat, destination_sort2, sort2 );
682 $("#budget_id").change();
685 function UserSearchPopup(f) {
687 "/cgi-bin/koha/acqui/add_user_search.pl",
689 'width=740, height=450, scrollbars=yes, toolbar=no,'
693 function add_user(borrowernumber, borrowername) {
694 var ids = $("#users_ids").val();
696 ids = ids.split(':');
700 if (ids.indexOf(borrowernumber.toString()) < 0) {
701 ids.push(borrowernumber);
702 $("#users_ids").val(ids.join(':'));
703 var li = '<li id="user_'+borrowernumber+'">'+borrowername
704 + ' [<a style="cursor:pointer" onclick="del_user('+borrowernumber+');">'
705 + _("Delete user") + '</a>]</li>';
706 $("#users_names").append(li);
712 function del_user(borrowernumber) {
713 $("#user_"+borrowernumber).remove();
714 var ids = $("#users_ids").val().split(':');
715 ids.splice(ids.indexOf(borrowernumber.toString()), 1);
716 $("#users_ids").val(ids.join(':'));
721 [% INCLUDE 'intranet-bottom.inc' %]
723 [% BLOCK display_subfield %]
724 <label>[% field.lib | html %] ([% field.tag | html %][% field.subfield | html %])</label>
725 [% IF field.authorised_value %]
726 [% SWITCH field.authorised_value %]
727 [% CASE 'branches' %]
728 [% IF field.mandatory %]
729 <select name="bib_field_value" required="required">
731 <select name="bib_field_value">
733 <option value=""></option>
734 [% PROCESS options_for_libraries libraries => Branches.all( selected => "FIXME" ) %]
736 [% CASE 'itemtypes' %]
737 [% IF field.mandatory %]
738 <select name="bib_field_value" required="required">
740 <select name="bib_field_value">
742 <option value=""></option>
743 [% PROCESS options_for_item_types itemtypes => ItemTypes.Get(), selected_itemtype => "FIXME" %]
745 [% CASE 'cn_source' %]
747 [% PROCESS 'av-build-dropbox.inc' name="bib_field_value", category=field.authorised_value, default="FIXME" %]
750 [% IF field.mandatory %]
751 <input type="text" name="bib_field_value" value="[% field.value | html %]" required="required" size="50" />
753 <input type="text" name="bib_field_value" value="[% field.value | html %]" size="50" />
757 <input type="hidden" name="bib_kohafield" value="[% field.kohafield | html %]" />
758 <input type="hidden" name="bib_tag" value="[% field.tag | html %]" />
759 <input type="hidden" name="bib_subfield" value="[% field.subfield | html %]" />
760 [% IF field.mandatory %] <span class="required">Required</span>[% END %]