|
@@ -255,6 +255,7 @@ public class BizAppointmentRecordServiceImpl extends ServiceImpl<BizAppointmentR
|
|
}
|
|
}
|
|
}
|
|
}
|
|
if(ObjectUtil.isNotEmpty(bizAppointmentRecordAddParam.getOrderId())){
|
|
if(ObjectUtil.isNotEmpty(bizAppointmentRecordAddParam.getOrderId())){
|
|
|
|
+ bizAppointmentRecordAddParam.setTimeId(bizOrderService.queryEntity(bizAppointmentRecordAddParam.getOrderId()).getDeliveryTimeId());
|
|
//查询预约时间段内可预约次数
|
|
//查询预约时间段内可预约次数
|
|
//BizAppointmentTime bizAppointmentTime = bizAppointmentTimeService.getById(bizAppointmentRecordAddParam.getTimeId());
|
|
//BizAppointmentTime bizAppointmentTime = bizAppointmentTimeService.getById(bizAppointmentRecordAddParam.getTimeId());
|
|
BizOrderConfig bizOrderConfig = bizOrderConfigService.getOne(new QueryWrapper<BizOrderConfig>().lambda().
|
|
BizOrderConfig bizOrderConfig = bizOrderConfigService.getOne(new QueryWrapper<BizOrderConfig>().lambda().
|
|
@@ -314,6 +315,7 @@ public class BizAppointmentRecordServiceImpl extends ServiceImpl<BizAppointmentR
|
|
}
|
|
}
|
|
}
|
|
}
|
|
if(ObjectUtil.isNotEmpty(bizAppointmentRecordEditParam.getOrderId())){
|
|
if(ObjectUtil.isNotEmpty(bizAppointmentRecordEditParam.getOrderId())){
|
|
|
|
+ bizAppointmentRecordEditParam.setTimeId(bizOrderService.queryEntity(bizAppointmentRecordEditParam.getOrderId()).getDeliveryTimeId());
|
|
//查询预约时间段内可预约次数
|
|
//查询预约时间段内可预约次数
|
|
//BizAppointmentTime bizAppointmentTime = bizAppointmentTimeService.getById(bizAppointmentRecordAddParam.getTimeId());
|
|
//BizAppointmentTime bizAppointmentTime = bizAppointmentTimeService.getById(bizAppointmentRecordAddParam.getTimeId());
|
|
BizOrderConfig bizOrderConfig = bizOrderConfigService.getOne(new QueryWrapper<BizOrderConfig>().lambda().
|
|
BizOrderConfig bizOrderConfig = bizOrderConfigService.getOne(new QueryWrapper<BizOrderConfig>().lambda().
|
|
@@ -325,7 +327,7 @@ public class BizAppointmentRecordServiceImpl extends ServiceImpl<BizAppointmentR
|
|
long count = this.count(new QueryWrapper<BizAppointmentRecord>().lambda().
|
|
long count = this.count(new QueryWrapper<BizAppointmentRecord>().lambda().
|
|
eq(BizAppointmentRecord::getTimeId, bizAppointmentRecordEditParam.getTimeId()).
|
|
eq(BizAppointmentRecord::getTimeId, bizAppointmentRecordEditParam.getTimeId()).
|
|
notIn(BizAppointmentRecord::getStatus, "10", "11", "12", "13", "14","15"));
|
|
notIn(BizAppointmentRecord::getStatus, "10", "11", "12", "13", "14","15"));
|
|
- if(count>=bizOrderConfig.getApplyNumber()){
|
|
|
|
|
|
+ if(count>=bizOrderConfig.getApplyNumber()+1){
|
|
throw new CommonException("该订单已经预约满!");
|
|
throw new CommonException("该订单已经预约满!");
|
|
}
|
|
}
|
|
}
|
|
}
|