Changeset 656 for trunk/grails-app
- Timestamp:
- Sep 24, 2010, 2:31:38 AM (14 years ago)
- Location:
- trunk/grails-app
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/grails-app/controllers/AssetExtendedAttributeDetailedController.groovy
r403 r656 87 87 if(!assetExtendedAttributeInstance.hasErrors() && assetExtendedAttributeInstance.save(flush: true)) { 88 88 flash.message = "AssetExtendedAttribute ${assetExtendedAttributeInstance.id} created" 89 redirect( action:show,id:assetExtendedAttributeInstance.id)89 redirect(controller:'assetDetailed', action:'edit',id:assetExtendedAttributeInstance.asset.id) 90 90 } 91 91 else { -
trunk/grails-app/views/assetExtendedAttributeDetailed/create.gsp
r413 r656 25 25 <tr class="prop"> 26 26 <td valign="top" class="name"> 27 <label for="value">Value:</label> 27 <label for="asset">Asset:</label> 28 </td> 29 30 <td valign="top" class="value"> 31 <g:link controller="assetDetailed" action="show" id="${assetExtendedAttributeInstance?.asset?.id}"> 32 <g:hiddenField name="asset.id" value="${assetExtendedAttributeInstance?.asset.id}" /> 33 ${assetExtendedAttributeInstance?.asset?.encodeAsHTML()} 34 </g:link> 35 </td> 36 </tr> 37 38 <tr class="prop"> 39 <td valign="top" class="name"> 40 <g:select optionKey="id" 41 from="${ExtendedAttributeType.findAllByIsActive(true).sort { p1, p2 -> p1.name.compareToIgnoreCase(p2.name) }}" 42 name="extendedAttributeType.id" 43 value="${assetExtendedAttributeInstance?.extendedAttributeType?.id}" > 44 </g:select> 28 45 </td> 29 46 <td valign="top" class="value ${hasErrors(bean:assetExtendedAttributeInstance,field:'value','errors')}"> 30 47 <input type="text" maxlength="100" id="value" name="value" value="${fieldValue(bean:assetExtendedAttributeInstance,field:'value')}"/> 48 <g:hiddenField name="isActive" value="${true}" /> 31 49 </td> 32 </tr> 33 34 <tr class="prop"> 35 <td valign="top" class="name"> 36 <label for="isActive">Is Active:</label> 37 </td> 38 <td valign="top" class="value ${hasErrors(bean:assetExtendedAttributeInstance,field:'isActive','errors')}"> 39 <g:checkBox name="isActive" value="${assetExtendedAttributeInstance?.isActive}" ></g:checkBox> 40 </td> 41 </tr> 42 43 <tr class="prop"> 44 <td valign="top" class="name"> 45 <label for="asset">Asset:</label> 46 </td> 47 <td valign="top" class="value ${hasErrors(bean:assetExtendedAttributeInstance,field:'asset','errors')}"> 48 <g:select optionKey="id" from="${Asset.list()}" name="asset.id" value="${assetExtendedAttributeInstance?.asset?.id}" ></g:select> 49 </td> 50 </tr> 51 52 <tr class="prop"> 53 <td valign="top" class="name"> 54 <label for="extendedAttributeType">Extended Attribute Type:</label> 55 </td> 56 <td valign="top" class="value ${hasErrors(bean:assetExtendedAttributeInstance,field:'extendedAttributeType','errors')}"> 57 <g:select optionKey="id" from="${ExtendedAttributeType.list()}" name="extendedAttributeType.id" value="${assetExtendedAttributeInstance?.extendedAttributeType?.id}" ></g:select> 58 </td> 59 </tr> 50 </tr> 60 51 61 52 </tbody>
Note: See TracChangeset
for help on using the changeset viewer.