diff options
Diffstat (limited to 'modules/niu/luasrc/controller')
-rw-r--r-- | modules/niu/luasrc/controller/niu/dashboard.lua | 3 | ||||
-rw-r--r-- | modules/niu/luasrc/controller/niu/network.lua | 15 | ||||
-rw-r--r-- | modules/niu/luasrc/controller/niu/system.lua | 13 |
3 files changed, 21 insertions, 10 deletions
diff --git a/modules/niu/luasrc/controller/niu/dashboard.lua b/modules/niu/luasrc/controller/niu/dashboard.lua index f6c8939808..bd4875cb9e 100644 --- a/modules/niu/luasrc/controller/niu/dashboard.lua +++ b/modules/niu/luasrc/controller/niu/dashboard.lua @@ -26,7 +26,8 @@ function index() end entry({"niu"}, alias("niu", "dashboard"), "NIU", 10) - entry({"niu", "dashboard"}, call("dashboard"), "Dashboard", 1) + entry({"niu", "dashboard"}, call("dashboard"), "Dashboard", 1).css = + "niu.css" end local require = req diff --git a/modules/niu/luasrc/controller/niu/network.lua b/modules/niu/luasrc/controller/niu/network.lua index c90662b6e6..9301e25028 100644 --- a/modules/niu/luasrc/controller/niu/network.lua +++ b/modules/niu/luasrc/controller/niu/network.lua @@ -16,23 +16,28 @@ local require = require module "luci.controller.niu.network" function index() - entry({"niu", "network"}, nil, "Network", 10).dbtemplate = "niu/network" + local toniu = {on_success_to={"niu"}} + + local e = entry({"niu", "network"}, alias("niu"), "Network", 10) + e.niu_dbtemplate = "niu/network" + e.niu_dbtasks = true + e.niu_dbicon = "icons32/network-workgroup.png" entry({"niu", "network", "wan"}, - cbi("niu/network/wan", {on_success_to={"niu"}}), "Configure Internet Connection", 10) + cbi("niu/network/wan", toniu), "Configure Internet Connection", 1) entry({"niu", "network", "lan"}, - cbi("niu/network/lan", {on_success_to={"niu"}}), "Configure Local Network", 20) + cbi("niu/network/lan", toniu), "Configure Local Network", 2) uci.inst_state:foreach("dhcp", "dhcp", function(s) if s.interface == "lan" and s.ignore ~= "1" then entry({"niu", "network", "assign"}, cbi("niu/network/assign", - {on_success_to={"niu"}}), "Display and Customize Address Assignment", 30) + toniu), "Display and Customize Address Assignment", 30) end end) entry({"niu", "network", "routes"}, cbi("niu/network/routes", - {on_success_to={"niu"}}), "Display and Customize Routing", 40) + toniu), "Display and Customize Routing", 40) entry({"niu", "network", "conntrack"}, call("cnntrck"), "Display Local Network Activity", 50) diff --git a/modules/niu/luasrc/controller/niu/system.lua b/modules/niu/luasrc/controller/niu/system.lua index 5ffed306b0..2adf1d7623 100644 --- a/modules/niu/luasrc/controller/niu/system.lua +++ b/modules/niu/luasrc/controller/niu/system.lua @@ -16,13 +16,18 @@ local require, pairs, unpack, tonumber = require, pairs, unpack, tonumber module "luci.controller.niu.system" function index() - entry({"niu", "system"}, nil, "System", 20).dbtemplate = "niu/system" + local toniu = {on_success_to={"niu"}} + + local e = entry({"niu", "system"}, alias("niu"), "System", 20) + e.niu_dbtemplate = "niu/system" + e.niu_dbtasks = true + e.niu_dbicon = "icons32/preferences-system.png" entry({"niu", "system", "general"}, - cbi("niu/system/general", {on_success_to={"niu"}}), "Configure Device", 10) + cbi("niu/system/general", toniu), "Configure Device", 1) - entry({"niu", "system", "backup"}, call("backup"), "Backup or Restore Settings", 20) - entry({"niu", "system", "upgrade"}, call("upgrade"), "Upgrade Firmware", 40) + entry({"niu", "system", "backup"}, call("backup"), "Backup or Restore Settings", 2) + entry({"niu", "system", "upgrade"}, call("upgrade"), "Upgrade Firmware", 30) end function backup() |