aqbudget display, minor changes
- removed 2 total that means nothing (and were troubling users) - reindented a little (removed tab)
This commit is contained in:
parent
01ba63a84f
commit
c85e22ad53
|
|
@ -221,13 +221,13 @@ if ($op eq 'add_form') {
|
|||
} else {
|
||||
AddBudget( $budget_hash );
|
||||
}
|
||||
}
|
||||
}
|
||||
my $branches = GetBranches();
|
||||
my $budget_period_dropbox = GetBudgetPeriodsDropbox($$period{budget_period_id} );
|
||||
$template->param(
|
||||
budget_period_dropbox => $budget_period_dropbox,
|
||||
budget_id => $budget_id,
|
||||
%$period,
|
||||
%$period,
|
||||
);
|
||||
|
||||
my $moo = GetBudgetHierarchy($$period{budget_period_id}, C4::Context->userenv->{branchcode}, $show_mine?$borrower_id:'');
|
||||
|
|
@ -236,7 +236,7 @@ if ($op eq 'add_form') {
|
|||
my $toggle = 0;
|
||||
my @loop;
|
||||
my $period_total = 0;
|
||||
my ( $period_alloc_total, $base_alloc_total, $base_spent_total, $base_remaining_total );
|
||||
my ( $period_alloc_total, $base_spent_total );
|
||||
|
||||
use YAML;
|
||||
$debug && warn Dump(@budgets);
|
||||
|
|
@ -282,10 +282,8 @@ if ($op eq 'add_form') {
|
|||
## TOTALS
|
||||
# adds to total - only if budget is a 'top-level' budget
|
||||
$period_alloc_total += $budget->{'budget_amount_total'} if $budget->{'depth'} == 0;
|
||||
$base_alloc_total += $budget->{'budget_amount'};
|
||||
$base_spent_total += $budget->{'budget_spent'};
|
||||
$budget->{'budget_remaining'} = $budget->{'budget_amount'} - $budget->{'budget_spent'};
|
||||
$base_remaining_total += $budget->{'budget_remaining'};
|
||||
|
||||
# if amount == 0 dont display...
|
||||
delete $budget->{'budget_unalloc_sublevel'} if $budget->{'budget_unalloc_sublevel'} == 0 ;
|
||||
|
|
@ -312,10 +310,7 @@ if ($op eq 'add_form') {
|
|||
budget => \@loop,
|
||||
budget_period_total => $budget_period_total,
|
||||
period_alloc_total => $num->format_price($period_alloc_total),
|
||||
base_alloc_total => $num->format_price($base_alloc_total),
|
||||
base_spent_total => $num->format_price($base_spent_total),
|
||||
base_remaining_total => $num->format_price($base_remaining_total),
|
||||
period_remaining_total => $num->format_price( $period_alloc_total - $base_alloc_total ),
|
||||
branchloop => \@branchloop2,
|
||||
);
|
||||
|
||||
|
|
|
|||
|
|
@ -7,8 +7,8 @@
|
|||
<!-- TMPL_IF name="add_form" -->
|
||||
<script type="text/javascript">
|
||||
//<![CDATA[
|
||||
|
||||
var actTotal ="";
|
||||
//
|
||||
var actTotal ="";
|
||||
|
||||
function ownerRemove(f) {
|
||||
document.getElementById('budget_owner_name').innerHTML = '';
|
||||
|
|
@ -164,9 +164,6 @@
|
|||
<th>Base-level<br />spent</th>
|
||||
<th>Base-level<br />remaining</th>
|
||||
<th class="tooltipcontent"> </th>
|
||||
<!-- Owner</th>
|
||||
<th>Branch</th>
|
||||
<th>Note</th> -->
|
||||
<th>Actions</th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
|
@ -213,7 +210,7 @@
|
|||
</tr>
|
||||
<!-- /TMPL_LOOP -->
|
||||
<!-- TMPL_ELSE -->
|
||||
<tr><td colspan="9">No budget found</td></tr>
|
||||
<tr><td colspan="12">No budget found</td></tr>
|
||||
<!-- /TMPL_IF -->
|
||||
</tbody>
|
||||
</table>
|
||||
|
|
@ -241,6 +238,7 @@
|
|||
<li>
|
||||
<span class="label">Budget Parent: </span>
|
||||
<!-- TMPL_VAR NAME="budget_parent_name" -->
|
||||
<!-- TMPL_VAR NAME="budget_parent_id" --> - <!-- TMPL_VAR NAME="budget_parent_name" -->
|
||||
<input type="hidden" name="budget_parent_id" value="<!-- TMPL_VAR NAME="budget_parent_id" -->" />
|
||||
</li>
|
||||
<!-- /TMPL_IF -->
|
||||
|
|
|
|||
Loading…
Reference in New Issue