添加岗位总数接口
This commit is contained in:
@@ -170,6 +170,15 @@ public class JobController {
|
||||
return jobService.recommendJobs(param, userId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 有效岗位总数统计
|
||||
* <p>统计当前上架(status=0)的岗位数量,接口允许不登录访问</p>
|
||||
*/
|
||||
@GetMapping("/count")
|
||||
public Long countValidJobs() {
|
||||
return jobService.countValidJobs();
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据岗位来源地址查询岗位信息
|
||||
* <p>通过岗位的原始链接(如招聘网站URL)查询对应的岗位信息</p>
|
||||
|
||||
@@ -565,6 +565,13 @@ public class JobService {
|
||||
}).collect(Collectors.toList());
|
||||
}
|
||||
|
||||
/**
|
||||
* 统计有效岗位总数(status=0)
|
||||
*/
|
||||
public Long countValidJobs() {
|
||||
return jobMapper.selectCount(new LambdaQueryWrapper<Job>().eq(Job::getStatus, 0));
|
||||
}
|
||||
|
||||
/**
|
||||
* 收藏统计
|
||||
* <p>方法逻辑流程:</p>
|
||||
|
||||
Reference in New Issue
Block a user