Bug 16963 - Remove the use of "onclick" from subscription add template
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / serials / result.tt
1 [% INCLUDE 'doc-head-open.inc' %]
2 <title>Koha &rsaquo; Serials &rsaquo; Search results</title>
3 [% INCLUDE 'doc-head-close.inc' %]
4 <script type="text/javascript">
5 //<![CDATA[
6     $(document).ready(function(){
7         $(".select_title").on("click",function(e){
8             e.preventDefault();
9             var biblionumber = $(this).data("biblionumber");
10             GetIt( biblionumber, $(this) );
11         });
12     });
13     function GetIt(bibno,title) {
14         title = title.parents('tr').find('.title').text();
15         opener.document.f.biblionumber.value = bibno;
16         opener.document.f.title.value = title;
17         window.close();
18     }
19 //]]>
20 </script>
21 </head>
22 <body id="ser_result" class="ser">
23
24 <div id="doc" class="yui-t7">
25    <div id="bd">
26         
27
28 [% IF ( total ) %]
29 <h1>Search results from [% from %] to [% to %] of [% total %]</h1>
30 <table>
31     <tr>
32        <th>Title</th>
33        <th>Author</th>
34        <th>Publisher</th>
35        <th>Publication year</th>
36        <th>ISSN</th>
37            <th>&nbsp;</th>
38     </tr>
39     [% FOREACH resultsloo IN resultsloop %]
40         <tr>
41             <td class="title">[% resultsloo.title |html %] [% resultsloo.subtitle |html %]
42             </td>
43             <td>
44                 [% resultsloo.author |html %]
45             </td>
46             <td>
47                 [% resultsloo.publishercode |html %]
48             </td>
49             <td>
50                 [% resultsloo.publicationyear |html %]
51             </td>
52             <td>
53                 [% resultsloo.issn |html %]
54             </td>
55             <td><a class="btn btn-mini select_title" data-biblionumber="[% resultsloo.biblionumber %]" href="#" title="Choose this record">Choose</a></td>
56         </tr>
57     [% END %]
58     </table>
59 [% ELSE %]
60
61     <div class="dialog message">
62         <p>No results found for <b>[% query %]</b></p>
63     </div>
64
65 [% END %]
66
67 <div class="pages">
68     [% IF ( displayprev ) %]
69         <a class="nav" href="/cgi-bin/koha/serials/subscription-bib-search.pl?op=do_search&amp;type=intranet&amp;startfrom=[% startfromprev |url %]&amp;q=[% query |url %]">&lt;&lt; Previous</a>
70     [% END %]
71     [% IF ( displaynext ) %]
72         <a class="nav" href="/cgi-bin/koha/serials/subscription-bib-search.pl?op=do_search&amp;type=intranet&amp;startfrom=[% startfromnext |url %]&amp;q=[% query |url %]">Next  &gt;&gt;</a>
73     [% END %]
74 </div>
75
76 <p><a href="subscription-bib-search.pl">Search for another record</a></p>
77
78 <div id="closewindow"><a class="btn btn-default close" href="#">Close</a></div>
79
80 </div>
81
82 [% INCLUDE 'intranet-bottom.inc' %]