[118] | 1 | |
---|
| 2 | |
---|
| 3 | <html> |
---|
| 4 | <head> |
---|
| 5 | <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> |
---|
| 6 | <meta name="layout" content="main" /> |
---|
| 7 | <title>Edit SubAssembly</title> |
---|
| 8 | </head> |
---|
| 9 | <body> |
---|
| 10 | <div class="nav"> |
---|
| 11 | <span class="menuButton"><g:link class="list" action="list">SubAssembly List</g:link></span> |
---|
| 12 | <span class="menuButton"><g:link class="create" action="create">New SubAssembly</g:link></span> |
---|
| 13 | </div> |
---|
| 14 | <div class="body"> |
---|
| 15 | <h1>Edit SubAssembly</h1> |
---|
| 16 | <g:if test="${flash.message}"> |
---|
| 17 | <div class="message">${flash.message}</div> |
---|
| 18 | </g:if> |
---|
| 19 | <g:hasErrors bean="${subAssemblyInstance}"> |
---|
| 20 | <div class="errors"> |
---|
| 21 | <g:renderErrors bean="${subAssemblyInstance}" as="list" /> |
---|
| 22 | </div> |
---|
| 23 | </g:hasErrors> |
---|
| 24 | <g:form method="post" > |
---|
| 25 | <input type="hidden" name="id" value="${subAssemblyInstance?.id}" /> |
---|
| 26 | <input type="hidden" name="version" value="${subAssemblyInstance?.version}" /> |
---|
| 27 | <div class="dialog"> |
---|
| 28 | <table> |
---|
| 29 | <tbody> |
---|
| 30 | |
---|
| 31 | <tr class="prop"> |
---|
| 32 | <td valign="top" class="name"> |
---|
[131] | 33 | <label for="assembly">Assembly:</label> |
---|
[118] | 34 | </td> |
---|
[131] | 35 | <td valign="top" class="value ${hasErrors(bean:subAssemblyInstance,field:'assembly','errors')}"> |
---|
| 36 | <g:select optionKey="id" from="${Assembly.list()}" name="assembly.id" value="${subAssemblyInstance?.assembly?.id}" ></g:select> |
---|
[118] | 37 | </td> |
---|
| 38 | </tr> |
---|
| 39 | |
---|
| 40 | <tr class="prop"> |
---|
| 41 | <td valign="top" class="name"> |
---|
| 42 | <label for="componentItems">Component Items:</label> |
---|
| 43 | </td> |
---|
| 44 | <td valign="top" class="value ${hasErrors(bean:subAssemblyInstance,field:'componentItems','errors')}"> |
---|
[131] | 45 | |
---|
| 46 | <ul> |
---|
| 47 | <g:each var="c" in="${subAssemblyInstance?.componentItems?}"> |
---|
| 48 | <li><g:link controller="componentItem" action="show" id="${c.id}">${c?.encodeAsHTML()}</g:link></li> |
---|
| 49 | </g:each> |
---|
| 50 | </ul> |
---|
| 51 | <g:link controller="componentItem" params="['subAssembly.id':subAssemblyInstance?.id]" action="create">Add ComponentItem</g:link> |
---|
[118] | 52 | |
---|
| 53 | </td> |
---|
| 54 | </tr> |
---|
| 55 | |
---|
| 56 | <tr class="prop"> |
---|
| 57 | <td valign="top" class="name"> |
---|
| 58 | <label for="description">Description:</label> |
---|
| 59 | </td> |
---|
| 60 | <td valign="top" class="value ${hasErrors(bean:subAssemblyInstance,field:'description','errors')}"> |
---|
| 61 | <input type="text" id="description" name="description" value="${fieldValue(bean:subAssemblyInstance,field:'description')}"/> |
---|
| 62 | </td> |
---|
| 63 | </tr> |
---|
| 64 | |
---|
| 65 | <tr class="prop"> |
---|
| 66 | <td valign="top" class="name"> |
---|
| 67 | <label for="isActive">Is Active:</label> |
---|
| 68 | </td> |
---|
| 69 | <td valign="top" class="value ${hasErrors(bean:subAssemblyInstance,field:'isActive','errors')}"> |
---|
| 70 | <g:checkBox name="isActive" value="${subAssemblyInstance?.isActive}" ></g:checkBox> |
---|
| 71 | </td> |
---|
| 72 | </tr> |
---|
| 73 | |
---|
| 74 | <tr class="prop"> |
---|
| 75 | <td valign="top" class="name"> |
---|
[122] | 76 | <label for="maintenanceActions">Maintenance Actions:</label> |
---|
[118] | 77 | </td> |
---|
[122] | 78 | <td valign="top" class="value ${hasErrors(bean:subAssemblyInstance,field:'maintenanceActions','errors')}"> |
---|
| 79 | |
---|
| 80 | <ul> |
---|
| 81 | <g:each var="m" in="${subAssemblyInstance?.maintenanceActions?}"> |
---|
| 82 | <li><g:link controller="maintenanceAction" action="show" id="${m.id}">${m?.encodeAsHTML()}</g:link></li> |
---|
| 83 | </g:each> |
---|
| 84 | </ul> |
---|
| 85 | <g:link controller="maintenanceAction" params="['subAssembly.id':subAssemblyInstance?.id]" action="create">Add MaintenanceAction</g:link> |
---|
| 86 | |
---|
[118] | 87 | </td> |
---|
| 88 | </tr> |
---|
| 89 | |
---|
| 90 | <tr class="prop"> |
---|
| 91 | <td valign="top" class="name"> |
---|
| 92 | <label for="name">Name:</label> |
---|
| 93 | </td> |
---|
| 94 | <td valign="top" class="value ${hasErrors(bean:subAssemblyInstance,field:'name','errors')}"> |
---|
| 95 | <input type="text" id="name" name="name" value="${fieldValue(bean:subAssemblyInstance,field:'name')}"/> |
---|
| 96 | </td> |
---|
| 97 | </tr> |
---|
| 98 | |
---|
| 99 | </tbody> |
---|
| 100 | </table> |
---|
| 101 | </div> |
---|
| 102 | <div class="buttons"> |
---|
| 103 | <span class="button"><g:actionSubmit class="save" value="Update" /></span> |
---|
| 104 | <span class="button"><g:actionSubmit class="delete" onclick="return confirm('Are you sure?');" value="Delete" /></span> |
---|
| 105 | </div> |
---|
| 106 | </g:form> |
---|
| 107 | </div> |
---|
| 108 | </body> |
---|
| 109 | </html> |
---|