Bug 11711 - Use new DataTables include in circ templates
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / circ / reserveratios.tt
1 [% INCLUDE 'doc-head-open.inc' %]
2 <title>Koha &rsaquo; Circulation &rsaquo; Hold ratios</title>
3 [% INCLUDE 'doc-head-close.inc' %]
4 [% INCLUDE 'calendar.inc' %]
5 <link rel="stylesheet" type="text/css" href="[% themelang %]/css/datatables.css" />
6 [% INCLUDE 'datatables.inc' %]
7 <script type="text/javascript">
8 //<![CDATA[
9      $(document).ready(function() {
10         $(".ratiolimit").click(function () {
11             $("#ratio").val($(this).html());
12         });
13         $(".ratiolimit").hover(
14             function () { $(this).toggleClass("ulined") },
15             function () { $(this).toggleClass("ulined") }
16         );
17         $("#holdst").dataTable($.extend(true, {}, dataTablesDefaults, {
18             "aaSorting": [ [0,'desc'], [3,'asc'] ],
19             "aoColumnDefs": [
20                 { "aTargets": [ 8 ], "sType": "natural" },
21                 { "aTargets": [ 3 ], "sType": "anti-the" }
22             ],
23             "aoColumns": [
24                 null,
25                 null,
26                 null,
27                 { "sType": "anti-the" },
28                 null,
29                 null,
30                 null,
31                 null,
32                 null
33             ],
34             "sPaginationType": "four_button"
35         }));
36      });
37 //]]>
38 </script>
39 <style type="text/css">
40     .sql { display: none; }
41     .ulined { text-decoration: underline; }
42     .ratiolimit { color: blue; cursor: pointer; }
43 </style>
44 </head>
45 <body id="circ_reserveratios" class="circ">
46 [% INCLUDE 'header.inc' %]
47 [% INCLUDE 'circ-search.inc' %]
48
49 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/circ/circulation-home.pl">Circulation</a> &rsaquo; Hold ratios</div>
50
51 <div id="doc3" class="yui-t2">
52    <div id="bd">
53     <div id="yui-main">
54     <div class="yui-b">
55 <h1>Hold ratios to calculate items needed</h1>
56    <h3>Calculated on [% todaysdate %]. From [% from %]
57     to [% to %]</h3>
58 <p>These items have a hold ratio &ge; [% ratio %].</p>
59 <div class="sql">[% sql %]</div>
60
61 [% IF ( reserveloop ) %]
62     <table id="holdst">
63       <thead>
64         <tr>
65           <th>Holds</th>
66           <th>Items</th>
67           <th>Hold ratio</th>
68           <th>Title</th>
69           <th>Holding libraries</th>
70           <th>Location</th>
71           <th>Itype</th>
72           <th>Call numbers</th>
73           <th>Items needed</th>
74         </tr>
75       </thead>
76       <tbody>
77       [% FOREACH reserveloo IN reserveloop %]
78         <tr>
79             <td><p>[% reserveloo.reservecount %]</p></td>
80             <td><p>[% reserveloo.itemcount %]</p></td>
81             <td><p class="ratiolimit">[% reserveloo.thisratio %]</p></td>
82             <td> [% INCLUDE 'biblio-default-view.inc' biblionumber = reserveloo.biblionumber %][% reserveloo.title |html %] [% IF ( reserveloo.subtitle ) %][% FOREACH subtitl IN reserveloo.subtitle %][% subtitl.subfield %][% END %][% END %]</a>[% IF ( reserveloo.author ) %] by [% reserveloo.author %][% END %]
83             </td>
84             <td><p>[% reserveloo.listbranch %]</p></td>
85             <td><p>[% reserveloo.location %]</p></td>
86             <td><p>[% reserveloo.itype %]</p></td>
87             <td><p>[% reserveloo.listcall %]</p></td>
88             <td>[% IF ( reserveloo.thisratio_atleast1 ) %]<p><b>[% reserveloo.ratiocalc %] to order</b></p>[% END %]</td>
89         </tr>
90       [% END %]
91       </tbody>
92     </table>
93     [% ELSE %]
94         <b>No items found.</b>
95     [% END %]
96 </div>
97 </div>
98 <div class="yui-b">
99 <form action="/cgi-bin/koha/circ/reserveratios.pl" method="post" >
100 <fieldset class="brief">
101 <h4>Refine results:</h4>
102 <ol><li><label for="ratio">
103     Hold ratio:
104 </label>
105 <input type="text" size="5" id="ratio" name="ratio" value="[% ratio %]" /></li>
106 <li><label for="from">
107     Start date:
108 </label>
109 <input type="text" size="10" id="from" name="from" value="[% from %]" class="datepickerfrom" />
110 </li>
111 <li><label for="to">
112     End date:
113 </label>
114 <input size="10" id="to" name="to" value="[% to %]" type="text" class="datepickerto" />
115 </li></ol>
116 (inclusive)
117
118 <fieldset class="action"><input type="submit" value="Go" class="submit"/></fieldset>
119 </fieldset>
120 </form>
121
122 </div>
123 </div>
124 [% INCLUDE 'intranet-bottom.inc' %]