1 -- Copyright 2015 Daniel Dickinson <openwrt@daniel.thecshore.com>
2 -- Licensed to the public under the Apache License 2.0.
4 module("luci.controller.nut", package.seeall)
7 if not nixio.fs.access("/etc/config/nut_server") and not nixio.fs.access("/etc/config/nut_monitor") and not nixio.fs.access("/etc/config/nut_cgi") then
11 entry({"admin", "services", "nut"}, firstchild(), _("Network UPS Tools"))
13 if nixio.fs.access("/etc/config/nut_server") then
14 entry({"admin", "services", "nut", "server"}, cbi("nut_server"), _("Network UPS Tools (Server)"), 20)
17 if nixio.fs.access("/etc/config/nut_monitor") then
18 entry({"admin", "services", "nut", "monitor"}, cbi("nut_monitor"), _("Network UPS Tools (Monitor)"), 30)
21 if nixio.fs.access("/etc/config/nut_cgi") then
22 entry({"admin", "services", "nut", "cgi"}, cbi("nut_cgi"), _("Network UPS Tools (CGI)"), 40)