Bugzilla – Attachment 37191 Details for
Bug 3969
Budget Search Doesn't Work
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 3969: Fix funds search
Bug-3969-Fix-funds-search.patch (text/plain), 4.20 KB, created by
Jonathan Druart
on 2015-03-24 16:33:45 UTC
(
hide
)
Description:
Bug 3969: Fix funds search
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2015-03-24 16:33:45 UTC
Size:
4.20 KB
patch
obsolete
>From 345b0c722857587483a54b3c25946bb75ba7c7bf Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@biblibre.com> >Date: Tue, 24 Mar 2015 17:30:02 +0100 >Subject: [PATCH] Bug 3969: Fix funds search > >The funds search does not work at all. >On the budget and the budget plan page, the library dropdown list is >empty. > >Test plan: >On the budget, the budget plan and the fund pages, confirm that you are >able to search a fund by code (or name) and the library dropdown list is >correctly filled. >--- > admin/aqbudgetperiods.pl | 3 +++ > admin/aqbudgets.pl | 18 ++++++------------ > admin/aqplan.pl | 4 +++- > 3 files changed, 12 insertions(+), 13 deletions(-) > >diff --git a/admin/aqbudgetperiods.pl b/admin/aqbudgetperiods.pl >index 94f77e7..3731cf6 100755 >--- a/admin/aqbudgetperiods.pl >+++ b/admin/aqbudgetperiods.pl >@@ -287,6 +287,8 @@ $url = "aqbudgetperiods.pl?tab=2"; > $url .= "&apage=$activepage" if($activepage != 1); > my $inactive_pagination_bar = pagination_bar ($url, getnbpages( scalar(@$results), $inactivepagesize), $inactivepage, "ipage"); > >+my $branchloop = C4::Branch::GetBranchesLoop(); >+ > my $tab = $input->param('tab') ? $input->param('tab') - 1 : 0; > $template->param( > period_active_loop => \@period_active_loop, >@@ -294,6 +296,7 @@ $template->param( > active_pagination_bar => $active_pagination_bar, > inactive_pagination_bar => $inactive_pagination_bar, > tab => $tab, >+ branchloop => $branchloop, > ); > > $template->param($op=>1); >diff --git a/admin/aqbudgets.pl b/admin/aqbudgets.pl >index f1c2f39..0cf3c61 100755 >--- a/admin/aqbudgets.pl >+++ b/admin/aqbudgets.pl >@@ -100,16 +100,7 @@ $template->param( > > my $budget; > >-my $branches = GetBranches($show_mine); >-my @branchloop2; >-foreach my $thisbranch (keys %$branches) { >- my %row = ( >- value => $thisbranch, >- branchname => $branches->{$thisbranch}->{'branchname'}, >- ); >- $row{selected} = 1 if $thisbranch eq $filter_budgetbranch; >- push @branchloop2, \%row; >-} >+my $branchloop = C4::Branch::GetBranchesLoop($filter_budgetbranch); > > $template->param(auth_cats_loop => GetBudgetAuthCats( $budget_period_id )) > if $budget_period_id; >@@ -284,6 +275,7 @@ if ( $op eq 'list' ) { > > #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 ? > >+ my @budgets_to_display; > foreach my $budget (@budgets) { > # PERMISSIONS > unless(CanUserModifyBudget($borrowernumber, $budget, $staffflags)) { >@@ -335,6 +327,7 @@ if ( $op eq 'list' ) { > $budget->{budget_hierarchy} = \@budget_hierarchy; > > $budget->{budget_has_children} = BudgetHasChildren( $budget->{budget_id} ); >+ push @budgets_to_display, $budget; > } > > my $budget_period_total = $period->{budget_period_total}; >@@ -343,14 +336,15 @@ if ( $op eq 'list' ) { > > $template->param( > op => 'list', >- budgets => \@budgets, >+ budgets => \@budgets_to_display, > periods => $periods, > budget_period_total => $budget_period_total, > period_alloc_total => $period_alloc_total, > spent_total => $spent_total, > ordered_total => $ordered_total, > available_total => $available_total, >- branchloop => \@branchloop2, >+ branchloop => $branchloop, >+ filter_budgetname => $filter_budgetname, > ); > > } #---- END list >diff --git a/admin/aqplan.pl b/admin/aqplan.pl >index e792ca2..20a5f12 100755 >--- a/admin/aqplan.pl >+++ b/admin/aqplan.pl >@@ -404,7 +404,8 @@ if ( $output eq "file" ) { > exit(1); > } > >-$template->param( >+my $branchloop = C4::Branch::GetBranchesLoop(); >+$template->aaram( > authvals_row => \@authvals_row, > budget_lines => \@budget_lines, > budget_period_description => $period->{'budget_period_description'}, >@@ -420,6 +421,7 @@ $template->param( > > authvals => \@authvals_row, > hide_cols_loop => \@hide_cols >+ branchloop => $branchloop, > ); > > output_html_with_http_headers $input, $cookie, $template->output; >-- >2.1.0
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 3969
:
6100
|
9198
|
9199
|
9202
|
9203
|
37191
|
37204
|
37206
|
37250