summaryrefslogtreecommitdiffhomepage
path: root/modules
diff options
context:
space:
mode:
authorJo-Philipp Wich <jo@mein.io>2016-07-29 15:28:28 +0200
committerGitHub <noreply@github.com>2016-07-29 15:28:28 +0200
commitf9e5d11d62cbb3c4203a07ac5cc3873a783bb824 (patch)
tree33c864cf1e21745002bdef68ae4f4087423d2a33 /modules
parent936d7716132653c6e23f96af2f2467c77bef1ff9 (diff)
parent8b07a65117b8a9ebbed801579d34ae8f51255868 (diff)
Merge pull request #766 from feckert/config_diag_url
luci-mod-admin-full: make diagnostics url customizable
Diffstat (limited to 'modules')
-rw-r--r--modules/luci-base/root/etc/config/luci5
-rw-r--r--modules/luci-mod-admin-full/luasrc/view/admin_network/diagnostics.htm6
2 files changed, 8 insertions, 3 deletions
diff --git a/modules/luci-base/root/etc/config/luci b/modules/luci-base/root/etc/config/luci
index baa3ac5d1e..a443742f93 100644
--- a/modules/luci-base/root/etc/config/luci
+++ b/modules/luci-base/root/etc/config/luci
@@ -22,3 +22,8 @@ config internal ccache
option enable 1
config internal themes
+
+config internal 'diag'
+ option ping 'dev.openwrt.org'
+ option route 'dev.openwrt.org'
+ option dns 'dev.openwrt.org'
diff --git a/modules/luci-mod-admin-full/luasrc/view/admin_network/diagnostics.htm b/modules/luci-mod-admin-full/luasrc/view/admin_network/diagnostics.htm
index 685082a335..90d7117175 100644
--- a/modules/luci-mod-admin-full/luasrc/view/admin_network/diagnostics.htm
+++ b/modules/luci-mod-admin-full/luasrc/view/admin_network/diagnostics.htm
@@ -63,7 +63,7 @@ local has_traceroute6 = fs.access("/usr/bin/traceroute6")
<br />
<div style="width:30%; float:left">
- <input style="margin: 5px 0" type="text" value="dev.openwrt.org" name="ping" /><br />
+ <input style="margin: 5px 0" type="text" value="<%=luci.config.diag.ping%>" name="ping" /><br />
<% if has_ping6 then %>
<select name="ping_proto" style="width:auto">
<option value="" selected="selected"><%:IPv4%></option>
@@ -76,7 +76,7 @@ local has_traceroute6 = fs.access("/usr/bin/traceroute6")
</div>
<div style="width:33%; float:left">
- <input style="margin: 5px 0" type="text" value="dev.openwrt.org" name="traceroute" /><br />
+ <input style="margin: 5px 0" type="text" value="<%=luci.config.diag.route%>" name="traceroute" /><br />
<% if has_traceroute6 then %>
<select name="traceroute_proto" style="width:auto">
<option value="" selected="selected"><%:IPv4%></option>
@@ -93,7 +93,7 @@ local has_traceroute6 = fs.access("/usr/bin/traceroute6")
</div>
<div style="width:33%; float:left;">
- <input style="margin: 5px 0" type="text" value="dev.openwrt.org" name="nslookup" /><br />
+ <input style="margin: 5px 0" type="text" value="<%=luci.config.diag.dns%>" name="nslookup" /><br />
<input type="button" value="<%:Nslookup%>" class="cbi-button cbi-button-apply" onclick="update_status(this.form.nslookup)" />
</div>