[WIP] Checking maintenance time using maintenance_timeslot table

This commit is contained in:
Louis Lam
2022-09-27 20:44:44 +08:00
parent 3f63cb246b
commit 4002b9f577
9 changed files with 75 additions and 13 deletions

View File

@@ -47,7 +47,7 @@ export default {
}
if (this.status === 3) {
return this.$t("Maintenance");
return this.$t("statusMaintenance");
}
return this.$t("Unknown");

View File

@@ -26,7 +26,7 @@ export default {
uptime() {
if (this.type === "maintenance") {
return this.$t("Maintenance");
return this.$t("statusMaintenance");
}
let key = this.monitor.id + "_" + this.type;

View File

@@ -10,6 +10,7 @@ export default {
maxRedirectDescription: "Maximum number of redirects to follow. Set to 0 to disable redirects.",
acceptedStatusCodesDescription: "Select status codes which are considered as a successful response.",
Maintenance: "Maintenance",
statusMaintenance: "Maintenance",
"Schedule maintenance": "Schedule maintenance",
"Affected Monitors": "Affected Monitors",
"Pick Affected Monitors...": "Pick Affected Monitors...",

View File

@@ -380,4 +380,6 @@ export default {
proxyDescription: "必須將代理伺服器指派給監測器才能運作。",
enableProxyDescription: "此代理伺服器在啟用前不會在監測器上生效,您可以藉由控制啟用狀態來暫時對所有的監測器停用代理伺服器。",
setAsDefaultProxyDescription: "預設情況下,新監測器將啟用此代理伺服器。您仍可分別停用各監測器的代理伺服器。",
Maintenance: "維護",
statusMaintenance: "維護中",
};

View File

@@ -588,7 +588,7 @@ export default {
if (this.monitorList[monitorID].maintenance) {
result[monitorID] = {
text: this.$t("Maintenance"),
text: this.$t("statusMaintenance"),
color: "maintenance",
};
} else if (! lastHeartBeat) {