1.重构任务跟踪页面 2.修复一系列bug
This commit is contained in:
parent
4af0979059
commit
360ee9a998
|
@ -5,14 +5,14 @@ spring:
|
||||||
driverClassName: com.mysql.cj.jdbc.Driver
|
driverClassName: com.mysql.cj.jdbc.Driver
|
||||||
druid:
|
druid:
|
||||||
# 主库数据源
|
# 主库数据源
|
||||||
# master:
|
|
||||||
# url: jdbc:mysql://192.168.1.165:3306/zeoa?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
|
|
||||||
# username: zeoa
|
|
||||||
# password: dHahLWNYB7tD2Mia
|
|
||||||
master:
|
master:
|
||||||
url: jdbc:mysql://localhost:3306/ry-vue?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
|
url: jdbc:mysql://192.168.1.165:3306/zeoa?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
|
||||||
username: root
|
username: zeoa
|
||||||
password: zero
|
password: dHahLWNYB7tD2Mia
|
||||||
|
# master:
|
||||||
|
# url: jdbc:mysql://localhost:3306/ry-vue?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
|
||||||
|
# username: root
|
||||||
|
# password: zero
|
||||||
# 从库数据源
|
# 从库数据源
|
||||||
slave:
|
slave:
|
||||||
# 从数据源开关/默认关闭
|
# 从数据源开关/默认关闭
|
||||||
|
|
|
@ -7,8 +7,8 @@ ruoyi:
|
||||||
# 版权年份
|
# 版权年份
|
||||||
copyrightYear: 2024
|
copyrightYear: 2024
|
||||||
# 文件路径 示例( Windows配置D:/ruoyi/uploadPath,Linux配置 /home/ruoyi/uploadPath)
|
# 文件路径 示例( Windows配置D:/ruoyi/uploadPath,Linux配置 /home/ruoyi/uploadPath)
|
||||||
profile: D:/zeroerr/uploadPath
|
#profile: D:/zeroerr/uploadPath
|
||||||
#profile: /home/zeroerr_oa/uploadPath
|
profile: /home/zeroerr_oa/uploadPath
|
||||||
# 获取ip地址开关
|
# 获取ip地址开关
|
||||||
addressEnabled: false
|
addressEnabled: false
|
||||||
# 验证码类型 math 数字计算 char 字符验证
|
# 验证码类型 math 数字计算 char 字符验证
|
||||||
|
@ -69,15 +69,15 @@ spring:
|
||||||
# redis 配置
|
# redis 配置
|
||||||
redis:
|
redis:
|
||||||
# 地址
|
# 地址
|
||||||
#host: 192.168.1.189
|
host: 192.168.1.189
|
||||||
host: localhost
|
#host: localhost
|
||||||
# 端口,默认为6379
|
# 端口,默认为6379
|
||||||
port: 6379
|
port: 6379
|
||||||
# 数据库索引
|
# 数据库索引
|
||||||
database: 0
|
database: 0
|
||||||
# 密码
|
# 密码
|
||||||
#password: 123456
|
password: 123456
|
||||||
password:
|
#password:
|
||||||
# 连接超时时间
|
# 连接超时时间
|
||||||
timeout: 10s
|
timeout: 10s
|
||||||
lettuce:
|
lettuce:
|
||||||
|
|
|
@ -8,14 +8,16 @@ import cn.zeroerr.common.core.domain.entity.SysDept;
|
||||||
import cn.zeroerr.common.core.domain.entity.SysUser;
|
import cn.zeroerr.common.core.domain.entity.SysUser;
|
||||||
import cn.zeroerr.common.core.page.TableDataInfo;
|
import cn.zeroerr.common.core.page.TableDataInfo;
|
||||||
import cn.zeroerr.common.enums.BusinessType;
|
import cn.zeroerr.common.enums.BusinessType;
|
||||||
import cn.zeroerr.domain.entity.PostPlanFollow;
|
import cn.zeroerr.domain.dto.FollowDTO;
|
||||||
import cn.zeroerr.domain.entity.RecruitPost;
|
import cn.zeroerr.domain.entity.*;
|
||||||
import cn.zeroerr.service.PostPlanFollowService;
|
import cn.zeroerr.domain.vo.FollowVO;
|
||||||
import cn.zeroerr.service.RecruitPostService;
|
import cn.zeroerr.service.*;
|
||||||
import cn.zeroerr.system.service.ISysDeptService;
|
import cn.zeroerr.system.service.ISysDeptService;
|
||||||
import cn.zeroerr.system.service.ISysUserService;
|
import cn.zeroerr.system.service.ISysUserService;
|
||||||
import cn.zeroerr.system.service.RecruitStructureService;
|
import cn.zeroerr.system.service.RecruitStructureService;
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.CollectionUtils;
|
||||||
import com.baomidou.mybatisplus.core.toolkit.IdWorker;
|
import com.baomidou.mybatisplus.core.toolkit.IdWorker;
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.ObjectUtils;
|
||||||
import io.swagger.annotations.Api;
|
import io.swagger.annotations.Api;
|
||||||
import io.swagger.annotations.ApiModelProperty;
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
import io.swagger.annotations.ApiOperation;
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
@ -30,6 +32,7 @@ import java.time.LocalDate;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
import java.util.Optional;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
@RestController
|
@RestController
|
||||||
|
@ -48,95 +51,264 @@ public class RecruitFollowController extends BaseController {
|
||||||
@Autowired
|
@Autowired
|
||||||
private PostPlanFollowService postPlanFollowService;
|
private PostPlanFollowService postPlanFollowService;
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private ResumeHandleRecordService resumeHandleRecordService;
|
||||||
|
|
||||||
@PreAuthorize("@ss.hasPermi('recruit:follow:add')")
|
@Autowired
|
||||||
@Log(title = "新增招聘计划与统计", businessType = BusinessType.INSERT)
|
private RecruitProcessTaskService recruitProcessTaskService;
|
||||||
@PostMapping("/follow/add")
|
|
||||||
@ApiOperation(value = "新增招聘计划与统计")
|
@Autowired
|
||||||
public AjaxResult add(@Validated @RequestBody PostPlanFollow req) {
|
private ResumeFollowRecordService resumeFollowRecordService;
|
||||||
//根据postId找到postName
|
|
||||||
RecruitPost recruitPost = recruitPostService.getById(req.getPostId());
|
|
||||||
//根据deptId找到deptName
|
|
||||||
//SysDept sysDept = iSysDeptService.selectDeptById(req.getDeptId());
|
|
||||||
RecruitStructure recruitStructure = recruitStructureService.selectNodeById(req.getDeptId());
|
|
||||||
req.setPostName(recruitPost.getPostName());
|
|
||||||
req.setDeptName(recruitStructure.getNodeName());
|
|
||||||
req.setHrId(getUserId());
|
|
||||||
req.setCreateDate(LocalDate.now());
|
|
||||||
//根据userId找到用户名
|
|
||||||
SysUser sysUser = iSysUserService.selectUserById(getUserId());
|
|
||||||
req.setHrName(sysUser.getNickName());
|
|
||||||
req.setId(String.valueOf(IdWorker.getId()));
|
|
||||||
return toAjax(postPlanFollowService.save(req));
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// @PreAuthorize("@ss.hasPermi('recruit:follow:add')")
|
||||||
|
// @Log(title = "新增招聘计划与统计", businessType = BusinessType.INSERT)
|
||||||
|
// @PostMapping("/follow/add")
|
||||||
|
// @ApiOperation(value = "新增招聘计划与统计")
|
||||||
|
// public AjaxResult add(@Validated @RequestBody PostPlanFollow req) {
|
||||||
|
// //根据postId找到postName
|
||||||
|
// RecruitPost recruitPost = recruitPostService.getById(req.getPostId());
|
||||||
|
// //根据deptId找到deptName
|
||||||
|
// //SysDept sysDept = iSysDeptService.selectDeptById(req.getDeptId());
|
||||||
|
// RecruitStructure recruitStructure = recruitStructureService.selectNodeById(req.getDeptId());
|
||||||
|
// req.setPostName(recruitPost.getPostName());
|
||||||
|
// req.setDeptName(recruitStructure.getNodeName());
|
||||||
|
// req.setHrId(getUserId());
|
||||||
|
// req.setCreateDate(LocalDate.now());
|
||||||
|
// //根据userId找到用户名
|
||||||
|
// SysUser sysUser = iSysUserService.selectUserById(getUserId());
|
||||||
|
// req.setHrName(sysUser.getNickName());
|
||||||
|
// req.setId(String.valueOf(IdWorker.getId()));
|
||||||
|
// return toAjax(postPlanFollowService.save(req));
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
//
|
||||||
|
// @PreAuthorize("@ss.hasPermi('recruit:follow:list')")
|
||||||
|
// @GetMapping("/follow/list")
|
||||||
|
// @ApiOperation(value = "查询招聘计划与统计列表")
|
||||||
|
// public List<TableDataInfo> list(PostPlanFollow req) {
|
||||||
|
// startPage();
|
||||||
|
// List<PostPlanFollow> postPlanFollowList=postPlanFollowService.listBySelect(req);
|
||||||
|
// List<TableDataInfo> tableDataInfoList=new ArrayList<>();
|
||||||
|
// //拿到筛选完条件的list后(应该是具体的某个月的list),再根据week进行分组
|
||||||
|
// Map<String, List<PostPlanFollow>> groupByWeek = postPlanFollowList.stream().collect(Collectors.groupingBy(PostPlanFollow::getWeek));
|
||||||
|
// for (Map.Entry<String, List<PostPlanFollow>> entry : groupByWeek.entrySet()) {
|
||||||
|
// List<PostPlanFollow> postPlanFollows = entry.getValue();
|
||||||
|
// postPlanFollows.forEach(
|
||||||
|
// postPlanFollow -> {
|
||||||
|
// //到面率=实际到人数/约面人数;
|
||||||
|
// if(postPlanFollow.getInviteInterviewCount() != 0) {
|
||||||
|
// BigDecimal actualCountBigDecimal = new BigDecimal(postPlanFollow.getActualCount());
|
||||||
|
// BigDecimal inviteInterviewCountBigDecimal = new BigDecimal(postPlanFollow.getInviteInterviewCount());
|
||||||
|
//
|
||||||
|
// // 计算到达率,保留两位小数
|
||||||
|
// BigDecimal arriveRateBigDecimal = actualCountBigDecimal.divide(inviteInterviewCountBigDecimal, 4, RoundingMode.HALF_UP).multiply(new BigDecimal(100)).setScale(2, RoundingMode.HALF_UP);
|
||||||
|
//
|
||||||
|
// double arriveRate = arriveRateBigDecimal.doubleValue();
|
||||||
|
// postPlanFollow.setArriveRate(arriveRate);
|
||||||
|
// }else {
|
||||||
|
// postPlanFollow.setArriveRate(0d);
|
||||||
|
// }
|
||||||
|
// //招聘达成率=入职人数/需求人数
|
||||||
|
// if(postPlanFollow.getPostCount() != 0) {
|
||||||
|
// BigDecimal entryCountBigDecimal = new BigDecimal(postPlanFollow.getEntryCount());
|
||||||
|
// BigDecimal postCountBigDecimal = new BigDecimal(postPlanFollow.getPostCount());
|
||||||
|
//
|
||||||
|
// // 计算达成率,保留两位小数
|
||||||
|
// BigDecimal achievementRateBigDecimal = entryCountBigDecimal.divide(postCountBigDecimal, 4, RoundingMode.HALF_UP).multiply(new BigDecimal(100)).setScale(2, RoundingMode.HALF_UP);
|
||||||
|
//
|
||||||
|
// double achievementRate = achievementRateBigDecimal.doubleValue();
|
||||||
|
// postPlanFollow.setAchievementRate(achievementRate);
|
||||||
|
// }else {
|
||||||
|
// postPlanFollow.setAchievementRate(0d);
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// );
|
||||||
|
// tableDataInfoList.add(getDataTable(postPlanFollows));
|
||||||
|
// }
|
||||||
|
// return tableDataInfoList;
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// @PreAuthorize("@ss.hasAnyPermi('recruit:follow:edit')")
|
||||||
|
// @GetMapping("/follow/{id}")
|
||||||
|
// @ApiOperation(value = "获取某条招聘计划与统计")
|
||||||
|
// public AjaxResult get(@PathVariable ("id")String id){
|
||||||
|
// return success(postPlanFollowService.getById(id));
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// @PreAuthorize("@ss.hasAnyPermi('recruit:follow:edit')")
|
||||||
|
// @PutMapping("/follow/edit")
|
||||||
|
// @ApiOperation(value = "修改某条招聘计划与统计")
|
||||||
|
// public AjaxResult edit(@Validated@RequestBody PostPlanFollow postPlanFollow){
|
||||||
|
// return toAjax(postPlanFollowService.updateById(postPlanFollow));
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// @PreAuthorize("@ss.hasAnyPermi('recruit:follow:delete')")
|
||||||
|
// @DeleteMapping("follow/delete/{id}")
|
||||||
|
// @ApiOperation(value = "删除某条招聘计划与统计")
|
||||||
|
// public AjaxResult delete (@PathVariable("id") String id){
|
||||||
|
// return toAjax(postPlanFollowService.removeById(id));
|
||||||
|
// }
|
||||||
@PreAuthorize("@ss.hasPermi('recruit:follow:list')")
|
@PreAuthorize("@ss.hasPermi('recruit:follow:list')")
|
||||||
@GetMapping("/follow/list")
|
@GetMapping("/follow/list")
|
||||||
@ApiOperation(value = "查询招聘计划与统计列表")
|
@ApiOperation(value = "查询招聘计划与统计列表")
|
||||||
public List<TableDataInfo> list(PostPlanFollow req) {
|
public AjaxResult list(FollowDTO req) {
|
||||||
startPage();
|
List<FollowVO> followVOList=new ArrayList<>();
|
||||||
List<PostPlanFollow> postPlanFollowList=postPlanFollowService.listBySelect(req);
|
//根据搜索条件,从简历处理表中查询所有符合条件的数据
|
||||||
List<TableDataInfo> tableDataInfoList=new ArrayList<>();
|
List<ResumeHandleRecord> resumeHandleRecordList=resumeHandleRecordService.listBySelect(req);
|
||||||
//拿到筛选完条件的list后(应该是具体的某个月的list),再根据week进行分组
|
Map<Long, List<ResumeHandleRecord>> mapResumeHandleRecord = resumeHandleRecordList.stream().collect(Collectors.groupingBy(ResumeHandleRecord::getPostId));
|
||||||
Map<String, List<PostPlanFollow>> groupByWeek = postPlanFollowList.stream().collect(Collectors.groupingBy(PostPlanFollow::getWeek));
|
if(!CollectionUtils.isEmpty(mapResumeHandleRecord)){
|
||||||
for (Map.Entry<String, List<PostPlanFollow>> entry : groupByWeek.entrySet()) {
|
for (Map.Entry<Long, List<ResumeHandleRecord>> entry : mapResumeHandleRecord.entrySet()) {
|
||||||
List<PostPlanFollow> postPlanFollows = entry.getValue();
|
List<ResumeHandleRecord> listByPostId = entry.getValue();
|
||||||
postPlanFollows.forEach(
|
if(!CollectionUtils.isEmpty(listByPostId)){
|
||||||
postPlanFollow -> {
|
FollowVO followVO = new FollowVO();
|
||||||
//到面率=实际到人数/约面人数;
|
ResumeHandleRecord resumeHandleRecord = listByPostId.get(0);
|
||||||
if(postPlanFollow.getInviteInterviewCount() != 0) {
|
followVO.setPostId(resumeHandleRecord.getPostId());
|
||||||
BigDecimal actualCountBigDecimal = new BigDecimal(postPlanFollow.getActualCount());
|
followVO.setPostName(resumeHandleRecord.getPostName());
|
||||||
BigDecimal inviteInterviewCountBigDecimal = new BigDecimal(postPlanFollow.getInviteInterviewCount());
|
followVO.setDeptId(resumeHandleRecord.getDeptId());
|
||||||
|
followVO.setDeptName(resumeHandleRecord.getDeptName());
|
||||||
// 计算到达率,保留两位小数
|
followVO.setHrId(resumeHandleRecord.getOperatorId());
|
||||||
BigDecimal arriveRateBigDecimal = actualCountBigDecimal.divide(inviteInterviewCountBigDecimal, 4, RoundingMode.HALF_UP).multiply(new BigDecimal(100)).setScale(2, RoundingMode.HALF_UP);
|
followVO.setHrName(resumeHandleRecord.getOperatorName());
|
||||||
|
//封装该岗位需求人数
|
||||||
double arriveRate = arriveRateBigDecimal.doubleValue();
|
RecruitStructure postNodeId = recruitStructureService.getByNodeId(followVO.getPostId());
|
||||||
postPlanFollow.setArriveRate(arriveRate);
|
if(!ObjectUtils.isEmpty(postNodeId)){
|
||||||
|
if(postNodeId.getTaskId()!=null){
|
||||||
|
RecruitProcessTask recruitProcessTask = recruitProcessTaskService.getByTaskId(postNodeId.getTaskId());
|
||||||
|
followVO.setPostCount(recruitProcessTask.getPostCount());
|
||||||
}else {
|
}else {
|
||||||
postPlanFollow.setArriveRate(0d);
|
followVO.setPostCount(0);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
//招聘达成率=入职人数/需求人数
|
|
||||||
if(postPlanFollow.getPostCount() != 0) {
|
|
||||||
BigDecimal entryCountBigDecimal = new BigDecimal(postPlanFollow.getEntryCount());
|
|
||||||
BigDecimal postCountBigDecimal = new BigDecimal(postPlanFollow.getPostCount());
|
|
||||||
|
|
||||||
// 计算达成率,保留两位小数
|
//封装查看的简历数
|
||||||
BigDecimal achievementRateBigDecimal = entryCountBigDecimal.divide(postCountBigDecimal, 4, RoundingMode.HALF_UP).multiply(new BigDecimal(100)).setScale(2, RoundingMode.HALF_UP);
|
followVO.setLookResumeCount(listByPostId.stream()
|
||||||
|
.mapToInt(ResumeHandleRecord::getGreetNum)
|
||||||
|
.sum());
|
||||||
|
//封装人力资源通过简历数
|
||||||
|
followVO.setPassResumeCount(listByPostId.stream()
|
||||||
|
.mapToInt(ResumeHandleRecord::getQualifiedNum)
|
||||||
|
.sum());
|
||||||
|
//封装约面人数
|
||||||
|
followVO.setInviteInterviewCount(listByPostId.stream()
|
||||||
|
.mapToInt(ResumeHandleRecord::getQualifiedNum)
|
||||||
|
.sum());
|
||||||
|
//封装接受邀约人数
|
||||||
|
followVO.setAcceptInviteCount(listByPostId.stream()
|
||||||
|
.mapToInt(ResumeHandleRecord::getReceiveInviteNum)
|
||||||
|
.sum());
|
||||||
|
followVOList.add(followVO);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
double achievementRate = achievementRateBigDecimal.doubleValue();
|
//根据搜索条件,从面试跟踪里查询所有符合条件的数据
|
||||||
postPlanFollow.setAchievementRate(achievementRate);
|
List<ResumeFollowRecord> resumeFollowRecordList=resumeFollowRecordService.listBySelect(req);
|
||||||
|
Map<Long, List<ResumeFollowRecord>> mapResumeFollowRecord = resumeFollowRecordList.stream().collect(Collectors.groupingBy(ResumeFollowRecord::getPostId));
|
||||||
|
if(!CollectionUtils.isEmpty(mapResumeFollowRecord)){
|
||||||
|
for (Map.Entry<Long, List<ResumeFollowRecord>> entry : mapResumeFollowRecord.entrySet()) {
|
||||||
|
//先去followVOList去找有没有对应的岗位
|
||||||
|
Optional<FollowVO> result = followVOList.stream()
|
||||||
|
.filter(followVO -> followVO.getPostId().equals(entry.getKey()))
|
||||||
|
.findFirst();
|
||||||
|
List<ResumeFollowRecord> resumeFollowRecords = entry.getValue();
|
||||||
|
//如果存在,则插入数据
|
||||||
|
if(result.isPresent()){
|
||||||
|
FollowVO followVO = result.get();
|
||||||
|
//设置一面人数
|
||||||
|
followVO.setFirstInterviewCount(resumeFollowRecords.stream()
|
||||||
|
.filter( record -> record.getFirstReach() != null && "1".equals(record.getFirstReach()))
|
||||||
|
.count());
|
||||||
|
//设置二面人数
|
||||||
|
followVO.setSecondInterviewCount(resumeFollowRecords.stream()
|
||||||
|
.filter(record -> record.getSecondReach() != null && "1".equals(record.getSecondReach()))
|
||||||
|
.count());
|
||||||
|
//设置三面人数
|
||||||
|
followVO.setThirdInterviewCount(resumeFollowRecords.stream()
|
||||||
|
.filter(record -> record.getFinalReach() != null && "1".equals(record.getFinalReach()))
|
||||||
|
.count());
|
||||||
|
//设置谈薪人数
|
||||||
|
followVO.setSalaryCount(resumeFollowRecords.stream()
|
||||||
|
.filter(record -> record.getFinalPass() != null && "1".equals(record.getFinalPass()))
|
||||||
|
.count());
|
||||||
|
//设置拿offer人数
|
||||||
|
followVO.setOfferCount(resumeFollowRecords.stream()
|
||||||
|
.filter(record -> record.getAcceptOffer() != null && "1".equals(record.getAcceptOffer()))
|
||||||
|
.count());
|
||||||
|
//设置入职人数(实际入职日期不为空的条数)
|
||||||
|
followVO.setEntryCount(resumeFollowRecords.stream()
|
||||||
|
.filter(record -> record.getActualJoinDate() != null)
|
||||||
|
.count());
|
||||||
|
//封装到面率(一面人数/接受邀约人数)
|
||||||
|
if(followVO.getAcceptInviteCount()!=null&&followVO.getAcceptInviteCount()!=0){
|
||||||
|
BigDecimal arrivePercentage = new BigDecimal(followVO.getFirstInterviewCount()).divide(new BigDecimal(followVO.getAcceptInviteCount()), 2, RoundingMode.HALF_UP).multiply(new BigDecimal(100));
|
||||||
|
followVO.setArriveRate(arrivePercentage.doubleValue());
|
||||||
}else {
|
}else {
|
||||||
postPlanFollow.setAchievementRate(0d);
|
followVO.setArriveRate(0d);
|
||||||
}
|
}
|
||||||
}
|
//封装招聘达成率(入职人数/需求人数)
|
||||||
);
|
if(followVO.getPostCount()!=null&&followVO.getPostCount()!=0){
|
||||||
tableDataInfoList.add(getDataTable(postPlanFollows));
|
BigDecimal entryPercentage = new BigDecimal(followVO.getEntryCount()).divide(new BigDecimal(followVO.getPostCount()), 2, RoundingMode.HALF_UP).multiply(new BigDecimal(100));
|
||||||
}
|
followVO.setAchievementRate(entryPercentage.doubleValue());
|
||||||
return tableDataInfoList;
|
}else {
|
||||||
|
followVO.setAchievementRate(0d);
|
||||||
}
|
}
|
||||||
|
|
||||||
@PreAuthorize("@ss.hasAnyPermi('recruit:follow:edit')")
|
//将更新完的数据放回去
|
||||||
@GetMapping("/follow/{id}")
|
int index = followVOList.indexOf(followVO);
|
||||||
@ApiOperation(value = "获取某条招聘计划与统计")
|
if (index >= 0) {
|
||||||
public AjaxResult get(@PathVariable ("id")String id){
|
followVOList.set(index, followVO);
|
||||||
return success(postPlanFollowService.getById(id));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@PreAuthorize("@ss.hasAnyPermi('recruit:follow:edit')")
|
|
||||||
@PutMapping("/follow/edit")
|
|
||||||
@ApiOperation(value = "修改某条招聘计划与统计")
|
|
||||||
public AjaxResult edit(@Validated@RequestBody PostPlanFollow postPlanFollow){
|
|
||||||
return toAjax(postPlanFollowService.updateById(postPlanFollow));
|
|
||||||
}
|
}
|
||||||
|
//如果不存在则新增数据
|
||||||
@PreAuthorize("@ss.hasAnyPermi('recruit:follow:delete')")
|
else {
|
||||||
@DeleteMapping("follow/delete/{id}")
|
FollowVO followVO = new FollowVO();
|
||||||
@ApiOperation(value = "删除某条招聘计划与统计")
|
ResumeFollowRecord resumeFollowRecord = resumeFollowRecords.get(0);
|
||||||
public AjaxResult delete (@PathVariable("id") String id){
|
followVO.setPostId(resumeFollowRecord.getPostId());
|
||||||
return toAjax(postPlanFollowService.removeById(id));
|
followVO.setPostName(resumeFollowRecord.getPostName());
|
||||||
|
RecruitStructure postNodeId = recruitStructureService.getByNodeId(followVO.getPostId());
|
||||||
|
if(!ObjectUtils.isEmpty(postNodeId)) {
|
||||||
|
if (postNodeId.getTaskId() != null) {
|
||||||
|
RecruitProcessTask recruitProcessTask = recruitProcessTaskService.getByTaskId(postNodeId.getTaskId());
|
||||||
|
followVO.setPostCount(recruitProcessTask.getPostCount());
|
||||||
|
} else {
|
||||||
|
followVO.setPostCount(0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
followVO.setHrId(resumeFollowRecord.getHrId());
|
||||||
|
followVO.setHrName(resumeFollowRecord.getHrName());
|
||||||
|
//设置一面人数
|
||||||
|
followVO.setFirstInterviewCount(resumeFollowRecords.stream()
|
||||||
|
.filter( record -> record.getFirstReach() != null && "1".equals(record.getFirstReach()))
|
||||||
|
.count());
|
||||||
|
//设置二面人数
|
||||||
|
followVO.setSecondInterviewCount(resumeFollowRecords.stream()
|
||||||
|
.filter(record -> record.getSecondReach() != null && "1".equals(record.getSecondReach()))
|
||||||
|
.count());
|
||||||
|
//设置三面人数
|
||||||
|
followVO.setThirdInterviewCount(resumeFollowRecords.stream()
|
||||||
|
.filter(record -> record.getFinalReach() != null && "1".equals(record.getFinalReach()))
|
||||||
|
.count());
|
||||||
|
//设置谈薪人数
|
||||||
|
followVO.setSalaryCount(resumeFollowRecords.stream()
|
||||||
|
.filter(record -> record.getFinalPass() != null && "1".equals(record.getFinalPass()))
|
||||||
|
.count());
|
||||||
|
//设置拿offer人数
|
||||||
|
followVO.setOfferCount(resumeFollowRecords.stream()
|
||||||
|
.filter(record -> record.getAcceptOffer() != null && "1".equals(record.getAcceptOffer()))
|
||||||
|
.count());
|
||||||
|
//设置入职人数(实际入职日期不为空的条数)
|
||||||
|
followVO.setEntryCount(resumeFollowRecords.stream()
|
||||||
|
.filter(record -> record.getActualJoinDate() != null)
|
||||||
|
.count());
|
||||||
|
//插入新数据
|
||||||
|
followVOList.add(followVO);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return AjaxResult.success(followVOList);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -5,6 +5,7 @@ import cn.zeroerr.common.config.RuoYiConfig;
|
||||||
import cn.zeroerr.common.constant.Constants;
|
import cn.zeroerr.common.constant.Constants;
|
||||||
import cn.zeroerr.common.core.controller.BaseController;
|
import cn.zeroerr.common.core.controller.BaseController;
|
||||||
import cn.zeroerr.common.core.domain.AjaxResult;
|
import cn.zeroerr.common.core.domain.AjaxResult;
|
||||||
|
import cn.zeroerr.common.core.domain.entity.RecruitStructure;
|
||||||
import cn.zeroerr.common.core.domain.entity.SysRole;
|
import cn.zeroerr.common.core.domain.entity.SysRole;
|
||||||
import cn.zeroerr.common.core.domain.entity.SysUser;
|
import cn.zeroerr.common.core.domain.entity.SysUser;
|
||||||
import cn.zeroerr.common.core.domain.model.LoginUser;
|
import cn.zeroerr.common.core.domain.model.LoginUser;
|
||||||
|
@ -21,8 +22,10 @@ import cn.zeroerr.domain.entity.ResumeFollowRecord;
|
||||||
import cn.zeroerr.domain.vo.UserVO;
|
import cn.zeroerr.domain.vo.UserVO;
|
||||||
import cn.zeroerr.service.RecruitPostService;
|
import cn.zeroerr.service.RecruitPostService;
|
||||||
import cn.zeroerr.service.ResumeFollowRecordService;
|
import cn.zeroerr.service.ResumeFollowRecordService;
|
||||||
|
import cn.zeroerr.system.mapper.RecruitStructureMapper;
|
||||||
import cn.zeroerr.system.service.ISysRoleService;
|
import cn.zeroerr.system.service.ISysRoleService;
|
||||||
import cn.zeroerr.system.service.ISysUserService;
|
import cn.zeroerr.system.service.ISysUserService;
|
||||||
|
import cn.zeroerr.system.service.RecruitStructureService;
|
||||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
|
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
|
||||||
import com.baomidou.mybatisplus.core.toolkit.CollectionUtils;
|
import com.baomidou.mybatisplus.core.toolkit.CollectionUtils;
|
||||||
|
@ -58,6 +61,9 @@ public class RecruitInterviewController extends BaseController {
|
||||||
@Autowired
|
@Autowired
|
||||||
private ISysRoleService iSysRoleService;
|
private ISysRoleService iSysRoleService;
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private RecruitStructureService recruitStructureService;
|
||||||
|
|
||||||
@PreAuthorize("@ss.hasAnyPermi('recruit:interview:list')")
|
@PreAuthorize("@ss.hasAnyPermi('recruit:interview:list')")
|
||||||
@GetMapping("/interview/getAllUser")
|
@GetMapping("/interview/getAllUser")
|
||||||
@ApiOperation(value = "查询所有的用户(领导+hr)")
|
@ApiOperation(value = "查询所有的用户(领导+hr)")
|
||||||
|
@ -109,8 +115,8 @@ public class RecruitInterviewController extends BaseController {
|
||||||
req.setHrId(getUserId());
|
req.setHrId(getUserId());
|
||||||
SysUser sysUser = iSysUserService.selectUserById(getUserId());
|
SysUser sysUser = iSysUserService.selectUserById(getUserId());
|
||||||
req.setHrName(sysUser.getNickName());
|
req.setHrName(sysUser.getNickName());
|
||||||
RecruitPost post = recruitPostService.getById(req.getPostId());
|
RecruitStructure recruitStructure = recruitStructureService.getByNodeId(req.getPostId());
|
||||||
req.setPostName(post.getPostName());
|
req.setPostName(recruitStructure.getNodeName());
|
||||||
req.setCreateDate(LocalDate.now());
|
req.setCreateDate(LocalDate.now());
|
||||||
//默认不置顶
|
//默认不置顶
|
||||||
req.setTopping(false);
|
req.setTopping(false);
|
||||||
|
|
|
@ -478,10 +478,13 @@ public class RecruitProcessController extends BaseController {
|
||||||
SysUser user = iSysUserService.selectUserById(getUserId());
|
SysUser user = iSysUserService.selectUserById(getUserId());
|
||||||
record.setOperatorName(user.getNickName());
|
record.setOperatorName(user.getNickName());
|
||||||
//根据岗位id获取岗位name
|
//根据岗位id获取岗位name
|
||||||
RecruitPost recruitPost = recruitPostService.getById(record.getPostId());
|
// RecruitPost recruitPost = recruitPostService.getById(record.getPostId());
|
||||||
record.setPostName(recruitPost.getPostName());
|
// record.setPostName(recruitPost.getPostName());
|
||||||
//寻找组织架构中,该岗位所属的最大部门
|
RecruitStructure post = recruitStructureService.getByNodeId(record.getPostId());
|
||||||
|
record.setPostName(post.getNodeName());
|
||||||
|
//根据deptId,找到部门名
|
||||||
|
RecruitStructure recruitStructure = recruitStructureService.selectNodeById(record.getDeptId());
|
||||||
|
record.setDeptName(recruitStructure.getNodeName());
|
||||||
|
|
||||||
return toAjax(resumeHandleRecordService.save(record));
|
return toAjax(resumeHandleRecordService.save(record));
|
||||||
}
|
}
|
||||||
|
@ -497,7 +500,8 @@ public class RecruitProcessController extends BaseController {
|
||||||
recruitPostList.forEach(
|
recruitPostList.forEach(
|
||||||
recruitPost -> {
|
recruitPost -> {
|
||||||
PostListVO postListVO = new PostListVO();
|
PostListVO postListVO = new PostListVO();
|
||||||
postListVO.setPostId(recruitPost.getPostId());
|
//这里传入的是组织架构节点id
|
||||||
|
postListVO.setPostId(recruitPost.getNodeId());
|
||||||
postListVO.setPostName(recruitPost.getPostName());
|
postListVO.setPostName(recruitPost.getPostName());
|
||||||
postListVOList.add(postListVO);
|
postListVOList.add(postListVO);
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,33 @@
|
||||||
|
package cn.zeroerr.domain.dto;
|
||||||
|
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.AllArgsConstructor;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.NoArgsConstructor;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
|
||||||
|
import java.time.LocalDate;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
@ApiModel
|
||||||
|
@AllArgsConstructor
|
||||||
|
@NoArgsConstructor
|
||||||
|
public class FollowDTO {
|
||||||
|
@ApiModelProperty(value = "岗位名称")
|
||||||
|
private String postName;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "hr名")
|
||||||
|
private String hrName;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "开始日期")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
private LocalDate startDate;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "结束日期")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
private LocalDate endDate;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "部门id")
|
||||||
|
private Long deptId;
|
||||||
|
}
|
|
@ -91,6 +91,18 @@ public class ResumeHandleRecord implements Serializable {
|
||||||
@TableField(value = "operator_name")
|
@TableField(value = "operator_name")
|
||||||
private String operatorName;
|
private String operatorName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 部门id
|
||||||
|
*/
|
||||||
|
@TableField(value = "dept_id")
|
||||||
|
private Long deptId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 部门名字
|
||||||
|
*/
|
||||||
|
@TableField(value = "dept_name")
|
||||||
|
private String deptName;
|
||||||
|
|
||||||
@TableField(exist = false)
|
@TableField(exist = false)
|
||||||
private static final long serialVersionUID = 1L;
|
private static final long serialVersionUID = 1L;
|
||||||
}
|
}
|
|
@ -0,0 +1,121 @@
|
||||||
|
package cn.zeroerr.domain.vo;
|
||||||
|
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ApiModel
|
||||||
|
@Data
|
||||||
|
public class FollowVO {
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "部门id")
|
||||||
|
private Long deptId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "部门名字")
|
||||||
|
private String deptName;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "岗位id")
|
||||||
|
private Long postId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "岗位名字")
|
||||||
|
private String postName;
|
||||||
|
|
||||||
|
// /**
|
||||||
|
// * 招聘时间
|
||||||
|
// */
|
||||||
|
// @TableField(value = "recruit_date")
|
||||||
|
// @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
// @DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
// private LocalDate recruitDate;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "需求人数")
|
||||||
|
private Integer postCount;
|
||||||
|
|
||||||
|
// /**
|
||||||
|
// * 招聘优先级
|
||||||
|
// */
|
||||||
|
// @TableField(value = "grade")
|
||||||
|
// private Integer grade;
|
||||||
|
|
||||||
|
// /**
|
||||||
|
// * 约面目标
|
||||||
|
// */
|
||||||
|
// @TableField(value = "interview_count")
|
||||||
|
// private Integer interviewCount;
|
||||||
|
//
|
||||||
|
// /**
|
||||||
|
// * 面试通过目标
|
||||||
|
// */
|
||||||
|
// @TableField(value = "pass_count_target")
|
||||||
|
// private Integer passCountTarget;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "查看过该岗位多少简历数")
|
||||||
|
private Integer lookResumeCount;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "hr提交部门简历数")
|
||||||
|
private Integer passResumeCount;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "约面人数")
|
||||||
|
private Integer inviteInterviewCount;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "接受邀约人数")
|
||||||
|
private Integer acceptInviteCount;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "一面人数")
|
||||||
|
private Long firstInterviewCount;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "二面人数")
|
||||||
|
private Long secondInterviewCount;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "三面人数")
|
||||||
|
private Long thirdInterviewCount;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "谈薪人数")
|
||||||
|
private Long salaryCount;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "offer人数")
|
||||||
|
private Long offerCount;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "入职人数")
|
||||||
|
private Long entryCount;
|
||||||
|
|
||||||
|
// @ApiModelProperty(value = "离职人数")
|
||||||
|
// private Long leaveCount;
|
||||||
|
|
||||||
|
// @ApiModelProperty(value = "实际到面人数")
|
||||||
|
// private Long actualCount;
|
||||||
|
|
||||||
|
// /**
|
||||||
|
// * 周初人数
|
||||||
|
// */
|
||||||
|
// @TableField(value = "early_week_count")
|
||||||
|
// private Integer earlyWeekCount;
|
||||||
|
//
|
||||||
|
// /**
|
||||||
|
// * 周末人数
|
||||||
|
// */
|
||||||
|
// @TableField(value = "late_week_count")
|
||||||
|
// private Integer lateWeekCount;
|
||||||
|
//
|
||||||
|
// /**
|
||||||
|
// * 离职率
|
||||||
|
// */
|
||||||
|
// @TableField(value = "leave_percent")
|
||||||
|
// private Integer leavePercent;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "负责人id")
|
||||||
|
private Long hrId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "负责人名字")
|
||||||
|
private String hrName;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "到面率")
|
||||||
|
private Double arriveRate;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "招聘达成率")
|
||||||
|
private Double achievementRate;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
|
@ -1,5 +1,6 @@
|
||||||
package cn.zeroerr.mapper;
|
package cn.zeroerr.mapper;
|
||||||
|
|
||||||
|
import cn.zeroerr.domain.dto.FollowDTO;
|
||||||
import cn.zeroerr.domain.entity.ResumeFollowRecord;
|
import cn.zeroerr.domain.entity.ResumeFollowRecord;
|
||||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
@ -25,7 +26,7 @@ public interface ResumeFollowRecordMapper extends BaseMapper<ResumeFollowRecord>
|
||||||
|
|
||||||
List<ResumeFollowRecord> getPostEntryList(@Param("postList") List<Long> postList, @Param("firstDay") LocalDate firstDay, @Param("lastDay")LocalDate lastDay);
|
List<ResumeFollowRecord> getPostEntryList(@Param("postList") List<Long> postList, @Param("firstDay") LocalDate firstDay, @Param("lastDay")LocalDate lastDay);
|
||||||
|
|
||||||
|
List<ResumeFollowRecord> listBySelect(@Param("req") FollowDTO req);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
package cn.zeroerr.mapper;
|
package cn.zeroerr.mapper;
|
||||||
|
|
||||||
|
import cn.zeroerr.domain.dto.FollowDTO;
|
||||||
import cn.zeroerr.domain.dto.RecordListDTO;
|
import cn.zeroerr.domain.dto.RecordListDTO;
|
||||||
import cn.zeroerr.domain.entity.ResumeHandleRecord;
|
import cn.zeroerr.domain.entity.ResumeHandleRecord;
|
||||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
@ -22,6 +23,8 @@ public interface ResumeHandleRecordMapper extends BaseMapper<ResumeHandleRecord>
|
||||||
List<ResumeHandleRecord> listByCondition(@Param("req") RecordListDTO req,@Param("userId") Long userId);
|
List<ResumeHandleRecord> listByCondition(@Param("req") RecordListDTO req,@Param("userId") Long userId);
|
||||||
|
|
||||||
List<ResumeHandleRecord> getBySelect(@Param("hrId")Long hrId, @Param("firstDay")LocalDate firstDay, @Param("lastDay")LocalDate lastDay);
|
List<ResumeHandleRecord> getBySelect(@Param("hrId")Long hrId, @Param("firstDay")LocalDate firstDay, @Param("lastDay")LocalDate lastDay);
|
||||||
|
|
||||||
|
List<ResumeHandleRecord> listBySelect(@Param("req") FollowDTO req);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
package cn.zeroerr.service;
|
package cn.zeroerr.service;
|
||||||
|
|
||||||
|
import cn.zeroerr.domain.dto.FollowDTO;
|
||||||
import cn.zeroerr.domain.entity.ResumeFollowRecord;
|
import cn.zeroerr.domain.entity.ResumeFollowRecord;
|
||||||
import com.baomidou.mybatisplus.extension.service.IService;
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
|
||||||
|
@ -21,5 +22,5 @@ public interface ResumeFollowRecordService extends IService<ResumeFollowRecord>
|
||||||
|
|
||||||
List<ResumeFollowRecord> getPostEntryList(List<Long> postList, LocalDate firstDay, LocalDate lastDay);
|
List<ResumeFollowRecord> getPostEntryList(List<Long> postList, LocalDate firstDay, LocalDate lastDay);
|
||||||
|
|
||||||
|
List<ResumeFollowRecord> listBySelect(FollowDTO req);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
package cn.zeroerr.service;
|
package cn.zeroerr.service;
|
||||||
|
|
||||||
|
import cn.zeroerr.domain.dto.FollowDTO;
|
||||||
import cn.zeroerr.domain.dto.RecordListDTO;
|
import cn.zeroerr.domain.dto.RecordListDTO;
|
||||||
import cn.zeroerr.domain.entity.ResumeHandleRecord;
|
import cn.zeroerr.domain.entity.ResumeHandleRecord;
|
||||||
import com.baomidou.mybatisplus.extension.service.IService;
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
@ -18,4 +19,6 @@ public interface ResumeHandleRecordService extends IService<ResumeHandleRecord>
|
||||||
List<ResumeHandleRecord> listByCondition(RecordListDTO req,Long userId);
|
List<ResumeHandleRecord> listByCondition(RecordListDTO req,Long userId);
|
||||||
|
|
||||||
List<ResumeHandleRecord> getBySelect(Long hrId, LocalDate firstDay, LocalDate lastDay);
|
List<ResumeHandleRecord> getBySelect(Long hrId, LocalDate firstDay, LocalDate lastDay);
|
||||||
|
|
||||||
|
List<ResumeHandleRecord> listBySelect(FollowDTO req);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
package cn.zeroerr.service.impl;
|
package cn.zeroerr.service.impl;
|
||||||
|
|
||||||
|
import cn.zeroerr.domain.dto.FollowDTO;
|
||||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
import cn.zeroerr.domain.entity.ResumeFollowRecord;
|
import cn.zeroerr.domain.entity.ResumeFollowRecord;
|
||||||
import cn.zeroerr.service.ResumeFollowRecordService;
|
import cn.zeroerr.service.ResumeFollowRecordService;
|
||||||
|
@ -42,6 +43,11 @@ public class ResumeFollowRecordServiceImpl extends ServiceImpl<ResumeFollowRecor
|
||||||
return resumeFollowRecordMapper.getPostEntryList(postList,firstDay,lastDay);
|
return resumeFollowRecordMapper.getPostEntryList(postList,firstDay,lastDay);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<ResumeFollowRecord> listBySelect(FollowDTO req) {
|
||||||
|
return resumeFollowRecordMapper.listBySelect(req);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
package cn.zeroerr.service.impl;
|
package cn.zeroerr.service.impl;
|
||||||
|
|
||||||
|
import cn.zeroerr.domain.dto.FollowDTO;
|
||||||
import cn.zeroerr.domain.dto.RecordListDTO;
|
import cn.zeroerr.domain.dto.RecordListDTO;
|
||||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
import cn.zeroerr.domain.entity.ResumeHandleRecord;
|
import cn.zeroerr.domain.entity.ResumeHandleRecord;
|
||||||
|
@ -32,6 +33,11 @@ public class ResumeHandleRecordServiceImpl extends ServiceImpl<ResumeHandleRecor
|
||||||
public List<ResumeHandleRecord> getBySelect(Long hrId, LocalDate firstDay, LocalDate lastDay) {
|
public List<ResumeHandleRecord> getBySelect(Long hrId, LocalDate firstDay, LocalDate lastDay) {
|
||||||
return resumeHandleRecordMapper.getBySelect(hrId,firstDay,lastDay);
|
return resumeHandleRecordMapper.getBySelect(hrId,firstDay,lastDay);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<ResumeHandleRecord> listBySelect(FollowDTO req) {
|
||||||
|
return resumeHandleRecordMapper.listBySelect(req);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -115,4 +115,16 @@
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
|
||||||
|
<select id="listBySelect" resultMap="BaseResultMap">
|
||||||
|
select
|
||||||
|
<include refid="Base_Column_List"/>
|
||||||
|
from resume_follow_record
|
||||||
|
where receive_date <![CDATA[>=]]> #{req.startDate}
|
||||||
|
and receive_date <![CDATA[<=]]> #{req.endDate}
|
||||||
|
<if test="req.hrName!=null and req.hrName != ''">and hr_name like concat('%', #{req.hrName}, '%')</if>
|
||||||
|
<if test="req.postName!=null and req.postName != ''">and post_name like concat('%', #{req.postName}, '%')</if>
|
||||||
|
<if test="req.deptId!=null">and dept_id = #{req.deptId}</if>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|
|
@ -17,19 +17,21 @@
|
||||||
<result property="receiveInviteNum" column="receive_invite_num" jdbcType="INTEGER"/>
|
<result property="receiveInviteNum" column="receive_invite_num" jdbcType="INTEGER"/>
|
||||||
<result property="operatorId" column="operator_id" />
|
<result property="operatorId" column="operator_id" />
|
||||||
<result property="operatorName" column="operator_name" />
|
<result property="operatorName" column="operator_name" />
|
||||||
|
<result property="deptId" column="dept_Id" />
|
||||||
|
<result property="deptName" column="dept_name" />
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<sql id="Base_Column_List">
|
<sql id="Base_Column_List">
|
||||||
id,post_id,post_name,
|
id,post_id,post_name,
|
||||||
handle_date,recruitment_channel,seen_num,
|
handle_date,recruitment_channel,seen_num,
|
||||||
greet_num,submit_num,qualified_num,
|
greet_num,submit_num,qualified_num,
|
||||||
receive_invite_num,operator_id,operator_name
|
receive_invite_num,operator_id,operator_name,dept_id,dept_name
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<select id="listByCondition" resultMap="BaseResultMap">
|
<select id="listByCondition" resultMap="BaseResultMap">
|
||||||
select <include refid="Base_Column_List"/> from resume_handle_record
|
select <include refid="Base_Column_List"/> from resume_handle_record
|
||||||
where operator_id=#{userId}
|
where operator_id=#{userId}
|
||||||
<if test="req.postName!=null and postName != ''">and post_name like concat('%', #{req.postName}, '%')</if>
|
<if test="req.postName!=null and req.postName != ''">and post_name like concat('%', #{req.postName}, '%')</if>
|
||||||
<if test="req.startDate!=null">and handle_date <![CDATA[>=]]> #{req.startDate}</if>
|
<if test="req.startDate!=null">and handle_date <![CDATA[>=]]> #{req.startDate}</if>
|
||||||
<if test="req.endDate!=null">and handle_date <![CDATA[<=]]> #{req.endDate}</if>
|
<if test="req.endDate!=null">and handle_date <![CDATA[<=]]> #{req.endDate}</if>
|
||||||
<if test="req.deptId!=null">and dept_id = #{req.deptId}</if>
|
<if test="req.deptId!=null">and dept_id = #{req.deptId}</if>
|
||||||
|
@ -44,4 +46,17 @@
|
||||||
and handle_date <![CDATA[<=]]> #{lastDay}
|
and handle_date <![CDATA[<=]]> #{lastDay}
|
||||||
<if test="hrId!=null">and operator_id=#{hrId}</if>
|
<if test="hrId!=null">and operator_id=#{hrId}</if>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
<select id="listBySelect" resultMap="BaseResultMap">
|
||||||
|
select
|
||||||
|
<include refid="Base_Column_List"/>
|
||||||
|
from resume_handle_record
|
||||||
|
where handle_date <![CDATA[>=]]> #{req.startDate}
|
||||||
|
and handle_date <![CDATA[<=]]> #{req.endDate}
|
||||||
|
<if test="req.hrName!=null and req.hrName != ''">and operator_name like concat('%', #{req.hrName}, '%')</if>
|
||||||
|
<if test="req.postName!=null and req.postName != ''">and post_name like concat('%', #{req.postName}, '%')</if>
|
||||||
|
<if test="req.deptId!=null">and dept_id = #{req.deptId}</if>
|
||||||
|
order by handle_date asc
|
||||||
|
</select>
|
||||||
|
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|
Loading…
Reference in New Issue