mirror of
https://github.com/ntop/ntopng.git
synced 2026-04-30 16:09:32 +00:00
Remove unused function host_pools_nedge.hostpool2record
This commit is contained in:
parent
d179a572c5
commit
68e719530e
1 changed files with 0 additions and 33 deletions
|
|
@ -563,39 +563,6 @@ function host_pools_nedge.updateRRDs(ifid, dump_ndpi, verbose)
|
|||
end
|
||||
end
|
||||
|
||||
function host_pools_nedge.hostpool2record(ifid, pool_id, pool)
|
||||
local record = {}
|
||||
record["key"] = tostring(pool_id)
|
||||
|
||||
local pool_name = host_pools_nedge.getPoolName(pool_id)
|
||||
local pool_link = "<A HREF='"..ntop.getHttpPrefix()..'/lua/hosts_stats.lua?pool='..pool_id.."' title='"..pool_name.."'>"..pool_name..'</A>'
|
||||
record["column_id"] = pool_link
|
||||
|
||||
record["column_hosts"] = pool["num_hosts"]..""
|
||||
record["column_since"] = secondsToTime(os.time() - pool["seen.first"] + 1)
|
||||
record["column_num_dropped_flows"] = (pool["flows.dropped"] or 0)..""
|
||||
|
||||
local sent2rcvd = round((pool["bytes.sent"] * 100) / (pool["bytes.sent"] + pool["bytes.rcvd"]), 0)
|
||||
record["column_breakdown"] = "<div class='progress'><div class='progress-bar bg-warning' style='width: "
|
||||
.. sent2rcvd .."%;'>Sent</div><div class='progress-bar bg-success' style='width: " .. (100-sent2rcvd) .. "%;'>Rcvd</div></div>"
|
||||
|
||||
if(throughput_type == "pps") then
|
||||
record["column_thpt"] = pktsToSize(pool["throughput_pps"])
|
||||
else
|
||||
record["column_thpt"] = bitsToSize(8*pool["throughput_bps"])
|
||||
end
|
||||
|
||||
record["column_traffic"] = bytesToSize(pool["bytes.sent"] + pool["bytes.rcvd"])
|
||||
|
||||
record["column_chart"] = ""
|
||||
|
||||
if areHostPoolsTimeseriesEnabled(ifid) then
|
||||
record["column_chart"] = '<A HREF="'..ntop.getHttpPrefix()..'/lua/pool_details.lua?pool='..pool_id..'&page=historical"><i class=\'fas fa-chart-area fa-lg\'></i></A>'
|
||||
end
|
||||
|
||||
return record
|
||||
end
|
||||
|
||||
function host_pools_nedge.printQuotas(pool_id, host, page_params)
|
||||
--[[
|
||||
local pools_stats = interface.getHostPoolsStats()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue