| 34913 |
ranu |
1 |
<script type="text/javascript">
|
|
|
2 |
$('#myModal').on('hidden.bs.modal', function (e) {
|
|
|
3 |
$(".activity-container .modal-body").empty();
|
|
|
4 |
|
|
|
5 |
});
|
|
|
6 |
|
|
|
7 |
$(function () {
|
|
|
8 |
getPartnerAheadOptions($("#typeaheadpartnername"), function (selectedPartner) {
|
|
|
9 |
$("#manager-ticket-search-by-partner-name").data('id', selectedPartner.partnerId);
|
|
|
10 |
$("#partner-name-input").val(selectedPartner.partnerId);
|
|
|
11 |
});
|
|
|
12 |
});
|
|
|
13 |
|
|
|
14 |
$(document).ready(function () {
|
|
|
15 |
|
|
|
16 |
$('#manager-ticket thead tr').clone(true).appendTo('#manager-ticket thead');
|
|
|
17 |
$('#manager-ticket thead tr:eq(1) th').each(function (i) {
|
|
|
18 |
var title = $(this).text();
|
|
|
19 |
$(this).html('<input type="text" style = "width:60%;" placeholder="Search ' + title + '" />');
|
|
|
20 |
|
|
|
21 |
$('input', this).on('keyup change', function () {
|
|
|
22 |
if (table.column(i).search() !== this.value) {
|
|
|
23 |
table
|
|
|
24 |
.column(i)
|
|
|
25 |
.search(this.value)
|
|
|
26 |
.draw();
|
|
|
27 |
}
|
|
|
28 |
});
|
|
|
29 |
})
|
|
|
30 |
|
|
|
31 |
var table = $('#manager-ticket').DataTable({
|
|
|
32 |
orderCellsTop: true,
|
|
|
33 |
fixedHeader: true
|
|
|
34 |
})
|
|
|
35 |
|
|
|
36 |
});
|
|
|
37 |
|
|
|
38 |
</script>
|
|
|
39 |
<style>
|
|
|
40 |
.incoming_msg_img {
|
|
|
41 |
display: inline-block;
|
|
|
42 |
width: 6%;
|
|
|
43 |
}
|
|
|
44 |
|
|
|
45 |
.incoming_msg_img img {
|
|
|
46 |
width: 100%;
|
|
|
47 |
}
|
|
|
48 |
|
|
|
49 |
.sent_msg p {
|
|
|
50 |
background: #b8d1f3;
|
|
|
51 |
border-radius: 12px 15px 15px 0;
|
|
|
52 |
font-size: 14px;
|
|
|
53 |
margin: 0;
|
|
|
54 |
color: black;
|
|
|
55 |
padding: 5px 10px 5px 12px;
|
|
|
56 |
word-break: break-all;
|
|
|
57 |
width: 100%;
|
|
|
58 |
}
|
|
|
59 |
|
|
|
60 |
.outgoing_msg {
|
|
|
61 |
overflow: hidden;
|
|
|
62 |
margin: 26px 0 26px;
|
|
|
63 |
}
|
|
|
64 |
|
|
|
65 |
.sent_msg {
|
|
|
66 |
float: right;
|
|
|
67 |
width: 46%;
|
|
|
68 |
}
|
|
|
69 |
|
|
|
70 |
.received_msg {
|
|
|
71 |
display: inline-block;
|
|
|
72 |
padding: 0 0 0 10px;
|
|
|
73 |
vertical-align: top;
|
|
|
74 |
width: 50%;
|
|
|
75 |
}
|
|
|
76 |
|
|
|
77 |
.received_withd_msg p {
|
|
|
78 |
background: #dae5f4 none repeat scroll 0 0;
|
|
|
79 |
border-radius: 0 15px 15px 15px;
|
|
|
80 |
color: #646464;
|
|
|
81 |
font-size: 14px;
|
|
|
82 |
margin: 0;
|
|
|
83 |
padding: 5px 10px 5px 12px;
|
|
|
84 |
word-break: break-all;
|
|
|
85 |
width: 100%;
|
|
|
86 |
}
|
|
|
87 |
|
|
|
88 |
.time_date {
|
|
|
89 |
color: black;
|
|
|
90 |
display: block;
|
|
|
91 |
font-size: 12px;
|
|
|
92 |
margin: 8px 0 0;
|
|
|
93 |
}
|
|
|
94 |
|
|
|
95 |
.blue_box, .green_box, .white_box {
|
|
|
96 |
display: block;
|
|
|
97 |
clear: both;
|
|
|
98 |
}
|
|
|
99 |
|
|
|
100 |
.modal-dialog {
|
|
|
101 |
/* 80% of window height */
|
|
|
102 |
max-height: 80%;
|
|
|
103 |
}
|
|
|
104 |
|
|
|
105 |
.modal-body {
|
|
|
106 |
max-height: 70vh;
|
|
|
107 |
overflow-y: auto;
|
|
|
108 |
}
|
|
|
109 |
|
|
|
110 |
.outgoing_msg:after, .incoming_msg:after, .white_box:after {
|
|
|
111 |
content: '\A';
|
|
|
112 |
white-space: pre;
|
|
|
113 |
}
|
|
|
114 |
|
|
|
115 |
.incoming_msg:before, .white_box:before {
|
|
|
116 |
content: '\A';
|
|
|
117 |
white-space: pre;
|
|
|
118 |
}
|
|
|
119 |
|
|
|
120 |
.white_box span {
|
|
|
121 |
background-color: #ebebeb;
|
|
|
122 |
background-size: 5px 5px;
|
|
|
123 |
word-break: break-all;
|
|
|
124 |
color: black;
|
|
|
125 |
display: block;
|
|
|
126 |
padding: 10px 10px;
|
|
|
127 |
text-align: center
|
|
|
128 |
}
|
|
|
129 |
</style>
|
|
|
130 |
<section class="wrapper">
|
|
|
131 |
<div class="row">
|
|
|
132 |
<div class="col-lg-12">
|
|
|
133 |
<h3 class="page-header"><i class="icon_document_alt"></i>TICKET</h3>
|
|
|
134 |
<ol class="breadcrumb">
|
|
|
135 |
<li><i class="fa fa-home"></i><a href="${rc.contextPath}/dashboard">Home</a></li>
|
|
|
136 |
<li><i class="icon_document_alt"></i>All Partner Ticket</li>
|
|
|
137 |
</ol>
|
|
|
138 |
</div>
|
|
|
139 |
</div>
|
|
|
140 |
<div class="row">
|
|
|
141 |
<div class="col-lg-2 form-group">
|
|
|
142 |
<select class="form-control input-sm" id="managerTicketStatus" name="managerTicketStatus"
|
|
|
143 |
placeholder="Type">
|
|
|
144 |
#foreach($ticketStatus in $ticketStatusValues)
|
|
|
145 |
#if($selectedticketStatus==$ticketStatus)
|
|
|
146 |
<option value="$ticketStatus" selected>$ticketStatus</option>
|
|
|
147 |
#else
|
|
|
148 |
<option value="$ticketStatus">$ticketStatus</option>
|
|
|
149 |
#end
|
|
|
150 |
#end
|
|
|
151 |
</select>
|
|
|
152 |
</div>
|
|
|
153 |
<div class="col-lg-2 form-group">
|
|
|
154 |
<select class="form-control input-sm" id="managerTicketorderBy" name="managerTicketorderBy"
|
|
|
155 |
placeholder="Type">
|
|
|
156 |
#foreach($orderby in $orderByValues)
|
|
|
157 |
#if($orderby=="UNSORTED")
|
|
|
158 |
#else
|
|
|
159 |
#if($selectedorderby==$orderby)
|
|
|
160 |
#if($orderby=="ASCENDING")
|
|
|
161 |
<option value="$orderby" selected>OLD TO NEW</option>
|
|
|
162 |
#else
|
|
|
163 |
<option value="$orderby" selected>NEW TO OLD</option>
|
|
|
164 |
#end
|
|
|
165 |
#else
|
|
|
166 |
#if($orderby=="ASCENDING")
|
|
|
167 |
<option value="$orderby">OLD TO NEW</option>
|
|
|
168 |
#else
|
|
|
169 |
<option value="$orderby">NEW TO OLD</option>
|
|
|
170 |
#end
|
|
|
171 |
#end
|
|
|
172 |
#end
|
|
|
173 |
#end
|
|
|
174 |
</select>
|
|
|
175 |
</div>
|
|
|
176 |
<div class="col-lg-6 form-group pull-right">
|
|
|
177 |
<div class="col-lg-6">
|
|
|
178 |
<select class="form-control" id="managersearchType" name="managersearchType" placeholder="Search Type">
|
|
|
179 |
<option value="" disabled selected>Search Type</option>
|
|
|
180 |
#foreach($searchType1 in $ticketSearchTypes)
|
|
|
181 |
#if($ticketSearchType.getValue()==$searchType1.getValue())
|
|
|
182 |
<option value="$searchType1" selected>$ticketSearchType.getValue()</option>
|
|
|
183 |
#else
|
|
|
184 |
<option value="$searchType1">$searchType1.getValue()</option>
|
|
|
185 |
#end
|
|
|
186 |
#end
|
|
|
187 |
</select>
|
|
|
188 |
</div>
|
|
|
189 |
|
|
|
190 |
<div class="col-lg-6">
|
|
|
191 |
<input type="hidden" id="partner-name-input" name="partner-name-input" value="">
|
|
|
192 |
<div class="byPartnerName" style="display: none;">
|
|
|
193 |
<div class="input-group">
|
|
|
194 |
<input placeholder="Partner Name" type="text" class="typeahead form-control"
|
|
|
195 |
id="typeaheadpartnername" value="" name="Item" data-provide="typeahead"
|
|
|
196 |
autocomplete="off">
|
|
|
197 |
<span class="input-group-btn">
|
|
|
198 |
<button class="btn btn-primary" id="manager-ticket-search-by-partner-name" type="button" data-id="">Go!</button>
|
|
|
199 |
</span>
|
|
|
200 |
</div>
|
|
|
201 |
</div>
|
|
|
202 |
<div class="byTicketId" style="display: none;">
|
|
|
203 |
<div class="input-group">
|
|
|
204 |
<input placeholder="Ticket Id" type="text" class="form-control" id="search-by-ticketId"
|
|
|
205 |
value="">
|
|
|
206 |
<span class="input-group-btn">
|
|
|
207 |
<button class="btn btn-primary" id="retailer-details-search-button-by-ticketId"
|
|
|
208 |
type="button">Go!</button>
|
|
|
209 |
</span>
|
|
|
210 |
</div>
|
|
|
211 |
</div>
|
|
|
212 |
</div>
|
|
|
213 |
</div>
|
|
|
214 |
</div>
|
|
|
215 |
<div id="manager-ticket-table">
|
|
|
216 |
<div class="row">
|
|
|
217 |
<div class="col-lg-12">
|
|
|
218 |
<table class="table table-border table-condensed table-bordered" id="manager-ticket">
|
|
|
219 |
<thead>
|
|
|
220 |
<tr>
|
|
|
221 |
<th>Ticket Id</th>
|
|
|
222 |
<th>Partner</th>
|
|
|
223 |
<th>Category</th>
|
|
|
224 |
<th>SubCategory</th>
|
|
|
225 |
<th>Message</th>
|
|
|
226 |
<th>Created By</th>
|
|
|
227 |
<th>Assigned To</th>
|
|
|
228 |
<th>Created TimeStamp</th>
|
|
|
229 |
<th>Status</th>
|
|
|
230 |
<th>Action</th>
|
|
|
231 |
</tr>
|
|
|
232 |
</thead>
|
|
|
233 |
|
|
|
234 |
<tbody>
|
|
|
235 |
#if($tickets.size()>0)
|
|
|
236 |
#foreach($ticket in $tickets)
|
|
|
237 |
<tr>
|
|
|
238 |
<td>$ticket.getId()</td>
|
|
|
239 |
<td>$fofoIdsAndCustomRetailer.get($ticket.getFofoId()).getBusinessName()</td>
|
|
|
240 |
<td>$subCategoryIdAndCategoryMap.get($ticket.getSubCategoryId()).getName()</td>
|
|
|
241 |
|
|
|
242 |
|
|
|
243 |
<td><a href="#" data-toggle="modal" data-target="#myModal"
|
| 35569 |
amit |
244 |
data-ticketid="$ticket.getId()" data-internal="true" data-role="true" data-crm="$isCrmUser"
|
| 34913 |
ranu |
245 |
id="activities"
|
|
|
246 |
data-assignee="$authUserListMap.get($ticket.getId()).get(0).getFirstName()">$subCategoryIdAndSubCategoryMap.get($ticket.getSubCategoryId()).getName()</a>
|
|
|
247 |
</td>
|
|
|
248 |
<td>$activityMap.get($ticket.getId()).get(0).getMessage()</td>
|
|
|
249 |
#if($activityMapWithActivityId.get($ticket.getFirstActivityId()).get(0).getCreatedBy() > 0)
|
|
|
250 |
<td>$authUserMap.get($activityMapWithActivityId.get($ticket.getFirstActivityId()).get(0).getCreatedBy()).getFirstName() $authUserMap.get($activityMapWithActivityId.get($ticket.getFirstActivityId()).get(0).getCreatedBy()).getLastName()</td>
|
|
|
251 |
#else
|
|
|
252 |
<td>Partner</td>
|
|
|
253 |
#end
|
|
|
254 |
<td>#foreach($authUser in $authUserListMap.get($ticket.getId()))
|
|
|
255 |
<span>$authUser.getFirstName() $authUser.getLastName() ($authUser.getEmployeeCode())
|
|
|
256 |
<span><br/>
|
|
|
257 |
#end
|
|
|
258 |
</td>
|
|
|
259 |
<td>$ticket.getFormattedCreateTimestamp()</td>
|
|
|
260 |
#if($ticket.getCloseTimestamp())
|
|
|
261 |
<td>Closed</td>
|
|
|
262 |
<td>
|
|
|
263 |
<button class="btn btn-primary" id="edit-ticket-partner"
|
|
|
264 |
data-ticketid1="$ticket.getId()" data-target="#theModal2"
|
|
|
265 |
data-toggle="modal" data-backdrop="false" disabled>Edit
|
|
|
266 |
</button>
|
|
|
267 |
</td>
|
|
|
268 |
#else
|
|
|
269 |
#if($ticket.getLastActivity()=="RESOLVED")
|
|
|
270 |
<td>Resolved</td>
|
|
|
271 |
#else
|
|
|
272 |
<td>Opened</td>
|
|
|
273 |
#end
|
|
|
274 |
<td>
|
|
|
275 |
<button class="btn btn-primary" id="edit-ticket-partner"
|
|
|
276 |
data-ticketid1="$ticket.getId()" data-target="#theModal2"
|
|
|
277 |
data-toggle="modal" data-backdrop="false">Edit
|
|
|
278 |
</button>
|
|
|
279 |
</td>
|
|
|
280 |
#end
|
|
|
281 |
</tr>
|
|
|
282 |
#end
|
|
|
283 |
#else
|
|
|
284 |
<tr>
|
|
|
285 |
<td colspan="12" style="text-align:center;">NO MATCHING DATA FOUND FOR CRITERIA</td>
|
|
|
286 |
</tr>
|
|
|
287 |
#end
|
|
|
288 |
</tbody>
|
|
|
289 |
</table>
|
|
|
290 |
|
|
|
291 |
</div>
|
|
|
292 |
</div>
|
|
|
293 |
</div>
|
|
|
294 |
|
|
|
295 |
</section>
|
|
|
296 |
<div id="manager-ticket-details-container" style="background:white;background-color:white;">
|
|
|
297 |
</div>
|
|
|
298 |
<div class="edit-container">
|
|
|
299 |
<div class="modal fade text-center" id="theModal2">
|
|
|
300 |
<div class="modal-dialog">
|
|
|
301 |
<div class="modal-content">
|
|
|
302 |
</div>
|
|
|
303 |
</div>
|
|
|
304 |
</div>
|
|
|
305 |
</div>
|
|
|
306 |
|
|
|
307 |
<div class="activity-container">
|
|
|
308 |
<div class="modal" id="myModal" role="dialog">
|
|
|
309 |
<div class="modal-dialog">
|
|
|
310 |
<!-- Modal content-->
|
|
|
311 |
<div class="modal-content">
|
|
|
312 |
<div class="modal-header">
|
|
|
313 |
<button type="button" class="close" data-dismiss="modal">×</button>
|
|
|
314 |
<h4 class="modal-title">Message History</h4>
|
|
|
315 |
</div>
|
|
|
316 |
<div class="modal-body">
|
|
|
317 |
</div>
|
|
|
318 |
<br><br>
|
|
|
319 |
<div class="modal-footer">
|
|
|
320 |
<div class="col-lg-8 form-group">
|
|
|
321 |
<input type="hidden" id="ticketIdforactivity">
|
|
|
322 |
<input type="hidden" id="assigneeUser">
|
|
|
323 |
<input type="hidden" id="role" value="">
|
| 35569 |
amit |
324 |
<input type="hidden" id="crmUser" value="">
|
| 34913 |
ranu |
325 |
|
|
|
326 |
<textarea class="form-control rounded-0" id="activityMessage" rows="2"></textarea>
|
|
|
327 |
</div>
|
|
|
328 |
<div class="col-lg-4">
|
|
|
329 |
<div class="col-lg-7 internalCheckBox">
|
|
|
330 |
<input type="checkbox" name="internalCommunication"
|
|
|
331 |
id="internalCommunication"> <span style="font-size:12px;font-weight:bold">INTERNAL</b>
|
|
|
332 |
</div>
|
|
|
333 |
<div class="col-lg-5">
|
|
|
334 |
<input class="btn btn-primary submit-message-button" type="button" value="Submit">
|
|
|
335 |
</div>
|
|
|
336 |
</div>
|
|
|
337 |
</div>
|
|
|
338 |
</div>
|
|
|
339 |
</div>
|
|
|
340 |
</div>
|
|
|
341 |
</div>
|