From e30287d0d53c2f911b58170c2980d0abe6bfd185 Mon Sep 17 00:00:00 2001 From: Unique-Jerry <10902054+unique-jerry@user.noreply.gitee.com> Date: Thu, 7 Dec 2023 10:22:42 +0800 Subject: [PATCH] =?UTF-8?q?=E9=82=80=E8=AF=B7=E9=9D=A2=E8=AF=95=E5=AE=8C?= =?UTF-8?q?=E5=96=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../VxController/VxInterviewController.java | 7 +++---- .../VxService/VxInterviewApplicationService.java | 2 +- .../impl/VxInterviewApplicationServiceImpl.java | 16 +++++++++++++--- .../service/impl/InvitePromoteServiceImpl.java | 1 - 4 files changed, 17 insertions(+), 9 deletions(-) diff --git a/src/main/java/com/yzdx/AiInterviewer/controller/VxController/VxInterviewController.java b/src/main/java/com/yzdx/AiInterviewer/controller/VxController/VxInterviewController.java index 7113d40..2a0c121 100644 --- a/src/main/java/com/yzdx/AiInterviewer/controller/VxController/VxInterviewController.java +++ b/src/main/java/com/yzdx/AiInterviewer/controller/VxController/VxInterviewController.java @@ -22,11 +22,10 @@ public class VxInterviewController { @PostMapping("addInterviewApplication") public R addInterviewApplication( @RequestParam(value = "jobId")Integer jobId, @RequestParam(value = "userId")Integer userId, - @RequestParam(value = "resumeId")Integer resumeId, @RequestParam(value = "postingId")Integer postingId, - @RequestParam(value = "companyEncoding")String companyEncoding, - @RequestParam(value = "status")Integer status){ - Integer rows=vxInterviewApplicationService.addInterviewApplication(jobId,userId,resumeId,postingId,companyEncoding,status); + @RequestParam(value = "companyEncoding")String companyEncoding + ){ + Integer rows=vxInterviewApplicationService.addInterviewApplication(jobId,userId,postingId,companyEncoding); if(rows==-2){ return R.error("申请失败"); } diff --git a/src/main/java/com/yzdx/AiInterviewer/service/VxService/VxInterviewApplicationService.java b/src/main/java/com/yzdx/AiInterviewer/service/VxService/VxInterviewApplicationService.java index ceaa0b4..2321953 100644 --- a/src/main/java/com/yzdx/AiInterviewer/service/VxService/VxInterviewApplicationService.java +++ b/src/main/java/com/yzdx/AiInterviewer/service/VxService/VxInterviewApplicationService.java @@ -4,5 +4,5 @@ import com.baomidou.mybatisplus.extension.service.IService; import com.yzdx.AiInterviewer.entity.vxEntity.VxInterviewApplication; public interface VxInterviewApplicationService extends IService { - Integer addInterviewApplication(Integer jobId, Integer userId, Integer resumeId, Integer postingId, String companyEncoding, Integer status); + Integer addInterviewApplication(Integer jobId, Integer userId, Integer postingId, String companyEncoding); } diff --git a/src/main/java/com/yzdx/AiInterviewer/service/VxService/impl/VxInterviewApplicationServiceImpl.java b/src/main/java/com/yzdx/AiInterviewer/service/VxService/impl/VxInterviewApplicationServiceImpl.java index ec3b54a..1e269b6 100644 --- a/src/main/java/com/yzdx/AiInterviewer/service/VxService/impl/VxInterviewApplicationServiceImpl.java +++ b/src/main/java/com/yzdx/AiInterviewer/service/VxService/impl/VxInterviewApplicationServiceImpl.java @@ -2,7 +2,9 @@ package com.yzdx.AiInterviewer.service.VxService.impl; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.yzdx.AiInterviewer.entity.Resume; import com.yzdx.AiInterviewer.entity.vxEntity.VxInterviewApplication; +import com.yzdx.AiInterviewer.mapper.ResumeMapper; import com.yzdx.AiInterviewer.mapper.VxMapper.VxInterviewApplicationMapper; import com.yzdx.AiInterviewer.service.VxService.VxInterviewApplicationService; import com.yzdx.AiInterviewer.utiles.TimeUtil; @@ -13,8 +15,11 @@ import org.springframework.stereotype.Service; public class VxInterviewApplicationServiceImpl extends ServiceImpl implements VxInterviewApplicationService { @Autowired private VxInterviewApplicationMapper vxInterviewApplicationMapper; + @Autowired + private ResumeMapper resumeMapper; + @Override - public Integer addInterviewApplication(Integer jobId, Integer userId, Integer resumeId, Integer postingId, String companyEncoding, Integer status) { + public Integer addInterviewApplication(Integer jobId, Integer userId, Integer postingId, String companyEncoding) { LambdaQueryWrapper queryWrapper=new LambdaQueryWrapper<>(); queryWrapper.eq(VxInterviewApplication::getJobId,jobId).eq(VxInterviewApplication::getPostingId,postingId); VxInterviewApplication vxInterviewApplication = vxInterviewApplicationMapper.selectOne(queryWrapper); @@ -26,8 +31,13 @@ public class VxInterviewApplicationServiceImpl extends ServiceImpl queryWrapper1=new LambdaQueryWrapper<>(); + + queryWrapper1.eq(Resume::getUserId,userId); + + Resume resume = resumeMapper.selectOne(queryWrapper1); + vxInterviewApplication1.setResumeId(resume.getId()); vxInterviewApplication1.setCreateTime(TimeUtil.getTime()); vxInterviewApplication1.setUpdateTime(TimeUtil.getTime()); vxInterviewApplication1.setCreateUser(userId); diff --git a/src/main/java/com/yzdx/AiInterviewer/service/impl/InvitePromoteServiceImpl.java b/src/main/java/com/yzdx/AiInterviewer/service/impl/InvitePromoteServiceImpl.java index 61cba74..a81dd72 100644 --- a/src/main/java/com/yzdx/AiInterviewer/service/impl/InvitePromoteServiceImpl.java +++ b/src/main/java/com/yzdx/AiInterviewer/service/impl/InvitePromoteServiceImpl.java @@ -139,7 +139,6 @@ public class InvitePromoteServiceImpl extends ServiceImpl