luci-app-wrtbwmon: code alignment

This commit is contained in:
Beginner-Go 2022-06-22 17:20:21 +00:00
parent 42bc686eeb
commit 63606e6c04
2 changed files with 5 additions and 2 deletions

View File

@ -1,8 +1,11 @@
module("luci.controller.wrtbwmon", package.seeall)
function index()
if not nixio.fs.access("/etc/config/wrtbwmon") then
return
end
entry({"admin", "nlbw", "usage"}, alias("admin", "nlbw", "usage", "details"), _("Usage"), 60)
entry({"admin", "nlbw", "usage"}, alias("admin", "nlbw", "usage", "details"), _("Usage"), 60).dependent = true
entry({"admin", "nlbw", "usage", "details"}, template("wrtbwmon/wrtbwmon"), _("Details"), 10).leaf = true
entry({"admin", "nlbw", "usage", "config"}, cbi("wrtbwmon/config"), _("Configuration"), 20).leaf = true
entry({"admin", "nlbw", "usage", "custom"}, form("wrtbwmon/custom"), _("User file"), 30).leaf = true

View File

@ -6,7 +6,7 @@ uci -q batch <<-EOF >/dev/null
set firewall.wrtbwmon.type=script
set firewall.wrtbwmon.path='/etc/wrtbwmon.include'
set firewall.wrtbwmon.reload=1
commit firewall
commit firewall
EOF
/etc/init.d/wrtbwmon enable