diff --git a/modules/http/webif/gstatic/datatables/datatables.defaults.js b/modules/http/webif/gstatic/datatables/datatables.defaults.js index 8161d4c1c1..a4727898f0 100755 --- a/modules/http/webif/gstatic/datatables/datatables.defaults.js +++ b/modules/http/webif/gstatic/datatables/datatables.defaults.js @@ -89,7 +89,12 @@ $(window).bind('datatables_defaults', function() { //setTimeout(function() { $(window).resize(); }, 2000); }, - responsive: {details: {type: 'column', renderer: $.fn.dataTable.Responsive.renderer.listHidden()}}, //makes it possible to update columns even if they are not shown as columns (but as collapsable items) + responsive: { + details: { + type: 'column', + renderer: $.fn.dataTable.Responsive.renderer.listHidden() + } + }, //makes it possible to update columns even if they are not shown as columns (but as collapsable items) preDrawCallback: function (oSettings) { // scroll diff --git a/modules/http/webif/gstatic/js/smarthomeng.js b/modules/http/webif/gstatic/js/smarthomeng.js index 7b1003109e..9293c18c51 100644 --- a/modules/http/webif/gstatic/js/smarthomeng.js +++ b/modules/http/webif/gstatic/js/smarthomeng.js @@ -115,7 +115,10 @@ function shngInsertText (id, text, table_id=null, highlight=0) { } // update datatable cell if (new_content) { - $('#' + table_id).DataTable().cell( $('#' + $.escapeSelector(id)) ).data(text); + let table = $('#' + table_id).DataTable(); + table.cell( $('#' + $.escapeSelector(id)) ).data(text).invalidate(); + table.responsive.rebuild(); + table.responsive.recalc(); console.log("Updating table because new cell data found: " + text + " for id " + id + ", old text: " + old_text); // $('#' + table_id).DataTable().draw(false); }