Lines 109-116
Link Here
|
109 |
<select name="[% kohafield | html %]" id="[%- mv.id | html -%]" class="input_marceditor select2 [% kohafield | html %]" data-category="[% mv.category | html %]" data-width="50%"> |
109 |
<select name="[% kohafield | html %]" id="[%- mv.id | html -%]" class="input_marceditor select2 [% kohafield | html %]" data-category="[% mv.category | html %]" data-width="50%"> |
110 |
[% END %] |
110 |
[% END %] |
111 |
|
111 |
|
|
|
112 |
[% SET matched = 0 %] |
112 |
[% FOREACH aval IN mv.values %] |
113 |
[% FOREACH aval IN mv.values %] |
113 |
[% IF aval == mv.default %] |
114 |
[% IF aval == mv.default %] |
|
|
115 |
[% SET matched = 1 %] |
114 |
<option value="[%- aval | html -%]" selected="selected">[%- mv.labels.$aval | html -%]</option> |
116 |
<option value="[%- aval | html -%]" selected="selected">[%- mv.labels.$aval | html -%]</option> |
115 |
[% ELSE %] |
117 |
[% ELSE %] |
116 |
[% IF subfield.IS_LOST_AV && Koha.Preference("ClaimReturnedLostValue") && aval == Koha.Preference("ClaimReturnedLostValue") %] |
118 |
[% IF subfield.IS_LOST_AV && Koha.Preference("ClaimReturnedLostValue") && aval == Koha.Preference("ClaimReturnedLostValue") %] |
Lines 122-128
Link Here
|
122 |
[% END %] |
124 |
[% END %] |
123 |
[% END %] |
125 |
[% END %] |
124 |
[% END %] |
126 |
[% END %] |
125 |
</select> |
127 |
[% UNLESS matched || ( ( kohafield == 'items.damaged' || kohafield == 'items.itemlost' || kohafield == 'items.withdrawn' || kohafield == 'items.notforloan' ) && mv.default == '0' ) %] |
|
|
128 |
[%# If the current value is not in the authorised list and is not a field where 0 means unset #%] |
129 |
<option value="[%- mv.default | html -%]" selected="selected">[%- mv.default | html -%]</option> |
130 |
</select> |
131 |
<span style="float:right;" title="The current value [% mv.default | html %] is not in the authorised value list"><i class="fa fa-exclamation-circle" aria-hidden="true"></i></span> |
132 |
[% ELSE %] |
133 |
</select> |
134 |
[% END %] |
126 |
[% ELSIF ( mv.type == 'text_auth' ) %] |
135 |
[% ELSIF ( mv.type == 'text_auth' ) %] |
127 |
[% IF mv.readonly %] |
136 |
[% IF mv.readonly %] |
128 |
<input type="text" id="[%- mv.id | html -%]" name="[% kohafield | html %]" class="input_marceditor [% kohafield | html %]" maxlength="[%- mv.maxlength | html -%]" value="[%- mv.value | html -%]" readonly="readonly" /> |
137 |
<input type="text" id="[%- mv.id | html -%]" name="[% kohafield | html %]" class="input_marceditor [% kohafield | html %]" maxlength="[%- mv.maxlength | html -%]" value="[%- mv.value | html -%]" readonly="readonly" /> |