[402] | 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 Contact</title> |
---|
| 8 | </head> |
---|
| 9 | <body> |
---|
| 10 | <div class="nav"> |
---|
| 11 | <h1>Edit Contact</h1> |
---|
| 12 | </div> |
---|
| 13 | <div class="body"> |
---|
| 14 | <g:render template="/shared/messages" /> |
---|
| 15 | <g:hasErrors bean="${contactInstance}"> |
---|
| 16 | <div class="errors"> |
---|
| 17 | <g:renderErrors bean="${contactInstance}" as="list" /> |
---|
| 18 | </div> |
---|
| 19 | </g:hasErrors> |
---|
| 20 | <g:form method="post" > |
---|
| 21 | <input type="hidden" name="id" value="${contactInstance?.id}" /> |
---|
| 22 | <input type="hidden" name="version" value="${contactInstance?.version}" /> |
---|
| 23 | <div class="dialog"> |
---|
| 24 | <table> |
---|
| 25 | <tbody> |
---|
| 26 | |
---|
| 27 | <g:if test="${contactInstance.supplier}"> |
---|
| 28 | <g:hiddenField name="supplier.id" value="${contactInstance.supplier.id}"/> |
---|
| 29 | <tr class="prop"> |
---|
| 30 | <td valign="top" class="name"> |
---|
| 31 | <label for="supplier">Supplier:</label> |
---|
| 32 | </td> |
---|
| 33 | <td valign="top" class="value ${hasErrors(bean:contactInstance,field:'supplier','errors')}"> |
---|
| 34 | <g:link controller="supplierDetailed" action="show" id="${contactInstance.supplier.id}"> |
---|
| 35 | ${contactInstance.supplier.encodeAsHTML()} |
---|
| 36 | </g:link> |
---|
| 37 | </td> |
---|
| 38 | </tr> |
---|
| 39 | </g:if> |
---|
| 40 | |
---|
| 41 | <g:if test="${contactInstance.person}"> |
---|
| 42 | <g:hiddenField name="person.id" value="${contactInstance.person.id}"/> |
---|
| 43 | <tr class="prop"> |
---|
| 44 | <td valign="top" class="name"> |
---|
| 45 | <label for="person">Person:</label> |
---|
| 46 | </td> |
---|
| 47 | <td valign="top" class="value"> |
---|
| 48 | <g:link controller="person" action="show" id="${contactInstance.person.id}"> |
---|
| 49 | ${contactInstance.person.encodeAsHTML()} |
---|
| 50 | </g:link> |
---|
| 51 | </td> |
---|
| 52 | </tr> |
---|
| 53 | </g:if> |
---|
| 54 | |
---|
| 55 | <g:if test="${contactInstance.site}"> |
---|
| 56 | <g:hiddenField name="site.id" value="${contactInstance.site.id}"/> |
---|
| 57 | <tr class="prop"> |
---|
| 58 | <td valign="top" class="name"> |
---|
| 59 | <label for="site">Site:</label> |
---|
| 60 | </td> |
---|
| 61 | <td valign="top" class="value"> |
---|
| 62 | <g:link controller="siteDetailed" action="show" id="${contactInstance.site.id}"> |
---|
| 63 | ${contactInstance.site.encodeAsHTML()} |
---|
| 64 | </g:link> |
---|
| 65 | </td> |
---|
| 66 | </tr> |
---|
| 67 | </g:if> |
---|
| 68 | |
---|
| 69 | <tr class="prop"> |
---|
| 70 | <td valign="top" class="name"> |
---|
| 71 | <label for="contactType">Contact Type:</label> |
---|
| 72 | </td> |
---|
| 73 | <td valign="top" class="value ${hasErrors(bean:contactInstance,field:'contactType','errors')}"> |
---|
| 74 | <g:select optionKey="id" from="${ContactType.list()}" name="contactType.id" value="${contactInstance?.contactType?.id}" ></g:select> |
---|
| 75 | </td> |
---|
| 76 | </tr> |
---|
| 77 | |
---|
| 78 | <tr class="prop"> |
---|
| 79 | <td valign="top" class="name"> |
---|
| 80 | <label for="email">Value:</label> |
---|
| 81 | </td> |
---|
| 82 | <td valign="top" class="value ${hasErrors(bean:contactInstance,field:'value','errors')}"> |
---|
| 83 | <input type="text" id="value" name="value" value="${fieldValue(bean:contactInstance,field:'value')}"/> |
---|
| 84 | </td> |
---|
| 85 | </tr> |
---|
| 86 | |
---|
| 87 | </tbody> |
---|
| 88 | </table> |
---|
| 89 | </div> |
---|
| 90 | <div class="buttons"> |
---|
| 91 | <span class="button"><g:actionSubmit class="save" value="Update" /></span> |
---|
| 92 | <span class="button"><g:actionSubmit class="cancel" value="Cancel" action="Show"/></span> |
---|
| 93 | <span class="button"><g:actionSubmit class="delete" onclick="return confirm('Are you sure?');" value="Delete" /></span> |
---|
| 94 | </div> |
---|
| 95 | </g:form> |
---|
| 96 | </div> |
---|
| 97 | </body> |
---|
| 98 | </html> |
---|