From 00157a420beba89f8faa0ab597dcef5a7f9615fe Mon Sep 17 00:00:00 2001 From: puriphatt Date: Wed, 13 Nov 2024 16:40:54 +0700 Subject: [PATCH] fix: handle null --- src/components/dialog/DialogProperties.vue | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/components/dialog/DialogProperties.vue b/src/components/dialog/DialogProperties.vue index e6931ca3..cbb471e2 100644 --- a/src/components/dialog/DialogProperties.vue +++ b/src/components/dialog/DialogProperties.vue @@ -283,7 +283,7 @@ watch( if (ret) { currWorkflow.value = ret; tempStep.value = - ret.step.length > 0 + ret.step?.length > 0 ? ret.step.map((s) => ({ name: s.name, attributes: s.attributes, @@ -329,7 +329,7 @@ watch(
0" + v-if="tempStep[stepIndex].attributes?.properties?.length > 0" class="q-py-sm" :class="{ 'q-px-lg': $q.screen.gt.sm, @@ -474,7 +474,7 @@ watch( flat round :size="$q.screen.xs ? 'xs' : ''" - :disable="propIndex === tempStep.length - 1" + :disable="propIndex === tempStep?.length - 1" style="color: hsl(var(--text-mute-2))" @click="moveItemDown(tempStep, propIndex)" />