7 [% USE AuthorisedValues %]
8 [% PROCESS 'i18n.inc' %]
10 [% INCLUDE 'doc-head-open.inc' %]
11 [% SET destination = "circ" %]
12 <title>[% FILTER collapse %]
14 [% patron_in_title = INCLUDE 'patron-title.inc' invert_name = 1 no_html = 1 %]
15 [% tx("Batch check out to {patron}", { patron = patron_in_title }) | html %] ›
17 [% t("Circulation") | html %] ›
18 [% t("Koha") | html %]
20 [% INCLUDE 'doc-head-close.inc' %]
23 <body id="circ_circulation_batch_checkouts" class="circ">
25 [% WRAPPER 'header.inc' %]
26 [% INCLUDE 'circ-search.inc' %]
29 [% WRAPPER 'sub-header.inc' %]
30 [% WRAPPER breadcrumbs %]
31 [% WRAPPER breadcrumb_item %]
32 <a href="/cgi-bin/koha/circ/circulation-home.pl">Circulation</a>
35 [% WRAPPER breadcrumb_item %]
36 <a href="/cgi-bin/koha/circ/circulation.pl?borrowernumber=[% borrowernumber | uri %]">Check out to [% INCLUDE 'patron-title.inc' %]</a>
39 [% WRAPPER breadcrumb_item bc_active= 1 %]
40 <span>Batch check out</span>
42 [% END #/ WRAPPER breadcrumbs %]
43 [% END #/ WRAPPER sub-header.inc %]
45 <div class="main container-fluid">
48 <div class="col-sm-10 col-sm-push-2">
50 <div class="col-md-10 col-md-offset-1 col-lg-8 col-lg-offset-2">
53 <h1>Batch check out</h1>
56 [% INCLUDE 'members-toolbar.inc' %]
59 [% IF patron and not batch_allowed %]
60 <div class="dialog alert">You are not allowed to use batch checkout for this patron</div>
61 [% ELSIF patron and noissues and not checkout_infos %]
62 <div class="dialog alert">
65 [% INCLUDE 'blocked-fines.inc' fines = chargesamount %]
67 [% IF ( charges_guarantors_guarantees ) %]
69 <span class="circ-hlt">Charges:</span> Patron's guarantors and their other guarantees collectively owe [% charges_guarantors_guarantees | $Price %].
71 <span class="circ-hlt">Checkouts are BLOCKED because fine balance is OVER THE LIMIT.</span>
75 [% IF ( charges_guarantees ) %]
77 <span class="circ-hlt">Charges:</span> Patron's guarantees collectively owe [% chargesamount_guarantees | $Price %].
79 <span class="circ-hlt">Checkouts are BLOCKED because fine balance is OVER THE LIMIT.</span>
84 [% ELSIF patron and not checkout_infos %]
85 <form method="post" enctype="multipart/form-data" action="/cgi-bin/koha/circ/circulation.pl">
86 <fieldset id="circ_circulation_issue">
87 <label for="barcode">Checking out to [% INCLUDE 'patron-title.inc' %]</label>
88 <fieldset class="rows">
89 <legend>Use a file</legend>
91 <li><label for="uploadfile">File: </label> <input type="file" id="uploadfile" name="uploadfile" /></li>
94 <fieldset class="rows">
95 <legend>Or list barcodes one by one</legend>
98 <label for="barcodelist">Barcode list (one barcode per line): </label>
99 <textarea rows="10" cols="30" id="barcodelist" name="barcodelist"></textarea>
103 [% IF Koha.Preference('SpecifyDueDate') || Koha.Preference('OnSiteCheckouts') %]
104 <fieldset class="rows">
106 [% IF Koha.Preference('SpecifyDueDate') %]
107 <legend>Due date</legend>
109 <label for="duedatespec">Hard due date: [% INCLUDE 'date-format.inc' %]</label>
110 <input type="text" size="20" id="duedatespec" name="duedatespec" value="[% duedatespec | html %]" class="flatpickr" data-flatpickr-enable-time="true"/>
113 [% IF Koha.Preference('OnSiteCheckouts') %]
115 <div id="onsite_checkout-select">
116 <label for="onsite_checkout">On-site checkout:</label>
117 <input type="checkbox" id="onsite_checkout" name="onsite_checkout" class="circ_setting"/>
125 <input type="hidden" name="op" value="show" />
128 <fieldset class="action">
129 <input type="hidden" name="borrowernumber" id="borrowernumber" value="[% patron.borrowernumber | html %]" />
130 <input type="hidden" name="branch" value="[% branch | html %]" />
131 <input type="hidden" name="batch" value="1" />
132 <input type="submit" class="btn btn-primary" value="Check out" />
137 [% IF confirmation_needed && CAN_user_circulate_force_checkout %]
138 <h3>Batch checkout confirmation [% IF patron %] for [% INCLUDE 'patron-title.inc' invert_name = 1 %] [% END %]</h3>
139 <form method="post" action="/cgi-bin/koha/circ/circulation.pl" id="mainform" name="mainform" autocomplete="off">
141 <h3>Batch checkout information [% IF patron.borrowernumber %] for [% INCLUDE 'patron-title.inc' invert_name = 1 %] |[% batch | html %]|[% END %]</h3>
143 <table id="checkout_infos">
146 [% IF confirmation_needed && CAN_user_circulate_force_checkout %]
147 <th class="NoSort"></th>
150 <th class="anti-the">Title</th>
155 [% FOR checkout_info IN checkout_infos %]
157 [% IF confirmation_needed && CAN_user_circulate_force_checkout %]
159 [% IF checkout_info.NEEDSCONFIRMATION %]
160 <input type="checkbox" name="barcodes" value="[% checkout_info.barcode | html %]" checked="checked" />
164 <td>[% checkout_info.barcode | html %]</td>
166 [% INCLUDE 'biblio-title.inc' biblio=checkout_info.biblio link = 1 %] [% IF checkout_info.biblio.author %], by [% checkout_info.biblio.author | html %][% END %][% IF ( checkout_info.item.itemnotes ) %]- <span class="circ-hlt">[% checkout_info.item.itemnotes | $raw %]</span>[% END %] <a href="/cgi-bin/koha/catalogue/moredetail.pl?biblionumber=[% checkout_info.biblio.biblionumber | uri %]&itemnumber=[% checkout_info.item.itemnumber | uri %]#item[% checkout_info.item.itemnumber | uri %]">[% checkout_info.item.barcode | html %]</a>
169 [% IF checkout_info.NEEDSCONFIRMATION %]
170 <ul class="fa-ul warn">
171 [% IF checkout_info.AGE_RESTRICTION %]
172 <li><i class="fa fa-li fa-warning"></i>Age restriction [% checkout_info.AGE_RESTRICTION | html %].</li>
174 [% IF checkout_info.RENEW_ISSUE %]
175 <li><i class="fa fa-li fa-warning"></i>This item is currently checked out to this patron. Renew?</li>
177 [% IF checkout_info.RESERVE_WAITING %]
178 <li><i class="fa fa-li fa-warning"></i>This item is waiting for another patron.</li>
180 [% IF checkout_info.TRANSFERRED %]
181 <li><i class="fa fa-li fa-warning"></i>This item is on hold and being transferred for another patron.</li>
183 [% IF checkout_info.PROCESSING %]
184 <li><i class="fa fa-li fa-warning"></i>This item is on hold and being processed for another patron.</li>
186 [% IF checkout_info.ISSUED_TO_ANOTHER %]
187 <li><i class="fa fa-li fa-warning"></i>This item is checked out to another patron.
188 [% IF CAN_user_circulate_force_checkout %]
189 Check in and check out?
192 [% IF checkout_info.TOO_MANY %]
193 <li><i class="fa fa-li fa-warning"></i>Too many checked out.</li>
195 [% IF checkout_info.BORRNOTSAMEBRANCH %]
196 <li><i class="fa fa-li fa-warning"></i>This patron is from a different library ([% Branches.GetName( checkout_info.BORRNOTSAMEBRANCH ) | html %]).</li>
198 [% IF checkout_info.PATRON_CANT %]
199 <li><i class="fa fa-li fa-warning"></i>This patron can't check out this item per library circulation policy.</li>
201 [% IF checkout_info.NOT_FOR_LOAN_FORCING %]
202 [% IF checkout_info.itemtype_notforloan %]
203 <li><i class="fa fa-li fa-warning"></i>Item type is normally not for loan.</li>
204 [% ELSIF checkout_info.item_notforloan %]
205 [% item_notforloan_lib = AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.notforloan', authorised_value => checkout_info.item_notforloan ) %]
206 <li><i class="fa fa-li fa-warning"></i>Item is normally not for loan [% IF item_notforloan_lib %]([% item_notforloan_lib | html %])[% END %].</li>
209 [% IF checkout_info.USERBLOCKEDOVERDUE %]
210 <li><i class="fa fa-li fa-warning"></i>Patron has [% checkout_info.USERBLOCKEDOVERDUE | html %] overdue item(s).</li>
212 [% IF checkout_info.ITEM_LOST %]
213 <li><i class="fa fa-li fa-warning"></i>This item has been lost with a status of "[% checkout_info.ITEM_LOST | html %]."</li>
215 [% IF checkout_info.HIGHHOLDS %]
216 <li><i class="fa fa-li fa-warning"></i>High demand item. Loan period shortened to [% checkout_info.HIGHHOLDS.duration | html %] days (due [% checkout_info.HIGHHOLDS.returndate | html %]).</li>
218 [% IF checkout_info.HIGHHOLDS %] <!-- FIXME -->
220 $(document).ready(function() {
221 $("input[name=duedatespec]:hidden").val('[% checkout_info.HIGHHOLDS.returndate | html %]');
226 [% IF NOT checkout_info.IMPOSSIBLE && ( CAN_user_circulate_force_checkout || checkout_info.HIGHHOLDS ) && ( checkout_info.RESERVED || checkout_info.RESERVE_WAITING || checkout_info.TRANSFERRED || checkout_info.PROCESSING ) %] <!-- arbitrary choice, revert the hold is not possible-->
227 <li><i class="fa fa-li fa-warning"></i>This item is on hold for another patron. The hold will be overridden, but not cancelled.</li>
228 [% ELSIF checkout_info.RESERVED %]
229 <li><i class="fa fa-li fa-warning"></i>This item is on hold for another patron.</li>
232 [% IF checkout_info.PREVISSUE %]
233 <li>This item has previously been checked out to this patron.</li>
239 [% IF checkout_info.alert.ITEM_LOST || checkout_info.alert.OTHER_CHARGES %]
241 [% IF checkout_info.alert.ITEM_LOST %]
242 <li>This item has been lost with a status of "[% checkout_info.alert.ITEM_LOST | html %]."</li>
244 [% IF checkout_info.alert.OTHER_CHARGES %]
245 <li>The patron has unpaid charges for holds, rentals etc of [% checkout_info.alert.OTHER_CHARGES | $Price %].</li>
250 [% IF checkout_info.alert.RETURNED_FROM_ANOTHER %]
251 <div class="dialog alert">Item was checked out to [% INCLUDE 'patron-title.inc' patron = checkout_info.alert.RETURNED_FROM_ANOTHER.patron %] and was returned automatically.</div>
254 [% IF checkout_info.IMPOSSIBLE %]
255 <ul class="fa-ul error">
256 [% IF checkout_info.STATS %]
257 <li><i class="fa fa-li fa-exclamation"></i>Local use recorded.</li>
260 [% IF checkout_info.NOT_FOR_LOAN %]
261 [% IF checkout_info.itemtype_notforloan %]
262 <li><i class="fa fa-li fa-exclamation"></i>Item type not for loan.</li>
263 [% ELSIF checkout_info.item_notforloan %]
264 [% item_notforloan_lib = AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.notforloan', authorised_value => checkout_info.item_notforloan ) %]
265 <li><i class="fa fa-li fa-exclamation"></i>Item not for loan [% IF item_notforloan_lib %]([% item_notforloan_lib | html %])[% END %].</li>
268 [% IF checkout_info.WTHDRAWN %]
269 <li><i class="fa fa-li fa-exclamation"></i>Item has been withdrawn.</li>
271 [% IF checkout_info.RESTRICTED %]
272 <li><i class="fa fa-li fa-exclamation"></i>Item is restricted.</li>
274 [% IF checkout_info.GNA %]
275 <li><i class="fa fa-li fa-exclamation"></i>Patron's address is in doubt.</li>
277 [% IF checkout_info.CARD_LOST %]
278 <li><i class="fa fa-li fa-exclamation"></i>Patron's card is lost.</li>
280 [% IF checkout_info.DEBARRED %]
281 <li><i class="fa fa-li fa-exclamation"></i>Patron is restricted.</li>
283 [% IF checkout_info.NO_MORE_RENEWALS %]
284 <li><i class="fa fa-li fa-exclamation"></i>No more renewals possible.</li>
286 [% IF checkout_info.EXPIRED %]
287 <li><i class="fa fa-li fa-exclamation"></i>Patron's card is expired.</li>
289 [% IF checkout_info.ITEMNOTSAMEBRANCH %]
290 <li><i class="fa fa-li fa-exclamation"></i>This item belongs to [% Branches.GetName( checkout_info.itemhomebranch ) | html %] and cannot be checked out from this location.</li>
292 [% IF checkout_info.USERBLOCKEDREMAINING %]
293 <li><i class="fa fa-li fa-exclamation"></i>Patron has had overdue items and is blocked for [% checkout_info.USERBLOCKEDREMAINING | html %] day(s).</li>
295 [% IF checkout_info.USERBLOCKEDOVERDUE %]
296 <li><i class="fa fa-li fa-exclamation"></i>Checkouts are BLOCKED because patron has overdue items.</li>
298 [% IF checkout_info.TOO_MANY %]
299 <li><i class="fa fa-li fa-exclamation"></i>Too many checked out.</li>
301 [% IF checkout_info.UNKNOWN_BARCODE %]
302 <li><i class="fa fa-li fa-exclamation"></i>The barcode was not found [% checkout_info.barcode | html %].</li>
304 [% IF checkout_info.DEBT %]
305 <li><i class="fa fa-li fa-exclamation"></i>The patron has a debt of [% checkout_info.DEBT | $Price %].</li> <!-- Need debt_confirmed -->
310 [% IF checkout_info.issue.date_due %]
311 <li>Due on [% checkout_info.issue.date_due | $KohaDates as_due_date => 1 %]</li>
319 [% IF confirmation_needed && CAN_user_circulate_force_checkout %]
321 <legend>Please confirm checkout</legend>
322 <input type="hidden" name="borrowernumber" value="[% patron.borrowernumber | html %]" />
323 <input type="hidden" name="issueconfirmed" value="1" />
324 <input type="hidden" name="debt_confirmed" value="1" />
325 <input type="hidden" name="branch" value="[% branch | html %]" />
326 <input type="hidden" name="duedatespec" value="[% duedatespec | html %]" />
327 <input type="hidden" name="batch" value="1" />
328 <input type="hidden" name="onsite_checkout" value="[% onsite_checkout | html %]" />
329 <input type="submit" id="checkoutrenew" class="btn btn-primary" value="Checkout or renew" />
335 <div class="dialog message">This patron does not exist. <a href="/cgi-bin/koha/members/members-home.pl">Find another patron?</a></div>
339 </div> <!-- /.col-sm-10.col-sm-push-2 -->
341 <div class="col-sm-2 col-sm-pull-10">
343 [% INCLUDE 'circ-menu.inc' %]
345 </div> <!-- /.col-sm-2.col-sm-pull-10 -->
347 </div> <!-- /.row -->
349 [% MACRO jsinclude BLOCK %]
350 [% INCLUDE 'calendar.inc' %]
351 [% INCLUDE 'datatables.inc' %]
353 $(document).ready(function() {
354 if($('#barcodelist').length) {
355 $('#barcodelist').focus();
356 } else if ($('#checkoutrenew').length) {
357 $('#checkoutrenew').focus();
359 $("#checkout_infos").dataTable($.extend(true, {}, dataTablesDefaults, {
363 { "bSortable": false, "bSearchable": false, 'aTargets': [ 'NoSort' ] },
364 { "sType": "anti-the", "aTargets" : [ "anti-the" ] }
369 // On-site batch checkout
370 function toggle_onsite_checkout(){
371 if ( $("#onsite_checkout").prop('checked') ) {
372 const duedatespec_fp = document.querySelector("#duedatespec")._flatpickr;
373 duedatespec_fp.setDate("[% today_due_date_and_time | $KohaDates dateformat => 'iso', with_hours => 1 %]");
377 $("#onsite_checkout").click(function(){
378 toggle_onsite_checkout();
381 [% INCLUDE 'str/members-menu.inc' %]
382 [% Asset.js("js/members-menu.js") | $raw %]
385 [% INCLUDE 'intranet-bottom.inc' %]