[59] | 1 | <head> |
---|
[150] | 2 | <meta name="layout" content="main" /> |
---|
| 3 | <title>Create Person</title> |
---|
[147] | 4 | <nav:resources override="true"/> |
---|
[59] | 5 | </head> |
---|
| 6 | |
---|
| 7 | <body> |
---|
| 8 | |
---|
[150] | 9 | <div class="nav"> |
---|
[147] | 10 | <nav:renderSubItems group="navAlt"/> |
---|
[150] | 11 | </div> |
---|
[59] | 12 | |
---|
[150] | 13 | <div class="body"> |
---|
| 14 | <g:if test="${flash.message}"> |
---|
| 15 | <div class="message">${flash.message}</div> |
---|
| 16 | </g:if> |
---|
| 17 | <g:if test="${params.message}"> |
---|
| 18 | <div class="message">${params.message}</div> |
---|
| 19 | </g:if> |
---|
| 20 | <g:hasErrors bean="${person}"> |
---|
| 21 | <div class="errors"> |
---|
| 22 | <g:renderErrors bean="${person}" as="list" /> |
---|
| 23 | </div> |
---|
| 24 | </g:hasErrors> |
---|
| 25 | <g:form action="save"> |
---|
| 26 | <div class="dialog"> |
---|
| 27 | <table> |
---|
| 28 | <tbody> |
---|
[59] | 29 | |
---|
[150] | 30 | <tr class="prop"> |
---|
| 31 | <td valign="top" class="name"><label for="loginName">Login Name:</label></td> |
---|
| 32 | <td valign="top" class="value ${hasErrors(bean:person,field:'loginName','errors')}"> |
---|
| 33 | <input type="text" id="loginName" name="loginName" value="${person.loginName?.encodeAsHTML()}"/> |
---|
| 34 | </td> |
---|
| 35 | </tr> |
---|
[59] | 36 | |
---|
[150] | 37 | <tr class="prop"> |
---|
| 38 | <td valign="top" class="name"><label for="firstName">First Name:</label></td> |
---|
| 39 | <td valign="top" class="value ${hasErrors(bean:person,field:'firstName','errors')}"> |
---|
| 40 | <input type="text" id="firstName" name="firstName" value="${person.firstName?.encodeAsHTML()}"/> |
---|
| 41 | </td> |
---|
| 42 | </tr> |
---|
[59] | 43 | |
---|
| 44 | <tr class="prop"> |
---|
| 45 | <td valign="top" class="name"><label for="lastName">Last Name:</label></td> |
---|
| 46 | <td valign="top" class="value ${hasErrors(bean:person,field:'lastName','errors')}"> |
---|
| 47 | <input type="text" id="lastName" name="lastName" value="${person.lastName?.encodeAsHTML()}"/> |
---|
| 48 | </td> |
---|
| 49 | </tr> |
---|
| 50 | |
---|
| 51 | |
---|
[150] | 52 | <tr class="prop"> |
---|
| 53 | <td valign="top" class="name"><label for="pass">Password:</label></td> |
---|
| 54 | <td valign="top" class="value ${hasErrors(bean:person,field:'pass','errors')}"> |
---|
| 55 | <input type="password" id="pass" name="pass"/> |
---|
| 56 | </td> |
---|
| 57 | </tr> |
---|
[59] | 58 | |
---|
[150] | 59 | <tr class="prop"> |
---|
| 60 | <td valign="top" class="name"><label for="isActive">isActive:</label></td> |
---|
| 61 | <td valign="top" class="value ${hasErrors(bean:person,field:'isActive','errors')}"> |
---|
| 62 | <g:checkBox name="isActive" value="${person.isActive}" ></g:checkBox> |
---|
| 63 | </td> |
---|
| 64 | </tr> |
---|
[59] | 65 | |
---|
[150] | 66 | <tr class="prop"> |
---|
| 67 | <td valign="top" class="name"><label for="description">Description:</label></td> |
---|
| 68 | <td valign="top" class="value ${hasErrors(bean:person,field:'description','errors')}"> |
---|
| 69 | <input type="text" id="description" name="description" value="${person.description?.encodeAsHTML()}"/> |
---|
| 70 | </td> |
---|
| 71 | </tr> |
---|
[59] | 72 | |
---|
[150] | 73 | <tr class="prop"> |
---|
| 74 | <td valign="top" class="name"><label for="email">Email:</label></td> |
---|
| 75 | <td valign="top" class="value ${hasErrors(bean:person,field:'email','errors')}"> |
---|
| 76 | <input type="text" id="email" name="email" value="${person.email?.encodeAsHTML()}"/> |
---|
| 77 | </td> |
---|
| 78 | </tr> |
---|
[59] | 79 | |
---|
[150] | 80 | <tr class="prop"> |
---|
| 81 | <td valign="top" class="name"><label for="emailShow">Show Email:</label></td> |
---|
| 82 | <td valign="top" class="value ${hasErrors(bean:person,field:'emailShow','errors')}"> |
---|
| 83 | <g:checkBox name="emailShow" value="${person.emailShow}"/> |
---|
| 84 | </td> |
---|
| 85 | </tr> |
---|
[59] | 86 | |
---|
| 87 | <tr class="prop"> |
---|
| 88 | <td valign="top" class="name"><label for="employeeID">employee ID:</label></td> |
---|
| 89 | <td valign="top" class="value ${hasErrors(bean:person,field:'employeeID','errors')}"> |
---|
| 90 | <input type="text" id="employeeID" name="employeeID" value="${person.employeeID?.encodeAsHTML()}"/> |
---|
| 91 | </td> |
---|
| 92 | </tr> |
---|
| 93 | |
---|
[150] | 94 | <tr class="prop"> |
---|
[164] | 95 | <td valign="top" class="name"> |
---|
| 96 | <label for="department">Department:</label> |
---|
| 97 | </td> |
---|
| 98 | <td valign="top" class="value ${hasErrors(bean:person,field:'department','errors')}"> |
---|
| 99 | <g:select optionKey="id" from="${Department.list()}" name="department.id" value="${person?.department?.id}" noSelection="['null':'']"></g:select> |
---|
| 100 | </td> |
---|
| 101 | </tr> |
---|
| 102 | |
---|
| 103 | <tr class="prop"> |
---|
| 104 | <td valign="top" class="name"> |
---|
| 105 | <label for="personGroups">Groups:</label> |
---|
| 106 | </td> |
---|
| 107 | <td valign="top" class="value ${hasErrors(bean:person,field:'personGroups','errors')}"> |
---|
| 108 | <g:select name="personGroups" |
---|
| 109 | from="${PersonGroup.list()}" |
---|
| 110 | size="5" multiple="yes" optionKey="id" |
---|
| 111 | value="${person?.personGroups}" /> |
---|
| 112 | |
---|
| 113 | </td> |
---|
| 114 | </tr> |
---|
| 115 | |
---|
| 116 | <tr class="prop"> |
---|
[150] | 117 | <td valign="top" class="name" align="left">Authorities:</td> |
---|
| 118 | </tr> |
---|
[59] | 119 | |
---|
[150] | 120 | <g:each in="${authorityList}"> |
---|
| 121 | <tr> |
---|
| 122 | <td valign="top" class="name" align="left">${it.authority.encodeAsHTML()}</td> |
---|
| 123 | <td align="left"><g:checkBox name="${it.authority}"/></td> |
---|
| 124 | </tr> |
---|
| 125 | </g:each> |
---|
[59] | 126 | |
---|
[150] | 127 | </tbody> |
---|
| 128 | </table> |
---|
| 129 | </div> |
---|
[59] | 130 | |
---|
[150] | 131 | <div class="buttons"> |
---|
| 132 | <span class="button"><input class="save" type="submit" value="Create" /></span> |
---|
| 133 | </div> |
---|
[59] | 134 | |
---|
[150] | 135 | </g:form> |
---|
[59] | 136 | |
---|
[150] | 137 | </div> |
---|
[59] | 138 | </body> |
---|