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 AssetSubItem</title> |
---|
8 | </head> |
---|
9 | <body> |
---|
10 | <div class="nav"> |
---|
11 | <span class="menuButton"><g:link class="list" action="search">Sub Item Search</g:link></span> |
---|
12 | </div> |
---|
13 | <div class="body"> |
---|
14 | <h1>Edit Sub Item</h1> |
---|
15 | <g:render template="/shared/messages" /> |
---|
16 | <g:hasErrors bean="${assetSubItemInstance}"> |
---|
17 | <div class="errors"> |
---|
18 | <g:renderErrors bean="${assetSubItemInstance}" as="list" /> |
---|
19 | </div> |
---|
20 | </g:hasErrors> |
---|
21 | <g:form method="post" > |
---|
22 | <input type="hidden" name="id" value="${assetSubItemInstance?.id}" /> |
---|
23 | <input type="hidden" name="version" value="${assetSubItemInstance?.version}" /> |
---|
24 | <div class="dialog"> |
---|
25 | <table> |
---|
26 | <tbody> |
---|
27 | |
---|
28 | <tr class="prop"> |
---|
29 | <td valign="top" class="name"> |
---|
30 | <label for="name">Name:</label> |
---|
31 | </td> |
---|
32 | <td valign="top" class="value ${hasErrors(bean:assetSubItemInstance,field:'name','errors')}"> |
---|
33 | <input type="text" class="description" maxlength="50" id="name" name="name" value="${fieldValue(bean:assetSubItemInstance,field:'name')}"/> |
---|
34 | </td> |
---|
35 | </tr> |
---|
36 | |
---|
37 | <tr class="prop"> |
---|
38 | <td valign="top" class="name"> |
---|
39 | <label for="description">Description:</label> |
---|
40 | </td> |
---|
41 | <td valign="top" class="value ${hasErrors(bean:assetSubItemInstance,field:'description','errors')}"> |
---|
42 | <input type="text" class="description" maxlength="75" id="description" name="description" value="${fieldValue(bean:assetSubItemInstance,field:'description')}"/> |
---|
43 | </td> |
---|
44 | </tr> |
---|
45 | |
---|
46 | <tr class="prop"> |
---|
47 | <td valign="top" class="name"> |
---|
48 | <label for="comment">Comment:</label> |
---|
49 | </td> |
---|
50 | <td valign="top" class="value ${hasErrors(bean:assetSubItemInstance,field:'comment','errors')}"> |
---|
51 | <textarea rows="5" cols="40" name="comment">${fieldValue(bean:assetSubItemInstance, field:'comment')}</textarea> |
---|
52 | </td> |
---|
53 | </tr> |
---|
54 | |
---|
55 | <tr class="prop"> |
---|
56 | <td valign="top" class="name"> |
---|
57 | <label for="isActive">Is Active:</label> |
---|
58 | </td> |
---|
59 | <td valign="top" class="value ${hasErrors(bean:assetSubItemInstance,field:'isActive','errors')}"> |
---|
60 | <g:checkBox name="isActive" value="${assetSubItemInstance?.isActive}" ></g:checkBox> |
---|
61 | </td> |
---|
62 | </tr> |
---|
63 | |
---|
64 | <tr class="prop"> |
---|
65 | <td valign="top" class="name"> |
---|
66 | <label for="assetSubItemExtendedAttributes">Asset Sub Item Extended Attributes:</label> |
---|
67 | </td> |
---|
68 | <td valign="top" class="value ${hasErrors(bean:assetSubItemInstance,field:'assetSubItemExtendedAttributes','errors')}"> |
---|
69 | |
---|
70 | <ul> |
---|
71 | <g:each var="a" in="${assetSubItemInstance?.assetSubItemExtendedAttributes?}"> |
---|
72 | <li><g:link controller="assetSubItemExtendedAttributeDetailed" action="show" id="${a.id}">${a?.encodeAsHTML()}</g:link></li> |
---|
73 | </g:each> |
---|
74 | </ul> |
---|
75 | <g:link controller="assetSubItemExtendedAttributeDetailed" params="['assetSubItem.id':assetSubItemInstance?.id]" action="create">Add AssetSubItemExtendedAttribute</g:link> |
---|
76 | |
---|
77 | </td> |
---|
78 | </tr> |
---|
79 | |
---|
80 | <tr class="prop"> |
---|
81 | |
---|
82 | <tr class="prop"> |
---|
83 | <td valign="top" class="name"> |
---|
84 | <label for="maintenanceActions">Maintenance Actions:</label> |
---|
85 | </td> |
---|
86 | <td valign="top" class="value ${hasErrors(bean:assetSubItemInstance,field:'maintenanceActions','errors')}"> |
---|
87 | |
---|
88 | <ul> |
---|
89 | <g:each var="m" in="${assetSubItemInstance?.maintenanceActions?}"> |
---|
90 | <li><g:link controller="maintenanceActionDetailed" action="show" id="${m.id}">${m?.encodeAsHTML()}</g:link></li> |
---|
91 | </g:each> |
---|
92 | </ul> |
---|
93 | <g:link controller="maintenanceActionDetailed" params="['assetSubItem.id':assetSubItemInstance?.id]" action="create">Add MaintenanceAction</g:link> |
---|
94 | |
---|
95 | </td> |
---|
96 | </tr> |
---|
97 | |
---|
98 | <tr class="prop"> |
---|
99 | <td valign="top" class="name"> |
---|
100 | <label for="parentItem">Parent Item:</label> |
---|
101 | </td> |
---|
102 | <td valign="top" class="value ${hasErrors(bean:assetSubItemInstance,field:'parentItem','errors')}"> |
---|
103 | <g:select optionKey="id" from="${AssetSubItem.list()}" name="parentItem.id" value="${assetSubItemInstance?.parentItem?.id}" noSelection="['null':'']"></g:select> |
---|
104 | </td> |
---|
105 | </tr> |
---|
106 | |
---|
107 | <tr class="prop"> |
---|
108 | <td valign="top" class="name">Assets:</td> |
---|
109 | |
---|
110 | <td valign="top" style="text-align:left;" class="value"> |
---|
111 | <ul> |
---|
112 | <g:each var="a" in="${assetSubItemInstance.assets}"> |
---|
113 | <li><g:link controller="assetDetailed" action="show" id="${a.id}">${a?.encodeAsHTML()}</g:link></li> |
---|
114 | </g:each> |
---|
115 | </ul> |
---|
116 | </td> |
---|
117 | |
---|
118 | </tr> |
---|
119 | |
---|
120 | <tr class="prop"> |
---|
121 | <td valign="top" class="name"> |
---|
122 | <label for="subItems">Sub Items:</label> |
---|
123 | </td> |
---|
124 | <td valign="top" class="value ${hasErrors(bean:assetSubItemInstance,field:'subItems','errors')}"> |
---|
125 | |
---|
126 | <ul> |
---|
127 | <g:each var="s" in="${assetSubItemInstance?.subItems?}"> |
---|
128 | <li><g:link controller="assetSubItemDetailed" action="show" id="${s.id}">${s?.encodeAsHTML()}</g:link></li> |
---|
129 | </g:each> |
---|
130 | </ul> |
---|
131 | <g:link controller="assetSubItemDetailed" params="['parentItem.id':assetSubItemInstance?.id]" action="create">Add AssetSubItem</g:link> |
---|
132 | |
---|
133 | </td> |
---|
134 | </tr> |
---|
135 | |
---|
136 | </tbody> |
---|
137 | </table> |
---|
138 | </div> |
---|
139 | <div class="buttons"> |
---|
140 | <span class="button"><g:actionSubmit class="save" value="Update" /></span> |
---|
141 | <span class="button"><g:actionSubmit class="delete" onclick="return confirm('Are you sure?');" value="Delete" /></span> |
---|
142 | </div> |
---|
143 | </g:form> |
---|
144 | </div> |
---|
145 | </body> |
---|
146 | </html> |
---|