dos пре 1 месец
родитељ
комит
262faaa546

+ 2 - 1
game-business/src/main/java/com/game/business/controller/AppUsersCashrecordController.java

@@ -260,11 +260,12 @@ public class AppUsersCashrecordController extends BaseController
                 tran.setTranGroupId(IdUtil.getSnowflakeNextId());
                 tran.setRemarks("转出失败:回退金额");
                 appUserService.updateUserAmount(tran);
-                appUserCountTask.updateWithdrawAble(appUser.getUserid());
                 //更新状态
                 update.setCashOutStatus(2L);
             }
             appUsersCashrecordService.updateAppUsersCashrecord(update);
+            //更新用户可提现余额
+            appUserCountTask.updateWithdrawAble(appUsersCashrecord.getUid());
 
             return "success";
         }else{

+ 2 - 0
game-business/src/main/java/com/game/business/task/AppUserCountTask.java

@@ -650,6 +650,7 @@ public class AppUserCountTask {
         String chargeType3 = FinTranType3.ON_LINE_CHARGE.getType() + "," + FinTranType3.CHARGE_IN.getType()+ "," + FinTranType3.CHARGE_IN_Back.getType()
                 + "," + FinTranType3.TRANSFER_TO_TEAM_DiamondCoin.getType();
         List<FinTranRecord> chargeList = finTranRecordService.selectUserTran(FinTranType1.U_Income_Coin_Balance.getType(),chargeType3,userId,null,null,1);
+        log.info("用户{},:满足提现充值订单数{} :{}",userId,null!=chargeList?chargeList.size():0);
         if(null != chargeList && chargeList.size() > 0){
             Map<Long, List<FinTranRecord>> chargeMap = chargeList.stream().collect(Collectors.groupingBy(FinTranRecord::getUid));
             for(Long uid : chargeMap.keySet()) {
@@ -685,6 +686,7 @@ public class AppUserCountTask {
                 updateUser.setUserid(uid);
                 updateUser.setWithdrawAble(withdrawAble);
                 appUserService.updateAppUser(updateUser);
+                log.info("用户{},可提现额度{}",userId,withdrawAble);
                 //清除用户缓存
                 redisCache.deleteObject("U:UserInfo:".concat(String.valueOf(uid)));
             }