| | |
| | | .isNotNull(JkCabinetGrid::getKeyId) |
| | | .apply(" ( t2.code in ( select c.car_code from car_use_book c where c.isdeleted = 0 and NOW() > DATE_SUB(c.START_TIME, INTERVAL "+earlyConfig+" MINUTE) and now() < c.end_time " + |
| | | " and c.DRIVER_ID = "+dto.getMemberId()+" )" + |
| | | " or t2.code in ( select c.car_code from car_use_book c inner join cars c1 on c.CAR_ID = c1.ID where c1.MEMBER_ID = 6611 AND NOW() > DATE_SUB( c.START_TIME, INTERVAL 30 MINUTE ) AND now() < c.end_time )" + |
| | | " or t2.code in ( select c.car_code from car_use_book c inner join cars c1 on c.CAR_ID = c1.ID where c1.MEMBER_ID = "+dto.getMemberId()+" AND NOW() > DATE_SUB( c.START_TIME, INTERVAL 30 MINUTE ) AND now() < c.end_time )" + |
| | | " )" + |
| | | " ") |
| | | ); |
| | |
| | | .eq(CarUseBook::getIsdeleted,Constants.ZERO) |
| | | .isNotNull(CarUseBook::getDriverId) |
| | | .apply(" car_id in ( SELECT k.CAR_ID FROM jk_cabinet_grid j inner join jk_keys k on j.KEY_ID = k.ID where j.isdeleted = 0 and k.isdeleted = 0 ) ") |
| | | .apply(" NOW() > DATE_SUB(START_TIME, INTERVAL "+earlyConfig+" MINUTE) and now() < end_time ") |
| | | .apply(" ( ( NOW() > DATE_SUB(START_TIME, INTERVAL "+earlyConfig+" MINUTE) and now() < end_time ) or KEY_STATUS = 1 ) ") |
| | | ); |
| | | if(CollectionUtils.isNotEmpty(carUseBookList)){ |
| | | driverList.addAll(memberMapper.selectList(new QueryWrapper<Member>().lambda() |