修复对话生成没有更新树

This commit is contained in:
X1627315083@163.com
2026-03-02 13:40:17 +08:00
parent 1d318f4094
commit 4857376736
4 changed files with 10 additions and 22 deletions

View File

@@ -29,7 +29,7 @@ const projectStore = useProjectStore()
let oldProjectId:any = ''
watch(()=>props.versionTreeData?.drawer, (newVal, oldVal) => {
console.log(newVal,oldProjectId,projectStore.state.id)
if(newVal && oldProjectId !== projectStore.state.id && projectStore.state.id){
if(newVal || (oldProjectId !== projectStore.state.id && projectStore.state.id)){
getVersionTree()
oldProjectId = JSON.parse(JSON.stringify(projectStore.state.id))
}
@@ -41,6 +41,7 @@ const getVersionTree = ()=>{
}).then(res => {
if(!res)return
setVersionsList([res])
treeKey.value++
})
}