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

(-)a/koha-tmpl/opac-tmpl/prog/en/includes/opac-topissues.inc (-2 / +2 lines)
Lines 15-23 Link Here
15
				<li>
15
				<li>
16
               <label for="branch">From: </label>
16
               <label for="branch">From: </label>
17
                <select name="branch" id="branch" style="width: 10em;">
17
                <select name="branch" id="branch" style="width: 10em;">
18
                <option value="">All libraries</option>
18
                <option value="__ANY__">All libraries</option>
19
                [% FOREACH branchloo IN branchloop %]
19
                [% FOREACH branchloo IN branchloop %]
20
                    [% IF ( branch == branchname ) %]<option value="[% branchloo.value %]" selected="selected">[% ELSE %]<option value="[% branchloo.value %]">[% END %]
20
                    [% IF ( branchloo.selected ) %]<option value="[% branchloo.value %]" selected="selected">[% ELSE %]<option value="[% branchloo.value %]">[% END %]
21
                        [% branchloo.branchname %]
21
                        [% branchloo.branchname %]
22
                    </option>
22
                    </option>
23
                [% END %]
23
                [% END %]
(-)a/koha-tmpl/opac-tmpl/prog/en/modules/opac-topissues.tt (-1 / +1 lines)
Lines 100-106 function Dopop(link) { Link Here
100
				<li>
100
				<li>
101
               <label for="branch">From: </label>
101
               <label for="branch">From: </label>
102
                <select name="branch" id="branch">
102
                <select name="branch" id="branch">
103
                <option value="">All libraries</option>
103
                <option value="__ANY__">All libraries</option>
104
                [% FOREACH branchloo IN branchloop %]
104
                [% FOREACH branchloo IN branchloop %]
105
                    [% IF ( branchloo.selected ) %]
105
                    [% IF ( branchloo.selected ) %]
106
                        <option value="[% branchloo.value %]" selected="selected">[% branchloo.branchname %]</option>
106
                        <option value="[% branchloo.value %]" selected="selected">[% branchloo.branchname %]</option>
(-)a/opac/opac-topissues.pl (-3 / +5 lines)
Lines 53-59 my ($template, $borrowernumber, $cookie) Link Here
53
my $dbh = C4::Context->dbh;
53
my $dbh = C4::Context->dbh;
54
# Displaying results
54
# Displaying results
55
my $limit = $input->param('limit') || 10;
55
my $limit = $input->param('limit') || 10;
56
my $branch = $input->param('branch') || '';
56
my $branch_input = $input->param('branch') || '';
57
my $branch = $branch_input eq '__ANY__' ? '' : $branch_input ; # __ANY__ is used to distinguish form display and no branch filter selected
57
my $itemtype = $input->param('itemtype') || '';
58
my $itemtype = $input->param('itemtype') || '';
58
my $timeLimit = $input->param('timeLimit') || 3;
59
my $timeLimit = $input->param('timeLimit') || 3;
59
my $advanced_search_types = C4::Context->preference('AdvancedSearchTypes');
60
my $advanced_search_types = C4::Context->preference('AdvancedSearchTypes');
Lines 129-135 $template->param(do_it => 1, Link Here
129
                results_loop => \@results,
130
                results_loop => \@results,
130
                );
131
                );
131
132
132
$template->param( branchloop => GetBranchesLoop(C4::Context->userenv?C4::Context->userenv->{'branch'}:''));
133
# GetBranchesLoop without parameter will select user default branch
134
my $branchloop = $branch_input ? GetBranchesLoop($branch_input) : GetBranchesLoop();
135
$template->param( branchloop => $branchloop );
133
136
134
# the index parameter is different for item-level itemtypes
137
# the index parameter is different for item-level itemtypes
135
my $itype_or_itemtype = (C4::Context->preference("item-level_itypes"))?'itype':'itemtype';
138
my $itype_or_itemtype = (C4::Context->preference("item-level_itypes"))?'itype':'itemtype';
136
- 

Return to bug 10588