1 -- Copyright 2017 Yousong Zhou <yszhou4tech@gmail.com>
2 -- Licensed to the public under the Apache License 2.0.
4 local ds = require "luci.dispatcher"
5 local ss = require("luci.model.shadowsocks-libev")
9 m = Map("shadowsocks-libev",
10 translate("Remote Servers"),
11 translate("Definition of remote shadowsocks servers. \
12 Disable any of them will also disable instances refering to it."))
16 if not m:get(sname) then
17 luci.http.redirect(ds.build_url("admin/services/shadowsocks-libev/servers"))
20 s = m:section(NamedSection, sname, "server")
21 m.title = m.title .. ' - ' .. sname
23 s = m:section(TypedSection, "server")
24 s.template = 'cbi/tblsection'
28 s:option(Flag, "disabled", translate("Disable"))