}
} else {
if ($branchcode) {
push @where_strings," (budget_branchcode =? or budget_branchcode is NULL)";
push @where_strings," (budget_branchcode =? or budget_branchcode is NULL OR budget_branchcode='')";
push @bind_params, $branchcode;
my $budgets_to_move = GetBudgetHierarchy($budget_period_id);
# C4::Context->userenv->{branchcode}, $show_mine ? $borrower_id : '')
my $number_of_unreceived_orders = 0;
for my $budget (@$budgets_to_move) {
);
my @budgets = @{
GetBudgetHierarchy($$period{budget_period_id},
GetBudgetHierarchy( $$period{budget_period_id}, C4::Context->userenv->{branch}, ( $show_mine ? $borrower_id : 0 ))
C4::Context->userenv->{branchcode}, $show_mine ? $borrower_id : '')
};
my $period_total = 0;
-