Lines 24-29
Link Here
|
24 |
|
24 |
|
25 |
[% SET first_priority = 0 %] |
25 |
[% SET first_priority = 0 %] |
26 |
[% SET last_priority = holds.last.priority %] |
26 |
[% SET last_priority = holds.last.priority %] |
|
|
27 |
[% SET next_available_locations = "" %] |
27 |
|
28 |
|
28 |
[% FOREACH hold IN holds %] |
29 |
[% FOREACH hold IN holds %] |
29 |
[% IF !hold.found && first_priority == 0 %][% first_priority = hold.priority %][% END %] |
30 |
[% IF !hold.found && first_priority == 0 %][% first_priority = hold.priority %][% END %] |
Lines 133-139
Link Here
|
133 |
[% Branches.GetName(hold.branchcode) | html %] <input type="hidden" name="pickup" value="[% hold.branchcode | html %]" /> |
134 |
[% Branches.GetName(hold.branchcode) | html %] <input type="hidden" name="pickup" value="[% hold.branchcode | html %]" /> |
134 |
[% ELSE %] |
135 |
[% ELSE %] |
135 |
<select name="pickup"> |
136 |
<select name="pickup"> |
136 |
[% PROCESS options_for_libraries libraries => Branches.pickup_locations( { search_params => { item => hold.itemnumber, biblio => hold.biblionumber, patron => hold.patron }, selected => hold.branchcode }) %] |
137 |
[% IF !hold.itemnumber %] |
|
|
138 |
[% IF next_available_locations == "" %] |
139 |
[% SET next_available_locations = Branches.pickup_locations( { search_params => { item => hold.itemnumber, biblio => hold.biblionumber, patron => hold.patron } } ) %] |
140 |
[% END %] |
141 |
[% PROCESS options_for_libraries libraries => next_available_locations, selected => hold.branchcode %] |
142 |
[% ELSE %] |
143 |
[% PROCESS options_for_libraries libraries => Branches.pickup_locations( { search_params => { item => hold.itemnumber, biblio => hold.biblionumber, patron => hold.patron }, selected => hold.branchcode }) %] |
144 |
[% END %] |
137 |
</select> |
145 |
</select> |
138 |
[% END %] |
146 |
[% END %] |
139 |
[% END %] |
147 |
[% END %] |