diff options
author | Liangbin Lian <jjm2473@gmail.com> | 2022-08-16 14:03:09 +0800 |
---|---|---|
committer | Liangbin Lian <jjm2473@gmail.com> | 2022-08-17 21:36:52 +0800 |
commit | 175487f054b904383673d85ca95bdccb386919c1 (patch) | |
tree | 59de8650070efd0131e9ff28be8fe894b1268291 /applications/luci-app-frpc/htdocs/luci-static | |
parent | 4a7726ac624611c2226dad2a6ee22f4008b37381 (diff) |
luci-app-frpc: add plugin options
Signed-off-by: Liangbin Lian <jjm2473@gmail.com>
Diffstat (limited to 'applications/luci-app-frpc/htdocs/luci-static')
-rw-r--r-- | applications/luci-app-frpc/htdocs/luci-static/resources/view/frpc.js | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/applications/luci-app-frpc/htdocs/luci-static/resources/view/frpc.js b/applications/luci-app-frpc/htdocs/luci-static/resources/view/frpc.js index 84eb9f8655..0999ba0294 100644 --- a/applications/luci-app-frpc/htdocs/luci-static/resources/view/frpc.js +++ b/applications/luci-app-frpc/htdocs/luci-static/resources/view/frpc.js @@ -72,6 +72,16 @@ var stcpProxyConf = [ [form.Value, 'sk', _('Sk')], ]; +var pluginConf = [ + [form.ListValue, 'plugin', _('Plugin'), undefined, {values: ['', 'http_proxy', 'socks5', 'unix_domain_socket'], rmempty: true}], + [form.Value, 'plugin_http_user', _('HTTP user'), undefined, {depends: {plugin: 'http_proxy'}}], + [form.Value, 'plugin_http_passwd', _('HTTP password'), undefined, {depends: {plugin: 'http_proxy'}}], + [form.Value, 'plugin_user', _('SOCKS5 user'), undefined, {depends: {plugin: 'socks5'}}], + [form.Value, 'plugin_passwd', _('SOCKS5 password'), undefined, {depends: {plugin: 'socks5'}}], + [form.Value, 'plugin_unix_path', _('Unix domain socket path'), undefined, {depends: {plugin: 'unix_domain_socket'}, optional: false, rmempty: false, + datatype: 'file', placeholder: '/var/run/docker.sock', default: '/var/run/docker.sock'}], +]; + function setParams(o, params) { if (!params) return; for (var key in params) { @@ -207,6 +217,7 @@ return view.extend({ s.tab('general', _('General Settings')); s.tab('http', _('HTTP Settings')); + s.tab('plugin', _('Plugin Settings')); s.option(form.Value, 'name', _('Proxy name')).modalonly = false; s.option(form.Value, 'type', _('Proxy type')).modalonly = false; @@ -235,6 +246,9 @@ return view.extend({ // STCP and XTCP defTabOpts(s, 'general', stcpProxyConf, {modalonly: true, depends: [{type: 'stcp'}, {type: 'xtcp'}]}); + // Plugin + defTabOpts(s, 'plugin', pluginConf, {modalonly: true}); + return m.render(); } }); |