Trying to show default ordering after initial whithout the grey grouping tr , then shows the group tr after one html select selected.
But the grouping is drawn by
"order": [[1, 'asc']],
"drawCallback": function (settings){
var api = this.api();
var rows = api.rows({ page: 'current' }).nodes();
var last = null;
api.column(1, { page: 'current' }).data().each(function (group, i) {
if (last !== group) {
$(rows).eq(i).before(
'<tr class="group"><td colspan="1">' + '<b>' + group + '</b>' + '</td><td colspan="5"></td></tr>'
);
last = group;
}
});
},
I tried rowGroup extension which didn't worked out.
I just wondering how can I triger the drawCallback or call some api to add the grouping <tr> after my select on 'change'.