(bug #4052) fix mandatory field/subfield deletion
this fix the way to delete repeatable mandatory fields, the minus char is now shown only on repeatable fields, even if they are mandatory or not. If the last field is mandatory it won't be deleted.
This commit is contained in:
parent
6b88ea88bb
commit
365feb4185
1 changed files with 3 additions and 6 deletions
|
@ -721,10 +721,8 @@ function unHideSubfield(index,labelindex) { // FIXME :: is it used ?
|
|||
<!-- /TMPL_UNLESS -->
|
||||
<!-- TMPL_IF name="repeatable" -->
|
||||
<a href="#" tabindex="1" class="buttonPlus" onclick="CloneField('tag_<!-- TMPL_VAR name="tag"-->_<!-- TMPL_VAR NAME='index'--><!-- TMPL_VAR name="random" -->'); return false;" title="Repeat this Tag">+</a>
|
||||
<!-- /TMPL_IF -->
|
||||
<!-- TMPL_UNLESS name="mandatory" -->
|
||||
<a href="#" tabindex="1" class="buttonMinus" onclick="UnCloneField('tag_<!-- TMPL_VAR name="tag"-->_<!-- TMPL_VAR NAME='index'--><!-- TMPL_VAR name="random" -->'); return false;" title="Delete this Tag">−</a>
|
||||
<!-- /TMPL_UNLESS -->
|
||||
<!-- /TMPL_IF -->
|
||||
|
||||
</div>
|
||||
|
||||
|
@ -761,10 +759,9 @@ function unHideSubfield(index,labelindex) { // FIXME :: is it used ?
|
|||
|
||||
<!-- TMPL_IF NAME="repeatable" -->
|
||||
<span class="buttonPlus" onclick="CloneSubfield('subfield<!-- TMPL_VAR NAME='tag' --><!-- TMPL_VAR NAME='subfield' --><!-- TMPL_VAR name="random" -->')">+</span>
|
||||
<!-- /TMPL_IF -->
|
||||
<!-- TMPL_UNLESS NAME="mandatory" -->
|
||||
<span class="buttonMinus" onclick="UnCloneField('subfield<!-- TMPL_VAR NAME='tag' --><!-- TMPL_VAR NAME='subfield' --><!-- TMPL_VAR name="random" -->')">−</span>
|
||||
<!-- /TMPL_UNLESS -->
|
||||
<!-- /TMPL_IF -->
|
||||
|
||||
|
||||
</div>
|
||||
<!-- End of the line -->
|
||||
|
|
Loading…
Reference in a new issue