Toggle navigation
Toggle navigation
This project
Loading...
Sign in
developOne
/
harmonyPool
Go to a project
Toggle navigation
Projects
Groups
Snippets
Help
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
陈剑华
2024-05-20 15:23:12 +0800
Browse Files
Options
Browse Files
Download
Plain Diff
Commit
bd7b84cc91d10b6b7fc0b49b2813ad979663f0ef
bd7b84cc
2 parents
5d17d9f3
d0c96eb0
Merge remote-tracking branch 'origin/main'
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
4 deletions
sight_harmony/commons/wdNetwork/src/main/ets/http/HttpBizUtil.ets
sight_harmony/commons/wdNetwork/src/main/ets/http/HttpBizUtil.ets
View file @
bd7b84c
...
...
@@ -93,10 +93,8 @@ export class HttpBizUtil {
*/
static refreshToken(): Promise<string> {
let url = HttpUrlUtils.getRefreshTokenUrl();
let params: HashMap<string, string> = new HashMap<string, string>()
params.set('refreshToken', HttpUtils.getRefreshToken())
params.set('deviceId', HttpUtils.getDeviceId())
// Logger.debug(TAG, 'refreshToken getRefreshToken: ' + HttpUrlUtils.getRefreshToken())
let params: RefreshTokenParam =
new RefreshTokenParam(HttpUtils.getRefreshToken(), HttpUtils.getDeviceId())
// 请求刷新token接口
return new Promise<string>((success, error) => {
WDHttp.post<ResponseDTO<RefreshTokenRes>>(url, params).then((resDTO: ResponseDTO<RefreshTokenRes>) => {
...
...
@@ -124,3 +122,13 @@ export class HttpBizUtil {
})
}
}
export class RefreshTokenParam {
refreshToken: string = ''
deviceId: string = ''
constructor(refreshToken: string, deviceId: string) {
this.refreshToken = refreshToken
this.deviceId = deviceId
}
}
\ No newline at end of file
...
...
Please
register
or
login
to post a comment