Merge branch 'develop' of http://117.78.60.236:8000/csbr-daop/fe-data-asset-management into develop
Showing
2 changed files
with
4 additions
and
4 deletions
| ... | @@ -101,9 +101,9 @@ const useUserStore = defineStore( | ... | @@ -101,9 +101,9 @@ const useUserStore = defineStore( |
| 101 | }).then((resInfo: any) => { | 101 | }).then((resInfo: any) => { |
| 102 | getTokenPromise.value = null; | 102 | getTokenPromise.value = null; |
| 103 | if (resInfo.code == '00000'){ | 103 | if (resInfo.code == '00000'){ |
| 104 | localStorage.setItem('token',resInfo.data.access_token); | 104 | localStorage.setItem('token',resInfo.data.accessToken); |
| 105 | token.value = resInfo.data.access_token; | 105 | token.value = resInfo.data.accessToken; |
| 106 | localStorage.setItem('refresh_token',resInfo.data.refresh_token); | 106 | localStorage.setItem('refresh_token',resInfo.data.refreshToken); |
| 107 | const expiresIn = (Date.now() + 1700000) + ""; | 107 | const expiresIn = (Date.now() + 1700000) + ""; |
| 108 | localStorage.setItem('expiresIn', expiresIn); | 108 | localStorage.setItem('expiresIn', expiresIn); |
| 109 | } else { | 109 | } else { | ... | ... |
| ... | @@ -112,7 +112,7 @@ service.interceptors.request.use( | ... | @@ -112,7 +112,7 @@ service.interceptors.request.use( |
| 112 | return config; | 112 | return config; |
| 113 | }; | 113 | }; |
| 114 | /** 若是刷新token的请求,则不需要等refreshToken完成。 */ | 114 | /** 若是刷新token的请求,则不需要等refreshToken完成。 */ |
| 115 | if (config.url.includes('/csbr-zuul/user/refreshToken')) { | 115 | if (config.url.includes('/user/refreshToken')) { |
| 116 | return process(); | 116 | return process(); |
| 117 | } | 117 | } |
| 118 | let expiresIn = localStorage.getItem('expiresIn'); | 118 | let expiresIn = localStorage.getItem('expiresIn'); | ... | ... |
-
Please register or sign in to post a comment