fix: bug#11826
This commit is contained in:
parent
2b996fadf3
commit
fb32cc9a38
|
@ -256,20 +256,21 @@ const getDetail = () => {
|
|||
}
|
||||
};
|
||||
|
||||
// watch(
|
||||
// () => route.params?.id,
|
||||
// async (newId) => {
|
||||
// if (newId) {
|
||||
// await instanceStore.refresh(String(newId));
|
||||
// getStatus(String(newId));
|
||||
// list.value = [...initList];
|
||||
// console.log('watch', route.params?.id)
|
||||
// getDetail();
|
||||
// instanceStore.tabActiveKey = 'Info';
|
||||
// }
|
||||
// },
|
||||
// { immediate: true, deep: true },
|
||||
// );
|
||||
const initPage = async (newId: any) => {
|
||||
await instanceStore.refresh(String(newId));
|
||||
getStatus(String(newId));
|
||||
list.value = [...initList];
|
||||
console.log('watch', route.params?.id)
|
||||
getDetail();
|
||||
instanceStore.tabActiveKey = 'Info';
|
||||
}
|
||||
|
||||
onBeforeRouteUpdate((to: any) => {
|
||||
if (to.params?.id) {
|
||||
initPage(to.params?.id)
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
const getDetailFn = async () => {
|
||||
const _id = route.params?.id;
|
||||
|
|
Loading…
Reference in New Issue