From 37d2d575146b4727b9a04ad16777d1fc3c323fc4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=80=81=E7=AB=AD=E5=8A=9B?= Date: Wed, 11 Dec 2024 12:09:53 +0800 Subject: [PATCH] Fix: Ensure totalPercentage does not go below zero during installation progress update Fix: Can not install. --- src/components/Apps/AppPanel.vue | 3 +- src/components/Apps/ComposeConfig.vue | 1199 +++++++++++++------------ src/components/CoreService.vue | 1080 +++++++++++----------- 3 files changed, 1176 insertions(+), 1106 deletions(-) diff --git a/src/components/Apps/AppPanel.vue b/src/components/Apps/AppPanel.vue index ab3c0ff0..f77941e0 100644 --- a/src/components/Apps/AppPanel.vue +++ b/src/components/Apps/AppPanel.vue @@ -1696,7 +1696,8 @@ export default { this.currentInstallAppType = resData.type if (resData.message !== '') { - this.totalPercentage = Number(resData.message) + const progress = Number(resData.message) + this.totalPercentage = progress < 0 ? 0 : progress if (this.totalPercentage === 0) { this.currentInstallAppText = 'Starting installation' diff --git a/src/components/Apps/ComposeConfig.vue b/src/components/Apps/ComposeConfig.vue index ced334a4..a5351b62 100644 --- a/src/components/Apps/ComposeConfig.vue +++ b/src/components/Apps/ComposeConfig.vue @@ -1,206 +1,59 @@ - - + + + diff --git a/src/components/CoreService.vue b/src/components/CoreService.vue index 300e7bd9..f8bf438b 100644 --- a/src/components/CoreService.vue +++ b/src/components/CoreService.vue @@ -1,106 +1,56 @@ - - + +