MyBatisPlus之lambdaChainWrapper
/**
* 通过老科室主键查询对照
*
* @return
*/
public DepartmentMapping getDepartmentMappingByOldId(Long oldId) {
DepartmentMappingPo po = new LambdaQueryChainWrapper<>(this.departmentMappingMapper)
.eq(DepartmentMappingPo::getOldId, oldId)
.last(" LIMIT 1 ")
.one();
return DepartmentMappingConverter.ME.po2bo(po);
}
学习使我充实,分享给我快乐!