Commit 6ec5877f authored by hezhen's avatar hezhen

123

parent 4843f402
...@@ -104,13 +104,15 @@ public class AppUserSellingWaterBiz extends BaseBiz<AppUserSellingWaterMapper, A ...@@ -104,13 +104,15 @@ public class AppUserSellingWaterBiz extends BaseBiz<AppUserSellingWaterMapper, A
Integer parentId = relation.getParentId(); Integer parentId = relation.getParentId();
log.info("购买计算用户拥金----payOrderWater--------userId===" + userId + "---parentId===" + parentId); log.info("购买计算用户拥金----payOrderWater--------userId===" + userId + "---parentId===" + parentId);
BigDecimal amount = new BigDecimal("0.00"); BigDecimal amount = new BigDecimal("0.00");
//商品类型
Integer orderType=0;
for (OrderGoodsDTO goodsDto : goodsDTOList) { for (OrderGoodsDTO goodsDto : goodsDTOList) {
//商品id //商品id
Integer goodId = goodsDto.getGoodId(); Integer goodId = goodsDto.getGoodId();
//商品价格 //商品价格
BigDecimal price = goodsDto.getPrice(); BigDecimal price = goodsDto.getPrice();
//商品类型
Integer orderType = goodsDto.getType(); orderType = goodsDto.getType();
//商品比例 //商品比例
Integer extract = commissionBiz.getExtract(orderType, goodId); Integer extract = commissionBiz.getExtract(orderType, goodId);
AppUserVo userVo = detailBiz.getUserInfoById(parentId); AppUserVo userVo = detailBiz.getUserInfoById(parentId);
...@@ -149,15 +151,14 @@ public class AppUserSellingWaterBiz extends BaseBiz<AppUserSellingWaterMapper, A ...@@ -149,15 +151,14 @@ public class AppUserSellingWaterBiz extends BaseBiz<AppUserSellingWaterMapper, A
insertSelective(sellingWater); insertSelective(sellingWater);
log.info("购买计算用户拥成功----payOrderWater--------userId===" + userId); log.info("购买计算用户拥成功----payOrderWater--------userId===" + userId);
amount = amount.add(commission); amount = amount.add(commission);
}
log.info("购买计算用户未入账----payOrderWater--------userId===" + userId+"----amount===="+amount+"--orderType==="+orderType);
if(orderType==3){
finishOrderWater(orderWaterDTO);
}else if(orderType==1||orderType==2){
myWaterBiz.updMyWalletUnbooked(userId,amount,1);
} }
} }
log.info("购买计算用户未入账----payOrderWater--------userId===" + parentId+"----amount===="+amount+"--orderType==="+orderType);
if(orderType==3){
finishOrderWater(orderWaterDTO);
}else if(orderType==1||orderType==2){
myWaterBiz.updMyWalletUnbooked(parentId,amount,1);
}
} }
//订单完成计算用户拥金 //订单完成计算用户拥金
......
...@@ -113,6 +113,7 @@ public class MyWaterBiz extends BaseBiz<MyWalletMapper, MyWallet>{ ...@@ -113,6 +113,7 @@ public class MyWaterBiz extends BaseBiz<MyWalletMapper, MyWallet>{
//钱包未入账的处理type1-进;2-出 //钱包未入账的处理type1-进;2-出
public void updMyWalletUnbooked(Integer userId,BigDecimal amount,Integer type){ public void updMyWalletUnbooked(Integer userId,BigDecimal amount,Integer type){
log.info("---钱包未入账的处理----userId==="+userId+"----type==="+type);
MyWallet wallet=new MyWallet(); MyWallet wallet=new MyWallet();
wallet.setUserId(userId); wallet.setUserId(userId);
wallet=selectOne(wallet); wallet=selectOne(wallet);
......
...@@ -89,7 +89,7 @@ public class WaterMQHandler { ...@@ -89,7 +89,7 @@ public class WaterMQHandler {
setImg(orderMQDTO.getPicture()); setImg(orderMQDTO.getPicture());
setPrice(orderMQDTO.getGoodsAmount()); setPrice(orderMQDTO.getGoodsAmount());
setTitle(orderMQDTO.getName()); setTitle(orderMQDTO.getName());
setType(OrderGoodsDTO.TYPE_RENT); setType(OrderGoodsDTO.TYPE_TOUR);
}}); }});
}} }}
); );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment