summaryrefslogtreecommitdiffhomepage
path: root/applications/luci-app-firewall/htdocs/luci-static/resources/tools/firewall.js
diff options
context:
space:
mode:
authorJo-Philipp Wich <jo@mein.io>2019-07-18 12:28:42 +0200
committerGitHub <noreply@github.com>2019-07-18 12:28:42 +0200
commit776e6d540990eabcd134d0bee8dd54695d9c53a7 (patch)
treed404f69600a0a3fb725cf7f96c52aa44aa619220 /applications/luci-app-firewall/htdocs/luci-static/resources/tools/firewall.js
parentd52990bc82a9c6ba95375bb15122c6a349db91d1 (diff)
parentb15c62071cd971eebf82547b4969d975d237c7a3 (diff)
Merge pull request #2880 from tano-systems/pr/fix-for-2878
luci-app-firewall: format protocol family for forwards and rules
Diffstat (limited to 'applications/luci-app-firewall/htdocs/luci-static/resources/tools/firewall.js')
-rw-r--r--applications/luci-app-firewall/htdocs/luci-static/resources/tools/firewall.js9
1 files changed, 9 insertions, 0 deletions
diff --git a/applications/luci-app-firewall/htdocs/luci-static/resources/tools/firewall.js b/applications/luci-app-firewall/htdocs/luci-static/resources/tools/firewall.js
index 6785d1ca63..198528aaa5 100644
--- a/applications/luci-app-firewall/htdocs/luci-static/resources/tools/firewall.js
+++ b/applications/luci-app-firewall/htdocs/luci-static/resources/tools/firewall.js
@@ -211,6 +211,15 @@ return L.Class.extend({
return rv;
},
+ fmt_family: function(family) {
+ if (family == 'ipv4')
+ return _('IPv4');
+ else if (family == 'ipv6')
+ return _('IPv6');
+ else
+ return _('IPv4 and IPv6');
+ },
+
fmt_proto: function(x, icmp_types) {
var rv = E([]), l = L.toArray(x);