[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>Show InventoryItem</title> |
---|
[139] | 8 | <nav:resources override="true"/> |
---|
[225] | 9 | <resource:tabView skin="tabviewCustom" /> |
---|
[182] | 10 | <g:render template="/shared/pictureHead" /> |
---|
[116] | 11 | </head> |
---|
| 12 | <body> |
---|
| 13 | <div class="nav"> |
---|
[139] | 14 | <nav:renderSubItems group="nav"/> |
---|
[116] | 15 | </div> |
---|
| 16 | <div class="body"> |
---|
[405] | 17 | <g:render template="/shared/messages" /> |
---|
[225] | 18 | <g:hasErrors bean="${inventoryMovementInstance}"> |
---|
[405] | 19 | <div class="errors"> |
---|
| 20 | <g:renderErrors bean="${inventoryMovementInstance}" as="list" /> |
---|
| 21 | </div> |
---|
[225] | 22 | </g:hasErrors> |
---|
[175] | 23 | |
---|
[225] | 24 | <g:hasErrors bean="${inventoryItemInstance}"> |
---|
[405] | 25 | <div class="errors"> |
---|
| 26 | <g:renderErrors bean="${inventoryItemInstance}" as="list" /> |
---|
| 27 | </div> |
---|
[225] | 28 | </g:hasErrors> |
---|
| 29 | |
---|
[422] | 30 | <div class="tabHeader"> |
---|
| 31 | <h1 class="taskHeader"> |
---|
| 32 | ${inventoryItemInstance.name} |
---|
| 33 | </h1> |
---|
| 34 | ${fieldValue(bean:inventoryItemInstance, field:'description')} |
---|
| 35 | </div> |
---|
| 36 | |
---|
| 37 | <br/> |
---|
| 38 | |
---|
[225] | 39 | <richui:tabView id="tabView"> |
---|
| 40 | |
---|
| 41 | <richui:tabLabels> |
---|
| 42 | <richui:tabLabel selected="${showTab.inventory}" title="Inventory Item" /> |
---|
| 43 | <richui:tabLabel selected="${showTab.detail}" title="Detail" /> |
---|
| 44 | <richui:tabLabel selected="${showTab.movement}" title="Movement" /> |
---|
| 45 | </richui:tabLabels> |
---|
| 46 | |
---|
| 47 | <richui:tabContents> |
---|
| 48 | |
---|
| 49 | <!-- Start Inventory tab --> |
---|
| 50 | <richui:tabContent> |
---|
| 51 | |
---|
| 52 | <g:if test="${inventoryMovementInstance}" > |
---|
| 53 | |
---|
| 54 | <g:form controller="inventoryItemDetailed" method="post" > |
---|
| 55 | <div class="dialog"> |
---|
| 56 | <table> |
---|
| 57 | <tbody> |
---|
| 58 | <g:hiddenField name="task.id" value="${inventoryMovementInstance.task.id}"/> |
---|
| 59 | <g:hiddenField name="inventoryItem.id" value="${inventoryItemInstance.id}"/> |
---|
| 60 | <tr class="prop"> |
---|
| 61 | <td valign="top" class="name">Use on task:</td> |
---|
| 62 | <td valign="top" class="value"> |
---|
| 63 | <g:link controller="taskDetailed" action="show" id="${inventoryMovementInstance.task.id}" > |
---|
| 64 | ${Task.get(inventoryMovementInstance.task.id).encodeAsHTML()} |
---|
| 65 | </g:link> |
---|
| 66 | </td> |
---|
| 67 | </tr> |
---|
| 68 | |
---|
| 69 | <tr class="prop"> |
---|
| 70 | <td valign="top" class="name"> |
---|
| 71 | <label for="quantity">Quantity:</label> |
---|
| 72 | </td> |
---|
| 73 | <td valign="top"> |
---|
| 74 | <input class="medium ${hasErrors(bean:inventoryMovementInstance,field:'quantity','errors')}" |
---|
| 75 | type="text" id="quantity" name="quantity" |
---|
| 76 | value="${fieldValue(bean:inventoryMovementInstance,field:'quantity')}"/> |
---|
| 77 | ${inventoryItemInstance.unitOfMeasure?.encodeAsHTML()} |
---|
| 78 | |
---|
| 79 | <span class="buttons"> |
---|
| 80 | <g:actionSubmit action="useInventoryItem" class="save" value="${InventoryMovementType.get(1)}" /> |
---|
| 81 | </span> |
---|
| 82 | |
---|
| 83 | </td> |
---|
| 84 | </tr> |
---|
| 85 | |
---|
| 86 | </tbody> |
---|
| 87 | </table> |
---|
| 88 | </div> |
---|
| 89 | </g:form> |
---|
| 90 | |
---|
| 91 | <br /> |
---|
| 92 | |
---|
| 93 | </g:if> |
---|
| 94 | |
---|
| 95 | <div class="dialog"> |
---|
| 96 | <table> |
---|
| 97 | <tbody> |
---|
| 98 | |
---|
| 99 | <tr class="prop"> |
---|
| 100 | <td valign="top" class="name">Picture:</td> |
---|
| 101 | <td valign="top" class="value"> |
---|
| 102 | <g:if test="${inventoryItemInstance.picture}" > |
---|
| 103 | <span class='gallery'><wa:pictureLightboxAnchor picture="${inventoryItemInstance.picture}" size="${Image.Medium}" lightboxSize="${Image.Large}" target="_blank" title="Show Original" /></span> |
---|
| 104 | </g:if> |
---|
| 105 | <g:else> |
---|
| 106 | <g:link controller="pictureDetailed" |
---|
| 107 | params="['inventoryItem.id':inventoryItemInstance.id]" |
---|
| 108 | action="create"> |
---|
| 109 | Add Picture |
---|
| 110 | </g:link> |
---|
| 111 | </g:else> |
---|
| 112 | </td> |
---|
| 113 | </tr> |
---|
| 114 | |
---|
| 115 | <tr class="prop"> |
---|
[422] | 116 | <td valign="top" class="name">Comment:</td> |
---|
[225] | 117 | |
---|
[422] | 118 | <td valign="top" class="value">${fieldValue(bean:inventoryItemInstance, field:'comment')}</td> |
---|
[225] | 119 | </tr> |
---|
| 120 | |
---|
| 121 | <tr class="prop"> |
---|
| 122 | <td valign="top" class="name">In Stock:</td> |
---|
| 123 | |
---|
| 124 | <td valign="top" class="value"> |
---|
| 125 | ${fieldValue(bean:inventoryItemInstance, field:'unitsInStock')} ${inventoryItemInstance.unitOfMeasure.encodeAsHTML()} |
---|
| 126 | </td> |
---|
| 127 | </tr> |
---|
| 128 | |
---|
| 129 | <tr class="prop"> |
---|
| 130 | <td valign="top" class="name">Location:</td> |
---|
| 131 | |
---|
| 132 | <td valign="top" class="value"> |
---|
| 133 | <g:link controller="inventoryLocationDetailed" action="show" id="${inventoryItemInstance.inventoryLocation?.id}"> |
---|
| 134 | ${inventoryItemInstance.inventoryLocation?.encodeAsHTML()} |
---|
| 135 | </g:link> |
---|
[392] | 136 | in ${inventoryItemInstance.inventoryLocation?.inventoryStore.encodeAsHTML()} |
---|
[225] | 137 | </td> |
---|
| 138 | </tr> |
---|
| 139 | |
---|
| 140 | <tr class="prop"> |
---|
| 141 | <td valign="top" class="name">Active:</td> |
---|
| 142 | |
---|
| 143 | <td valign="top" class="value">${fieldValue(bean:inventoryItemInstance, field:'isActive')}</td> |
---|
| 144 | </tr> |
---|
| 145 | |
---|
| 146 | <tr class="prop"> |
---|
| 147 | <td valign="top" class="name">Alternate Items:</td> |
---|
| 148 | |
---|
| 149 | <td valign="top" style="text-align:left;" class="value"> |
---|
| 150 | <ul> |
---|
[425] | 151 | <g:each var="a" in="${ inventoryItemInstance.alternateItems.sort { p1, p2 -> p1.name.compareToIgnoreCase(p2.name) } }"> |
---|
[225] | 152 | <li><g:link controller="inventoryItemDetailed" action="show" id="${a.id}">${a?.encodeAsHTML()}</g:link></li> |
---|
| 153 | </g:each> |
---|
| 154 | </ul> |
---|
| 155 | </td> |
---|
| 156 | </tr> |
---|
| 157 | |
---|
| 158 | <tr class="prop"> |
---|
| 159 | <td valign="top" class="name">Spare For:</td> |
---|
| 160 | |
---|
| 161 | <td valign="top" style="text-align:left;" class="value"> |
---|
| 162 | <ul> |
---|
[382] | 163 | <g:each var="s" in="${ inventoryItemInstance.spareFor.sort { p1, p2 -> p1.name.compareToIgnoreCase(p2.name) } }"> |
---|
[225] | 164 | <li><g:link controller="assetDetailed" action="show" id="${s.id}">${s?.encodeAsHTML()}</g:link></li> |
---|
| 165 | </g:each> |
---|
| 166 | </ul> |
---|
| 167 | </td> |
---|
| 168 | </tr> |
---|
| 169 | |
---|
| 170 | </tbody> |
---|
| 171 | </table> |
---|
| 172 | </div> |
---|
| 173 | <div class="buttons"> |
---|
| 174 | <g:form> |
---|
| 175 | <g:hiddenField name="id" value="${inventoryItemInstance.id}" /> |
---|
| 176 | <span class="button"><g:actionSubmit class="edit" value="Edit" /></span> |
---|
| 177 | <span class="button"><g:actionSubmit class="delete" onclick="return confirm('Are you sure?');" value="Delete" /></span> |
---|
| 178 | </g:form> |
---|
| 179 | </div> |
---|
| 180 | |
---|
| 181 | <br /> |
---|
| 182 | |
---|
| 183 | </richui:tabContent> |
---|
| 184 | <!-- End Inventory tab --> |
---|
| 185 | |
---|
| 186 | <!-- Start Detail tab --> |
---|
| 187 | <richui:tabContent> |
---|
| 188 | |
---|
| 189 | <div class="dialog"> |
---|
| 190 | <table> |
---|
| 191 | <tbody> |
---|
| 192 | |
---|
| 193 | <tr class="prop"> |
---|
| 194 | <td valign="top" class="name">Id:</td> |
---|
| 195 | <td valign="top" class="value">${fieldValue(bean:inventoryItemInstance, field:'id')}</td> |
---|
| 196 | </tr> |
---|
| 197 | |
---|
| 198 | <tr class="prop"> |
---|
| 199 | <td valign="top" class="name">Obsolete:</td> |
---|
| 200 | <td valign="top" class="value">${fieldValue(bean:inventoryItemInstance, field:'isObsolete')}</td> |
---|
| 201 | </tr> |
---|
| 202 | |
---|
| 203 | <tr class="prop"> |
---|
| 204 | <td valign="top" class="name">Inventory Group:</td> |
---|
| 205 | <td valign="top" class="value">${inventoryItemInstance.inventoryGroup?.encodeAsHTML()}</td> |
---|
| 206 | </tr> |
---|
| 207 | |
---|
| 208 | <tr class="prop"> |
---|
| 209 | <td valign="top" class="name">Inventory Type:</td> |
---|
| 210 | <td valign="top" class="value">${inventoryItemInstance.inventoryType?.encodeAsHTML()}</td> |
---|
| 211 | </tr> |
---|
| 212 | |
---|
| 213 | <tr class="prop"> |
---|
| 214 | <td valign="top" class="name">Reorder Point:</td> |
---|
| 215 | <td valign="top" class="value">${fieldValue(bean:inventoryItemInstance, field:'reorderPoint')}</td> |
---|
| 216 | </tr> |
---|
| 217 | |
---|
| 218 | <tr class="prop"> |
---|
| 219 | <td valign="top" class="name">Enable Reorder:</td> |
---|
| 220 | <td valign="top" class="value">${fieldValue(bean:inventoryItemInstance, field:'enableReorder')}</td> |
---|
| 221 | </tr> |
---|
| 222 | |
---|
| 223 | <tr class="prop"> |
---|
| 224 | <td valign="top" class="name">Recommended Reorder Point:</td> |
---|
| 225 | <td valign="top" class="value">${fieldValue(bean:inventoryItemInstance, field:'recommendedReorderPoint')}</td> |
---|
| 226 | </tr> |
---|
| 227 | |
---|
| 228 | <tr class="prop"> |
---|
[405] | 229 | <td valign="top" class="name">Estimated Unit Price:</td> |
---|
| 230 | |
---|
| 231 | <td valign="top" class="value"> |
---|
| 232 | <g:if test="${inventoryItemInstance.estimatedUnitPriceAmount}"> |
---|
| 233 | ${inventoryItemInstance.estimatedUnitPriceAmount.encodeAsHTML()} |
---|
| 234 | ${inventoryItemInstance.estimatedUnitPriceCurrency.encodeAsHTML()} |
---|
| 235 | </g:if> |
---|
| 236 | </td> |
---|
| 237 | </tr> |
---|
| 238 | |
---|
| 239 | <tr class="prop"> |
---|
[225] | 240 | <td valign="top" class="name">Suppliers Part Number:</td> |
---|
| 241 | <td valign="top" class="value">${fieldValue(bean:inventoryItemInstance, field:'suppliersPartNumber')}</td> |
---|
| 242 | </tr> |
---|
| 243 | |
---|
| 244 | <tr class="prop"> |
---|
| 245 | <td valign="top" class="name">Suppliers:</td> |
---|
| 246 | |
---|
| 247 | <td valign="top" style="text-align:left;" class="value"> |
---|
| 248 | <ul> |
---|
[382] | 249 | <g:each var="s" in="${ inventoryItemInstance.suppliers.sort { p1, p2 -> p1.name.compareToIgnoreCase(p2.name) } }"> |
---|
[225] | 250 | <li><g:link controller="supplierDetailed" action="show" id="${s.id}">${s?.encodeAsHTML()}</g:link></li> |
---|
| 251 | </g:each> |
---|
| 252 | </ul> |
---|
| 253 | </td> |
---|
| 254 | </tr> |
---|
| 255 | |
---|
| 256 | <tr class="prop"> |
---|
| 257 | <td valign="top" class="name">Average Delivery Time:</td> |
---|
| 258 | <td valign="top" class="value"> |
---|
| 259 | ${fieldValue(bean:inventoryItemInstance, field:'averageDeliveryTime')} |
---|
| 260 | ${fieldValue(bean:inventoryItemInstance, field:'averageDeliveryPeriod')} |
---|
| 261 | </td> |
---|
| 262 | </tr> |
---|
| 263 | |
---|
| 264 | <tr class="prop"> |
---|
| 265 | <td valign="top" class="name">Manufacturers Part Number:</td> |
---|
| 266 | <td valign="top" class="value">${fieldValue(bean:inventoryItemInstance, field:'manufacturersPartNumber')}</td> |
---|
| 267 | </tr> |
---|
| 268 | |
---|
| 269 | <tr class="prop"> |
---|
| 270 | <td valign="top" class="name">Manufacturers:</td> |
---|
| 271 | |
---|
| 272 | <td valign="top" style="text-align:left;" class="value"> |
---|
| 273 | <ul> |
---|
[382] | 274 | <g:each var="m" in="${ inventoryItemInstance.manufacturers.sort { p1, p2 -> p1.name.compareToIgnoreCase(p2.name) } }"> |
---|
[225] | 275 | <li><g:link controller="manufacturerDetailed" action="show" id="${m.id}">${m?.encodeAsHTML()}</g:link></li> |
---|
| 276 | </g:each> |
---|
| 277 | </ul> |
---|
| 278 | </td> |
---|
| 279 | </tr> |
---|
| 280 | |
---|
| 281 | |
---|
| 282 | </tbody> |
---|
| 283 | </table> |
---|
| 284 | </div> |
---|
| 285 | <div class="buttons"> |
---|
| 286 | <g:form> |
---|
| 287 | <g:hiddenField name="id" value="${inventoryItemInstance.id}" /> |
---|
| 288 | <span class="button"><g:actionSubmit class="edit" value="Edit" /></span> |
---|
| 289 | <span class="button"><g:actionSubmit class="delete" onclick="return confirm('Are you sure?');" value="Delete" /></span> |
---|
| 290 | </g:form> |
---|
| 291 | </div> |
---|
| 292 | </richui:tabContent> |
---|
| 293 | <!-- End Detail tab --> |
---|
| 294 | |
---|
| 295 | <!-- Start Movement tab --> |
---|
| 296 | <richui:tabContent> |
---|
| 297 | |
---|
| 298 | <g:if test="${inventoryMovementList.isEmpty()}"> |
---|
| 299 | <br /> |
---|
| 300 | No Inventory Movements. |
---|
| 301 | <br /> |
---|
| 302 | <br /> |
---|
| 303 | |
---|
| 304 | <div class="buttons"> |
---|
| 305 | <g:form controller="inventoryMovementDetailed"> |
---|
[226] | 306 | <g:hiddenField name="inventoryItem.id" value="${inventoryItemInstance.id}" /> |
---|
[225] | 307 | <span class="button"><g:actionSubmit action="create" class="add" value="Create" /></span> |
---|
| 308 | </g:form> |
---|
| 309 | </div> |
---|
| 310 | |
---|
| 311 | </g:if> |
---|
| 312 | <g:else> |
---|
| 313 | |
---|
| 314 | <div class="list"> |
---|
| 315 | <table> |
---|
| 316 | <thead> |
---|
| 317 | <tr> |
---|
| 318 | <th>Quantity</th> |
---|
| 319 | <th>Movement Type</th> |
---|
| 320 | <th>Date</th> |
---|
| 321 | <th>Person</th> |
---|
| 322 | <th></th> |
---|
| 323 | </tr> |
---|
| 324 | </thead> |
---|
| 325 | <tbody> |
---|
| 326 | <g:each in="${inventoryMovementList}" status="i" var="movements"> |
---|
| 327 | <tr class="${(i % 2) == 0 ? 'clickableOdd' : 'clickableEven'}" onclick='window.location = "${request.getContextPath()}/inventoryMovementDetailed/show/${movements.id}"'/> |
---|
| 328 | |
---|
| 329 | <td>${fieldValue(bean:movements, field:'quantity')}</td> |
---|
| 330 | <td>${fieldValue(bean:movements, field:'inventoryMovementType')}</td> |
---|
| 331 | <td><g:formatDate date="${movements.date}" format="EEE, dd-MMM-yyyy"/></td> |
---|
| 332 | <td>${fieldValue(bean:movements, field:'person')}</td> |
---|
| 333 | <td> |
---|
| 334 | <g:link controller="inventoryMovementDetailed" action="show" id="${movements.id}"> |
---|
| 335 | <img src="${resource(dir:'images/skin',file:'database_go.png')}" alt="Show" /> |
---|
| 336 | </g:link> |
---|
| 337 | </td> |
---|
| 338 | |
---|
| 339 | </tr> |
---|
| 340 | </g:each> |
---|
| 341 | </tbody> |
---|
| 342 | </table> |
---|
| 343 | </div> |
---|
| 344 | |
---|
| 345 | <div class="buttons"> |
---|
| 346 | <g:form controller="inventoryMovementDetailed"> |
---|
[226] | 347 | <g:hiddenField name="inventoryItem.id" value="${inventoryItemInstance.id}" /> |
---|
[225] | 348 | <g:if test="${inventoryMovementListTotal > inventoryMovementListMax}"> |
---|
| 349 | Showing ${inventoryMovementListMax} of ${inventoryMovementListTotal} |
---|
| 350 | <br /> |
---|
| 351 | </g:if> |
---|
| 352 | <g:else> |
---|
| 353 | Total ${inventoryMovementListTotal} |
---|
| 354 | <br /> |
---|
| 355 | </g:else> |
---|
| 356 | <span class="button"><g:actionSubmit action="listInventoryMovements" class="table" value="List" /></span> |
---|
| 357 | <span class="button"><g:actionSubmit action="create" class="add" value="Create" /></span> |
---|
| 358 | </g:form> |
---|
| 359 | </div> |
---|
| 360 | |
---|
| 361 | </g:else> |
---|
| 362 | |
---|
| 363 | </richui:tabContent> |
---|
| 364 | <!-- End Movement tab --> |
---|
| 365 | |
---|
| 366 | </richui:tabContents> |
---|
| 367 | </richui:tabView> |
---|
| 368 | |
---|
| 369 | |
---|
[116] | 370 | </div> |
---|
| 371 | </body> |
---|
| 372 | </html> |
---|