|
@@ -234,8 +234,8 @@ public class TbBusinessCarService extends ServiceImpl<TbBusinessCarMapper, TbBus
|
|
|
throw new Exception("补录离场时间,请填写入场时间");
|
|
|
}
|
|
|
String carNo = t.getCarNo();
|
|
|
- String color=t.getColor();
|
|
|
- if (StrUtil.isEmpty(color)){
|
|
|
+ String color = t.getColor();
|
|
|
+ if (StrUtil.isEmpty(color)) {
|
|
|
throw new AjaxError("车牌颜色不能为空");
|
|
|
}
|
|
|
if (color.contains(partConfig.getFreeColor())) {
|
|
@@ -393,7 +393,6 @@ public class TbBusinessCarService extends ServiceImpl<TbBusinessCarMapper, TbBus
|
|
|
}
|
|
|
|
|
|
|
|
|
-
|
|
|
public List<TbBusinessCar> findNotOutCarLike(String carNo) {
|
|
|
if (StrUtil.isEmpty(carNo) || StrUtil.length(carNo) < 3) {
|
|
|
return Collections.emptyList();
|
|
@@ -408,7 +407,6 @@ public class TbBusinessCarService extends ServiceImpl<TbBusinessCarMapper, TbBus
|
|
|
}
|
|
|
|
|
|
|
|
|
-
|
|
|
public List<TbBusinessCar> searchByNo(String carNo) {
|
|
|
if (StrUtil.length(carNo) < 3) {
|
|
|
return Collections.emptyList();
|
|
@@ -425,6 +423,9 @@ public class TbBusinessCarService extends ServiceImpl<TbBusinessCarMapper, TbBus
|
|
|
}
|
|
|
|
|
|
|
|
|
+ public List<TbBusinessCar> searchForPayCar(String carNo) {
|
|
|
+ return tbBusinessCarMapper.searchForPayCar(carNo);
|
|
|
+ }
|
|
|
|
|
|
public void outCar(String id, String outChannel, Date realOutTime) {
|
|
|
Date now = new Date();
|
|
@@ -475,10 +476,15 @@ public class TbBusinessCarService extends ServiceImpl<TbBusinessCarMapper, TbBus
|
|
|
* @param judgeContent
|
|
|
*/
|
|
|
public void callback(String id, String judgeContent) {
|
|
|
+ TbBusinessCar db = this.getById(id);
|
|
|
+ db.setConfirmJudge(TbBusinessCar.ConfirmJudgeEnum.CALL_BACK.getCode())
|
|
|
+ .setConfirmJudgeContent(judgeContent).setConfirmJudgeTime(new Date())
|
|
|
+ .setConfirmJudgeBy(StpUserUtil.getCreateBy());
|
|
|
+ this.updateById(db);
|
|
|
List<TbBusiness> businessList = tbBusinessService.findOtherBusinessByCarId(id);
|
|
|
businessList.forEach(tbBusiness -> {
|
|
|
List<TbBusinessCar> tbBusinessCars = this.findOtherBusinessCar(tbBusiness.getId());
|
|
|
- tbBusinessCars.forEach(tbBusinessCar -> {
|
|
|
+ tbBusinessCars.stream().filter(tbBusinessCar -> !StrUtil.equals(tbBusinessCar.getId(),id)).forEach(tbBusinessCar -> {
|
|
|
tbBusinessCar.setConfirmJudge(TbBusinessCar.ConfirmJudgeEnum.CALL_BACK.getCode())
|
|
|
.setConfirmJudgeContent(judgeContent).setConfirmJudgeTime(new Date())
|
|
|
.setConfirmJudgeBy(StpUserUtil.getCreateBy());
|
|
@@ -507,14 +513,15 @@ public class TbBusinessCarService extends ServiceImpl<TbBusinessCarMapper, TbBus
|
|
|
|
|
|
/**
|
|
|
* 未支付的车
|
|
|
+ *
|
|
|
* @param carNo
|
|
|
* @return
|
|
|
*/
|
|
|
public List<TbBusinessCar> findNotPayByCarNo(String carNo) {
|
|
|
- QueryWrapper<TbBusinessCar>ew=new QueryWrapper<>();
|
|
|
- ew.lambda().like(TbBusinessCar::getCarNo,carNo)
|
|
|
- .eq(TbBusinessCar::getPay,0)
|
|
|
- .eq(TbBusinessCar::getPayType,TbBusinessCar.PayTypeEnum.NO_PAY_TYPE.getType());
|
|
|
+ QueryWrapper<TbBusinessCar> ew = new QueryWrapper<>();
|
|
|
+ ew.lambda().like(TbBusinessCar::getCarNo, carNo)
|
|
|
+ .eq(TbBusinessCar::getPay, 0)
|
|
|
+ .eq(TbBusinessCar::getPayType, TbBusinessCar.PayTypeEnum.NO_PAY_TYPE.getType());
|
|
|
return list(ew);
|
|
|
}
|
|
|
}
|