[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"> |
---|
| 27 | <td valign="top" class="name"> |
---|
| 28 | <label for="name">Name:</label> |
---|
| 29 | </td> |
---|
| 30 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'name','errors')}"> |
---|
[175] | 31 | <input type="text" class="description" maxlength="50" id="name" name="name" value="${fieldValue(bean:inventoryItemInstance,field:'name')}"/> |
---|
[116] | 32 | </td> |
---|
[422] | 33 | </tr> |
---|
| 34 | |
---|
[116] | 35 | <tr class="prop"> |
---|
| 36 | <td valign="top" class="name"> |
---|
| 37 | <label for="description">Description:</label> |
---|
| 38 | </td> |
---|
| 39 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'description','errors')}"> |
---|
[422] | 40 | <textarea rows="5" cols="40" name="description">${fieldValue(bean:inventoryItemInstance, field:'description')}</textarea> |
---|
[116] | 41 | </td> |
---|
[175] | 42 | </tr> |
---|
[182] | 43 | |
---|
[175] | 44 | <tr class="prop"> |
---|
| 45 | <td valign="top" class="name"> |
---|
[422] | 46 | <label for="comment">Comment:</label> |
---|
| 47 | </td> |
---|
| 48 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'comment','errors')}"> |
---|
| 49 | <textarea rows="5" cols="40" name="comment">${fieldValue(bean:inventoryItemInstance, field:'comment')}</textarea> |
---|
| 50 | </td> |
---|
| 51 | </tr> |
---|
| 52 | |
---|
| 53 | <tr class="prop"> |
---|
| 54 | <td valign="top" class="name"> |
---|
[182] | 55 | <label for="inventoryLocation">Inventory Location:</label> |
---|
[175] | 56 | </td> |
---|
[182] | 57 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'inventoryLocation','errors')}"> |
---|
[382] | 58 | <g:select optionKey="id" |
---|
| 59 | from="${ InventoryLocation.list().sort { p1, p2 -> p1.toString().compareToIgnoreCase(p2.toString()) } }" |
---|
[392] | 60 | name="inventoryLocation.id" value="${inventoryItemInstance?.inventoryLocation?.id}" |
---|
| 61 | optionValue="${{it.name+ ' in ' + it.inventoryStore}}"> |
---|
[382] | 62 | </g:select> |
---|
| 63 | |
---|
[410] | 64 | <p><g:link controller="inventoryLocationDetailed" action="create">+Add Location</g:link></p> |
---|
[175] | 65 | </td> |
---|
| 66 | </tr> |
---|
[116] | 67 | |
---|
| 68 | <tr class="prop"> |
---|
| 69 | <td valign="top" class="name"> |
---|
| 70 | <label for="reorderPoint">Reorder Point:</label> |
---|
| 71 | </td> |
---|
[223] | 72 | <td valign="top"> |
---|
| 73 | <input class="medium ${hasErrors(bean:inventoryItemInstance,field:'reorderPoint','errors')}" |
---|
| 74 | type="text" id="reorderPoint" name="reorderPoint" |
---|
| 75 | value="${fieldValue(bean:inventoryItemInstance,field:'reorderPoint')}" /> |
---|
[382] | 76 | <g:select optionKey="id" |
---|
| 77 | from="${UnitOfMeasure.list()}" |
---|
| 78 | name="unitOfMeasure.id" |
---|
| 79 | value="${inventoryItemInstance?.unitOfMeasure?.id}" > |
---|
| 80 | </g:select> |
---|
[116] | 81 | </td> |
---|
| 82 | </tr> |
---|
| 83 | |
---|
| 84 | <tr class="prop"> |
---|
| 85 | <td valign="top" class="name"> |
---|
[616] | 86 | <label for="enableReorderListing">Enable Reorder Listing:</label> |
---|
[116] | 87 | </td> |
---|
[616] | 88 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'enableReorderListing','errors')}"> |
---|
| 89 | <g:checkBox name="enableReorderListing" value="${inventoryItemInstance?.enableReorderListing}" ></g:checkBox> |
---|
[116] | 90 | </td> |
---|
[175] | 91 | </tr> |
---|
[116] | 92 | |
---|
| 93 | <tr class="prop"> |
---|
| 94 | <td valign="top" class="name"> |
---|
| 95 | <label for="inventoryGroup">Inventory Group:</label> |
---|
| 96 | </td> |
---|
| 97 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'inventoryGroup','errors')}"> |
---|
| 98 | <g:select optionKey="id" from="${InventoryGroup.list()}" name="inventoryGroup.id" value="${inventoryItemInstance?.inventoryGroup?.id}" ></g:select> |
---|
[382] | 99 | |
---|
[410] | 100 | <p><g:link controller="inventoryGroupDetailed" action="create">+Add Group</g:link></p> |
---|
[116] | 101 | </td> |
---|
| 102 | </tr> |
---|
| 103 | |
---|
| 104 | <tr class="prop"> |
---|
| 105 | <td valign="top" class="name"> |
---|
| 106 | <label for="inventoryType">Inventory Type:</label> |
---|
| 107 | </td> |
---|
| 108 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'inventoryType','errors')}"> |
---|
| 109 | <g:select optionKey="id" from="${InventoryType.list()}" name="inventoryType.id" value="${inventoryItemInstance?.inventoryType?.id}" ></g:select> |
---|
| 110 | </td> |
---|
[175] | 111 | </tr> |
---|
[116] | 112 | |
---|
| 113 | <tr class="prop"> |
---|
| 114 | <td valign="top" class="name"> |
---|
[223] | 115 | <label for="averageDeliveryTime">Average Delivery Time:</label> |
---|
[116] | 116 | </td> |
---|
[223] | 117 | <td valign="top"> |
---|
| 118 | <input class="medium ${hasErrors(bean:inventoryItemInstance,field:'averageDeliveryTime','errors')}" |
---|
| 119 | type="text" id="averageDeliveryTime" name="averageDeliveryTime" |
---|
| 120 | value="${fieldValue(bean:inventoryItemInstance,field:'averageDeliveryTime')}" /> |
---|
| 121 | <g:select optionKey="id" from="${Period.list()}" name="averageDeliveryPeriod.id" value="${inventoryItemInstance?.averageDeliveryPeriod?.id}" noSelection="['null':'--None--']"></g:select> |
---|
[116] | 122 | </td> |
---|
[175] | 123 | </tr> |
---|
[116] | 124 | |
---|
| 125 | <tr class="prop"> |
---|
| 126 | <td valign="top" class="name"> |
---|
[405] | 127 | <label for="averageDeliveryTime">Estimated Unit Price:</label> |
---|
| 128 | </td> |
---|
| 129 | <td valign="top"> |
---|
| 130 | <input class="medium ${hasErrors(bean:inventoryItemInstance,field:'estimatedUnitPriceAmount','errors')}" |
---|
| 131 | type="text" id="estimatedUnitPriceAmount" name="estimatedUnitPriceAmount" |
---|
| 132 | value="${fieldValue(bean:inventoryItemInstance,field:'estimatedUnitPriceAmount')}" /> |
---|
| 133 | <g:currencySelect name="estimatedUnitPriceCurrency" |
---|
[604] | 134 | value="${inventoryItemInstance?.estimatedUnitPriceCurrency}" |
---|
| 135 | from="${grailsApplication.config.currencyList}"> |
---|
| 136 | </g:currencySelect> |
---|
[405] | 137 | </td> |
---|
| 138 | </tr> |
---|
| 139 | |
---|
| 140 | <tr class="prop"> |
---|
| 141 | <td valign="top" class="name"> |
---|
[116] | 142 | <label for="suppliersPartNumber">Suppliers Part Number:</label> |
---|
| 143 | </td> |
---|
| 144 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'suppliersPartNumber','errors')}"> |
---|
| 145 | <input type="text" id="suppliersPartNumber" name="suppliersPartNumber" value="${fieldValue(bean:inventoryItemInstance,field:'suppliersPartNumber')}"/> |
---|
| 146 | </td> |
---|
[175] | 147 | </tr> |
---|
[116] | 148 | |
---|
| 149 | <tr class="prop"> |
---|
| 150 | <td valign="top" class="name"> |
---|
[435] | 151 | <label for="preferredSupplier">Preferred Supplier:</label> |
---|
[116] | 152 | </td> |
---|
[435] | 153 | <td valign="top"> |
---|
| 154 | <g:select optionKey="id" from="${suppliers}" name="preferredSupplier.id" value="${inventoryItemInstance.preferredSupplier?.id}" noSelection="['null':'--None--']"></g:select> |
---|
[175] | 155 | |
---|
[435] | 156 | <p><g:link controller="supplierDetailed" action="create">+Add Supplier</g:link></p> |
---|
[116] | 157 | </td> |
---|
[175] | 158 | </tr> |
---|
[116] | 159 | |
---|
| 160 | <tr class="prop"> |
---|
| 161 | <td valign="top" class="name"> |
---|
[435] | 162 | <label for="alternateSuppliers">Alternate Suppliers:</label> |
---|
| 163 | </td> |
---|
| 164 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'alternateSuppliers','errors')}"> |
---|
| 165 | <g:select id="alternateSuppliers" name="alternateSuppliers" |
---|
| 166 | from="${suppliers}" |
---|
| 167 | size="5" multiple="yes" optionKey="id" |
---|
| 168 | value="${inventoryItemInstance.alternateSuppliers?.id}" noSelection="['':'--None--']"/> |
---|
| 169 | </td> |
---|
| 170 | </tr> |
---|
| 171 | |
---|
| 172 | <tr class="prop"> |
---|
| 173 | <td valign="top" class="name"> |
---|
[223] | 174 | <label for="manufacturersPartNumber">Manufacturers Part Number:</label> |
---|
[116] | 175 | </td> |
---|
[223] | 176 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'manufacturersPartNumber','errors')}"> |
---|
| 177 | <input type="text" id="manufacturersPartNumber" name="manufacturersPartNumber" value="${fieldValue(bean:inventoryItemInstance,field:'manufacturersPartNumber')}"/> |
---|
[116] | 178 | </td> |
---|
[223] | 179 | </tr> |
---|
| 180 | |
---|
| 181 | <tr class="prop"> |
---|
| 182 | <td valign="top" class="name"> |
---|
[435] | 183 | <label for="preferredManufacturer">Preferred Manufacturer:</label> |
---|
[223] | 184 | </td> |
---|
[435] | 185 | <td valign="top"> |
---|
| 186 | <g:select optionKey="id" from="${manufacturers}" name="preferredManufacturer.id" value="${inventoryItemInstance?.preferredManufacturer?.id}" noSelection="['null':'--None--']"></g:select> |
---|
[223] | 187 | |
---|
[410] | 188 | <p><g:link controller="manufacturerDetailed" action="create">+Add Manufacturer</g:link></p> |
---|
[223] | 189 | </td> |
---|
[175] | 190 | </tr> |
---|
[116] | 191 | |
---|
[435] | 192 | <tr class="prop"> |
---|
| 193 | <td valign="top" class="name"> |
---|
| 194 | <label for="manufacturers">Alternate Manufacturers:</label> |
---|
| 195 | </td> |
---|
| 196 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'alternateManufacturers','errors')}"> |
---|
| 197 | <g:select id="alternateManufacturers" name="alternateManufacturers" |
---|
| 198 | from="${manufacturers}" |
---|
| 199 | size="5" multiple="yes" optionKey="id" |
---|
| 200 | value="${inventoryItemInstance.alternateManufacturers?.id}" noSelection="['':'--None--']" /> |
---|
| 201 | </td> |
---|
| 202 | </tr> |
---|
| 203 | |
---|
[116] | 204 | </tbody> |
---|
| 205 | </table> |
---|
| 206 | </div> |
---|
| 207 | <div class="buttons"> |
---|
| 208 | <span class="button"><input class="save" type="submit" value="Create" /></span> |
---|
| 209 | </div> |
---|
| 210 | </g:form> |
---|
| 211 | </div> |
---|
| 212 | </body> |
---|
| 213 | </html> |
---|