From 8b7fc3718d7cf847858e26db6a1b3421710ce1f8 Mon Sep 17 00:00:00 2001 From: admin <weikou2014> Date: 星期一, 16 九月 2019 15:52:28 +0800 Subject: [PATCH] UserInfo DAO层修改 --- fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserAccountServiceImpl.java | 20 ++++++++++---------- 1 files changed, 10 insertions(+), 10 deletions(-) diff --git a/fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserAccountServiceImpl.java b/fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserAccountServiceImpl.java index a46a971..d2cfb2b 100644 --- a/fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserAccountServiceImpl.java +++ b/fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserAccountServiceImpl.java @@ -734,7 +734,7 @@ @Override public void bindPhone(Long uid, String phone) throws UserAccountException { - UserInfo user = userInfoMapper.selectByPrimaryKey(uid); + UserInfo user = userInfoMapper.selectAvailableByPrimaryKey(uid); if (user == null) throw new UserAccountException(4, "鐢ㄦ埛涓嶅瓨鍦�"); @@ -755,7 +755,7 @@ @Override public void unBindPhone(Long uid, String phone) throws UserAccountException { - UserInfo user = userInfoMapper.selectByPrimaryKey(uid); + UserInfo user = userInfoMapper.selectAvailableByPrimaryKey(uid); if (user == null) throw new UserAccountException(4, "鐢ㄦ埛涓嶅瓨鍦�"); @@ -777,7 +777,7 @@ @Override public void bindTaoBao(Long uid, String tbOpenId, String tbNickName, String tbPortrait) throws UserAccountException { - UserInfo user = userInfoMapper.selectByPrimaryKey(uid); + UserInfo user = userInfoMapper.selectAvailableByPrimaryKey(uid); if (user == null) throw new UserAccountException(4, "鐢ㄦ埛涓嶅瓨鍦�"); @@ -807,7 +807,7 @@ @Override public void unBindTaoBao(Long uid) throws UserAccountException { - UserInfo user = userInfoMapper.selectByPrimaryKey(uid); + UserInfo user = userInfoMapper.selectAvailableByPrimaryKey(uid); if (user == null) throw new UserAccountException(4, "鐢ㄦ埛涓嶅瓨鍦�"); if (StringUtil.isNullOrEmpty(user.getOpenid())) @@ -835,7 +835,7 @@ @Override public void changeWXBind(AcceptData acceptData, Long uid, String code) throws UserAccountException { - UserInfo user = userInfoMapper.selectByPrimaryKey(uid); + UserInfo user = userInfoMapper.selectAvailableByPrimaryKey(uid); if (user == null) throw new UserAccountException(4, "鐢ㄦ埛涓嶅瓨鍦�"); WXAccountInfoDTO wxAccount = Constant.getWXAccount(acceptData.getPlatform(), acceptData.getVersion()); @@ -886,7 +886,7 @@ TimeUtil.getGernalTime(System.currentTimeMillis(), "yyyyMMddHHmmss")); // 澶囦唤鐢ㄦ埛淇℃伅 - UserInfo user = userInfoMapper.selectByPrimaryKey(uid); + UserInfo user = userInfoMapper.selectAvailableByPrimaryKey(uid); // TODO 澶囦唤璧勯噾鏄庣粏 @@ -923,7 +923,7 @@ public void clearUserPortrait(Long uid) { if (uid == null) return; - UserInfo user = userInfoMapper.selectByPrimaryKey(uid); + UserInfo user = userInfoMapper.selectAvailableByPrimaryKey(uid); String prefix = String.format("/portrait/wx/%s_", user.getWxUnionId()); ObjectListing list = COSManager.getInstance().getObjectList(prefix, null, 30); if (list != null && list.getObjectSummaries() != null) @@ -938,7 +938,7 @@ public String repairPortrait(Long uid) { if (uid == null) return null; - UserInfo user = userInfoMapper.selectByPrimaryKey(uid); + UserInfo user = userInfoMapper.selectAvailableByPrimaryKey(uid); if (user == null) return null; String prefix = String.format("/portrait/wx/%s_", user.getWxUnionId()); @@ -1173,7 +1173,7 @@ @Override public void bindPhoneNew(Long uid, String phone) throws UserAccountException { - UserInfo user = userInfoMapper.selectByPrimaryKey(uid); + UserInfo user = userInfoMapper.selectAvailableByPrimaryKey(uid); if (user == null) { throw new UserAccountException(1, "鐢ㄦ埛涓嶅瓨鍦�"); } @@ -1214,7 +1214,7 @@ @Override public void bindWeiXin(AcceptData acceptData, Long uid, String code) throws UserAccountException { - UserInfo user = userInfoMapper.selectByPrimaryKey(uid); + UserInfo user = userInfoMapper.selectAvailableByPrimaryKey(uid); if (user == null) { throw new UserAccountException(1, "鐢ㄦ埛涓嶅瓨鍦�"); } -- Gitblit v1.8.0