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

(-)a/C4/Budgets.pm (-6 / +6 lines)
Lines 666-676 sub GetBudget { Link Here
666
    return $result;
666
    return $result;
667
}
667
}
668
668
669
=head2 GetBudgets
669
=head2 GetChildBudgetsSpent
670
670
671
  &GetBudgets($filter, $order_by);
671
  &GetChildBudgetsSpent($budget-id);
672
672
673
gets all budgets
673
gets the total spent of the level and sublevels of $budget_id
674
674
675
=cut
675
=cut
676
676
Lines 693-703 sub GetChildBudgetsSpent { Link Here
693
    return $total_spent;
693
    return $total_spent;
694
}
694
}
695
695
696
=head2 GetChildBudgetsSpent
696
=head2 GetBudgets
697
697
698
  &GetChildBudgetsSpent($budget-id);
698
  &GetBudgets($filter, $order_by);
699
699
700
gets the total spent of the level and sublevels of $budget_id
700
gets all budgets
701
701
702
=cut
702
=cut
703
703
(-)a/acqui/basket.pl (+13 lines)
Lines 291-296 if ( $op eq 'delete_confirm' ) { Link Here
291
291
292
    my $contract = &GetContract($basket->{contractnumber});
292
    my $contract = &GetContract($basket->{contractnumber});
293
    my @orders = GetOrders($basketno);
293
    my @orders = GetOrders($basketno);
294
295
    my $borrower= GetMember('borrowernumber' => $loggedinuser);
296
    my $budgets = GetBudgetHierarchy(q{},$borrower->{branchcode},$borrower->{borrowernumber});
297
    my $has_budgets = 0;
298
    foreach my $r (@{$budgets}) {
299
        if (!defined $r->{budget_amount} || $r->{budget_amount} == 0) {
300
            next;
301
        }
302
        $has_budgets = 1;
303
        last;
304
    }
305
294
    $template->param(
306
    $template->param(
295
        basketno             => $basketno,
307
        basketno             => $basketno,
296
        basketname           => $basket->{'basketname'},
308
        basketname           => $basket->{'basketname'},
Lines 321-326 if ( $op eq 'delete_confirm' ) { Link Here
321
        basketgroups         => $basketgroups,
333
        basketgroups         => $basketgroups,
322
        grouped              => $basket->{basketgroupid},
334
        grouped              => $basket->{basketgroupid},
323
        unclosable           => @orders ? 0 : 1, 
335
        unclosable           => @orders ? 0 : 1, 
336
        has_budgets          => $has_budgets,
324
    );
337
    );
325
}
338
}
326
339
(-)a/acqui/neworderempty.pl (-2 / +1 lines)
Lines 93-99 use C4::ImportBatch qw/GetImportRecordMarc SetImportRecordStatus/; Link Here
93
93
94
my $input           = new CGI;
94
my $input           = new CGI;
95
my $booksellerid    = $input->param('booksellerid');	# FIXME: else ERROR!
95
my $booksellerid    = $input->param('booksellerid');	# FIXME: else ERROR!
96
my $budget_id       = $input->param('budget_id') || 0;	# FIXME: else ERROR!
96
my $budget_id       = $input->param('budget_id') || 0;
97
my $title           = $input->param('title');
97
my $title           = $input->param('title');
98
my $author          = $input->param('author');
98
my $author          = $input->param('author');
99
my $publicationyear = $input->param('publicationyear');
99
my $publicationyear = $input->param('publicationyear');
100
- 

Return to bug 5072