记得上下班打卡 | git大法好,push需谨慎

Commit 37bb6953 authored by GaoHu's avatar GaoHu

exit

parent 446fa0de
......@@ -36,6 +36,9 @@ public class GoblinGoodsAnticipateServiceImpl implements IGoblinGoodsAnticipateS
@Autowired
QueueUtils queueUtils;
@Autowired
GoblinAnticipateUtils goblinAnticipateUtils;
@Override
public ResponseDto<Object> userAbout(String skuId) {
//查询该skuId是否能被预约
......@@ -45,7 +48,6 @@ public class GoblinGoodsAnticipateServiceImpl implements IGoblinGoodsAnticipateS
if (!anticipateValueVo.getState().equals(1)) {
return ResponseDto.failure("该商品预约尚未开始或已经结束,不可预约!");
}
GoblinAnticipateUtils goblinAnticipateUtils = new GoblinAnticipateUtils();
AdamUserInfoVo userInfo = goblinAnticipateUtils.getUserInfo();
if (userInfo==null){
return ResponseDto.failure("登陆信息有误");
......
......@@ -31,16 +31,16 @@ public class GoblinAnticipateUtils {
header.add("Authorization", "Bearer " + CurrentUtil.getToken());
header.add("Accept", "application/json;charset=UTF-8");
String returnData = HttpUtil.post(adamUrl+"/adam/user/info",null, header);
String returnData = HttpUtil.post(adamUrl + "/adam/user/info", null, header);
ResponseDto<AdamUserProfileVo> innerReturnVo = JsonUtils.fromJson(returnData, new TypeReference<ResponseDto<AdamUserProfileVo>>() {
});
if (innerReturnVo.getData()!=null){
if (innerReturnVo.getData() != null) {
return innerReturnVo.getData().getUserInfo();
}
log.info("post url:{}<----->Authorization:{}",adamUrl+" /adam/user/info",CurrentUtil.getToken());
log.info("post url:{}<----->Authorization:{}", adamUrl + " /adam/user/info", CurrentUtil.getToken());
return null;
} catch (Exception e) {
log.info("post url:{}<----->Authorization:{}",adamUrl+" /adam/user/info",CurrentUtil.getToken());
log.info("post url:{}<----->Authorization:{}", adamUrl + " /adam/user/info", CurrentUtil.getToken());
log.error("获取用户头像失败", e);
return null;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment