From 755306945feaac013e9432781374f94b80fa38a2 Mon Sep 17 00:00:00 2001 From: cheney <1251790704@qq.com> Date: Fri, 22 Dec 2023 18:52:12 +0800 Subject: [PATCH] =?UTF-8?q?=E7=94=A8=E6=88=B7=E4=B8=8D=E5=AD=98=E5=9C=A8?= =?UTF-8?q?=EF=BC=8C=E8=AF=B7=E5=85=88=E9=87=8D=E6=96=B0=E7=99=BB=E5=BD=95?= =?UTF-8?q?=E6=B3=A8=E5=86=8C=EF=BC=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/huoran/users/entity/res/UserInfoDetailsRes.java | 7 ++++++- .../users/service/impl/HrUserAccountServiceImpl.java | 5 +++++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/users/src/main/java/com/huoran/users/entity/res/UserInfoDetailsRes.java b/users/src/main/java/com/huoran/users/entity/res/UserInfoDetailsRes.java index 02b00ca..c19df85 100644 --- a/users/src/main/java/com/huoran/users/entity/res/UserInfoDetailsRes.java +++ b/users/src/main/java/com/huoran/users/entity/res/UserInfoDetailsRes.java @@ -30,9 +30,14 @@ public class UserInfoDetailsRes implements Serializable { * 用户id */ @ApiModelProperty("用户id") - @TableId(value = "userId", type = IdType.AUTO) private Integer userId; + @ApiModelProperty("无数据状态") + private boolean status; + + @ApiModelProperty("信息") + private String message; + /** * 用户对象 */ diff --git a/users/src/main/java/com/huoran/users/service/impl/HrUserAccountServiceImpl.java b/users/src/main/java/com/huoran/users/service/impl/HrUserAccountServiceImpl.java index 517ddba..b37a933 100644 --- a/users/src/main/java/com/huoran/users/service/impl/HrUserAccountServiceImpl.java +++ b/users/src/main/java/com/huoran/users/service/impl/HrUserAccountServiceImpl.java @@ -417,6 +417,11 @@ public class HrUserAccountServiceImpl extends ServiceImpl userAccountList = hrUserAccountMapper.selectList(new QueryWrapper() .eq("app_open_id", openId)); + if (userAccountList.size() == 0){ + res.setStatus(false); + res.setMessage("用户不存在,请先重新登录注册!"); + return res; + } //查询个人端用户信息 Integer userId = null;