Bug 27883: (follow-up) Make label match input id

This change alters the list of columns under "Preserve existing values,"
changing the label for each checkbox can be clicked to trigger the
checkbox change.

To test, apply the patch and refresh the patron import page. Expand the
"Preserve existing values" section and click any label in the list. The
corresponding checkbox should be checked.

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This commit is contained in:
Owen Leonard 2021-03-30 15:04:24 +00:00 committed by Jonathan Druart
parent 58b5c1a68f
commit b5eee9bc7b

View file

@ -300,7 +300,7 @@
<div class="hint">Selected fields will be preserved from original patron record when overwriting existing patron.</div>
[% FOREACH borrower_field IN borrower_fields %]
<li>
<label class="description" for="[% borrower_field.field | html %]">[% borrower_field.description | html %]: </label>
<label class="description" for="preserve_existing_[% borrower_field.field | html %]">[% borrower_field.description | html %]: </label>
<input name="preserve_existing" id="preserve_existing_[% borrower_field.field | html %]" value="[% borrower_field.field | html %]" type="checkbox">
<span class="field_hint">[% borrower_field.field | html %]</span>
</li>