🎨 Sync 2026-08-05 00:15:00

This commit is contained in:
github-actions[bot]
2026-08-05 00:15:00 +08:00
parent 9b522ebf42
commit e40fd6d46b
72 changed files with 1246 additions and 78 deletions
@@ -6,8 +6,15 @@ XHR.poll(5, '<%=url("admin/services/kaiplus_status")%>', null, function(x, st) {
el.innerHTML = '<br/><em style=\"color:red\"><%:The KaiPlus service is not running.%></em>';
}
if (st.running) {
var basePath = st.base_path || "/apps/kaiplus/";
if (basePath.charAt(0) !== "/") {
basePath = "/" + basePath;
}
if (basePath.charAt(basePath.length - 1) !== "/") {
basePath = basePath + "/";
}
el.innerHTML = '<br/><em style=\"color:green\"><%:The KaiPlus service is running.%></em>'
+ "<br/><br/><input class=\"btn cbi-button cbi-button-apply\" type=\"button\" value=\" <%:Click to open KaiPlus%> \" onclick=\"window.open('http://" + window.location.hostname + ":" + st.port + "/')\"/>";
+ "<br/><br/><input class=\"btn cbi-button cbi-button-apply\" type=\"button\" value=\" <%:Click to open KaiPlus%> \" onclick=\"window.open('http://' + window.location.hostname + ':' + st.port + basePath)\"/>";
}
}
});