[update] 修改bug87432,去掉企标详情页跳转的判断
This commit is contained in:
+2
-19
@@ -114,25 +114,8 @@ router.beforeEach(async (to, from, next) => {
|
|||||||
// hack方法 确保addRoutes已完成 ,set the replace: true so the navigation will not leave a history record
|
// hack方法 确保addRoutes已完成 ,set the replace: true so the navigation will not leave a history record
|
||||||
next({ ...to, replace: true })
|
next({ ...to, replace: true })
|
||||||
} else {
|
} else {
|
||||||
if (to.path === '/enterpriseStandardLibrary/enterpriseStandardDetail') {
|
// 跳转到目的路由
|
||||||
// 跳企标详情,需要判断是否能看详情
|
next({ path: redirect })
|
||||||
const params = {}
|
|
||||||
if (to.query.id) {
|
|
||||||
params.id = to.query.id
|
|
||||||
} else if (to.query.standardNumber) {
|
|
||||||
params.standardNumber = to.query.standardNumber
|
|
||||||
}
|
|
||||||
isCanLookDetail(params).then(res => {
|
|
||||||
if (res.success && res.result) {
|
|
||||||
next({ path: redirect })
|
|
||||||
} else {
|
|
||||||
next({ path: '/404' })
|
|
||||||
}
|
|
||||||
})
|
|
||||||
} else {
|
|
||||||
// 跳转到目的路由
|
|
||||||
next({ path: redirect })
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user