From 09e56c4d0cb67a3a4c8920f8bef455df440c5ebd Mon Sep 17 00:00:00 2001 From: wangshuaiswim Date: Fri, 31 Mar 2023 17:56:26 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E5=B8=83=E5=B0=94?= =?UTF-8?q?=E7=B1=BB=E5=9E=8B=E5=80=BC=E7=B1=BB=E5=9E=8B=E6=98=AF=E5=B8=83?= =?UTF-8?q?=E5=B0=94=E7=9A=84=E6=83=85=E5=86=B5=E4=B8=8B=E4=B8=8D=E8=83=BD?= =?UTF-8?q?=E7=BC=96=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/Metadata/BooleanParam/index.vue | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/components/Metadata/BooleanParam/index.vue b/src/components/Metadata/BooleanParam/index.vue index e1a08a94..aab4aa55 100644 --- a/src/components/Metadata/BooleanParam/index.vue +++ b/src/components/Metadata/BooleanParam/index.vue @@ -47,8 +47,7 @@ const emit = defineEmits() const props = defineProps({ value: { type: Object as PropType, - default: () => ({ - }) + default: () => ({}) }, name: { type: Array as PropType<(string| number)[]>, @@ -67,6 +66,15 @@ onMounted(() => { }) }) +watchEffect(() => { + if (typeof props.value.trueValue === 'boolean') { + props.value.trueValue = String(props.value.trueValue) + } + if (typeof props.value.falseValue === 'boolean') { + props.value.falseValue = String(props.value.falseValue) + } +}) +