Bug 13618: Remove html filters at the intranet
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / admin / aqbudgetperiods.tt
1 [% USE KohaDates %]
2 [% USE Price %]
3
4 [%- BLOCK action_menu %]
5     <div class="dropdown">
6         <a class="btn btn-mini dropdown-toggle" id="budgetmenu_[% block_budget_id %]" role="button" data-toggle="dropdown" href="#">
7            Actions <b class="caret"></b>
8         </a>
9         <ul class="dropdown-menu pull-right" role="menu" aria-labelledby="budgetmenu_[% block_budget_id %]">
10               <li>
11                   <a href="[% script_name %]?op=add_form&amp;budget_period_id=[% block_budget_id %]"><i class="fa fa-pencil"></i> Edit</a>
12               </li>
13               <li>
14                   <a href="[% script_name %]?op=delete_confirm&amp;budget_period_id=[% block_budget_id %]"><i class="fa fa-remove"></i> Delete</a>
15               </li>
16               <li>
17                   <a href="[% script_name %]?op=duplicate_form&amp;budget_period_id=[% block_budget_id %]"><i class="fa fa-copy"></i> Duplicate</a>
18               </li>
19               <li>
20                   <a href="[% script_name %]?op=close_form&amp;budget_period_id=[% block_budget_id %]"><i class="fa fa-times-circle"></i> Close</a>
21               </li>
22               <li>
23                   <a href="/cgi-bin/koha/admin/aqbudgets.pl?op=add_form&amp;budget_period_id=[% block_budget_id %]"><i class="fa fa-plus"></i> Add fund</a>
24               </li>
25         </ul>
26     </div>
27 [% END -%]
28
29 [% INCLUDE 'doc-head-open.inc' %]
30 <link rel="stylesheet" type="text/css" href="[% themelang %]/css/datatables.css" />
31 [% INCLUDE 'doc-head-close.inc' %]
32 [% INCLUDE 'calendar.inc' %]
33 [% INCLUDE 'datatables.inc' %]
34 [% IF close_form %]
35     <link href="[% interface %]/lib/jquery/plugins/treetable/stylesheets/jquery.treetable.css" rel="stylesheet" type="text/css" />
36     <script type="text/javascript" src="[% interface %]/lib/jquery/plugins/treetable/jquery.treetable.js"></script>
37 [% END %]
38 <script type="text/javascript" src="[% themelang %]/js/acq.js"></script>
39 <script type="text/javascript">
40 // #################################################################################
41 // Javascript
42 // #################################################################################
43     function CheckDuplicateForm(f){
44             var ok=1;
45             var _alertString="";
46             var alertString="";
47             if(!(isNotNull(f.budget_period_startdate,1))){
48               _alertString += "\n- " + _("Start date missing");
49             }
50             if (!(isNotNull(f.budget_period_enddate,1))){
51               _alertString += "\n- " + _("End date missing");
52             }
53             if( f.budget_period_startdate > f.budget_period_enddate ) {
54               _alertString += "\n- " + _("Start date must be before end date");
55             }
56             if (!(isNotNull(f.budget_period_description,1))){
57               _alertString += "\n- " + _("Budget description missing");
58             }
59
60             if(_alertString.length==0){
61               f.submit();
62             } else {
63               alertString += _("Form not submitted because of the following problem(s)");
64               alertString += "\n-----------------------------------------\n";
65               alertString += _alertString;
66               alert(alertString);
67             }
68     }
69     function Check(f) {
70             var ok=1;
71             var _alertString="";
72             var alertString2;
73
74             if (!(isNotNull(f.budget_period_startdate,1))) {
75                     _alertString += "\n- " + _("Start date missing");
76             }
77
78             if (!(isNotNull(f.budget_period_enddate,1))) {
79                     _alertString += "\n- " + _("End date missing");
80             }
81
82             if ( f.budget_period_startdate >   f.budget_period_enddate )  {
83                     _alertString += "\n- " + _("Start date must be before end date");
84             }
85
86             if (!(isNotNull(f.budget_period_description,1))) {
87                     _alertString += "\n- " + _("Description missing");
88             }
89
90             if (!(isNum(f.budget_period_total))) {
91                     _alertString += "\n- " + _("Amount must be a valid number, or empty");
92             }
93
94 /*
95                         checkBudgetTotal(f) {
96                         }
97 */
98
99             if (_alertString.length==0) {
100                     f.submit();
101             } else {
102                     alertString2  = _("Form not submitted because of the following problem(s)");
103                     alertString2 += "\n------------------------------------------------------------------------------------\n";
104                     alertString2 += _alertString;
105                     alert(alertString2);
106             }
107     }
108
109     $(document).ready(function() {
110         var tabs = $('#budgetsTabs').tabs();
111         [% IF ( tab ) %]
112             tabs.tabs("option", "active", [% tab %]);
113         [% END %]
114         $("#activeperiodst,#inactiveperiodst").dataTable($.extend(true, {}, dataTablesDefaults, {
115             "sDom": 't',
116             "aaSorting": [],
117             "aoColumnDefs": [
118                 { "aTargets": [ -1 ], "bSortable": false, "bSearchable": false },
119                 { "sType": "title-string", "aTargets" : [ "title-string" ] }
120             ],
121             "bPaginate": false,
122             'bAutoWidth': false
123         } ) );
124
125         [% IF close_form %]
126           $("#budgeth").dataTable($.extend(true, {}, dataTablesDefaults, {
127             sDom: "t"
128           }));
129           $("#move_form").submit(function(){
130             var budget_from = "[% budget_period_description %]";
131             var budget_to = $("#to_budget_period_id").find("option:selected").html();
132             var alert_message = _("You have chosen to move all unreceived orders from '%s' to '%s'.").format(budget_from, budget_to);
133             alert_message += "\n" + _("This action cannot be reversed. Do you wish to continue?");
134             return confirm ( alert_message );
135           });
136         [% END %]
137         [% IF closed %]
138           var oTable = $("#closed_report").dataTable($.extend(true, {}, dataTablesDefaults, {
139             // The following is a c/p from aqbudgets.tt and is a candidate for refactoring.
140             "fnDrawCallback": function ( oSettings ) {
141                 if ( oSettings.aiDisplay.length == 0 )
142                 {
143                     return;
144                 }
145
146                 var nTrs = $('#closed_report tbody tr');
147                 var iColspan = nTrs[1].getElementsByTagName('td').length;
148                 var sLastGroup = "";
149                 for ( var i=0 ; i<nTrs.length ; i++ )
150                 {
151                     var iDisplayIndex = oSettings._iDisplayStart + i;
152                     var sGroup = oSettings.aoData[ oSettings.aiDisplay[iDisplayIndex] ]._aData[0];
153                     if ( sGroup != sLastGroup )
154                     {
155                         var nGroup = document.createElement( 'tr' );
156                         var nCell = document.createElement( 'td' );
157                         nCell.colSpan = iColspan;
158                         nCell.className = "group";
159                         nCell.innerHTML = sGroup;
160                         nGroup.appendChild( nCell );
161                         nTrs[i].parentNode.insertBefore( nGroup, nTrs[i] );
162                         sLastGroup = sGroup;
163                     }
164                 }
165             },
166             "aoColumnDefs": [
167                 { "bVisible": false, "aTargets": [ 0, 1 ] },
168                 { "bSortable": false, "aTargets": ["_all"] }
169             ],
170             'bSort': true,
171             'aaSortingFixed': [[ 1, 'asc' ]],
172             'bPaginate': false,
173             "bAutoWidth": false
174           }));
175         [% END %]
176     });
177 </script>
178
179 <title>
180     Koha &rsaquo; Administration &rsaquo; Budgets
181
182     [% IF ( add_form ) %]&rsaquo;
183         [% IF ( budget_period_id ) %]
184             Modify budget [% budget_period_description %]
185         [% ELSE %]
186             Add budget
187         [% END %]
188     [% END %]
189     [% IF ( duplicate_form ) %]&rsaquo; Duplicate budget[% END %]
190     [% IF ( delete_confirm ) %]&rsaquo;
191             Delete budget '[% budget_period_description %]'?
192     [% END %]
193     [% IF ( delete_confirmed ) %]&rsaquo;
194         Data deleted
195     [% END %]
196     [% IF close_form %]&rsaquo;
197       Close budget [% budget_period_description %]
198     [% END %]
199     [% IF closed %]&rsaquo;
200       Budget [% budget_period_description %] closed
201     [% END %]
202 </title>
203
204
205 </head>
206
207 <body id="admin_aqbudgetperiods" class="admin">
208
209 [% INCLUDE 'header.inc' %]
210 [% INCLUDE 'budgets-admin-search.inc' %]
211
212 <!-- ################################################################################# -->
213 <!-- BREADCRUMBS -->
214 <!-- ################################################################################# -->
215
216 <div id="breadcrumbs">
217     <a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo;
218     <a href="/cgi-bin/koha/admin/admin-home.pl">Administration</a> &rsaquo;
219
220     [% IF ( add_form ) %]
221         <a href="/cgi-bin/koha/admin/aqbudgetperiods.pl">Budgets</a> &rsaquo;
222         [% IF ( budget_period_id ) %]
223             <span>Modify budget '[% budget_period_description %]'</span>
224         [% ELSE %]
225             <span>Add budget</span>
226         [% END %]
227     [% END %]
228     [% IF ( delete_confirm ) %]
229         <a href="/cgi-bin/koha/admin/aqbudgetperiods.pl">Budgets</a> &rsaquo;
230         [% IF ( total ) %]
231             <span>Cannot delete budget '[% budget_period_description %]'</span>
232         [% ELSE %]
233             <span>Delete budget '[% budget_period_description %]'?</span>
234         [% END %]
235     [% END %]
236     [% IF ( duplicate_form ) %]
237         <a href="/cgi-bin/koha/admin/aqbudgetperiods.pl">Budgets</a> &rsaquo; Duplicate budget
238     [% END %]
239     [% IF close_form %]
240         <a href="/cgi-bin/koha/admin/aqbudgetperiods.pl">Budgets</a> &rsaquo;
241         <span>Close budget <a href="/cgi-bin/koha/admin/aqbudgets.pl?budget_period_id=[% budget_period_id %]">[% budget_period_description %]</a></span>
242     [% END %]
243     [% IF closed %]
244         <a href="/cgi-bin/koha/admin/aqbudgetperiods.pl">Budgets</a> &rsaquo;
245         <span>Budget <a href="/cgi-bin/koha/admin/aqbudgets.pl?budget_period_id=[% budget_period_id %]">[% budget_period_description %]</a> closed</span>
246     [% END %]
247     [% IF ( else ) %]
248         <span>Budgets administration</span>
249     [% END %]
250 </div>
251
252 <div id="doc3" class="yui-t2">
253 <div id="bd">
254 <div id="yui-main">
255 <div class="yui-b">
256
257 [% UNLESS close_form OR closed%]
258   [% INCLUDE 'budgets-admin-toolbar.inc' %]
259 [% END %]
260
261 [% IF ( duplicate_form ) %]
262 <h3>Duplicate budget</h3>
263 <form action="/cgi-bin/koha/admin/aqbudgetperiods.pl" name="f" method="post">
264     <fieldset class="rows">
265     <input type="hidden" name="op" value="duplicate_budget" />
266     <input type="hidden" name="budget_period_id" value="[% budget_period_id %]" />
267
268     <ol>
269
270     <li>
271     <label class="required" for="from">Start date: </label>
272     <input type="text" size="10" id="from" name="budget_period_startdate" value="[% budget_period_startdate | $KohaDates %]" class="datepickerfrom" />
273                                 <div class="hint">[% INCLUDE 'date-format.inc' %]</div>
274     </li>
275     <li>
276
277     <label class="required" for="to">End date: </label>
278     <input type="text" size="10" id="to" name="budget_period_enddate" value="[% budget_period_enddate | $KohaDates %]" class="datepickerto" />
279                                 <div class="hint">[% INCLUDE 'date-format.inc' %]</div>
280     </li>
281
282     <li>
283     <label class="required" for="budget_period_description">Description</label>
284     <input type="text" id="budget_period_description" name="budget_period_description" value="[% budgetperiod.budget_period_description %]" />
285     </li>
286
287     <li>
288       <label for="amount_change_percentage">Change amounts by</label>
289       <input type="text" id="amount_change_percentage" name="amount_change_percentage" /> %
290       <div class="hint">(can be positive or negative)</div>
291     </li>
292
293     <li>
294       <label for="amount_change_round_increment">If amounts changed, round to a multiple of</label>
295       <input type="text" id="amount_change_round_increment" name="amount_change_round_increment" />
296       <div class="hint">(amounts will be rounded down)</div>
297     </li>
298
299     <li>
300       <label for="mark_as_inactive">Mark the original budget as inactive</label>
301       <input type="checkbox" id="mark_as_inactive" name="mark_original_budget_as_inactive" />
302     </li>
303
304     <li>
305       <label for="reset_all_budgets">Set all funds to zero</label>
306       <input type="checkbox" id="reset_all_budgets" name="reset_all_budgets" />
307     </li>
308
309     </ol>
310     </fieldset>
311
312     <fieldset class="action">
313         <input type="button" value="Save Changes"  onclick="CheckDuplicateForm(this.form)" /> <a class="cancel" href="/cgi-bin/koha/admin/aqbudgets.pl?budget_period_id=[% budget_period_id %]">Cancel</a>
314     </fieldset>
315
316 </form>
317
318 [% END %]
319
320 [% IF ( add_form ) %]
321     <!--  add or modify a budget period   -->
322
323     [% IF ( budget_period_id ) %]
324         <h3>Modify budget <i>[% budget_period_description %]</i></h3>
325     [% ELSE %]
326         <h3>Add budget</h3>
327         [% END %]
328 <form action="/cgi-bin/koha/admin/aqbudgetperiods.pl" name="f" method="post">
329     <fieldset class="rows">
330     <!-- ################################################################################# -->
331     <!-- display information about the budget period that must be added or modified -->
332     <!-- ################################################################################# -->
333     <input type="hidden" name="op" value="add_validate" />
334     <input type="hidden" name="budget_period_id" value="[% budget_period_id %]" />
335     <ol>
336     <li>
337     <label class="required" for="from">Start date: </label>
338     <input type="text" size="10" id="from" name="budget_period_startdate" value="[% budget_period_startdate | $KohaDates %]" class="datepickerfrom" />
339                                 <div class="hint">[% INCLUDE 'date-format.inc' %]</div>
340     </li>
341     <li>
342
343     <label class="required" for="to">End date: </label>
344     <input type="text" size="10" id="to" name="budget_period_enddate" value="[% budget_period_enddate | $KohaDates %]" class="datepickerto" />
345                                 <div class="hint">[% INCLUDE 'date-format.inc' %]</div>
346     </li>
347
348     <li>
349         <!-- DESCRIPTION -->
350         <!-- ############################## -->
351         <label class="required" for="budget_period_description">Description: </label>
352         <input type="text" id="budget_period_description" name="budget_period_description"
353         size="48" maxlength="80" value="[% budget_period_description %]" />
354     </li>
355
356     <li>
357         <!-- TOTAL -->
358         <!-- ############################## -->
359         <label for="budget_period_total">Total amount: </label>
360         <input type="text" id="budget_period_total" name="budget_period_total"
361         size="10" maxlength="80" value="[% budget_period_total | $Price on_editing => 1 %]" />
362     </li>
363
364     <li>
365         <!-- ACTIVE -->
366         <!-- ############################## -->
367         <label for="budget_period_active">Make budget active: </label>
368         [% IF ( budget_period_active ) %]<input type="checkbox" checked="checked" id="budget_period_active" name="budget_period_active" value="1" />[% ELSE %]  <input type="checkbox" id="budget_period_active" name="budget_period_active" value="1"/> [% END %]
369     </li>
370
371     <li>
372         <!-- LOCK  -->
373         <!-- ############################## -->
374         <label for="budget_period_locked">Lock budget: </label>
375         [% IF ( budget_period_locked ) %]<input type="checkbox" checked="checked" id="budget_period_locked" name="budget_period_locked" value="1" />[% ELSE %]  <input type="checkbox" id="budget_period_locked" name="budget_period_locked" value="1"/> [% END %]
376     </li>
377     </ol>
378     </fieldset>
379
380     <fieldset class="action">
381         <!-- "save changes" button -->
382         <!-- ###################################### -->
383         <input type="button" value="Save changes"  onclick="Check(this.form)"    />
384         <!--             <input type="submit" value="Save Changes"  />  -->
385         [% IF ( budget_period_id ) %]<a href="/cgi-bin/koha/admin/aqbudgets.pl?budget_period_id=[% budget_period_id %]" class="cancel">Cancel</a>[% END %]
386     </fieldset>
387
388 </form>
389
390 [% END %]
391
392 <!-- ####################################################################### -->
393 <!-- delete a budget period -->
394 <!-- ####################################################################### -->
395
396 [% IF ( delete_confirm ) %]
397     [% IF ( total ) %]
398         <div class="dialog message">
399         <h3>Cannot delete budget</h3>
400         <p><strong>This record is used [% total %] times</strong>
401         . Deletion is not possible.</p>
402     [% ELSE %]
403         <div class="dialog alert">
404         <h3>Delete budget '[% budget_period_description %]'?</h3>
405     [% END %]
406
407     <!-- ############################################################# -->
408     <!-- "delete" and "cancel" buttons    -->
409     <!-- ############################################################# -->
410
411     <form action="[% script_name %]" method="post">
412         <input type="hidden" name="op" value="delete_confirmed" />
413         <input type="hidden" name="budget_period_id" value="[% budget_period_id %]" />
414         <input type="submit" class="approve" value="Delete" />
415     </form>
416
417     <form action="[% script_name %]" method="post">
418         <input type="submit" class="deny" value="Cancel" />
419     </form>
420
421     </div>
422 [% END %]
423
424 [% IF close_form %]
425   [% IF budget_periods.size == 0 %]
426     You cannot move funds of this budget, there is no active budget.
427     Please create a new active budget and retry.
428     <a href="/cgi-bin/koha/admin/aqbudgetperiods.pl">Back</a>
429   [% ELSIF number_of_unreceived_orders == 0 %]
430     There are no unreceived orders for this budget.
431     <a href="/cgi-bin/koha/admin/aqbudgetperiods.pl">Back</a>
432   [% ELSE %]
433     <h3>The unreceived orders from the following funds will be moved</h3>
434       Fund list of budget <a href="/cgi-bin/koha/admin/aqbudgets.pl?budget_period_id=[% budget_period_id %]">[% budget_period_description %]</a>:
435     <table id="budgeth">
436       <thead>
437         <tr>
438             <th>Fund id</th>
439             <th>Fund code</th>
440             <th>Fund name</th>
441             <th>Unreceived orders</th>
442         </tr>
443       </thead>
444       <tbody>
445         [% FOREACH budget IN budgets_to_move %]
446           <tr>
447             <td>[% budget.budget_id %]</td>
448             <td>[% budget.budget_code_indent %]</td>
449             <td>[% budget.budget_name %]</td>
450             <td>[% budget.unreceived_orders.size %]</td>
451           </tr>
452         [% END %]
453       </tbody>
454     </table>
455     <form action="/cgi-bin/koha/admin/aqbudgetperiods.pl" name="f" method="post" id="move_form">
456       <fieldset class="rows">
457         <ol>
458           <li>
459             <label class="required" for="to_budget_period_id">Select a budget</label>
460             <select name="to_budget_period_id" id="to_budget_period_id" required="required">
461               <option value=""></option>
462               [% FOR budget_period IN budget_periods %]
463                 <option value="[% budget_period.budget_period_id %]">[% budget_period.budget_period_description %]</option>
464               [% END %]
465             </select>
466           </li>
467           <li>
468           <label for="move_remaining_unspent">Move remaining unspent funds</label>
469             <input type="checkbox" name="move_remaining_unspent" id="move_remaining_unspent" />
470           </li>
471         </ol>
472       </fieldset>
473       <fieldset class="action">
474           <input type="hidden" name="op" value="close_confirmed" />
475           <input type="hidden" name="budget_period_id" value="[% budget_period_id %]" />
476           <input type="submit" value="Move unreceived orders" />
477           <a class="cancel" href="/cgi-bin/koha/admin/aqbudgetperiods.pl">Cancel</a>
478       </fieldset>
479     </form>
480   [% END %]
481 [% ELSIF closed %]
482   <h3>Report after moving unreceived orders from budget [% from_budget_period.budget_period_description %] ([% from_budget_period.budget_period_startdate | $KohaDates %] - [% from_budget_period.budget_period_enddate | $KohaDates %]) to [% to_budget_period.budget_period_description %] ([% to_budget_period.budget_period_startdate | $KohaDates %] - [% to_budget_period.budget_period_enddate | $KohaDates%])</h3>
483
484   <table id="closed_report">
485     <thead>
486       <tr>
487         <td>Budget id</td>
488         <td>Basket</td>
489         <td>Ordernumber</td>
490         <td>Details</td>
491       </tr>
492     </thead>
493     <tbody>
494       [% FOR r IN report %]
495           [% IF r.moved %]
496             [% IF r.orders_moved.size > 0 %]
497               [% FOR order IN r.orders_moved %]
498                 <tr>
499                   <td>[% r.budget.budget_name %] (id=[% r.budget.budget_id %]) Amount=[% r.budget.budget_amount | $Price %][% IF r.unspent_moved %] ([% r.unspent_moved | $Price %] remaining has been moved)[% END %]</td>
500                   <td>[% order.basketname %]</td>
501                   <td>[% order.ordernumber %]</td>
502                   <td>Moved!</td>
503                 </tr>
504               [% END %]
505             [% ELSE %]
506               <tr>
507                 <td>[% r.budget.budget_name %] (id=[% r.budget.budget_id %])</td>
508                 <td></td>
509                 <td></td>
510                 <td>There were no unreceived orders for this fund.</td>
511               </tr>
512             [% END %]
513           [% ELSE %]
514             [% IF r.error == 'budget_code_not_exists' %]
515               <tr>
516                 <td>[% r.budget.budget_id %] [% r.budget.budget_amount | $Price %][% IF r.unspent_moved %] ([% r.unspent_moved | $Price %] remaining has been moved)[% END %]</td>
517                 <td></td>
518                 <td></td>
519                 <td>This fund code does not exist in the destination budget.</td>
520               </tr>
521             [% END %]
522           [% END %]
523         </tr>
524       [% END %]
525     </tbody>
526   </table>
527   <a class="cancel" href="/cgi-bin/koha/admin/aqbudgetperiods.pl">Back</a>
528 [% END %]
529
530 <!--  DEFAULT  display budget periods list -->
531 [% IF ( else ) %]
532   <h2>Budgets administration</h2>
533
534   [% INCLUDE 'budgets-active-currency.inc' %]
535
536   <div id="budgetsTabs" class="toptabs">
537     <ul>
538         <li><a href="#active">Active budgets</a></li>
539         <li><a href="#inactive">Inactive budgets</a></li>
540     </ul>
541
542     <div id="active">
543       [% IF ( period_active_loop ) %]
544         <table id="activeperiodst">
545           <thead>
546             <tr>
547               <th>Budget name</th>
548               <th class="title-string">Start date</th>
549               <th class="title-string">End date</th>
550               <th>Locked</th>
551               <th>Total</th>
552               <th>Actions</th>
553             </tr>
554           </thead>
555           <tbody>
556               [% FOREACH period_active IN period_active_loop %]
557                 <tr>
558                 <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>
559                 <td><span title="[% period_active.budget_period_startdate %]">[% period_active.budget_period_startdate | $KohaDates %]</span></td>
560                 <td><span title="[% period_active.budget_period_enddate %]">[% period_active.budget_period_enddate | $KohaDates %]</span></td>
561                 <td>
562                   [% IF ( period_active.budget_period_locked ) %]
563                     <span style="color:green;">Locked</span>&nbsp;
564                   [% END %]
565                 </td>
566                 <td class="data">[% period_active.budget_period_total | $Price %]</td>
567                 <td>
568                     [% PROCESS action_menu block_budget_id=period_active.budget_period_id %]
569                 </td>
570                 </tr>
571               [% END %]
572           </tbody>
573         </table>
574       [% ELSE %]
575         No active budgets
576       [% END %]
577       <div class="paginationBar">[% active_pagination_bar %]</div>
578     </div>
579     <div id="inactive">
580       [% IF ( period_inactive_loop ) %]
581         <table id="inactiveperiodst">
582           <thead>
583               <tr>
584                   <th>Budget name</th>
585                   <th class="title-string">Start date</th>
586                   <th class="title-string">End date</th>
587                   <th>Locked</th>
588                   <th>Total</th>
589                   <th>Actions</th>
590               </tr>
591           </thead>
592           <tbody>
593               [% FOREACH period_loo IN period_inactive_loop %]
594                   <tr>
595                   <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>
596                   <td><span title="[% period_loo.budget_period_startdate %]">[% period_loo.budget_period_startdate | $KohaDates %]</span></td>
597                   <td><span title="[% period_loo.budget_period_enddate %]">[% period_loo.budget_period_enddate | $KohaDates %]</span></td>
598                   <td> [% IF ( period_loo.budget_period_locked ) %]<span style="color:green;">Locked</span>&nbsp;[% ELSE %][% END %] </td>
599                   <td class="data">[% period_loo.budget_period_total | $Price %]</td>
600                   <td>
601                         [% PROCESS action_menu block_budget_id=period_loo.budget_period_id %]
602                   </td>
603                   </tr>
604               [% END %]
605           </tbody>
606         </table>
607       [% ELSE %]
608         No inactive budgets
609       [% END %]
610       <div class="pages">[% inactive_pagination_bar %]</div>
611     </div>
612   </div>
613 [% END %]
614
615
616 </div>
617 </div>
618 <div class="yui-b">
619 [% INCLUDE 'acquisitions-menu.inc' %]
620 </div>
621 </div>
622
623 [% INCLUDE 'intranet-bottom.inc' %]