0513新功能优化
This commit is contained in:
@@ -504,12 +504,19 @@ const handleDelete = async (id: number) => {
|
||||
} catch {}
|
||||
}
|
||||
|
||||
let activatedOnce = false
|
||||
|
||||
onMounted(async () => {
|
||||
await loadOfficeOptions()
|
||||
await getList()
|
||||
})
|
||||
|
||||
onActivated(() => {
|
||||
// KeepAlive 首次挂载也会触发 onActivated,跳过首轮避免重复请求列表。
|
||||
if (!activatedOnce) {
|
||||
activatedOnce = true
|
||||
return
|
||||
}
|
||||
getList()
|
||||
})
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user