Refactor JS code into class NtopngUtils

Implements #3735
This commit is contained in:
Simone Mainardi 2020-08-18 11:43:22 +02:00
parent 8a0525702e
commit e61f9ffe68
56 changed files with 1168 additions and 1210 deletions

View file

@ -3780,8 +3780,8 @@ function initFlowsRefreshRows()
print[[
datatableInitRefreshRows($("#table-flows"), "key_and_hash", 10000, {
/* List of rows with trend icons */
"column_thpt": ]] print(ternary(getThroughputType() ~= "bps", "fpackets", "bitsToSize")) print[[,
"column_bytes": bytesToSize,
"column_thpt": ]] print(ternary(getThroughputType() ~= "bps", "NtopngUtils.fpackets", "NtopngUtils.bitsToSize")) print[[,
"column_bytes": NtopngUtils.bytesToSize,
});
$("#dt-bottom-details > .float-left > p").first().append('. ]]