View | Details | Raw Unified | Return to bug 3969
Collapse All | Expand All

(-)a/admin/aqbudgetperiods.pl (+3 lines)
Lines 287-292 $url = "aqbudgetperiods.pl?tab=2"; Link Here
287
$url .= "&apage=$activepage" if($activepage != 1);
287
$url .= "&apage=$activepage" if($activepage != 1);
288
my $inactive_pagination_bar = pagination_bar ($url, getnbpages( scalar(@$results), $inactivepagesize), $inactivepage, "ipage");
288
my $inactive_pagination_bar = pagination_bar ($url, getnbpages( scalar(@$results), $inactivepagesize), $inactivepage, "ipage");
289
289
290
my $branchloop = C4::Branch::GetBranchesLoop();
291
290
my $tab = $input->param('tab') ? $input->param('tab') - 1 : 0;
292
my $tab = $input->param('tab') ? $input->param('tab') - 1 : 0;
291
$template->param(
293
$template->param(
292
    period_active_loop      => \@period_active_loop,
294
    period_active_loop      => \@period_active_loop,
Lines 294-299 $template->param( Link Here
294
    active_pagination_bar   => $active_pagination_bar,
296
    active_pagination_bar   => $active_pagination_bar,
295
    inactive_pagination_bar => $inactive_pagination_bar,
297
    inactive_pagination_bar => $inactive_pagination_bar,
296
    tab                     => $tab,
298
    tab                     => $tab,
299
    branchloop              => $branchloop,
297
);
300
);
298
301
299
$template->param($op=>1);
302
$template->param($op=>1);
(-)a/admin/aqbudgets.pl (-12 / +6 lines)
Lines 100-115 $template->param( Link Here
100
100
101
my $budget;
101
my $budget;
102
102
103
my $branches = GetBranches($show_mine);
103
my $branchloop = C4::Branch::GetBranchesLoop($filter_budgetbranch);
104
my @branchloop2;
105
foreach my $thisbranch (keys %$branches) {
106
    my %row = (
107
        value      => $thisbranch,
108
        branchname => $branches->{$thisbranch}->{'branchname'},
109
    );
110
    $row{selected} = 1 if $thisbranch eq $filter_budgetbranch;
111
    push @branchloop2, \%row;
112
}
113
104
114
$template->param(auth_cats_loop => GetBudgetAuthCats( $budget_period_id ))
105
$template->param(auth_cats_loop => GetBudgetAuthCats( $budget_period_id ))
115
    if $budget_period_id;
106
    if $budget_period_id;
Lines 284-289 if ( $op eq 'list' ) { Link Here
284
275
285
	#This Looks WEIRD to me : should budgets be filtered in such a way ppl who donot own it would not see the amount spent on the budget by others ?
276
	#This Looks WEIRD to me : should budgets be filtered in such a way ppl who donot own it would not see the amount spent on the budget by others ?
286
277
278
    my @budgets_to_display;
287
    foreach my $budget (@budgets) {
279
    foreach my $budget (@budgets) {
288
        # PERMISSIONS
280
        # PERMISSIONS
289
        unless(CanUserModifyBudget($borrowernumber, $budget, $staffflags)) {
281
        unless(CanUserModifyBudget($borrowernumber, $budget, $staffflags)) {
Lines 335-340 if ( $op eq 'list' ) { Link Here
335
        $budget->{budget_hierarchy} = \@budget_hierarchy;
327
        $budget->{budget_hierarchy} = \@budget_hierarchy;
336
328
337
        $budget->{budget_has_children} = BudgetHasChildren( $budget->{budget_id} );
329
        $budget->{budget_has_children} = BudgetHasChildren( $budget->{budget_id} );
330
        push @budgets_to_display, $budget;
338
    }
331
    }
339
332
340
    my $budget_period_total = $period->{budget_period_total};
333
    my $budget_period_total = $period->{budget_period_total};
Lines 343-356 if ( $op eq 'list' ) { Link Here
343
336
344
    $template->param(
337
    $template->param(
345
        op                     => 'list',
338
        op                     => 'list',
346
        budgets                => \@budgets,
339
        budgets                => \@budgets_to_display,
347
        periods                => $periods,
340
        periods                => $periods,
348
        budget_period_total    => $budget_period_total,
341
        budget_period_total    => $budget_period_total,
349
        period_alloc_total     => $period_alloc_total,
342
        period_alloc_total     => $period_alloc_total,
350
        spent_total            => $spent_total,
343
        spent_total            => $spent_total,
351
        ordered_total          => $ordered_total,
344
        ordered_total          => $ordered_total,
352
        available_total        => $available_total,
345
        available_total        => $available_total,
353
        branchloop             => \@branchloop2,
346
        branchloop             => $branchloop,
347
        filter_budgetname      => $filter_budgetname,
354
    );
348
    );
355
349
356
} #---- END list
350
} #---- END list
(-)a/admin/aqplan.pl (-2 / +3 lines)
Lines 404-410 if ( $output eq "file" ) { Link Here
404
    exit(1);
404
    exit(1);
405
}
405
}
406
406
407
$template->param(
407
my $branchloop = C4::Branch::GetBranchesLoop();
408
$template->aaram(
408
    authvals_row              => \@authvals_row,
409
    authvals_row              => \@authvals_row,
409
    budget_lines              => \@budget_lines,
410
    budget_lines              => \@budget_lines,
410
    budget_period_description => $period->{'budget_period_description'},
411
    budget_period_description => $period->{'budget_period_description'},
Lines 420-425 $template->param( Link Here
420
421
421
    authvals              => \@authvals_row,
422
    authvals              => \@authvals_row,
422
    hide_cols_loop              => \@hide_cols
423
    hide_cols_loop              => \@hide_cols
424
    branchloop                => $branchloop,
423
);
425
);
424
426
425
output_html_with_http_headers $input, $cookie, $template->output;
427
output_html_with_http_headers $input, $cookie, $template->output;
426
- 

Return to bug 3969