Lines 27-50
Link Here
|
27 |
|
27 |
|
28 |
[% SET readonly = NOT CAN_user_acquisition_edit_invoices %] |
28 |
[% SET readonly = NOT CAN_user_acquisition_edit_invoices %] |
29 |
|
29 |
|
30 |
|
|
|
31 |
[% WRAPPER 'sub-header.inc' %] |
30 |
[% WRAPPER 'sub-header.inc' %] |
32 |
<nav id="breadcrumbs" aria-label="Breadcrumb" class="breadcrumb"> |
31 |
<nav id="breadcrumbs" aria-label="Breadcrumb" class="breadcrumb"> |
33 |
<ol> |
32 |
<ol> |
34 |
<li> |
33 |
<li> |
35 |
<a href="/cgi-bin/koha/mainpage.pl">Home</a> |
34 |
<a href="/cgi-bin/koha/mainpage.pl">Home</a> |
36 |
</li> |
35 |
</li> |
37 |
<li> |
36 |
<li> |
38 |
<a href="/cgi-bin/koha/acqui/acqui-home.pl">Acquisitions</a> |
37 |
<a href="/cgi-bin/koha/acqui/acqui-home.pl">Acquisitions</a> |
39 |
</li> |
38 |
</li> |
40 |
<li> |
39 |
<li> |
41 |
<a href="/cgi-bin/koha/acqui/invoices.pl">Invoices</a> |
40 |
<a href="/cgi-bin/koha/acqui/invoices.pl">Invoices</a> |
42 |
</li> |
41 |
</li> |
43 |
<li> |
42 |
<li> |
44 |
<a href="#" aria-current="page">[% invoicenumber | html %]</a> |
43 |
<a href="#" aria-current="page">[% invoicenumber | html %]</a> |
45 |
</li> |
44 |
</li> |
46 |
</ol> |
45 |
</ol> |
47 |
</nav> |
46 |
</nav> |
48 |
[% END %] |
47 |
[% END %] |
49 |
|
48 |
|
50 |
<div class="main container-fluid"> |
49 |
<div class="main container-fluid"> |
Lines 52-447
Link Here
|
52 |
<div class="col-sm-10 col-sm-push-2"> |
51 |
<div class="col-sm-10 col-sm-push-2"> |
53 |
<main> |
52 |
<main> |
54 |
|
53 |
|
55 |
<h1>Invoice: [% invoicenumber | html %]</h1> |
54 |
<h1>Invoice: [% invoicenumber | html %]</h1> |
56 |
[% INCLUDE 'blocking_errors.inc' %] |
55 |
[% INCLUDE 'blocking_errors.inc' %] |
57 |
|
56 |
|
58 |
[% IF ( modified ) %] |
57 |
[% IF ( modified ) %] |
59 |
<div class="dialog message"> |
58 |
<div class="dialog message"> |
60 |
<p>Invoice has been modified</p> |
59 |
<p>Invoice has been modified</p> |
61 |
</div> |
60 |
</div> |
62 |
[% END %] |
|
|
63 |
|
64 |
<p>Vendor: <a href="/cgi-bin/koha/acqui/supplier.pl?booksellerid=[% booksellerid | uri %]">[% suppliername | html %]</a></p> |
65 |
<form action="/cgi-bin/koha/acqui/invoice.pl" method="post" class="validated"> |
66 |
<fieldset class="rows"> |
67 |
<ol> |
68 |
<li> |
69 |
[% IF readonly %] |
70 |
<label for="shipmentdate">Invoice number:</label> |
71 |
[% invoicenumber | html %] |
72 |
[% ELSE %] |
73 |
<label for="shipmentdate" class="required">Invoice number:</label> |
74 |
<input type="text" id="invoicenumber" name="invoicenumber" value="[% invoicenumber | html %]" class="required" required="required"/> |
75 |
<span class="required">Required</span> |
76 |
[% END %] |
61 |
[% END %] |
77 |
</li> |
|
|
78 |
|
62 |
|
79 |
<li> |
63 |
<p>Vendor: <a href="/cgi-bin/koha/acqui/supplier.pl?booksellerid=[% booksellerid | uri %]">[% suppliername | html %]</a></p> |
80 |
<label for="shipmentdate">Shipment date:</label> |
|
|
81 |
[% IF readonly %] |
82 |
[% shipmentdate | $KohaDates %] |
83 |
[% ELSE %] |
84 |
<input type="text" size="10" id="shipmentdate" name="shipmentdate" value="[% shipmentdate | html %]" class="flatpickr" /> |
85 |
<div class="hint">[% INCLUDE 'date-format.inc' %]</div> |
86 |
[% END %] |
87 |
</li> |
88 |
|
64 |
|
89 |
<li> |
65 |
<form action="/cgi-bin/koha/acqui/invoice.pl" method="post" class="validated"> |
90 |
<label for="billingdate">Billing date:</label> |
66 |
<fieldset class="rows"> |
91 |
[% IF readonly %] |
67 |
<ol> |
92 |
[% billingdate | $KohaDates %] |
68 |
<li> |
93 |
[% ELSE %] |
69 |
[% IF readonly %] |
94 |
<input type="text" size="10" id="billingdate" name="billingdate" value="[% billingdate | html %]" class="flatpickr" /> |
70 |
<label for="shipmentdate">Invoice number:</label> |
95 |
<div class="hint">[% INCLUDE 'date-format.inc' %]</div> |
71 |
[% invoicenumber | html %] |
96 |
[% END %] |
72 |
[% ELSE %] |
97 |
</li> |
73 |
<label for="shipmentdate" class="required">Invoice number:</label> |
|
|
74 |
<input type="text" id="invoicenumber" name="invoicenumber" value="[% invoicenumber | html %]" class="required" required="required"/> |
75 |
<span class="required">Required</span> |
76 |
[% END %] |
77 |
</li> |
78 |
<li> |
79 |
<label for="shipmentdate">Shipment date:</label> |
80 |
[% IF readonly %] |
81 |
[% shipmentdate | $KohaDates %] |
82 |
[% ELSE %] |
83 |
<input type="text" size="10" id="shipmentdate" name="shipmentdate" value="[% shipmentdate | html %]" class="flatpickr" /> |
84 |
<div class="hint">[% INCLUDE 'date-format.inc' %]</div> |
85 |
[% END %] |
86 |
</li> |
87 |
<li> |
88 |
<label for="billingdate">Billing date:</label> |
89 |
[% IF readonly %] |
90 |
[% billingdate | $KohaDates %] |
91 |
[% ELSE %] |
92 |
<input type="text" size="10" id="billingdate" name="billingdate" value="[% billingdate | html %]" class="flatpickr" /> |
93 |
<div class="hint">[% INCLUDE 'date-format.inc' %]</div> |
94 |
[% END %] |
95 |
</li> |
96 |
<li> |
97 |
<label for="shipmentcost">Shipping cost:</label> |
98 |
[% IF readonly %] |
99 |
[% shipmentcost | $Price %] |
100 |
[% ELSE %] |
101 |
<input type="text" size="10" id="shipmentcost" name="shipmentcost" value="[% shipmentcost | $Price on_editing => 1 %]" /> |
102 |
[% END %] |
103 |
</li> |
104 |
<li> |
105 |
[% PROCESS fund_dropdown form_id => 'shipment_budget_id' form_name => 'shipment_budget_id' selected => shipment_budget_id %] |
106 |
</li> |
98 |
|
107 |
|
99 |
<li> |
108 |
[% IF ( invoiceclosedate ) %] |
100 |
<label for="shipmentcost">Shipping cost:</label> |
109 |
<li> |
101 |
[% IF readonly %] |
110 |
<span class="label">Status:</span> |
102 |
[% shipmentcost | $Price %] |
111 |
Closed on [% invoiceclosedate | $KohaDates %] |
103 |
[% ELSE %] |
112 |
</li> |
104 |
<input type="text" size="10" id="shipmentcost" name="shipmentcost" value="[% shipmentcost | $Price on_editing => 1 %]" /> |
113 |
[% IF CAN_user_acquisition_reopen_closed_invoices AND NOT readonly %] |
105 |
[% END %] |
114 |
<li> |
106 |
</li> |
115 |
<label for="reopen">Reopen: </label> |
107 |
<li> |
116 |
<input type="checkbox" name="reopen" id="reopen" /> |
108 |
[% PROCESS fund_dropdown form_id => 'shipment_budget_id' form_name => 'shipment_budget_id' selected => shipment_budget_id %] |
117 |
</li> |
109 |
</li> |
118 |
[% END %] |
|
|
119 |
[% ELSE %] |
120 |
<li> |
121 |
<span class="label">Status:</span> |
122 |
Open |
123 |
</li> |
124 |
[% UNLESS ( readonly ) %] |
125 |
<li> |
126 |
<label for="close">Close: </label> |
127 |
<input type="checkbox" name="close" id="close" /> |
128 |
</li> |
129 |
[% END %] |
130 |
[% END %] |
131 |
</ol> |
110 |
|
132 |
|
111 |
[% IF ( invoiceclosedate ) %] |
133 |
<fieldset class="rows"> |
112 |
<li><span class="label">Status:</span> |
134 |
[% IF available_additional_fields.count %] |
113 |
Closed on [% invoiceclosedate | $KohaDates %]</li> |
135 |
[% INCLUDE 'additional-fields-entry.inc' available=available_additional_fields values=additional_field_values %] |
|
|
136 |
[% END %] |
137 |
</fieldset> |
114 |
|
138 |
|
115 |
[% IF CAN_user_acquisition_reopen_closed_invoices AND NOT readonly %] |
139 |
[% UNLESS readonly %] |
116 |
<li> |
140 |
<input type="hidden" name="op" value="mod" /> |
117 |
<label for="reopen">Reopen: </label> |
141 |
<input type="hidden" name="invoiceid" value="[% invoiceid | html %]" /> |
118 |
<input type="checkbox" name="reopen" id="reopen" /> |
142 |
<fieldset class="action"> |
119 |
</li> |
143 |
<input type="submit" class="btn btn-primary" value="Save" /> |
120 |
[% END %] |
144 |
[% IF CAN_user_acquisition_delete_invoices AND NOT orders_loop.size %] |
121 |
[% ELSE %] |
145 |
<a href="invoice.pl?op=delete&invoiceid=[% invoiceid | uri %]" id="delete">Delete</a> |
122 |
<li> |
146 |
[% END %] |
123 |
<span class="label">Status:</span> |
147 |
</fieldset> |
124 |
Open |
148 |
[% END %] |
125 |
</li> |
149 |
</fieldset> |
126 |
[% UNLESS ( readonly ) %] |
150 |
</form> |
127 |
<li> |
|
|
128 |
<label for="close">Close: </label> |
129 |
<input type="checkbox" name="close" id="close" /> |
130 |
</li> |
131 |
[% END %] |
132 |
[% END %] |
133 |
</ol> |
134 |
<fieldset class="rows"> |
135 |
[% IF available_additional_fields.count %] |
136 |
[% INCLUDE 'additional-fields-entry.inc' available=available_additional_fields values=additional_field_values %] |
137 |
[% END %] |
138 |
</fieldset> |
139 |
[% UNLESS readonly %] |
140 |
<input type="hidden" name="op" value="mod" /> |
141 |
<input type="hidden" name="invoiceid" value="[% invoiceid | html %]" /> |
142 |
<fieldset class="action"> |
143 |
<input type="submit" class="btn btn-primary" value="Save" /> |
144 |
[% IF CAN_user_acquisition_delete_invoices AND NOT orders_loop.size %] |
145 |
<a href="invoice.pl?op=delete&invoiceid=[% invoiceid | uri %]" id="delete">Delete</a> |
146 |
[% END %] |
147 |
</fieldset> |
148 |
[% END %] |
149 |
</fieldset> |
150 |
</form> |
151 |
|
151 |
|
152 |
<h3>Adjustments</h3> |
152 |
<h3>Adjustments</h3> |
153 |
|
153 |
|
154 |
<form action="/cgi-bin/koha/acqui/invoice.pl" method="post" class="validated"> |
154 |
<form action="/cgi-bin/koha/acqui/invoice.pl" method="post" class="validated"> |
155 |
<fieldset class="rows"> |
155 |
<fieldset class="rows"> |
156 |
<input type="hidden" name="invoiceid" value="[% invoiceid | html %]" /> |
156 |
<input type="hidden" name="invoiceid" value="[% invoiceid | html %]" /> |
157 |
[% IF (adjustments && adjustments.count > 0) %] |
157 |
[% IF (adjustments && adjustments.count > 0) %] |
158 |
<table id="invoice_adj_table"> |
158 |
<table id="invoice_adj_table"> |
159 |
<tr> |
159 |
<tr> |
160 |
<th>Id</th> |
160 |
<th>Id</th> |
161 |
<th>Amount</th> |
161 |
<th>Amount</th> |
162 |
<th>Reason</th> |
162 |
<th>Reason</th> |
163 |
<th>Note</th> |
163 |
<th>Note</th> |
164 |
<th>Fund</th> |
164 |
<th>Fund</th> |
165 |
<th>Encumber while invoice open</th> |
165 |
<th>Encumber while invoice open</th> |
166 |
[% UNLESS readonly %]<th> </th>[% END %] |
166 |
[% UNLESS readonly %]<th> </th>[% END %] |
167 |
</tr> |
167 |
</tr> |
168 |
[% total_adj = 0 %] |
168 |
[% total_adj = 0 %] |
169 |
[% FOREACH adjustment IN adjustments %] |
169 |
[% FOREACH adjustment IN adjustments %] |
170 |
[% total_adj = total_adj + adjustment.adjustment %] |
170 |
[% total_adj = total_adj + adjustment.adjustment %] |
171 |
<tr> |
171 |
<tr> |
172 |
<td><input type="hidden" name="adjustment_id" value="[% adjustment.adjustment_id | html %]" />[% adjustment.adjustment_id | html %]</td> |
172 |
<td> |
173 |
<td> |
173 |
<input type="hidden" name="adjustment_id" value="[% adjustment.adjustment_id | html %]" />[% adjustment.adjustment_id | html %] |
174 |
[% IF readonly %] |
174 |
</td> |
175 |
[% adjustment.adjustment | $Price %] |
175 |
<td> |
176 |
[% ELSE %] |
176 |
[% IF readonly %] |
177 |
<input type="text" name="adjustment" id="adjustment_[% adjustment.adjustment_id | html %]" value="[% adjustment.adjustment | $Price on_editing => 1 %]" /> |
177 |
[% adjustment.adjustment | $Price %] |
178 |
[% END %] |
178 |
[% ELSE %] |
179 |
</td> |
179 |
<input type="text" name="adjustment" id="adjustment_[% adjustment.adjustment_id | html %]" value="[% adjustment.adjustment | $Price on_editing => 1 %]" /> |
180 |
<td> |
180 |
[% END %] |
181 |
[% IF readonly %] |
181 |
</td> |
182 |
[% AuthorisedValues.GetByCode('ADJ_REASON', adjustment.reason) | html %] |
182 |
<td> |
183 |
[% ELSE %] |
183 |
[% IF readonly %] |
184 |
[% reasons = AuthorisedValues.Get("ADJ_REASON") %] |
184 |
[% AuthorisedValues.GetByCode('ADJ_REASON', adjustment.reason) | html %] |
185 |
[% IF reasons.0 %] |
185 |
[% ELSE %] |
186 |
<select id="reason_[% adjustment.adjustment_id | html %]" name="reason"> |
186 |
[% reasons = AuthorisedValues.Get("ADJ_REASON") %] |
187 |
<option value="">No reason</option> |
187 |
[% IF reasons.0 %] |
188 |
[% FOREACH reason IN reasons %] |
188 |
<select id="reason_[% adjustment.adjustment_id | html %]" name="reason"> |
189 |
[% IF ( adjustment.reason == reason.authorised_value ) %] |
189 |
<option value="">No reason</option> |
190 |
<option selected="selected" value="[% reason.authorised_value | html %]"> |
190 |
[% FOREACH reason IN reasons %] |
191 |
[% ELSE %] |
191 |
[% IF ( adjustment.reason == reason.authorised_value ) %] |
192 |
<option value="[% reason.authorised_value | html %]"> |
192 |
<option selected="selected" value="[% reason.authorised_value | html %]"> |
193 |
[% END %] |
193 |
[% ELSE %] |
194 |
[% reason.lib | html %] |
194 |
<option value="[% reason.authorised_value | html %]"> |
195 |
</option> |
195 |
[% END %] |
196 |
[% END %] |
196 |
[% reason.lib | html %] |
197 |
</select> |
197 |
</option> |
198 |
[% ELSE %] |
198 |
[% END %] |
199 |
<p title="Define values in authorised value category ADJ_REASON to enable">None</p> |
199 |
</select> |
200 |
<input type="hidden" name="reason" id="reason_[% adjustment.adjustment_id | html %]" value="" /> |
200 |
[% ELSE %] |
201 |
[% END %] |
201 |
<p title="Define values in authorised value category ADJ_REASON to enable">None</p> |
202 |
[% END %] |
202 |
<input type="hidden" name="reason" id="reason_[% adjustment.adjustment_id | html %]" value="" /> |
203 |
</td> |
203 |
[% END %] |
204 |
<td> |
204 |
[% END %] |
205 |
[% IF readonly %] |
205 |
</td> |
206 |
[% adjustment.note | html %] |
206 |
<td> |
207 |
[% ELSE %] |
207 |
[% IF readonly %] |
208 |
<input type="text" name="note" id="note_new" value="[% adjustment.note | html %]"/> |
208 |
[% adjustment.note | html %] |
209 |
[% END %] |
209 |
[% ELSE %] |
210 |
</td> |
210 |
<input type="text" name="note" id="note_new" value="[% adjustment.note | html %]"/> |
211 |
<td> |
211 |
[% END %] |
212 |
[% PROCESS fund_dropdown form_id => "budget_id_" _ adjustment.adjustment_id form_name => 'budget_id' selected => adjustment.budget_id %] |
212 |
</td> |
213 |
</td> |
213 |
<td> |
214 |
[% IF adjustment.encumber_open %] |
214 |
[% PROCESS fund_dropdown form_id => "budget_id_" _ adjustment.adjustment_id form_name => 'budget_id' selected => adjustment.budget_id %] |
215 |
<td> |
215 |
</td> |
216 |
[% IF readonly %] |
216 |
[% IF adjustment.encumber_open %] |
217 |
<input type="checkbox" checked="checked" readonly="readonly" /> |
217 |
<td> |
|
|
218 |
[% IF readonly %] |
219 |
<input type="checkbox" checked="checked" readonly="readonly" /> |
220 |
[% ELSE %] |
221 |
<input type="checkbox" name="encumber_open" id="encumber_[% adjustment.adjustment_id | html %]" value="[% adjustment.adjustment_id | html %]" checked/> |
222 |
[% END %] |
223 |
</td> |
218 |
[% ELSE %] |
224 |
[% ELSE %] |
219 |
<input type="checkbox" name="encumber_open" id="encumber_[% adjustment.adjustment_id | html %]" value="[% adjustment.adjustment_id | html %]" checked/> |
225 |
<td> |
|
|
226 |
[% IF readonly %] |
227 |
<input type="checkbox" disabled="disabled" /> |
228 |
[% ELSE %] |
229 |
<input type="checkbox" name="encumber_open" id="encumber_[% adjustment.adjustment_id | html %]" value="[% adjustment.adjustment_id | html %]" /> |
230 |
[% END %] |
231 |
</td> |
220 |
[% END %] |
232 |
[% END %] |
221 |
</td> |
233 |
[% UNLESS readonly %] |
222 |
[% ELSE %] |
234 |
<td> |
223 |
<td> |
235 |
<a class="btn btn-default btn-xs delete_adjustment" href="/cgi-bin/koha/acqui/invoice.pl?op=del_adj&adjustment_id=[% adjustment.adjustment_id | html %]&invoiceid=[% invoiceid | html %]"><i class="fa fa-trash"></i> Delete</a> |
224 |
[% IF readonly %] |
236 |
</td> |
225 |
<input type="checkbox" disabled="disabled" /> |
|
|
226 |
[% ELSE %] |
227 |
<input type="checkbox" name="encumber_open" id="encumber_[% adjustment.adjustment_id | html %]" value="[% adjustment.adjustment_id | html %]" /> |
228 |
[% END %] |
237 |
[% END %] |
229 |
</td> |
238 |
</tr> |
230 |
[% END %] |
239 |
[% END %] |
231 |
[% UNLESS readonly %] |
240 |
</table> |
232 |
<td> |
241 |
[% END %] |
233 |
<a class="btn btn-default btn-xs delete_adjustment" href="/cgi-bin/koha/acqui/invoice.pl?op=del_adj&adjustment_id=[% adjustment.adjustment_id | html %]&invoiceid=[% invoiceid | html %]"><i class="fa fa-trash"></i> Delete</a> |
|
|
234 |
</td> |
235 |
[% END %] |
236 |
</tr> |
237 |
[% END %] |
238 |
</table> |
239 |
[% END %] |
240 |
|
242 |
|
241 |
[% UNLESS readonly %] |
243 |
[% UNLESS readonly %] |
242 |
<p> |
244 |
<p> |
243 |
<a href="#" id="show_invoice_adjustment" class="toggle_invoice_adjustment"><i class="fa fa-plus"></i> Add an adjustment</a> |
245 |
<a href="#" id="show_invoice_adjustment" class="toggle_invoice_adjustment"><i class="fa fa-plus"></i> Add an adjustment</a> |
244 |
</p> |
246 |
</p> |
245 |
|
247 |
|
246 |
<fieldset id="add_invoice_adjustment" style="display:none"> |
248 |
<fieldset id="add_invoice_adjustment" style="display:none"> |
247 |
<h4>Add an adjustment</h4> |
249 |
<h4>Add an adjustment</h4> |
248 |
<input type="hidden" name="adjustment_id" value="new" /> |
250 |
<input type="hidden" name="adjustment_id" value="new" /> |
249 |
<ol> |
251 |
<ol> |
250 |
<li> |
252 |
<li> |
251 |
<label for="adjustment_new">Amount: </label> |
253 |
<label for="adjustment_new">Amount: </label> |
252 |
<input type="text" name="adjustment" id="adjustment_new" /> |
254 |
<input type="text" name="adjustment" id="adjustment_new" /> |
253 |
</li> |
255 |
</li> |
254 |
[% reasons = AuthorisedValues.Get("ADJ_REASON") %] |
256 |
[% reasons = AuthorisedValues.Get("ADJ_REASON") %] |
255 |
[% IF reasons.0 %] |
257 |
[% IF reasons.0 %] |
256 |
<li> |
258 |
<li> |
257 |
<label for="reason_[% adjustment.adjustment_id | html %]">Reason: </label> |
259 |
<label for="reason_[% adjustment.adjustment_id | html %]">Reason: </label> |
258 |
<select id="reason_[% adjustment.adjustment_id | html %]" name="reason"> |
260 |
<select id="reason_[% adjustment.adjustment_id | html %]" name="reason"> |
259 |
<option value="">No reason</option> |
261 |
<option value="">No reason</option> |
260 |
[% FOREACH reason IN reasons %] |
262 |
[% FOREACH reason IN reasons %] |
261 |
<option value="[% reason.authorised_value | html %]"> |
263 |
<option value="[% reason.authorised_value | html %]"> |
262 |
[% reason.lib | html %] |
264 |
[% reason.lib | html %] |
263 |
</option> |
265 |
</option> |
264 |
[% END %] |
266 |
[% END %] |
265 |
</select> |
267 |
</select> |
266 |
</li> |
268 |
</li> |
267 |
[% ELSE %] |
269 |
[% ELSE %] |
268 |
<li> |
270 |
<li> |
269 |
<span class="label">Reason: </span> |
271 |
<span class="label">Reason: </span> |
270 |
<span>None</span> |
272 |
<span>None</span> |
271 |
<div class="hint">Define values in authorised value category ADJ_REASON to enable</div> |
273 |
<div class="hint">Define values in authorised value category ADJ_REASON to enable</div> |
272 |
</li> |
274 |
</li> |
273 |
[% END %] |
275 |
[% END %] |
274 |
<li> |
276 |
<li> |
275 |
<label for="note_new">Note: </label> |
277 |
<label for="note_new">Note: </label> |
276 |
<input type="text" name="note" id="note_new" value=""/> |
278 |
<input type="text" name="note" id="note_new" value=""/> |
277 |
</li> |
279 |
</li> |
278 |
<li> |
280 |
<li> |
279 |
[% PROCESS fund_dropdown form_id => "budget_id_new" form_name => 'budget_id' selected => "" %] |
281 |
[% PROCESS fund_dropdown form_id => "budget_id_new" form_name => 'budget_id' selected => "" %] |
280 |
</li> |
282 |
</li> |
281 |
<li> |
283 |
<li> |
282 |
<label for="encumber_new">Encumber while invoice open? </label> |
284 |
<label for="encumber_new">Encumber while invoice open? </label> |
283 |
<input type="checkbox" name="encumber_open" id="encumber_new" value="new" /> |
285 |
<input type="checkbox" name="encumber_open" id="encumber_new" value="new" /> |
284 |
<input type="hidden" name="delete" value=""> |
286 |
<input type="hidden" name="delete" value=""> |
285 |
</li> |
287 |
</li> |
286 |
<li> |
288 |
<li> |
287 |
<span class="label"> </span> |
289 |
<span class="label"> </span> |
288 |
<a href="#" id="cancel_invoice_adjustment" class="toggle_invoice_adjustment" style="display:none"><i class="fa fa-remove"></i> Cancel</a> |
290 |
<a href="#" id="cancel_invoice_adjustment" class="toggle_invoice_adjustment" style="display:none"><i class="fa fa-remove"></i> Cancel</a> |
289 |
</li> |
291 |
</li> |
290 |
</ol> |
292 |
</ol> |
291 |
</fieldset> |
293 |
</fieldset> |
292 |
<fieldset class="action"> |
294 |
<fieldset class="action"> |
293 |
<input type="hidden" name="op" value="mod_adj" /> |
295 |
<input type="hidden" name="op" value="mod_adj" /> |
294 |
<input type="submit" class="btn btn-primary" value="Update adjustments" /> |
296 |
<input type="submit" class="btn btn-primary" value="Update adjustments" /> |
295 |
</fieldset> |
297 |
</fieldset> |
296 |
[% END %] |
298 |
[% END %] |
297 |
</fieldset> |
299 |
</fieldset> |
298 |
</form> |
300 |
</form> |
299 |
<p> |
301 |
|
300 |
<a href="/cgi-bin/koha/acqui/parcel.pl?invoiceid=[% invoiceid | uri %]">Go to receipt page</a> |
302 |
<p> |
301 |
[% IF Koha.Preference('AcqEnableFiles') %]| <a href="/cgi-bin/koha/acqui/invoice-files.pl?invoiceid=[% invoiceid | uri %]">Manage invoice files</a>[% END %] |
303 |
<a href="/cgi-bin/koha/acqui/parcel.pl?invoiceid=[% invoiceid | uri %]">Go to receipt page</a> |
302 |
</p> |
304 |
[% IF Koha.Preference('AcqEnableFiles') %]| <a href="/cgi-bin/koha/acqui/invoice-files.pl?invoiceid=[% invoiceid | uri %]">Manage invoice files</a>[% END %] |
303 |
<h2>Invoice details</h2> |
305 |
</p> |
304 |
<fieldset> |
306 |
|
305 |
[% IF orders_loop.size %] |
307 |
<h2>Invoice details</h2> |
306 |
<label for="show_all_details"> |
308 |
|
307 |
<input type="checkbox" style="vertical-align: middle;" id="show_all_details" /> |
309 |
<fieldset> |
308 |
Show all details |
310 |
[% IF orders_loop.size %] |
309 |
</label> |
311 |
<label for="show_all_details"> |
310 |
<table id="orderst"> |
312 |
<input type="checkbox" style="vertical-align: middle;" id="show_all_details" /> |
311 |
<thead> |
313 |
Show all details |
312 |
<tr> |
314 |
</label> |
313 |
<th class="anti-the">Summary</th> |
315 |
<table id="orderst"> |
314 |
<th>Library</th> |
316 |
<thead> |
315 |
<th class="tax_excluded">Actual cost tax exc.</th> |
317 |
<tr> |
316 |
<th class="tax_included">Actual cost tax inc.</th> |
318 |
<th class="anti-the">Summary</th> |
317 |
<th class="replacementprice">Replacement price</th> |
319 |
<th>Library</th> |
318 |
<th>Qty.</th> |
320 |
<th class="tax_excluded">Actual cost tax exc.</th> |
319 |
<th class="tax_excluded">Total tax exc. ([% currency.symbol | html %])</th> |
321 |
<th class="tax_included">Actual cost tax inc.</th> |
320 |
<th class="tax_included">Total tax inc. ([% currency.symbol | html %])</th> |
322 |
<th class="replacementprice">Replacement price</th> |
321 |
<th>GST %</th> |
323 |
<th>Qty.</th> |
322 |
<th>GST</th> |
324 |
<th class="tax_excluded">Total tax exc. ([% currency.symbol | html %])</th> |
323 |
<th>Fund</th> |
325 |
<th class="tax_included">Total tax inc. ([% currency.symbol | html %])</th> |
324 |
</tr> |
326 |
<th>GST %</th> |
325 |
</thead> |
327 |
<th>GST</th> |
326 |
<tbody> |
328 |
<th>Fund</th> |
327 |
[% FOREACH order IN orders_loop %] |
329 |
</tr> |
328 |
<tr> |
330 |
</thead> |
329 |
<td> |
331 |
<tbody> |
330 |
[% IF order.biblionumber %] |
332 |
[% FOREACH order IN orders_loop %] |
331 |
[% INCLUDE 'biblio-title.inc' biblio=order link = 1 %] |
333 |
<tr> |
332 |
[% IF ( order.author ) %] |
334 |
<td> |
333 |
<br /><em>by</em> [% order.author | html %] |
335 |
[% IF order.biblionumber %] |
334 |
[% END %] |
336 |
[% INCLUDE 'biblio-title.inc' biblio=order link = 1 %] |
|
|
337 |
[% IF ( order.author ) %] |
338 |
<br /><em>by</em> [% order.author | html %] |
339 |
[% END %] |
340 |
[% ELSE %] |
341 |
<em>Deleted bibliographic record, can't find title</em> |
342 |
[% END %] |
343 |
[% IF ( order.isbn ) %] – [% order.isbn | html %][% END %] |
344 |
[% IF ( order.publishercode ) %] |
345 |
<br/>[% order.publishercode | html %] |
346 |
[% IF order.publicationyear %], [% order.publicationyear | html %] |
347 |
[% ELSIF ( order.copyrightdate ) %][% order.copyrightdate | html %][% END %] |
348 |
[% END %] |
349 |
</td> |
350 |
<td> |
351 |
<p>[% order.branchcode | html %]</p> |
352 |
</td> |
353 |
<td class="number tax_excluded"> |
354 |
[% order.unitprice_tax_excluded | $Price %] |
355 |
</td> |
356 |
<td class="number tax_included"> |
357 |
[% order.unitprice_tax_included | $Price %] |
358 |
</td> |
359 |
<td class="number replacementprice"> |
360 |
[% order.replacementprice | $Price %] |
361 |
[% IF ( order.uncertainprice ) %] |
362 |
<span>(Uncertain)</span> |
363 |
[% END %] |
364 |
</td> |
365 |
<td class="number"> |
366 |
[% order.quantity | html %] |
367 |
</td> |
368 |
<td class="number tax_excluded"> |
369 |
[% order.total_tax_excluded | $Price %] |
370 |
</td> |
371 |
<td class="number tax_included"> |
372 |
[% order.total_tax_included | $Price %] |
373 |
</td> |
374 |
<td class="number"> |
375 |
[% order.tax_rate * 100 | html %] |
376 |
</td> |
377 |
<td class="number"> |
378 |
[% order.tax_value | $Price %] |
379 |
</td> |
380 |
<td> |
381 |
<span class="order_name" data-order_id="[% order.ordernumber | html %]">[% order.budget_name | html %]</span></br> |
382 |
<a href="#" class="modify_fund" data-order_id="[% order.ordernumber | html %]" data-budget_id="[% order.budget_id | html %]" data-sort_1="[% order.sort1 | html %]" data-sort_2="[% order.sort2 | html %]" data-sort1="[% order.sort1 | html %]" data-sort2="[% order.sort2 | html %]">Modify fund</a> |
383 |
</td> |
384 |
</tr> |
385 |
[% END %] |
386 |
</tbody> |
387 |
<tfoot> |
388 |
[% FOR tf IN foot_loop %] |
389 |
<tr> |
390 |
<th colspan="2">Total (GST [% tf.tax_rate * 100 | html %] %)</th> |
391 |
<th class="tax_excluded"></th> |
392 |
<th class="tax_included"></th> |
393 |
<th class="replacementprice"/> |
394 |
<th>[% tf.quantity | html %]</th> |
395 |
<th class="tax_excluded">[% tf.total_tax_excluded | $Price %]</th> |
396 |
<th class="tax_included">[% tf.total_tax_included | $Price %]</th> |
397 |
<th> </th> |
398 |
<th>[% tf.tax_value | $Price %]</th> |
399 |
<th> </th> |
400 |
</tr> |
401 |
[% END %] |
402 |
<tr> |
403 |
<th colspan="2">Total ([% currency.symbol | html %])</th> |
404 |
<th class="tax_excluded"></th> |
405 |
<th class="tax_included"></th> |
406 |
<th class="replacementprice"/> |
407 |
<th>[% total_quantity | html %]</th> |
408 |
<th class="tax_excluded">[% total_tax_excluded | $Price %]</th> |
409 |
<th class="tax_included">[% total_tax_included | $Price %]</th> |
410 |
<th> </th> |
411 |
<th>[% total_tax_value | $Price %]</th> |
412 |
<th> </th> |
413 |
</tr> |
414 |
<tr> |
415 |
<th colspan="2">Total + adjustments + shipment cost ([% currency.symbol | html %])</th> |
416 |
<th class="tax_excluded"></th> |
417 |
<th class="tax_included"></th> |
418 |
<th class="replacementprice"/> |
419 |
<th>[% total_quantity | html %]</th> |
420 |
<th class="tax_excluded">[% total_tax_excluded_shipment + total_adj | $Price %]</th> |
421 |
<th class="tax_included">[% total_tax_included_shipment + total_adj | $Price %]</th> |
422 |
<th> </th> |
423 |
<th>[% total_tax_value | $Price %]</th> |
424 |
<th> </th> |
425 |
</tr> |
426 |
</tfoot> |
427 |
</table> |
335 |
[% ELSE %] |
428 |
[% ELSE %] |
336 |
<em>Deleted bibliographic record, can't find title</em> |
429 |
<div class="dialog message"> |
|
|
430 |
<p>No orders yet</p> |
431 |
[% IF adjustments && adjustments.count > 0 || shipmentcost && shipmentcost > 0 %] |
432 |
<p>Adjustments plus shipping: [% total_adj + shipmentcost | $Price %]</p> |
433 |
[% END %] |
434 |
</div> |
337 |
[% END %] |
435 |
[% END %] |
338 |
[% IF ( order.isbn ) %] – [% order.isbn | html %][% END %] |
436 |
[% IF ( (Koha.Preference('AcqEnableFiles')) && files ) %] |
339 |
[% IF ( order.publishercode ) %] |
437 |
<br /> |
340 |
<br/>[% order.publishercode | html %] |
438 |
<h2>Files attached to invoice</h2> |
341 |
[% IF order.publicationyear %], [% order.publicationyear | html %] |
439 |
<table id="invoice_files_table"> |
342 |
[% ELSIF ( order.copyrightdate ) %][% order.copyrightdate | html %][% END %] |
440 |
<thead> |
|
|
441 |
<tr> |
442 |
<th>Name</th> |
443 |
<th>Type</th> |
444 |
<th>Description</th> |
445 |
<th>Uploaded</th> |
446 |
</tr> |
447 |
</thead> |
448 |
<tbody> |
449 |
[% FOREACH f IN files %] |
450 |
<tr> |
451 |
<td> |
452 |
<a href="/cgi-bin/koha/acqui/invoice-files.pl?invoiceid=[% invoiceid | uri %]&op=download&view=1&file_id=[% f.file_id | uri %]">[% f.file_name | html %]</a> |
453 |
</td> |
454 |
<td>[% f.file_type | html %]</td> |
455 |
<td>[% f.file_description | html %]</td> |
456 |
<td data-order="[% f.date_uploaded | html %]"> |
457 |
[% f.date_uploaded | $KohaDates %] |
458 |
</td> |
459 |
</tr> |
460 |
[% END %] |
461 |
</tbody> |
462 |
</table> |
343 |
[% END %] |
463 |
[% END %] |
344 |
</td> |
464 |
</fieldset> |
345 |
<td><p>[% order.branchcode | html %]</p></td> |
465 |
</main> |
346 |
<td class="number tax_excluded">[% order.unitprice_tax_excluded | $Price %]</td> |
466 |
</div> <!-- /.col-sm-10.col-sm-push-2 --> |
347 |
<td class="number tax_included">[% order.unitprice_tax_included | $Price %]</td> |
|
|
348 |
<td class="number replacementprice">[% order.replacementprice | $Price %] [% IF ( order.uncertainprice ) %] <span>(Uncertain)</span> [% END %]</td> |
349 |
<td class="number">[% order.quantity | html %]</td> |
350 |
<td class="number tax_excluded">[% order.total_tax_excluded | $Price %]</td> |
351 |
<td class="number tax_included">[% order.total_tax_included | $Price %]</td> |
352 |
<td class="number">[% order.tax_rate * 100 | html %]</td> |
353 |
<td class="number">[% order.tax_value | $Price %]</td> |
354 |
<td> |
355 |
<span class="order_name" data-order_id="[% order.ordernumber | html %]">[% order.budget_name | html %]</span></br> |
356 |
<a href="#" class="modify_fund" data-order_id="[% order.ordernumber | html %]" data-budget_id="[% order.budget_id | html %]" data-sort_1="[% order.sort1 | html %]" data-sort_2="[% order.sort2 | html %]" data-sort1="[% order.sort1 | html %]" data-sort2="[% order.sort2 | html %]">Modify fund</a> |
357 |
</td> |
358 |
</tr> |
359 |
[% END %] |
360 |
</tbody> |
361 |
<tfoot> |
362 |
[% FOR tf IN foot_loop %] |
363 |
<tr> |
364 |
<th colspan="2">Total (GST [% tf.tax_rate * 100 | html %] %)</th> |
365 |
<th class="tax_excluded"></th> |
366 |
<th class="tax_included"></th> |
367 |
<th class="replacementprice"/> |
368 |
<th>[% tf.quantity | html %]</th> |
369 |
<th class="tax_excluded">[% tf.total_tax_excluded | $Price %]</th> |
370 |
<th class="tax_included">[% tf.total_tax_included | $Price %]</th> |
371 |
<th> </th> |
372 |
<th>[% tf.tax_value | $Price %]</th> |
373 |
<th> </th> |
374 |
</tr> |
375 |
[% END %] |
376 |
<tr> |
377 |
<th colspan="2">Total ([% currency.symbol | html %])</th> |
378 |
<th class="tax_excluded"></th> |
379 |
<th class="tax_included"></th> |
380 |
<th class="replacementprice"/> |
381 |
<th>[% total_quantity | html %]</th> |
382 |
<th class="tax_excluded">[% total_tax_excluded | $Price %]</th> |
383 |
<th class="tax_included">[% total_tax_included | $Price %]</th> |
384 |
<th> </th> |
385 |
<th>[% total_tax_value | $Price %]</th> |
386 |
<th> </th> |
387 |
</tr> |
388 |
<tr> |
389 |
<th colspan="2">Total + adjustments + shipment cost ([% currency.symbol | html %])</th> |
390 |
<th class="tax_excluded"></th> |
391 |
<th class="tax_included"></th> |
392 |
<th class="replacementprice"/> |
393 |
<th>[% total_quantity | html %]</th> |
394 |
<th class="tax_excluded">[% total_tax_excluded_shipment + total_adj | $Price %]</th> |
395 |
<th class="tax_included">[% total_tax_included_shipment + total_adj | $Price %]</th> |
396 |
<th> </th> |
397 |
<th>[% total_tax_value | $Price %]</th> |
398 |
<th> </th> |
399 |
</tr> |
400 |
</tfoot> |
401 |
</table> |
402 |
[% ELSE %] |
403 |
<div class="dialog message"><p>No orders yet</p> |
404 |
[% IF adjustments && adjustments.count > 0 || shipmentcost && shipmentcost > 0 %] |
405 |
<p>Adjustments plus shipping: [% total_adj + shipmentcost | $Price %]</p> |
406 |
[% END %] |
407 |
</div> |
408 |
[% END %] |
409 |
[% IF ( (Koha.Preference('AcqEnableFiles')) && files ) %] |
410 |
<br /> |
411 |
<h2>Files attached to invoice</h2> |
412 |
<table id="invoice_files_table"> |
413 |
<thead> |
414 |
<tr> |
415 |
<th>Name</th> |
416 |
<th>Type</th> |
417 |
<th>Description</th> |
418 |
<th>Uploaded</th> |
419 |
</tr> |
420 |
</thead> |
421 |
<tbody> |
422 |
[% FOREACH f IN files %] |
423 |
<tr> |
424 |
<td><a href="/cgi-bin/koha/acqui/invoice-files.pl?invoiceid=[% invoiceid | uri %]&op=download&view=1&file_id=[% f.file_id | uri %]">[% f.file_name | html %]</a></td> |
425 |
<td>[% f.file_type | html %]</td> |
426 |
<td>[% f.file_description | html %]</td> |
427 |
<td data-order="[% f.date_uploaded | html %]"> |
428 |
[% f.date_uploaded | $KohaDates %] |
429 |
</td> |
430 |
</tr> |
431 |
[% END %] |
432 |
</tbody> |
433 |
</table> |
434 |
[% END %] |
435 |
</fieldset> |
436 |
</main> |
437 |
</div> <!-- /.col-sm-10.col-sm-push-2 --> |
438 |
|
467 |
|
439 |
<aside> |
468 |
<aside> |
440 |
<div class="col-sm-2 col-sm-pull-10"> |
469 |
<div class="col-sm-2 col-sm-pull-10"> |
441 |
[% INCLUDE 'acquisitions-menu.inc' %] |
470 |
[% INCLUDE 'acquisitions-menu.inc' %] |
442 |
</div> |
471 |
</div> |
443 |
</aside> |
472 |
</aside> |
444 |
</div> <!-- /.row --> |
473 |
</div> <!-- /.row --> |
445 |
|
474 |
|
446 |
<div id="updateFund" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="updateReceivedFund" aria-hidden="true"> |
475 |
<div id="updateFund" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="updateReceivedFund" aria-hidden="true"> |
447 |
<div class="modal-dialog"> |
476 |
<div class="modal-dialog"> |
Lines 453-469
Link Here
|
453 |
<div class="modal-body"> |
482 |
<div class="modal-body"> |
454 |
<p>Updating the fund may change available statistics for the order, please check values before submitting.</p> |
483 |
<p>Updating the fund may change available statistics for the order, please check values before submitting.</p> |
455 |
<fieldset class="rows"> |
484 |
<fieldset class="rows"> |
456 |
<ol> |
485 |
<ol> |
457 |
<li>[% PROCESS fund_dropdown form_id => 'modify_budget_id' form_name => 'modify_budget_id' selected => "" %]</li> |
486 |
<li> |
458 |
<li> |
487 |
[% PROCESS fund_dropdown form_id => 'modify_budget_id' form_name => 'modify_budget_id' selected => "" %] |
459 |
<label for="sort1">Statistic 1: </label> |
488 |
</li> |
460 |
<input type="text" name="sort1" /> |
489 |
<li> |
461 |
</li> |
490 |
<label for="sort1">Statistic 1: </label> |
462 |
<li> |
491 |
<input type="text" name="sort1" /> |
463 |
<label for="sort2">Statistic 2: </label> |
492 |
</li> |
464 |
<input type="text" name="sort2" /> |
493 |
<li> |
465 |
</li> |
494 |
<label for="sort2">Statistic 2: </label> |
466 |
</ol> |
495 |
<input type="text" name="sort2" /> |
|
|
496 |
</li> |
497 |
</ol> |
467 |
</fieldset> |
498 |
</fieldset> |
468 |
<a id="update_fund" class="btn btn-default">Update fund</a> |
499 |
<a id="update_fund" class="btn btn-default">Update fund</a> |
469 |
</div> |
500 |
</div> |
470 |
- |
|
|