2 [% INCLUDE 'doc-head-open.inc' %]
3 <title>Koha › Acquisitions</title>
4 [% INCLUDE 'doc-head-close.inc' %]
5 <link rel="stylesheet" type="text/css" href="[% themelang %]/css/datatables.css" />
6 [% INCLUDE 'datatables.inc' %]
7 <link href="[% interface %]/lib/jquery/plugins/treetable/stylesheets/jquery.treetable.css" rel="stylesheet" type="text/css" />
8 <script type="text/javascript" src="[% interface %]/lib/jquery/plugins/treetable/jquery.treetable.js"></script>
10 <script type="text/javascript">
13 dt_overwrite_html_sorting_localeCompare();
15 $(document).ready(function() {
17 var inactive = $(".b_inactive,.bu_active");
18 var active = $(".bu_inactive");
22 var oTable = $("#accounts").dataTable($.extend(true, {}, dataTablesDefaults, {
23 "fnDrawCallback": function ( oSettings ) {
24 if ( oSettings.aiDisplay.length == 0 )
29 var nTrs = $('#accounts tbody tr');
30 var iColspan = nTrs[0].getElementsByTagName('td').length;
32 for ( var i=0 ; i<nTrs.length ; i++ )
34 var iDisplayIndex = oSettings._iDisplayStart + i;
35 var sGroup = oSettings.aoData[ oSettings.aiDisplay[iDisplayIndex] ]._aData[1];
36 if ( sGroup != sLastGroup )
38 var nGroup = document.createElement( 'tr' );
39 var nCell = document.createElement( 'td' );
40 nCell.colSpan = iColspan;
41 nCell.className = "group";
42 nCell.innerHTML = sGroup;
43 nGroup.appendChild( nCell );
44 nTrs[i].parentNode.insertBefore( nGroup, nTrs[i] );
50 { "bVisible": false, "aTargets": [ 0, 1 ] },
51 { "bSortable": false, "aTargets": ["_all"] }
54 'aaSortingFixed': [[ 1, 'asc' ]],
62 $(oTable).treetable('expandAll');
63 $("#expand_all").click(function(e){
65 $(oTable).treetable('expandAll');
67 $("#collapse_all").click(function(e){
69 $(oTable).treetable('collapseAll');
72 $("#hide_inactive").click(function(e){
74 oTable.fnFilter( 1, 0 ); // Show only active=1
78 $("#show_inactive").click(function(e){
80 oTable.fnFilter( '', 0 );
84 $("#hide_inactive").click();
91 <body id="acq_acqui-home" class="acq">
92 [% INCLUDE 'header.inc' %]
93 [% INCLUDE 'acquisitions-search.inc' %]
95 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> › <a href="/cgi-bin/koha/acqui/acqui-home.pl">Acquisitions</a> › </div>
97 <div id="doc3" class="yui-t2">
103 [% INCLUDE 'acquisitions-toolbar.inc' %]
105 <h1>Acquisitions</h1>
106 [% UNLESS ( loop_budget ) %]
107 [% IF ( CAN_user_acquisition_period_manage ) %]
108 <div class="dialog alert">You must <a href="/cgi-bin/koha/admin/aqbudgetperiods.pl">define a budget</a> in Administration</div>
110 <div class="dialog alert">Your administrator must define a budget in Administration</div>
114 <div class="yui-u first">
115 <div id="acqui_acqui_home_order">
117 <legend>Manage orders</legend>
118 <form name="findsupplier" action="/cgi-bin/koha/acqui/booksellers.pl" method="post">
119 <p><label for="supplierpage">Vendor: </label><input type="text" size="25" name="supplier" id="supplierpage" class="focus" />
120 <input type="submit" value="Search" />
127 [% IF ( suggestion && suggestions_count ) %]
129 <div id="acqui_acqui_home_suggestions">
131 <legend>Pending suggestions</legend>
132 <p>[% suggestions_count %] suggestions waiting. <a href="/cgi-bin/koha/suggestion/suggestion.pl">Manage suggestions</a>.</p>
140 [% IF ( loop_budget ) %]
142 <h3>All available funds[% IF ( branchname ) %] for [% branchname %][% END %]</h3>
144 <div id="BudgetsAndFunds">
145 <table id="accounts">
147 <span class="actions"><a href="#" id="expand_all">Expand all</a>
148 | <a href="#" id="collapse_all">Collapse all</a>
149 | <a href="#" id="hide_inactive">Hide inactive budgets</a>
150 | <a href="#" id="show_inactive">Show inactive budgets</a></span>
156 <th>Budget period description</th>
164 <th>Total available</th>
167 <tfoot id="funds_total">
171 <th colspan="4">Total</th>
172 <th class="data"><span class="bu_active">[% total %]</span><span class="bu_inactive" >[% total_active | $Price %]</span></th>
173 <th class="data"><span class="bu_active">[% totordered %]</span><span class="bu_inactive" >[% totordered_active | $Price %]</span></th>
174 <th class="data"><span class="bu_active">[% totspent %]</span><span class="bu_inactive" >[% totspent_active | $Price %]</span></th>
175 <th class="data"><span class="bu_active">[% totavail %]</span><span class="bu_inactive" >[% totavail_active | $Price %]</span></th>
179 [% FOREACH loop_budge IN loop_budget %]
180 [% IF loop_budge.budget_parent_id %]
181 <tr data-tt-id="[% loop_budge.budget_id %]" data-tt-parent-id="[% loop_budge.budget_parent_id %]">
183 <tr data-tt-id="[% loop_budge.budget_id %]">
186 <td>[% loop_budge.budget_period_active %]</td>
187 <td>Budget [% loop_budge.budget_period_description %] [id=[% loop_budge.budget_period_id %]][% UNLESS loop_budge.budget_period_active %] (inactive)[% END %]</td>
189 [% IF ( CAN_user_acquisition_budget_manage ) %]
190 <a href="/cgi-bin/koha/admin/aqbudgets.pl?budget_period_id=[% loop_budge.budget_period_id %]">[% loop_budge.budget_code %]</a>
192 [% loop_budge.budget_code %]
195 <td>[% loop_budge.budget_name %]</td>
196 <td>[% IF ( loop_budge.budget_owner_borrowernumber ) %]
197 <a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% loop_budge.budget_owner_borrowernumber %]">[% loop_budge.budget_owner_surname %], [% loop_budge.budget_owner_firstname %]</a>
202 <td>[% loop_budge.budget_branchname %]</td>
203 <td class="data"><span title="[% loop_budge.budget_amount %]">[% loop_budge.budget_amount | $Price %]</span></td>
204 <td class="data"><span title="[% loop_budge.budget_ordered %]"><a href="ordered.pl?fund=[% loop_budge.budget_id %]&fund_code=[% loop_budge.budget_code %]">[% loop_budge.budget_ordered | $Price %]</a></span></td>
205 <td class="data"><span title="[% loop_budge.budget_spent %]"><a href="spent.pl?fund=[% loop_budge.budget_id %]&fund_code=[% loop_budge.budget_code %]">[% loop_budge.budget_spent | $Price %]</span></a></td>
206 <td class="data"><span title="[% loop_budge.budget_avail %]">[% loop_budge.budget_avail | $Price %]</td>
217 [% INCLUDE 'acquisitions-menu.inc' %]
220 [% INCLUDE 'intranet-bottom.inc' %]