fix: 更新文件URL生成逻辑并调整白名单路由
修改文件URL生成逻辑,移除自动添加斜杠的代码并更新基础URL 同时将大屏相关路由添加到白名单中
This commit is contained in:
@@ -8,11 +8,11 @@ function getFileUrl(url){
|
|||||||
return url
|
return url
|
||||||
}
|
}
|
||||||
// 如果没有以/开头的加上/
|
// 如果没有以/开头的加上/
|
||||||
if (!/^\//.test(url)) {
|
// if (!/^\//.test(url)) {
|
||||||
url = `/${url}`
|
// url = `/${url}`
|
||||||
}
|
// }
|
||||||
// return `${window.BS_CONFIG?.httpConfigs?.fileUrlPrefix}${url}`
|
// return `${window.BS_CONFIG?.httpConfigs?.fileUrlPrefix}${url}`
|
||||||
return `${process.env.VUE_APP_BASE_API}/static${url}`
|
return `http://49.232.154.205:10900${url}`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -9,10 +9,10 @@ NProgress.configure({ showSpinner: false })
|
|||||||
|
|
||||||
const whiteList = ['/login', '/register'
|
const whiteList = ['/login', '/register'
|
||||||
,'/public/page'
|
,'/public/page'
|
||||||
// ,"/bigscreen/preview"
|
,"/bigscreen/preview"
|
||||||
// ,"/bigScreen/chart/data/list"
|
,"/bigScreen/chart/data/list"
|
||||||
// ,"/bigScreen/design/info/code/**"
|
,"/bigScreen/design/info/code/**"
|
||||||
// ,"/bigScreen/permission/check/**"
|
,"/bigScreen/permission/check/**"
|
||||||
]
|
]
|
||||||
|
|
||||||
router.beforeEach((to, from, next) => {
|
router.beforeEach((to, from, next) => {
|
||||||
|
|||||||
Reference in New Issue
Block a user