[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"> |
---|
| 15 | <g:if test="${flash.message}"> |
---|
| 16 | <div class="message">${flash.message}</div> |
---|
| 17 | </g:if> |
---|
| 18 | <g:hasErrors bean="${inventoryItemInstance}"> |
---|
| 19 | <div class="errors"> |
---|
| 20 | <g:renderErrors bean="${inventoryItemInstance}" as="list" /> |
---|
| 21 | </div> |
---|
| 22 | </g:hasErrors> |
---|
| 23 | <g:form action="save" method="post" > |
---|
| 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:inventoryItemInstance,field:'name','errors')}"> |
---|
[175] | 33 | <input type="text" class="description" maxlength="50" id="name" name="name" value="${fieldValue(bean:inventoryItemInstance,field:'name')}"/> |
---|
[116] | 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:inventoryItemInstance,field:'description','errors')}"> |
---|
[175] | 42 | <input type="text" class="description" id="description" name="description" value="${fieldValue(bean:inventoryItemInstance,field:'description')}"/> |
---|
[116] | 43 | </td> |
---|
[175] | 44 | </tr> |
---|
[182] | 45 | |
---|
[175] | 46 | <tr class="prop"> |
---|
| 47 | <td valign="top" class="name"> |
---|
[182] | 48 | <label for="inventoryLocation">Inventory Location:</label> |
---|
[175] | 49 | </td> |
---|
[182] | 50 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'inventoryLocation','errors')}"> |
---|
[382] | 51 | <g:select optionKey="id" |
---|
| 52 | from="${ InventoryLocation.list().sort { p1, p2 -> p1.toString().compareToIgnoreCase(p2.toString()) } }" |
---|
[392] | 53 | name="inventoryLocation.id" value="${inventoryItemInstance?.inventoryLocation?.id}" |
---|
| 54 | optionValue="${{it.name+ ' in ' + it.inventoryStore}}"> |
---|
[382] | 55 | </g:select> |
---|
| 56 | |
---|
| 57 | <p><g:link controller="inventoryLocationDetailed" action="create">add Location</g:link></p> |
---|
[175] | 58 | </td> |
---|
| 59 | </tr> |
---|
[116] | 60 | |
---|
| 61 | <tr class="prop"> |
---|
| 62 | <td valign="top" class="name"> |
---|
| 63 | <label for="reorderPoint">Reorder Point:</label> |
---|
| 64 | </td> |
---|
[223] | 65 | <td valign="top"> |
---|
| 66 | <input class="medium ${hasErrors(bean:inventoryItemInstance,field:'reorderPoint','errors')}" |
---|
| 67 | type="text" id="reorderPoint" name="reorderPoint" |
---|
| 68 | value="${fieldValue(bean:inventoryItemInstance,field:'reorderPoint')}" /> |
---|
[382] | 69 | <g:select optionKey="id" |
---|
| 70 | from="${UnitOfMeasure.list()}" |
---|
| 71 | name="unitOfMeasure.id" |
---|
| 72 | value="${inventoryItemInstance?.unitOfMeasure?.id}" > |
---|
| 73 | </g:select> |
---|
[116] | 74 | </td> |
---|
| 75 | </tr> |
---|
| 76 | |
---|
| 77 | <tr class="prop"> |
---|
| 78 | <td valign="top" class="name"> |
---|
| 79 | <label for="enableReorder">Enable Reorder:</label> |
---|
| 80 | </td> |
---|
| 81 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'enableReorder','errors')}"> |
---|
| 82 | <g:checkBox name="enableReorder" value="${inventoryItemInstance?.enableReorder}" ></g:checkBox> |
---|
| 83 | </td> |
---|
[175] | 84 | </tr> |
---|
[116] | 85 | |
---|
| 86 | <tr class="prop"> |
---|
| 87 | <td valign="top" class="name"> |
---|
| 88 | <label for="inventoryGroup">Inventory Group:</label> |
---|
| 89 | </td> |
---|
| 90 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'inventoryGroup','errors')}"> |
---|
| 91 | <g:select optionKey="id" from="${InventoryGroup.list()}" name="inventoryGroup.id" value="${inventoryItemInstance?.inventoryGroup?.id}" ></g:select> |
---|
[382] | 92 | |
---|
| 93 | <p><g:link controller="inventoryGroupDetailed" action="create">add Group</g:link></p> |
---|
[116] | 94 | </td> |
---|
| 95 | </tr> |
---|
| 96 | |
---|
| 97 | <tr class="prop"> |
---|
| 98 | <td valign="top" class="name"> |
---|
| 99 | <label for="inventoryType">Inventory Type:</label> |
---|
| 100 | </td> |
---|
| 101 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'inventoryType','errors')}"> |
---|
| 102 | <g:select optionKey="id" from="${InventoryType.list()}" name="inventoryType.id" value="${inventoryItemInstance?.inventoryType?.id}" ></g:select> |
---|
| 103 | </td> |
---|
[175] | 104 | </tr> |
---|
[116] | 105 | |
---|
| 106 | <tr class="prop"> |
---|
| 107 | <td valign="top" class="name"> |
---|
[223] | 108 | <label for="averageDeliveryTime">Average Delivery Time:</label> |
---|
[116] | 109 | </td> |
---|
[223] | 110 | <td valign="top"> |
---|
| 111 | <input class="medium ${hasErrors(bean:inventoryItemInstance,field:'averageDeliveryTime','errors')}" |
---|
| 112 | type="text" id="averageDeliveryTime" name="averageDeliveryTime" |
---|
| 113 | value="${fieldValue(bean:inventoryItemInstance,field:'averageDeliveryTime')}" /> |
---|
| 114 | <g:select optionKey="id" from="${Period.list()}" name="averageDeliveryPeriod.id" value="${inventoryItemInstance?.averageDeliveryPeriod?.id}" noSelection="['null':'--None--']"></g:select> |
---|
[116] | 115 | </td> |
---|
[175] | 116 | </tr> |
---|
[116] | 117 | |
---|
| 118 | <tr class="prop"> |
---|
| 119 | <td valign="top" class="name"> |
---|
| 120 | <label for="suppliersPartNumber">Suppliers Part Number:</label> |
---|
| 121 | </td> |
---|
| 122 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'suppliersPartNumber','errors')}"> |
---|
| 123 | <input type="text" id="suppliersPartNumber" name="suppliersPartNumber" value="${fieldValue(bean:inventoryItemInstance,field:'suppliersPartNumber')}"/> |
---|
| 124 | </td> |
---|
[175] | 125 | </tr> |
---|
[116] | 126 | |
---|
| 127 | <tr class="prop"> |
---|
| 128 | <td valign="top" class="name"> |
---|
[175] | 129 | <label for="suppliers">Suppliers:</label> |
---|
[116] | 130 | </td> |
---|
[175] | 131 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'suppliers','errors')}"> |
---|
| 132 | <g:select id="suppliers" name="suppliers" |
---|
[382] | 133 | from="${ Supplier.list().sort { p1, p2 -> p1.name.compareToIgnoreCase(p2.name) } }" |
---|
[175] | 134 | size="5" multiple="yes" optionKey="id" |
---|
| 135 | value="${inventoryItemInstance?.suppliers?.id}" noSelection="['':'--None--']"/> |
---|
| 136 | |
---|
[382] | 137 | <p><g:link controller="supplierDetailed" action="create">add Supplier</g:link></p> |
---|
[116] | 138 | </td> |
---|
[175] | 139 | </tr> |
---|
[116] | 140 | |
---|
| 141 | <tr class="prop"> |
---|
| 142 | <td valign="top" class="name"> |
---|
[223] | 143 | <label for="manufacturersPartNumber">Manufacturers Part Number:</label> |
---|
[116] | 144 | </td> |
---|
[223] | 145 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'manufacturersPartNumber','errors')}"> |
---|
| 146 | <input type="text" id="manufacturersPartNumber" name="manufacturersPartNumber" value="${fieldValue(bean:inventoryItemInstance,field:'manufacturersPartNumber')}"/> |
---|
[116] | 147 | </td> |
---|
[223] | 148 | </tr> |
---|
| 149 | |
---|
| 150 | <tr class="prop"> |
---|
| 151 | <td valign="top" class="name"> |
---|
| 152 | <label for="manufacturers">Manufacturers:</label> |
---|
| 153 | </td> |
---|
| 154 | <td valign="top" class="value ${hasErrors(bean:inventoryItemInstance,field:'manufacturers','errors')}"> |
---|
| 155 | <g:select id="manufacturers" name="manufacturers" |
---|
[382] | 156 | from="${ Manufacturer.list().sort { p1, p2 -> p1.name.compareToIgnoreCase(p2.name) } }" |
---|
[223] | 157 | size="5" multiple="yes" optionKey="id" |
---|
| 158 | value="${inventoryItemInstance?.manufacturers?.id}" noSelection="['':'--None--']" /> |
---|
| 159 | |
---|
[382] | 160 | <p><g:link controller="manufacturerDetailed" action="create">add Manufacturer</g:link></p> |
---|
[223] | 161 | </td> |
---|
[175] | 162 | </tr> |
---|
[116] | 163 | |
---|
| 164 | </tbody> |
---|
| 165 | </table> |
---|
| 166 | </div> |
---|
| 167 | <div class="buttons"> |
---|
| 168 | <span class="button"><input class="save" type="submit" value="Create" /></span> |
---|
| 169 | </div> |
---|
| 170 | </g:form> |
---|
| 171 | </div> |
---|
| 172 | </body> |
---|
| 173 | </html> |
---|