7 [% INCLUDE 'doc-head-open.inc' %]
8 <title>Koha › ILL requests ›</title>
9 [% INCLUDE 'doc-head-close.inc' %]
10 [% Asset.js("lib/jquery/plugins/jquery.checkboxes.min.js") | $raw %]
11 [% Asset.css("css/datatables.css") | $raw %]
12 [% INCLUDE 'datatables.inc' %]
13 [% INCLUDE 'calendar.inc' %]
14 <script type="text/javascript">
16 $(document).ready(function() {
18 // Illview Datatable setup
22 // Filters that are active
23 var activeFilters = {};
25 // Fields we don't want to display
39 // Fields we need to expand (flatten)
46 // This is auto populated
49 // The core fields that should be displayed first
64 'action' // Action should always be last
70 prep: function(tableData, oData) {
72 tableData.forEach(function(row) {
73 var resolvedName = getStatusName(
74 oData[0].capabilities[row.status].name
76 uniques[resolvedName] = 1
78 Object.keys(uniques).sort().forEach(function(unique) {
79 $('#illfilter_status').append(
80 '<option value="' + unique +
81 '">' + unique + '</option>'
85 listener: function() {
87 $('#illfilter_status').change(function() {
88 var sel = $('#illfilter_status option:selected').val();
89 if (sel && sel.length > 0) {
90 activeFilters[me] = function() {
91 table.column(6).search(sel);
94 if (activeFilters.hasOwnProperty(me)) {
95 delete activeFilters[me];
101 $('#illfilter_status').val('');
105 prep: function(tableData, oData) {
107 tableData.forEach(function(row) {
108 uniques[row.library.branchname] = 1
110 Object.keys(uniques).sort().forEach(function(unique) {
111 $('#illfilter_branchname').append(
112 '<option value="' + unique +
113 '">' + unique + '</option>'
117 listener: function() {
118 var me = 'pickupBranch';
119 $('#illfilter_branchname').change(function() {
120 var sel = $('#illfilter_branchname option:selected').val();
121 if (sel && sel.length > 0) {
122 activeFilters[me] = function() {
123 table.column(5).search(sel);
126 if (activeFilters.hasOwnProperty(me)) {
127 delete activeFilters[me];
133 $('#illfilter_branchname').val('');
137 listener: function() {
139 $('#illfilter_barcode').change(function() {
140 var val = $('#illfilter_barcode').val();
141 if (val && val.length > 0) {
142 activeFilters[me] = function() {
143 table.column(3).search(val);
146 if (activeFilters.hasOwnProperty(me)) {
147 delete activeFilters[me];
153 $('#illfilter_barcode').val('');
158 $('#illfilter_datemodified_start, #illfilter_datemodified_end').val('');
163 $('#illfilter_dateplaced_start, #illfilter_dateplaced_end').val('');
168 // Remove any fields we're ignoring
169 var removeIgnore = function(dataObj) {
170 dataObj.forEach(function(thisRow) {
171 ignore.forEach(function(thisIgnore) {
172 if (thisRow.hasOwnProperty(thisIgnore)) {
173 delete thisRow[thisIgnore];
179 // Expand any fields we're expanding
180 var expandExpand = function(row) {
181 expand.forEach(function(thisExpand) {
182 if (row.hasOwnProperty(thisExpand)) {
183 if (!expanded.hasOwnProperty(thisExpand)) {
184 expanded[thisExpand] = [];
186 var expandObj = row[thisExpand];
187 Object.keys(expandObj).forEach(
188 function(thisExpandCol) {
189 var expColName = thisExpand + '_' + thisExpandCol;
190 // Keep a list of fields that have been expanded
191 // so we can create toggle links for them
192 if (expanded[thisExpand].indexOf(expColName) == -1) {
193 expanded[thisExpand].push(expColName);
195 expandObj[expColName] =
196 expandObj[thisExpandCol];
197 delete expandObj[thisExpandCol];
200 $.extend(true, row, expandObj);
201 delete row[thisExpand];
206 // Build a de-duped list of all column names
208 core.map(function(thisCore) {
209 allCols[thisCore] = 1;
212 // Strip the expand prefix if it exists, we do this for display
213 var stripPrefix = function(value) {
214 expand.forEach(function(thisExpand) {
215 var regex = new RegExp(thisExpand + '_', 'g');
216 value = value.replace(regex, '');
221 // Our 'render' function for borrowerlink
222 var createPatronLink = function(data, type, row) {
223 var patronLink = '<a title="' + _("View borrower details") + '" ' +
224 'href="/cgi-bin/koha/members/moremember.pl?' +
225 'borrowernumber='+row.borrowernumber+'">';
226 if ( row.patron_firstname ) {
227 patronLink = patronLink + row.patron_firstname + ' ';
229 patronLink = patronLink + row.patron_surname + '</a>';
233 // Our 'render' function for biblio_id
234 var createBiblioLink = function(data, type, row) {
235 return (row.biblio_id) ?
236 '<a title="' + _("View biblio details") + '" ' +
237 'href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=' +
238 row.biblio_id + '">' +
243 // Our 'render' function for the library name
244 var createLibrary = function(data, type, row) {
245 return row.library.branchname;
248 // Render function for request ID
249 var createRequestId = function(data, type, row) {
250 return row.id_prefix + row.illrequest_id;
253 // Render function for request status
254 var createStatus = function(data, type, row, meta) {
255 var origData = meta.settings.oInit.originalData;
256 if (origData.length > 0) {
257 var status_name = meta.settings.oInit.originalData[0].capabilities[
260 return getStatusName(status_name);
266 var getStatusName = function(origName) {
269 return _("New request");
271 return _("Requested");
272 case "Requested from partners":
273 return _("Requested from partners");
274 case "Request reverted":
275 return _("Request reverted");
276 case "Queued request":
277 return _("Queued request");
278 case "Cancellation requested":
279 return _("Cancellation requested");
281 return _("Completed");
282 case "Delete request":
283 return _("Delete request");
289 // Render function for creating a row's action link
290 var createActionLink = function(data, type, row) {
291 return '<a class="btn btn-default btn-sm" ' +
292 'href="/cgi-bin/koha/ill/ill-requests.pl?' +
293 'method=illview&illrequest_id=' +
295 '">' + _("Manage request") + '</a>';
298 // Columns that require special treatment
302 func: createActionLink
306 func: createPatronLink
309 name: _("Request number"),
310 func: createRequestId
317 name: _("Bibliographic record ID"),
318 func: createBiblioLink
325 name: _("Updated on"),
328 name: _("Patron barcode")
332 // Toggle request attributes in Illview
333 $('#toggle_requestattributes').on('click', function(e) {
335 $('#requestattributes').toggleClass('content_hidden');
338 // Toggle new comment form in Illview
339 $('#toggle_addcomment').on('click', function(e) {
341 $('#addcomment').toggleClass('content_hidden');
344 // Filter partner list
345 $('#partner_filter').keyup(function() {
346 var needle = $('#partner_filter').val();
347 $('#partners > option').each(function() {
348 var regex = new RegExp(needle, 'i');
350 needle.length == 0 ||
351 $(this).is(':selected') ||
352 $(this).text().match(regex)
361 // Display the modal containing request supplier metadata
362 $('#ill-request-display-metadata').on('click', function(e) {
364 $('#dataPreview').modal({show:true});
367 // Get our data from the API and process it prior to passing
370 '/api/v1/illrequests?embed=metadata,patron,capabilities,library,comments'
372 var data = JSON.parse(ajax.responseText);
373 // Make a copy, we'll be removing columns next and need
374 // to be able to refer to data that has been removed
375 var dataCopy = $.extend(true, [], data);
376 // Remove all columns we're not interested in
377 removeIgnore(dataCopy);
378 // Expand columns that need it and create an array
379 // of all column names
380 $.each(dataCopy, function(k, row) {
384 // Assemble an array of column definitions for passing
387 Object.keys(allCols).forEach(function(thisCol) {
388 // Create the base column object
394 // We may need to process the data going in this
395 // column, so do it if necessary
397 specialCols.hasOwnProperty(thisCol) &&
398 specialCols[thisCol].hasOwnProperty('func')
400 colObj.render = specialCols[thisCol].func;
402 colObj.data = thisCol;
404 colData.push(colObj);
407 // Initialise the datatable
408 table = $('#ill-requests').DataTable($.extend(true, {}, dataTablesDefaults, {
410 { // Last column shouldn't be sortable or searchable
411 'aTargets': [ 'actions' ],
415 { // Hide the two date columns we use just for sorting
416 'aTargets': [ 'placed', 'updated' ],
420 { // When sorting 'placed', we want to use the
421 // unformatted column
422 'aTargets': [ 'placed_formatted'],
425 { // When sorting 'updated', we want to use the
426 // unformatted column
427 'aTargets': [ 'updated_formatted'],
431 'aaSorting': [[ 9, 'desc' ]], // Default sort, updated descending
432 'processing': true, // Display a message when manipulating
433 'iDisplayLength': 10, // 10 results per page
434 'sPaginationType': "full_numbers", // Pagination display
435 'deferRender': true, // Improve performance on big datasets
438 'originalData': data, // Enable render functions to access
440 'initComplete': function() {
442 // Prepare any filter elements that need it
443 for (var el in filterable) {
444 if (filterable.hasOwnProperty(el)) {
445 if (filterable[el].hasOwnProperty('prep')) {
446 filterable[el].prep(dataCopy, data);
448 if (filterable[el].hasOwnProperty('listener')) {
449 filterable[el].listener();
457 // Custom date range filtering
458 $.fn.dataTable.ext.search.push(function(settings, data, dataIndex) {
459 var placedStart = $('#illfilter_dateplaced_start').datepicker('getDate');
460 var placedEnd = $('#illfilter_dateplaced_end').datepicker('getDate');
461 var modifiedStart = $('#illfilter_datemodified_start').datepicker('getDate');
462 var modifiedEnd = $('#illfilter_datemodified_end').datepicker('getDate');
463 var rowPlaced = data[8] ? new Date(data[8]) : null;
464 var rowModified = data[10] ? new Date(data[10]) : null;
465 var placedPassed = true;
466 var modifiedPassed = true;
467 if (placedStart && rowPlaced && rowPlaced < placedStart) {
470 if (placedEnd && rowPlaced && rowPlaced > placedEnd) {
471 placedPassed = false;
473 if (modifiedStart && rowModified && rowModified < modifiedStart) {
474 modifiedPassed = false
476 if (modifiedEnd && rowModified && rowModified > modifiedEnd) {
477 modifiedPassed = false;
480 return placedPassed && modifiedPassed;
487 var clearSearch = function() {
488 table.search('').columns().search('');
490 for (var filter in filterable) {
492 filterable.hasOwnProperty(filter) &&
493 filterable[filter].hasOwnProperty('clear')
495 filterable[filter].clear();
501 // Apply any search filters, or clear any previous
503 $('#illfilter_form').submit(function(event) {
504 event.preventDefault();
505 table.search('').columns().search('');
506 for (var active in activeFilters) {
507 if (activeFilters.hasOwnProperty(active)) {
508 activeFilters[active]();
515 $('#clear_search').click(function() {
524 <body id="illrequests" class="ill">
525 [% INCLUDE 'header.inc' %]
526 [% INCLUDE 'cat-search.inc' %]
528 <div id="breadcrumbs">
529 <a href="/cgi-bin/koha/mainpage.pl">Home</a> ›
530 <a href="/cgi-bin/koha/ill/ill-requests.pl">ILL requests</a>
531 [% IF query_type == 'create' %]
533 [% ELSIF query_type == 'status' %]
538 <div id="doc3" class="yui-t2">
540 [% IF query_type == 'illlist' %]
541 <div id="illfilter_yui_column" class="yui-b">
542 <form method="get" id="illfilter_form">
543 <fieldset class="brief">
547 <label for="illfilter_status">Status:</label>
548 <select name="illfilter_status" id="illfilter_status">
549 <option value=""></option>
553 <label for="illfilter_dateplaced_start">Date placed between:</label>
554 <input type="text" name="illfilter_dateplaced_start" id="illfilter_dateplaced_start" class="datepicker">
557 <label for="illfilter_dateplaced_end">and:</label>
558 <input type="text" name="illfilter_dateplaced_end" id="illfilter_dateplaced_end" class="datepicker">
561 <label for="illfilter_datemodified_start">Updated between:</label>
562 <input type="text" name="illfilter_datemodified_start" id="illfilter_datemodified_start" class="datepicker">
565 <label for="illfilter_datemodified_end">and:</label>
566 <input type="text" name="illfilter_datemodified_end" id="illfilter_datemodified_end" class="datepicker">
569 <label for="illfilter_branchname">Library:</label>
570 <select name="illfilter_branchname" id="illfilter_branchname">
571 <option value=""></option>
575 <label for="illfilter_barcode">Patron barcode:</label>
576 <input type="text" name="illfilter_barcode" id="illfilter_barcode">
579 <fieldset class="action">
580 <input type="submit" value="Search" />
581 <input type="button" value="Clear" id="clear_search" />
588 <div id="interlibraryloans" class="yui-b">
589 [% IF !backends_available || !has_branch %]
590 <div class="dialog message">ILL module configuration problem. Take a look at the <a href="/cgi-bin/koha/about.pl#sysinfo">about page</a></div>
592 [% INCLUDE 'ill-toolbar.inc' %]
595 <h1>Error performing operation</h1>
596 <!-- Dispatch on Status -->
597 <p>We encountered an error:</p>
599 <pre>[% whole.message | html %] ([% whole.status | html %])</pre>
603 [% IF query_type == 'create' %]
604 <h1>New ILL request</h1>
605 [% PROCESS $whole.template %]
607 [% ELSIF query_type == 'confirm' %]
608 <h1>Confirm ILL request</h1>
609 [% PROCESS $whole.template %]
611 [% ELSIF query_type == 'cancel' and !whole.error %]
612 <h1>Cancel a confirmed request</h1>
613 [% PROCESS $whole.template %]
615 [% ELSIF query_type == 'generic_confirm' %]
616 <h1>Place request with partner libraries</h1>
618 [% IF error == 'no_target_email' %]
620 No target email addresses found. Either select at least
621 one partner or check your ILL partner library records.
623 [% ELSIF error == 'no_library_email' %]
625 Your library has no usable email address. Please set it.
627 [% ELSIF error == 'unkown_error' %]
629 Unknown error processing your request. Contact your administrator.
633 <!-- Start of GENERIC_EMAIL case -->
634 [% IF whole.value.partners %]
635 [% ill_url = "/cgi-bin/koha/ill/ill-requests.pl?method=illview&illrequest_id=" _ request.illrequest_id %]
636 <form method="POST" action="/cgi-bin/koha/ill/ill-requests.pl">
637 <fieldset class="rows">
638 <legend>Interlibrary loan request details</legend>
641 <label for="partner_filter">Filter partner libraries:</label>
642 <input type="text" id="partner_filter">
645 <label for="partners" class="required">Select partner libraries:</label>
646 <select size="5" multiple="true" id="partners" name="partners" required="required">
647 [% FOREACH partner IN whole.value.partners %]
648 <option value=[% partner.email | html %]>
649 [% partner.branchcode _ " - " _ partner.surname %]
656 <label for="subject" class="required">Subject Line</label>
657 <input type="text" name="subject" id="subject" type="text" value="[% whole.value.draft.subject | html %]" required="required" />
660 <label for="body" class="required">Email text:</label>
661 <textarea name="body" id="body" rows="20" cols="80" required="required">[% whole.value.draft.body | html %]</textarea>
664 <input type="hidden" value="generic_confirm" name="method">
665 <input type="hidden" value="draft" name="stage">
666 <input type="hidden" value="[% request.illrequest_id | html %]" name="illrequest_id">
668 <fieldset class="action">
669 <input type="submit" class="btn btn-default" value="Send email"/>
670 <span><a href="[% ill_url | url %]" title="Return to request details">Cancel</a></span>
674 <fieldset class="rows">
675 <legend>Interlibrary loan request details</legend>
676 <p>No partners have been defined yet. Please create appropriate patron records (by default ILLLIBS category).</p>
677 <p>Be sure to provide email addresses for these patrons.</p>
678 <p><span><a href="[% ill_url | url %]" title="Return to request details">Cancel</a></span></p>
681 <!-- generic_confirm ends here -->
683 [% ELSIF query_type == 'edit_action' %]
684 <form method="POST" action="/cgi-bin/koha/ill/ill-requests.pl">
685 <fieldset class="rows">
686 <legend>Request details</legend>
688 [% type = request.get_type %]
689 <li class="borrowernumber">
690 <label for="borrowernumber">Patron ID:</label>
691 [% request.borrowernumber | html %]
693 <li class="biblio_id">
694 <label for="biblio_id" class="biblio_id">Bibliographic record ID:</label>
695 <input name="biblio_id" id="biblio_id" type="text" value="[% request.biblio_id | html %]">
697 <li class="branchcode">
698 <label for="library" class="branchcode">Library:</label>
699 <select name="branchcode" id="library">
700 [% PROCESS options_for_libraries libraries => Branches.all( selected => request.branchcode ) %]
704 <label class="status">Status:</label>
705 [% stat = request.status %]
706 [% request.capabilities.$stat.name | html %]
709 <label class="updated">Last updated:</label>
710 [% request.updated | $KohaDates with_hours => 1 %]
713 <label class="medium">Request type:</label>
714 [% IF type %][% type | html %][% ELSE %]<span>N/A</span>[% END %]
717 <label class="cost">Cost:</label>
718 [% IF request.cost %][% request.cost | html %][% ELSE %]<span>N/A</span>[% END %]
720 <li class="price_paid">
721 <label class="price_paid">Price paid:</label>
722 <input name="price_paid" id="price_paid" type="text" value="[% request.price_paid | html %]">
725 <label class="req_id">Request number:</label>
726 [% request.id_prefix _ request.illrequest_id | html %]
728 <li class="notesstaff">
729 <label for="notesstaff" class="notesstaff">Staff notes:</label>
730 <textarea name="notesstaff" id="notesstaff" rows="5">[% request.notesstaff | html %]</textarea>
732 <li class="notesopac">
733 <label for="notesopac" class="notesopac">Opac notes:</label>
734 <textarea name="notesopac" id="notesopac" rows="5">[% request.notesopac | html %]</textarea>
738 <fieldset class="action">
739 <input type="hidden" value="edit_action" name="method">
740 <input type="hidden" value="form" name="stage">
741 <input type="hidden" value="[% request.illrequest_id | html %]" name="illrequest_id">
742 <input type="hidden" value="[% request.borrowernumber | html %]" name="borrowernumber">
743 <input type="submit" value="Submit">
744 <a class="cancel" href="/cgi-bin/koha/ill/ill-requests.pl?method=illview&illrequest_id=[% request.id | html %]">Cancel</a>
748 [% ELSIF query_type == 'delete_confirm' %]
750 <div class="dialog alert">
751 <h3>Are you sure you wish to delete this request?</h3>
752 <form action="/cgi-bin/koha/ill/ill-requests.pl" method="post">
753 <input type="hidden" name="method" value="delete" />
754 <input type="hidden" name="confirmed" value="1" />
755 <input type="hidden" name="illrequest_id" value="[% request.id | html %]" />
756 <button type="submit" class="btn btn-default btn-sm approve"><i class="fa fa-fw fa-check"></i> Yes, delete</button>
758 <a class="btn btn-default btn-sm deny" href="/cgi-bin/koha/ill/ill-requests.pl?method=illview&illrequest_id=[% request.id | html %]"><i class="fa fa-fw fa-remove"></i>No, do not delete</a>
761 [% ELSIF query_type == 'illview' %]
762 [% req_status = request.status %]
765 [% IF error == 'migrate_target' %]
767 The backend you tried to migrate to does not yet support migrations, please try again with an alternative target.
772 <h1>Manage ILL request</h1>
773 <div id="request-toolbar" class="btn-toolbar">
774 <a title="Edit request" id="ill-toolbar-btn-edit-action" class="btn btn-sm btn-default" href="/cgi-bin/koha/ill/ill-requests.pl?method=edit_action&illrequest_id=[% request.illrequest_id | html %]">
775 <span class="fa fa-pencil"></span>
778 [% FOREACH action IN request.available_actions %]
779 [% IF action.method == 'migrate' %]
780 [% IF backends.size > 2 %]
781 <div class="dropdown btn-group">
782 <button class="btn btn-sm btn-default dropdown-toggle" type="button" id="ill-migrate-dropdown" data-toggle="dropdown" aria-haspopup="true" aria-expanded="true">
783 <i class="fa [% action.ui_method_icon | html %]"></i> [% action.ui_method_name | html %] <span class="caret"></span>
785 <ul class="dropdown-menu" aria-labelledby="ill-migrate-dropdown">
786 [% FOREACH backend IN backends %]
787 [% IF backend != request.backend %]
788 <li><a href="/cgi-bin/koha/ill/ill-requests.pl?method=[% action.method | uri %]&illrequest_id=[% request.illrequest_id | uri %]&backend=[% backend | uri %]">[% backend | html %]</a></li>
793 [% ELSIF backends.size == 2 %]
794 [% FOREACH backend IN backends %]
795 [% IF backend != request.backend %]
796 <a title="[% action.ui_method_name | html %]" id="ill-toolbar-btn-[% action.id | lower | html %]" class="btn btn-sm btn-default" href="/cgi-bin/koha/ill/ill-requests.pl?method=[% action.method | uri %]&illrequest_id=[% request.illrequest_id | uri %]&backend=[% backend | uri %]">
797 <span class="fa [% action.ui_method_icon | html %]"></span>
798 [% action.ui_method_name | html %]
803 [% ELSIF action.method != 0 %]
804 <a title="[% action.ui_method_name | html %]" id="ill-toolbar-btn-[% action.id | lower | html %]" class="btn btn-sm btn-default" href="/cgi-bin/koha/ill/ill-requests.pl?method=[% action.method | uri %]&illrequest_id=[% request.illrequest_id | uri %]">
805 <span class="fa [% action.ui_method_icon | html %]"></span>
806 [% action.ui_method_name | html %]
810 <a title="Display supplier metadata" id="ill-request-display-metadata" class="btn btn-sm btn-default pull-right" href="#">
811 <span class="fa fa-eye"></span>
812 Display supplier metadata
815 <div class="ill-view-panel panel panel-default">
816 <div class="panel-heading">
817 <h3>Request details</h3>
819 <div class="panel-body">
820 <h4>Details from library</h4>
824 <span class="label orderid">Order ID:</span>
825 [% IF request.orderid %][% request.orderid | html %][% ELSE %]<span>N/A</span>[% END %]
827 <li class="borrowernumber">
828 <span class="label borrowernumber">Patron:</span>
829 [% borrowerlink = "/cgi-bin/koha/members/moremember.pl" _ "?borrowernumber=" _ request.patron.borrowernumber %]
830 <a href="[% borrowerlink | url %]" title="View borrower details">
831 [% request.patron.firstname _ " " _ request.patron.surname _ " [" _ request.patron.cardnumber _ "]" | html %]
835 <li class="biblio_id">
836 <span class="label biblio_id">Bibliographic record ID:</span>
837 [% IF request.biblio_id %]
838 <a href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=[% request.biblio_id | uri %]">[% request.biblio_id | html %]</a>
843 <li class="branchcode">
844 <span class="label branchcode">Library:</span>
845 [% Branches.GetName(request.branchcode) | html %]
848 <span class="label status">Status:</span>
849 [% request.capabilities.$req_status.name | html %]
852 <span class="label updated">Last updated:</span>
853 [% request.updated | $KohaDates with_hours => 1 %]
856 <span class="label medium">Request type:</span>
857 [% type = request.get_type %]
858 [% IF type %][% type | html %][% ELSE %]<span>N/A</span>[% END %]
861 <span class="label cost">Cost:</span>
862 [% IF request.cost %][% request.cost | html %][% ELSE %]<span>N/A</span>[% END %]
864 <li class="price_paid">
865 <span class="label price_paid">Price paid:</span>
866 [% IF request.price_paid %][% request.price_paid | html %][% ELSE %]<span>N/A</span>[% END %]
869 <span class="label req_id">Request number:</span>
870 [% request.id_prefix _ request.illrequest_id | html %]
872 <li class="notesstaff">
873 <span class="label notes_staff">Staff notes:</span>
874 <p>[% request.notesstaff | html %]</p>
876 <li class="notesopac">
877 <span class="label notes_opac">Notes:</span>
878 <p>[% request.notesopac | html %]</p>
883 <h4>Details from supplier ([% request.backend | html %])</h4>
885 [% FOREACH meta IN request.metadata %]
886 <li class="requestmeta-[% meta.key.replace('\s','_') | html %]">
887 <span class="label">[% meta.key | html %]:</span>
888 [% meta.value | html %]
896 <div id="dataPreview" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="dataPreviewLabel" aria-hidden="true">
897 <div class="modal-dialog">
898 <div class="modal-content">
899 <div class="modal-header">
900 <button type="button" class="closebtn" data-dismiss="modal" aria-hidden="true">×</button>
901 <h3 id="dataPreviewLabel"> Supplier metadata</h3>
903 <div class="modal-body">
904 <div id="requestattributes">
905 [% FOREACH attr IN request.illrequestattributes %]
906 <div class="requestattr-[% attr.type | html %]">
907 <span class="label">[% attr.type | html %]:</span>
908 [% attr.value | html %]
913 <div class="modal-footer">
914 <button class="btn btn-default" data-dismiss="modal" aria-hidden="true">Close</button>
920 <div class="ill-view-panel panel panel-default">
921 <div class="panel-heading">
922 <h3>[% request.illcomments.count | html %] comments</h3>
924 <div class="panel-body">
925 [% IF request.illcomments.count && request.illcomments.count > 0 %]
926 [% FOREACH comment IN request.illcomments %]
927 <div class="rows comment_[% comment.patron.categorycode | html %]">
929 <a href="[% borrowerlink | url %]" title="View borrower details">
930 [% comment.patron.firstname _ " " _ comment.patron.surname _ " [" _ comment.patron.cardnumber _ "]" | html %]</a>
931 [% comment.timestamp | $KohaDates with_hours => 1 %]</h5>
932 <p>[% comment.comment | html %]</p>
937 <h3><a id="toggle_addcomment" href="#">Add comment</a></h3>
938 <div id="addcomment" class="content_hidden">
939 <form class="validated" method="post" action="/cgi-bin/koha/ill/ill-requests.pl">
940 <input type="hidden" value="save_comment" name="method">
941 <input type="hidden" value="[% csrf_token | html %]" name="csrf_token">
942 <input type="hidden" value="[% request.illrequest_id | html %]" name="illrequest_id">
943 <fieldset class="rows">
946 <label class="required" for="comment">Comment: </label>
947 <textarea class="required" required="required" cols="80" rows="10" id="comment" name="comment"></textarea>
948 <span class="required">Required</span>
952 <fieldset class="action">
953 <input type="submit" value="Submit">
961 [% ELSIF query_type == 'illlist' %]
963 <h1>View ILL requests</h1>
965 <h3>Details for all requests</h3>
967 <table id="ill-requests">
969 <tr id="illview-header">
973 <th>Bibliographic record ID</th>
976 <th class="placed"> </th>
977 <th class="placed_formatted">Date placed</th>
978 <th class="updated"> </th>
979 <th class="updated_formatted">Updated on</th>
980 <th>Request number</th>
982 <th class="actions"></th>
985 <tbody id="illview-body">
990 <!-- Custom Backend Action -->
991 [% PROCESS $whole.template %]
1000 [% PROCESS backend_jsinclude %]
1004 [% INCLUDE 'intranet-bottom.inc' %]