diff --git a/luci-app-nyn/luasrc/model/cbi/nyn.lua b/luci-app-nyn/luasrc/model/cbi/nyn.lua index fc13baa..46f12be 100644 --- a/luci-app-nyn/luasrc/model/cbi/nyn.lua +++ b/luci-app-nyn/luasrc/model/cbi/nyn.lua @@ -1,23 +1,21 @@ -- /usr/lib/lua/luci/model/cbi/nyn.lua - local m, s, o local sys = require "luci.sys" -m = Map("nyn", translate("NYN 802.1x Authentication Client"), - translate("Configure 802.1x authentication for network access using NYN client")) +m = Map("nyn", "NYN 802.1x 认证客户端", + "配置使用 NYN 客户端进行网络访问的 802.1x 认证") -- Authentication Settings -s = m:section(TypedSection, "auth", translate("Authentication Settings")) +s = m:section(TypedSection, "auth", "认证设置") s.anonymous = true s.addremove = false -- Service Status -o = s:option(DummyValue, "_status", translate("Current Status")) +o = s:option(DummyValue, "_status", "当前状态") o.rawhtml = true o.cfgvalue = function() local sys = require "luci.sys" local running = sys.call("pgrep nyn >/dev/null") == 0 - if running then return "✔ 正在运行中" else @@ -26,20 +24,21 @@ o.cfgvalue = function() end -- Enable/Disable -o = s:option(Flag, "enabled", translate("Enable Service")) +o = s:option(Flag, "enabled", "启用服务") o.rmempty = false -- Username -o = s:option(Value, "user", translate("Username"), translate("802.1x authentication username")) +o = s:option(Value, "user", "用户名", "802.1x 认证用户名") +o.password = true o.rmempty = false -- Password -o = s:option(Value, "password", translate("Password"), translate("802.1x authentication password")) +o = s:option(Value, "password", "密码", "802.1x 认证密码") o.password = true o.rmempty = false -- Network Device -o = s:option(ListValue, "device", translate("Network Device"), translate("Network device to use for authentication")) +o = s:option(ListValue, "device", "网络接口", "用于认证的网络接口") o.rmempty = false o:value("eth0", "eth0") o:value("eth1", "eth1") diff --git a/screenshot.png b/screenshot.png index 8c79568..487f447 100644 Binary files a/screenshot.png and b/screenshot.png differ