Skip to content

菜单-外部链接-非https不正常(会拼接当前域名)? #1037

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
hsj-xiaokang opened this issue Nov 20, 2020 · 2 comments
Closed

Comments

@hsj-xiaokang
Copy link

hsj-xiaokang commented Nov 20, 2020

版本:
"@ant-design-vue/pro-layout": "^0.3.4",
"ant-design-vue": "^1.6.5"

部分代码:
// 路由菜单,path外部链接http
......
{
path: 'http://192.168.1.105:8080/swagger-ui.html',
name: 'Monitor',
meta: { title: 'menu.dashboard.monitor', target: '_blank' }
},
......

路由hash模式

开发某个界面:http://192.168.1.105:8009/#xxx
菜单查看html部分: href="http://192.168.1.105:8080/swagger-ui.html" target="_blank"
实际鼠标浮在上面可以看到href地址是:http://192.168.1.105:8009/http://192.168.1.105:8080/swagger-ui.html
实际跳转地址:http://192.168.1.105:8009/http://192.168.1.105:8080/swagger-ui.html

如果改成https则正常,开发时候谁搞成https?:
......
{
path: 'https://192.168.1.105:8080/swagger-ui.html',
name: 'Monitor',
meta: { title: 'menu.dashboard.monitor', target: '_blank' }
},
......

@sendya
Copy link
Member

sendya commented Nov 20, 2020

请使用 history 模式

@sendya
Copy link
Member

sendya commented Nov 26, 2020

@sendya sendya closed this as completed Nov 26, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants