|
|
|
@ -106,14 +106,28 @@ function parseStringToArray(str: string) { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
onBeforeMount(() => { |
|
|
|
setTimeout(() => { |
|
|
|
|
|
|
|
function editModeInitValue(){ |
|
|
|
|
|
|
|
if(props.modelValue){ |
|
|
|
const initialValue = parseStringToArray(props.modelValue) |
|
|
|
value.value = initialValue; |
|
|
|
if (initialValue.length > 0 && !multiSelect.value) { |
|
|
|
lastSelectedValue.value = initialValue[initialValue.length - 1]; |
|
|
|
} |
|
|
|
}, 500) |
|
|
|
}else{ |
|
|
|
setTimeout(()=>{ |
|
|
|
editModeInitValue() |
|
|
|
},100) |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
onBeforeMount(() => { |
|
|
|
|
|
|
|
editModeInitValue() |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
// 递归处理树节点,将部门节点设置为禁用 |
|
|
|
|