DmitrMakeev
commited on
Commit
•
2dbd458
1
Parent(s):
b6d5c55
Update data_gc_tab.html
Browse files- data_gc_tab.html +40 -41
data_gc_tab.html
CHANGED
@@ -264,39 +264,36 @@ button:hover, #filter-clear:hover, #download-json:hover, #take-for-yourself:hove
|
|
264 |
{title:"Номер в списке", field:"id"},
|
265 |
{title:"Имя", field:"name", width:100},
|
266 |
{title:"WhatsApp", field:"phone", formatter: function(cell, formatterParams, onRendered) {
|
267 |
-
|
268 |
-
|
269 |
-
|
270 |
-
|
271 |
-
|
272 |
-
|
273 |
-
|
274 |
-
|
275 |
-
|
276 |
-
|
277 |
-
|
278 |
-
}},
|
279 |
{title:"Город", field:"b_city", width:110},
|
280 |
{title:"Email", field:"email", width:110},
|
281 |
-
{title:"Реплики", field:"b_mess", width:95, cellClick:function(e, cell){
|
282 |
-
|
283 |
-
|
284 |
-
|
285 |
-
|
286 |
-
|
287 |
-
|
288 |
-
|
289 |
-
|
290 |
-
|
291 |
-
|
292 |
-
|
293 |
-
|
294 |
-
|
295 |
-
|
296 |
-
|
297 |
-
}
|
298 |
-
});
|
299 |
-
}},
|
300 |
{title:"Куратор", field:"curator", formatter: linkFormatter},
|
301 |
{title:"Статус покупки", field:"shop_st", formatter: function(cell, formatterParams, onRendered) {
|
302 |
var status = cell.getValue();
|
@@ -334,16 +331,16 @@ button:hover, #filter-clear:hover, #download-json:hover, #take-for-yourself:hove
|
|
334 |
{title:"Статус WhatsApp", field:"ws_st"},
|
335 |
{title:"Стутус подписки", field:"ws_stop"},
|
336 |
{title:"Вебинары-присутствовал", field:"web_st", formatter:"star", formatterParams:{stars:7}, hozAlign:"center", width:120},
|
337 |
-
{title:"Вебинары-досмотрел до конца", field:"b_fin", formatter:function(cell, formatterParams, onRendered){
|
338 |
-
|
339 |
-
|
340 |
-
|
341 |
-
|
342 |
-
|
343 |
-
|
344 |
-
|
345 |
-
|
346 |
-
}, width:100},
|
347 |
|
348 |
{title:"Прогрес по воронке", field:"fin_prog", formatter:"progress", formatterParams:{color:["#ff0000", "orange", "#00dd00"]}, sorter:"number", width:100},
|
349 |
{title:"pr1", field:"pr1"},
|
@@ -356,6 +353,8 @@ button:hover, #filter-clear:hover, #download-json:hover, #take-for-yourself:hove
|
|
356 |
{title:"Дата", field:"data_t", width:150}
|
357 |
],
|
358 |
});
|
|
|
|
|
359 |
var fieldEl = document.getElementById("filter-field");
|
360 |
var typeEl = document.getElementById("filter-type");
|
361 |
var valueEl = document.getElementById("filter-value");
|
|
|
264 |
{title:"Номер в списке", field:"id"},
|
265 |
{title:"Имя", field:"name", width:100},
|
266 |
{title:"WhatsApp", field:"phone", formatter: function(cell, formatterParams, onRendered) {
|
267 |
+
var phone = cell.getValue();
|
268 |
+
var ws_stop = cell.getData().ws_stop;
|
269 |
+
var imageUrl1 = "https://i.ibb.co/S3Kk5vM/1.png"; // Замените на URL первой картинки
|
270 |
+
var imageUrl2 = "https://i.ibb.co/Ph3SB0m/2.png"; // Замените на URL второй картинки
|
271 |
+
var link = `<a href="https://web.whatsapp.com/send?phone=${phone}" target="_blank">`;
|
272 |
+
|
273 |
+
if (ws_stop === "1") {
|
274 |
+
return link + `<img src="${imageUrl1}" alt="WhatsApp" style="width: 98px; height: 14px;">`;
|
275 |
+
} else {
|
276 |
+
return link + `<img src="${imageUrl2}" alt="WhatsApp" style="width: 98px; height: 14px;">`;
|
277 |
+
}
|
278 |
+
}},
|
279 |
{title:"Город", field:"b_city", width:110},
|
280 |
{title:"Email", field:"email", width:110},
|
281 |
+
{title:"Реплики", field:"b_mess", width:95, cellClick:function(e, cell){
|
282 |
+
var data = cell.getData();
|
283 |
+
Swal.fire({
|
284 |
+
title: 'Детали пользователя',
|
285 |
+
html: `
|
286 |
+
<strong>Имя:</strong> ${data.name}<br>
|
287 |
+
<strong>WhatsApp:</strong> <a href="https://web.whatsapp.com/send?phone=${data.phone}" target="_blank">${data.phone}</a><br>
|
288 |
+
<strong>Реплики:</strong> ${data.b_mess}`,
|
289 |
+
icon: 'success',
|
290 |
+
confirmButtonText: 'Закрыть',
|
291 |
+
confirmButtonColor: '#4CAF50',
|
292 |
+
customClass: {
|
293 |
+
confirmButton: 'button is-success',
|
294 |
+
title: 'title-custom',
|
295 |
+
content: 'content-custom'}});}},
|
296 |
+
|
|
|
|
|
|
|
297 |
{title:"Куратор", field:"curator", formatter: linkFormatter},
|
298 |
{title:"Статус покупки", field:"shop_st", formatter: function(cell, formatterParams, onRendered) {
|
299 |
var status = cell.getValue();
|
|
|
331 |
{title:"Статус WhatsApp", field:"ws_st"},
|
332 |
{title:"Стутус подписки", field:"ws_stop"},
|
333 |
{title:"Вебинары-присутствовал", field:"web_st", formatter:"star", formatterParams:{stars:7}, hozAlign:"center", width:120},
|
334 |
+
{title:"Вебинары-досмотрел до конца", field:"b_fin", formatter:function(cell, formatterParams, onRendered){
|
335 |
+
var value = cell.getValue();
|
336 |
+
var icon;
|
337 |
+
if (value === 'True') {
|
338 |
+
icon = ' <img src="https://i.ibb.co/Bnqy0q5/1.png" width="98" height="14" />'; // Иконка для активного статуса
|
339 |
+
} else {
|
340 |
+
icon = ''; // Пустая строка для неактивного статуса или если значение не определено
|
341 |
+
}
|
342 |
+
return icon;
|
343 |
+
}, width:100},
|
344 |
|
345 |
{title:"Прогрес по воронке", field:"fin_prog", formatter:"progress", formatterParams:{color:["#ff0000", "orange", "#00dd00"]}, sorter:"number", width:100},
|
346 |
{title:"pr1", field:"pr1"},
|
|
|
353 |
{title:"Дата", field:"data_t", width:150}
|
354 |
],
|
355 |
});
|
356 |
+
|
357 |
+
|
358 |
var fieldEl = document.getElementById("filter-field");
|
359 |
var typeEl = document.getElementById("filter-type");
|
360 |
var valueEl = document.getElementById("filter-value");
|