From f2a36b0b93939c9d7a14585e0afae80ec70402a0 Mon Sep 17 00:00:00 2001 From: admin <weikou2014> Date: 星期一, 12 八月 2019 16:11:10 +0800 Subject: [PATCH] 商品更新缓存机制完善 --- fanli/src/main/java/com/yeshi/fanli/service/impl/order/OrderProcessServiceImpl.java | 11 +++++++++++ 1 files changed, 11 insertions(+), 0 deletions(-) diff --git a/fanli/src/main/java/com/yeshi/fanli/service/impl/order/OrderProcessServiceImpl.java b/fanli/src/main/java/com/yeshi/fanli/service/impl/order/OrderProcessServiceImpl.java index a8c6ff9..d94c651 100644 --- a/fanli/src/main/java/com/yeshi/fanli/service/impl/order/OrderProcessServiceImpl.java +++ b/fanli/src/main/java/com/yeshi/fanli/service/impl/order/OrderProcessServiceImpl.java @@ -292,6 +292,11 @@ public void fanli(HongBaoV2 hb1) throws TaoBaoWeiQuanException { // 鏌ヨ鏈�鏂扮殑绾㈠寘鏁版嵁 hb1 = hongBaoV2Mapper.selectByPrimaryKeyForUpdate(hb1.getId()); + // 姝e父鐢ㄦ埛鎵嶈兘鍒拌处 + UserInfo mainUser = userInfoMapper.selectByPrimaryKey(hb1.getUserInfo().getId()); + if (mainUser == null || mainUser.getState() != UserInfo.STATE_NORMAL) { + return; + } // 鏌ヨ绾㈠寘鐩稿叧鑱旂殑璁㈠崟 HongBaoOrder hongBaoOrder = hongBaoOrderMapper.selectByHongBaoId(hb1.getId()); if (hongBaoOrder == null) { @@ -576,6 +581,12 @@ || co.getSourceType() == Constant.SOURCE_TYPE_PDD) { hongBaoList.remove(i); i--; + } else {// 涓婄骇鐢ㄦ埛涓嶆槸姝e父鐢ㄦ埛锛岃鍗曞潎涓嶈兘鍒拌处 + UserInfo userInfo = userInfoMapper.selectByPrimaryKey(item.getUserInfo().getId()); + if (userInfo == null || userInfo.getState() != UserInfo.STATE_NORMAL) { + hongBaoList.remove(i); + i--; + } } } } -- Gitblit v1.8.0