applications/luci-radvd: fix some variable clashes in overview model
This commit is contained in:
parent
a3c3168b1c
commit
258bfb7b81
1 changed files with 12 additions and 12 deletions
|
@ -263,7 +263,7 @@ s4.extedit = luci.dispatcher.build_url("admin/network/radvd/rdnss/%s")
|
||||||
s4.addremove = true
|
s4.addremove = true
|
||||||
s4.anonymous = true
|
s4.anonymous = true
|
||||||
|
|
||||||
function s.create(...)
|
function s4.create(...)
|
||||||
local id = TypedSection.create(...)
|
local id = TypedSection.create(...)
|
||||||
luci.http.redirect(s4.extedit % id)
|
luci.http.redirect(s4.extedit % id)
|
||||||
end
|
end
|
||||||
|
@ -331,19 +331,19 @@ end
|
||||||
-- DNSSL
|
-- DNSSL
|
||||||
--
|
--
|
||||||
|
|
||||||
s4 = m:section(TypedSection, "dnssl", translate("DNSSL"))
|
s5 = m:section(TypedSection, "dnssl", translate("DNSSL"))
|
||||||
s4.template = "cbi/tblsection"
|
s5.template = "cbi/tblsection"
|
||||||
s4.extedit = luci.dispatcher.build_url("admin/network/radvd/dnssl/%s")
|
s5.extedit = luci.dispatcher.build_url("admin/network/radvd/dnssl/%s")
|
||||||
s4.addremove = true
|
s5.addremove = true
|
||||||
s4.anonymous = true
|
s5.anonymous = true
|
||||||
|
|
||||||
function s.create(...)
|
function s5.create(...)
|
||||||
local id = TypedSection.create(...)
|
local id = TypedSection.create(...)
|
||||||
luci.http.redirect(s4.extedit % id)
|
luci.http.redirect(s5.extedit % id)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
o = s4:option(Flag, "ignore", translate("Enable"))
|
o = s5:option(Flag, "ignore", translate("Enable"))
|
||||||
o.rmempty = false
|
o.rmempty = false
|
||||||
o.width = "30px"
|
o.width = "30px"
|
||||||
function o.cfgvalue(...)
|
function o.cfgvalue(...)
|
||||||
|
@ -354,11 +354,11 @@ function o.write(self, section, value)
|
||||||
Flag.write(self, section, value == "1" and "0" or "1")
|
Flag.write(self, section, value == "1" and "0" or "1")
|
||||||
end
|
end
|
||||||
|
|
||||||
o = s4:option(DummyValue, "interface", translate("Interface"))
|
o = s5:option(DummyValue, "interface", translate("Interface"))
|
||||||
o.template = "cbi/network_netinfo"
|
o.template = "cbi/network_netinfo"
|
||||||
o.width = "10%"
|
o.width = "10%"
|
||||||
|
|
||||||
o = s4:option(DummyValue, "suffix", translate("Suffix"))
|
o = s5:option(DummyValue, "suffix", translate("Suffix"))
|
||||||
o.width = "60%"
|
o.width = "60%"
|
||||||
function o.cfgvalue(self, section)
|
function o.cfgvalue(self, section)
|
||||||
local v = m.uci:get_list("radvd", section, "suffix")
|
local v = m.uci:get_list("radvd", section, "suffix")
|
||||||
|
@ -375,7 +375,7 @@ function o.cfgvalue(self, section)
|
||||||
return table.concat(l, ", ")
|
return table.concat(l, ", ")
|
||||||
end
|
end
|
||||||
|
|
||||||
o = s4:option(DummyValue, "AdvDNSSLLifetime", translate("Lifetime"))
|
o = s5:option(DummyValue, "AdvDNSSLLifetime", translate("Lifetime"))
|
||||||
function o.cfgvalue(self, section)
|
function o.cfgvalue(self, section)
|
||||||
local v = Value.cfgvalue(self, section) or "1200"
|
local v = Value.cfgvalue(self, section) or "1200"
|
||||||
return translate(v)
|
return translate(v)
|
||||||
|
|
Loading…
Reference in a new issue