mirror of
https://github.com/ntop/ntopng.git
synced 2026-05-03 01:10:10 +00:00
39 lines
841 B
JavaScript
39 lines
841 B
JavaScript
$(function () {
|
|
const TABLE_DATA_REFRESH = 15000;
|
|
|
|
let dtConfig = DataTableUtils.getStdDatatableConfig([
|
|
{
|
|
text: '<i class="fas fa-sync"></i>',
|
|
className: 'btn-link',
|
|
action: () => {
|
|
$flowdevicesList.ajax.reload();
|
|
}
|
|
}
|
|
]);
|
|
dtConfig = DataTableUtils.setAjaxConfig(dtConfig, `${http_prefix}/lua/pro/rest/v2/get/flowdevices/stats.lua?ifid=${ifid}`, 'rsp');
|
|
dtConfig = DataTableUtils.extendConfig(dtConfig, {
|
|
columns: [
|
|
{
|
|
data: 'column_ip'
|
|
},
|
|
{
|
|
data: 'column_chart',
|
|
className: "text-center",
|
|
width: "15%",
|
|
},
|
|
{
|
|
data: 'column_name'
|
|
},
|
|
{
|
|
data: 'column_descr'
|
|
},
|
|
{
|
|
data: 'column_location'
|
|
},
|
|
],
|
|
initComplete: function (settings, json) {
|
|
}
|
|
});
|
|
|
|
const $flowdevicesList = $(`table#flowdevices-list`).DataTable(dtConfig);
|
|
});
|