source: trunk/grails-app/views/templateEditor/elements/_liFieldNotInUse.gsp @ 556

Last change on this file since 556 was 556, checked in by roberth, 10 years ago

Improved the TemplateEditor? again: templates can be created and removed and some checks were built in to ensure that the same fields in different templates point to the same TemplateField? object.

File size: 1.6 KB
Line 
1<span class="listButtons">
2  <img onClick="showTemplateFieldForm( 'templateField_' + ${templateField.id}); this.blur(); return false;" src="${createLinkTo( dir: 'images', file: 'icons/famfamfam/application_edit.png')}" alt="Edit template field properties" title="Edit template field properties">
3  <img onClick="if( confirm( 'Are you sure?' ) ) { deleteTemplateField( ${templateField.id} ); }" src="${createLinkTo( dir: 'images', file: 'icons/famfamfam/delete.png')}" alt="Delete this template field" title="Delete this template field">
4  <img onClick="addTemplateField( ${templateField.id} ); moveFieldListItem( ${templateField.id}, '#selectedTemplateFields' );" src="${createLinkTo( dir: 'images', file: 'icons/famfamfam/add.png')}" alt="Add field to template" title="Add field to template">
5</span>
6
7<b>${templateField.name}</b>
8(<g:if test="${templateField.unit}">${templateField.unit}, </g:if><g:render template="elements/${templateField.type.toString().toLowerCase().replaceAll(/ /,'_')}" model="[templateField: templateField]" />)
9
10<form class="templateField_form" id="templateField_${templateField.id}_form" action="updateField">
11        <g:hiddenField name="id" value="${templateField.id}" />
12        <g:hiddenField name="version" value="${templateField.version}" />
13        <g:render template="elements/fieldForm" model="['templateField': templateField, 'fieldTypes': fieldTypes]"/>
14        <div class="templateFieldButtons">
15                <input type="button" value="Save" onClick="updateTemplateField( ${templateField.id} );">
16                <input type="button" value="Close" onClick="hideTemplateFieldForm( ${templateField.id} );">
17        </div>
18</form>
Note: See TracBrowser for help on using the repository browser.