source: trunk/grails-app/views/manufacturer/edit.gsp @ 178

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

Resolve ticket #12 again.
Turn query cache on again since this did not resolve the problem.
Implement fix as per http://jira.codehaus.org/browse/GRAILS-5111, add flush:true to save.
Adjust templates to include above and remove home url.
Re-generate all non detailed views and controllers.
Manually add flush:true and remove home url to detailed views and controllers.

File size: 4.5 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>Edit Manufacturer</title>
8    </head>
9    <body>
10        <div class="nav">
11            <span class="menuButton"><g:link class="list" action="list">Manufacturer List</g:link></span>
12            <span class="menuButton"><g:link class="create" action="create">New Manufacturer</g:link></span>
13        </div>
14        <div class="body">
15            <h1>Edit Manufacturer</h1>
16            <g:if test="${flash.message}">
17            <div class="message">${flash.message}</div>
18            </g:if>
19            <g:hasErrors bean="${manufacturerInstance}">
20            <div class="errors">
21                <g:renderErrors bean="${manufacturerInstance}" as="list" />
22            </div>
23            </g:hasErrors>
24            <g:form method="post" >
25                <input type="hidden" name="id" value="${manufacturerInstance?.id}" />
26                <input type="hidden" name="version" value="${manufacturerInstance?.version}" />
27                <div class="dialog">
28                    <table>
29                        <tbody>
30                       
31                            <tr class="prop">
32                                <td valign="top" class="name">
33                                    <label for="description">Description:</label>
34                                </td>
35                                <td valign="top" class="value ${hasErrors(bean:manufacturerInstance,field:'description','errors')}">
36                                    <input type="text" id="description" name="description" value="${fieldValue(bean:manufacturerInstance,field:'description')}"/>
37                                </td>
38                            </tr>
39                       
40                            <tr class="prop">
41                                <td valign="top" class="name">
42                                    <label for="inventoryItems">Inventory Items:</label>
43                                </td>
44                                <td valign="top" class="value ${hasErrors(bean:manufacturerInstance,field:'inventoryItems','errors')}">
45                                   
46                                </td>
47                            </tr>
48                       
49                            <tr class="prop">
50                                <td valign="top" class="name">
51                                    <label for="isActive">Is Active:</label>
52                                </td>
53                                <td valign="top" class="value ${hasErrors(bean:manufacturerInstance,field:'isActive','errors')}">
54                                    <g:checkBox name="isActive" value="${manufacturerInstance?.isActive}" ></g:checkBox>
55                                </td>
56                            </tr>
57                       
58                            <tr class="prop">
59                                <td valign="top" class="name">
60                                    <label for="manufacturerType">Manufacturer Type:</label>
61                                </td>
62                                <td valign="top" class="value ${hasErrors(bean:manufacturerInstance,field:'manufacturerType','errors')}">
63                                    <g:select optionKey="id" from="${ManufacturerType.list()}" name="manufacturerType.id" value="${manufacturerInstance?.manufacturerType?.id}" ></g:select>
64                                </td>
65                            </tr>
66                       
67                            <tr class="prop">
68                                <td valign="top" class="name">
69                                    <label for="name">Name:</label>
70                                </td>
71                                <td valign="top" class="value ${hasErrors(bean:manufacturerInstance,field:'name','errors')}">
72                                    <input type="text" id="name" name="name" value="${fieldValue(bean:manufacturerInstance,field:'name')}"/>
73                                </td>
74                            </tr>
75                       
76                        </tbody>
77                    </table>
78                </div>
79                <div class="buttons">
80                    <span class="button"><g:actionSubmit class="save" value="Update" /></span>
81                    <span class="button"><g:actionSubmit class="delete" onclick="return confirm('Are you sure?');" value="Delete" /></span>
82                </div>
83            </g:form>
84        </div>
85    </body>
86</html>
Note: See TracBrowser for help on using the repository browser.