diff options
Diffstat (limited to 'applications/luci-app-shadowsocks-libev/luasrc')
-rw-r--r-- | applications/luci-app-shadowsocks-libev/luasrc/model/shadowsocks-libev.lua | 4 | ||||
-rw-r--r-- | applications/luci-app-shadowsocks-libev/luasrc/view/shadowsocks-libev/add_instance.htm | 33 |
2 files changed, 15 insertions, 22 deletions
diff --git a/applications/luci-app-shadowsocks-libev/luasrc/model/shadowsocks-libev.lua b/applications/luci-app-shadowsocks-libev/luasrc/model/shadowsocks-libev.lua index af1a75b6f2..5fc20c52bc 100644 --- a/applications/luci-app-shadowsocks-libev/luasrc/model/shadowsocks-libev.lua +++ b/applications/luci-app-shadowsocks-libev/luasrc/model/shadowsocks-libev.lua @@ -23,7 +23,7 @@ function values_actions(o) end function values_redir(o, xmode) - o.map.uci.foreach("shadowsocks-libev", "ss_redir", function(sdata) + o.map.uci:foreach("shadowsocks-libev", "ss_redir", function(sdata) local disabled = ucival_to_bool(sdata["disabled"]) local sname = sdata[".name"] local mode = sdata["mode"] or "tcp_only" @@ -37,7 +37,7 @@ function values_redir(o, xmode) end function values_serverlist(o) - o.map.uci.foreach("shadowsocks-libev", "server", function(sdata) + o.map.uci:foreach("shadowsocks-libev", "server", function(sdata) local sname = sdata[".name"] local server = sdata["server"] local server_port = sdata["server_port"] 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 index 219d89b074..f016dd47e6 100644 --- 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 @@ -1,24 +1,17 @@ <div class="cbi-section-create cbi-tblsection-create"> - <br /> - <table class="cbi-section-table"> - <tr class="cbi-section-table-row"> - <td class="cbi-section-table-cell" style="width:140px"> - <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> - </td> - <td class="cbi-section-table-cell" style="width:110px"> - <input type="text" class="cbi-input-text" id="_newinst.name" name="_newinst.name" placeholder="<%:Name%>"/> - </td> - <td class="cbi-section-table-cell left"> - <input type="submit" class="cbi-button cbi-button-add" name="cbi.cts.<%=self.config%>" value="<%:Add%>" /> - </td> - </tr> - </table> + <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(5, '<%=url('admin/services/shadowsocks-libev/status')%>', null, |