|
Lines 11-17
Link Here
|
| 11 |
</head> |
11 |
</head> |
| 12 |
|
12 |
|
| 13 |
[% marcfield_tables = ['subscription'] %] |
13 |
[% marcfield_tables = ['subscription'] %] |
|
|
14 |
[% searchable_tables = ['subscription', 'aqbasket'] %] |
| 14 |
[% show_marcfield = marcfield_tables.grep('^' _ tablename _ '$').size ? 1 : 0 %] |
15 |
[% show_marcfield = marcfield_tables.grep('^' _ tablename _ '$').size ? 1 : 0 %] |
|
|
16 |
[% show_searchable = searchable_tables.grep('^' _ tablename _ '$').size ? 1 : 0 %] |
| 15 |
|
17 |
|
| 16 |
<body id="ser_add_fields" class="ser"> |
18 |
<body id="ser_add_fields" class="ser"> |
| 17 |
[% INCLUDE 'header.inc' %] |
19 |
[% INCLUDE 'header.inc' %] |
|
Lines 101-107
Link Here
|
| 101 |
[% END %] |
103 |
[% END %] |
| 102 |
|
104 |
|
| 103 |
[% IF op == 'list_tables' %] |
105 |
[% IF op == 'list_tables' %] |
| 104 |
[% IF CAN_user_acquisitions_order_manage || CAN_user_serials_edit_subscription %] |
106 |
[% IF CAN_user_acquisitions_order_manage || CAN_user_serials_edit_subscription || CAN_user_updatecharges_remaining_permissions %] |
| 105 |
<h1>Additional fields</h1> |
107 |
<h1>Additional fields</h1> |
| 106 |
<p>Select a table:</p> |
108 |
<p>Select a table:</p> |
| 107 |
[% BLOCK table_option %] |
109 |
[% BLOCK table_option %] |
|
Lines 114-122
Link Here
|
| 114 |
[% IF CAN_user_serials_edit_subscription %] |
116 |
[% IF CAN_user_serials_edit_subscription %] |
| 115 |
[% WRAPPER table_option value="subscription" %]<span>Subscriptions</span>[% END %] |
117 |
[% WRAPPER table_option value="subscription" %]<span>Subscriptions</span>[% END %] |
| 116 |
[% END %] |
118 |
[% END %] |
|
|
119 |
[% IF CAN_user_updatecharges_remaining_permissions %] |
| 120 |
[% WRAPPER table_option value="accountlines:credit" %]Account lines (credit)[% END %] |
| 121 |
[% WRAPPER table_option value="accountlines:debit" %]Account lines (debit)[% END %] |
| 122 |
[% END %] |
| 117 |
</ul> |
123 |
</ul> |
| 118 |
[% ELSE %] |
124 |
[% ELSE %] |
| 119 |
Additional permissions in the acquisitions or serials modules are required for editing additional fields |
125 |
Additional permissions are required for editing additional fields |
| 120 |
[% END %] |
126 |
[% END %] |
| 121 |
[% ELSIF op == 'list' %] |
127 |
[% ELSIF op == 'list' %] |
| 122 |
<h1>Additional fields for '[% tablename | html %]'</h1> |
128 |
<h1>Additional fields for '[% tablename | html %]'</h1> |
|
Lines 129-135
Link Here
|
| 129 |
[% IF show_marcfield %] |
135 |
[% IF show_marcfield %] |
| 130 |
<th>MARC field</th> |
136 |
<th>MARC field</th> |
| 131 |
[% END %] |
137 |
[% END %] |
| 132 |
<th>Searchable</th> |
138 |
[% IF show_searchable %] |
|
|
139 |
<th>Searchable</th> |
| 140 |
[% END %] |
| 133 |
<th class="noExport">Actions</th> |
141 |
<th class="noExport">Actions</th> |
| 134 |
</tr> |
142 |
</tr> |
| 135 |
</thead> |
143 |
</thead> |
|
Lines 141-149
Link Here
|
| 141 |
[% IF show_marcfield %] |
149 |
[% IF show_marcfield %] |
| 142 |
<td>[% field.marcfield | html %]</td> |
150 |
<td>[% field.marcfield | html %]</td> |
| 143 |
[% END %] |
151 |
[% END %] |
| 144 |
<td> |
152 |
[% IF show_searchable %] |
| 145 |
[% IF field.searchable %]Yes[% ELSE %]No[% END %] |
153 |
<td> |
| 146 |
</td> |
154 |
[% IF field.searchable %]Yes[% ELSE %]No[% END %] |
|
|
155 |
</td> |
| 156 |
[% END %] |
| 147 |
<td class="actions"> |
157 |
<td class="actions"> |
| 148 |
<a class="btn btn-default btn-xs" href="?op=add_form&field_id=[% field.id | html %]"><i class="fa fa-pencil"></i> Edit</a> |
158 |
<a class="btn btn-default btn-xs" href="?op=add_form&field_id=[% field.id | html %]"><i class="fa fa-pencil"></i> Edit</a> |
| 149 |
<a class="confirmdelete btn btn-default btn-xs" href="?op=delete&field_id=[% field.id | uri %]&tablename=[% tablename | uri %]"><i class="fa fa-trash"></i> Delete</a> |
159 |
<a class="confirmdelete btn btn-default btn-xs" href="?op=delete&field_id=[% field.id | uri %]&tablename=[% tablename | uri %]"><i class="fa fa-trash"></i> Delete</a> |
|
Lines 182-195
Link Here
|
| 182 |
<input type="text" name="marcfield" id="marcfield" value="[% field.marcfield | html %]" /> |
192 |
<input type="text" name="marcfield" id="marcfield" value="[% field.marcfield | html %]" /> |
| 183 |
</li> |
193 |
</li> |
| 184 |
[% END %] |
194 |
[% END %] |
| 185 |
<li> |
195 |
[% IF show_searchable %] |
| 186 |
<label for="searchable">Searchable: </label> |
196 |
<li> |
| 187 |
[% IF field.searchable %] |
197 |
<label for="searchable">Searchable: </label> |
| 188 |
<input type="checkbox" name="searchable" id="searchable" checked="checked" /> |
198 |
[% IF field.searchable %] |
| 189 |
[% ELSE %] |
199 |
<input type="checkbox" name="searchable" id="searchable" checked="checked" /> |
| 190 |
<input type="checkbox" name="searchable" id="searchable" /> |
200 |
[% ELSE %] |
| 191 |
[% END %] |
201 |
<input type="checkbox" name="searchable" id="searchable" /> |
| 192 |
</li> |
202 |
[% END %] |
|
|
203 |
</li> |
| 204 |
[% END %] |
| 193 |
</ol> |
205 |
</ol> |
| 194 |
</fieldset> |
206 |
</fieldset> |
| 195 |
<fieldset class="action"> |
207 |
<fieldset class="action"> |