Bug 15229: Fix tiny typos in error messages of batch checkout page
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / circ / reserveratios.tt
index d55382e..67f4226 100644 (file)
@@ -1,11 +1,10 @@
+[% USE KohaDates %]
 [% INCLUDE 'doc-head-open.inc' %]
 <title>Koha &rsaquo; Circulation &rsaquo; Hold ratios</title>
 [% INCLUDE 'doc-head-close.inc' %]
 [% INCLUDE 'calendar.inc' %]
 <link rel="stylesheet" type="text/css" href="[% themelang %]/css/datatables.css" />
-<script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.dataTables.min.js"></script>
-[% INCLUDE 'datatables-strings.inc' %]
-<script type="text/javascript" src="[% themelang %]/js/datatables.js"></script>
+[% INCLUDE 'datatables.inc' %]
 <script type="text/javascript">
 //<![CDATA[
      $(document).ready(function() {
             function () { $(this).toggleClass("ulined") }
         );
         $("#holdst").dataTable($.extend(true, {}, dataTablesDefaults, {
+            "aaSorting": [ [2,'desc'], [3,'asc'] ],
             "aoColumnDefs": [
-                { "aTargets": [ 8 ], "sType": "natural" }
+                { "aTargets": [ 0,1,2,8 ], "sType": "natural" },
+                { "aTargets": [ 3 ], "sType": "anti-the" },
             ],
-            "aLengthMenu": [[10, 20, 50, 100, -1], [10, 20, 50, 100, "All"]],
-            "iDisplayLength": 20,
             "sPaginationType": "four_button"
         }));
      });
@@ -44,8 +43,8 @@
     <div id="yui-main">
     <div class="yui-b">
 <h1>Hold ratios to calculate items needed</h1>
-   <h3>Calculated on [% todaysdate %]. From [% from %]
-    to [% to %]</h3>
+   <h3>Calculated on [% todaysdate | $KohaDates %]. From [% from | $KohaDates %]
+    to [% to | $KohaDates %]</h3>
 <p>These items have a hold ratio &ge; [% ratio %].</p>
 <div class="sql">[% sql %]</div>
 
@@ -57,6 +56,7 @@
           <th>Items</th>
           <th>Hold ratio</th>
           <th>Title</th>
+          <th>Home libraries</th>
           <th>Holding libraries</th>
           <th>Location</th>
           <th>Itype</th>
             <td><p class="ratiolimit">[% reserveloo.thisratio %]</p></td>
             <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 %]
             </td>
-            <td><p>[% reserveloo.listbranch %]</p></td>
+            <td><p>[% reserveloo.homebranch_list %]</p></td>
+            <td><p>[% reserveloo.holdingbranch_list %]</p></td>
             <td><p>[% reserveloo.location %]</p></td>
             <td><p>[% reserveloo.itype %]</p></td>
             <td><p>[% reserveloo.listcall %]</p></td>
-            <td>[% IF ( reserveloo.thisratio_atleast1 ) %]<p><b>[% reserveloo.ratiocalc %] to order</b></p>[% END %]</td>
+            <td>[% IF ( reserveloo.thisratio_atleast1 ) %]<p>[% IF ( CAN_user_acquisition && basketno && booksellerid ) %]<!-- [% reserveloo.ratiocalc %] --><a href="/cgi-bin/koha/acqui/neworderempty.pl?biblionumber=[% reserveloo.biblionumber %]&amp;booksellerid=[% booksellerid %]&amp;basketno=[% basketno %]&amp;rr_quantity_to_order=[% reserveloo.ratiocalc %]">[% END %]<b>[% reserveloo.ratiocalc %] to order</b>[% IF ( CAN_user_acquisition && basketno && booksellerid ) %]</a>[% END %]
+            [% IF ( reserveloo.pendingorders ) %]<br><b>[% reserveloo.pendingorders %] pending</b>[% END %]</p>[% END %]</td>
         </tr>
       [% END %]
       </tbody>
 <form action="/cgi-bin/koha/circ/reserveratios.pl" method="post" >
 <fieldset class="brief">
 <h4>Refine results:</h4>
-<ol><li><label for="ratio">
-    Hold ratio:
-</label>
-<input type="text" size="5" id="ratio" name="ratio" value="[% ratio %]" /></li>
-<li><label for="from">
-    Start date:
-</label>
-<input type="text" size="10" id="from" name="from" value="[% from %]" class="datepickerfrom" />
-</li>
-<li><label for="to">
-    End date:
-</label>
-<input size="10" id="to" name="to" value="[% to %]" type="text" class="datepickerto" />
-</li></ol>
+<ol>
+    <li>
+        <label for="ratio">Hold ratio:</label>
+        <input type="text" size="5" id="ratio" name="ratio" value="[% ratio %]" />
+    <li>
+
+    <li>
+        <label for="include_ordered">Included ordered:</label>
+        [% IF include_ordered %]
+            <input id="include_ordered" name="include_ordered" type="checkbox" checked="checked"/>
+        [% ELSE %]
+            <input id="include_ordered" name="include_ordered" type="checkbox"/>
+        [% END %]
+    <li>
+
+    <li>
+        <label for="from">Start date:</label>
+        <input type="text" size="10" id="from" name="from" value="[% from | $KohaDates %]" class="datepickerfrom" />
+    </li>
+
+    <li>
+        <label for="to">End date:</label>
+        <input size="10" id="to" name="to" value="[% to | $KohaDates %]" type="text" class="datepickerto" />
+    </li>
+</ol>
 (inclusive)
 
 <fieldset class="action"><input type="submit" value="Go" class="submit"/></fieldset>
 </fieldset>
+[% IF ( CAN_user_acquisition && basketno && booksellerid ) %]
+<input type="hidden" name="booksellerid" value="[% booksellerid %]" />
+<input type="hidden" name="basketno" value="[% basketno %]" />
+[% END %]
 </form>
 
 </div>