Bug 20102: Remove attribute "text/css" for <style> element used in staff client templates
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / circ / view_holdsqueue.tt
1 [% USE raw %]
2 [% USE Asset %]
3 [% USE Koha %]
4 [% USE KohaDates %]
5 [% USE ItemTypes %]
6 [% USE Branches %]
7 [% USE AuthorisedValues %]
8 [% USE ColumnsSettings %]
9 [% USE Koha %]
10 [% SET footerjs = 1 %]
11 [% INCLUDE 'doc-head-open.inc' %]
12 <title>Koha &rsaquo; Circulation &rsaquo; Holds queue</title>
13 [% INCLUDE 'doc-head-close.inc' %]
14 <style> p { margin-top: 0; }</style>
15 [% Asset.css("css/datatables.css") | $raw %]
16 </head>
17
18 <body id="circ_view_holdsqueue" class="circ">
19 [% INCLUDE 'header.inc' %]
20 [% INCLUDE 'cat-search.inc' %]
21
22 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a>
23 &rsaquo; <a href="/cgi-bin/koha/circ/circulation-home.pl">Circulation</a>
24 &rsaquo; <a href="/cgi-bin/koha/circ/view_holdsqueue.pl">Holds queue</a>
25 [% IF ( run_report ) %] &rsaquo; Results[% END %]
26 </div>
27
28 <div class="main container-fluid">
29     <div class="row">
30         <div class="col-sm-12">
31             <main>
32                 <div class="row">
33
34                 [% IF Koha.Preference('CircSidebar') %]
35                     <div class="col-sm-10 col-sm-push-2">
36                 [% ELSE %]
37                     <div class="col-md-10 col-md-offset-1 col-lg-8 col-lg-offset-2">
38                 [% END %]
39
40 <h1>Holds queue</h1>
41
42 [% IF ( run_report ) %]
43     [% IF ( total ) %]
44         <div class="results">[% total | html %] items found for
45             [% IF ( branchlimit ) %][% Branches.GetName( branchlimit ) | html %][% ELSE %]All libraries[% END %]
46         </div>
47     [% ELSE %]
48         <div class="dialog message">No items found.</div>
49     [% END %]
50     [% IF ( itemsloop ) %]
51 <table id="holdst">
52         <thead>
53     <tr>
54         <th class="hq-title">Title</th>
55         <th class="hq-collection">Collection</th>
56         <th class="hq-itemtype">Item type</th>
57         <th class="hq-callnumber">Call number</th>
58         <th class="hq-copynumber">Copy number</th>
59         <th class="hq-enumchron">Enumeration</th>
60         <th class="hq-barcode">Barcode</th>
61         <th class="hq-patron">Patron</th>
62         <th class="hq-sendto">Send to</th>
63         <th class="hq-date">Date</th>
64         <th class="hq-notes">Notes</th>
65     </tr>
66     <tr>
67         <td class="hq-title">
68             <span class="filter_column filter_text">
69                 <input class="text_filter" type="text" placeholder="Title">
70             </span>
71         </td>
72         <td class="hq-collection">
73             <span class="filter_column filter_text">
74                 <input type="text" placeholder="Collection">
75             </span>
76         </td>
77         <td class="hq-itemtype">
78             <span class="filter_column filter_text">
79                 <input type="text" placeholder="Item type">
80             </span>
81         </td>
82         <td class="hq-callnumber">
83             <span class="filter_column filter_text">
84                 <input type="text" placeholder="Call number">
85             </span>
86         </td>
87         <td class="hq-copynumber">
88             <span class="filter_column filter_text">
89                 <input type="text" placeholder="Copy number">
90             </span>
91         </td>
92         <td class="hq-enumchron">
93             <span class="filter_column filter_text">
94                 <input type="text" placeholder="Enumeration">
95             </span>
96         </td>
97         <td class="hq-barcode">
98             <span class="filter_column filter_text">
99                 <input type="text" placeholder="Barcode">
100             </span>
101         </td>
102         <td class="hq-patron">
103             <span class="filter_column filter_text">
104                 <input type="text" placeholder="Patron">
105             </span>
106         </td>
107         <td class="hq-sendto">
108             <span class="filter_column filter_text">
109                 <input type="text" placeholder="Send to">
110             </span>
111         </td>
112         <td class="hq-date">
113             <span class="filter_column filter_text">
114                 <input type="text" placeholder="Date">
115             </span>
116         </td>
117         <td class="hq-notes">
118             <span class="filter_column filter_text">
119                 <input type="text" placeholder="Notes">
120             </span>
121         </td>
122     </tr>
123         </thead>
124      <tbody>[% FOREACH itemsloo IN itemsloop %]
125         <tr>
126             <td class="hq-title">
127                 <p><a href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=[% itemsloo.biblionumber | uri %]"><strong>[% itemsloo.title | html %]</strong> [% FOREACH s IN itemsloo.subtitle %] [% s | html %][% END %]</a></p>
128                 <p>
129                     <div class="hq-biblionumber content_hidden">[% itemsloo.biblionumber | html %]</div>
130                     <div class="hq-author">[% itemsloo.author | html %]</div>
131                     <div class="hq-pubdata">
132                         [% IF ( itemsloo.publishercode ) %][% itemsloo.publishercode | html %][% END %]
133
134                         [% IF ( itemsloo.publicationyear ) %]
135                             , [% itemsloo.publicationyear | html %]
136                         [% ELSIF ( itemsloo.copyrightdate ) %]
137                             , [% itemsloo.copyrightdate | html %]
138                         [% END %]
139
140                         [% IF ( itemsloo.pages ) %]: [% itemsloo.pages | html %] [% END %]
141
142                         [% IF ( itemsloo.item('size') ) %][% itemsloo.item('size') | html %][% END %]
143
144                         [% IF ( itemsloo.isbn ) %]ISBN: [% itemsloo.isbn | html %][% END %]
145                     </div>
146                 </p>
147             </td>
148             <td class="hq-collection">[% AuthorisedValues.GetByCode( 'CCODE', itemsloo.ccode ) | html %]</td>
149             <td class="hq-itemtype">[% ItemTypes.GetDescription( itemsloo.itype ) | html %]</td>
150             <td class="hq-callnumber">[% IF ( itemsloo.location ) %]<em>[% AuthorisedValues.GetByCode( 'LOC', itemsloo.location ) | html %]</em> [% END %][% itemsloo.itemcallnumber | html %]</td>
151             <td class="hq-copynumber">[% itemsloo.copynumber | html %]</td>
152             <td class="hq-enumchron">[% itemsloo.enumchron | html %]</td>
153             <td class="hq-barcode">
154                 [% IF ( itemsloo.item_level_request ) %]
155                     <em>Only item:</em> <strong>[% itemsloo.barcode | html %]</strong>
156                 [% ELSE %]
157                     <strong>[% itemsloo.barcode | html %]</strong> <em>or any available</em>
158                 [% END %]
159             </td>
160             <td class="hq-patron">
161               <p>
162                   [% INCLUDE 'patron-title.inc' patron=itemsloo.patron hide_patron_infos_if_needed=1 link_to="circulation_reserves" %]
163               </p>
164               [% UNLESS Koha.Preference('HidePatronName') %]
165                  <p>[% itemsloo.patron.phone | html %]</p>
166               [% END %]
167             </td>
168             <td class="hq-sendto">[% Branches.GetName( itemsloo.pickbranch ) | html %]</td>
169             <td class="hq-date"><span title="[% itemsloo.reservedate | html %]">[% itemsloo.reservedate | $KohaDates %]</span></td>
170             <td class="hq-notes">[% itemsloo.notes | html %]</td>
171         </tr>
172     [% END %]</tbody>
173     </table>
174         [% END %] 
175         [% END %]
176
177 [% UNLESS ( total ) %]
178 <form name="f" action="/cgi-bin/koha/circ/view_holdsqueue.pl" method="post">
179         <fieldset class="rows">
180         <ol>
181         <li>
182             <label for="branchlimit">Library: </label>
183             <select name="branchlimit" id="branchlimit">
184                 <option value="">All</option>
185                 [% PROCESS options_for_libraries libraries => Branches.all( only_from_group => 1 ) %]
186             </select>
187         </li>
188     </ol></fieldset>
189     <fieldset class="action">    <input type="submit" value="Submit" />
190         <input type="hidden" name="run_report" value="1" /></fieldset>
191 </form>
192 [% END %]
193
194                     [% IF Koha.Preference('CircSidebar') %]
195                             </div> <!-- /.col-sm-10.col-sm-push-2 -->
196                             <div class="col-sm-2 col-sm-pull-10">
197                                 <aside>
198                                     [% INCLUDE 'circ-nav.inc' %]
199                                 </aside>
200                             </div> <!-- /.col-sm-2.col-sm-pull-10 -->
201                         </div> <!-- /.row -->
202                     [% END %]
203
204             </main>
205         </div> <!-- /.col-sm-12 -->
206     </div> <!-- /.row -->
207
208 [% MACRO jsinclude BLOCK %]
209     [% INCLUDE 'datatables.inc' %]
210     [% INCLUDE 'columns_settings.inc' %]
211     <script>
212         $(document).ready(function() {
213             var holdst;
214
215             // Setup filters before DataTables initialisation, in case some columns are
216             // hidden by default
217             var filterColumnTimeoutId;
218             var filterColumn = function(e) {
219                 clearTimeout(filterColumnTimeoutId);
220                 filterColumnTimeoutId = setTimeout(function() {
221                     var input = $(e.target);
222                     var idx = input.parents('td').index();
223                     holdst.api().column(idx + ':visible').search(input.val()).draw();
224                 }, 200);
225             };
226             $('#holdst thead input').on('change keyup keydown', filterColumn);
227
228             var columns_settings = [% ColumnsSettings.GetColumns('circ', 'view_holdsqueue', 'holds-table', 'json') | $raw %];
229             var holdst = KohaTable("holdst", {
230                 "aaSorting": [[ 3, "asc" ]],
231                 "aoColumns": [
232                     { "sType": "anti-the" },null,null,null,null,null,null,null,null,{ "sType": "title-string" },null
233                 ],
234                 "sDom": 'B<"clearfix">t',
235                 "bSortCellsTop": true,
236                 "bPaginate": false
237             }, columns_settings);
238
239         });
240     </script>
241 [% END %]
242
243 [% INCLUDE 'intranet-bottom.inc' %]