diff options
author | Jo-Philipp Wich <jow@openwrt.org> | 2009-01-16 20:02:45 +0000 |
---|---|---|
committer | Jo-Philipp Wich <jow@openwrt.org> | 2009-01-16 20:02:45 +0000 |
commit | 9de7ed0945db1915a430e5d8339c7f3c18682e7e (patch) | |
tree | 5b27729a400f4d820247ee75622dfd7ca5716287 /applications/luci-fw/luasrc/model | |
parent | 8458684ab9f95c042fdeed43492331d02c85a6f4 (diff) |
applications/luci-fw:
- add toggle for the drop_invalid option
- bump translations
Diffstat (limited to 'applications/luci-fw/luasrc/model')
-rw-r--r-- | applications/luci-fw/luasrc/model/cbi/luci_fw/zones.lua | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/applications/luci-fw/luasrc/model/cbi/luci_fw/zones.lua b/applications/luci-fw/luasrc/model/cbi/luci_fw/zones.lua index 38f95136d0..81a0f65cf7 100644 --- a/applications/luci-fw/luasrc/model/cbi/luci_fw/zones.lua +++ b/applications/luci-fw/luasrc/model/cbi/luci_fw/zones.lua @@ -19,6 +19,12 @@ s.anonymous = true s:option(Flag, "syn_flood") +local di = s:option(Flag, "drop_invalid", translate("fw_dropinvalid")) +di.rmempty = false +function di.cfgvalue(...) + return AbstractValue.cfgvalue(...) or "1" +end + p = {} p[1] = s:option(ListValue, "input") p[2] = s:option(ListValue, "output") @@ -56,7 +62,7 @@ net = s:option(MultiValue, "network") net.widget = "select" net.rmempty = true luci.tools.webadmin.cbi_add_networks(net) - + function net.cfgvalue(self, section) local value = MultiValue.cfgvalue(self, section) return value or name:cfgvalue(section) |