Lines 1-8
Link Here
|
|
|
1 |
[% USE KohaDates %] |
1 |
[% INCLUDE 'doc-head-open.inc' %] |
2 |
[% INCLUDE 'doc-head-open.inc' %] |
|
|
3 |
<link rel="stylesheet" type="text/css" href="[% themelang %]/css/datatables.css" /> |
2 |
[% INCLUDE 'doc-head-close.inc' %] |
4 |
[% INCLUDE 'doc-head-close.inc' %] |
3 |
[% INCLUDE 'calendar.inc' %] |
5 |
[% INCLUDE 'calendar.inc' %] |
|
|
6 |
<script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.dataTables.min.js"></script> |
7 |
[% INCLUDE 'datatables-strings.inc' %] |
8 |
<script type="text/javascript" src="[% themelang %]/js/datatables.js"></script> |
4 |
<script type="text/javascript" src="[% themelang %]/js/acq.js"></script> |
9 |
<script type="text/javascript" src="[% themelang %]/js/acq.js"></script> |
5 |
<script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.tablesorter.min.js"></script> |
|
|
6 |
<script type="text/javascript"> |
10 |
<script type="text/javascript"> |
7 |
// ################################################################################# |
11 |
// ################################################################################# |
8 |
// Javascript |
12 |
// Javascript |
Lines 69-81
Link Here
|
69 |
alert(alertString2); |
73 |
alert(alertString2); |
70 |
} |
74 |
} |
71 |
} |
75 |
} |
72 |
$(document).ready(function() { |
76 |
|
73 |
$("#periodsh").tablesorter({ |
77 |
|
74 |
widgets : ['zebra'], |
78 |
|
75 |
sortList: [[0,0]], |
79 |
[% IF ( dateformat == 'metric' ) %] |
76 |
headers: {6:{sorter:false}} |
80 |
dt_add_type_uk_date(); |
77 |
}); |
81 |
[% END %] |
78 |
}); |
82 |
$(document).ready(function() { |
|
|
83 |
var tabs = $('#budgetsTabs').tabs(); |
84 |
[% IF ( tab ) %] |
85 |
tabs.tabs('select', [% tab %]); |
86 |
[% END %] |
87 |
$("table").dataTable($.extend(true, {}, dataTablesDefaults, { |
88 |
"aoColumnDefs": [ |
89 |
{ |
90 |
[% IF ( dateformat == 'metric' ) %] |
91 |
"aTargets": [ 1, 2 ], "sType": "uk_date", |
92 |
[% END %] |
93 |
"bSortable": false, 'aTargets':['_all'], |
94 |
}, |
95 |
], |
96 |
"sPaginationType": "four_button", |
97 |
"bAutoWidth": false, |
98 |
"bPaginate": false, |
99 |
"bInfo": false, |
100 |
"bFilter": false, |
101 |
} ) ); |
102 |
}); |
79 |
</script> |
103 |
</script> |
80 |
|
104 |
|
81 |
<title> |
105 |
<title> |
Lines 164-176
Link Here
|
164 |
|
188 |
|
165 |
<li> |
189 |
<li> |
166 |
<label class="required" for="from">Start date</label> |
190 |
<label class="required" for="from">Start date</label> |
167 |
<input type="text" size="10" id="from" name="budget_period_startdate" value="[% budget_period_startdate %]" class="datepickerfrom" /> |
191 |
<input type="text" size="10" id="from" name="budget_period_startdate" value="[% budget_period_startdate | $KohaDates %]" class="datepickerfrom" /> |
168 |
<div class="hint">[% INCLUDE 'date-format.inc' %]</div> |
192 |
<div class="hint">[% INCLUDE 'date-format.inc' %]</div> |
169 |
</li> |
193 |
</li> |
170 |
<li> |
194 |
<li> |
171 |
|
195 |
|
172 |
<label class="required" for="to">End date</label> |
196 |
<label class="required" for="to">End date</label> |
173 |
<input type="text" size="10" id="to" name="budget_period_enddate" value="[% budget_period_enddate %]" class="datepickerto" /> |
197 |
<input type="text" size="10" id="to" name="budget_period_enddate" value="[% budget_period_enddate | $KohaDates %]" class="datepickerto" /> |
174 |
<div class="hint">[% INCLUDE 'date-format.inc' %]</div> |
198 |
<div class="hint">[% INCLUDE 'date-format.inc' %]</div> |
175 |
</li> |
199 |
</li> |
176 |
|
200 |
|
Lines 203-215
Link Here
|
203 |
<ol> |
227 |
<ol> |
204 |
<li> |
228 |
<li> |
205 |
<label class="required" for="from">Start date</label> |
229 |
<label class="required" for="from">Start date</label> |
206 |
<input type="text" size="10" id="from" name="budget_period_startdate" value="[% budget_period_startdate %]" class="datepickerfrom" /> |
230 |
<input type="text" size="10" id="from" name="budget_period_startdate" value="[% budget_period_startdate | $KohaDates %]" class="datepickerfrom" /> |
207 |
<div class="hint">[% INCLUDE 'date-format.inc' %]</div> |
231 |
<div class="hint">[% INCLUDE 'date-format.inc' %]</div> |
208 |
</li> |
232 |
</li> |
209 |
<li> |
233 |
<li> |
210 |
|
234 |
|
211 |
<label class="required" for="to">End date</label> |
235 |
<label class="required" for="to">End date</label> |
212 |
<input type="text" size="10" id="to" name="budget_period_enddate" value="[% budget_period_enddate %]" class="datepickerto" /> |
236 |
<input type="text" size="10" id="to" name="budget_period_enddate" value="[% budget_period_enddate | $KohaDates %]" class="datepickerto" /> |
213 |
<div class="hint">[% INCLUDE 'date-format.inc' %]</div> |
237 |
<div class="hint">[% INCLUDE 'date-format.inc' %]</div> |
214 |
</li> |
238 |
</li> |
215 |
|
239 |
|
Lines 290-337
Link Here
|
290 |
[% END %] |
314 |
[% END %] |
291 |
<!-- DEFAULT display budget periods list --> |
315 |
<!-- DEFAULT display budget periods list --> |
292 |
[% IF ( else ) %] |
316 |
[% IF ( else ) %] |
293 |
<h2>Budgets administration</h2> |
317 |
<h2>Budgets administration</h2> |
294 |
|
318 |
|
295 |
[% INCLUDE 'budgets-active-currency.inc' %] |
319 |
[% INCLUDE 'budgets-active-currency.inc' %] |
296 |
|
320 |
|
297 |
<table id="periodsh"> |
321 |
<div id="budgetsTabs" class="toptabs"> |
298 |
<thead> |
322 |
<ul> |
299 |
<tr> |
323 |
<li><a href="#active">Active Budgets</a></li> |
300 |
<th>Budget name</th> |
324 |
<li><a href="#inactive">Inactive Budgets</a></li> |
301 |
<th>Start date</th> |
325 |
</ul> |
302 |
<th>End date</th> |
326 |
|
303 |
<th>Active</th> |
327 |
<div id="active"> |
304 |
<th>Locked</th> |
328 |
<h3>Active Budgets</h3> |
305 |
<th>Total</th> |
329 |
[% IF ( period_active_loop ) %] |
306 |
<th>Actions</th> |
330 |
<table id="activeperiodst"> |
307 |
</tr> |
331 |
<thead> |
308 |
</thead> |
332 |
<tr> |
309 |
<tbody> |
333 |
<th>Budget name</th> |
310 |
[% FOREACH period_loo IN period_loop %] |
334 |
<th>Start date</th> |
311 |
[% IF ( loop.odd ) %] |
335 |
<th>End date</th> |
312 |
<tr> |
336 |
<th>Locked</th> |
313 |
[% ELSE %] |
337 |
<th>Total</th> |
314 |
<tr class="highlight"> |
338 |
<th>Actions</th> |
315 |
[% END %] |
339 |
</tr> |
316 |
<td><a href="/cgi-bin/koha/admin/aqbudgets.pl?budget_period_id=[% period_loo.budget_period_id %]" title="View funds for [% period_loo.budget_period_description %]">[% period_loo.budget_period_description %]</a></td> |
340 |
</thead> |
317 |
<td>[% period_loo.budget_period_startdate %]</td> |
341 |
<tbody> |
318 |
<td>[% period_loo.budget_period_enddate %]</td> |
342 |
[% FOREACH period_active IN period_active_loop %] |
319 |
<td>[% IF ( period_loo.budget_period_active ) %]<span style="color:green;">Active</span> [% ELSE %][% END %] </td> |
343 |
<tr> |
320 |
<td> [% IF ( period_loo.budget_period_locked ) %]<span style="color:green;">Locked</span> [% ELSE %][% END %] </td> |
344 |
<td><a href="/cgi-bin/koha/admin/aqbudgets.pl?budget_period_id=[% period_active.budget_period_id %]" title="View funds for [% period_active.budget_period_description %]">[% period_active.budget_period_description %]</a></td> |
321 |
<td align='right'>[% period_loo.budget_period_total %]</td> |
345 |
<td>[% period_active.budget_period_startdate | $KohaDates %]</td> |
322 |
<td> |
346 |
<td>[% period_active.budget_period_enddate | $KohaDates %]</td> |
323 |
<a href="[% period_loo.script_name %]?op=add_form&budget_period_id=[% period_loo.budget_period_id |html %]">Edit</a> |
347 |
<td> |
324 |
<a href="[% period_loo.script_name %]?op=delete_confirm&budget_period_id=[% period_loo.budget_period_id %]">Delete</a> |
348 |
[% IF ( period_active.budget_period_locked ) %] |
325 |
<a href="/cgi-bin/koha/admin/aqbudgets.pl?op=add_form&budget_period_id=[% period_loo.budget_period_id %]">Add fund</a> |
349 |
<span style="color:green;">Locked</span> |
326 |
</td> |
350 |
[% END %] |
327 |
</tr> |
351 |
</td> |
328 |
[% END %] |
352 |
<td align='right'>[% period_active.budget_period_total %]</td> |
329 |
[% UNLESS ( period_loop ) %] |
353 |
<td> |
330 |
<tr><td colspan="7">No budget</td></tr> |
354 |
<a href="[% script_name %]?op=add_form&budget_period_id=[% period_active.budget_period_id |html %]">Edit</a> |
331 |
[% END %] |
355 |
<a href="[% script_name %]?op=delete_confirm&budget_period_id=[% period_active.budget_period_id %]">Delete</a> |
332 |
</tbody> |
356 |
<a href="/cgi-bin/koha/admin/aqbudgets.pl?op=add_form&budget_period_id=[% period_active.budget_period_id %]">Add Fund</a> |
333 |
</table> |
357 |
</td> |
334 |
<div class="pages">[% pagination_bar %]</div> |
358 |
</tr> |
|
|
359 |
[% END %] |
360 |
</tbody> |
361 |
</table> |
362 |
[% ELSE %] |
363 |
No active budgets |
364 |
[% END %] |
365 |
<div class="paginationBar">[% active_pagination_bar %]</div> |
366 |
</div> |
367 |
<div id="inactive"> |
368 |
<h3>Inactive Budgets</h3> |
369 |
[% IF ( period_inactive_loop ) %] |
370 |
<table id="inactiveperiodst"> |
371 |
<thead> |
372 |
<tr> |
373 |
<th>Budget name</th> |
374 |
<th>Start date</th> |
375 |
<th>End date</th> |
376 |
<th>Locked</th> |
377 |
<th>Total</th> |
378 |
<th>Actions</th> |
379 |
</tr> |
380 |
</thead> |
381 |
<tbody> |
382 |
[% FOREACH period_loo IN period_inactive_loop %] |
383 |
[% IF ( loop.odd ) %] |
384 |
<tr> |
385 |
[% ELSE %] |
386 |
<tr class="highlight"> |
387 |
[% END %] |
388 |
<td><a href="/cgi-bin/koha/admin/aqbudgets.pl?budget_period_id=[% period_loo.budget_period_id %]" title="View funds for [% period_loo.budget_period_description %]">[% period_loo.budget_period_description %]</a></td> |
389 |
<td>[% period_loo.budget_period_startdate | $KohaDates %]</td> |
390 |
<td>[% period_loo.budget_period_enddate | $KohaDates %]</td> |
391 |
<td> [% IF ( period_loo.budget_period_locked ) %]<span style="color:green;">Locked</span> [% ELSE %][% END %] </td> |
392 |
<td align='right'>[% period_loo.budget_period_total %]</td> |
393 |
<td> |
394 |
<a href="[% period_loo.script_name %]?op=add_form&budget_period_id=[% period_loo.budget_period_id |html %]">Edit</a> |
395 |
<a href="[% period_loo.script_name %]?op=delete_confirm&budget_period_id=[% period_loo.budget_period_id %]">Delete</a> |
396 |
<a href="/cgi-bin/koha/admin/aqbudgets.pl?op=add_form&budget_period_id=[% period_loo.budget_period_id %]">Add fund</a> |
397 |
</td> |
398 |
</tr> |
399 |
[% END %] |
400 |
</tbody> |
401 |
</table> |
402 |
[% ELSE %] |
403 |
No inactive budgets |
404 |
[% END %] |
405 |
<div class="pages">[% inactive_pagination_bar %]</div> |
406 |
</div> |
407 |
</div> |
335 |
[% END %] |
408 |
[% END %] |
336 |
|
409 |
|
337 |
|
410 |
|
338 |
- |
|
|