Bug 22015: Move DataTables CSS to global include
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / acqui / ordered.tt
1 [% USE raw %]
2 [% USE Asset %]
3 [% USE KohaDates %]
4 [% USE ItemTypes %]
5 [% USE Price %]
6 [% SET footerjs = 1 %]
7 [% INCLUDE 'doc-head-open.inc' %]
8 <title>Koha &rsaquo; Acquisitions &rsaquo; Ordered</title>
9 [% INCLUDE 'doc-head-close.inc' %]
10 </head>
11
12 <body id="acq_ordered" class="acq">
13 [% INCLUDE 'header.inc' %]
14 [% INCLUDE 'acquisitions-search.inc' %]
15
16 <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; Ordered - [% fund_code | html %]</div>
17
18 <div class="main container-fluid">
19     <div class="row">
20         <div class="col-sm-10 col-sm-push-2">
21             <main>
22
23 <h1>Fund: [% fund_code | html %]</h1>
24 <h2>Ordered</h2>
25
26 <table id="spent">
27     <thead>
28     <tr>
29     <th class="anti-the"> Title </th>
30     <th> Order </th>
31     <th> Vendor </th>
32     <th> Item type </th>
33     <th> Left on order </th>
34     <th> Estimated cost per unit </th>
35     <th class="title-string"> Date ordered </th>
36     <th> Subtotal </th>
37     </tr>
38     </thead>
39     <tbody>
40 [% FOREACH order IN ordered %]
41     <tr>
42     <td class="cell">
43             <a href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=[% order.biblionumber | uri %]">
44         [% order.title | html %]
45             </a>
46     </td>
47     <td class="cell">
48         [% IF ( CAN_user_acquisition_order_manage ) %]
49             <a href="/cgi-bin/koha/acqui/neworderempty.pl?ordernumber=[% order.ordernumber | uri %]&amp;booksellerid=[% order.booksellerid | uri %]&amp;basketno=[% order.basketno | uri %]">[% order.ordernumber | html %]</a>
50         [% ELSE %]
51             [% order.ordernumber | html %]
52         [% END %]
53     </td>
54     <td class="cell">
55         <a href="/cgi-bin/koha/acqui/supplier.pl?booksellerid=[% order.booksellerid | uri %]">[% order.vendorname | html %]</a>
56     </td>
57     <td class="cell">
58         [% ItemTypes.GetDescription( order.itype ) | html %]
59     </td>
60     <td class="cell">
61         [% order.left | html %]
62     </td>
63     <td class="data cell">
64         [% order.ecost_tax_included | $Price %]
65     </td>
66     <td class="cell">
67         <span title="[% order.entrydate | html %]">[% order.entrydate | $KohaDates %]</span>
68     </td>
69     <td class="data cell">
70         [% order.subtotal | $Price %]
71     </td>
72     </tr>
73 [% END %]
74     </tbody>
75     <tfoot>
76     [% IF ( adjustments && adjustments.count > 0 ) %]
77             [% FOREACH adjustment IN adjustments %]
78                 <tr>
79                     <td></td>
80                     <td colspan="6">Adjustment cost for invoice [% adjustment.invoiceid | html %]</td>
81                     <td class="data total">[% adjustment.adjustment | $Price %]</td>
82                 </tr>
83             [% END %]
84
85     [% END %]
86     <tr>
87         <td> Total </td>
88         <td> </td>
89         <td> </td>
90         <td> </td>
91         <td> </td>
92         <td> </td>
93         <td> </td>
94         <td class="data">
95             [% total | $Price %]
96         </td>
97     </tr>
98     </tfoot>
99
100 </table>
101
102 </main>
103 </div> <!-- /.col-sm-10.col-sm-push-2 -->
104
105 <div class="col-sm-2 col-sm-pull-10">
106     <aside>
107         [% INCLUDE 'acquisitions-menu.inc' %]
108     </aside>
109 </div> <!-- /.col-sm-2.col-sm-pull-10 -->
110 </div> <!-- /.row -->
111
112 [% MACRO jsinclude BLOCK %]
113     [% Asset.js("js/acquisitions-menu.js") | $raw %]
114     [% INCLUDE 'datatables.inc' %]
115     <script>
116         $(document).ready(function() {
117             $("#spent").dataTable($.extend(true, {}, dataTablesDefaults, {
118                 "aoColumnDefs": [
119                     { "sType": "anti-the", "aTargets" : [ "anti-the" ] },
120                     { "sType": "title-string", "aTargets" : [ "title-string" ] }
121                 ],
122                 "sPaginationType": "four_button"
123             }));
124         });
125     </script>
126 [% END %]
127
128 [% INCLUDE 'intranet-bottom.inc' %]