luci-app-openclash: sync with upstream source
This commit is contained in:
parent
394160de96
commit
4d2c36d7ba
@ -294,8 +294,17 @@ do
|
||||
else
|
||||
proxy_provider_path_exist=1
|
||||
fi
|
||||
|
||||
done
|
||||
|
||||
if [ -z "$(pidof clash)" ] && [ "$proxy_provider_mode" = 1 ]; then
|
||||
echo "错误: OpenClash 启动失败,请到日志页面查看详细错误信息!" >$START_LOG
|
||||
echo "${LOGTIME} OpenClash Can Not Start, Please Check The Error Info And Try Again" >> $LOG_FILE
|
||||
sleep 10
|
||||
echo "" >$START_LOG
|
||||
stop && echo "" >$START_LOG
|
||||
exit 0
|
||||
fi
|
||||
|
||||
}
|
||||
|
||||
#切割配置文件以分开处理
|
||||
|
||||
@ -119,18 +119,15 @@ e.inputstyle="reset"
|
||||
Button.render(e,t,a)
|
||||
end
|
||||
btnrm.write=function(a,t)
|
||||
local a=fs.unlink("/etc/openclash/game_rules/"..e[t].filename)
|
||||
HTTP.redirect(luci.dispatcher.build_url("admin", "services", "openclash", "game-settings"))
|
||||
fs.unlink("/etc/openclash/game_rules/"..e[t].filename)
|
||||
HTTP.redirect(DISP.build_url("admin", "services", "openclash", "game-settings"))
|
||||
end
|
||||
|
||||
local t = {
|
||||
{Commit, Apply}
|
||||
}
|
||||
|
||||
ap = SimpleForm("apply")
|
||||
ap.reset = false
|
||||
ap.submit = false
|
||||
ss = ap:section(Table, t)
|
||||
ss = m:section(Table, t)
|
||||
|
||||
o = ss:option(Button, "Commit")
|
||||
o.inputtitle = translate("Commit Configurations")
|
||||
@ -149,4 +146,4 @@ o.write = function()
|
||||
HTTP.redirect(DISP.build_url("admin", "services", "openclash"))
|
||||
end
|
||||
|
||||
return m, ap, form
|
||||
return m, form
|
||||
|
||||
Loading…
Reference in New Issue
Block a user