refactor(ProjectManage): 修改创建项目中的链接打开方式
- 替换原有的在新窗口打开链接的方式,改为在当前窗口中打开- 解析 URL 中的 sn 参数,通过路由跳转到 survey/planet/design 页面 - 注释掉原有的 window.open 代码,阻止在 iframe 中打开新窗口
This commit is contained in:
@@ -673,10 +673,13 @@ function onIframeLoad() {
|
|||||||
// return null
|
// return null
|
||||||
|
|
||||||
// 示例:用主窗口打开链接
|
// 示例:用主窗口打开链接
|
||||||
// router.push({
|
router.push({
|
||||||
// path:url
|
path:'/survey/planet/design',
|
||||||
// })
|
query:{
|
||||||
window.open(url, '_blank')
|
sn: url.split('sn=')[1]
|
||||||
|
}
|
||||||
|
})
|
||||||
|
// window.open(url, '_blank')
|
||||||
return null // 阻止 iframe 的 window.open
|
return null // 阻止 iframe 的 window.open
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user