Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/openwrt/luci.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJo-Philipp Wich <jo@mein.io>2019-08-14 18:07:55 +0300
committerJo-Philipp Wich <jo@mein.io>2019-08-14 23:58:15 +0300
commited8f1c4c1c47465f79ddaf6af118d1dd29ee7d12 (patch)
tree914ae840352c37975e7053bbd2a60fb743eff34a /applications/luci-app-firewall/htdocs
parent7610f1d9cfc64f2841faf3f74db6976dc0c190bc (diff)
luci-app-firewall: honour global default policies in per-zone settings
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Diffstat (limited to 'applications/luci-app-firewall/htdocs')
-rw-r--r--applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/forwards.js3
-rw-r--r--applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/rules.js3
-rw-r--r--applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/zones.js8
3 files changed, 11 insertions, 3 deletions
diff --git a/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/forwards.js b/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/forwards.js
index 63af69f8a9..80938711e9 100644
--- a/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/forwards.js
+++ b/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/forwards.js
@@ -75,7 +75,8 @@ function forward_via_txt(s) {
return L.view.extend({
callHostHints: rpc.declare({
object: 'luci',
- method: 'host_hints'
+ method: 'getHostHints',
+ expect: { '': {} }
}),
load: function() {
diff --git a/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/rules.js b/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/rules.js
index a7924b1076..6df3bc7f85 100644
--- a/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/rules.js
+++ b/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/rules.js
@@ -112,7 +112,8 @@ function rule_target_txt(s) {
return L.view.extend({
callHostHints: rpc.declare({
object: 'luci',
- method: 'host_hints'
+ method: 'getHostHints',
+ expect: { '': {} }
}),
load: function() {
diff --git a/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/zones.js b/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/zones.js
index 22f1683fe4..3ac3f6e2fb 100644
--- a/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/zones.js
+++ b/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/zones.js
@@ -15,12 +15,14 @@ return L.view.extend({
load: function() {
return Promise.all([
- this.callConntrackHelpers()
+ this.callConntrackHelpers(),
+ firewall.getDefaults()
]);
},
render: function(data) {
var ctHelpers = data[0],
+ fwDefaults = data[1],
m, s, o, inp, out;
m = new form.Map('firewall', _('Firewall - Zone Settings'),
@@ -118,6 +120,10 @@ return L.view.extend({
p[i].editable = true;
}
+ p[0].default = fwDefaults.getInput();
+ p[1].default = fwDefaults.getOutput();
+ p[2].default = fwDefaults.getForward();
+
o = s.taboption('general', form.Flag, 'masq', _('Masquerading'));
o.editable = true;