feat: 修改设计流程切换到第三步自动赋值流程标识与流程名称逻辑

This commit is contained in:
GoldenZqqqq
2024-12-14 00:21:43 +08:00
parent 9459a7296f
commit 21c28c3665
5 changed files with 245 additions and 73 deletions

View File

@ -5,6 +5,7 @@
:model-key="modelKey"
:model-name="modelName"
@success="handleSuccess"
ref="designerRef"
/>
</ContentWrap>
</template>
@ -15,13 +16,21 @@ defineOptions({
name: 'SimpleModelDesign'
})
defineProps<{
const props = defineProps<{
modelId?: string
modelKey?: string
modelName?: string
}>()
const emit = defineEmits(['success'])
const designerRef = ref()
// 监听属性变化
watch([() => props.modelKey, () => props.modelName], ([newKey, newName]) => {
if (designerRef.value && newKey && newName) {
designerRef.value.updateModel(newKey, newName)
}
}, { immediate: true, deep: true })
// 修改成功回调
const handleSuccess = (data?: any) => {