From b8140ee7442bef60d223918c439ea2991cd2496e Mon Sep 17 00:00:00 2001 From: leafage-collb <3303710797@qq.com> Date: Tue, 19 Mar 2024 17:27:46 +0800 Subject: [PATCH] =?UTF-8?q?bug:=20=E6=8C=81=E4=B9=85=E5=AD=98=E5=82=A8?= =?UTF-8?q?=E7=BC=96=E8=BE=91=E6=97=A0=E6=B3=95=E4=BF=9D=E5=AD=98=EF=BC=8C?= =?UTF-8?q?=E5=AD=97=E5=8F=B7=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../create-persistent-storage-dailog.vue | 4 ++++ .../engine/cloud-deployment/deploy-volume.vue | 16 +++++++++------- 2 files changed, 13 insertions(+), 7 deletions(-) diff --git a/webfe/package_vue/src/components/create-persistent-storage-dailog.vue b/webfe/package_vue/src/components/create-persistent-storage-dailog.vue index b2d9e1248d..0b732c5f01 100644 --- a/webfe/package_vue/src/components/create-persistent-storage-dailog.vue +++ b/webfe/package_vue/src/components/create-persistent-storage-dailog.vue @@ -176,4 +176,8 @@ export default { line-height: 22px; } } +.capacity-tips { + color: #979BA5; + font-size: 12px; +} diff --git a/webfe/package_vue/src/views/dev-center/app/engine/cloud-deployment/deploy-volume.vue b/webfe/package_vue/src/views/dev-center/app/engine/cloud-deployment/deploy-volume.vue index 6728d26493..7b687ada1b 100644 --- a/webfe/package_vue/src/views/dev-center/app/engine/cloud-deployment/deploy-volume.vue +++ b/webfe/package_vue/src/views/dev-center/app/engine/cloud-deployment/deploy-volume.vue @@ -573,7 +573,7 @@ export default { return this.persistentStorageList.filter(v => v.environment_name === this.volumeFormData.environment_name); }, readonly() { - return this.volumeFormData.sourceConfigArrData.length <= 0; + return this.volumeFormData.sourceConfigArrData?.length <= 0; }, }, watch: { @@ -780,7 +780,14 @@ export default { }, handleConfirm() { this.$refs.formRef?.validate().then(() => { - if (!Object.keys(this.volumeFormData.source_config_data)?.length && !this.isPersistentStorage) { + if (!this.isPersistentStorage) { + if (!Object.keys(this.volumeFormData?.source_config_data || {})?.length) { + this.$paasMessage({ + theme: 'error', + message: this.$t('请填写文件名'), + }); + return; + } if (!this.sliderEditordetail) { this.$paasMessage({ theme: 'error', @@ -788,11 +795,6 @@ export default { }); return; } - this.$paasMessage({ - theme: 'error', - message: this.$t('请填写文件名'), - }); - return; } this.handleConfirmVolume(); })