Bug 10649 - Upgrade DataTables and move scripts out of theme directory
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / acqui / invoice.tt
1 [% USE KohaDates %]
2
3 [% INCLUDE 'doc-head-open.inc' %]
4 <title>Koha &rsaquo; Acquisitions &rsaquo; Invoice</title>
5 <link rel="stylesheet" type="text/css" href="[% themelang %]/css/datatables.css" />
6 [% INCLUDE 'doc-head-close.inc' %]
7 [% INCLUDE 'calendar.inc' %]
8 [% INCLUDE 'datatables.inc' %]
9 <script type="text/javascript">
10 //<![CDATA[
11     $(document).ready(function() {
12         $("#orderst").dataTable($.extend(true, {}, dataTablesDefaults, {
13             bInfo: false,
14             bPaginate: false,
15             bFilter: false,
16             sDom: "t"
17         }));
18     });
19 //]]>
20 </script>
21 </head>
22
23 <body>
24 [% INCLUDE 'header.inc' %]
25 [% INCLUDE 'acquisitions-search.inc' %]
26
27 <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/invoices.pl">Invoices</a> &rsaquo; <a href="/cgi-bin/koha/acqui/invoice.pl?invoiceid=[% invoiceid %]">[% invoicenumber %]</a></div>
28
29 <div id="doc3" class="yui-t2">
30
31 <div id="bd">
32   <div id="yui-main">
33     <div class="yui-b">
34       [% IF ( modified ) %]
35         <div class="dialog message">
36           <p>Invoice has been modified</p>
37         </div>
38       [% END %]
39       <h1>Invoice: [% invoicenumber %]</h1>
40
41       <p>Vendor: <a href="/cgi-bin/koha/acqui/supplier.pl?booksellerid=[% booksellerid %]">[% suppliername %]</a></p>
42         <form action="/cgi-bin/koha/acqui/invoice.pl" method="post">
43         <fieldset class="rows">
44             <ol>
45             <li><label for="shipmentdate">Shipment date:</label>
46                     <input type="text" size="10" id="shipmentdate" name="shipmentdate" value="[% shipmentdate | $KohaDates %]" readonly="readonly" class="datepicker" /></li>
47
48             <li><label for="billingdate">Billing date:</label>
49                     <input type="text" size="10" id="billingdate" name="billingdate" value="[% billingdate | $KohaDates %]" readonly="readonly" class="datepicker" /></li>
50
51             <li><label for="shipmentcost">Shipment cost:</label>
52                     <input type="text" size="10" id="shipmentcost" name="shipmentcost" value="[% shipmentcost %]" /></li>
53             <li><label for="shipment_budget_id">Fund:</label>
54                     <select id="shipment_budget_id" name="shipment_budget_id">
55                         <option value="">No fund</option>
56                       [% FOREACH budget IN budgets_loop %]
57                         [% IF ( budget.selected ) %]
58                           <option selected="selected" value="[% budget.budget_id %]">
59                         [% ELSE %]
60                           <option value="[% budget.budget_id %]">
61                         [% END %]
62                           [% budget.budget_name %]
63                         </option>
64                       [% END %]
65                     </select></li>
66
67             [% IF ( invoiceclosedate ) %]
68             <li><span class="label">Status:</span>
69                 Closed on [% invoiceclosedate | $KohaDates %].</li>
70
71             <li><label for="reopen">Reopen: </label> <input type="checkbox" name="reopen" id="reopen" /></li>
72             [% ELSE %]
73             <li><span class="label">Status:</span>
74                 Open.</li>
75
76             <li><label for="close">Close: </label> <input type="checkbox" name="close" id="close" />
77                 </li>
78             [% END %]
79             </ol>
80           <input type="hidden" name="op" value="mod" />
81           <input type="hidden" name="invoiceid" value="[% invoiceid %]" />
82         </fieldset>
83         <fieldset class="action">
84             <input type="submit" value="Save" />
85             [% UNLESS orders_loop.size %]
86             <a href="invoice.pl?op=delete&invoiceid=[% invoiceid %]">Delete</a>
87             [% END %]
88         </fieldset>
89       </form>
90       <p>
91           <a href="/cgi-bin/koha/acqui/parcel.pl?invoiceid=[% invoiceid %]">Go to receipt page</a>
92       </p>
93       <h2>Invoice details</h2>
94       [% IF orders_loop.size %]
95           <table id="orderst">
96             <thead>
97               <tr>
98                 <th>Summary</th>
99                 <th>Publisher</th>
100                 <th>Library</th>
101                 <th>RRP</th>
102                 <th>Est.</th>
103                 <th>Qty.</th>
104                 <th>Total</th>
105                 <th>Fund</th>
106               </tr>
107             </thead>
108             <tbody>
109               [% FOREACH order IN orders_loop %]
110                 <tr>
111                   <td><p><a href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=[% order.biblionumber %]">[% order.title %]</a>
112                     [% IF ( order.author ) %]
113                       <br /><em>by</em> [% order.author %]
114                     [% END %]
115                   </p></td>
116                   <td>
117                     [% IF ( order.publishercode ) %]
118                       <p>[% order.publishercode %]
119                         [% IF ( order.publicationyear ) %]
120                           - [% order.publicationyear %]
121                         [% END %]
122                       </p>
123                     [% END %]
124                   </td>
125                   <td><p>[% order.branchcode %]</p></td>
126                   <td>[% order.rrp %]</td>
127                   <td>[% order.ecost %]</td>
128                   <td class="number">[% order.quantity %]</td>
129                   <td>[% order.total %]</td>
130                   <td>[% order.budget_name %]</td>
131                 </tr>
132               [% END %]
133             </tbody>
134             <tfoot>
135                 <tr>
136                     <th colspan="3">Total tax exc.</th>
137                     <th>[% total_rrp_gste %]</th>
138                     <th>&nbsp;</th>
139                     <th>[% total_quantity %]</th>
140                     <th>[% total_est_gste %]</th>
141                     <th>&nbsp;</th>
142                 </tr>
143                 <tr>
144                     <th colspan='3'>Tax ([% gist %]%)</th>
145                     <th>[% gist_rrp %]</th>
146                     <th>&nbsp;</th>
147                     <th>&nbsp;</th>
148                     <th>[% gist_est %]</th>
149                     <th>&nbsp;</th>
150                 </tr>
151                 <tr>
152                     <th colspan='3'>Total tax inc. ([% currency %])</th>
153                     <th>[% total_rrp_gsti %]</th>
154                     <th>&nbsp;</th>
155                     <th>[% total_quantity %]</th>
156                     <th>[% total_est_gsti %]</th>
157                     <th>&nbsp;</th>
158                 </tr>
159                 <tr>
160                     <th colspan="3">Total + shipment cost ([% currency %])</th>
161                     <th>&nbsp;</th>
162                     <th>&nbsp;</th>
163                     <th>[% total_quantity %]</th>
164                     <th>[% total_gsti_shipment %]</th>
165                     <th>&nbsp;</th>
166                 </tr>
167             </tfoot>
168           </table>
169         [% ELSE %]
170             <div class="dialog message"><p>No orders yet</p></div>
171         [% END %]
172     </div>
173   </div>
174   <div class="yui-b">
175     [% INCLUDE 'acquisitions-menu.inc' %]
176   </div>
177 </div>
178 [% INCLUDE 'intranet-bottom.inc' %]