Bug 24786: Update paycollect to use session register
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / includes / html_helpers.inc
1 [% BLOCK options_for_libraries %]
2     [% FOREACH l IN libraries %]
3         [% IF l.selected %]
4             <option value="[% prefix | html %][% l.branchcode | html %]" selected="selected">[% l.branchname | html %]</option>
5         [% ELSE %]
6             <option value="[% prefix | html %][% l.branchcode | html %]">[% l.branchname | html %]</option>
7         [% END%]
8     [% END %]
9 [% END %]
10
11 [% BLOCK options_for_desks %]
12     <option id="nodesk" value="">---</option>
13     [% FOREACH d IN desks %]
14         [% IF d.branchcode == branch %]
15           [% IF selected == d.desk_id %]
16             <option class="[% d.branchcode | html %]" value="[% d.desk_id | html %]" selected="selected">[% d.desk_name | html %]</option>
17           [% ELSE %]
18             <option class="[% d.branchcode | html %]" value="[% d.desk_id | html %]" >[% d.desk_name | html %]</option>
19           [% END %]
20         [% ELSE %]
21             <option class="[% d.branchcode | html %]" value="[% d.desk_id | html %]" disabled hidden>[% d.desk_name | html %]</option>
22         [% END %]
23     [% END %]
24 [% END %]
25
26 [% BLOCK options_for_registers %]
27     <option id="noregister"[% IF register_required %] disabled [% END %] selected="selected" value="">[% IF register_required %]-- Select an option--[% ELSE %]-- None --[% END %]</option>
28     [% FOREACH r IN registers %]
29         [% IF r.branch == Branches.GetLoggedInBranchcode %]
30             [% IF r.selected %]
31                 <option class="[% r.branch | html %] [% IF r.branch_default %]default[% END %]" value="[% r.id | html %]" selected="selected">[% r.name | html %]</option>
32             [% ELSE %]
33                 <option class="[% r.branch | html %] [% IF r.branch_default %]default[% END %]" value="[% r.id | html %]">[% r.name | html %]</option>
34             [% END%]
35         [% ELSE %]
36             <option class="[% r.branch | html %] [% IF r.branch_default %]default[% END %]" value="[% r.id | html %]" disabled hidden>[% r.name | html %]</option>
37         [% END %]
38     [% END %]
39 [% END %]
40
41 [% BLOCK options_for_authorised_value_categories %]
42     [% FOREACH avc IN authorised_value_categories %]
43         [% IF avc.selected %]
44             <option value="[% avc.category | html %]" selected="selected">[% avc.category | html %]</option>
45         [% ELSE %]
46             <option value="[% avc.category | html %]">[% avc.category | html %]</option>
47         [% END %]
48     [% END %]
49 [% END %]
50
51 [% BLOCK options_for_item_types %]
52     [% FOREACH itemtype IN itemtypes %]
53         [% IF itemtype.itemtype == selected_itemtype %]
54             <option value="[% itemtype.itemtype | html %]" selected="selected">
55         [% ELSE %]
56             <option value="[% itemtype.itemtype | html %]">
57         [% END %]
58             [% itemtype.translated_description | html %]
59         </option>
60     [% END %]
61 [% END %]