diff options
author | Richard Yu <yurichard3839@gmail.com> | 2019-11-04 10:02:03 +0800 |
---|---|---|
committer | Yousong Zhou <yszhou4tech@gmail.com> | 2019-11-04 10:14:15 +0800 |
commit | b83374b3401d33f1f1bc40bbb367991cc34cc918 (patch) | |
tree | 0207830ab0118912fe8d2fa86c35641f4384c925 /applications/luci-app-shadowsocks-libev/luasrc/view | |
parent | 4e9f2d3f1ef21262e8c009579d235d355fbd467a (diff) |
luci-app-shadowsocks-libev: port to client side
Signed-off-by: Richard Yu <yurichard3839@gmail.com>
Diffstat (limited to 'applications/luci-app-shadowsocks-libev/luasrc/view')
-rw-r--r-- | applications/luci-app-shadowsocks-libev/luasrc/view/shadowsocks-libev/add_instance.htm | 38 |
1 files changed, 0 insertions, 38 deletions
diff --git a/applications/luci-app-shadowsocks-libev/luasrc/view/shadowsocks-libev/add_instance.htm b/applications/luci-app-shadowsocks-libev/luasrc/view/shadowsocks-libev/add_instance.htm deleted file mode 100644 index 27e101a4d..000000000 --- a/applications/luci-app-shadowsocks-libev/luasrc/view/shadowsocks-libev/add_instance.htm +++ /dev/null @@ -1,38 +0,0 @@ -<div class="cbi-section-create cbi-tblsection-create"> - <div> - <select class="cbi-input-select" id="_newinst.type" name="_newinst.type"> - <option value="_dummy">-- instance type --</option> - <option value="ss_local">ss-local</option> - <option value="ss_tunnel">ss-tunnel</option> - <option value="ss_redir">ss-redir</option> - <option value="ss_server">ss-server</option> - </select> - </div> - <div> - <input type="text" class="cbi-input-text" id="_newinst.name" name="_newinst.name" placeholder="<%:Name%>"/> - </div> - <input type="submit" class="cbi-button cbi-button-add" name="cbi.cts.<%=self.config%>" value="<%:Add%>" /> -</div> -<script type="text/javascript">//<![CDATA[ - XHR.poll(-1, '<%=url('admin/services/shadowsocks-libev/status')%>', null, - function(x, st) - { - var names = [ - <%- - for _, name in ipairs(self:cfgsections()) do - write("%q," % name) - end - -%> - ]; - var instances = st["instances"] || {}; - for (var i = 0, len = names.length; i < len; i++) { - var name = names[i]; - var el = document.getElementById('cbi-table-' + name + '-running'); - if (el) { - var running = instances.hasOwnProperty(name)? instances[name].running : false; - el.innerText = running ? 'yes' : 'no'; - } - } - } - ); -//]]></script> |