Authored by Lixiaodi

bug修改

@@ -101,6 +101,7 @@ public class MerchantOrderPaymentService extends AbstractOrderPaymentService { @@ -101,6 +101,7 @@ public class MerchantOrderPaymentService extends AbstractOrderPaymentService {
101 101
102 BigDecimal amount = orderInfo.getAmount(); 102 BigDecimal amount = orderInfo.getAmount();
103 BigDecimal beforeAmount = BigDecimal.ZERO; 103 BigDecimal beforeAmount = BigDecimal.ZERO;
  104 + BigDecimal beforeLockAmount = BigDecimal.ZERO;
104 SellerWallet sw = sellerWalletMapper.selectByUidAndType(orderInfo.getUid(), 1); 105 SellerWallet sw = sellerWalletMapper.selectByUidAndType(orderInfo.getUid(), 1);
105 logger.info("充值后回调,处理总账表,orderCode={}", orderInfo.getOrderCode()); 106 logger.info("充值后回调,处理总账表,orderCode={}", orderInfo.getOrderCode());
106 if (orderInfo.getType() == TYPE_FIRST_RECHARGE) { 107 if (orderInfo.getType() == TYPE_FIRST_RECHARGE) {
@@ -134,6 +135,7 @@ public class MerchantOrderPaymentService extends AbstractOrderPaymentService { @@ -134,6 +135,7 @@ public class MerchantOrderPaymentService extends AbstractOrderPaymentService {
134 return; 135 return;
135 } 136 }
136 beforeAmount = sw.getAmount(); 137 beforeAmount = sw.getAmount();
  138 + beforeLockAmount = sw.getLockAmount();
137 sw.setLockAmount(null); 139 sw.setLockAmount(null);
138 sw.setAmount(orderInfo.getAmount()); 140 sw.setAmount(orderInfo.getAmount());
139 sw.setUpdateTime(TimeUtils.getTimeStampSecond()); 141 sw.setUpdateTime(TimeUtils.getTimeStampSecond());
@@ -162,7 +164,7 @@ public class MerchantOrderPaymentService extends AbstractOrderPaymentService { @@ -162,7 +164,7 @@ public class MerchantOrderPaymentService extends AbstractOrderPaymentService {
162 swd.setLockAmount(BigDecimal.ZERO); 164 swd.setLockAmount(BigDecimal.ZERO);
163 } else { 165 } else {
164 swd.setAvailAmount(orderInfo.getAmount().add(beforeAmount)); 166 swd.setAvailAmount(orderInfo.getAmount().add(beforeAmount));
165 - swd.setLockAmount(sw.getLockAmount()); 167 + swd.setLockAmount(beforeLockAmount);
166 } 168 }
167 swd.setIsSet(1); 169 swd.setIsSet(1);
168 MerchantOrderAttachInfo att = new MerchantOrderAttachInfo(); 170 MerchantOrderAttachInfo att = new MerchantOrderAttachInfo();