Changeset 659 for trunk/grails-app
- Timestamp:
- Sep 24, 2010, 3:47:30 AM (14 years ago)
- Location:
- trunk/grails-app/views/assetSubItemDetailed
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/grails-app/views/assetSubItemDetailed/edit.gsp
r410 r659 27 27 28 28 <tr class="prop"> 29 <td valign="top" class="name"> 29 <td valign="top" class="groupHeader"> 30 <label for="name">Asset Sub Item</label> 31 </td> 32 <td valign="top" class="value"> 33 </td> 34 </tr> 35 36 <tr class="prop"> 37 <td valign="top" class="groupName"> 30 38 <label for="name">Name:</label> 31 39 </td> … … 36 44 37 45 <tr class="prop"> 38 <td valign="top" class=" name">46 <td valign="top" class="groupName"> 39 47 <label for="description">Description:</label> 40 48 </td> … … 45 53 46 54 <tr class="prop"> 47 <td valign="top" class=" name">55 <td valign="top" class="groupName"> 48 56 <label for="comment">Comment:</label> 49 57 </td> … … 54 62 55 63 <tr class="prop"> 56 <td valign="top" class=" name">64 <td valign="top" class="groupName"> 57 65 <label for="isActive">Is Active:</label> 58 66 </td> … … 63 71 64 72 <tr class="prop"> 65 <td valign="top" class="name"> 66 <label for="assetSubItemExtendedAttributes">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 Extended Attribute</g:link> 76 77 </td> 73 <td valign="top" class="groupHeader"> 74 <label for="name">Extended Attributes</label> 75 </td> 76 <td valign="top" class="value"> 77 </td> 78 </tr> 79 80 <g:each var="a" in="${assetSubItemInstance?.assetSubItemExtendedAttributes?}"> 81 <tr class="prop"> 82 <td valign="top" class="name"> 83 </td> 84 <td valign="top" class="value ${hasErrors(bean:assetSubItemInstance,field:'assetSubItemExtendedAttributes','errors')}"> 85 <g:link controller="assetSubItemExtendedAttributeDetailed" action="show" id="${a.id}"> 86 ${a?.encodeAsHTML()} 87 </g:link> 88 </td> 89 </tr> 90 </g:each> 91 92 <tr class="prop"> 93 <td valign="top" class="groupHeader"> 94 </td> 95 <td valign="top" class="value"> 96 <g:link controller="assetSubItemExtendedAttributeDetailed" params="['assetSubItem.id':assetSubItemInstance?.id]" action="create">+Add Extended Attribute</g:link> 97 </td> 98 </tr> 99 100 <tr class="prop"> 101 102 <tr class="prop"> 103 <td valign="top" class="groupHeader"> 104 <label for="name">Asset Tree</label> 105 </td> 106 <td valign="top" class="value"> 107 </td> 108 </tr> 109 110 <tr class="prop"> 111 <td valign="top" class="groupName">Assets:</td> 112 113 <td valign="top" style="text-align:left;" class="value"> 114 <g:if test="${assetSubItemInstance.parentItem}" > 115 N/A (Assigned to parent item) 116 </g:if> 117 <g:else> 118 <g:if test="${assetSubItemInstance.assets}"> 119 <ul> 120 <g:each var="a" in="${ assetSubItemInstance.assets.sort { p1, p2 -> p1.name.compareToIgnoreCase(p2.name) } }"> 121 <li><g:link controller="assetDetailed" action="show" id="${a.id}">${a?.encodeAsHTML()}</g:link></li> 122 </g:each> 123 </ul> 124 </g:if> 125 <g:else> 126 May be assigned via asset edit view. 127 </g:else> 128 </g:else> 129 </td> 130 78 131 </tr> 79 80 <tr class="prop">81 132 82 133 <tr class="prop"> 83 <td valign="top" class=" name">134 <td valign="top" class="groupName"> 84 135 <label for="parentItem">Parent Item:</label> 85 136 </td> 86 137 <td valign="top" class="value ${hasErrors(bean:assetSubItemInstance,field:'parentItem','errors')}"> 87 138 <g:if test="${assetSubItemInstance.assets}"> 88 Assigned to assets.139 Level 1 sub item (Assigned directly to assets) 89 140 </g:if> 90 141 <g:else> … … 95 146 96 147 <tr class="prop"> 97 <td valign="top" class="name">Assets:</td> 98 99 <td valign="top" style="text-align:left;" class="value"> 100 <g:if test="${assetSubItemInstance.parentItem}" > 101 Assigned to parent item. 102 </g:if> 103 <g:else> 104 <ul> 105 <g:each var="a" in="${ assetSubItemInstance.assets.sort { p1, p2 -> p1.name.compareToIgnoreCase(p2.name) } }"> 106 <li><g:link controller="assetDetailed" action="show" id="${a.id}">${a?.encodeAsHTML()}</g:link></li> 107 </g:each> 108 </ul> 109 </g:else> 110 </td> 111 112 </tr> 113 114 <tr class="prop"> 115 <td valign="top" class="name"> 148 <td valign="top" class="groupName"> 116 149 <label for="subItems">Sub Items:</label> 117 150 </td> … … 129 162 130 163 <tr class="prop"> 131 <td valign="top" class="name"> 132 <label for="maintenanceActions">Maintenance Actions:</label> 133 </td> 134 <td valign="top" class="value ${hasErrors(bean:assetSubItemInstance,field:'maintenanceActions','errors')}"> 135 136 <ul> 137 <g:each var="m" in="${assetSubItemInstance?.maintenanceActions?}"> 138 <li><g:link controller="maintenanceActionDetailed" action="show" id="${m.id}">${m?.encodeAsHTML()}</g:link></li> 139 </g:each> 140 </ul> 141 <g:link controller="maintenanceActionDetailed" params="['assetSubItem.id':assetSubItemInstance?.id]" action="create">+Add Maintenance Action</g:link> 142 143 </td> 144 </tr> 164 <td valign="top" class="groupHeader"> 165 <label for="name">Maintenance Actions</label> 166 </td> 167 <td valign="top" class="value"> 168 </td> 169 </tr> 170 171 <g:each var="m" in="${assetSubItemInstance?.maintenanceActions?}"> 172 <tr class="prop"> 173 <td valign="top" class="name"> 174 </td> 175 <td valign="top" class="value ${hasErrors(bean:assetSubItemInstance,field:'maintenanceActions','errors')}"> 176 <g:link controller="maintenanceActionDetailed" action="show" id="${m.id}">${m?.encodeAsHTML()}</g:link></li> 177 </td> 178 </tr> 179 </g:each> 180 181 <tr class="prop"> 182 <td valign="top" class="groupHeader"> 183 </td> 184 <td valign="top" class="value"> 185 <g:link controller="maintenanceActionDetailed" params="['assetSubItem.id':assetSubItemInstance?.id]" action="create">+Add Maintenance Action</g:link> 186 </td> 187 </tr> 145 188 146 189 </tbody> -
trunk/grails-app/views/assetSubItemDetailed/show.gsp
r388 r659 17 17 <table> 18 18 <tbody> 19 20 <tr class="prop"> 21 <td valign="top" class="groupHeader"> 22 <label for="name">Asset Sub Item</label> 23 </td> 24 <td valign="top" class="value"> 25 </td> 26 </tr> 19 27 20 28 21 29 <tr class="prop"> 22 <td valign="top" class=" name">Id:</td>30 <td valign="top" class="groupName">Id:</td> 23 31 24 32 <td valign="top" class="value">${fieldValue(bean:assetSubItemInstance, field:'id')}</td> … … 27 35 28 36 <tr class="prop"> 29 <td valign="top" class=" name">Name:</td>37 <td valign="top" class="groupName">Name:</td> 30 38 31 39 <td valign="top" class="value">${fieldValue(bean:assetSubItemInstance, field:'name')}</td> … … 34 42 35 43 <tr class="prop"> 36 <td valign="top" class=" name">Description:</td>44 <td valign="top" class="groupName">Description:</td> 37 45 38 46 <td valign="top" class="value">${fieldValue(bean:assetSubItemInstance, field:'description')}</td> … … 41 49 42 50 <tr class="prop"> 43 <td valign="top" class=" name">Comment:</td>51 <td valign="top" class="groupName">Comment:</td> 44 52 45 53 <td valign="top" class="value">${fieldValue(bean:assetSubItemInstance, field:'comment')}</td> … … 48 56 49 57 <tr class="prop"> 50 <td valign="top" class=" name">Is Active:</td>58 <td valign="top" class="groupName">Is Active:</td> 51 59 52 60 <td valign="top" class="value">${fieldValue(bean:assetSubItemInstance, field:'isActive')}</td> 53 61 54 62 </tr> 63 64 <tr class="prop"> 65 <td valign="top" class="groupHeader"> 66 <label for="name">Extended Attributes</label> 67 </td> 68 <td valign="top" class="value"> 69 </td> 70 </tr> 55 71 72 <g:each var="a" in="${assetSubItemInstance.assetSubItemExtendedAttributes}"> 56 73 <tr class="prop"> 57 <td valign="top" class="name">Extended Attributes:</td> 58 74 <td valign="top" class="name"></td> 59 75 <td valign="top" style="text-align:left;" class="value"> 60 <ul> 61 <g:each var="a" in="${assetSubItemInstance.assetSubItemExtendedAttributes}"> 62 <li><g:link controller="assetSubItemExtendedAttributeDetailed" action="show" id="${a.id}">${a?.encodeAsHTML()}</g:link></li> 63 </g:each> 64 </ul> 76 <g:link controller="assetSubItemExtendedAttributeDetailed" action="show" id="${a.id}">${a?.encodeAsHTML()}</g:link> 65 77 </td> 66 78 </tr> 79 </g:each> 80 81 <tr class="prop"> 82 <td valign="top" class="groupHeader"> 83 <label for="name">Asset Tree</label> 84 </td> 85 <td valign="top" class="value"> 86 </td> 87 </tr> 88 89 <tr class="prop"> 90 <td valign="top" class="groupName">Assets:</td> 91 92 <td valign="top" style="text-align:left;" class="value"> 93 <g:if test="${assetSubItemInstance.parentItem}" > 94 N/A (Assigned to parent item) 95 </g:if> 96 <g:else> 97 <g:if test="${assetSubItemInstance.assets}"> 98 <ul> 99 <g:each var="a" in="${ assetSubItemInstance.assets.sort { p1, p2 -> p1.name.compareToIgnoreCase(p2.name) } }"> 100 <li><g:link controller="assetDetailed" action="show" id="${a.id}">${a?.encodeAsHTML()}</g:link></li> 101 </g:each> 102 </ul> 103 </g:if> 104 <g:else> 105 May be assigned via asset edit view. 106 </g:else> 107 </g:else> 108 </td> 109 67 110 </tr> 68 111 69 112 <tr class="prop"> 70 <td valign="top" class=" name">Parent Item:</td>113 <td valign="top" class="groupName">Parent Item:</td> 71 114 72 115 <td valign="top" class="value"> 73 116 <g:if test="${assetSubItemInstance.assets}"> 74 Assigned to assets.117 Level 1 sub item (Assigned directly to assets) 75 118 </g:if> 76 119 <g:else> … … 82 125 83 126 </tr> 84 85 <tr class="prop">86 <td valign="top" class="name">Assets:</td>87 88 <td valign="top" style="text-align:left;" class="value">89 <g:if test="${assetSubItemInstance.parentItem}" >90 Assigned to parent item.91 </g:if>92 <g:else>93 <ul>94 <g:each var="a" in="${ assetSubItemInstance.assets.sort { p1, p2 -> p1.name.compareToIgnoreCase(p2.name) } }">95 <li><g:link controller="assetDetailed" action="show" id="${a.id}">${a?.encodeAsHTML()}</g:link></li>96 </g:each>97 </ul>98 </g:else>99 </td>100 101 </tr>102 127 103 128 <tr class="prop"> 104 <td valign="top" class=" name">Sub Items:</td>129 <td valign="top" class="groupName">Sub Items:</td> 105 130 106 131 <td valign="top" style="text-align:left;" class="value"> … … 113 138 114 139 </tr> 140 141 <tr class="prop"> 142 <td valign="top" class="groupHeader"> 143 <label for="name">Maintenance Actions</label> 144 </td> 145 <td valign="top" class="value"> 146 </td> 147 </tr> 115 148 116 <tr class="prop"> 117 <td valign="top" class="name">Maintenance Actions:</td> 118 119 <td valign="top" style="text-align:left;" class="value"> 120 <ul> 121 <g:each var="m" in="${assetSubItemInstance.maintenanceActions}"> 122 <li><g:link controller="maintenanceActionDetailed" action="show" id="${m.id}">${m?.encodeAsHTML()}</g:link></li> 123 </g:each> 124 </ul> 125 </td> 126 127 </tr> 149 <g:each var="m" in="${assetSubItemInstance.maintenanceActions}"> 150 <tr class="prop"> 151 <td valign="top" class="name"></td> 152 <td valign="top" style="text-align:left;" class="value"> 153 <g:link controller="maintenanceActionDetailed" action="show" id="${m.id}">${m?.encodeAsHTML()}</g:link> 154 </td> 155 </tr> 156 </g:each> 128 157 129 158 </tbody>
Note: See TracChangeset
for help on using the changeset viewer.