package com.boying.service.impl;
|
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
import com.boying.entity.ViolationType;
|
import com.boying.entity.WhiteList;
|
import com.boying.mapper.ViolationTypeMapper;
|
import com.boying.mapper.WhiteListMapper;
|
import com.boying.service.ViolationTypeService;
|
import com.boying.service.WhiteListService;
|
import org.springframework.stereotype.Service;
|
|
import java.util.List;
|
|
/**
|
* @author kdq
|
* @version 1.0.0
|
* @ClassName WhiteListServiceImpl.java
|
* @Description TODO
|
* @createTime 2022年11月21日 11:23:00
|
*/
|
@Service
|
public class WhiteListServiceImpl extends ServiceImpl<WhiteListMapper, WhiteList> implements WhiteListService {
|
@Override
|
public WhiteList getByCarNo(String carNo) {
|
QueryWrapper<WhiteList> whiteListQueryWrapper = new QueryWrapper<>();
|
whiteListQueryWrapper.lambda()
|
.eq(WhiteList::getCarNo,carNo);
|
List<WhiteList> list = list(whiteListQueryWrapper);
|
if(list.size()>0){
|
return list.get(0);
|
}else {
|
return null;
|
}
|
}
|
}
|