few js fixes

This commit is contained in:
osaajani 2021-08-28 02:07:30 +02:00
parent 850923c1e6
commit 54f3567714
8 changed files with 21 additions and 30 deletions

View File

@ -1 +1 @@
v3.1.8
v3.1.10

View File

@ -177,6 +177,7 @@ namespace controllers\publics;
continue;
}
$receiveds[$key]['text'] = $this->s($received['text'], false, true, false);
$receiveds[$key]['origin'] = $this->s($contact['name'], false, true, false) . ' (' . \controllers\internals\Tool::phone_link($received['origin']) . ')';
}

View File

@ -127,7 +127,6 @@
data_container.find('.form-group').each(function (e)
{
console.log(this);
var current_input_name = jQuery(this).find('.contact-data-name');
var current_input_value = jQuery(this).find('.contact-data-value');

View File

@ -92,39 +92,32 @@ jQuery(document).ready(function ()
{
data: '_',
render: function (data, type, row, meta) {
var html = '<div class="bold">Réception d\'un SMS : </div>';
var html = '';
if (row.callback_reception) {
html += '<div><code>' + row.callback_reception + '</code></div>';
} else {
html += '<div>Non disponible.</div>';
html += '<div class="bold">Réception d\'un SMS : </div>';
html += '<div><code>' + jQuery.fn.dataTable.render.text().display(row.callback_reception) + '</code></div>';
html += '<br/>';
}
html += '<br/>';
html += '<div class="bold">Changement de statut d\'un SMS : </div>';
if (row.callback_status) {
html += '<div><code>' + row.callback_status + '</code></div>';
} else {
html += '<div>Non disponible.</div>';
html += '<div class="bold">Changement de statut d\'un SMS : </div>';
html += '<div><code>' + jQuery.fn.dataTable.render.text().display(row.callback_status) + '</code></div>';
html += '<br/>';
}
html += '<br/>';
html += '<div class="bold">Notification d\'appel entrant : </div>';
if (row.callback_inbound_call) {
html += '<div><code>' + row.callback_inbound_call + '</code></div>';
} else {
html += '<div>Non disponible.</div>';
html += '<div class="bold">Notification d\'appel entrant : </div>';
html += '<div><code>' + jQuery.fn.dataTable.render.text().display(row.callback_inbound_call) + '</code></div>';
html += '<br/>';
}
html += '<br/>';
html += '<div class="bold">Notification de fin d\'appel : </div>';
console.log(row);
if (row.callback_end_call) {
html += '<div><code>' + row.callback_end_call + '</code></div>';
} else {
html += '<div>Non disponible.</div>';
html += '<div class="bold">Notification de fin d\'appel : </div>';
html += '<div><code>' + jQuery.fn.dataTable.render.text().display(row.callback_end_call) + '</code></div>';
}
return html;

View File

@ -114,11 +114,11 @@ jQuery(document).ready(function ()
for (i = 0; i < row.medias.length; i++) {
medias.push('<a href="' + HTTP_PWD + '/data/public/' + jQuery.fn.dataTable.render.text().display(row.medias[i].path) + '" target="_blank">Fichier ' + (i + 1) + '</a>');
}
html = data + '<br/>' + medias.join(' - ');
html = jQuery.fn.dataTable.render.text().display(data) + '<br/>' + medias.join(' - ');
return html;
}
return data;
return jQuery.fn.dataTable.render.text().display(data);
},
},
{data: 'at', render: jQuery.fn.dataTable.render.text()},

View File

@ -95,11 +95,11 @@ jQuery(document).ready(function ()
for (i = 0; i < row.medias.length; i++) {
medias.push('<a href="' + HTTP_PWD + '/data/public/' + jQuery.fn.dataTable.render.text().display(row.medias[i].path) + '" target="_blank">Fichier ' + (i + 1) + '</a>');
}
html = data + '<br/>' + medias.join(' - ');
html = jQuery.fn.dataTable.render.text().display(data) + '<br/>' + medias.join(' - ');
return html;
}
return data;
return jQuery.fn.dataTable.render.text().display(data);
},
},
{

View File

@ -104,11 +104,11 @@ jQuery(document).ready(function ()
for (i = 0; i < row.medias.length; i++) {
medias.push('<a href="' + HTTP_PWD + '/data/public/' + jQuery.fn.dataTable.render.text().display(row.medias[i].path) + '" target="_blank">Fichier ' + (i + 1) + '</a>');
}
html = data + '<br/>' + medias.join(' - ');
html = jQuery.fn.dataTable.render.text().display(data) + '<br/>' + medias.join(' - ');
return html;
}
return data;
return jQuery.fn.dataTable.render.text().display(data);
},
},
{data: 'at', render: jQuery.fn.dataTable.render.text()},

View File

@ -178,13 +178,11 @@
{
if (event.target.value == 0)
{
console.log('disable');
jQuery('.quota-settings').addClass('hidden');
jQuery('.quota-settings input, .quota-settings select').prop('disabled', true);
}
else
{
console.log('enable');
jQuery('.quota-settings').removeClass('hidden');
jQuery('.quota-settings input, .quota-settings select').prop('disabled', false);
}