1 | <html> |
---|
2 | <head> |
---|
3 | <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> |
---|
4 | <meta name="layout" content="main" /> |
---|
5 | <title>Task Search</title> |
---|
6 | <filterpane:includes /> |
---|
7 | <g:javascript src="overlayPane.js" /> |
---|
8 | <nav:resources override="true"/> |
---|
9 | </head> |
---|
10 | <body> |
---|
11 | <div class="nav"> |
---|
12 | <nav:renderSubItems group="nav"/> |
---|
13 | </div> |
---|
14 | |
---|
15 | <div class="body"> |
---|
16 | <g:if test="${flash.message}"> |
---|
17 | <div class="message">${flash.message}</div> |
---|
18 | </g:if> |
---|
19 | <g:if test="${params.message}"> |
---|
20 | <div class="message">${params.message}</div> |
---|
21 | </g:if> |
---|
22 | <g:hasErrors bean="${appCore}"> |
---|
23 | <div class="errors"> |
---|
24 | <g:renderErrors bean="${appCore}" as="list" /> |
---|
25 | </div> |
---|
26 | </g:hasErrors> |
---|
27 | <filterpane:currentCriteria domainBean="Task" |
---|
28 | action="search" |
---|
29 | dateFormat="${'EEE, dd-MMM-yyyy'}" |
---|
30 | removeImgDir="images" |
---|
31 | removeImgFile="bullet_delete.png" |
---|
32 | title="Advanced Search"/> |
---|
33 | |
---|
34 | <div class="paginateButtons"> |
---|
35 | <a href='' onclick="showElement('searchPane'); return false;">Quick</a> |
---|
36 | Results:${taskInstanceTotal} |
---|
37 | <filterpane:filterButton text="Advanced" appliedText="Advanced" /> |
---|
38 | </div> |
---|
39 | |
---|
40 | <div class="list"> |
---|
41 | <table> |
---|
42 | <thead> |
---|
43 | <tr> |
---|
44 | |
---|
45 | <g:sortableColumn property="id" title="Id" params="${filterParams}" /> |
---|
46 | |
---|
47 | <g:sortableColumn property="targetStartDate" title="Target Start Date" params="${filterParams}" /> |
---|
48 | |
---|
49 | <g:sortableColumn property="description" title="Description" params="${filterParams}" /> |
---|
50 | |
---|
51 | <g:sortableColumn property="leadPerson" title="Lead Person" params="${filterParams}" /> |
---|
52 | |
---|
53 | <g:sortableColumn property="taskPriority" title="Task Priority" params="${filterParams}" /> |
---|
54 | |
---|
55 | <g:sortableColumn property="taskStatus" title="Task Status" params="${filterParams}" /> |
---|
56 | |
---|
57 | <th></th> |
---|
58 | |
---|
59 | </tr> |
---|
60 | </thead> |
---|
61 | <tbody> |
---|
62 | <g:each in="${taskInstanceList}" status="i" var="taskInstance"> |
---|
63 | <tr class="${(i % 2) == 0 ? 'clickableOdd' : 'clickableEven'}" onclick='window.location = "${request.getContextPath()}/taskDetailed/show/${taskInstance.id}"'/> |
---|
64 | |
---|
65 | <td>${fieldValue(bean:taskInstance, field:'id')}</td> |
---|
66 | |
---|
67 | <td><g:formatDate date="${taskInstance.targetStartDate}" format="EEE, dd-MMM-yyyy"/></td> |
---|
68 | |
---|
69 | <td>${fieldValue(bean:taskInstance, field:'description')}</td> |
---|
70 | |
---|
71 | <td>${fieldValue(bean:taskInstance, field:'leadPerson')}</td> |
---|
72 | |
---|
73 | <td>${fieldValue(bean:taskInstance, field:'taskPriority')}</td> |
---|
74 | |
---|
75 | <td>${fieldValue(bean:taskInstance, field:'taskStatus')}</td> |
---|
76 | |
---|
77 | <td> |
---|
78 | <g:link action="show" id="${taskInstance.id}"> |
---|
79 | <img src="${resource(dir:'images/skin',file:'database_go.png')}" alt="Show" /> |
---|
80 | </g:link> |
---|
81 | </td> |
---|
82 | |
---|
83 | </tr> |
---|
84 | </g:each> |
---|
85 | </tbody> |
---|
86 | </table> |
---|
87 | </div> |
---|
88 | <div class="paginateButtons"> |
---|
89 | <g:paginate total="${taskInstanceTotal}" params="${filterParams}" /> |
---|
90 | </div> |
---|
91 | |
---|
92 | <filterpane:filterPane domainBean="Task" |
---|
93 | title="Advanced Search" |
---|
94 | action="search" |
---|
95 | class="overlayPane" |
---|
96 | additionalProperties="id" |
---|
97 | associatedProperties="taskPriority.name, |
---|
98 | leadPerson.lastName, |
---|
99 | leadPerson.firstName, |
---|
100 | taskGroup.name, |
---|
101 | associatedAssets.name, |
---|
102 | primaryAsset.name, |
---|
103 | taskStatus.name, |
---|
104 | taskType.name" |
---|
105 | filterPropertyValues="${['taskPriority.name':[values:TaskPriority.list()], |
---|
106 | 'leadPerson.lastName':[values:Person.executeQuery('select distinct t.lastName from Person t')], |
---|
107 | 'leadPerson.firstName':[values:Person.executeQuery('select distinct t.firstName from Person t')], |
---|
108 | 'taskGroup.name':[values:TaskGroup.list()], |
---|
109 | 'associatedAssets.name':[values:Asset.list()], |
---|
110 | 'primaryAsset.name':[values:Asset.list()], |
---|
111 | 'taskStatus.name':[values:TaskStatus.list()], |
---|
112 | 'taskType.name':[values:TaskType.list()], |
---|
113 | targetCompletionDate:[years:2020..2000,precision:'day'], |
---|
114 | targetStartDate:[years:2020..2000,precision:'day'] |
---|
115 | ]}"/> |
---|
116 | </div> <!-- end body --> |
---|
117 | |
---|
118 | <!-- Start Search Pane --> |
---|
119 | <div class="overlayPane" id="searchPane" style="display:none;"> |
---|
120 | <h2>Quick Search</h2> |
---|
121 | <g:form method="post" id="searchForm" name="searchForm" > |
---|
122 | <table> |
---|
123 | <tbody> |
---|
124 | |
---|
125 | <tr class="prop"> |
---|
126 | <td valign="top" class="name"> |
---|
127 | <label>My Tasks:</label> |
---|
128 | </td> |
---|
129 | <td valign="top" class="value"> |
---|
130 | <g:link controller="taskDetailed" |
---|
131 | action="search" |
---|
132 | params="[quickSearch: 'searchMyTodays']"> |
---|
133 | Today's |
---|
134 | </g:link> |
---|
135 | <br /> |
---|
136 | <g:link controller="taskDetailed" |
---|
137 | action="search" |
---|
138 | params="[quickSearch: 'searchMyInTheLastWeek']"> |
---|
139 | In the last week |
---|
140 | </g:link> |
---|
141 | </td> |
---|
142 | </tr> |
---|
143 | |
---|
144 | <tr class="prop"> |
---|
145 | <td valign="top" class="name"> |
---|
146 | <label>Tasks:</label> |
---|
147 | </td> |
---|
148 | <td valign="top" class="value"> |
---|
149 | <g:link controller="taskDetailed" |
---|
150 | action="search" |
---|
151 | params="[quickSearch: 'searchTodays']"> |
---|
152 | Today's |
---|
153 | </g:link> |
---|
154 | <br /> |
---|
155 | <g:link controller="taskDetailed" |
---|
156 | action="search" |
---|
157 | params="[quickSearch: 'searchInTheLastWeek']"> |
---|
158 | In the last week |
---|
159 | </g:link> |
---|
160 | </td> |
---|
161 | </tr> |
---|
162 | |
---|
163 | </tbody> |
---|
164 | </table> |
---|
165 | <div class="buttons"> |
---|
166 | <span class="button"> |
---|
167 | <input type="button" value="${g.message(code:'fp.tag.filterPane.button.cancel.text', default:'Cancel')}" onclick="return hideElement('searchPane');" /> |
---|
168 | </span> |
---|
169 | <!-- <span class="button"> |
---|
170 | <input type="button" value="${g.message(code:'fp.tag.filterPane.button.clear.text', default:'Clear')}" onclick="return clearFilterPane('searchForm');" /> |
---|
171 | </span> |
---|
172 | <span class="button"> |
---|
173 | <g:actionSubmit class="search" value="Search" /> |
---|
174 | </span>--> |
---|
175 | </div> |
---|
176 | </g:form> |
---|
177 | </div> <!-- end search pane --> |
---|
178 | |
---|
179 | </body> |
---|
180 | </html> |
---|