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