[66] | 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 Task</title> |
---|
| 8 | </head> |
---|
| 9 | <body> |
---|
| 10 | <div class="nav"> |
---|
| 11 | <span class="menuButton"><a class="home" href="${createLinkTo(dir:'')}">Home</a></span> |
---|
| 12 | <span class="menuButton"><g:link class="list" action="list">Task List</g:link></span> |
---|
| 13 | <span class="menuButton"><g:link class="create" action="create">New Task</g:link></span> |
---|
| 14 | </div> |
---|
| 15 | <div class="body"> |
---|
| 16 | <h1>Edit Task</h1> |
---|
| 17 | <g:if test="${flash.message}"> |
---|
| 18 | <div class="message">${flash.message}</div> |
---|
| 19 | </g:if> |
---|
| 20 | <g:hasErrors bean="${taskInstance}"> |
---|
| 21 | <div class="errors"> |
---|
| 22 | <g:renderErrors bean="${taskInstance}" as="list" /> |
---|
| 23 | </div> |
---|
| 24 | </g:hasErrors> |
---|
| 25 | <g:form method="post" > |
---|
| 26 | <input type="hidden" name="id" value="${taskInstance?.id}" /> |
---|
| 27 | <div class="dialog"> |
---|
| 28 | <table> |
---|
| 29 | <tbody> |
---|
| 30 | |
---|
| 31 | <tr class="prop"> |
---|
| 32 | <td valign="top" class="name"> |
---|
| 33 | <label for="targetStartDate">Target Start Date:</label> |
---|
| 34 | </td> |
---|
| 35 | <td valign="top" class="value ${hasErrors(bean:taskInstance,field:'targetStartDate','errors')}"> |
---|
| 36 | <g:datePicker name="targetStartDate" value="${taskInstance?.targetStartDate}" ></g:datePicker> |
---|
| 37 | </td> |
---|
| 38 | </tr> |
---|
| 39 | |
---|
| 40 | <tr class="prop"> |
---|
| 41 | <td valign="top" class="name"> |
---|
| 42 | <label for="description">Description:</label> |
---|
| 43 | </td> |
---|
| 44 | <td valign="top" class="value ${hasErrors(bean:taskInstance,field:'description','errors')}"> |
---|
| 45 | <input type="text" maxlength="50" id="description" name="description" value="${fieldValue(bean:taskInstance,field:'description')}"/> |
---|
| 46 | </td> |
---|
| 47 | </tr> |
---|
| 48 | |
---|
| 49 | <tr class="prop"> |
---|
| 50 | <td valign="top" class="name"> |
---|
| 51 | <label for="leadPerson">Lead Person:</label> |
---|
| 52 | </td> |
---|
| 53 | <td valign="top" class="value ${hasErrors(bean:taskInstance,field:'leadPerson','errors')}"> |
---|
| 54 | <g:select optionKey="id" from="${Person.list()}" name="leadPerson.id" value="${taskInstance?.leadPerson?.id}" ></g:select> |
---|
| 55 | </td> |
---|
| 56 | </tr> |
---|
| 57 | |
---|
| 58 | <tr class="prop"> |
---|
| 59 | <td valign="top" class="name"> |
---|
| 60 | <label for="taskStatus">Task Status:</label> |
---|
| 61 | </td> |
---|
| 62 | <td valign="top" class="value ${hasErrors(bean:taskInstance,field:'taskStatus','errors')}"> |
---|
| 63 | <g:select optionKey="id" from="${TaskStatus.list()}" name="taskStatus.id" value="${taskInstance?.taskStatus?.id}" ></g:select> |
---|
| 64 | </td> |
---|
| 65 | </tr> |
---|
| 66 | |
---|
| 67 | <tr class="prop"> |
---|
| 68 | <td valign="top" class="name"> |
---|
| 69 | <label for="comment">Comment:</label> |
---|
| 70 | </td> |
---|
| 71 | <td valign="top" class="value ${hasErrors(bean:taskInstance,field:'comment','errors')}"> |
---|
| 72 | <textarea rows="5" cols="40" name="comment">${fieldValue(bean:taskInstance, field:'comment')}</textarea> |
---|
| 73 | </td> |
---|
| 74 | </tr> |
---|
| 75 | |
---|
| 76 | <tr class="prop"> |
---|
| 77 | <td valign="top" class="name"> |
---|
| 78 | <label for="assignedPersons">Assigned Persons:</label> |
---|
| 79 | </td> |
---|
| 80 | <td valign="top" class="value ${hasErrors(bean:taskInstance,field:'assignedPersons','errors')}"> |
---|
| 81 | |
---|
| 82 | <ul> |
---|
| 83 | <g:each var="a" in="${taskInstance?.assignedPersons?}"> |
---|
| 84 | <li><g:link controller="person" action="show" id="${a.id}">${a?.encodeAsHTML()}</g:link></li> |
---|
| 85 | </g:each> |
---|
| 86 | </ul> |
---|
| 87 | <g:link controller="person" params="['task.id':taskInstance?.id]" action="create">Add Person</g:link> |
---|
| 88 | |
---|
| 89 | </td> |
---|
| 90 | </tr> |
---|
| 91 | |
---|
| 92 | <tr class="prop"> |
---|
| 93 | <td valign="top" class="name"> |
---|
| 94 | <label for="entries">Entries:</label> |
---|
| 95 | </td> |
---|
| 96 | <td valign="top" class="value ${hasErrors(bean:taskInstance,field:'entries','errors')}"> |
---|
| 97 | |
---|
| 98 | <ul> |
---|
| 99 | <g:each var="e" in="${taskInstance?.entries?}"> |
---|
| 100 | <li><g:link controller="entry" action="show" id="${e.id}">${e?.encodeAsHTML()}</g:link></li> |
---|
| 101 | </g:each> |
---|
| 102 | </ul> |
---|
| 103 | <g:link controller="entry" params="['task.id':taskInstance?.id]" action="create">Add Entry</g:link> |
---|
| 104 | |
---|
| 105 | </td> |
---|
| 106 | </tr> |
---|
| 107 | |
---|
| 108 | <tr class="prop"> |
---|
| 109 | <td valign="top" class="name"> |
---|
| 110 | <label for="isActive">Is Active:</label> |
---|
| 111 | </td> |
---|
| 112 | <td valign="top" class="value ${hasErrors(bean:taskInstance,field:'isActive','errors')}"> |
---|
| 113 | <g:checkBox name="isActive" value="${taskInstance?.isActive}" ></g:checkBox> |
---|
| 114 | </td> |
---|
| 115 | </tr> |
---|
| 116 | |
---|
| 117 | <tr class="prop"> |
---|
| 118 | <td valign="top" class="name"> |
---|
| 119 | <label for="isApproved">Is Approved:</label> |
---|
| 120 | </td> |
---|
| 121 | <td valign="top" class="value ${hasErrors(bean:taskInstance,field:'isApproved','errors')}"> |
---|
| 122 | <g:checkBox name="isApproved" value="${taskInstance?.isApproved}" ></g:checkBox> |
---|
| 123 | </td> |
---|
| 124 | </tr> |
---|
| 125 | |
---|
| 126 | <tr class="prop"> |
---|
| 127 | <td valign="top" class="name"> |
---|
| 128 | <label for="isScheduled">Is Scheduled:</label> |
---|
| 129 | </td> |
---|
| 130 | <td valign="top" class="value ${hasErrors(bean:taskInstance,field:'isScheduled','errors')}"> |
---|
| 131 | <g:checkBox name="isScheduled" value="${taskInstance?.isScheduled}" ></g:checkBox> |
---|
| 132 | </td> |
---|
| 133 | </tr> |
---|
| 134 | |
---|
| 135 | <tr class="prop"> |
---|
| 136 | <td valign="top" class="name"> |
---|
| 137 | <label for="modifications">Modifications:</label> |
---|
| 138 | </td> |
---|
| 139 | <td valign="top" class="value ${hasErrors(bean:taskInstance,field:'modifications','errors')}"> |
---|
| 140 | |
---|
| 141 | <ul> |
---|
| 142 | <g:each var="m" in="${taskInstance?.modifications?}"> |
---|
| 143 | <li><g:link controller="modification" action="show" id="${m.id}">${m?.encodeAsHTML()}</g:link></li> |
---|
| 144 | </g:each> |
---|
| 145 | </ul> |
---|
| 146 | <g:link controller="modification" params="['task.id':taskInstance?.id]" action="create">Add Modification</g:link> |
---|
| 147 | |
---|
| 148 | </td> |
---|
| 149 | </tr> |
---|
| 150 | |
---|
| 151 | <tr class="prop"> |
---|
| 152 | <td valign="top" class="name"> |
---|
| 153 | <label for="targetCompletionDate">Target Completion Date:</label> |
---|
| 154 | </td> |
---|
| 155 | <td valign="top" class="value ${hasErrors(bean:taskInstance,field:'targetCompletionDate','errors')}"> |
---|
| 156 | <g:datePicker name="targetCompletionDate" value="${taskInstance?.targetCompletionDate}" ></g:datePicker> |
---|
| 157 | </td> |
---|
| 158 | </tr> |
---|
| 159 | |
---|
| 160 | <tr class="prop"> |
---|
| 161 | <td valign="top" class="name"> |
---|
| 162 | <label for="taskGroup">Task Group:</label> |
---|
| 163 | </td> |
---|
| 164 | <td valign="top" class="value ${hasErrors(bean:taskInstance,field:'taskGroup','errors')}"> |
---|
| 165 | <g:select optionKey="id" from="${TaskGroup.list()}" name="taskGroup.id" value="${taskInstance?.taskGroup?.id}" ></g:select> |
---|
| 166 | </td> |
---|
| 167 | </tr> |
---|
| 168 | |
---|
| 169 | </tbody> |
---|
| 170 | </table> |
---|
| 171 | </div> |
---|
| 172 | <div class="buttons"> |
---|
| 173 | <span class="button"><g:actionSubmit class="save" value="Update" /></span> |
---|
| 174 | <span class="button"><g:actionSubmit class="delete" onclick="return confirm('Are you sure?');" value="Delete" /></span> |
---|
| 175 | </div> |
---|
| 176 | </g:form> |
---|
| 177 | </div> |
---|
| 178 | </body> |
---|
| 179 | </html> |
---|