mirror of
https://github.com/ntop/ntopng.git
synced 2026-04-29 07:29:32 +00:00
Improve category editor labels and protocol navigation
This commit is contained in:
parent
11e783bae1
commit
9f8a70e279
11 changed files with 215 additions and 101 deletions
|
|
@ -3425,6 +3425,30 @@ end
|
|||
|
||||
-- ###########################################
|
||||
|
||||
-- Banner format: {type="success|warning|danger", text="..."}
|
||||
function printMessageBanners(banners)
|
||||
for _, msg in ipairs(banners) do
|
||||
print[[
|
||||
<div class="alert alert-]] print(msg.type) print([[ alert-dismissible" style="margin-top:2em; margin-bottom:0em;">
|
||||
<button type="button" class="close" data-dismiss="alert" aria-label="]]..i18n("close")..[[">
|
||||
<span aria-hidden="true">×</span>
|
||||
</button>]])
|
||||
|
||||
if (msg.type == "warning") then
|
||||
print("<b>".. i18n("warning") .. "</b>: ")
|
||||
elseif (msg.type == "danger") then
|
||||
print("<b>".. i18n("error") .. "</b>: ")
|
||||
end
|
||||
|
||||
print(msg.text)
|
||||
|
||||
print[[
|
||||
</div>]]
|
||||
end
|
||||
end
|
||||
|
||||
-- ###########################################
|
||||
|
||||
--
|
||||
-- IMPORTANT
|
||||
-- Leave it at the end so it can use the functions
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue