Open liangqilang opened 2 years ago
Search before asking
- [x] I searched the issues and found no similar issues.
DSS Component
dss-web/framework
What happened + What you expected to happen
后端接口返回了
{ "data": { "enableSSO": true, "SSOURL": "http://****/user/login?token=datastar&callback=http%3A%2F%2F192.168.1.64%3A8088%2Fapi%2Frest_j%2Fv1%2Fuser%2FcallBack" } }
前端不会自动跳转到SSO 登录页,目前是定向到了DSS 登录页。
Relevent platform
branch dev-1.0.1
Reproduction script
wds.linkis.gateway.conf.enable.sso=true wds.linkis.gateway.conf.sso.interceptor=****
Anything else
No response
Are you willing to submit a PR?
- [x] Yes I am willing to submit a PR!
const api = {
instance: instance,
error: {
'-1': function(res) {
console.log(res.data.data);
if (res.data.data && res.data.data.enableSSO && res.data.data.SSOURL) {
localStorage.setItem("enableSSO", res.data.data.enableSSO);
localStorage.setItem("SSOURL", res.data.data.SSOURL);
return window.location.replace(res.data.data.SSOURL);
}
router.push('/login');
throw new Error('您尚未登录,请先登录!');
},
},
constructionOfResponse: {
codePath: 'status',
successCode: '0',
messagePath: 'message',
resultPath: 'data',
},
};
if (res.data.data && res.data.data.enableSSO && res.data.data.SSOURL) {
Search before asking
DSS Component
dss-web/framework
What happened + What you expected to happen
后端接口返回了
{ "data": { "enableSSO": true, "SSOURL": "http://****/user/login?token=datastar&callback=http%3A%2F%2F192.168.1.64%3A8088%2Fapi%2Frest_j%2Fv1%2Fuser%2FcallBack" } }
前端不会自动跳转到SSO 登录页,目前是定向到了DSS 登录页。
Relevent platform
branch dev-1.0.1
Reproduction script
wds.linkis.gateway.conf.enable.sso=true wds.linkis.gateway.conf.sso.interceptor=****
Anything else
No response
Are you willing to submit a PR?