Bug 20033: Switch single-column templates to Bootstrap grid: Catalog
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / basket / basket.tt
1 [% SET footerjs = 1 %]
2 [% BLOCK controls %]
3     <p style="padding: 7px 0; border-top : 1px solid #E8E8E8;">
4         <a id="CheckAll" href="#"><i class="fa fa-check"></i> Select all</a> <a id="CheckNone" href="#"><i class="fa fa-remove"></i> Clear all</a>
5         | <b>Selected items :</b>
6         <a href="#" id="remove_from_cart">Remove</a>
7
8         [% IF ( loggedinusername ) %]
9              | <a href="#" id="add_to_list">Add to a list</a>
10         [% END %]
11
12         [% IF ( CAN_user_reserveforothers ) %]
13              | <a href="#" id="place_hold">Place hold</a>
14         [% END %]
15
16         [% IF CAN_user_tools_records_batchmod %]
17             | <a href="#" id="batch_modify">Batch modify</a>
18         [% END %]
19
20         [% IF CAN_user_tools_records_batchdel %]
21             | <a href="#" id="batch_delete">Batch delete</a>
22         [% END %]
23     </p>
24 [% END %]
25 [% INCLUDE 'doc-head-open.inc' %]
26 <title>[% IF ( LibraryNameTitle ) %][% LibraryNameTitle %][% ELSE %]Koha online[% END %] Catalog &rsaquo; Your cart</title>
27     [% IF ( print_basket ) %]
28
29 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
30 <link rel="shortcut icon" href="[% IF ( IntranetFavicon ) %][% IntranetFavicon %][% ELSE %][% interface %]/[% theme %]/img/favicon.ico[% END %]" type="image/x-icon" />
31 <style type="text/css">
32     @import url([% interface %]/[% theme %]/css/print.css);
33 </style>
34     [% ELSE %][% INCLUDE 'doc-head-close.inc' %]
35 <link rel="stylesheet" type="text/css" href="[% interface %]/[% theme %]/css/datatables_[% KOHA_VERSION %].css" />
36         [% END %]
37 </head>
38 [% IF ( print_basket ) %]<body id="cart_basket" class="cart" onload="print();history.back();">[% ELSE %]<body id="cart_basket" class="cart">[% END %]
39
40 <div class="main container-fluid">
41     <div class="row">
42         <div class="col-md-12">
43
44 <div class="container">
45 [% UNLESS ( print_basket ) %]
46 <h1>Your cart</h1>
47
48 <div id="toolbar" class="btn-toolbar">
49     [% IF ( verbose ) %]
50         <a href="basket.pl" class="btn btn-default btn-sm showdetails showless"><i class="fa fa-folder"></i> Brief display</a>
51     [% ELSE %]
52         <a href="basket.pl" class="btn btn-default btn-sm showdetails showmore"><i class="fa fa-folder-open"></i> More details</a>
53     [% END %]
54
55     <a class="btn btn-default btn-sm" href="basket.pl" id="send_cart"><i class="fa fa-envelope"></i> Send</a>
56     <div class="btn-group">
57         <a class="btn btn-default btn-sm dropdown-toggle" data-toggle="dropdown" href="#" id="downloadcart"><i class="fa fa-download"></i> Download <span class="caret"></span> </a>
58         <ul class="dropdown-menu">
59             <li><a href="/cgi-bin/koha/basket/downloadcart.pl?format=iso2709&amp;bib_list=[% bib_list %]">iso2709</a></li>
60             <li><a href="/cgi-bin/koha/basket/downloadcart.pl?format=ris&amp;bib_list=[% bib_list %]">RIS</a></li>
61             <li><a href="/cgi-bin/koha/basket/downloadcart.pl?format=bibtex&amp;bib_list=[% bib_list %]">BibTex</a></li>
62         [% FOREACH csv_profile IN csv_profiles %]
63             <li><a href="/cgi-bin/koha/basket/downloadcart.pl?format=[% csv_profile.export_format_id %]&amp;bib_list=[% bib_list %]">CSV - [% csv_profile.profile %]</a></li>
64         [% END %]
65         </ul>
66     </div>
67     <a class="btn btn-default btn-sm" href="basket.pl" id="print_cart"><i class="fa fa-print"></i> Print</a>
68     <a class="btn btn-default btn-sm" href="basket.pl" id="empty_cart"><i class="fa fa-trash"></i> Empty and close</a>
69     <a class="btn btn-default btn-sm close" href="basket.pl"><i class="fa fa-times-circle"></i> Hide window</a>
70 </div>
71         [% END %]
72
73 [% IF ( verbose ) %]
74     [% UNLESS ( print_basket ) %]
75         [% PROCESS controls %]
76     [% END %]
77             <form action="basket.pl" method="get" name="bookbag_form" id="bookbag_form">
78     [% FOREACH BIBLIO_RESULT IN BIBLIO_RESULTS %]
79     <h3>
80         [% IF ( print_basket ) %]
81             [% BIBLIO_RESULT.title |html %]
82                 [% FOREACH subtitl IN BIBLIO_RESULT.subtitle %] [% subtitl.subfield | html %][% END %]
83                 [% IF ( BIBLIO_RESULT.author ) %] [% BIBLIO_RESULT.author %][% END %]
84         [% ELSE %]
85                 <input type="checkbox" class="select_record" value="[% BIBLIO_RESULT.biblionumber %]" name="bib[% BIBLIO_RESULT.biblionumber %]" id="bib[% BIBLIO_RESULT.biblionumber %]" />
86                 [% BIBLIO_RESULT.title |html %]
87                 [% FOREACH subtitl IN BIBLIO_RESULT.subtitle %] [% subtitl.subfield | html %][% END %]
88                 [% IF ( BIBLIO_RESULT.author ) %] [% BIBLIO_RESULT.author %][% END %]
89         [% END %]
90     </h3>
91             <!-- COinS / Openurl -->
92     <span class="Z3988" title="ctx_ver=Z39.88-2004&amp;rft_val_fmt=info%3Aofi%2Ffmt%3Akev%3Amtx%3Abook&amp;rft.au=[% BIBLIO_RESULT.author %]&amp;rft.btitle=[% BIBLIO_RESULT.title |url %]&amp;rft.date=[% BIBLIO_RESULT.publicationyear %]&amp;rft.tpages=[% BIBLIO_RESULT.item('size') %]&amp;rft.isbn=[% BIBLIO_RESULT.isbn |url %]&amp;rft.aucorp=&amp;rft.place=[% BIBLIO_RESULT.place %]&amp;rft.pub=[% BIBLIO_RESULT.publisher |url %]&amp;rft.edition=[% BIBLIO_RESULT.edition %]&amp;rft.series=[% BIBLIO_RESULT.series %]&amp;rft.genre="></span>
93     <table>
94         [% IF ( BIBLIO_RESULT.isbn ) %]
95         <tr>
96             <th scope="row">ISBN</th>
97             <td>[% BIBLIO_RESULT.isbn %]</td>
98         </tr>
99         [% END %]
100
101         [% IF ( BIBLIO_RESULT.HASAUTHORS ) %]
102         <tr>
103             <th scope="row">Author(s)</th>
104             <td>
105                    [% IF ( BIBLIO_RESULT.author ) %]
106                        <p>[% BIBLIO_RESULT.author %]</p>
107                    [% END %]
108                    [% IF ( BIBLIO_RESULT.MARCAUTHORS ) %]
109                        [% FOREACH MARCAUTHOR IN BIBLIO_RESULT.MARCAUTHORS %]
110                        <p> [% FOREACH MARCAUTHOR_SUBFIELDS_LOO IN MARCAUTHOR.MARCAUTHOR_SUBFIELDS_LOOP %]
111                               [% MARCAUTHOR_SUBFIELDS_LOO.separator %]
112                                   [% MARCAUTHOR_SUBFIELDS_LOO.value %]
113                            [% END %]
114                        </p>
115                        [% END %]
116                    [% END %]
117             </td>
118         </tr>
119         [% END %]
120
121         [% IF ( BIBLIO_RESULT.publishercode ) %]
122             <tr>
123                 <th scope="row">Publisher</th>
124                 <td>[% BIBLIO_RESULT.place %] [% BIBLIO_RESULT.publishercode %] [% BIBLIO_RESULT.publicationyear %]
125                 </td>
126             </tr>
127         [% END %]
128         [% IF ( BIBLIO_RESULT.pages ) %]
129             <tr>
130                 <th scope="row">Details</th>
131                 <td>[% BIBLIO_RESULT.pages %] [% BIBLIO_RESULT.illus %] [% BIBLIO_RESULT.item('size') %]</td>
132             </tr>
133         [% END %]
134         [% IF ( BIBLIO_RESULT.seriestitle ) %]
135         <tr>
136             <th scope="row">Collection</th>
137             <td> [% BIBLIO_RESULT.seriestitle %]</td>
138         </tr>
139         [% END %]
140
141         [% IF ( BIBLIO_RESULT.MARCSUBJCTS ) %]
142         <tr>
143             <th scope="row">Subject(s)</th>
144             <td>[% FOREACH MARCSUBJCT IN BIBLIO_RESULT.MARCSUBJCTS %]
145                    <p> [% FOREACH MARCSUBJECT_SUBFIELDS_LOO IN MARCSUBJCT.MARCSUBJECT_SUBFIELDS_LOOP %]
146                         [% MARCSUBJECT_SUBFIELDS_LOO.separator %][% MARCSUBJECT_SUBFIELDS_LOO.value %][% END %]
147                    </p>
148                 [% END %]</td>
149         </tr>
150         [% END %]
151
152         [% IF ( BIBLIO_RESULT.copyrightdate ) %]
153             <tr><th scope="row">Copyright</th>
154                 <td> [% BIBLIO_RESULT.copyrightdate %]</td>
155             </tr>
156         [% END %]
157
158         [% IF ( BIBLIO_RESULT.MARCNOTES ) %]
159         <tr>
160             <th scope="row">Notes</th>
161             <td>
162             [% FOREACH MARCNOTE IN BIBLIO_RESULT.MARCNOTES %]
163                 <p>
164                 [% IF MARCNOTE.marcnote.match('^https?://\S+$') %]
165                     - <a href="[% MARCNOTE.marcnote %]">[% MARCNOTE.marcnote %]</a>
166                 [% ELSE %]
167                     - [% MARCNOTE.marcnote %]
168                 [% END %]
169             [% END %]
170             </td>
171         </tr>
172         [% END %]
173
174         [% IF ( BIBLIO_RESULT.unititle ) %]
175         <tr>
176             <th scope="row">Unified title</th>
177             <td> [% BIBLIO_RESULT.unititle %]</td>
178         </tr>
179         [% END %]
180         [% IF ( BIBLIO_RESULT.serial ) %]
181         <tr>
182             <th scope="row">Serial</th>
183             <td>[% BIBLIO_RESULT.serial %]</td>
184         </tr>
185         [% END %]
186         [% IF ( BIBLIO_RESULT.dewey ) %]
187         <tr>
188             <th scope="row">Dewey</th>
189             <td>[% BIBLIO_RESULT.dewey %]</td>
190         </tr>
191         [% END %]
192         [% IF ( BIBLIO_RESULT.classification ) %]
193         <tr>
194             <th scope="row">Classification</th>
195             <td> [% BIBLIO_RESULT.classification %]</td>
196         </tr>
197         [% END %]
198         [% IF ( BIBLIO_RESULT.lccn ) %]
199         <tr>
200             <th scope="row">LCCN</th>
201             <td> [% BIBLIO_RESULT.lccn %]</td>
202         </tr>
203         [% END %]
204
205
206         [% IF BIBLIO_RESULT.MARCURLS.size %]
207             <tr>
208                 <th scope="row">URL(s)</th>
209                 <td>
210                    [% FOREACH MARCurl IN BIBLIO_RESULT.MARCURLS %]
211                         [% IF MARCurl.part %]<p>[% MARCurl.part %]</p>[% END %]
212
213                         <a href="[% MARCurl.MARCURL %]" title="[% MARCurl.MARCURL %]">[% MARCurl.linktext %]</a>
214
215                         [% IF MARCurl.notes %][% FOREACH note IN MARCurl.notes %]<p>[% note.note %]</p>[% END %][% END %]
216                     [% END %]
217                 </td>
218             </tr>
219         [% END %]
220
221         <tr>
222             <th scope="row">Location(s)</th>
223             <td>[% IF ( BIBLIO_RESULT.ITEM_RESULTS ) %][% FOREACH ITEM_RESULT IN BIBLIO_RESULT.ITEM_RESULTS %]
224                 <p>
225                     [% ITEM_RESULT.branchname %] [% ITEM_RESULT.location_description %]
226                     [% IF ( ITEM_RESULT.itemcallnumber ) %]
227                         ([% ITEM_RESULT.itemcallnumber %])
228                     [% END %]
229                 </p>
230                 [% END %][% ELSE %]This record has no items.[% END %]</td>
231         </tr>
232     </table>
233     [% END %]
234             </form>
235
236 [% ELSE %]
237 [% UNLESS ( print_basket ) %]
238     <form action="/cgi-bin/koha/basket/basket.pl" method="get" name="bookbag_form" id="bookbag_form">
239     [% PROCESS controls %]
240 [% END %]
241
242     <table id="itemst">
243         <thead><tr>
244         [% UNLESS ( print_basket ) %]<th class="NoSort">&nbsp;</th>[% END %]
245         <th class="anti-the">Title</th>
246         <th>Item type</th>
247         <th><a id="items-popover" href="#" data-trigger="hover" data-toggle="popover" data-placement="top" title="Item sorting" data-content="Items are sorted by the highest or lowest callnumber in a group of items respectively.">Items</a></th>
248         </tr></thead>
249
250         [% FOREACH BIBLIO_RESULT IN BIBLIO_RESULTS %]
251                 <tr>
252             [% UNLESS ( print_basket ) %]<td>
253                         <input type="checkbox" class="select_record" value="[% BIBLIO_RESULT.biblionumber %]" name="bib[% BIBLIO_RESULT.biblionumber %]" id="bib[% BIBLIO_RESULT.biblionumber %]" />
254
255                 </td> [% END %]
256             <td><a href="[% BIBLIO_RESULT.dest %]?biblionumber=[% BIBLIO_RESULT.biblionumber %]" class="open_title">
257                         [% BIBLIO_RESULT.title |html %] [% FOREACH subtitl IN BIBLIO_RESULT.subtitle %] [% subtitl.subfield | html %][% END %]
258                     </a>
259                         [% BIBLIO_RESULT.author %]
260                         <p>[% IF ( BIBLIO_RESULT.publishercode ) %]- [% BIBLIO_RESULT.publishercode %]
261                         [% IF ( BIBLIO_RESULT.place ) %] [% BIBLIO_RESULT.place %][% END %][% END %]
262                         [% IF ( BIBLIO_RESULT.pages ) %] - [% BIBLIO_RESULT.pages %][% IF ( BIBLIO_RESULT.item('size') ) %] [% BIBLIO_RESULT.item('size') %]
263                         [% END %]
264                         [% END %]</p>
265                         [% IF ( BIBLIO_RESULT.notes ) %]
266                         <p>[% BIBLIO_RESULT.notes %]</p>
267                         [% END %]
268                                                     <!-- COinS / Openurl -->
269     <span class="Z3988" title="ctx_ver=Z39.88-2004&amp;rft_val_fmt=info%3Aofi%2Ffmt%3Akev%3Amtx%3Abook&amp;rft.au=[% BIBLIO_RESULT.author %]&amp;rft.btitle=[% BIBLIO_RESULT.title |url %]&amp;rft.date=[% BIBLIO_RESULT.publicationyear %]&amp;rft.tpages=[% BIBLIO_RESULT.item('size') %]&amp;rft.isbn=[% BIBLIO_RESULT.isbn |url %]&amp;rft.aucorp=&amp;rft.place=[% BIBLIO_RESULT.place %]&amp;rft.pub=[% BIBLIO_RESULT.publisher |url %]&amp;rft.edition=[% BIBLIO_RESULT.edition %]&amp;rft.series=[% BIBLIO_RESULT.series %]&amp;rft.genre="></span>
270
271                                                 </td>
272             <td>[% BIBLIO_RESULT.description %]</td>
273             <td class="callnumbers">
274                 [% IF ( BIBLIO_RESULT.ITEM_RESULTS ) %]
275                     [% FOREACH ITEM_RESULT IN BIBLIO_RESULT.ITEM_RESULTS %]
276                         <div><span class="nowrap"><strong><span class="callnumber">[% ITEM_RESULT.itemcallnumber %]</span></strong> [% ITEM_RESULT.branchname %] <span class="shelvingloc inline">[% ITEM_RESULT.location_description %]</span></span></div>
277                     [% END %]
278                 [% ELSE %]
279                     This record has no items.
280                 [% END %]
281             </td>
282             </tr>
283         [% END %]
284     </table></form>
285 [% END %]
286
287 <form name="myform" action="basket/basket.pl" method="get">
288     <input type="hidden" name="records" id="records" />
289 </form>
290
291             </div>
292         </div>
293     </div>
294 </div>
295             [% INCLUDE js_includes.inc %]
296             [% UNLESS ( print_basket ) %]
297                 [% INCLUDE 'datatables.inc' %]
298                 <script type="text/javascript" src="[% interface %]/[% theme %]/js/cart_[% KOHA_VERSION %].js"></script>
299                 <script type="text/javascript" src="[% interface %]/lib/jquery/plugins/jquery.checkboxes.min_[% KOHA_VERSION %].js"></script>
300             [% END %]
301     </body>
302 </html>