[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" /> |
---|
[139] | 7 | <title>Create InventoryItem</title> |
---|
| 8 | <nav:resources override="true"/> |
---|
[116] | 9 | </head> |
---|
| 10 | <body> |
---|
| 11 | <div class="nav"> |
---|
[139] | 12 | <nav:renderSubItems group="nav"/> |
---|
[116] | 13 | </div> |
---|
| 14 | <div class="body"> |
---|
[405] | 15 | <g:render template="/shared/messages" /> |
---|
[116] | 16 | <g:hasErrors bean="${inventoryItemInstance}"> |
---|
| 17 | <div class="errors"> |
---|
| 18 | <g:renderErrors bean="${inventoryItemInstance}" as="list" /> |
---|
| 19 | </div> |
---|
| 20 | </g:hasErrors> |
---|
| 21 | <g:form action="save" method="post" > |
---|
| 22 | <div class="dialog"> |
---|
| 23 | <table> |
---|
| 24 | <tbody> |
---|
| 25 | |
---|
| 26 | <tr class="prop"> |
---|
[727] | 27 | <td valign="top" class="groupHeader"> |
---|
| 28 | <label for="name">Inventory Item</label> |
---|
| 29 | </td> |
---|
| 30 | <td valign="top" class="value"> |
---|
| 31 | </td> |
---|
| 32 | </tr> |
---|
| 33 | |
---|
| 34 | <tr class="prop"> |
---|
| 35 | <td valign="top" class="groupName"> |
---|
[116] | 36 | <label for="name">Name:</label> |
---|
| 37 | </td> |
---|
| 38 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'name','errors')}"> |
---|
[175] | 39 | <input type="text" class="description" maxlength="50" id="name" name="name" value="${fieldValue(bean:inventoryItemInstance,field:'name')}"/> |
---|
[716] | 40 | <g:helpBalloon class="helpballoon" code="inventory.item.name" /> |
---|
[116] | 41 | </td> |
---|
[422] | 42 | </tr> |
---|
| 43 | |
---|
[116] | 44 | <tr class="prop"> |
---|
[727] | 45 | <td valign="top" class="groupName"> |
---|
[116] | 46 | <label for="description">Description:</label> |
---|
| 47 | </td> |
---|
| 48 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'description','errors')}"> |
---|
[422] | 49 | <textarea rows="5" cols="40" name="description">${fieldValue(bean:inventoryItemInstance, field:'description')}</textarea> |
---|
[716] | 50 | <g:helpBalloon class="helpballoon" code="inventory.item.description" /> |
---|
[116] | 51 | </td> |
---|
[175] | 52 | </tr> |
---|
[182] | 53 | |
---|
[175] | 54 | <tr class="prop"> |
---|
[727] | 55 | <td valign="top" class="groupName"> |
---|
[422] | 56 | <label for="comment">Comment:</label> |
---|
| 57 | </td> |
---|
| 58 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'comment','errors')}"> |
---|
| 59 | <textarea rows="5" cols="40" name="comment">${fieldValue(bean:inventoryItemInstance, field:'comment')}</textarea> |
---|
[716] | 60 | <g:helpBalloon class="helpballoon" code="inventory.item.comment" /> |
---|
[422] | 61 | </td> |
---|
| 62 | </tr> |
---|
| 63 | |
---|
| 64 | <tr class="prop"> |
---|
[727] | 65 | <td valign="top" class="groupName"> |
---|
| 66 | <label for="unitOfMeasure">Unit Of Measure:</label> |
---|
| 67 | </td> |
---|
| 68 | <td valign="top"> |
---|
| 69 | <g:select optionKey="id" |
---|
| 70 | from="${UnitOfMeasure.findAllByIsActive(true)}" |
---|
| 71 | name="unitOfMeasure.id" |
---|
| 72 | value="${inventoryItemInstance?.unitOfMeasure?.id}" > |
---|
| 73 | </g:select> |
---|
| 74 | <g:helpBalloon class="helpballoon" code="inventory.item.unit.of.measure" /> |
---|
| 75 | </td> |
---|
| 76 | </tr> |
---|
| 77 | |
---|
| 78 | <tr class="prop"> |
---|
| 79 | <td valign="top" class="groupName"> |
---|
[182] | 80 | <label for="inventoryLocation">Inventory Location:</label> |
---|
[175] | 81 | </td> |
---|
[182] | 82 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'inventoryLocation','errors')}"> |
---|
[382] | 83 | <g:select optionKey="id" |
---|
[727] | 84 | from="${ InventoryLocation.findAllByIsActive(true).sort { p1, p2 -> p1.toString().compareToIgnoreCase(p2.toString()) } }" |
---|
[392] | 85 | name="inventoryLocation.id" value="${inventoryItemInstance?.inventoryLocation?.id}" |
---|
[727] | 86 | optionValue="${{it.name+ ' in ' + it.inventoryStore}}" |
---|
| 87 | noSelection="['null':/${g.message(code:'default.please.select.text')}/]" > |
---|
[382] | 88 | </g:select> |
---|
[716] | 89 | <g:helpBalloon class="helpballoon" code="inventory.item.inventory.location" /> |
---|
[382] | 90 | |
---|
[410] | 91 | <p><g:link controller="inventoryLocationDetailed" action="create">+Add Location</g:link></p> |
---|
[175] | 92 | </td> |
---|
| 93 | </tr> |
---|
[116] | 94 | |
---|
| 95 | <tr class="prop"> |
---|
[727] | 96 | <td valign="top" class="groupName"> |
---|
| 97 | <label for="inventoryGroup">Inventory Group:</label> |
---|
[116] | 98 | </td> |
---|
[727] | 99 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'inventoryGroup','errors')}"> |
---|
[382] | 100 | <g:select optionKey="id" |
---|
[727] | 101 | from="${InventoryGroup.findAllByIsActive(true).sort { p1, p2 -> p1.name.compareToIgnoreCase(p2.name) }}" |
---|
| 102 | name="inventoryGroup.id" |
---|
| 103 | value="${inventoryItemInstance?.inventoryGroup?.id}" |
---|
| 104 | noSelection="['null':/${g.message(code:'default.please.select.text')}/]" > |
---|
[382] | 105 | </g:select> |
---|
[727] | 106 | <g:helpBalloon class="helpballoon" code="inventory.item.inventory.group" /> |
---|
| 107 | <p><g:link controller="inventoryGroupDetailed" action="create">+Add Group</g:link></p> |
---|
[116] | 108 | </td> |
---|
| 109 | </tr> |
---|
| 110 | |
---|
| 111 | <tr class="prop"> |
---|
[727] | 112 | <td valign="top" class="groupName"> |
---|
| 113 | <label for="inventoryType">Inventory Type:</label> |
---|
| 114 | </td> |
---|
| 115 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'inventoryType','errors')}"> |
---|
| 116 | <g:select optionKey="id" |
---|
| 117 | from="${InventoryType.findAllByIsActive(true).sort { p1, p2 -> p1.name.compareToIgnoreCase(p2.name) }}" |
---|
| 118 | name="inventoryType.id" |
---|
| 119 | value="${inventoryItemInstance?.inventoryType?.id}" |
---|
| 120 | noSelection="['null':/${g.message(code:'default.please.select.text')}/]" > |
---|
| 121 | </g:select> |
---|
| 122 | <g:helpBalloon class="helpballoon" code="inventory.item.inventory.type" /> |
---|
| 123 | </td> |
---|
| 124 | </tr> |
---|
| 125 | |
---|
| 126 | <tr class="prop"> |
---|
| 127 | <td valign="top" class="groupHeader"> |
---|
| 128 | <label for="name">Reorder Details</label> |
---|
| 129 | </td> |
---|
| 130 | <td valign="top" class="value"> |
---|
| 131 | </td> |
---|
| 132 | </tr> |
---|
| 133 | |
---|
| 134 | <tr class="prop"> |
---|
| 135 | <td valign="top" class="groupName"> |
---|
[616] | 136 | <label for="enableReorderListing">Enable Reorder Listing:</label> |
---|
[116] | 137 | </td> |
---|
[616] | 138 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'enableReorderListing','errors')}"> |
---|
| 139 | <g:checkBox name="enableReorderListing" value="${inventoryItemInstance?.enableReorderListing}" ></g:checkBox> |
---|
[716] | 140 | <g:helpBalloon class="helpballoon" code="inventory.item.enable.reorder.listing" /> |
---|
[116] | 141 | </td> |
---|
[175] | 142 | </tr> |
---|
[116] | 143 | |
---|
| 144 | <tr class="prop"> |
---|
[727] | 145 | <td valign="top" class="groupName"> |
---|
| 146 | <label for="reorderPoint">Reorder Point:</label> |
---|
[116] | 147 | </td> |
---|
[727] | 148 | <td valign="top"> |
---|
| 149 | <input class="medium ${hasErrors(bean:inventoryItemInstance,field:'reorderPoint','errors')}" |
---|
| 150 | type="text" id="reorderPoint" name="reorderPoint" |
---|
| 151 | value="${fieldValue(bean:inventoryItemInstance,field:'reorderPoint')}" /> |
---|
| 152 | <g:helpBalloon class="helpballoon" code="inventory.item.reorder.point" /> |
---|
[116] | 153 | </td> |
---|
[727] | 154 | </tr> |
---|
| 155 | |
---|
[116] | 156 | <tr class="prop"> |
---|
[727] | 157 | <td valign="top" class="groupName"> |
---|
| 158 | <label for="reorderQuantity">Reorder Quantity:</label> |
---|
[116] | 159 | </td> |
---|
[727] | 160 | <td valign="top"> |
---|
| 161 | <input class="medium ${hasErrors(bean:inventoryItemInstance,field:'reorderQuantity','errors')}" |
---|
| 162 | type="text" id="reorderQuantity" name="reorderQuantity" |
---|
| 163 | value="${fieldValue(bean:inventoryItemInstance,field:'reorderQuantity')}" /> |
---|
| 164 | <g:helpBalloon class="helpballoon" code="inventory.item.reorder.quantity" /> |
---|
[116] | 165 | </td> |
---|
[175] | 166 | </tr> |
---|
[116] | 167 | |
---|
| 168 | <tr class="prop"> |
---|
[727] | 169 | <td valign="top" class="groupName"> |
---|
[718] | 170 | <label for="estimatedUnitPriceAmount">Estimated Unit Price:</label> |
---|
[116] | 171 | </td> |
---|
[223] | 172 | <td valign="top"> |
---|
[405] | 173 | <input class="medium ${hasErrors(bean:inventoryItemInstance,field:'estimatedUnitPriceAmount','errors')}" |
---|
| 174 | type="text" id="estimatedUnitPriceAmount" name="estimatedUnitPriceAmount" |
---|
| 175 | value="${fieldValue(bean:inventoryItemInstance,field:'estimatedUnitPriceAmount')}" /> |
---|
| 176 | <g:currencySelect name="estimatedUnitPriceCurrency" |
---|
[604] | 177 | value="${inventoryItemInstance?.estimatedUnitPriceCurrency}" |
---|
| 178 | from="${grailsApplication.config.currencyList}"> |
---|
| 179 | </g:currencySelect> |
---|
[716] | 180 | <g:helpBalloon class="helpballoon" code="inventory.item.estimated.unit.price.amount" /> |
---|
[405] | 181 | </td> |
---|
| 182 | </tr> |
---|
| 183 | |
---|
| 184 | <tr class="prop"> |
---|
[727] | 185 | <td valign="top" class="groupName"> |
---|
[116] | 186 | <label for="suppliersPartNumber">Suppliers Part Number:</label> |
---|
| 187 | </td> |
---|
| 188 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'suppliersPartNumber','errors')}"> |
---|
[727] | 189 | <input type="text" id="suppliersPartNumber" maxlength="50" name="suppliersPartNumber" value="${fieldValue(bean:inventoryItemInstance,field:'suppliersPartNumber')}"/> |
---|
[716] | 190 | <g:helpBalloon class="helpballoon" code="inventory.item.suppliers.part.number" /> |
---|
[116] | 191 | </td> |
---|
[175] | 192 | </tr> |
---|
[116] | 193 | |
---|
| 194 | <tr class="prop"> |
---|
[727] | 195 | <td valign="top" class="groupName"> |
---|
[435] | 196 | <label for="preferredSupplier">Preferred Supplier:</label> |
---|
[116] | 197 | </td> |
---|
[435] | 198 | <td valign="top"> |
---|
[727] | 199 | <g:select optionKey="id" |
---|
| 200 | from="${suppliers}" |
---|
| 201 | name="preferredSupplier.id" |
---|
| 202 | value="${inventoryItemInstance.preferredSupplier?.id}" |
---|
| 203 | noSelection="['null':'--None--']"> |
---|
| 204 | </g:select> |
---|
[716] | 205 | <g:helpBalloon class="helpballoon" code="inventory.item.preferred.supplier" /> |
---|
[435] | 206 | <p><g:link controller="supplierDetailed" action="create">+Add Supplier</g:link></p> |
---|
[116] | 207 | </td> |
---|
[175] | 208 | </tr> |
---|
[727] | 209 | |
---|
[116] | 210 | <tr class="prop"> |
---|
[727] | 211 | <td valign="top" class="groupName"> |
---|
[435] | 212 | <label for="alternateSuppliers">Alternate Suppliers:</label> |
---|
| 213 | </td> |
---|
| 214 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'alternateSuppliers','errors')}"> |
---|
[716] | 215 | <g:helpBalloon class="helpballoon" code="inventory.item.alternate.suppliers" /> |
---|
[727] | 216 | <custom:checkBoxList name="alternateSuppliers" |
---|
| 217 | from="${suppliers}" |
---|
| 218 | value="${inventoryItemInstance?.alternateSuppliers?.collect{it.id}}" |
---|
| 219 | optionKey="id" |
---|
| 220 | linkController="supplierDetailed" |
---|
| 221 | linkAction="show"/> |
---|
| 222 | <g:link controller="supplierDetailed" action="create">+Add Supplier</g:link> |
---|
[435] | 223 | </td> |
---|
| 224 | </tr> |
---|
[727] | 225 | |
---|
| 226 | <tr class="prop"> |
---|
| 227 | <td valign="top" class="groupHeader"> |
---|
| 228 | <label for="name">Spare For</label> |
---|
| 229 | </td> |
---|
| 230 | <td valign="top" class="value"> |
---|
| 231 | </td> |
---|
| 232 | </tr> |
---|
| 233 | |
---|
| 234 | <tr class="prop"> |
---|
| 235 | <td valign="top" class="groupName"> |
---|
| 236 | <label for="spareFor">Assets:</label> |
---|
| 237 | </td> |
---|
| 238 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'spareFor','errors')}"> |
---|
| 239 | <g:helpBalloon class="helpballoon" code="inventory.item.spare.for" /> |
---|
| 240 | <custom:checkBoxList name="spareFor" |
---|
| 241 | from="${Asset.findAllByIsActive(true).sort { p1, p2 -> p1.name.compareToIgnoreCase(p2.name) }}" |
---|
| 242 | value="${inventoryItemInstance?.spareFor?.collect{it.id}}" |
---|
| 243 | optionKey="id" |
---|
| 244 | sortBy="name" |
---|
| 245 | linkController="assetDetailed" |
---|
| 246 | linkAction="show"/> |
---|
| 247 | <g:link controller="assetDetailed" action="create">+Add Asset</g:link> |
---|
| 248 | </td> |
---|
| 249 | </tr> |
---|
[435] | 250 | |
---|
[116] | 251 | </tbody> |
---|
| 252 | </table> |
---|
| 253 | </div> |
---|
| 254 | <div class="buttons"> |
---|
| 255 | <span class="button"><input class="save" type="submit" value="Create" /></span> |
---|
| 256 | </div> |
---|
| 257 | </g:form> |
---|
| 258 | </div> |
---|
| 259 | </body> |
---|
| 260 | </html> |
---|