| Line 45... |
Line 45... |
| 45 |
#foreach($b in $userBeats)
|
45 |
#foreach($b in $userBeats)
|
| 46 |
<strong>$b.get("totalCount")</strong><br>
|
46 |
<strong>$b.get("totalCount")</strong><br>
|
| 47 |
#end
|
47 |
#end
|
| 48 |
</td>
|
48 |
</td>
|
| 49 |
#else
|
49 |
#else
|
| 50 |
<td colspan="3" style="color:#999; text-align:center; font-style:italic;">No beat scheduled</td>
|
50 |
<td style="color:#999; text-align:center; font-style:italic;">No beat scheduled</td>
|
| - |
|
51 |
<td style="color:#999;">--</td>
|
| - |
|
52 |
<td style="color:#999;">--</td>
|
| 51 |
#end
|
53 |
#end
|
| 52 |
<td>
|
54 |
<td>
|
| 53 |
#if($row.get("punchInTime") != "")<span class="label label-success">$row.get("punchInTime")</span>#else<span style="color:#ccc;">--</span>#end
|
55 |
#if($row.get("punchInTime") != "")<span class="label label-success">$row.get("punchInTime")</span>#else<span style="color:#ccc;">--</span>#end
|
| 54 |
#if($row.get("punchOutTime") != "")<span class="label label-danger">$row.get("punchOutTime")</span>#else<span style="color:#ccc;">--</span>#end
|
56 |
#if($row.get("punchOutTime") != "")<span class="label label-danger">$row.get("punchOutTime")</span>#else<span style="color:#ccc;">--</span>#end
|
| 55 |
</td>
|
57 |
</td>
|
| Line 80... |
Line 82... |
| 80 |
<br>
|
82 |
<br>
|
| 81 |
#end
|
83 |
#end
|
| 82 |
#end
|
84 |
#end
|
| 83 |
</td>
|
85 |
</td>
|
| 84 |
</tr>
|
86 |
</tr>
|
| 85 |
|
- |
|
| 86 |
<script>
|
- |
|
| 87 |
window.beatReportData = window.beatReportData || {};
|
- |
|
| 88 |
window.beatReportData[$rowIndex] = {
|
- |
|
| 89 |
username: "$row.get('username').replace('"', '\"')",
|
- |
|
| 90 |
total: [
|
- |
|
| 91 |
#foreach($lt in $row.get("totalList"))
|
- |
|
| 92 |
{ taskName: "$!lt.getTaskName().replace('"', '\"')", markType: "$!lt.getMarkType()", address: "$!lt.getAddress().replace('"', '\"').replace("'", "\'")", checkInTime: "$!lt.getCheckInTime()", checkOutTime: "$!lt.getCheckOutTime()", timeSpent: "$!lt.getTimeSpent()", taskType: "$!lt.getTaskType()", visitLocation: "$!lt.getVisitLocation()", checkInLatLng: "$!lt.getCheckInLatLng()", taskDescription: "$!lt.getTaskDescription().replace('"', '\"')", attachment: "$!lt.getAttachment()" },
|
- |
|
| 93 |
#end
|
- |
|
| 94 |
],
|
- |
|
| 95 |
completed: [
|
- |
|
| 96 |
#foreach($lt in $row.get("completedList"))
|
- |
|
| 97 |
{ taskName: "$!lt.getTaskName().replace('"', '\"')", markType: "$!lt.getMarkType()", address: "$!lt.getAddress().replace('"', '\"').replace("'", "\'")", checkInTime: "$!lt.getCheckInTime()", checkOutTime: "$!lt.getCheckOutTime()", timeSpent: "$!lt.getTimeSpent()", taskType: "$!lt.getTaskType()", visitLocation: "$!lt.getVisitLocation()", checkInLatLng: "$!lt.getCheckInLatLng()", taskDescription: "$!lt.getTaskDescription().replace('"', '\"')", attachment: "$!lt.getAttachment()" },
|
- |
|
| 98 |
#end
|
- |
|
| 99 |
],
|
- |
|
| 100 |
pending: [
|
- |
|
| 101 |
#foreach($lt in $row.get("pendingList"))
|
- |
|
| 102 |
{ taskName: "$!lt.getTaskName().replace('"', '\"')", markType: "$!lt.getMarkType()", address: "$!lt.getAddress().replace('"', '\"').replace("'", "\'")", checkInTime: "$!lt.getCheckInTime()", checkOutTime: "$!lt.getCheckOutTime()", timeSpent: "$!lt.getTimeSpent()", taskType: "$!lt.getTaskType()", visitLocation: "$!lt.getVisitLocation()", checkInLatLng: "$!lt.getCheckInLatLng()", taskDescription: "$!lt.getTaskDescription().replace('"', '\"')", attachment: "$!lt.getAttachment()" },
|
- |
|
| 103 |
#end
|
- |
|
| 104 |
],
|
- |
|
| 105 |
deferred: [
|
- |
|
| 106 |
#foreach($lt in $row.get("deferredList"))
|
- |
|
| 107 |
{ taskName: "$!lt.getTaskName().replace('"', '\"')", markType: "$!lt.getMarkType()", address: "$!lt.getAddress().replace('"', '\"').replace("'", "\'")", checkInTime: "$!lt.getCheckInTime()", checkOutTime: "$!lt.getCheckOutTime()", timeSpent: "$!lt.getTimeSpent()", taskType: "$!lt.getTaskType()", visitLocation: "$!lt.getVisitLocation()", checkInLatLng: "$!lt.getCheckInLatLng()", taskDescription: "$!lt.getTaskDescription().replace('"', '\"')", attachment: "$!lt.getAttachment()" },
|
- |
|
| 108 |
#end
|
- |
|
| 109 |
]
|
- |
|
| 110 |
};
|
- |
|
| 111 |
</script>
|
- |
|
| 112 |
#set($rowIndex = $rowIndex + 1)
|
87 |
#set($rowIndex = $rowIndex + 1)
|
| 113 |
#end
|
88 |
#end
|
| 114 |
</tbody>
|
89 |
</tbody>
|
| 115 |
</table>
|
90 |
</table>
|
| 116 |
</div>
|
91 |
</div>
|
| 117 |
|
92 |
|
| - |
|
93 |
<!--
|
| - |
|
94 |
Per-row visit lists are emitted as a single script block OUTSIDE the table.
|
| - |
|
95 |
Embedding them between <tr> rows triggers HTML foster-parenting (browsers
|
| - |
|
96 |
move misplaced non-row content out of the table during parsing), which
|
| - |
|
97 |
fragments the tbody and causes DataTables to throw
|
| - |
|
98 |
"Cannot set properties of undefined (setting '_DT_CellIndex')".
|
| - |
|
99 |
-->
|
| - |
|
100 |
<script>
|
| - |
|
101 |
window.beatReportData = window.beatReportData || {};
|
| - |
|
102 |
#set($rowIndex = 0)
|
| - |
|
103 |
#foreach($row in $reportRows)
|
| - |
|
104 |
window.beatReportData[$rowIndex] = {
|
| - |
|
105 |
username: "$row.get('username').replace('"', '\"')",
|
| - |
|
106 |
total: [
|
| - |
|
107 |
#foreach($lt in $row.get("totalList"))
|
| - |
|
108 |
{
|
| - |
|
109 |
taskName: "$!lt.getTaskName().replace('"', '\"')",
|
| - |
|
110 |
markType: "$!lt.getMarkType()",
|
| - |
|
111 |
address: "$!lt.getAddress().replace('"', '\"').replace("'", "\'")",
|
| - |
|
112 |
checkInTime: "$!lt.getCheckInTime()",
|
| - |
|
113 |
checkOutTime: "$!lt.getCheckOutTime()",
|
| - |
|
114 |
timeSpent: "$!lt.getTimeSpent()",
|
| - |
|
115 |
taskType: "$!lt.getTaskType()",
|
| - |
|
116 |
visitLocation: "$!lt.getVisitLocation()",
|
| - |
|
117 |
checkInLatLng: "$!lt.getCheckInLatLng()",
|
| - |
|
118 |
taskDescription: "$!lt.getTaskDescription().replace('"', '\"')",
|
| - |
|
119 |
attachment: "$!lt.getAttachment()"
|
| - |
|
120 |
},
|
| - |
|
121 |
#end
|
| - |
|
122 |
],
|
| - |
|
123 |
completed: [
|
| - |
|
124 |
#foreach($lt in $row.get("completedList"))
|
| - |
|
125 |
{
|
| - |
|
126 |
taskName: "$!lt.getTaskName().replace('"', '\"')",
|
| - |
|
127 |
markType: "$!lt.getMarkType()",
|
| - |
|
128 |
address: "$!lt.getAddress().replace('"', '\"').replace("'", "\'")",
|
| - |
|
129 |
checkInTime: "$!lt.getCheckInTime()",
|
| - |
|
130 |
checkOutTime: "$!lt.getCheckOutTime()",
|
| - |
|
131 |
timeSpent: "$!lt.getTimeSpent()",
|
| - |
|
132 |
taskType: "$!lt.getTaskType()",
|
| - |
|
133 |
visitLocation: "$!lt.getVisitLocation()",
|
| - |
|
134 |
checkInLatLng: "$!lt.getCheckInLatLng()",
|
| - |
|
135 |
taskDescription: "$!lt.getTaskDescription().replace('"', '\"')",
|
| - |
|
136 |
attachment: "$!lt.getAttachment()"
|
| - |
|
137 |
},
|
| - |
|
138 |
#end
|
| - |
|
139 |
],
|
| - |
|
140 |
pending: [
|
| - |
|
141 |
#foreach($lt in $row.get("pendingList"))
|
| - |
|
142 |
{
|
| - |
|
143 |
taskName: "$!lt.getTaskName().replace('"', '\"')",
|
| - |
|
144 |
markType: "$!lt.getMarkType()",
|
| - |
|
145 |
address: "$!lt.getAddress().replace('"', '\"').replace("'", "\'")",
|
| - |
|
146 |
checkInTime: "$!lt.getCheckInTime()",
|
| - |
|
147 |
checkOutTime: "$!lt.getCheckOutTime()",
|
| - |
|
148 |
timeSpent: "$!lt.getTimeSpent()",
|
| - |
|
149 |
taskType: "$!lt.getTaskType()",
|
| - |
|
150 |
visitLocation: "$!lt.getVisitLocation()",
|
| - |
|
151 |
checkInLatLng: "$!lt.getCheckInLatLng()",
|
| - |
|
152 |
taskDescription: "$!lt.getTaskDescription().replace('"', '\"')",
|
| - |
|
153 |
attachment: "$!lt.getAttachment()"
|
| - |
|
154 |
},
|
| - |
|
155 |
#end
|
| - |
|
156 |
],
|
| - |
|
157 |
deferred: [
|
| - |
|
158 |
#foreach($lt in $row.get("deferredList"))
|
| - |
|
159 |
{
|
| - |
|
160 |
taskName: "$!lt.getTaskName().replace('"', '\"')",
|
| - |
|
161 |
markType: "$!lt.getMarkType()",
|
| - |
|
162 |
address: "$!lt.getAddress().replace('"', '\"').replace("'", "\'")",
|
| - |
|
163 |
checkInTime: "$!lt.getCheckInTime()",
|
| - |
|
164 |
checkOutTime: "$!lt.getCheckOutTime()",
|
| - |
|
165 |
timeSpent: "$!lt.getTimeSpent()",
|
| - |
|
166 |
taskType: "$!lt.getTaskType()",
|
| - |
|
167 |
visitLocation: "$!lt.getVisitLocation()",
|
| - |
|
168 |
checkInLatLng: "$!lt.getCheckInLatLng()",
|
| - |
|
169 |
taskDescription: "$!lt.getTaskDescription().replace('"', '\"')",
|
| - |
|
170 |
attachment: "$!lt.getAttachment()"
|
| - |
|
171 |
},
|
| - |
|
172 |
#end
|
| - |
|
173 |
]
|
| - |
|
174 |
};
|
| - |
|
175 |
#set($rowIndex = $rowIndex + 1)
|
| - |
|
176 |
#end
|
| - |
|
177 |
</script>
|
| - |
|
178 |
|
| 118 |
<!-- Map Modal -->
|
179 |
<!-- Map Modal -->
|
| 119 |
<div class="modal fade" id="beatMapModal" tabindex="-1" role="dialog">
|
180 |
<div class="modal fade" id="beatMapModal" tabindex="-1" role="dialog">
|
| 120 |
<div class="modal-dialog modal-lg" role="document" style="width:90%;">
|
181 |
<div class="modal-dialog modal-lg" role="document" style="width:90%;">
|
| 121 |
<div class="modal-content">
|
182 |
<div class="modal-content">
|
| 122 |
<div class="modal-header" style="background:#1abc9c; color:white;">
|
183 |
<div class="modal-header" style="background:#1abc9c; color:white;">
|