Lines 1-7
Link Here
|
1 |
[% USE raw %] |
1 |
[% USE raw %] |
2 |
[% USE Asset %] |
2 |
[% USE Asset %] |
|
|
3 |
[% USE TablesSettings %] |
3 |
[% SET footerjs = 1 %] |
4 |
[% SET footerjs = 1 %] |
4 |
[% SET panel_id = 0 %] |
5 |
[% SET panel_id = 0 %] |
|
|
6 |
[% USE Dumper %] |
5 |
[% BLOCK pagelist %] |
7 |
[% BLOCK pagelist %] |
6 |
<div class="pagelist"> |
8 |
<div class="pagelist"> |
7 |
<form method="post" action="/cgi-bin/koha/admin/columns_settings.pl"> |
9 |
<form method="post" action="/cgi-bin/koha/admin/columns_settings.pl"> |
Lines 11-85
Link Here
|
11 |
[% SET panel_id = panel_id + 1 %] |
13 |
[% SET panel_id = panel_id + 1 %] |
12 |
[% IF module.keys and module.keys.size > 0 %] |
14 |
[% IF module.keys and module.keys.size > 0 %] |
13 |
[% FOR pagename IN module.keys %] |
15 |
[% FOR pagename IN module.keys %] |
14 |
<h5>[% pagename | html %]</h5> |
16 |
<h5>Page [% pagename | html %]</h5> |
15 |
[% SET tables = module %] |
17 |
[% SET tables = module %] |
16 |
[% IF tables.$pagename.keys and tables.$pagename.keys.size > 0 %] |
18 |
[% IF tables.$pagename.keys and tables.$pagename.keys.size > 0 %] |
17 |
[% FOR tablename IN tables.$pagename.keys.sort %] |
19 |
[% FOR tablename IN tables.$pagename.keys.sort %] |
18 |
[% IF pagename == 'additem' AND tablename == 'itemst' %] |
20 |
[% SET table_id = pagename _ '#' _ tablename %] |
19 |
<div class="alert">Changes made below will only apply to item subfields that are mapped to the 'items' table. <a href="/cgi-bin/koha/admin/koha2marclinks.pl?tablename=items">Go to Koha to MARC mapping</a></div> |
21 |
<div class="datatable_config" id="[% table_id | html %]" style="border:1px solid #7EA6B2; padding: 1em;"> |
20 |
[% END %] |
22 |
<input type="hidden" name="table_id" value="[% table_id| html %]" /> |
21 |
<table> |
23 |
[% IF pagename == 'additem' AND tablename == 'itemst' %] |
22 |
<caption> |
24 |
<div class="alert">Changes made below will only apply to item subfields that are mapped to the 'items' table. <a href="/cgi-bin/koha/admin/koha2marclinks.pl?tablename=items">Go to Koha to MARC mapping</a></div> |
23 |
[% IF tablename == 'currencies-table' %] |
25 |
[% END %] |
24 |
Currency |
26 |
<table> |
25 |
[% ELSIF pagename == 'additem' AND tablename == 'itemst' %] |
27 |
<caption> |
26 |
Items Editor |
28 |
[% IF tablename == 'currencies-table' %] |
27 |
[% END %] |
29 |
Currency |
28 |
(id=[% tablename | html %]) |
30 |
[% ELSIF pagename == 'additem' AND tablename == 'itemst' %] |
29 |
</caption> |
31 |
Items Editor |
30 |
<thead> |
32 |
[% END %] |
31 |
<tr> |
33 |
(id=[% tablename | html %]) |
32 |
<th>Column name</th> |
34 |
</caption> |
33 |
<th>Is hidden by default</th> |
35 |
<thead> |
34 |
<th>Cannot be toggled</th> |
|
|
35 |
</tr> |
36 |
</thead> |
37 |
<tbody> |
38 |
[% FOR column IN tables.$pagename.$tablename %] |
39 |
[% SET value = pagename _ '#' _ tablename _ '#' _ column.columnname %] |
40 |
<tr> |
36 |
<tr> |
41 |
<td> |
37 |
<th>Column name</th> |
42 |
[% column.columnname | html %] |
38 |
<th>Is hidden by default</th> |
43 |
<input type="hidden" name="columnid" value="[% value | html %]" /> |
39 |
<th>Cannot be toggled</th> |
44 |
</td> |
40 |
</tr> |
45 |
<td> |
41 |
</thead> |
46 |
[% IF column.is_hidden %] |
42 |
<tbody> |
47 |
[% IF column.cannot_be_modified %] |
43 |
[% FOR column IN tables.$pagename.$tablename.columns %] |
48 |
<input type="checkbox" name="[% value | html %]_hidden" value="1" checked="checked" disabled="disabled" /> |
44 |
[% SET value = pagename _ '#' _ tablename _ '#' _ column.columnname %] |
49 |
<input type="hidden" name="[% value | html %]_hidden" value="1" /> |
45 |
<tr> |
50 |
[% ELSE %] |
46 |
<td> |
51 |
<input type="checkbox" name="[% value | html %]_hidden" value="1" checked="checked" /> |
47 |
[% column.columnname | html %] |
52 |
[% END %] |
48 |
<input type="hidden" name="columnid" value="[% value | html %]" /> |
53 |
[% ELSE %] |
49 |
</td> |
54 |
[% IF column.cannot_be_modified %] |
50 |
<td> |
55 |
<input type="checkbox" name="[% value | html %]_hidden" value="1" disabled="disabled" /> |
51 |
[% IF column.is_hidden %] |
56 |
<input type="hidden" name="[% value | html %]_hidden" value="0" /> |
52 |
[% IF column.cannot_be_modified %] |
|
|
53 |
<input type="checkbox" name="[% value | html %]_hidden" value="1" checked="checked" disabled="disabled" /> |
54 |
<input type="hidden" name="[% value | html %]_hidden" value="1" /> |
55 |
[% ELSE %] |
56 |
<input type="checkbox" name="[% value | html %]_hidden" value="1" checked="checked" /> |
57 |
[% END %] |
57 |
[% ELSE %] |
58 |
[% ELSE %] |
58 |
<input type="checkbox" name="[% value | html %]_hidden" value="1" /> |
59 |
[% IF column.cannot_be_modified %] |
|
|
60 |
<input type="checkbox" name="[% value | html %]_hidden" value="1" disabled="disabled" /> |
61 |
<input type="hidden" name="[% value | html %]_hidden" value="0" /> |
62 |
[% ELSE %] |
63 |
<input type="checkbox" name="[% value | html %]_hidden" value="1" /> |
64 |
[% END %] |
59 |
[% END %] |
65 |
[% END %] |
60 |
[% END %] |
66 |
</td> |
61 |
</td> |
67 |
<td> |
62 |
<td> |
68 |
[% IF column.cannot_be_toggled %] |
63 |
[% IF column.cannot_be_toggled %] |
69 |
[% IF column.cannot_be_modified %] |
64 |
[% IF column.cannot_be_modified %] |
70 |
<input type="checkbox" name="[% value | html %]_cannot_be_toggled" value="1" checked="checked" disabled="disabled" /> |
65 |
<input type="checkbox" name="[% value | html %]_cannot_be_toggled" value="1" checked="checked" disabled="disabled" /> |
71 |
<input type="hidden" name="[% value | html %]_cannot_be_toggled" value="1" /> |
66 |
<input type="hidden" name="[% value | html %]_cannot_be_toggled" value="1" /> |
72 |
[% ELSE %] |
|
|
73 |
<input type="checkbox" name="[% value | html %]_cannot_be_toggled" value="1" checked="checked" /> |
74 |
[% END %] |
67 |
[% ELSE %] |
75 |
[% ELSE %] |
68 |
<input type="checkbox" name="[% value | html %]_cannot_be_toggled" value="1" checked="checked" /> |
76 |
[% IF column.cannot_be_modified %] |
|
|
77 |
<input type="checkbox" name="[% value | html %]_cannot_be_toggled" value="1" disabled="disabled" /> |
78 |
<input type="hidden" name="[% value | html %]_cannot_be_toggled" value="0" /> |
79 |
[% ELSE %] |
80 |
<input type="checkbox" name="[% value | html %]_cannot_be_toggled" value="1" /> |
81 |
[% END %] |
69 |
[% END %] |
82 |
[% END %] |
|
|
83 |
</td> |
84 |
</tr> |
85 |
[% END %] |
86 |
</tbody> |
87 |
</table> |
88 |
[% SET table_settings = TablesSettings.GetTableSettings( modulename, pagename, tablename ) %] |
89 |
[% IF table_settings.default_display_length %] |
90 |
<p> |
91 |
Default display length: |
92 |
<select name="[% table_id | html %]_default_display_length"> |
93 |
[% IF table_settings.default_display_length == 10 %] |
94 |
<option value="10" selected="selected">10</option> |
95 |
[% ELSE %] |
96 |
[% END %] |
97 |
[% IF table_settings.default_display_length == 20 %] |
98 |
<option value="20" selected="selected">20</option> |
99 |
[% ELSE %] |
100 |
<option value="20">20</option> |
101 |
[% END %] |
102 |
[% IF table_settings.default_display_length == 50 %] |
103 |
<option value="50" selected="selected">50</option> |
104 |
[% ELSE %] |
105 |
<option value="50">50</option> |
106 |
[% END %] |
107 |
[% IF table_settings.default_display_length == 100 %] |
108 |
<option value="100" selected="selected">100</option> |
109 |
[% ELSE %] |
110 |
<option value="100">100</option> |
111 |
[% END %] |
112 |
[% IF table_settings.default_display_length == -1 %] |
113 |
<option value="-1" selected="selected">All</option> |
114 |
[% ELSE %] |
115 |
<option value="-1">All</option> |
116 |
[% END %] |
117 |
</select> |
118 |
</p> |
119 |
[% END %] |
120 |
[% IF table_settings.default_sort_order.defined %] |
121 |
<p> |
122 |
Default sort order: |
123 |
<select name="[% pagename | html %]#[% tablename | html %]_default_sort_order"> |
124 |
[% FOR column IN tables.$pagename.$tablename.columns %] |
125 |
[% IF table_settings.default_sort_order == loop.count - 1 %] |
126 |
<option value="[% loop.count - 1 %]" selected="selected">[% column.columnname | html %]</option> |
70 |
[% ELSE %] |
127 |
[% ELSE %] |
71 |
[% IF column.cannot_be_modified %] |
128 |
<option value="[% loop.count - 1 %]">[% column.columnname | html %]</option> |
72 |
<input type="checkbox" name="[% value | html %]_cannot_be_toggled" value="1" disabled="disabled" /> |
|
|
73 |
<input type="hidden" name="[% value | html %]_cannot_be_toggled" value="0" /> |
74 |
[% ELSE %] |
75 |
<input type="checkbox" name="[% value | html %]_cannot_be_toggled" value="1" /> |
76 |
[% END %] |
77 |
[% END %] |
129 |
[% END %] |
78 |
</td> |
130 |
[% END %] |
79 |
</tr> |
131 |
</select> |
80 |
[% END %] |
132 |
</p> |
81 |
</tbody> |
133 |
[% END %] |
82 |
</table> |
134 |
|
|
|
135 |
</div> |
83 |
[% END %] |
136 |
[% END %] |
84 |
<input type="submit" value="Save" /> |
137 |
<input type="submit" value="Save" /> |
85 |
[% ELSE %] |
138 |
[% ELSE %] |