[116] | 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 InventoryItem</title> |
---|
[139] | 8 | <nav:resources override="true"/> |
---|
[182] | 9 | <g:render template="/shared/pictureHead" /> |
---|
[116] | 10 | </head> |
---|
| 11 | <body> |
---|
| 12 | <div class="nav"> |
---|
[139] | 13 | <nav:renderSubItems group="nav"/> |
---|
[116] | 14 | </div> |
---|
| 15 | <div class="body"> |
---|
[405] | 16 | <g:render template="/shared/messages" /> |
---|
[116] | 17 | <g:hasErrors bean="${inventoryItemInstance}"> |
---|
| 18 | <div class="errors"> |
---|
| 19 | <g:renderErrors bean="${inventoryItemInstance}" as="list" /> |
---|
| 20 | </div> |
---|
| 21 | </g:hasErrors> |
---|
| 22 | <g:form method="post" > |
---|
| 23 | <input type="hidden" name="id" value="${inventoryItemInstance?.id}" /> |
---|
| 24 | <input type="hidden" name="version" value="${inventoryItemInstance?.version}" /> |
---|
| 25 | <div class="dialog"> |
---|
| 26 | <table> |
---|
| 27 | <tbody> |
---|
[223] | 28 | |
---|
[182] | 29 | <tr class="prop"> |
---|
| 30 | <td valign="top" class="name">Picture:</td> |
---|
| 31 | <td valign="top" class="value"> |
---|
| 32 | <g:if test="${inventoryItemInstance.picture}" > |
---|
| 33 | <span class='gallery'> |
---|
| 34 | <wa:pictureLightboxAnchor picture="${inventoryItemInstance.picture}" size="${Image.Medium}" lightboxSize="${Image.Large}" target="_blank" title="Show Original" /> |
---|
| 35 | </span> |
---|
| 36 | <br /> |
---|
| 37 | <g:link controller="pictureDetailed" action="edit" id="${inventoryItemInstance.picture.id}" > |
---|
| 38 | Edit Picture |
---|
| 39 | </g:link> |
---|
| 40 | </g:if> |
---|
| 41 | </td> |
---|
| 42 | </tr> |
---|
[223] | 43 | |
---|
[116] | 44 | <tr class="prop"> |
---|
| 45 | <td valign="top" class="name"> |
---|
| 46 | <label for="name">Name:</label> |
---|
| 47 | </td> |
---|
[223] | 48 | <td valign="top"> |
---|
| 49 | <input class="description ${hasErrors(bean:inventoryItemInstance,field:'name','errors')}" |
---|
| 50 | type="text" maxlength="50" id="name" name="name" |
---|
| 51 | value="${fieldValue(bean:inventoryItemInstance,field:'name')}"/> |
---|
[116] | 52 | </td> |
---|
[223] | 53 | </tr> |
---|
| 54 | |
---|
[116] | 55 | <tr class="prop"> |
---|
| 56 | <td valign="top" class="name"> |
---|
| 57 | <label for="description">Description:</label> |
---|
| 58 | </td> |
---|
[223] | 59 | <td valign="top"> |
---|
| 60 | <input class="description ${hasErrors(bean:inventoryItemInstance,field:'description','errors')}" |
---|
| 61 | type="text" id="description" name="description" |
---|
| 62 | value="${fieldValue(bean:inventoryItemInstance,field:'description')}"/> |
---|
[116] | 63 | </td> |
---|
[223] | 64 | </tr> |
---|
| 65 | |
---|
[116] | 66 | <tr class="prop"> |
---|
| 67 | <td valign="top" class="name"> |
---|
[223] | 68 | <label for="unitsInStock">In Stock:</label> |
---|
[175] | 69 | </td> |
---|
[182] | 70 | <td valign="top" class="value"> |
---|
[223] | 71 | ${inventoryItemInstance.unitsInStock} ${inventoryItemInstance.unitOfMeasure.encodeAsHTML()} |
---|
[175] | 72 | </td> |
---|
| 73 | </tr> |
---|
[223] | 74 | |
---|
[175] | 75 | <tr class="prop"> |
---|
| 76 | <td valign="top" class="name"> |
---|
[223] | 77 | <label for="inventoryLocation">Location:</label> |
---|
[116] | 78 | </td> |
---|
[223] | 79 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'inventoryLocation','errors')}"> |
---|
[382] | 80 | <g:select optionKey="id" |
---|
| 81 | from="${ InventoryLocation.list().sort { p1, p2 -> p1.toString().compareToIgnoreCase(p2.toString()) } }" |
---|
| 82 | name="inventoryLocation.id" |
---|
[392] | 83 | value="${inventoryItemInstance?.inventoryLocation?.id}" |
---|
| 84 | optionValue="${{it.name+ ' in ' + it.inventoryStore}}"> |
---|
[382] | 85 | </g:select> |
---|
[116] | 86 | </td> |
---|
[175] | 87 | </tr> |
---|
[223] | 88 | |
---|
[175] | 89 | <tr class="prop"> |
---|
| 90 | <td valign="top" class="name"> |
---|
| 91 | <label for="isActive">Active:</label> |
---|
[116] | 92 | </td> |
---|
| 93 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'isActive','errors')}"> |
---|
| 94 | <g:checkBox name="isActive" value="${inventoryItemInstance?.isActive}" ></g:checkBox> |
---|
| 95 | </td> |
---|
[223] | 96 | </tr> |
---|
| 97 | |
---|
[116] | 98 | <tr class="prop"> |
---|
| 99 | <td valign="top" class="name"> |
---|
[223] | 100 | <label for="reorderPoint">Reorder Point:</label> |
---|
[116] | 101 | </td> |
---|
[223] | 102 | <td valign="top"> |
---|
| 103 | <input class="medium ${hasErrors(bean:inventoryItemInstance,field:'reorderPoint','errors')}" |
---|
| 104 | type="text" id="reorderPoint" name="reorderPoint" |
---|
| 105 | value="${fieldValue(bean:inventoryItemInstance,field:'reorderPoint')}" /> |
---|
| 106 | ${inventoryItemInstance.unitOfMeasure.encodeAsHTML()} |
---|
[116] | 107 | </td> |
---|
[223] | 108 | </tr> |
---|
| 109 | |
---|
[116] | 110 | <tr class="prop"> |
---|
| 111 | <td valign="top" class="name"> |
---|
[223] | 112 | <label for="recommendedReorderPoint">Recommended Reorder Point:</label> |
---|
[116] | 113 | </td> |
---|
[223] | 114 | <td valign="top"> |
---|
| 115 | <input class="medium ${hasErrors(bean:inventoryItemInstance,field:'recommendedReorderPoint','errors')}" |
---|
| 116 | type="text" id="recommendedReorderPoint" name="recommendedReorderPoint" |
---|
| 117 | value="${fieldValue(bean:inventoryItemInstance,field:'recommendedReorderPoint')}" /> |
---|
| 118 | ${inventoryItemInstance.unitOfMeasure.encodeAsHTML()} |
---|
[116] | 119 | </td> |
---|
[223] | 120 | </tr> |
---|
| 121 | |
---|
[116] | 122 | <tr class="prop"> |
---|
| 123 | <td valign="top" class="name"> |
---|
[223] | 124 | <label for="enableReorder">Enable Reorder:</label> |
---|
[116] | 125 | </td> |
---|
[223] | 126 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'enableReorder','errors')}"> |
---|
| 127 | <g:checkBox name="enableReorder" value="${inventoryItemInstance?.enableReorder}" ></g:checkBox> |
---|
[116] | 128 | </td> |
---|
[175] | 129 | </tr> |
---|
[223] | 130 | |
---|
[116] | 131 | <tr class="prop"> |
---|
| 132 | <td valign="top" class="name"> |
---|
[223] | 133 | <label for="isObsolete">Obsolete:</label> |
---|
[116] | 134 | </td> |
---|
[223] | 135 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'isObsolete','errors')}"> |
---|
| 136 | <g:checkBox name="isObsolete" value="${inventoryItemInstance?.isObsolete}" ></g:checkBox> |
---|
[116] | 137 | </td> |
---|
[175] | 138 | </tr> |
---|
[223] | 139 | |
---|
[116] | 140 | <tr class="prop"> |
---|
| 141 | <td valign="top" class="name"> |
---|
[175] | 142 | <label for="averageDeliveryTime">Average Delivery Time:</label> |
---|
[116] | 143 | </td> |
---|
[175] | 144 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'averageDeliveryTime','errors')}"> |
---|
| 145 | <input type="text" id="averageDeliveryTime" name="averageDeliveryTime" value="${fieldValue(bean:inventoryItemInstance,field:'averageDeliveryTime')}" /> |
---|
[382] | 146 | <g:select optionKey="id" |
---|
| 147 | from="${Period.list()}" |
---|
| 148 | name="averageDeliveryPeriod.id" |
---|
| 149 | value="${inventoryItemInstance?.averageDeliveryPeriod?.id}" |
---|
| 150 | noSelection="['null':'--None--']"> |
---|
| 151 | </g:select> |
---|
[116] | 152 | </td> |
---|
[175] | 153 | </tr> |
---|
[405] | 154 | |
---|
| 155 | <tr class="prop"> |
---|
| 156 | <td valign="top" class="name"> |
---|
| 157 | <label for="averageDeliveryTime">Estimated Unit Price:</label> |
---|
| 158 | </td> |
---|
| 159 | <td valign="top"> |
---|
| 160 | <input class="medium ${hasErrors(bean:inventoryItemInstance,field:'estimatedUnitPriceAmount','errors')}" |
---|
| 161 | type="text" id="estimatedUnitPriceAmount" name="estimatedUnitPriceAmount" |
---|
| 162 | value="${inventoryItemInstance.estimatedUnitPriceAmount}" /> |
---|
| 163 | <g:currencySelect name="estimatedUnitPriceCurrency" |
---|
| 164 | value="${inventoryItemInstance.estimatedUnitPriceCurrency}" /> |
---|
| 165 | </td> |
---|
| 166 | </tr> |
---|
[223] | 167 | |
---|
[116] | 168 | <tr class="prop"> |
---|
| 169 | <td valign="top" class="name"> |
---|
[223] | 170 | <label for="suppliersPartNumber">Suppliers Part Number:</label> |
---|
[116] | 171 | </td> |
---|
[223] | 172 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'suppliersPartNumber','errors')}"> |
---|
| 173 | <input type="text" id="suppliersPartNumber" name="suppliersPartNumber" value="${fieldValue(bean:inventoryItemInstance,field:'suppliersPartNumber')}"/> |
---|
[116] | 174 | </td> |
---|
[175] | 175 | </tr> |
---|
[223] | 176 | |
---|
[116] | 177 | <tr class="prop"> |
---|
| 178 | <td valign="top" class="name"> |
---|
[223] | 179 | <label for="suppliers">Suppliers:</label> |
---|
[116] | 180 | </td> |
---|
[223] | 181 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'suppliers','errors')}"> |
---|
| 182 | <g:select id="suppliers" name="suppliers" |
---|
[382] | 183 | from="${ Supplier.list().sort { p1, p2 -> p1.name.compareToIgnoreCase(p2.name) } }" |
---|
[223] | 184 | size="5" multiple="yes" optionKey="id" |
---|
| 185 | value="${inventoryItemInstance?.suppliers.id}" noSelection="['':'--None--']"/> |
---|
[116] | 186 | |
---|
[410] | 187 | <p><g:link controller="supplierDetailed" action="create">+Add Supplier</g:link></p> |
---|
[116] | 188 | </td> |
---|
[223] | 189 | </tr> |
---|
| 190 | |
---|
[116] | 191 | <tr class="prop"> |
---|
| 192 | <td valign="top" class="name"> |
---|
[223] | 193 | <label for="manufacturersPartNumber">Manufacturers Part Number:</label> |
---|
[116] | 194 | </td> |
---|
[223] | 195 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'manufacturersPartNumber','errors')}"> |
---|
| 196 | <input type="text" id="manufacturersPartNumber" name="manufacturersPartNumber" value="${fieldValue(bean:inventoryItemInstance,field:'manufacturersPartNumber')}"/> |
---|
| 197 | </td> |
---|
| 198 | </tr> |
---|
[116] | 199 | |
---|
| 200 | <tr class="prop"> |
---|
| 201 | <td valign="top" class="name"> |
---|
| 202 | <label for="manufacturers">Manufacturers:</label> |
---|
| 203 | </td> |
---|
| 204 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'manufacturers','errors')}"> |
---|
[175] | 205 | <g:select id="manufacturers" name="manufacturers" |
---|
[382] | 206 | from="${ Manufacturer.list().sort { p1, p2 -> p1.name.compareToIgnoreCase(p2.name) } }" |
---|
[175] | 207 | size="5" multiple="yes" optionKey="id" |
---|
[223] | 208 | value="${inventoryItemInstance?.manufacturers.id}" noSelection="['':'--None--']"/> |
---|
[382] | 209 | |
---|
[410] | 210 | <p><g:link controller="manufacturerDetailed" action="create">+Add Manufacturer</g:link></p> |
---|
[223] | 211 | </td> |
---|
| 212 | </tr> |
---|
[116] | 213 | |
---|
| 214 | <tr class="prop"> |
---|
| 215 | <td valign="top" class="name"> |
---|
| 216 | <label for="spareFor">Spare For:</label> |
---|
| 217 | </td> |
---|
| 218 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'spareFor','errors')}"> |
---|
| 219 | <g:select name="spareFor" |
---|
[382] | 220 | from="${ Asset.list().sort { p1, p2 -> p1.name.compareToIgnoreCase(p2.name) } }" |
---|
[223] | 221 | size="5" multiple="yes" optionKey="id" |
---|
[382] | 222 | value="${inventoryItemInstance?.spareFor.id}" noSelection="['':'--None--']"/> |
---|
[116] | 223 | |
---|
| 224 | </td> |
---|
[175] | 225 | </tr> |
---|
[223] | 226 | |
---|
[116] | 227 | <tr class="prop"> |
---|
| 228 | <td valign="top" class="name"> |
---|
[223] | 229 | <label for="alternateItems">Alternate Items:</label> |
---|
[116] | 230 | </td> |
---|
[223] | 231 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'alternateItems','errors')}"> |
---|
| 232 | <g:select name="alternateItems" |
---|
[382] | 233 | from="${ InventoryItem.list().sort { p1, p2 -> p1.name.compareToIgnoreCase(p2.name) } }" |
---|
[223] | 234 | size="5" multiple="yes" optionKey="id" |
---|
[382] | 235 | value="${inventoryItemInstance?.alternateItems.id}" noSelection="['':'--None--']"/> |
---|
[223] | 236 | |
---|
[116] | 237 | </td> |
---|
[175] | 238 | </tr> |
---|
[223] | 239 | |
---|
[116] | 240 | <tr class="prop"> |
---|
| 241 | <td valign="top" class="name"> |
---|
[223] | 242 | <label for="inventoryGroup">Inventory Group:</label> |
---|
[116] | 243 | </td> |
---|
[223] | 244 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'inventoryGroup','errors')}"> |
---|
| 245 | <g:select optionKey="id" from="${InventoryGroup.list()}" name="inventoryGroup.id" value="${inventoryItemInstance?.inventoryGroup?.id}" ></g:select> |
---|
| 246 | </td> |
---|
| 247 | </tr> |
---|
[116] | 248 | |
---|
[223] | 249 | <tr class="prop"> |
---|
| 250 | <td valign="top" class="name"> |
---|
| 251 | <label for="inventoryType">Inventory Type:</label> |
---|
[116] | 252 | </td> |
---|
[223] | 253 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'inventoryType','errors')}"> |
---|
| 254 | <g:select optionKey="id" from="${InventoryType.list()}" name="inventoryType.id" value="${inventoryItemInstance?.inventoryType?.id}" ></g:select> |
---|
| 255 | </td> |
---|
[175] | 256 | </tr> |
---|
[223] | 257 | |
---|
[116] | 258 | </tbody> |
---|
| 259 | </table> |
---|
| 260 | </div> |
---|
| 261 | <div class="buttons"> |
---|
| 262 | <span class="button"><g:actionSubmit class="save" value="Update" /></span> |
---|
[223] | 263 | <span class="button"><g:actionSubmit class="cancel" value="Cancel" action="Show"/></span> |
---|
[116] | 264 | <span class="button"><g:actionSubmit class="delete" onclick="return confirm('Are you sure?');" value="Delete" /></span> |
---|
| 265 | </div> |
---|
| 266 | </g:form> |
---|
| 267 | </div> |
---|
| 268 | </body> |
---|
| 269 | </html> |
---|