Koha/koha-tmpl/intranet-tmpl/prog/en/includes/admin-items-search-field-form.inc
Owen Leonard e33742c676 Bug 20689: (follow-up) Correct scope of template variables
The removal of the <select>s should have been accompanied by a
correction to the scope of tagfield and tagsubfield. It is also
unnecessary to conditionally include the "value" attribute.

To test, apply the patch and test the process for editing an item search
field. All the correct values should appear in form fields during edit,
and all values should save correctly.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2022-03-01 22:47:46 -10:00

35 lines
1.6 KiB
HTML

[% PROCESS 'html_helpers.inc' %]
<ol>
<li>
[% IF field %]
<span class="label">Name: </span>
[% field.name | html %]
<input type="hidden" name="name" value="[% field.name | html %]">
[% ELSE %]
<label class="required" for="name">Name: </label>
<input type="text" name="name" id="name" class="required" required="required" />
<span class="required">Required</span>
[% END %]
</li>
<li>
<label class="required" for="label">Label: </label>
<input type="text" name="label" id="label" value="[% field.label | html %]" class="required" required="required" />
<span class="required">Required</span>
</li>
<li>
<label class="required" for="tagfield">MARC field: </label>
<input type="text" id="tagfield" name="tagfield" maxlength="3" size="3" class="required" pattern="[a-zA-Z0-9]+" required="required" value="[% field.tagfield | html %]" />
<span class="required">Required</span>
</li>
<li>
<label for="tagsubfield">MARC subfield: </label>
<input type="text" id="tagsubfield" name="tagsubfield" pattern="[a-zA-Z0-9]+" maxlength="1" size="1" value="[% field.tagsubfield | html %]" />
</li>
<li>
<label for="authorised_values_category">Authorised values category: </label>
<select id="authorised_values_category" name="authorised_values_category">
<option value="">- None -</option>
[% PROCESS options_for_authorised_value_categories authorised_value_categories => AuthorisedValues.GetCategories( selected => field.authorised_values_category ) %]
</select>
</li>
</ol>