mirror of
https://github.com/ntop/ntopng.git
synced 2026-08-14 10:53:27 +00:00
reworked script editor page
This commit is contained in:
parent
3f1fabc73f
commit
1e5376da95
8 changed files with 166 additions and 110 deletions
|
|
@ -13,24 +13,14 @@ local code_editor = require("code_editor")
|
|||
|
||||
sendHTTPContentTypeHeader('text/html')
|
||||
|
||||
|
||||
local title = i18n("plugin_browser", {plugin_name = _GET["plugin_path"]})
|
||||
local url = ntop.getHttpPrefix().."/lua/code_viewer.lua"
|
||||
local title = string.gsub(i18n("plugin_browser", {plugin_name = _GET["plugin_path"]}), "/plugins/", "")
|
||||
local referal_script_page = _GET["referal_url"]
|
||||
|
||||
page_utils.set_active_menu_entry(page_utils.menu_entries.plugin_browser, {plugin_name = _GET["plugin_path"]})
|
||||
|
||||
dofile(dirs.installdir .. "/scripts/lua/inc/menu.lua")
|
||||
|
||||
page_utils.print_navbar(title, url,
|
||||
{
|
||||
{
|
||||
active = true,
|
||||
page_name = "overview",
|
||||
label = "<i class=\"fas fa-lg fa-home\"></i>",
|
||||
},
|
||||
}
|
||||
)
|
||||
|
||||
code_editor.editor(_GET["plugin_file_path"], _GET["plugin_path"])
|
||||
page_utils.print_page_title(title)
|
||||
code_editor.editor(_GET["plugin_file_path"], _GET["plugin_path"], referal_script_page)
|
||||
|
||||
dofile(dirs.installdir .. "/scripts/lua/inc/footer.lua")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue