source: trunk/grails-app/views/inventoryItemPurchaseDetailed/create.gsp @ 595

Last change on this file since 595 was 595, checked in by gav, 14 years ago

Improve work flow when working from inventoryItemPurchase search view.

File size: 5.4 KB
Line 
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>Create InventoryItemPurchase</title>
8        <nav:resources override="true"/>
9    </head>
10    <body>
11        <div class="nav">
12            <h1>Order Inventory</h1>
13        </div>
14        <div class="body">
15            <g:render template="/shared/messages" />
16            <g:hasErrors bean="${inventoryItemPurchaseInstance}">
17            <div class="errors">
18                <g:renderErrors bean="${inventoryItemPurchaseInstance}" as="list" />
19            </div>
20            </g:hasErrors>
21            <g:form action="save" method="post" >
22                <g:hiddenField name="inventoryItem.id" value="${inventoryItemPurchaseInstance?.inventoryItem?.id}" />
23                <g:hiddenField name="returnTo" value="${params.returnTo}" />
24                <div class="dialog">
25                    <table>
26                        <tbody>
27                       
28                            <tr class="prop">
29                                <td valign="top" class="name">
30                                    <label for="inventoryItem">Inventory Item:</label>
31                                </td>
32                                <td valign="top" class="value">
33                                    <g:link controller="inventoryItemDetailed"
34                                                    action="show"
35                                                    id="${inventoryItemPurchaseInstance.inventoryItem.id}">
36                                        ${inventoryItemPurchaseInstance.inventoryItem.encodeAsHTML()}
37                                    </g:link>
38                                </td>
39                            </tr>
40                       
41                            <tr class="prop">
42                                <td valign="top" class="name">
43                                    <label for="purchaseOrderNumber">Purchase Order #:</label>
44                                </td>
45                                <td valign="top" class="value ${hasErrors(bean:inventoryItemPurchaseInstance,field:'purchaseOrderNumber','errors')}">
46                                    <input type="text" maxlength="50" id="purchaseOrderNumber" name="purchaseOrderNumber" value="${fieldValue(bean:inventoryItemPurchaseInstance,field:'purchaseOrderNumber')}"/>
47                                </td>
48                            </tr>
49                       
50                            <tr class="prop">
51                                <td valign="top" class="name">
52                                    <label for="costCode">Cost Code:</label>
53                                </td>
54                                <td valign="top" class="value ${hasErrors(bean:inventoryItemPurchaseInstance,field:'costCode','errors')}">
55                                    <g:select optionKey="id"
56                                                        from="${ CostCode.findAllByIsActive(true).sort { p1, p2 -> p1.name.compareToIgnoreCase(p2.name) } }"
57                                                        name="costCode.id"
58                                                        value="${inventoryItemPurchaseInstance?.costCode?.id}"
59                                                        noSelection="['null':'']"></g:select>
60                                </td>
61                            </tr>
62                       
63                            <tr class="prop">
64                                <td valign="top" class="name">
65                                    <label for="quantity">Quantity:</label>
66                                </td>
67                                <td valign="top" class="value ${hasErrors(bean:inventoryItemPurchaseInstance,field:'quantity','errors')}">
68                                    <input type="text" id="quantity" name="quantity" value="${fieldValue(bean:inventoryItemPurchaseInstance,field:'quantity')}" />
69                                    ${inventoryItemPurchaseInstance.inventoryItem.unitOfMeasure.encodeAsHTML()}
70                                </td>
71                            </tr>
72                       
73                            <tr class="prop">
74                                <td valign="top" class="name">
75                                    <label for="orderValue">Purchase Order $:</label>
76                                </td>
77                                <td valign="top" class="value">
78                                    <input  class="medium ${hasErrors(bean:inventoryItemPurchaseInstance,field:'orderValueAmount','errors')}"
79                                                    type="text" id="orderValueAmount" name="orderValueAmount"
80                                                    value="${inventoryItemPurchaseInstance.orderValueAmount}" />
81                                    <g:currencySelect name="orderValueCurrency"
82                                                                        value="${inventoryItemPurchaseInstance.orderValueCurrency}" />
83                                </td>
84                            </tr>
85                       
86                        </tbody>
87                    </table>
88                </div>
89                <div class="buttons">
90                    <span class="button"><input class="save" type="submit" value="Create" /></span>
91                </div>
92            </g:form>
93        </div>
94    </body>
95</html>
Note: See TracBrowser for help on using the repository browser.