feat:用户token更新
This commit is contained in:
@@ -30,6 +30,6 @@ public interface IJntyzxHttpService {
|
||||
* @param openId openid
|
||||
* @return
|
||||
*/
|
||||
JntyzxResponse<Void> healthDeclaration(String token, String openId);
|
||||
JntyzxResponse healthDeclaration(String token, String openId);
|
||||
|
||||
}
|
||||
|
||||
@@ -142,7 +142,7 @@ public class JntyzxHttpServiceImpl implements IJntyzxHttpService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public JntyzxResponse<Void> healthDeclaration(String token, String openId) {
|
||||
public JntyzxResponse healthDeclaration(String token, String openId) {
|
||||
Map<String, String> headers = Maps.newHashMap();
|
||||
headers.put("X-Access-Token", token);
|
||||
Map<String, String> params = Maps.newHashMap();
|
||||
@@ -152,8 +152,7 @@ public class JntyzxHttpServiceImpl implements IJntyzxHttpService {
|
||||
if (StringUtils.isBlank(respStr)) {
|
||||
return null;
|
||||
}
|
||||
JntyzxResponse jntyzxResponse = JSON.parseObject(respStr, JntyzxResponse.class);
|
||||
return jntyzxResponse;
|
||||
return JSON.parseObject(respStr, JntyzxResponse.class);
|
||||
}
|
||||
|
||||
private static JSONObject buildParamJsonObj() {
|
||||
|
||||
@@ -49,7 +49,7 @@ public class UserTokenInfoServiceImpl implements IUserTokenInfoService {
|
||||
}
|
||||
|
||||
private boolean healthDeclaration(UserTokenInfoDO userTokenInfoDO) {
|
||||
JntyzxResponse<Void> jntyzxResponse = jntyzxHttpService.healthDeclaration(userTokenInfoDO.getToken(), userTokenInfoDO.getOpenId());
|
||||
JntyzxResponse jntyzxResponse = jntyzxHttpService.healthDeclaration(userTokenInfoDO.getToken(), userTokenInfoDO.getOpenId());
|
||||
if (Objects.isNull(jntyzxResponse)) {
|
||||
log.info("用户名:{}心跳监测失败!", userTokenInfoDO.getName());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user