Ignore:
Timestamp:
Nov 19, 2010, 11:51:09 AM (12 years ago)
Author:
robert@…
Message:

The templateeditor is now capable of adding new items to a stringlist (that is in use), or adding new ontologies to a ontologyterm field that is in use. See ticket #74

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/grails-app/views/templateEditor/elements/_liFieldInUse.gsp

    r1159 r1175  
    1010   
    1111<form class="templateField_form" id="templateField_${templateField.id}_form" action="updateField">
    12         <g:hiddenField name="id" value="${templateField.id}" />
    13         <g:hiddenField name="version" value="${templateField.version}" />
    14         <p class="noEditsPossible">Editing not possible. Field is used in ${numUses} template(s).</p>
    15         <g:render template="elements/disabledFieldForm" model="['templateField': templateField, 'ontologies': ontologies, 'fieldTypes': fieldTypes]"/>
    16         <div class="templateFieldButtons">
    17                 <input type="button" value="Close" onClick="hideTemplateFieldForm( ${templateField.id} );">
    18         </div>
     12  <g:if test="${ templateField?.type.toString() == 'STRINGLIST' }">
     13    <p class="noEditsPossible">You can only add or remove list items that are not used. Field is used in ${numUses} template(s).</p>
     14  </g:if>
     15  <g:else>
     16    <g:if test="${templateField?.type.toString() == 'ONTOLOGYTERM' }">
     17    <p class="noEditsPossible">You can only add or remove ontologies that are not used. Field is used in ${numUses} template(s).</p>
     18        </g:if>
     19        <g:else>
     20          <p class="noEditsPossible">Editing not possible. Field is used in ${numUses} template(s).</p>
     21        </g:else>
     22  </g:else>
     23  <g:render template="elements/disabledFieldForm" model="['templateField': templateField, 'ontologies': ontologies, 'fieldTypes': fieldTypes]"/>
    1924</form>
    2025
Note: See TracChangeset for help on using the changeset viewer.