mirror of
https://github.com/ntop/ntopng.git
synced 2026-04-29 07:29:32 +00:00
Improved items placements on stacked bar
This commit is contained in:
parent
d4068bb48a
commit
c889e011f6
1 changed files with 3 additions and 0 deletions
|
|
@ -202,12 +202,15 @@ function stackedProgressBars(total, bars, other_label, formatter, css_class)
|
|||
}
|
||||
end
|
||||
|
||||
num = 0
|
||||
for _, bar in ipairs(legend_items) do
|
||||
res[#res + 1] = [[<span>]]
|
||||
if(num > 0) then res[#res + 1] = [[<br>]] end
|
||||
if bar.link ~= nil then res[#res + 1] = [[<a href="]] .. bar.link .. [[">]] end
|
||||
res[#res + 1] = [[<span class="label label-]].. (bar.class) ..[[" style="]] .. bar.style .. [["> </span>]]
|
||||
if bar.link ~= nil then res[#res + 1] = [[</a>]] end
|
||||
res[#res + 1] = [[<span>]] .. bar.title .. " (".. formatter(bar.value) ..")</span></span>"
|
||||
num = num + 1
|
||||
end
|
||||
|
||||
res[#res + 1] = [[<span style="margin-left: 0"><span></span><span> - ]] .. i18n("total") .. ": ".. formatter(total) .."</span></span>"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue