修改查询条件
This commit is contained in:
parent
795eb2a154
commit
2b6f0ccfab
|
@ -41,8 +41,7 @@ public class GwJobController extends BaseController {
|
||||||
private final IGwJobService iGwJobService;
|
private final IGwJobService iGwJobService;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询招聘信息
|
* 查询招聘信息列表
|
||||||
列表
|
|
||||||
*/
|
*/
|
||||||
@SaCheckPermission("official:job:list")
|
@SaCheckPermission("official:job:list")
|
||||||
@GetMapping("/list")
|
@GetMapping("/list")
|
||||||
|
|
|
@ -49,20 +49,12 @@ public class GwJobInfoServiceImpl implements IGwJobInfoService {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询招聘信息
|
* 查询招聘信息列表
|
||||||
列表
|
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public TableDataInfo<GwJobInfoVo> queryPageList(GwJobInfoBo bo, PageQuery pageQuery) {
|
public TableDataInfo<GwJobInfoVo> queryPageList(GwJobInfoBo bo, PageQuery pageQuery) {
|
||||||
LambdaQueryWrapper<GwJobInfo> lqw = buildQueryWrapper(bo);
|
LambdaQueryWrapper<GwJobInfo> lqw = buildQueryWrapper(bo);
|
||||||
Page<GwJobInfoVo> result = baseMapper.selectVoPage(pageQuery.build(), lqw);
|
Page<GwJobInfoVo> result = baseMapper.selectVoPage(pageQuery.build(), lqw);
|
||||||
//取置顶数据放在首条
|
|
||||||
if (CollUtil.isNotEmpty(result.getRecords())){
|
|
||||||
List<GwJobInfoVo> records = result.getRecords();
|
|
||||||
List<GwJobInfoVo> fist = records.stream().filter(itx -> itx.getIsTop().equals("1")).collect(Collectors.toList());
|
|
||||||
fist.addAll(records.stream().filter(itx->!itx.getIsTop().equals("1")).collect(Collectors.toList()));
|
|
||||||
result.setRecords(fist);
|
|
||||||
}
|
|
||||||
return TableDataInfo.build(result);
|
return TableDataInfo.build(result);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -85,7 +77,7 @@ public class GwJobInfoServiceImpl implements IGwJobInfoService {
|
||||||
lqw.like(StringUtils.isNotBlank(bo.getJobName()), GwJobInfo::getJobName, bo.getJobName());
|
lqw.like(StringUtils.isNotBlank(bo.getJobName()), GwJobInfo::getJobName, bo.getJobName());
|
||||||
lqw.eq(StringUtils.isNotBlank(bo.getPostStatement()), GwJobInfo::getPostStatement, bo.getPostStatement());
|
lqw.eq(StringUtils.isNotBlank(bo.getPostStatement()), GwJobInfo::getPostStatement, bo.getPostStatement());
|
||||||
lqw.eq(StringUtils.isNotBlank(bo.getSalaryRange()), GwJobInfo::getSalaryRange, bo.getSalaryRange());
|
lqw.eq(StringUtils.isNotBlank(bo.getSalaryRange()), GwJobInfo::getSalaryRange, bo.getSalaryRange());
|
||||||
lqw.eq(StringUtils.isNotBlank(bo.getBaseSite()), GwJobInfo::getBaseSite, bo.getBaseSite());
|
lqw.like(StringUtils.isNotBlank(bo.getBaseSite()), GwJobInfo::getBaseSite, bo.getBaseSite());
|
||||||
lqw.eq(StringUtils.isNotBlank(bo.getEducation()), GwJobInfo::getEducation, bo.getEducation());
|
lqw.eq(StringUtils.isNotBlank(bo.getEducation()), GwJobInfo::getEducation, bo.getEducation());
|
||||||
lqw.eq(StringUtils.isNotBlank(bo.getAgeRange()), GwJobInfo::getAgeRange, bo.getAgeRange());
|
lqw.eq(StringUtils.isNotBlank(bo.getAgeRange()), GwJobInfo::getAgeRange, bo.getAgeRange());
|
||||||
lqw.eq(bo.getReleaseTime() != null, GwJobInfo::getReleaseTime, bo.getReleaseTime());
|
lqw.eq(bo.getReleaseTime() != null, GwJobInfo::getReleaseTime, bo.getReleaseTime());
|
||||||
|
|
|
@ -43,7 +43,7 @@ public class GwSlideshowServiceImpl implements IGwSlideshowService {
|
||||||
public GwSlideshowVo queryById(Long id) {
|
public GwSlideshowVo queryById(Long id) {
|
||||||
GwSlideshowVo gwSlideshowVo = baseMapper.selectVoById(id);
|
GwSlideshowVo gwSlideshowVo = baseMapper.selectVoById(id);
|
||||||
//查询详情时返回上一篇,下一篇处理
|
//查询详情时返回上一篇,下一篇处理
|
||||||
List<GwSlideshow> list = baseMapper.selectList(Wrappers.<GwSlideshow>lambdaQuery().eq(GwSlideshow::getType,gwSlideshowVo.getType()).orderByDesc(GwSlideshow::getCreateTime));
|
List<GwSlideshow> list = baseMapper.selectList(Wrappers.<GwSlideshow>lambdaQuery().eq(GwSlideshow::getType,gwSlideshowVo.getType()).orderByDesc(GwSlideshow::getIsTop).orderByDesc(GwSlideshow::getCreateTime));
|
||||||
getPrevNextArticles(id, gwSlideshowVo, list);
|
getPrevNextArticles(id, gwSlideshowVo, list);
|
||||||
return gwSlideshowVo;
|
return gwSlideshowVo;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user