From f755599fcadda9e84e2fea1a97cd3016b72fdf52 Mon Sep 17 00:00:00 2001 From: hanxueda Date: Mon, 22 Apr 2019 21:03:11 +0800 Subject: [PATCH] =?UTF-8?q?[=E7=A7=AF=E5=88=86][=E4=BF=AE=E6=94=B9]:?= =?UTF-8?q?=E6=80=BB=E7=A7=AF=E5=88=86=E8=8E=B7=E5=8F=96=E8=A7=84=E5=88=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../iformall/service/impl/WxCreditHistoryServiceImpl.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/mallinkService/src/main/java/com/iformall/service/impl/WxCreditHistoryServiceImpl.java b/mallinkService/src/main/java/com/iformall/service/impl/WxCreditHistoryServiceImpl.java index 27509c810..8f21e031b 100644 --- a/mallinkService/src/main/java/com/iformall/service/impl/WxCreditHistoryServiceImpl.java +++ b/mallinkService/src/main/java/com/iformall/service/impl/WxCreditHistoryServiceImpl.java @@ -163,11 +163,11 @@ public class WxCreditHistoryServiceImpl implements WxCreditHistoryService { record.setSpend(new BigDecimal(record.getSpendStr()).multiply(new BigDecimal(100)).intValue()); } int currentCreditAmount = 0; - //获取当前用户总积分规则:优先获取wxCUserBasicInfo中数据 若不存在 再获取wxCUser表中数据 - if (wxCUserBasicInfo != null && wxCUserBasicInfo.getCredit() != null && wxCUserBasicInfo.getCredit() > 0) { - currentCreditAmount = wxCUserBasicInfo.getCredit(); - } else if (wxCUser != null && wxCUser.getCredit() != null && wxCUser.getCredit() > 0) { + //获取当前用户总积分规则:优先获取wxCUser中数据 若不存在 再获取wxCUserBasicInfo表中数据 + if (wxCUser != null && wxCUser.getCredit() != null && wxCUser.getCredit() > 0) { currentCreditAmount = wxCUser.getCredit(); + } else if (wxCUserBasicInfo != null && wxCUserBasicInfo.getCredit() != null && wxCUserBasicInfo.getCredit() > 0) { + currentCreditAmount = wxCUserBasicInfo.getCredit(); } //计算出需要新增或减少的积分