Commit 4b3f817c authored by hezhen's avatar hezhen

Merge branch 'holiday-price' into dev

parents 7f5a996c 0cb50c73
...@@ -197,8 +197,10 @@ public class AppUserSellingWaterBiz extends BaseBiz<AppUserSellingWaterMapper, A ...@@ -197,8 +197,10 @@ public class AppUserSellingWaterBiz extends BaseBiz<AppUserSellingWaterMapper, A
BigDecimal commission = sellingWater.getCommission(); BigDecimal commission = sellingWater.getCommission();
log.info("订单完成计算用户拥金----finishOrderWater----id====" + id + "---commission==" + commission + "----orderType===" + orderType); log.info("订单完成计算用户拥金----finishOrderWater----id====" + id + "---commission==" + commission + "----orderType===" + orderType);
amount = amount.add(commission); amount = amount.add(commission);
} }
log.info("订单完成计算用户拥金----finishOrderWater----orderId====" + orderId + "---amount==" + amount); BigDecimal unbooked=amount;
log.info("订单完成计算用户拥金----finishOrderWater----orderId====" + orderId + "---amount==" + amount+"---unbooked=="+unbooked);
if(orderType==1){ if(orderType==1){
List<OrderGoodsDTO> goodsDTOList =orderWaterDTO.getGoodsDTOList(); List<OrderGoodsDTO> goodsDTOList =orderWaterDTO.getGoodsDTOList();
log.info("租车订单完成-----goodsDTOList==="+goodsDTOList); log.info("租车订单完成-----goodsDTOList==="+goodsDTOList);
...@@ -247,7 +249,7 @@ public class AppUserSellingWaterBiz extends BaseBiz<AppUserSellingWaterMapper, A ...@@ -247,7 +249,7 @@ public class AppUserSellingWaterBiz extends BaseBiz<AppUserSellingWaterMapper, A
detail.setSource(1); detail.setSource(1);
myWaterBiz.updMyWater(detail); myWaterBiz.updMyWater(detail);
if (orderType == 1 || orderType == 2) { if (orderType == 1 || orderType == 2) {
myWaterBiz.updMyWalletUnbooked(userId, amount, 2); myWaterBiz.updMyWalletUnbooked(userId, unbooked, 2);
} }
} }
......
...@@ -308,4 +308,17 @@ public class BaseOrder implements Serializable { ...@@ -308,4 +308,17 @@ public class BaseOrder implements Serializable {
@Column(name = "remark") @Column(name = "remark")
private Integer remark; private Integer remark;
/**
* 备注
*/
@ApiModelProperty(value = "上级id")
@Column(name = "parent_user_id")
private Integer parentUserId;
/**
* 备注
*/
@ApiModelProperty(value = "备注")
@Column(name = "parent_user_company_id")
private Integer parentUserCompanyId;
} }
...@@ -33,12 +33,6 @@ public interface OrderDetail extends OrderItemInter { ...@@ -33,12 +33,6 @@ public interface OrderDetail extends OrderItemInter {
public void setAppUserDTO(AppUserDTO appUserDTO); public void setAppUserDTO(AppUserDTO appUserDTO);
// public Integer getFacilitateId();
//
// public void setFacilitateId(Integer facilitateId);
public String getFacilitatePhone(); public String getFacilitatePhone();
public void setFacilitatePhone(String facilitatePhone);
} }
...@@ -105,17 +105,14 @@ public class VehicleItemDTO extends OrderItem { ...@@ -105,17 +105,14 @@ public class VehicleItemDTO extends OrderItem {
public BigDecimal getUsedAmount(Integer useDays) { public BigDecimal getUsedAmount(Integer useDays) {
List<VMCalendarPriceCostDTO> vmcpds = getVehicleDetail(); List<VMCalendarPriceCostDTO> vmcpds = getVehicleDetail();
if(CollUtil.isEmpty(vmcpds)){
if(useDays > getTotalNum()) { if(useDays > getTotalNum()) {
useDays = getTotalNum(); useDays = getTotalNum();
} }
if(CollUtil.isEmpty(vmcpds)){
return getUnitPrice().multiply(new BigDecimal(useDays+ "")); return getUnitPrice().multiply(new BigDecimal(useDays+ ""));
} }
BigDecimal usedAmount = BigDecimal.ZERO; BigDecimal usedAmount = BigDecimal.ZERO;
// for(VMCalendarPriceCostDTO vmcpcd : vmcpds) {
// usedAmount.add(vmcpcd.getPrice());
// }
for(int i = 0; i < useDays; i++) { for(int i = 0; i < useDays; i++) {
usedAmount = usedAmount.add(vmcpds.get(i).getPrice()); usedAmount = usedAmount.add(vmcpds.get(i).getPrice());
} }
......
...@@ -99,6 +99,9 @@ public abstract class AbstractOrderHandle<Biz extends BaseBiz, Detail extends Or ...@@ -99,6 +99,9 @@ public abstract class AbstractOrderHandle<Biz extends BaseBiz, Detail extends Or
baseOrder.setUserId(appUserDTO.getUserid()); baseOrder.setUserId(appUserDTO.getUserid());
baseOrder.setMemberLevel(appUserDTO.getMemberLevel()); baseOrder.setMemberLevel(appUserDTO.getMemberLevel());
//设置上级
baseOrder.setParentUserId(appUserDTO.getParentId());
return baseOrder; return baseOrder;
} }
......
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