From 725b24509b764b66c68edae44cf15a36a33a5e65 Mon Sep 17 00:00:00 2001 From: Andrey Borysenko Date: Wed, 17 Apr 2024 11:22:42 +0300 Subject: [PATCH] feat: add healthcheck status displaying Signed-off-by: Andrey Borysenko --- src/mixins/AppManagement.js | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/mixins/AppManagement.js b/src/mixins/AppManagement.js index f087184b..a2d96b96 100644 --- a/src/mixins/AppManagement.js +++ b/src/mixins/AppManagement.js @@ -10,7 +10,7 @@ export default { return this.app && this.$store.getters.loading(this.app.id) }, isInitializing() { - return this.app && Object.hasOwn(this.app?.status, 'action') && this.app.status.action === 'init' + return this.app && Object.hasOwn(this.app?.status, 'action') && (this.app.status.action === 'init' || this.app.status.action === 'healthcheck') }, isDeploying() { return this.app && Object.hasOwn(this.app?.status, 'action') && this.app.status.action === 'deploy' @@ -31,6 +31,9 @@ export default { if (this.app && Object.hasOwn(this.app?.status, 'action') && this.app.status.action === 'init') { return t('app_api', '{progress}% Initializing', { progress: this.app.status?.init }) } + if (this.app && Object.hasOwn(this.app?.status, 'action') && this.app.status.action === 'healthcheck') { + return t('app_api', 'Healthcheck') + } if (this.app.needsDownload) { return t('app_api', 'Deploy and Enable') } @@ -43,6 +46,9 @@ export default { if (this.app && Object.hasOwn(this.app?.status, 'action') && this.app.status.action === 'init') { return t('app_api', '{progress}% Initializing', { progress: this.app.status?.init }) } + if (this.app && Object.hasOwn(this.app?.status, 'action') && this.app.status.action === 'healthcheck') { + return t('app_api', 'Healthcheck') + } return t('app_api', 'Disable') }, forceEnableButtonText() {