Bug 5349: add ability to transfer order lines from one basket to another
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / acqui / basket.tt
1 [% USE KohaDates %]
2 [% INCLUDE 'doc-head-open.inc' %]
3 <title>Koha &rsaquo; Acquisitions &rsaquo; [% UNLESS ( basketno ) %]New [% END %][% IF ( delete_confirm ) %]Delete [% END %]Basket [% basketname|html %] ([% basketno %]) for [% name|html %]</title>
4 <link rel="stylesheet" type="text/css" href="[% themelang %]/css/datatables.css" />
5 [% INCLUDE 'doc-head-close.inc' %]
6 [% INCLUDE 'datatables.inc' %]
7 <script type="text/javascript">
8 //<![CDATA[
9     function updateColumnsVisibility(visible) {
10         if ( visible ) {
11             $("table .gste, .gsti").show();
12         } else {
13             [% IF ( listincgst ) %]
14                 $("table .gste").hide();
15             [% ELSE %]
16                 $("table .gsti").hide();
17             [% END %]
18         }
19     }
20
21     $(document).ready(function() {
22         $("#show_all_details").click(function(){
23             updateColumnsVisibility($(this+":checked").val());
24         });
25
26         $("#show_all_details").attr('checked', false);
27         updateColumnsVisibility(false);
28         [% UNLESS ( closedate ) %]
29             $('#addtoBasket').on('show', function () {
30                $(this).find(".modal-body").html($(".acqui_basket_add")[0].outerHTML);
31             });
32         [% END %]
33     });
34 //]]>
35 </script>
36
37 [% UNLESS ( closedate ) %]
38 <script type="text/javascript">
39 //<![CDATA[
40             function confirm_close() {
41                 var is_confirmed = confirm(_("Are you sure you want to close this basket?"));
42                 if (is_confirmed) {
43                     window.location = "[% script_name %]?op=close&basketno=[% basketno %]";
44                 }
45             }
46             function confirm_deletion() {
47                 var is_confirmed = confirm(_("Are you sure you want to delete this basket?"));
48                 if (is_confirmed) {
49                     window.location = "[% script_name %]?op=delete_confirm&basketno=[% basketno %]&booksellerid=[% booksellerid %]";
50                 }
51             }
52             function confirm_delete_item(ordernumber, biblionumber) {
53                 var is_confirmed = confirm(_("Are you sure you want to delete this order ?"));
54                 if (is_confirmed) {
55                     window.location = "addorder.pl?ordernumber="+ordernumber+"&basketno=[% basketno %]&quantity=0&biblionumber="+biblionumber;
56                 }
57             }
58             
59             function confirm_delete_biblio(ordernumber, biblionumber) {
60                 var is_confirmed = confirm(_("Are you sure you want to delete this catalog record and order ?"));
61                 if (is_confirmed) {
62                     window.location = "addorder.pl?ordernumber="+ordernumber+"&basketno=[% basketno %]&quantity=0&biblionumber="+biblionumber+"&delbiblio=1";
63                     }
64             }
65
66 //]]>
67 </script>
68 [% ELSE %]
69 <script type="text/javascript">
70 //<![CDATA[
71     $(document).ready(function(){
72         $("#basketgroupid").change(function(){
73             if($(this).val() == "new"){
74                 location.href="/cgi-bin/koha/acqui/basketgroup.pl?op=add&booksellerid=[% booksellerid %]";
75             }
76         });
77     });
78 //]]>
79 </script>
80 [% UNLESS ( grouped ) %]
81 <script type="text/javascript">
82 //<![CDATA[
83             function confirm_reopen() {
84                 var skip = [% IF ( skip_confirm_reopen ) %] 1 [% ELSE %] 0 [% END %];
85                 var is_confirmed = skip || confirm(_("Are you sure you want to reopen this basket?"));
86                 if (is_confirmed) {
87                     window.location = "[% script_name %]?op=reopen&basketno=[% basketno %]";
88                 }
89             }
90 //]]>
91 </script>
92 [% END %]
93 [% END %]
94 <script type="text/javascript">
95 //<![CDATA[
96     $(document).ready(function() {
97         var orderst = $("#orders").dataTable($.extend(true, {}, dataTablesDefaults, {
98             "sPaginationType": "four_button",
99             [% IF ( active ) %]
100               [% UNLESS ( closedate ) %]
101                 "aoColumnDefs": [
102                     { "aTargets": [ -1, -2 ], "bSortable": false, "bSearchable": false },
103                 ],
104               [% END %]
105             [% END %]
106         } ) );
107         var cancelledorderst = $("#cancelledorderst").dataTable($.extend(true, {}, dataTablesDefaults, {
108             "sPaginationType": "four_button"
109         } ) );
110         $("#delbasketbutton").on("click",function(e){
111             e.preventDefault();
112             confirm_deletion();
113         });
114         $("#reopenbutton").on("click",function(e){
115             e.preventDefault();
116             confirm_reopen();
117         });
118     });
119 //]]>
120 </script>
121
122 <style type="text/css">
123 .sortmsg {font-size: 80%;}
124 </style>
125 </head>
126 <body id="acq_basket" class="acq">
127 [% INCLUDE 'header.inc' %]
128 [% INCLUDE 'acquisitions-search.inc' %]
129
130
131 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/acqui/acqui-home.pl">Acquisitions</a> &rsaquo; <a href="/cgi-bin/koha/acqui/supplier.pl?booksellerid=[% booksellerid %]">[% name|html %]</a> &rsaquo; [% UNLESS ( basketno ) %]New [% END %][% IF ( delete_confirm ) %]Delete [% END %]Basket [% basketname|html %] ([% basketno %]) for [% name|html %]</div>
132
133 <div id="doc3" class="yui-t2">
134
135 <div id="bd">
136     <div id="yui-main">
137     <div class="yui-b">
138         [% UNLESS ( confirm_close ) %]
139         [% UNLESS ( selectbasketg ) %]
140             [% UNLESS ( closedate ) %]
141                 <div id="toolbar" class="btn-toolbar">
142                     <div class="btn-group"><a href="#addtoBasket" role="button" class="btn btn-small" data-toggle="modal"><i class="icon-plus"></i> Add to basket</a></div>
143                     <div class="btn-group"><a href="basketheader.pl?booksellerid=[% booksellerid %]&amp;basketno=[% basketno %]&amp;op=add_form" class="btn btn-small" id="basketheadbutton"><i class="icon-pencil"></i> Edit basket</a></div>
144                     <div class="btn-group"><a href="#" class="btn btn-small" id="delbasketbutton"><i class="icon-remove"></i> Delete this basket</a></div>
145                     [% IF ( unclosable ) %]
146                     [% ELSIF ( uncertainprices ) %]
147                         <div class="btn-group"><a href="/cgi-bin/koha/acqui/uncertainprice.pl?booksellerid=[% booksellerid %]&amp;owner=1" class="btn btn-small" id="uncertpricesbutton">Uncertain prices</a></div>
148                     [% ELSE %]
149                         <div class="btn-group">
150                             <a href="[% script_name %]?op=close&amp;basketno=[% basketno %]&amp;booksellerid=[% booksellerid %]" class="btn btn-small" id="closebutton"><i class="icon-remove-sign"></i> Close this basket</a>
151                         </div>
152                     [% END %]
153                         <div class="btn-group"><a href="[% script_name %]?op=export&amp;basketno=[% basketno %]&amp;booksellerid=[% booksellerid %]" class="btn btn-small" id="exportbutton"><i class="icon-download"></i> Export this basket as CSV</a></div>
154
155                 </div>
156             [% ELSE %]
157                 [% UNLESS ( grouped ) %]
158                 <div id="toolbar" class="btn-toolbar">
159                     <div class="btn-group"><a href="#" class="btn btn-small" id="reopenbutton"><i class="icon-refresh"></i> Reopen this basket</a></div>
160                     <div class="btn-group"><a href="[% script_name %]?op=export&amp;basketno=[% basketno %]&amp;booksellerid=[% booksellerid %]" class="btn btn-small" id="exportbutton"><i class="icon-download"></i> Export this basket as CSV</a></div>
161                 </div>
162                 [% END %]
163             [% END %]
164             [% END %]
165
166     [% IF ( NO_BOOKSELLER ) %]
167     <h2>Vendor not found</h2>
168     [% ELSE %]
169         [% IF ( delete_confirmed ) %]
170             <h3>Basket deleted</h3>
171             <META HTTP-EQUIV=Refresh CONTENT="0; url=booksellers.pl">
172         [% ELSE %]
173         <h1>[% UNLESS ( basketno ) %]New [% END %][% IF ( delete_confirm ) %]Delete [% END %]Basket [% basketname|html %] ([% basketno %]) for <a href="supplier.pl?booksellerid=[% booksellerid %]">[% name|html %]</a></h1>
174         [% IF ( delete_confirm ) %]
175             <h2>
176             <span class="yui-button yui-link-button">
177             <em class="first-child">
178                 <a href="[% script_name %]?op=delete_confirm&amp;basketno=[% basketno %]&amp;booksellerid=[% booksellerid %]" class="yui-link-button">Yes, delete this basket!</a>
179             </em>
180             </span>
181             <span class="yui-button yui-link-button">
182             <em class="first-child">
183                 <a href="[% script_name %]?basketno=[% basketno %]" class="yui-link-button">Cancel</a>
184             </em>
185             </span>
186             </h2>
187         [% END %]
188         [% IF ( basketno ) %]
189             <div id="acqui_basket_summary" class="yui-g">
190                 <div class="rows">
191                 <div class="yui-u first">
192                 <ol>
193                 [% IF ( basketnote ) %]<li><span class="label">Internal note:</span> [% basketnote %]</li>[% END %]
194                 [% IF ( basketbooksellernote ) %]<li><span class="label">Vendor note:</span> [% basketbooksellernote %]</li>[% END %]
195                 [% IF ( basketcontractno ) %]
196                     <li><span class="label">Contract name:</span> <a href="../admin/aqcontract.pl?op=add_form&amp;contractnumber=[% basketcontractno %]&amp;booksellerid=[% booksellerid %]">[% basketcontractname %]</a></li>
197                 [% END %]
198                 [% IF ( deliveryplace ) %]<li><span class="label">Delivery place:</span> [% deliveryplace %]</li>[% END %]
199                 [% IF ( billingplace ) %]<li><span class="label">Billing place:</span> [% billingplace %]</li>[% END %]
200                 [% IF ( authorisedbyname ) %]<li><span class="label">Managed by:</span>  [% authorisedbyname %]</li>[% END %]
201                 [% IF ( creationdate ) %]<li><span class="label">Opened on:</span>  [% creationdate | $KohaDates %]</li>[% END %]
202                 [% IF ( closedate ) %]<li><span class="label">Closed on:</span> [% closedate | $KohaDates %]</li>[% END %]
203                 [% IF ( estimateddeliverydate ) %]<li><span class="label">Estimated delivery date:</span> [% estimateddeliverydate | $KohaDates  %]</li>[% END %]
204
205                 </ol>
206                 </div>
207                 [% IF ( closedate ) %]
208                 <div class="yui-u">
209                     [% IF ( CAN_user_acquisition_group_manage ) %]
210                     <form action="/cgi-bin/koha/acqui/basketgroup.pl" method="post">
211                     [% END %]
212                         <ol>
213                         <li>
214                           <span class="label">Basket group:</span>
215                           [% IF basketgroup.closed %]
216                             [% basketgroup.name %] (closed)
217                           [% ELSIF ( ! CAN_user_acquisition_group_manage ) %]
218                             [%- IF basketgroup.name -%]
219                                 [% basketgroup.name %]
220                             [%- ELSE -%]
221                                 No group
222                             [%- END -%]
223                           [% ELSE %]
224                             <select id="basketgroupid" name="basketgroupid">
225                               <option value="new">Add new group</option>
226                               [% FOREACH bg IN basketgroups %]
227                                 [% IF ( bg.default ) %]
228                                     <option value="[% bg.id %]" selected="selected">[% bg.name %]</option>
229                                 [% ELSE %]
230                                   [% UNLESS bg.closed %]
231                                     <option value="[% bg.id %]">[% bg.name %]</option>
232                                   [% ELSE %]
233                                     <option value="[% bg.id %]" disabled="disabled">[% bg.name %] (closed)</option>
234                                   [% END %]
235                                 [% END %]
236                               [% END %]
237                             </select>
238                             <input type="hidden" id="basketno" value="[% basketno %]" name="basketno" />
239                             <input type="hidden" value="mod_basket" name="op" />
240                             <input type="hidden" name="booksellerid" value="[% booksellerid %]" />
241                             <input type="submit" value="Change basket group" />
242                           [% END %]
243                         </li>
244                     [% IF ( basketgroup.deliveryplacename ) %]<li><span class="label">Basket group delivery placename:</span> [% basketgroup.deliveryplacename %]</li>[% END %]
245                     [% IF ( basketgroup.billingplacename ) %]<li><span class="label">Basket group billing place:</span> [% basketgroup.billingplacename %]</li>[% END %]
246                         </ol>
247                     [% IF ( CAN_user_acquisition_group_manage ) %]
248                     </form>
249                     [% END %]
250                 </div>
251                 [% END %]
252             </div>
253             </div>
254         [% END %]
255
256         [% UNLESS ( delete_confirm ) %]
257         <div id="acqui_basket_content" class="yui-g">
258         [% IF ( books_loop ) %]
259         <h2>Orders</h2>
260         <label for="show_all_details">
261             <input type="checkbox" style="vertical-align: middle;" id="show_all_details" />
262             Show all details
263         </label>
264             <table id="orders">
265                 <thead>
266                     <tr>
267                         <th>Order</th>
268                         <th class="gste">RRP tax exc.</th>
269                         <th class="gste">ecost tax exc.</th>
270                         <th class="gsti">RRP tax inc.</th>
271                         <th class="gsti">ecost tax inc.</th>
272                         <th>Qty.</th>
273                         <th class="gste">Total tax exc. ([% currency %])</th>
274                         <th class="gsti">Total tax inc. ([% currency %])</th>
275                         <th>GST %</th>
276                         <th>GST</th>
277                         <th>Fund</th>
278                         [% IF ( active ) %]
279                             [% UNLESS ( closedate ) %]
280                                 <th>Modify</th>
281                                 <th>Delete</th>
282                             [% END %]
283                         [% END %]
284                     </tr>
285                 </thead>
286                 <tfoot>
287                 [% FOREACH foot_loo IN book_foot_loop %]
288                     <tr>
289                         <th>Total (GST [% foot_loo.gstgsti %])</th>
290                         <th class="gste">&nbsp;</th>
291                         <th class="gste">&nbsp;</th>
292                         <th class="gsti">&nbsp;</th>
293                         <th class="gsti">&nbsp;</th>
294                         <th>[% foot_loo.quantity %]</th>
295                         <th class="gste">[% foot_loo.totalgste %]</th>
296                         <th class="gsti">[% foot_loo.totalgsti %]</th>
297                         <th>&nbsp;</th>
298                         <th>[% foot_loo.gstvalue %]</th>
299                         <th>&nbsp;</th>
300                         [% IF ( active ) %]
301                             [% UNLESS ( closedate ) %]
302                                 <th>&nbsp;</th>
303                                 <th>&nbsp;</th>
304                             [% END %]
305                         [% END %]
306                     </tr>
307                 [% END %]
308                 <tr>
309                     <th>Total ([% currency %])</th>
310                     <th class="gste">&nbsp;</th>
311                     <th class="gste">&nbsp;</th>
312                     <th class="gsti">&nbsp;</th>
313                     <th class="gsti">&nbsp;</th>
314                     <th>[% total_quantity %]</th>
315                     <th class="gste">[% total_gste %]</th>
316                     <th class="gsti">[% total_gsti %]</th>
317                     <th>&nbsp;</th>
318                     <th>[% total_gstvalue %]</th>
319                     <th>&nbsp;</th>
320                     [% IF ( active ) %]
321                         [% UNLESS ( closedate ) %]
322                             <th>&nbsp;</th>
323                             <th>&nbsp;</th>
324                         [% END %]
325                     [% END %]
326                 </tr>
327                 </tfoot>
328                 <tbody>
329                 [% FOREACH books_loo IN books_loop %]
330                     [% IF ( books_loo.order_received ) %]<tr class="disabled">[% ELSE %][% IF ( books_loo.toggle ) %]<tr class="highlight">[% ELSE %]<tr>[% END %][% END %]
331                         <td>
332                             <p>[% IF ( books_loo.order_received ) %] (rcvd)[% END %]
333                                 <a href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=[% books_loo.biblionumber %]">[% books_loo.title |html %]</a> by [% books_loo.author %]
334                                 <br />
335                                 [% IF ( books_loo.isbn ) %] - [% books_loo.isbn %][% END %]
336                                 [% IF ( books_loo.issn ) %] - [% books_loo.issn %][% END %]
337                                 [% IF ( books_loo.publishercode ) %], [% books_loo.publishercode %][% END %]
338                                 [% IF ( books_loo.publicationyear ) %], [% books_loo.publicationyear %][% END %]
339                                 [% IF ( books_loo.editionstatement ) %], [% books_loo.editionstatement %][% END %]
340                                 [% IF ( books_loo.suggestionid ) %]
341                                     <br/>
342                                     Suggested by: [% books_loo.surnamesuggestedby %][% IF ( books_loo.firstnamesuggestedby ) %], [% books_loo.firstnamesuggestedby %] [% END %]
343                                     (<a href="/cgi-bin/koha/suggestion/suggestion.pl?suggestionid=[% books_loo.suggestionid %]&amp;op=show">suggestion #[% books_loo.suggestionid %]</a>)
344                                 [% END %]
345                             </p>
346                                 [% IF ( books_loo.notes ) %]
347                                     <p class="ordernote"><strong>Note: </strong>[% books_loo.notes|html %] [<a href="/cgi-bin/koha/acqui/modordernotes.pl?ordernumber=[% books_loo.ordernumber %]">Change note</a>]</p>
348                                 [% ELSE %]
349                                     <p>[<a href="/cgi-bin/koha/acqui/modordernotes.pl?ordernumber=[% books_loo.ordernumber %]">Add note</a>]</p>
350                                 [% END %]
351                             <p>[% books_loo.internalnotes %]</p>
352                         </td>
353                         <td class="number gste [% IF books_loo.rrpgste.search('^0') %]error[% END %]">[% books_loo.rrpgste %]</td>
354                         <td class="number gste [% IF books_loo.ecostgste.search('^0') %]error[% END %]">[% books_loo.ecostgste %]</td>
355                         <td class="number gsti [% IF books_loo.rrpgsti.search('^0') %]error[% END %]">[% books_loo.rrpgsti %]</td>
356                         <td class="number gsti [% IF books_loo.ecostgsti.search('^0') %]error[% END %]">[% books_loo.ecostgsti %]</td>
357                         <td class="number [% IF books_loo.quantity.search('^0') %]error[% END %]">[% books_loo.quantity %]</td>
358                         <td class="number gste [% IF books_loo.totalgste.search('^0') %]error[% END %]">[% books_loo.totalgste %]</td>
359                         <td class="number gsti [% IF books_loo.totalgsti.search('^0') %]error[% END %]">[% books_loo.totalgsti %]</td>
360                         <td class="number [% IF books_loo.gstgsti.search('^0') %]error[% END %]">[% books_loo.gstgsti %]</td>
361                         <td class="number [% IF books_loo.gstvalue.search('^0') %]error[% END %]">[% books_loo.gstvalue %]</td>
362                         <td>[% books_loo.budget_name %]</td>
363                         [% IF ( active ) %]
364                             [% UNLESS ( closedate ) %]
365                             <td>
366                                 <a href="neworderempty.pl?ordernumber=[% books_loo.ordernumber %]&amp;booksellerid=[% booksellerid %]&amp;basketno=[% basketno %]">Modify</a>
367                                 [% UNLESS (books_loo.order_received) %]
368                                     <br />
369                                     <a href="/cgi-bin/koha/acqui/transferorder.pl?ordernumber=[% books_loo.ordernumber %]&referrer=[% "/cgi-bin/koha/acqui/basket.pl?basketno=$basketno" | uri %]">Transfer</a>
370                                 [% END %]
371                             </td>
372                             <td>
373                             [% IF ( books_loo.left_holds_on_order ) %]
374                             <span class="button" title="Can't delete order, ([% books_loo.holds_on_order %]) holds are linked with this order cancel holds first">Can't delete order</span><br>
375                             [% ELSE %]
376                             <a href="javascript:confirm_delete_item([% books_loo.ordernumber %],[% books_loo.biblionumber %])" class="button">Delete order</a><br>
377                             [% END %]
378                             [% IF ( books_loo.can_del_bib ) %]
379                             <a href="javascript:confirm_delete_biblio([% books_loo.ordernumber %],[% books_loo.biblionumber %])" class="button">Delete order and catalog record</a><br>
380                             [% ELSE %]
381                             <span class="button" title="Can't delete catalog record, see constraints below">Can't delete order and catalog record</span><br>
382                             [% END %]
383                             [% IF ( books_loo.left_item ) %]
384                             <b title="Can't delete catalog record, because of [% books_loo.items %] existing hold(s)" >[% books_loo.items %] item(s) left</b><br>
385                             [% END %]
386                             [% IF ( books_loo.left_biblio ) %]
387                             <b title="Can't delete catalog record, delete other orders linked to it first">[% books_loo.biblios %] order(s) left</b><br>
388                             [% END %]
389                             [% IF ( books_loo.left_subscription ) %]
390                             <b title="Can't delete catalog record, delete subscriptions first">[% books_loo.subscriptions %] subscription(s) left</b><br>
391                             [% END %]
392                             [% IF ( books_loo.left_holds ) %]
393                             <b title="Can't delete catalog record or order, cancel holds first">[% books_loo.holds %] hold(s) left</b>
394                             [% END %]
395                             </td>
396                             [% END %]
397                         [% END %]
398                     </tr>
399                 [% END %]
400                 </tbody>
401             </table>
402         [% END %]
403         [% IF ( listincgst ) %]<small class="highlight">** Vendor's listings already include tax.</small>
404         [% END %]
405         </div>
406         [% IF (cancelledorders_loop) %]
407           <div id="cancelledorders">
408             <h2>Cancelled orders</h2>
409             <table id="cancelledorderst">
410               <thead>
411                 <tr>
412                   <th>Order</th>
413                   <th class="gste">RRP tax exc.</th>
414                   <th class="gste">ecost tax exc.</th>
415                   <th class="gsti">RRP tax inc.</th>
416                   <th class="gsti">ecost tax inc.</th>
417                   <th>Qty.</th>
418                   <th class="gste">Total tax exc. ([% currency %])</th>
419                   <th class="gsti">Total tax inc. ([% currency %])</th>
420                   <th>GST %</th>
421                   <th>GST</th>
422                   <th>Fund</th>
423                 </tr>
424               </thead>
425               <tbody>
426                 [% FOREACH order IN cancelledorders_loop %]
427                   <tr style="color:grey">
428                     <td>
429                       <p>
430                         [% IF ( order.order_received ) %] (rcvd)[% END %]
431                         [% IF (order.title) %]
432                           [% order.title |html %] by [% order.author %]<br />
433                         [% ELSE %]
434                           <em>Deleted bibliographic record, can't find title</em><br />
435                         [% END %]
436                         [% IF ( order.notes ) %] [% order.notes %][% END %]
437                         [% IF ( order.isbn ) %] - [% order.isbn %][% END %]
438                         [% IF ( order.issn ) %] - [% order.issn %][% END %]
439                         [% IF ( order.publishercode ) %], [% order.publishercode %][% END %]
440                         [% IF ( order.publicationyear ) %], [% order.publicationyear %][% END %]
441                         [% IF ( books_loo.editionstatement ) %], [% books_loo.editionstatement %][% END %]
442                       </p>
443                       <p>[% order.internalnotes %]</p>
444                     </td>
445                     <td class="number gste">[% order.rrpgste %]</td>
446                     <td class="number gste">[% order.ecostgste %]</td>
447                     <td class="number gsti">[% order.rrpgsti %]</td>
448                     <td class="number gsti">[% order.ecostgsti %]</td>
449                     <td class="number">[% order.quantity %]</td>
450                     <td class="number gste">[% order.totalgste %]</td>
451                     <td class="number gsti">[% order.totalgsti %]</td>
452                     <td class="number">[% order.gstgsti %]</td>
453                     <td class="number">[% order.gstvalue %]</td>
454                     <td>[% order.budget_name %]
455                   </tr>
456                 [% END %]
457               </tbody>
458             </table>
459           </div>
460         [% END %]
461         <br />
462         [% UNLESS ( closedate ) %]
463
464     <!-- Modal -->
465     <div id="addtoBasket" class="modal hide" tabindex="-1" role="dialog" aria-labelledby="addtoBasketLabel" aria-hidden="true">
466         <div class="modal-body"></div>
467         <div class="modal-footer">
468             <a href="#" class="cancel" data-dismiss="modal" aria-hidden="true">Cancel</a>
469         </div>
470     </div>
471
472         [% INCLUDE 'acquisitions-add-to-basket.inc' %]
473         [% END %]
474         [% END %]
475 [% END %]
476 [% END %]    [% ELSE %] <!-- if we want just to select a basketgroup for a closed basket -->
477     [% END %]
478 [% IF ( confirm_close ) %]
479         <div id="closebasket_needsconfirmation" class="dialog alert">
480
481         <form action="/cgi-bin/koha/acqui/basket.pl" class="confirm">
482             <h1>Are you sure you want to close basket [% basketname|html %]?</h1>
483             [% IF ( CAN_user_acquisition_group_manage ) %]
484             <p>
485             <label for="createbasketgroup">Attach this basket to a new basket group with the same name</label>
486             <input type="checkbox" id="createbasketgroup" name="createbasketgroup"/>
487             </p>
488             [% END %]
489             <input type="hidden" id="basketno" value="[% basketno %]" name="basketno" />
490             <input type="hidden" value="close" name="op" />
491             <input type="hidden" name="booksellerid" value="[% booksellerid %]" />
492             <input type="hidden" name="confirm" value="1" />
493             <input type="hidden" name="basketgroupname" value="[% basketgroupname %]" />
494             <input type="submit" class="approve" value="Yes, close (Y)" accesskey="y" />
495             <input type="submit" class="deny" value="No, don't close (N)" accesskey="n" onclick="javascript:window.location='/cgi-bin/koha/acqui/basket.pl?basketno=[% basketno %]';return false;" />
496         </form>
497         </div>
498     [% END %]
499 </div>
500 </div>
501 <div class="yui-b">
502 [% INCLUDE 'acquisitions-menu.inc' %]
503 </div>
504 </div>
505 [% INCLUDE 'intranet-bottom.inc' %]