2 [% IF (AllowOfflineCirculation) %]
3 [% SET manifestattr = 'manifest="/cgi-bin/koha/circ/offline-mf.pl"' %]
5 [% IF ( bidi && AllowOfflineCirculation ) %]<html lang="[% lang %]" dir="[% bidi %]" manifest="/cgi-bin/koha/circ/offline-mf.pl">
6 [% ELSIF ( bidi ) %]<html lang="[% lang %]" dir="[% bidi %]">
7 [% ELSIF ( AllowOfflineCirculation ) %]<html lang="[% lang %]" manifest="/cgi-bin/koha/circ/offline-mf.pl">
8 [% ELSE %]<html lang="[% lang %]">[% END %]
10 <title>Koha › Circulation</title>
11 [% INCLUDE 'doc-head-close.inc' %]
12 [% INCLUDE 'calendar.inc' %]
13 <script type="text/javascript" src="[% interface %]/lib/jquery/plugins/jquery.indexeddb.js"></script>
14 <script type="text/javascript" src="[% interface %]/[% theme %]/js/offlinecirc.js"></script>
15 <script type="text/javascript" src="[% interface %]/lib/jquery/plugins/jquery-ui-timepicker-addon.min.js"></script>
16 [% INCLUDE 'timepicker.inc' %]
17 <script type="text/javascript">
19 var ALERT_SUCCESSFUL_CHECKIN = _("Checked in item.");
20 var ALERT_MATERIALS = _("Note about the accompanying materials: %s");
21 var ALERT_RESTRICTED = _("Patron is RESTRICTED");
22 var ALERT_NO_MATCHING_ITEM = _("No item with barcode in offline database (transaction recorded anyway): %s");
23 var ALERT_NOT_CHECKED_OUT = _("Item not listed as checked out in offline database (transaction recorded anyway)");
24 var ALERT_ITEM_WITHDRAWN = _("Item has been withdrawn (transaction recorded anyway)");
25 var ALERT_ITEM_RESTRICTED = _("Item is restricted (transaction recorded anyway)");
26 var ALERT_ITEM_LOST = _("Item has been lost (transaction recorded anyway)");
27 var ALERT_NO_MATCHING_PATRON = _("No patron cardnumber in offline database (proceeding anyway): %s");
28 var ALERT_PATRON_GONE_NO_ADDRESS = _("Patron's address is in doubt (proceeding anyway)");
29 var ALERT_PATRON_CARD_LOST = _("Patron's card is lost");
30 var ALERT_PATRON_EXPIRED = _("Patron's card is expired (%s)");
31 var ALERT_PATRON_BLOCKED_TEMPORARY = _("Patron has had overdue items and is restricted until: %s");
32 var ALERT_PATRON_RESTRICTED = _("Patron is restricted");
33 var ALERT_PATRON_FINE = _("Patron has outstanding fines: %s");
34 var ALERT_PATRON_FINE_OVER_LIMIT = _("Patron fines are over limit: %s");
35 var UPLOAD_PENDING_MESSAGE = _("You have transactions in the offline circulation database on this computer that have not been uploaded.");
36 var NO_UPLOAD_PENDING_MESSAGE = _("You do not have any pending transactions in the offline circulation database on this computer.");
40 var dateformat = '[% IF ( dateformat_us ) %]mm/dd/yy[% ELSIF ( dateformat_metric ) %]dd/mm/yy[% ELSE %]yy-mm-dd[% END %]';
42 function checkin(barcode, item, error) {
43 var alerts = checkAlerts(barcode, item);
44 if (typeof item === 'undefined') {
47 item.title = item.title || _("(Unknown)");
48 item.author = item.author || _("(Unknown)");
49 item.homebranch = item.homebranch || "";
50 item.holdingbranch = item.holdingbranch || "";
51 item.callnumber = item.callnumber || "";
52 item.itemtype = item.itemtype || "";
53 item.barcode = item.barcode || barcode;
54 var trans = { "timestamp" : new Date().toMySQLString(),
59 $('.offline-home').hide();
60 $('.offline-sync').hide();
61 $('.offline-circulation').hide();
62 $('.offline-circulation-instructions').hide();
63 $('.offline-returns').show();
64 kohadb.recordTransaction(trans, function () {
65 $('#session-returned').show();
66 $('#already-checked-in tbody').prepend('<tr><td>' + item.title + '</td><td>' + item.author + '</td><td>' + barcode + '</td><td>' + item.homebranch + '</td><td>' + item.holdingbranch + '</td><td></td><td>' + item.callnumber + '</td><td>' + item.itemtype + '</td></tr>');
67 if (alerts.length > 0) {
68 $('#alerts').append('<div class="dialog alert"><h3>' + _("Check in message") + '</h3></div>');
69 for (var msg in alerts) {
70 $('#alerts .dialog').append('<p>' + alerts[msg] + '</p');
73 $('#alerts').append('<div class="dialog"><h3>' + ALERT_SUCCESSFUL_CHECKIN + '</h3></div>');
76 setTimeout(function() { $('#checkin-barcode').trigger('focus'), 1 });
79 function checkAlerts(barcode, item) {
81 if (typeof item === 'undefined') {
82 alerts.push(ALERT_NO_MATCHING_ITEM.format(barcode));
84 if (typeof item.materials !== 'undefined' && item.materials != null) {
85 alerts.push(ALERT_MATERIALS.format(item.materials));
91 function showSyncInfo() {
92 kohadb.loadSetting("item-timestamp", showTimestamp);
93 kohadb.loadSetting("patron-timestamp", showTimestamp);
94 kohadb.loadSetting("issue-timestamp", showTimestamp);
95 kohadb.loadSetting("dirty", function (key, val) {
97 $('#upload-message').text(UPLOAD_PENDING_MESSAGE);
99 $('#upload-message').text(NO_UPLOAD_PENDING_MESSAGE);
104 function synchronize() {
105 kohadb.saveSetting("userid", "[% loggedinusername %]");
106 kohadb.saveSetting("branchcode", "[% LoginBranchcode %]");
108 [% UNLESS (AllowOfflineCirculation) %]
112 $('#download-records').click(reloadRecords);
113 $('#upload-transactions').click(function () {
114 $('.loading-overlay div').text(_("Uploading transactions, please wait..."));
115 $('.loading-overlay').show();
118 url: "/cgi-bin/koha/offline_circ/service.pl",
119 }).done(function (data) {
121 $('.loading-overlay').hide();
122 alert(_("Please log in to Koha and try again. (Error: '%s')").format(data));
124 var uploadIter = $.indexedDB("koha").objectStore("transactions").each(uploadTransaction);
125 uploadIter.done(function() {
126 $.indexedDB("koha").transaction(["transactions"]).then(function(){
128 }, function(transaction){
129 transaction.objectStore("transactions").clear();
131 $('.loading-overlay').hide();
132 kohadb.saveSetting("dirty", false);
133 $('#upload-message').text(NO_UPLOAD_PENDING_MESSAGE);
141 function showTimestamp(key, value) {
142 if (typeof value !== 'undefined') {
143 var ts = new Date(value);
144 $('#' + key).text($.datepicker.formatDate(dateformat, ts) + ' ' + ts.toTimeString());
146 $('#' + key).text(_("(never)"));
150 function reloadRecords(ev) {
151 $(".loading-overlay div").text(_("Loading records, please wait..."));
152 $(".loading-overlay").show();
154 $.indexedDB("koha").transaction(["patrons", "items", "issues"]).then(function(){
157 }, function(transaction){
158 transaction.objectStore("patrons").clear();
159 transaction.objectStore("items").clear();
160 transaction.objectStore("issues").clear();
162 if (typeof ev !== 'undefined') {
163 ev.stopPropagation();
167 function uploadTransaction(transaction) {
170 url: "/cgi-bin/koha/offline_circ/service.pl",
171 data: { "userid" : kohadb.settings.userid,
172 "branchcode" : kohadb.settings.branchcode,
173 "timestamp" : transaction.value.timestamp,
174 "action" : transaction.value.action,
175 "barcode" : transaction.value.barcode,
176 "cardnumber" : transaction.value.cardnumber,
177 "amount" : transaction.value.amount,
181 return undefined, true;
184 function finishedLoading() {
185 kohadb.saveSetting('item-timestamp', start.toISOString())
186 kohadb.saveSetting('patron-timestamp', start.toISOString())
187 kohadb.saveSetting('issue-timestamp', start.toISOString())
188 showTimestamp('item-timestamp', start.toISOString());
189 showTimestamp('patron-timestamp', start.toISOString());
190 showTimestamp('issue-timestamp', start.toISOString());
191 $(".loading-overlay").hide();
194 function loadRecords(page) {
195 [% IF (AllowOfflineCirculation) %]
196 $(".loading-overlay div").text(_("Loading page %s, please wait...").format(page));
197 $(".loading-overlay").show();
200 url: "/cgi-bin/koha/offline_circ/download.pl",
201 data: { "data": "all",
205 }).done(function (data) {
206 $.indexedDB("koha").transaction(["patrons", "items", "issues"]).then(function(){
210 setTimeout(function () { loadRecords(page + 1); }, 200);
213 }, function(transaction){
215 var patrons = transaction.objectStore("patrons");
216 $.each(data.patrons, function () {
221 var items = transaction.objectStore("items");
222 $.each(data.items, function () {
227 var issues = transaction.objectStore("issues");
228 $.each(data.issues, function () {
237 function validate1(date) {
238 var today = new Date();
239 if ( date < today ) {
246 function loadPatron(barcode) {
247 $('#oldissues').hide();
248 $('#session-issues').hide();
249 $('#issuest tbody').empty();
250 $('#session-payments').hide();
251 $('.checkout-count').text(0);
252 $.indexedDB("koha").transaction(["patrons", "issues"]).then(function() {
254 }, function(transaction){
255 var patrons = transaction.objectStore("patrons");
256 patrons.get(barcode).done(function (patron, error) {
257 showPatron(barcode, patron, error);
259 var issuesidx = transaction.objectStore("issues").index("cardnumber");
260 $('#oldissuest tbody').empty();
261 issuesidx.each(function (item) {
262 $('#oldissues').show();
263 $('#oldissuest tbody').append("<tr><td>" + item.value.date_due + "</td><td>" + item.value.title + "</td><td>" + item.value.barcode + "</td><td>" + item.value.itype + "</td><td>" + item.value.issuedate + "</td><td>" + item.value.issuebranch + "</td><td>" + item.value.callnumber + "</td><td>" + "" + "</td></tr>");
264 $('.checkout-count').text(parseInt($('.checkout-count').text()) + 1);
269 function checkout(barcode, item, error) {
270 var alerts = checkAlerts(barcode, item);
271 if (typeof item === 'undefined') {
274 item.title = item.title || "";
275 item.author = item.author || "";
276 item.homebranch = item.homebranch || "";
277 item.holdingbranch = item.holdingbranch || "";
278 item.callnumber = item.callnumber || "";
279 item.itemtype = item.itemtype || "";
280 if ($('#duedatespec').val().length === 0) {
281 alert(_("You must set a due date in order to use offline circulation!"));
282 setTimeout(function() { $('#duedatespec').trigger('focus'), 1 });
285 var date_due = new Date($('#duedatespec').datepicker('getDate'));
286 var trans = { "timestamp" : new Date().toMySQLString(),
288 "cardnumber" : curpatron.cardnumber,
289 "date_due" : date_due.toMySQLString(),
292 $('#alerts').empty();
293 kohadb.recordTransaction(trans, function () {
294 $('#session-issues').show();
295 $('#issuest tbody').prepend('<tr><td>' + $.datepicker.formatDate(dateformat, date_due) + date_due.toTimeString() + '</td><td>' + item.title + '</td><td>' + barcode + '</td><td>' + item.itemtype + '</td><td>' + $.datepicker.formatDate(dateformat, new Date()) + '</td><td>' + kohadb.settings.branchcode + '</td><td>' + item.callnumber + '</td><td></td></tr>');
296 $('.checkout-count').text(parseInt($('.checkout-count').text()) + 1);
297 if (alerts.length > 0) {
298 $('#alerts').append('<div class="dialog alert"><h3>' + _("Check out message") + '</h3></div>');
299 for (var msg in alerts) {
300 $('#alerts .dialog').append('<p>' + alerts[msg] + '</p');
303 $('#checkout-barcode').val('');
307 function recordFine(amount) {
308 var timestamp = new Date()
309 var trans = { "timestamp" : timestamp.toMySQLString(),
310 "cardnumber" : curpatron.cardnumber,
312 "action" : "payment",
314 kohadb.recordTransaction(trans, function () {
315 $('#session-payments').show();
316 $('#session-payments tbody').prepend('<tr><td>' + amount + '</td><td>' + $.datepicker.formatDate(dateformat, timestamp) + timestamp.toTimeString() + '</td></tr>');
317 $('.fine-amount').text(parseInt($('.fine-amount').text()) - amount);
321 function checkPatronAlerts(cardnumber, patron) {
323 if (typeof patron === 'undefined') {
324 alerts.push(ALERT_NO_MATCHING_PATRON.format(cardnumber));
326 if (patron.gonenoaddress !== '0') {
327 alerts.push(ALERT_PATRON_GONE_NO_ADDRESS);
329 if (patron.lost !== '0') {
330 alerts.push(ALERT_PATRON_CARD_LOST);
332 if (patron.debarred !== null) {
333 if (patron.debarred != '9999-12-31') {
334 alerts.push(ALERT_PATRON_BLOCKED_TEMPORARY.format($.datepicker.formatDate(dateformat, new Date(patron.debarred))));
336 alerts.push(ALERT_PATRON_RESTRICTED);
339 if (new Date(patron.dateexpiry) < new Date()) {
340 alerts.push(ALERT_PATRON_EXPIRED.format($.datepicker.formatDate(dateformat, new Date(patron.dateexpiry))));
342 if (parseInt(patron.fine) > [% maxoutstanding %]) {
343 alerts.push(ALERT_PATRON_FINE_OVER_LIMIT.format(patron.fine));
344 } else if (parseInt(patron.fine) > 0) {
345 alerts.push(ALERT_PATRON_FINE.format(patron.fine));
353 function showPatron(barcode, patron, error) {
354 var alerts = checkPatronAlerts(barcode, patron);
355 if (typeof patron === 'undefined') {
358 patron.surname = patron.surname || "";
359 patron.firstname = patron.firstname || "";
360 patron.othernames = patron.othernames || "";
361 patron.address = patron.address || "";
362 patron.address2 = patron.address2 || "";
363 patron.city = patron.city || "";
364 patron.state = patron.state || "";
365 patron.country = patron.country || "";
366 patron.zipcode = patron.zipcode || "";
367 patron.phone = patron.phone || "";
368 patron.mobile = patron.mobile || "";
369 patron.phonepro = patron.phonepro || "";
370 patron.email = patron.email || "";
371 patron.emailpro = patron.emailpro || "";
372 patron.categorycode = patron.categorycode || "";
373 patron.branchcode = patron.branchcode || "";
374 patron.cardnumber = barcode;
375 patron.fine = patron.fine || "0";
377 patron.name = patron.firstname + (patron.othernames.length > 0 ? " (" + patron.othernames + ") " : " ") + patron.surname + " (" + barcode + ")";
378 if (patron.name.length > 0) {
379 $('.patron-title').text(patron.name);
381 $('.patron-title').text(_("Unrecognized patron (%s)").format(barcode));
383 if (patron.address.length > 0 || patron.address2.length > 0) {
384 $('#patron-address-1').text(patron.address);
385 $('#patron-address-2').text(patron.address2);
387 $('#patron-address-1').html('<span class="empty" id="noaddressstored">' + _("No address stored.") + '</span></li>');
388 $('#patron-address-2').text('');
390 if (patron.city.length > 0) {
391 $('#patron-address-parts').text(patron.city + (patron.state.length > 0 ? ", " + patron.state : "") + " " + patron.zipcode + (patron.country.length > 0 ? ", " + patron.country : ""));
393 $('#patron-address-parts').html('<span class="empty" id="nocitystored">' + _("No city stored.") + '</span></li>');
395 if (patron.phone.length > 0 || patron.mobile.length > 0 || patron.phonepro.length > 0) {
396 $('#patron-phone').text((patron.phone.length > 0 ? patron.phone : (patron.mobile.length > 0 ? patron.mobile : (patron.phonepro.length > 0 ? patron.phonepro : ''))));
398 $('#patron-phone').html('<span class="empty" id="nophonestored">' + _("No phone stored.") + '</span></li>');
400 if (patron.email.length > 0 || patron.emailpro.length > 0) {
401 $('#patron-email').text((patron.email.length > 0 ? patron.email : (patron.emailpro.length > 0 ? patron.emailpro : "")));
403 $('#patron-email').html('<span class="empty" id="noemailstored">' + _("No email stored.") + '</span></li>');
405 if (patron.categorycode.length > 0) {
406 $('#patron-category').text(_("Category: %s").format(patron.categorycode));
408 $('#patron-category').html('<span class="empty" id="unknowncategory">' + _("Category code unknown.") + '</span></li>');
410 if (patron.branchcode.length > 0) {
411 $('#patron-library').text(_("Home library: %s").format(patron.branchcode));
413 $('#patron-library').html('<span class="empty" id="unknowncategory">' + _("Home library unknown.") + '</span></li>');
415 $('.fine-amount').text(patron.fine);
416 $('#alerts').empty();
417 if (alerts.length > 0) {
418 $('#alerts').append('<div class="dialog alert"><h3>' + _("Check out message") + '</h3></div>');
419 for (var msg in alerts) {
420 $('#alerts .dialog').append('<p>' + alerts[msg] + '</p>');
424 $('#yui-main').show();
425 setTimeout(function() { $('#checkout-barcode').trigger('focus'), 1 });
428 // This next bit of code is to deal with the updated session issue
429 window.addEventListener('load', function(e) {
430 window.applicationCache.addEventListener('updateready', function(e) {
431 if (window.applicationCache.status == window.applicationCache.UPDATEREADY) {
432 // Browser downloaded a new app cache.
433 // Swap it in and reload the page to get the new hotness.
434 window.applicationCache.swapCache();
435 if (confirm(_("A new version of this site is available. Load it?"))) {
436 window.location.reload();
439 // Manifest didn't changed. Nothing new to server.
445 $(document).ready(function () {
447 $('#header_search #circ_search .tip').text(_("Enter patron card number:"));
449 $('ul[aria-labelledby="drop3"]').html('<li><a class="toplinks">You cannot change your branch or logout while using offline circulation</a></li>');
452 $('#checkin-form, #checkin_search form').submit(function (event) {
453 event.preventDefault();
454 var barcode = $('input[name="barcode"]', this).val();
455 $('input[name="barcode"]', this).val('');
456 $.indexedDB("koha").transaction(["items"]).then(function() {
458 }, function(transaction){
459 var items = transaction.objectStore("items");
460 items.get(barcode).done(function (item, error) {
461 checkin(barcode, item, error);
466 $('#go-to-home').click(function () {
467 $('#alerts').empty();
468 $('.offline-sync').hide();
469 $('.offline-circulation').hide();
470 $('.offline-returns').hide();
471 $('.offline-circulation-instructions').hide();
472 $('.offline-home').show();
475 $('#go-to-returns').click(function () {
476 $('#alerts').empty();
477 $('.offline-home').hide();
478 $('.offline-sync').hide();
479 $('.offline-circulation').hide();
480 $('.offline-circulation-instructions').hide();
481 $('.offline-returns').show();
482 setTimeout(function() { $('#checkin-form input[name="barcode"]').trigger('focus'), 1 });
485 $('#go-to-circ').click(function () {
486 $('#alerts').empty();
487 $('.offline-home').hide();
488 $('.offline-sync').hide();
489 $('.offline-returns').hide();
490 $('.offline-circulation').hide();
491 $('.offline-circulation-instructions').show();
492 $('#header_search').tabs("option", "active", 0);
493 setTimeout(function() { $('#circ_search input[name="findborrower"]').trigger('focus'), 1 });
496 $('#go-to-sync').click(function () {
497 $('#alerts').empty();
501 url: "/cgi-bin/koha/offline_circ/list.pl",
502 success: function () {
503 $('.offline-home').hide();
504 $('.offline-returns').hide();
505 $('.offline-circulation').hide();
506 $('.offline-circulation-instructions').hide();
507 $('.offline-sync').show();
511 alert(_("You are offline and therefore cannot sync your database"));
516 $('#go-to-pending').click(function (ev) {
517 $('#alerts').empty();
521 url: "/cgi-bin/koha/offline_circ/list.pl",
522 success: function () {
523 window.location = '/cgi-bin/koha/offline_circ/list.pl';
526 alert(_("You are offline and therefore cannot process pending operations"));
531 $('#patronsearch').submit(function (event) {
532 event.preventDefault();
533 loadPatron($('#findborrower').val());
534 $('.offline-home').hide();
535 $('.offline-returns').hide();
536 $('.offline-sync').hide();
537 $('.offline-circulation-instructions').hide();
538 $('.offline-circulation').show();
539 $('#findborrower').val('');
540 setTimeout(function() { $('#checkout-barcode').trigger('focus'), 1 });
543 $('#pay-fine').click(function (event) {
544 event.preventDefault();
545 recordFine($('#pay-fine-amount').val());
548 $('#patronlists').tabs();
550 $("#newduedate").datetimepicker({
551 minDate: 1, // require that renewal date is after today
555 $("#duedatespec").datetimepicker({
556 onClose: function(dateText, inst) {
557 if (validate_date(dateText, inst) ) {
558 setTimeout(function() { $('#checkout-barcode').trigger('focus'), 1 });
564 $('#mainform').submit(function (event) {
565 event.preventDefault();
566 var barcode = $('#checkout-barcode').val();
567 $.indexedDB("koha").transaction(["items"]).then(function() {
569 }, function(transaction){
570 var items = transaction.objectStore("items");
571 items.get(barcode).done(function (item, error) {
572 checkout(barcode, item, error);
580 <body id="circ_offline" class="circ">
581 [% INCLUDE 'header.inc' %]
582 [% INCLUDE 'circ-search.inc' %]
583 <div class="loading-overlay" style="display: none;">
584 <div>Downloading records, please wait...</div>
587 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> › <a id="go-to-home" href="#offline-home">Offline circulation</a></div>
589 <div id="doc3" class="yui-t2">
593 <audio id="alert_sound" src="[% interface %]/prog/sound/critical.ogg" preload="auto"></audio>
594 <audio id="success_sound" src="[% interface %]/prog/sound/beep.ogg" preload="auto"></audio>
596 <div id="alerts" class="yui-b">
598 [% UNLESS (AllowOfflineCirculation) %]
599 <div id="noofflinecircwarning" class="dialog alert">
600 <p><strong>Warning:</strong> Offline Circulation has been disabled. You may continue and record transactions, but patron and item information will not be available.</p>
604 <div id="offline-home" class="yui-b offline-home">
606 <h1>Offline circulation</h1>
607 <div class="yui-u first">
609 <li><a id="go-to-circ" href="#offline-circulation">Check out</a></li>
610 <li><a id="go-to-returns" href="#offline-returns">Check in</a></li>
615 <p><strong>Note:</strong> You must be online to use these options.</p>
617 <li><a id="go-to-sync" href="#offline-sync">Synchronize</a></li>
618 <li><a id="go-to-pending" href="/cgi-bin/koha/offline_circ/list.pl">Pending offline circulation actions</a>
624 <div id="offline-sync" style="display: none;" class="yui-b offline-sync">
625 <div id="toolbar" class="btn-toolbar">
626 [% IF (AllowOfflineCirculation) %]
627 <a href="#" id="download-records" class="btn btn-small"><i class="fa fa-arrow-down"></i>Download records</a>
629 <a href="#" id="upload-transactions" class="btn btn-small"><i class="fa fa-arrow-up"></i>Upload transactions</a>
632 <h1>Offline circulation</h1>
633 <div class="yui-u first">
634 <div id="download-message">
635 In order for offline circulation to work on this computer,
636 your library's records must be up-to-date on this computer:
638 <li>Patron records were last synced on: <span id="patron-timestamp">(checking)</span></li>
639 <li>Item records were last synced on: <span id="item-timestamp">(checking)</span></li>
640 <li>Circulation records were last synced on: <span id="issue-timestamp">(checking)</span></li>
646 <div id="upload-message">
648 <div>View <a href="/cgi-bin/koha/offline_circ/list.pl">pending offline circulation actions</a></div>
653 <div id="offline-returns" style="display: none;" class="yui-b offline-returns">
655 <form id="checkin-form" method="post" action="/cgi-bin/koha/circ/returns.pl" autocomplete="off" >
656 <div class="yui-u first">
658 <legend>Check In</legend>
659 <label for="checkin-barcode">Enter item barcode: </label>
660 <input name="barcode" id="checkin-barcode" size="14" class="focus"/>
661 <input type="submit" class="submit" value="Submit" />
667 <div id="session-returned" style="display: none;">
668 <h2>Checked-in items</h2>
669 <table id="already-checked-in">
671 <tr><th>Title</th><th>Author</th><th>Barcode</th><th>Home library</th><th>Holding library</th><th>Shelving location</th><th>Call number</th><th>Type</th></tr>
679 <div style="display: none;" class="yui-b offline-circulation-instructions">
681 Scan a patron barcode to start.
685 <div id="offline-circulation" style="display: none;" class="yui-b offline-circulation">
687 <form method="post" action="/cgi-bin/koha/circ/offline.pl" id="mainform" name="mainform" autocomplete="off">
688 <fieldset id="circ_circulation_issue">
689 <span id="clearscreen"><a href="/cgi-bin/koha/circ/offline.pl" title="Clear screen">x</a></span>
690 <label for="checkout-barcode">Checking out to <span class="patron-title"></span></label>
691 <div class="hint">Enter item barcode:</div>
692 <input type="text" name="barcode" id="checkout-barcode" class="barcode focus" size="14" />
693 <input type="submit" value="Check Out" />
695 <div class="date-select">
696 <div class="hint">Specify due date [% INCLUDE 'date-format.inc' %]: </div>
697 <input type="text" size="13" id="duedatespec" name="duedatespec" value="[% duedatespec %]" />
698 <label for="stickyduedate"> Remember for session:</label>
699 <input type="checkbox" id="stickyduedate" onclick="this.form.barcode.focus();" name="stickyduedate" checked="checked" />
700 <input type="button" class="action" id="cleardate" value="Clear" name="cleardate" onclick="this.checked = false; this.form.duedatespec.value = ''; this.form.stickyduedate.checked = false; this.form.barcode.focus(); return false;" />
706 <div class="yui-g"><div id="patronlists" class="toptabs">
708 <li><a href="#checkouts"><span class="checkout-count">0</span> Checkouts</a></li>
709 <li><a href="#fines"><span class="fine-amount">0</span> in fines</a></li>
712 <!-- SUMMARY : TODAY & PREVIOUS ISSUES -->
714 <div id="session-issues">
717 <th scope="col">Due date</th>
718 <th scope="col">Title</th>
719 <th scope="col">Barcode</th>
720 <th scope="col">Item type</th>
721 <th scope="col">Checked out on</th>
722 <th scope="col">Checked out from</th>
723 <th scope="col">Call no</th>
724 <th scope="col">Charge</th>
732 <h5>Previous checkouts</h5>
733 <table id="oldissuest">
735 <th scope="col">Due date</th>
736 <th scope="col">Title</th>
737 <th scope="col">Barcode</th>
738 <th scope="col">Item type</th>
739 <th scope="col">Checked out on</th>
740 <th scope="col">Checked out from</th>
741 <th scope="col">Call no</th>
742 <th scope="col">Charge</th>
751 <span class="patron-title"></span> has <span class="fine-amount">0</span> in fines. If you would like you can record payments.
752 <fieldset><legend>Pay fines</legend>
753 <label for="pay-fine-amount">Fine amount: </label><input type="text" name="pay-fine-amount" id="pay-fine-amount"/>
754 <button id="pay-fine" class="submit">Pay fine</button>
756 <table id="session-payments" style="display: none;">
757 <thead><tr><th>Amount</th><th>Timestamp</th></tr></thead>
767 <div class="yui-b offline-circulation" style="display: none;">
768 <div class="patroninfo"><h5 class="patron-title"> </h5>
770 <li id="patron-address-1"></li>
771 <li id="patron-address-2"></li>
772 <li id="patron-address-parts"><!-- city, state, zipcode, country --></li>
773 <li id="patron-phone"></li>
774 <li id="patron-email"></li>
775 <li id="patron-category"></li>
776 <li id="patron-library"></li>
782 [% INCLUDE 'intranet-bottom.inc' %]