libs/web: move XHR apply callback into subtemplate
[project/luci.git] / applications / luci-fw / luasrc / model / cbi / luci_fw / traffic.lua
index c3efdd8..3bdc6db 100644 (file)
@@ -13,15 +13,21 @@ You may obtain a copy of the License at
 $Id$
 ]]--
 
-m = Map("firewall", translate("fw_traffic"))
-s = m:section(TypedSection, "forwarding", translate("fw_forwarding"), translate("fw_forwarding1"))
+m = Map("firewall", translate("Traffic Control"))
+s = m:section(TypedSection, "forwarding", translate("Zone-to-Zone traffic"),
+       translate("Here you can specify which network traffic is allowed " ..
+               "to flow between network zones. Only new connections will " ..
+               "be matched.  Packets belonging to already open " ..
+               "connections are automatically allowed to pass the " ..
+               "firewall. If you experience occasional connection " ..
+               "problems try enabling MSS Clamping otherwise disable it " ..
+               "for performance reasons."))
 s.template  = "cbi/tblsection"
 s.addremove = true
 s.anonymous = true
 
-iface = s:option(ListValue, "src", translate("fw_src"))
-oface = s:option(ListValue, "dest", translate("fw_dest"))
-s:option(Flag, "mtu_fix", translate("fw_mtufix"))
+iface = s:option(ListValue, "src", translate("Source"))
+oface = s:option(ListValue, "dest", translate("Destination"))
 
 luci.model.uci.cursor():foreach("firewall", "zone",
        function (section)
@@ -31,7 +37,7 @@ luci.model.uci.cursor():foreach("firewall", "zone",
 
 
 
-s = m:section(TypedSection, "rule")
+s = m:section(TypedSection, "rule", translate("Rules"))
 s.addremove = true
 s.anonymous = true
 s.template = "cbi/tblsection"
@@ -54,10 +60,10 @@ function s.parse(self, ...)
        end
 end
 
-s:option(DummyValue, "_name", translate("name"))
-s:option(DummyValue, "proto", translate("protocol"))
+s:option(DummyValue, "_name", translate("Name"))
+s:option(DummyValue, "proto", translate("Protocol"))
 
-src = s:option(DummyValue, "src", translate("fw_src"))
+src = s:option(DummyValue, "src", translate("Source"))
 function src.cfgvalue(self, s)
        return "%s:%s:%s" % {
                self.map:get(s, "src") or "*",
@@ -66,17 +72,17 @@ function src.cfgvalue(self, s)
        } 
 end
 
-dest = s:option(DummyValue, "dest", translate("fw_dest"))
+dest = s:option(DummyValue, "dest", translate("Destination"))
 function dest.cfgvalue(self, s)
        return "%s:%s:%s" % {
-               self.map:get(s, "dest") or translate("device", "device"),
+               self.map:get(s, "dest") or translate("Device"),
                self.map:get(s, "dest_ip") or "0.0.0.0/0",
                self.map:get(s, "dest_port") or "*"
        } 
 end
 
 
-s:option(DummyValue, "target")
+s:option(DummyValue, "target", translate("Action"))
 
 
-return m
\ No newline at end of file
+return m