Bug 23854: Fix failure on dates when editing a suggestion
[koha.git] / koha-tmpl / opac-tmpl / prog / en / modules / opac-results.tt
1 [% INCLUDE 'doc-head-open.inc' %]
2 [% IF ( LibraryNameTitle ) %][% LibraryNameTitle %][% ELSE %]Koha Online[% END %] Catalog ›
3 [% IF ( searchdesc ) %]
4         Results of Search [% IF ( query_desc ) %]for '[% query_desc | html%]'[% END %][% IF ( limit_desc ) %] with limit(s): '[% limit_desc | html %]'[% END %]
5 [% ELSE %]
6     You did not specify any search criteria.
7 [% END %]
8 [% INCLUDE 'doc-head-close.inc' %]
9 <link rel="alternate" type="application/rss+xml" title="[% LibraryName |html %] Search RSS Feed" href="[% OPACBaseURL %]/cgi-bin/koha/opac-search.pl?[% query_cgi |html %][% limit_cgi |html %]&amp;count=[% countrss |html %]&amp;sort_by=acqdate_dsc&amp;format=rss2" />
10
11
12 <script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.checkboxes.min.js"></script>
13 [% IF ( OpacHighlightedWords ) %]<script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.highlight-3.js"></script>
14 [% END %]<script type="text/javascript">
15 //<![CDATA[
16 [% IF ( opacuserlogin ) %][% IF ( RequestOnOpac ) %]
17 function holdMultiple() {
18     var checkedBiblioNums = ""; // Separated by "/"
19     var checkedCount = 0;
20     if(document.bookbag_form.biblionumber.length > 0) {
21         for (var i=0; i < document.bookbag_form.biblionumber.length; i++) {
22             if (document.bookbag_form.biblionumber[i].checked) {
23                 checkedBiblioNums += (document.bookbag_form.biblionumber[i].value + "/");
24                 checkedCount++;
25             }
26         }
27     }
28
29     if (checkedCount > 0) {
30         holdBiblioNums(checkedBiblioNums);
31     } else {
32         alert(MSG_NO_RECORD_SELECTED);
33     }
34 }
35
36 function holdBiblioNums(numList) {
37     // numList: biblio numbers separated by "/"
38     $("#hold_form_biblios").attr("value", numList);
39     $("#hold_form").submit();
40 }[% END %]
41
42 [% IF ( TagsEnabled ) %]
43 function tagSelected() {
44     var checkedBoxes = $(".searchresults :checkbox:checked");
45     if ($(checkedBoxes).size() == 0) {
46         alert(MSG_NO_RECORD_SELECTED);
47     } else {
48         $("#tagsel_tag").hide();
49         $("#sort_by").hide();
50         $("#tagsel_form").show();
51     }
52 }
53
54 function tagCanceled() {
55     $("#tagsel_form").hide();
56     $("#tagsel_tag").show();
57     $("#sort_by").show();
58 }
59
60 function tagAdded() {
61     var checkedBoxes = $(".searchresults :checkbox:checked");
62     if ($(checkedBoxes).size() == 0) {
63         alert(MSG_NO_RECORD_SELECTED);
64         return false;
65     }
66
67     var tag = $("#tagsel_new").val();
68     if (!tag || (tag == "")) {
69         return false;
70     }
71
72     var bibs = [];
73     for (var i = 0; i < $(checkedBoxes).size(); i++) {
74         var box = $(checkedBoxes).get(i);
75         bibs[i] = $(box).val();
76     }
77
78     KOHA.Tags.add_multitags_button(bibs, tag);
79     return false;
80 }[% END %][% END %]
81 [% IF ( OpacHighlightedWords ) %]
82 var q_array = new Array();  // holds search terms if available
83
84 function highlightOff() {
85     $("td").removeHighlight();
86     $(".highlight_toggle").toggle();
87 }
88 function highlightOn() {
89     var x;
90     for (x in q_array) {
91         $(".title").highlight(q_array[x]);
92         $(".author").highlight(q_array[x]);
93         $(".results_summary").highlight(q_array[x]);
94     }
95     $(".highlight_toggle").toggle();
96 }
97 [% END %]
98 $(document).ready(function(){
99         [% IF ( opacbookbag ) %]$(".addtocart").show();[% END %]
100
101 [% IF ( opacbookbag ) %]
102         [% IF ( virtualshelves ) %]
103         var param1 = "<label for=\"addto\">"+_("Add to: ")+"<\/label><select name=\"addto\" id=\"addto\"><option value=\"\"><\/option>";
104         [% IF ( opacbookbag ) %]        param1 += "<option value=\"addtocart\">"+_("Cart")+"<\/option>";
105         [% END %][% IF ( virtualshelves ) %][% IF ( loggedinusername ) %][% IF ( addbarshelves ) %]
106         param1 += "<optgroup label=\""+_("Your Lists:")+"\">";[% FOREACH addbarshelvesloo IN addbarshelvesloop %]
107         param1 += "<option id=\"s[% addbarshelvesloo.shelfnumber %]\" value=\"addtolist\">[% addbarshelvesloo.shelfname |html %]<\/option>";[% END %]
108     [% IF ( bartotal ) %]param1 += "<option value=\"morelists\">[ "+_("More lists")+" ]<\/option>";[% END %]
109         param1 += "<\/optgroup>";[% END %]
110         [% IF ( addpubshelves ) %]param1 += "<optgroup label=\""+_("Public Lists:")+"\">"[% FOREACH addpubshelvesloo IN addpubshelvesloop %]+"<option id=\"s[% addpubshelvesloo.shelfnumber %]\" value=\"addtolist\">[% addpubshelvesloo.shelfname |html %]<\/option>"[% END %];[% END %]
111         param1 += "<\/optgroup>";
112     param1 += "<option value=\"newlist\">[ "+_("New List")+" ]<\/option>";
113         [% END %]
114         [% END %]
115         param1 += "<\/select> <input type=\"submit\" class=\"submit\" value=\""+_("Save")+"\" />";
116         [% ELSE %]
117                 var param1 = "<a id=\"addto\" class=\"addtocart\" href=\"#\">Add to Cart<\/a>";
118         [% END %]
119 [% ELSE %]
120                 var param1 = "<label for=\"addto\">"+_("Add to list: ")+"<\/label><select name=\"addto\" id=\"addto\"><option value=\"\"><\/option>";
121 [% IF ( virtualshelves ) %][% IF ( loggedinusername ) %][% IF ( addbarshelves ) %]
122         param1 += "<optgroup label=\""+_("Your Lists:")+"\">";[% FOREACH addbarshelvesloo IN addbarshelvesloop %]
123         param1 += "<option id=\"s[% addbarshelvesloo.shelfnumber %]\" value=\"addtolist\">[% addbarshelvesloo.shelfname |html %]<\/option>";[% END %]
124         param1 += "<\/optgroup>";[% END %]
125         [% IF ( addpubshelves ) %]param1 += "<optgroup label=\""+_("Public Lists:")+"\">"[% FOREACH addpubshelvesloo IN addpubshelvesloop %]+"<option id=\"s[% addpubshelvesloo.shelfnumber %]\" value=\"addtolist\">[% addpubshelvesloo.shelfname |html %]<\/option>"[% END %][% END %]
126         param1 +="<\/optgroup><option value=\"newlist\">[ "+_("New List")+" ]<\/option>"
127         [% END %]
128         [% END %]
129         param1 += "<\/select> <input type=\"submit\" class=\"submit\" value=\""+_("Save")+"\" />";
130 [% END %]
131
132         $('#sortsubmit').hide();
133     $('#sort_by').change(function() {
134         $('#bookbag_form').submit();
135     });
136         $("span.clearall").html("<a id=\"CheckNone\" href=\"#\">"+_("Clear All")+"<\/a>");
137         $("span.checkall").html("<a id=\"CheckAll\" href=\"#\">"+_("Select All")+"<\/a>");
138 [% IF ( opacbookbag ) %]$("span.addto").html(param1);[% ELSE %][% IF ( virtualshelves ) %][% IF ( loggedinusername ) %]$("span.addto").html(param1);[% END %][% END %][% END %]
139 [% IF ( opacbookbag ) %]
140         [% IF ( virtualshelves ) %]
141         $("#addto").change(function(){
142                 cartList();
143         });
144         $(".addto").find("input:submit").click(function(){
145                 cartList();
146                 return false;
147         });
148         [% ELSE %]
149         $("#addto").click(function(){
150                 cartList();
151                 return false;
152         });
153         [% END %]
154 [% END %]
155     [% IF ( opacuserlogin ) %][% IF ( TagsEnabled ) %]$("#tagsel_span").html("<input id=\"tagsel_tag\" class=\"submit\" type=\"submit\" value=\"Tag\"/>");[% END %][% END %]
156
157         function cartList(){
158                 if($("#addto").find("option:selected").attr("value") == "addtolist"){
159                         var shelfnumber = $("#addto").find("option:selected").attr("id").replace("s","");
160                         if (vShelfAdd()) {
161                         Dopop('/cgi-bin/koha/opac-addbybiblionumber.pl?selectedshelf='+shelfnumber+'&' + vShelfAdd());
162                         }
163                         return false;
164                 } else if($("#addto").find("option:selected").attr("value") == "newlist"){
165                         [% IF ( loggedinusername ) %]if (vShelfAdd()) {
166                         Dopop('/cgi-bin/koha/opac-addbybiblionumber.pl?newshelf=1&' + vShelfAdd());
167                         }[% ELSE %] alert(_('You must be logged in to create or add to Lists')); [% END %]
168                         return false;
169         } else if($("#addto").find("option:selected").attr("value") == "morelists"){
170             [% IF ( loggedinusername ) %]if (vShelfAdd()) {
171             Dopop('/cgi-bin/koha/opac-addbybiblionumber.pl?' + vShelfAdd());
172             }[% ELSE %] alert(_('You must be logged in to create or add to Lists')); [% END %]
173             return false;
174                 }
175                 if($("#addto").find("option:selected").attr("value") == "addtocart" || $("#addto").attr("class") == "addtocart"){
176                         addMultiple();
177                         return false;
178                  }
179         }
180     $("#CheckAll").click(function(){
181         $("#bookbag_form").checkCheckboxes();
182         return false;
183     });
184     $("#CheckNone").click(function(){
185         $("#bookbag_form").unCheckCheckboxes();
186         return false;
187     });
188 [% IF ( RequestOnOpac ) %]
189   [% IF ( opacuserlogin ) %]
190   [% IF ( DisplayMultiPlaceHold ) %]
191     $("#placehold").html("<input class=\"submit\" type=\"submit\" value=\""+_("Place Hold")+"\"/>");
192         $("#placehold").find("input:submit").click(function(){
193         holdMultiple();
194                 return false;
195         });
196   [% END %]
197   [% END %]
198 [% END %]
199     $("#holdDetails").hide();
200
201 [% IF ( query_desc ) %][% IF ( OpacHighlightedWords ) %]var query_desc = "[% query_desc |replace("'", "\'") |replace('"', '\"') |replace('\n', '\\n') |replace('\r', '\\r') %]";
202         q_array = query_desc.split(" ");
203         highlightOn();
204         $("#highlight_toggle_on" ).hide().click(function() {highlightOn() ;});
205         $("#highlight_toggle_off").show().click(function() {highlightOff();});[% END %][% END %]
206
207 [% IF ( opacuserlogin ) %]    [% IF ( TagsEnabled ) %]
208         $(".tagbutton").click(KOHA.Tags.add_tag_button);
209         [% IF ( TagsInputOnList ) %]
210         [% IF ( loggedinusername ) %]
211             $("#tagsel_tag").click(function(){
212                 tagSelected();
213                 return false;
214             });
215             $("#tagsel_cancel").click(function(){
216                 tagCanceled();
217                 return false;
218             });
219             $("#tagsel_button").click(function(){
220                 tagAdded();
221                 return false;
222             });
223         [% ELSE %]
224             $("#tagsel_tag").click(function(){
225                 window.location = "/cgi-bin/koha/opac-user.pl";
226                 return false;
227             });
228         [% END %]
229         [% END %]
230     [% END %][% END %]
231     [% IF OpenLibraryCovers %]KOHA.OpenLibrary.GetCoverFromIsbn();[% END %]
232         [% IF OPACLocalCoverImages %]KOHA.LocalCover.GetCoverFromBibnumber(false);[% END %]
233     [% IF ( GoogleJackets ) %]KOHA.Google.GetCoverFromIsbn();[% END %]
234 });
235 //]]>
236 </script>
237 </head>
238 <body id="results">
239         [% IF ( opacfacets ) %]<div id="doc3" class="yui-t1">[% ELSE %]<div id="doc3" class="yui-t7">[% END %]
240    <div id="bd">
241
242 [% INCLUDE 'masthead.inc' %]
243
244
245         <div id="yui-main">
246         <div class="yui-b">
247         <div id="userresults" class="container">
248   [% IF ( koha_spsuggest ) %]
249         Did you mean:
250     <ul style="list-style: none;">
251         [% FOREACH SPELL_SUGGES IN SPELL_SUGGEST %]
252         <li>
253             <a href="/cgi-bin/koha/opac-search.pl?q=[% SPELL_SUGGES.spsuggestion %]">[% SPELL_SUGGES.spsuggestion %]</a>
254         </li>
255         [% END %]
256     </ul>
257 [% END %]
258
259 [% IF ( query_error ) %]
260 <div class="dialog alert">
261         <h4>Error:</h4>
262     [% query_error %]
263 </div>
264 [% END %]
265
266 <!-- Search Results Table -->
267 [% IF ( total ) %]
268 [% IF ( scan ) %]
269     <h1>Scan Index:</h1>
270     <form action="/cgi-bin/koha/opac-search.pl" method="get">
271         <table>
272             <tr>
273                 <td>
274                     Scan Index for: <input type="text" name="q" id="scan-index" size="35" value="" />
275                 </td>
276             </tr>
277             <tr>
278                 <td>
279                     <label for="scan-index">Indexed in:</label>
280                     <select name="idx" id="scan-index">
281                         <option value="">Any Word</option>
282                         <option value="kw,phr:">Any Phrase</option>
283                         <option value="ti:">Title</option>
284                         <option value="ti,phr:">Title Phrase</option>
285                         <option value="au,phr:">Author</option>
286                         <option value="su:">Subject</option>
287                         <option value="su,phr:">Subject Phrase</option>
288                         <option value="se:">Series</option>
289                         <option value="pb:">Publisher</option>
290                         <option value="nt:">Notes</option>
291                         <option value="se:">Series Title</option>
292                         <option value="sn:">ISBN</option>
293                         <option value="ss:">ISSN</option>
294                     </select>
295                     <input type="hidden" name="scan" value="1" />
296                 </td>
297             </tr>
298         </table>
299     </form>
300
301     <form action="/cgi-bin/koha/opac-search.pl" method="get">
302         <table>
303             <tr>
304                 <th>Term/Phrase</th>
305                 <th>Count</th>
306             </tr>
307             [% FOREACH SEARCH_RESULT IN SEARCH_RESULTS %]
308                         [% IF ( SEARCH_RESULT.even ) %]
309             <tr class="highlight">
310                         [% ELSE %]
311                         <tr>
312                         [% END %]
313                 <td>
314                     <a href="/cgi-bin/koha/opac-search.pl?q=[% SEARCH_RESULT.scan_use |url %]&quot;[% SEARCH_RESULT.title |url %]&quot;">[% IF ( SEARCH_RESULT.title ) %][% SEARCH_RESULT.title |html %][% ELSE %]No title[% END %]</a>
315                 </td>
316                 <td>
317                     [% SEARCH_RESULT.author %]
318                 </td>
319             </tr>
320             [% END %]
321         </table>
322     </form>
323 [% ELSE %]
324
325     <div class="searchresults">
326         <form action="/cgi-bin/koha/opac-search.pl" method="get" name="bookbag_form" id="bookbag_form">
327                 [% IF ( searchdesc ) %]
328                 [% FOREACH QUERY_INPUT IN QUERY_INPUTS %]
329                 <input type="hidden" name="[% QUERY_INPUT.input_name |html %]" value="[% QUERY_INPUT.input_value |html %]"/>
330                 [% END %]
331                 [% FOREACH LIMIT_INPUT IN LIMIT_INPUTS %]
332                 <input type="hidden" name="[% LIMIT_INPUT.input_name |html %]" value="[% LIMIT_INPUT.input_value |html %]"/>
333                 [% END %]
334                 [% END %]
335
336         <!-- TABLE RESULTS START -->
337         <table>
338                 <tr><td colspan="5" class="resultscontrol">
339                 <div class="resort"> <select id="sort_by" name="sort_by"> [% INCLUDE 'resort_form.inc' %] </select> <input type="submit" class="submit clearfix" id="sortsubmit" value="Go" /></div>
340                 <div class="cartlist">
341             <!-- checkall, clearall are now needed for placehold -->
342             <span class="checkall"></span>
343                 <span class="clearall"></span>
344             [% IF ( OpacHighlightedWords ) %]
345                 <a href="#" class="highlight_toggle" id="highlight_toggle_off">Unhighlight</a>
346                 <a href="#" class="highlight_toggle" id="highlight_toggle_on">Highlight</a>
347             [% END %]
348             [% IF ( opacbookbag || virtualshelves ) %]
349                 <span class="addto"></span>
350             [% END %]
351                     <span id="placehold"><!-- input class="submit" type="submit" value="Place Hold"/ --></span>
352             <div id="holdDetails"></div>
353
354                         [% IF ( opacuserlogin ) %][% IF ( loggedinusername ) %][% IF ( TagsEnabled ) %]
355                         [% IF ( TagsInputOnList ) %]
356                             <span id="tagsel_span"></span>
357                           [% IF ( loggedinusername ) %]
358                             <span id="tagsel_form" style="display:none">
359                               <label for="tagsel_new">New Tag:</label>
360                               <input name="tagsel_new" id="tagsel_new" maxlength="100" />
361                               <input id="tagsel_button" name="tagsel_button" class="input tagsel_button" title="tagsel_button" type="submit" value="Add" />
362                               <a href="#" id="tagsel_cancel">Cancel</a>
363                             </span>
364                             <span id="tagsel_status" class="tagsel_tatus" style="display:none;">
365                               Tag status here.
366                             </span>
367                           [% END %]
368                         [% END %]
369                 [% END %][% END %][% END %]
370         </div>
371
372         </td></tr>
373             <!-- Actual Search Results -->
374             [% FOREACH SEARCH_RESULT IN SEARCH_RESULTS %]
375             [% UNLESS ( loop.odd ) %]
376                 <tr class="highlight">
377             [% ELSE %]
378                 <tr>
379             [% END %]
380
381                 <td class="select selectcol">[% IF ( opacbookbag ) %]<input type="checkbox" id="bib[% SEARCH_RESULT.biblionumber %]" name="biblionumber" value="[% SEARCH_RESULT.biblionumber %]" /> <label for="bib[% SEARCH_RESULT.biblionumber %]"></label>[% ELSE %]
382 [% IF ( virtualshelves ) %]<input type="checkbox" id="bib[% SEARCH_RESULT.biblionumber %]" name="biblionumber" value="[% SEARCH_RESULT.biblionumber %]" /> <label for="bib[% SEARCH_RESULT.biblionumber %]"></label>[% ELSE %]
383 [% IF ( RequestOnOpac ) %][% UNLESS ( SEARCH_RESULT.norequests ) %][% IF ( opacuserlogin ) %]<input type="checkbox" id="bib[% SEARCH_RESULT.biblionumber %]" name="biblionumber" value="[% SEARCH_RESULT.biblionumber %]" /> <label for="bib[% SEARCH_RESULT.biblionumber %]"></label>[% END %][% END %][% END %][% END %][% END %]</td>
384
385                                 [% UNLESS ( item_level_itypes ) %]
386                 [% UNLESS ( noItemTypeImages ) %]
387
388                                 <td class="itypecol">
389                 [% IF ( SEARCH_RESULT.imageurl ) %]
390                                 <img src="[% SEARCH_RESULT.imageurl %]" title="[% SEARCH_RESULT.description %]" alt="[% SEARCH_RESULT.description %]" />
391                 [% END %]
392                                 </td>
393                 [% END %]
394                 [% END %]
395
396                                 [% IF ( SEARCH_RESULT.AuthorisedValueImages ) %]
397                 <td class="itypecol">
398                 [% FOREACH authorised_value_image IN SEARCH_RESULT.authorised_value_images %]
399                 <img src="[% authorised_value_image.imageurl %]" alt="[% authorised_value_image.label %]" title="[% authorised_value_image.label %]">
400                 [% END %]
401                 </td>
402                 [% END %]
403
404                                 <td>
405                 [% IF ( COinSinOPACResults ) %]
406                     [% IF ( SEARCH_RESULT.coins ) %]
407                         <!-- COinS / Openurl --><span class="Z3988" title="[% SEARCH_RESULT.coins %]"></span>
408                     [% END %]
409                 [% END %]
410
411                                 [% IF ( OPACXSLTResultsDisplay ) %]
412                 [% SEARCH_RESULT.XSLTResultsRecord %]
413                                 [% ELSE %]
414                                 [% IF ( BiblioDefaultViewmarc ) %]<a class="title" href="/cgi-bin/koha/opac-MARCdetail.pl?biblionumber=[% SEARCH_RESULT.biblionumber |url %]" title="View details for this title">
415                                 [% ELSE %]
416                                 [% IF ( BiblioDefaultViewisbd ) %]<a class="title" href="/cgi-bin/koha/opac-ISBDdetail.pl?biblionumber=[% SEARCH_RESULT.biblionumber |url %]" title="View details for this title">
417                                 [% ELSE %]<a class="title" href="/cgi-bin/koha/opac-detail.pl?biblionumber=[% SEARCH_RESULT.biblionumber |url %]" title="View details for this title">
418                                 [% END %]
419                                 [% END %]
420                                                                 [% IF ( SEARCH_RESULT.title ) %][% SEARCH_RESULT.title |html %][% ELSE %]No title[% END %] [% FOREACH subtitl IN SEARCH_RESULT.subtitle %], [% subtitl.subfield|html %][% END %]</a>
421                                 [% IF ( SEARCH_RESULT.author ) %]by <a href="/cgi-bin/koha/opac-search.pl?q=au:[% SEARCH_RESULT.author |url %]" title="Search for works by this author" class="author">[% SEARCH_RESULT.author %]</a>
422                                 [% ELSE %]&nbsp;
423                                 [% END %]
424                                 <span class="results_summary"><span class="label">Publication:</span>
425                         [% IF ( SEARCH_RESULT.place ) %][% SEARCH_RESULT.place %] [% END %][% IF ( SEARCH_RESULT.publishercode ) %][% SEARCH_RESULT.publishercode|html %][% END %][% IF ( SEARCH_RESULT.publicationyear ) %] [% SEARCH_RESULT.publicationyear %]
426                     [% ELSE %][% IF ( SEARCH_RESULT.copyrightdate ) %] [% SEARCH_RESULT.copyrightdate %][% END %][% END %]
427                         [% IF ( SEARCH_RESULT.pages ) %]. [% SEARCH_RESULT.pages %][% END %]
428                         [% IF ( SEARCH_RESULT.notes ) %], [% SEARCH_RESULT.notes|html %][% END %]
429                         [% IF ( SEARCH_RESULT.size ) %] [% SEARCH_RESULT.size %][% END %]
430                         [% IF ( SEARCH_RESULT.timestamp ) %] <i>(modified on [% SEARCH_RESULT.timestamp %])</i>[% END %]
431                 </span>
432                 [% IF ( SEARCH_RESULT.summary ) %]
433                 <span class="result_summary">
434                         [% SEARCH_RESULT.summary %]
435                 </span>
436                 [% END %]
437                 [% IF ( SEARCH_RESULT.copyrightdate ) %]<span class="results_summary"><span class="label">Date:</span>[% SEARCH_RESULT.copyrightdate %]</span>[% END %]
438
439                                 <span class="results_summary">
440                 <span class="label">Availability:</span>
441                     [% IF ( SEARCH_RESULT.available_items_loop.0 ) %]
442                     <span class="available"><strong>Copies available:</strong>
443                     [% FOREACH available_items_loo IN SEARCH_RESULT.available_items_loop %]
444                     [% UNLESS ( available_items_loo.hideatopac ) %]
445                     [% IF ( singleBranchMode ) %]
446                         [% available_items_loo.location %]
447                     [% ELSE %]
448                         [% available_items_loo.branchname %]
449                     [% END %]
450
451                     [% IF ( OPACItemsResultsDisplay ) %]
452                                             [% UNLESS ( singleBranchMode ) %][% available_items_loo.location %][% END %]
453                         [% IF ( available_items_loo.itemcallnumber ) %][<a href="/cgi-bin/koha/opac-search.pl?q=callnum:[% available_items_loo.itemcallnumber |url %]">[% available_items_loo.itemcallnumber %]</a>][% END %]
454                     [% END %]
455                     ([% available_items_loo.count %]),
456                     [% END %]
457                     [% END %]
458                     </span>
459                     [% ELSE %]
460                     [% IF ( SEARCH_RESULT.ALTERNATEHOLDINGS ) %]
461                     [% FOREACH ALTERNATEHOLDING IN SEARCH_RESULT.ALTERNATEHOLDINGS %]
462                         &nbsp;<span id="alternateholdings">[% ALTERNATEHOLDING.holding %]</span>,
463                     [% END %]
464                     [% ELSE %]
465                         <span class="unavailable">No items available:</span>
466                     [% END %]
467                     [% END %]
468                     <span class="unavailable">
469                     [% IF ( SEARCH_RESULT.onloancount ) %] Checked out ([% SEARCH_RESULT.onloancount %]), [% END %]
470                     [% IF ( SEARCH_RESULT.wthdrawncount ) %] Withdrawn ([% SEARCH_RESULT.wthdrawncount %]), [% END %]
471                     [% UNLESS ( SEARCH_RESULT.hidelostitems ) %][% IF ( SEARCH_RESULT.itemlostcount ) %] Lost ([% SEARCH_RESULT.itemlostcount %]),[% END %][% END %]
472                     [% IF ( SEARCH_RESULT.damagedcount ) %] Damaged ([% SEARCH_RESULT.damagedcount %]),[% END %]
473                     [% IF ( SEARCH_RESULT.orderedcount ) %] On order ([% SEARCH_RESULT.orderedcount %]),[% END %]
474                     [% IF ( SEARCH_RESULT.onholdcount ) %] On hold ([% SEARCH_RESULT.onholdcount %]),[% END %]
475                     [% IF ( SEARCH_RESULT.intransitcount ) %] In transit ([% SEARCH_RESULT.intransitcount %]),[% END %]
476                     </span>
477                 </span>
478
479                                 [% END %]
480                                 [% IF ( LibraryThingForLibrariesID ) %]<div class="ltfl_reviews"></div>[% END %]
481                                 [% IF ( opacuserlogin ) %][% IF ( TagsEnabled ) %]
482                                 [% IF ( TagsShowOnList ) %]
483                                 [% IF ( SEARCH_RESULT.TagLoop.size ) %]
484                                         <div class="results_summary"><span class="label">Tags:</span>
485                                         <ul style="display: inline; list-style: none;">[% FOREACH TagLoo IN SEARCH_RESULT.TagLoop %]<li style="display: inline; list-style: none;"><a href="/cgi-bin/koha/opac-search.pl?tag=[% TagLoo.term |url %]&amp;q=[% TagLoo.term |url %]">[% TagLoo.term %]</a> <span class="weight">([% TagLoo.weight_total %])</span></li>
486                                             [% END %]
487                                         </ul>
488                                    [% END %]
489                                 [% IF ( TagsInputOnList ) %]
490                                     [% IF ( loggedinusername ) %]
491                                         <span class="label">New tag:</span>
492                                         <input name="newtag[% SEARCH_RESULT.biblionumber %]" id="newtag[% SEARCH_RESULT.biblionumber %]" maxlength="100" />
493                                         <input name="tagbutton" class="tagbutton" title="[% SEARCH_RESULT.biblionumber %]" type="submit" value="Add" />
494                                     <span id="newtag[% SEARCH_RESULT.biblionumber %]_status" class="tagstatus" style="display:none;">
495                                         Tag status here.
496                                     </span>
497                                        [% ELSIF ( loop.first ) %]<span class="tagstatus" id="login4tags">Log in to add tags.</span>
498                                     [% END %]
499                                 [% END %]
500                                     [% IF ( SEARCH_RESULT.TagLoop.size ) %]
501                                     </div>[% END %]
502                                 [% END %]
503                                 [% END %][% END %]
504                                 [% IF ( SEARCH_RESULT.searchhighlightblob ) %]<span class="results_summary"><span class="label">Match:</span> [% SEARCH_RESULT.searchhighlightblob %]</span>[% END %]
505
506 <span class="results_summary actions"><span class="label">Actions:</span>
507                                 [% IF ( RequestOnOpac ) %]
508                                         [% UNLESS ( SEARCH_RESULT.norequests ) %]
509                                                 [% IF ( opacuserlogin ) %]
510                                                         [% IF ( AllowOnShelfHolds ) %]
511                                                                 <a class="hold" href="/cgi-bin/koha/opac-reserve.pl?biblionumber=[% SEARCH_RESULT.biblionumber %]">Place Hold</a><!-- add back when available 0 holds in queue-->
512                                                         [% ELSE %]
513                                                                 [% IF ( SEARCH_RESULT.itemsissued ) %]
514                                                                         <a class="hold" href="/cgi-bin/koha/opac-reserve.pl?biblionumber=[% SEARCH_RESULT.biblionumber %]">Place Hold</a><!-- add back when available 0 holds in queue-->
515                                                                 [% END %]
516                                                         [% END %]
517                                                 [% END %]
518                                         [% END %]
519                                 [% END %]
520
521
522                                 [% IF ( opacuserlogin ) %][% IF ( loggedinusername ) %][% IF ( virtualshelves ) %]<a class="addtoshelf" href="/cgi-bin/koha/opac-addbybiblionumber.pl?biblionumber=[% SEARCH_RESULT.biblionumber %]" onclick="Dopop('opac-addbybiblionumber.pl?biblionumber=[% SEARCH_RESULT.biblionumber %]'); return false;">Save to Lists</a>
523                         [% END %][% END %][% END %]
524                         [% IF ( opacbookbag ) %]<a class="addtocart" href="#" onclick="addRecord('[% SEARCH_RESULT.biblionumber %]'); return false;">Add to Cart</a>[% END %]
525                                 </span>
526                                 </td><td>
527                                         <a class="p1" href="/cgi-bin/koha/opac-detail.pl?biblionumber=[% SEARCH_RESULT.biblionumber %]">
528             [% IF ( OPACLocalCoverImages ) %]<span title="[% SEARCH_RESULT.biblionumber |url %]" class="[% SEARCH_RESULT.biblionumber %]" id="local-thumbnail[% loop.count %]"></span>[% END %]
529                     [% IF ( OPACAmazonEnabled ) %][% IF ( OPACAmazonCoverImages ) %][% IF ( SEARCH_RESULT.normalized_isbn ) %]<img src="http://images.amazon.com/images/P/[% SEARCH_RESULT.normalized_isbn %].01.TZZZZZZZ.jpg" alt="" class="thumbnail" />[% ELSE %]<span class="no-image">No cover image available</span>[% END %][% END %][% END %]
530
531                                         [% IF ( SyndeticsEnabled ) %][% IF ( SyndeticsCoverImages ) %][% IF ( using_https ) %]
532                 <img src="https://secure.syndetics.com/index.aspx?isbn=[% SEARCH_RESULT.normalized_isbn %]/SC.GIF&amp;client=[% SyndeticsClientCode %]&amp;type=xw10&amp;upc=[% SEARCH_RESULT.normalized_upc %]&amp;oclc=[% SEARCH_RESULT.normalized_oclc %]" alt="" class="thumbnail" />
533                 [% ELSE %]
534                 <img src="http://www.syndetics.com/index.aspx?isbn=[% SEARCH_RESULT.normalized_isbn %]/SC.GIF&amp;client=[% SyndeticsClientCode %]&amp;type=xw10&amp;upc=[% SEARCH_RESULT.normalized_upc %]&amp;oclc=[% SEARCH_RESULT.normalized_oclc %]" alt="" class="thumbnail" />[% END %][% END %][% END %]
535
536                 [% IF ( GoogleJackets ) %][% IF ( SEARCH_RESULT.normalized_isbn ) %]<div style="block" title="[% SEARCH_RESULT.biblionumber |url %]" class="[% SEARCH_RESULT.normalized_isbn %]" id="gbs-thumbnail[% loop.count %]"></div>[% ELSE %]<span class="no-image">No cover image available</span>[% END %][% END %]
537                 [% IF OpenLibraryCovers %][% IF SEARCH_RESULT.normalized_isbn %]<div style="block" title="[% SEARCH_RESULT.biblionumber %]" class="[% SEARCH_RESULT.normalized_isbn %]" id="openlibrary-thumbnail[% loop.count %]"></div>[% ELSE %]<span class="no-image">No cover image available</span>[% END %][% END %]
538                 </a>
539                 [% IF ( BakerTaylorEnabled ) %][% IF ( SEARCH_RESULT.normalized_isbn ) %]<a href="https://[% BakerTaylorBookstoreURL |html %][% SEARCH_RESULT.normalized_isbn %]"><img alt="See Baker &amp; Taylor" src="[% BakerTaylorImageURL |html %][% SEARCH_RESULT.normalized_isbn %]" /></a>[% ELSE %]<span class="no-image">No cover image available</span>[% END %][% END %]
540                                 </td>
541                 </tr>
542                 [% END %]
543             </table>
544     </form>
545     <form id="hold_form" name="hold_form" method="get" action="/cgi-bin/koha/opac-reserve.pl">
546         <!-- The value will be set by holdBiblioNums() in basket.js -->
547         <input id="hold_form_biblios" type="hidden" name="biblionumbers" value=""/>
548     </form>
549         </div>
550     [% END %]
551         [% INCLUDE 'page-numbers.inc' %]
552
553     [% ELSE %]
554     [% END %]
555
556         [% IF ( suggestion ) %]
557 [% IF ( AnonSuggestions ) %]<div class="suggestion">Not finding what you're looking for?<br />  Make a <a href="/cgi-bin/koha/opac-suggestions.pl?op=add">purchase suggestion</a></div>[% ELSE %][% IF ( loggedinusername ) %]<div class="suggestion">Not finding what you're looking for?<br />  Make a <a href="/cgi-bin/koha/opac-suggestions.pl?op=add">purchase suggestion</a></div>[% END %][% END %]
558 [% END %]
559 </div>
560 </div>
561 </div>
562         [% IF ( opacfacets ) %]
563 <div class="yui-b"><div id="facetcontainer" class="container">
564         <!-- FACETS START -->
565                 [% INCLUDE 'opac-facets.inc' %]
566         <!-- FACETS END -->
567 </div></div>
568         [% END %]
569 </div>
570
571 [% IF ( LibraryThingForLibrariesID ) %]
572 [% IF ( using_https ) %]
573 <script src="https://ltfl.librarything.com/forlibraries/widget.js?id=[% LibraryThingForLibrariesID %]&amp;systype=koha" type="text/javascript"></script>
574 [% ELSE %]
575 <script src="http://ltfl.librarything.com/forlibraries/widget.js?id=[% LibraryThingForLibrariesID %]&amp;systype=koha" type="text/javascript"></script>
576 [% END %]
577 [% END %]
578
579 [% INCLUDE 'opac-bottom.inc' %]