diff --git a/vetti-admin/src/main/java/com/vetti/web/controller/hotake/HotakeInitScreQuestionsReplyRecordInfoController.java b/vetti-admin/src/main/java/com/vetti/web/controller/hotake/HotakeInitScreQuestionsReplyRecordInfoController.java index 108ab43..e3fec8b 100644 --- a/vetti-admin/src/main/java/com/vetti/web/controller/hotake/HotakeInitScreQuestionsReplyRecordInfoController.java +++ b/vetti-admin/src/main/java/com/vetti/web/controller/hotake/HotakeInitScreQuestionsReplyRecordInfoController.java @@ -4,8 +4,10 @@ import com.vetti.common.annotation.Log; import com.vetti.common.core.controller.BaseController; import com.vetti.common.core.domain.R; import com.vetti.common.core.page.TableDataInfo; +import com.vetti.common.core.page.TableWebDataInfo; import com.vetti.common.enums.BusinessType; import com.vetti.hotake.domain.HotakeInitScreQuestionsReplyRecordInfo; +import com.vetti.hotake.domain.vo.HotakeInitScreQuestionsReplyRecordInfoVo; import com.vetti.hotake.service.IHotakeInitScreQuestionsReplyRecordInfoService; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; @@ -33,11 +35,11 @@ public class HotakeInitScreQuestionsReplyRecordInfoController extends BaseContro */ @ApiOperation("查询初步筛选问题回答记录信息列表") @GetMapping("/getPageList") - public TableDataInfo pageList(HotakeInitScreQuestionsReplyRecordInfo hotakeInitScreQuestionsReplyRecordInfo) + public TableWebDataInfo pageList(HotakeInitScreQuestionsReplyRecordInfo hotakeInitScreQuestionsReplyRecordInfo) { startPage(); List list = hotakeInitScreQuestionsReplyRecordInfoService.selectHotakeInitScreQuestionsReplyRecordInfoList(hotakeInitScreQuestionsReplyRecordInfo); - return getDataTable(list); + return getWebDataTable(list); } /** @@ -95,4 +97,16 @@ public class HotakeInitScreQuestionsReplyRecordInfoController extends BaseContro { return R.ok(hotakeInitScreQuestionsReplyRecordInfoService.deleteHotakeInitScreQuestionsReplyRecordInfoByIds(ids)); } + + + /** + * 初步筛选问题回答记录信息批量保存 + */ + @ApiOperation("初步筛选问题回答记录信息批量保存") + @Log(title = "初步筛选问题回答记录信息批量保存", businessType = BusinessType.INSERT) + @PostMapping("/save") + public R save(@RequestBody HotakeInitScreQuestionsReplyRecordInfoVo initScreQuestionsReplyRecordInfoVo) + { + return R.ok(hotakeInitScreQuestionsReplyRecordInfoService.saveHotakeInitScreQuestionsReplyRecordInfo(initScreQuestionsReplyRecordInfoVo)); + } } diff --git a/vetti-admin/src/main/java/com/vetti/web/controller/hotake/HotakeRolesApplyInfoController.java b/vetti-admin/src/main/java/com/vetti/web/controller/hotake/HotakeRolesApplyInfoController.java new file mode 100644 index 0000000..143f58a --- /dev/null +++ b/vetti-admin/src/main/java/com/vetti/web/controller/hotake/HotakeRolesApplyInfoController.java @@ -0,0 +1,96 @@ +package com.vetti.web.controller.hotake; + +import com.vetti.common.annotation.Log; +import com.vetti.common.core.controller.BaseController; +import com.vetti.common.core.domain.R; +import com.vetti.common.core.page.TableWebDataInfo; +import com.vetti.common.enums.BusinessType; +import com.vetti.hotake.domain.HotakeRolesApplyInfo; +import com.vetti.hotake.service.IHotakeRolesApplyInfoService; +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.*; + +import java.util.List; + +/** + * 候选人岗位申请信息Controller + * + * @author wangxiangshun + * @date 2025-12-17 + */ +@Api(tags ="候选人岗位申请信息") +@RestController +@RequestMapping("/hotake/rolesApplyInfo") +public class HotakeRolesApplyInfoController extends BaseController +{ + @Autowired + private IHotakeRolesApplyInfoService hotakeRolesApplyInfoService; + + /** + * 查询候选人岗位申请信息列表 + */ + @ApiOperation("查询候选人岗位申请信息列表") + @GetMapping("/getPageList") + public TableWebDataInfo pageList(HotakeRolesApplyInfo hotakeRolesApplyInfo) + { + startPage(); + List list = hotakeRolesApplyInfoService.selectHotakeRolesApplyInfoList(hotakeRolesApplyInfo); + return getWebDataTable(list); + } + + /** + * 查询候选人岗位申请信息列表 + */ + @ApiOperation("查询候选人岗位申请信息列表(无分页)") + @GetMapping("/getList") + public R> list(HotakeRolesApplyInfo hotakeRolesApplyInfo) + { + List list = hotakeRolesApplyInfoService.selectHotakeRolesApplyInfoList(hotakeRolesApplyInfo); + return R.ok(list,""); + } + + /** + * 获取候选人岗位申请信息详细信息 + */ + @ApiOperation("获取候选人岗位申请信息详细信息") + @GetMapping(value = "/{id}") + public R getInfo(@PathVariable("id") Long id) + { + return R.ok(hotakeRolesApplyInfoService.selectHotakeRolesApplyInfoById(id),""); + } + + /** + * 新增候选人岗位申请信息 + */ + @ApiOperation("新增候选人岗位申请信息") + @Log(title = "候选人岗位申请信息", businessType = BusinessType.INSERT) + @PostMapping + public R add(@RequestBody HotakeRolesApplyInfo hotakeRolesApplyInfo) + { + return R.ok(hotakeRolesApplyInfoService.insertHotakeRolesApplyInfo(hotakeRolesApplyInfo)); + } + + /** + * 修改候选人岗位申请信息 + */ + @ApiOperation("修改候选人岗位申请信息") + @Log(title = "候选人岗位申请信息", businessType = BusinessType.UPDATE) + @PutMapping + public R edit(@RequestBody HotakeRolesApplyInfo hotakeRolesApplyInfo) + { + return R.ok(hotakeRolesApplyInfoService.updateHotakeRolesApplyInfo(hotakeRolesApplyInfo)); + } + + /** + * 删除候选人岗位申请信息 + */ + @ApiOperation("删除候选人岗位申请信息") + @Log(title = "候选人岗位申请信息", businessType = BusinessType.DELETE) + @DeleteMapping("/{ids}") + public R remove(@PathVariable Long[] ids) + { + return R.ok(hotakeRolesApplyInfoService.deleteHotakeRolesApplyInfoByIds(ids)); + } +} diff --git a/vetti-admin/src/main/java/com/vetti/web/controller/hotake/HotakeRolesInfoController.java b/vetti-admin/src/main/java/com/vetti/web/controller/hotake/HotakeRolesInfoController.java index 78324bd..de94157 100644 --- a/vetti-admin/src/main/java/com/vetti/web/controller/hotake/HotakeRolesInfoController.java +++ b/vetti-admin/src/main/java/com/vetti/web/controller/hotake/HotakeRolesInfoController.java @@ -61,7 +61,7 @@ public class HotakeRolesInfoController extends BaseController /** * 查询岗位信息列表 */ - @ApiOperation("查询岗位信息列表") + @ApiOperation("查询岗位信息列表(首页)") @GetMapping("/home/getPageList") public TableWebDataInfo listHomePage(HotakeRolesInfo hotakeRolesInfo) { @@ -73,7 +73,7 @@ public class HotakeRolesInfoController extends BaseController /** * 查询岗位信息列表(无分页) */ - @ApiOperation("查询岗位信息列表(无分页)") + @ApiOperation("查询岗位信息列表(无分页-首页)") @GetMapping("/home/getList") public R> listHome(HotakeRolesInfo hotakeRolesInfo) { diff --git a/vetti-admin/src/main/java/com/vetti/web/controller/system/VerificationController.java b/vetti-admin/src/main/java/com/vetti/web/controller/system/VerificationController.java index 0574f69..ca49305 100644 --- a/vetti-admin/src/main/java/com/vetti/web/controller/system/VerificationController.java +++ b/vetti-admin/src/main/java/com/vetti/web/controller/system/VerificationController.java @@ -3,6 +3,7 @@ package com.vetti.web.controller.system; import cn.hutool.core.collection.CollectionUtil; import com.vetti.common.core.controller.BaseController; import com.vetti.common.core.domain.AjaxResult; +import com.vetti.common.core.domain.R; import com.vetti.common.core.domain.entity.SysUser; import com.vetti.common.exception.ServiceException; import com.vetti.common.service.verification.VerificationService; @@ -61,13 +62,14 @@ public class VerificationController extends BaseController { /** * 验证邮箱验证码 */ + @ApiOperation("验证邮箱验证码") @PostMapping("/email/verify") - public AjaxResult verifyCode(@RequestParam String email, @RequestParam String code) { + public R verifyCode(@RequestParam String email, @RequestParam String code) { boolean isValid = verificationEmailService.verifyCode(email, code); if (isValid) { - return AjaxResult.success(MessageUtils.messageCustomize("systemVerificationEmailController10003")); + return R.ok(MessageUtils.messageCustomize("systemVerificationEmailController10003")); } else { - return AjaxResult.error(MessageUtils.messageCustomize("systemVerificationEmailController10004")); + return R.fail(MessageUtils.messageCustomize("systemVerificationEmailController10004")); } } diff --git a/vetti-admin/target/classes/i18n/messages.properties b/vetti-admin/target/classes/i18n/messages.properties index e0f19b9..9f8bd4a 100644 --- a/vetti-admin/target/classes/i18n/messages.properties +++ b/vetti-admin/target/classes/i18n/messages.properties @@ -1,39 +1,39 @@ #错误消息 -not.null=* 必须填写 -user.jcaptcha.error=验证码错误 -user.jcaptcha.expire=验证码已失效 -user.not.exists=User does not exist/password incorrect -user.password.not.match=User does not exist/password incorrect -user.password.retry.limit.count=密码输入错误{0}次 -user.password.retry.limit.exceed=密码输入错误{0}次,帐户锁定{1}分钟 -user.password.delete=对不起,您的账号已被删除 -user.blocked=用户已封禁,请联系管理员 -role.blocked=角色已封禁,请联系管理员 -login.blocked=很遗憾,访问IP已被列入系统黑名单 -user.logout.success=退出成功 +not.null=* Required +user.jcaptcha.error=Incorrect verification code +user.jcaptcha.expire=The verification code has expired +user.not.exists=Account Or Password Error +user.password.not.match=Account Or Password Error +user.password.retry.limit.count=Password input error {0} times +user.password.retry.limit.exceed=Password input error {0} times, account locked for {1} minutes +user.password.delete=Sorry, your account has been deleted +user.blocked=The user has been banned, please contact the administrator +role.blocked=The role has been banned, please contact the administrator +login.blocked=Unfortunately, the access IP has been blacklisted by the system +user.logout.success=Exit successful -length.not.valid=长度必须在{min}到{max}个字符之间 +length.not.valid=The length must be between {min} and {max} characters -user.username.not.valid=* 2到20个汉字、字母、数字或下划线组成,且必须以非数字开头 -user.password.not.valid=* 5-50个字符 +user.username.not.valid=* Composed of 2 to 20 Chinese characters, letters, numbers, or underscores, and must start with a non numeric character +user.password.not.valid=* 5-50 characters -user.email.not.valid=邮箱格式错误 -user.mobile.phone.number.not.valid=手机号格式错误 -user.login.success=登录成功 -user.register.success=注册成功 -user.notfound=请重新登录 -user.forcelogout=管理员强制退出,请重新登录 -user.unknown.error=未知错误,请重新登录 +user.email.not.valid=Email format error +user.mobile.phone.number.not.valid=Phone number format error +user.login.success=Login successful +user.register.success=registered successfully +user.notfound=Please log in again +user.forcelogout=Administrator forced logout, please log in again +user.unknown.error=Unknown error, please log in again ##文件上传消息 -upload.exceed.maxSize=上传的文件大小超出限制的文件大小!
允许的文件最大大小是:{0}MB! -upload.filename.exceed.length=上传的文件名最长{0}个字符 +upload.exceed.maxSize=The uploaded file size exceeds the limit! The maximum allowed file size is: {0}MB ! +upload.filename.exceed.length=The maximum length of the uploaded file name is {0} characters ##权限 -no.permission=您没有数据的权限,请联系管理员添加权限 [{0}] -no.create.permission=您没有创建数据的权限,请联系管理员添加权限 [{0}] -no.update.permission=您没有修改数据的权限,请联系管理员添加权限 [{0}] -no.delete.permission=您没有删除数据的权限,请联系管理员添加权限 [{0}] -no.export.permission=您没有导出数据的权限,请联系管理员添加权限 [{0}] -no.view.permission=您没有查看数据的权限,请联系管理员添加权限 [{0}] +no.permission=You do not have permission to access the data. Please contact the administrator to add permission [{0}] +no.create.permission=You do not have permission to create data. Please contact the administrator to add permission [{0}] +no.update.permission=You do not have permission to modify data. Please contact the administrator to add permission [{0}] +no.delete.permission=You do not have permission to delete data. Please contact the administrator to add permission [{0}] +no.export.permission=You do not have permission to export data. Please contact the administrator to add permission [{0}] +no.view.permission=You do not have permission to view data. Please contact the administrator to add permission [{0}] diff --git a/vetti-common/src/main/java/com/vetti/common/core/controller/BaseController.java b/vetti-common/src/main/java/com/vetti/common/core/controller/BaseController.java index 852fe35..4be7d33 100644 --- a/vetti-common/src/main/java/com/vetti/common/core/controller/BaseController.java +++ b/vetti-common/src/main/java/com/vetti/common/core/controller/BaseController.java @@ -226,7 +226,7 @@ public class BaseController TableWebDataInfo rspData = new TableWebDataInfo(); rspData.setCode(HttpStatus.SUCCESS); rspData.setSuccess(true); - rspData.setMessage(MessageUtils.messageCustomize("systemR10001")); + rspData.setMessage(""); rspData.setData(list); rspData.setTotal(new PageInfo(list).getTotal()); rspData.setPages(new PageInfo(list).getPages()); diff --git a/vetti-hotakes/src/main/java/com/vetti/hotake/domain/HotakeRolesApplyInfo.java b/vetti-hotakes/src/main/java/com/vetti/hotake/domain/HotakeRolesApplyInfo.java new file mode 100644 index 0000000..31ce8e8 --- /dev/null +++ b/vetti-hotakes/src/main/java/com/vetti/hotake/domain/HotakeRolesApplyInfo.java @@ -0,0 +1,116 @@ +package com.vetti.hotake.domain; + +import java.math.BigDecimal; +import lombok.Data; +import lombok.experimental.Accessors; +import io.swagger.annotations.ApiModelProperty; +import com.vetti.common.annotation.Excel; +import com.vetti.common.core.domain.BaseEntity; + +/** + * 候选人岗位申请信息对象 hotake_roles_apply_info + * + * @author wangxiangshun + * @date 2025-12-17 + */ +@Data +@Accessors(chain = true) +public class HotakeRolesApplyInfo extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 主键ID */ + @ApiModelProperty("主键ID") + private Long id; + + /** 候选人ID */ + @ApiModelProperty("候选人ID") + @Excel(name = "候选人ID") + private Long candidateId; + + /** 岗位ID */ + @ApiModelProperty("岗位ID") + @Excel(name = "岗位ID") + private Long roleId; + + /** 姓名 */ + @ApiModelProperty("姓名") + @Excel(name = "姓名") + private String fullName; + + /** 邮箱 */ + @ApiModelProperty("邮箱") + @Excel(name = "邮箱") + private String email; + + /** 手机号 */ + @ApiModelProperty("手机号") + @Excel(name = "手机号") + private String phoneNumber; + + /** CV 简历文件地址 */ + @ApiModelProperty("CV 简历文件地址") + @Excel(name = "CV 简历文件地址") + private String cvFile; + + /** 简历类型(如:image/jpeg, application/pdf等) */ + @ApiModelProperty("简历文件后缀(doc/pdf)") + private String cvFileSuffix; + + @ApiModelProperty("简历文件大小") + private String fileSizeShow; + + /** 求职信 */ + @ApiModelProperty("求职信") + @Excel(name = "求职信") + private String coverLetter; + + /** 候选人状态(Hot、Warm、Cold、Pending) */ + @ApiModelProperty("候选人状态(Hot、Warm、Cold、Pending)") + private String candidateStatus; + + /** 当前阶段 */ + @ApiModelProperty("当前阶段") + @Excel(name = "当前阶段") + private String stage; + + /** 最后联系时间 */ + @ApiModelProperty("最后联系时间") + @Excel(name = "最后联系时间") + private String lastContact; + + /** 简历模版Json */ + @ApiModelProperty("简历模版Json") + @Excel(name = "简历模版Json") + private String cvTemplateJson; + + /** 简历评分以及说明 */ + @ApiModelProperty("简历评分以及说明") + @Excel(name = "简历评分以及说明") + private String cvScore; + + /** 简历文件Hash */ + @ApiModelProperty("简历文件Hash") + @Excel(name = "简历文件Hash") + private String cvMd5; + + /** 工作经验 */ + @ApiModelProperty("工作经验") + @Excel(name = "工作经验") + private String experience; + + /** AI评分 */ + @ApiModelProperty("AI评分") + @Excel(name = "AI评分") + private String aiMatchScore; + + /** AI评分百分比 */ + @ApiModelProperty("AI评分百分比") + @Excel(name = "AI评分百分比") + private BigDecimal aiMatchScorePercentage; + + /** 删除状态(0正常 2删除) */ + @ApiModelProperty("删除状态(0正常 2删除)") + private String delFlag; + +} diff --git a/vetti-hotakes/src/main/java/com/vetti/hotake/domain/vo/HotakeInitScreQuestionsReplyRecordInfoVo.java b/vetti-hotakes/src/main/java/com/vetti/hotake/domain/vo/HotakeInitScreQuestionsReplyRecordInfoVo.java new file mode 100644 index 0000000..24434ac --- /dev/null +++ b/vetti-hotakes/src/main/java/com/vetti/hotake/domain/vo/HotakeInitScreQuestionsReplyRecordInfoVo.java @@ -0,0 +1,31 @@ +package com.vetti.hotake.domain.vo; + +import com.vetti.common.annotation.Excel; +import com.vetti.hotake.domain.HotakeInitScreQuestionsReplyRecordInfo; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; +import lombok.experimental.Accessors; + +import java.util.List; + +/** + * 初步筛选问题回答记录信息对象 + * + * @author wangxiangshun + * @date 2025-12-14 + */ +@Data +@Accessors(chain = true) +public class HotakeInitScreQuestionsReplyRecordInfoVo { + + @ApiModelProperty("岗位申请ID") + private Long roleApplyId; + + /** 岗位ID */ + @ApiModelProperty("岗位ID") + @Excel(name = "岗位ID") + private Long roleId; + + @ApiModelProperty("初步筛选问题回答记录数据集合") + private List initScreQuestionsReplyRecordInfoList; +} diff --git a/vetti-hotakes/src/main/java/com/vetti/hotake/mapper/HotakeInitScreQuestionsReplyRecordInfoMapper.java b/vetti-hotakes/src/main/java/com/vetti/hotake/mapper/HotakeInitScreQuestionsReplyRecordInfoMapper.java index 33c9eae..dc485ae 100644 --- a/vetti-hotakes/src/main/java/com/vetti/hotake/mapper/HotakeInitScreQuestionsReplyRecordInfoMapper.java +++ b/vetti-hotakes/src/main/java/com/vetti/hotake/mapper/HotakeInitScreQuestionsReplyRecordInfoMapper.java @@ -58,6 +58,15 @@ public interface HotakeInitScreQuestionsReplyRecordInfoMapper * @return 结果 */ public int deleteHotakeInitScreQuestionsReplyRecordInfoByIds(Long[] ids); + + + /** + * 删除初步筛选问题回答记录信息 + * + * @param roleApplyId 岗位申请ID + * @return 结果 + */ + public int deleteHotakeInitScreQuestionsReplyRecordInfoByRoleApplyId(Long roleApplyId); /** * 批量新增初步筛选问题回答记录信息 * diff --git a/vetti-hotakes/src/main/java/com/vetti/hotake/mapper/HotakeRolesApplyInfoMapper.java b/vetti-hotakes/src/main/java/com/vetti/hotake/mapper/HotakeRolesApplyInfoMapper.java new file mode 100644 index 0000000..201ea79 --- /dev/null +++ b/vetti-hotakes/src/main/java/com/vetti/hotake/mapper/HotakeRolesApplyInfoMapper.java @@ -0,0 +1,69 @@ +package com.vetti.hotake.mapper; + +import java.util.List; +import com.vetti.hotake.domain.HotakeRolesApplyInfo; + +/** + * 候选人岗位申请信息Mapper接口 + * + * @author wangxiangshun + * @date 2025-12-17 + */ +public interface HotakeRolesApplyInfoMapper +{ + /** + * 查询候选人岗位申请信息 + * + * @param id 候选人岗位申请信息主键 + * @return 候选人岗位申请信息 + */ + public HotakeRolesApplyInfo selectHotakeRolesApplyInfoById(Long id); + + /** + * 查询候选人岗位申请信息列表 + * + * @param hotakeRolesApplyInfo 候选人岗位申请信息 + * @return 候选人岗位申请信息集合 + */ + public List selectHotakeRolesApplyInfoList(HotakeRolesApplyInfo hotakeRolesApplyInfo); + + /** + * 新增候选人岗位申请信息 + * + * @param hotakeRolesApplyInfo 候选人岗位申请信息 + * @return 结果 + */ + public int insertHotakeRolesApplyInfo(HotakeRolesApplyInfo hotakeRolesApplyInfo); + + /** + * 修改候选人岗位申请信息 + * + * @param hotakeRolesApplyInfo 候选人岗位申请信息 + * @return 结果 + */ + public int updateHotakeRolesApplyInfo(HotakeRolesApplyInfo hotakeRolesApplyInfo); + + /** + * 删除候选人岗位申请信息 + * + * @param id 候选人岗位申请信息主键 + * @return 结果 + */ + public int deleteHotakeRolesApplyInfoById(Long id); + + /** + * 批量删除候选人岗位申请信息 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + public int deleteHotakeRolesApplyInfoByIds(Long[] ids); + /** + * 批量新增候选人岗位申请信息 + * + * @param hotakeRolesApplyInfoList 候选人岗位申请信息列表 + * @return 结果 + */ + public int batchInsertHotakeRolesApplyInfo(List hotakeRolesApplyInfoList); + +} diff --git a/vetti-hotakes/src/main/java/com/vetti/hotake/service/IHotakeInitScreQuestionsReplyRecordInfoService.java b/vetti-hotakes/src/main/java/com/vetti/hotake/service/IHotakeInitScreQuestionsReplyRecordInfoService.java index 6c7d0fa..0a26a96 100644 --- a/vetti-hotakes/src/main/java/com/vetti/hotake/service/IHotakeInitScreQuestionsReplyRecordInfoService.java +++ b/vetti-hotakes/src/main/java/com/vetti/hotake/service/IHotakeInitScreQuestionsReplyRecordInfoService.java @@ -2,6 +2,7 @@ package com.vetti.hotake.service; import java.util.List; import com.vetti.hotake.domain.HotakeInitScreQuestionsReplyRecordInfo; +import com.vetti.hotake.domain.vo.HotakeInitScreQuestionsReplyRecordInfoVo; /** * 初步筛选问题回答记录信息Service接口 @@ -67,4 +68,13 @@ public interface IHotakeInitScreQuestionsReplyRecordInfoService */ public int batchInsertHotakeInitScreQuestionsReplyRecordInfo(List hotakeInitScreQuestionsReplyRecordInfoList); + + /** + * 初步筛选问题回答记录信息批量保存 + * + * @param initScreQuestionsReplyRecordInfoVo 初步筛选问题回答记录信息数据 + * @return 结果 + */ + public int saveHotakeInitScreQuestionsReplyRecordInfo(HotakeInitScreQuestionsReplyRecordInfoVo initScreQuestionsReplyRecordInfoVo); + } diff --git a/vetti-hotakes/src/main/java/com/vetti/hotake/service/IHotakeRolesApplyInfoService.java b/vetti-hotakes/src/main/java/com/vetti/hotake/service/IHotakeRolesApplyInfoService.java new file mode 100644 index 0000000..59629db --- /dev/null +++ b/vetti-hotakes/src/main/java/com/vetti/hotake/service/IHotakeRolesApplyInfoService.java @@ -0,0 +1,70 @@ +package com.vetti.hotake.service; + +import java.util.List; +import com.vetti.hotake.domain.HotakeRolesApplyInfo; + +/** + * 候选人岗位申请信息Service接口 + * + * @author wangxiangshun + * @date 2025-12-17 + */ +public interface IHotakeRolesApplyInfoService +{ + /** + * 查询候选人岗位申请信息 + * + * @param id 候选人岗位申请信息主键 + * @return 候选人岗位申请信息 + */ + public HotakeRolesApplyInfo selectHotakeRolesApplyInfoById(Long id); + + /** + * 查询候选人岗位申请信息列表 + * + * @param hotakeRolesApplyInfo 候选人岗位申请信息 + * @return 候选人岗位申请信息集合 + */ + public List selectHotakeRolesApplyInfoList(HotakeRolesApplyInfo hotakeRolesApplyInfo); + + /** + * 新增候选人岗位申请信息 + * + * @param hotakeRolesApplyInfo 候选人岗位申请信息 + * @return 结果 + */ + public HotakeRolesApplyInfo insertHotakeRolesApplyInfo(HotakeRolesApplyInfo hotakeRolesApplyInfo); + + /** + * 修改候选人岗位申请信息 + * + * @param hotakeRolesApplyInfo 候选人岗位申请信息 + * @return 结果 + */ + public HotakeRolesApplyInfo updateHotakeRolesApplyInfo(HotakeRolesApplyInfo hotakeRolesApplyInfo); + + /** + * 批量删除候选人岗位申请信息 + * + * @param ids 需要删除的候选人岗位申请信息主键集合 + * @return 结果 + */ + public int deleteHotakeRolesApplyInfoByIds(Long[] ids); + + /** + * 删除候选人岗位申请信息信息 + * + * @param id 候选人岗位申请信息主键 + * @return 结果 + */ + public int deleteHotakeRolesApplyInfoById(Long id); + + /** + * 批量新增候选人岗位申请信息 + * + * @param hotakeRolesApplyInfoList 候选人岗位申请信息列表 + * @return 结果 + */ + public int batchInsertHotakeRolesApplyInfo(List hotakeRolesApplyInfoList); + +} diff --git a/vetti-hotakes/src/main/java/com/vetti/hotake/service/impl/HotakeCvInfoServiceImpl.java b/vetti-hotakes/src/main/java/com/vetti/hotake/service/impl/HotakeCvInfoServiceImpl.java index 43c399f..84d3601 100644 --- a/vetti-hotakes/src/main/java/com/vetti/hotake/service/impl/HotakeCvInfoServiceImpl.java +++ b/vetti-hotakes/src/main/java/com/vetti/hotake/service/impl/HotakeCvInfoServiceImpl.java @@ -443,11 +443,6 @@ public class HotakeCvInfoServiceImpl extends BaseServiceImpl implements IHotakeC return resultMsg; } - public static void main(String[] args){ - String md5s = MD5.create().digestHex16("You are a construction industry interview expert. Evaluate candidate responses and provide scores (1-5) and follow-up questions when needed. Always respond in JSON format.You are a construction industry interview expert. Evaluate candidate responses and provide scores (1-5) and follow-up questions when needed. Always respond in JSON format.You are a construction industry interview expert. Evaluate candidate responses and provide scores (1-5) and follow-up questions when needed. Always respond in JSON format.You are a construction industry interview expert. Evaluate candidate responses and provide scores (1-5) and follow-up questions when needed. Always respond in JSON format.You are a construction industry interview expert. Evaluate candidate responses and provide scores (1-5) and follow-up questions when needed. Always respond in JSON format.You are a construction industry interview expert. Evaluate candidate responses and provide scores (1-5) and follow-up questions when needed. Always respond in JSON format.You are a construction industry interview expert. Evaluate candidate responses and provide scores (1-5) and follow-up questions when needed. Always respond in JSON format.You are a construction industry interview expert. Evaluate candidate responses and provide scores (1-5) and follow-up questions when needed. Always respond in JSON format.You are a construction industry interview expert. Evaluate candidate responses and provide scores (1-5) and follow-up questions when needed. Always respond in JSON format.You are a construction industry interview expert. Evaluate candidate responses and provide scores (1-5) and follow-up questions when needed. Always respond in JSON format."); - System.out.println(md5s); - String md5s1 = MD5.create().digestHex16("You 1are a construction industry interview expert. Evaluate candidate responses and provide scores (1-5) and follow-up questions when needed. Always respond in JSON format.You are a construction industry interview expert. Evaluate candidate responses and provide scores (1-5) and follow-up questions when needed. Always respond in JSON format.You are a construction industry interview expert. Evaluate candidate responses and provide scores (1-5) and follow-up questions when needed. Always respond in JSON format.You are a construction industry interview expert. Evaluate candidate responses and provide scores (1-5) and follow-up questions when needed. Always respond in JSON format.You are a construction industry interview expert. Evaluate candidate responses and provide scores (1-5) and follow-up questions when needed. Always respond in JSON format.You are a construction industry interview expert. Evaluate candidate responses and provide scores (1-5) and follow-up questions when needed. Always respond in JSON format.You are a construction industry interview expert. Evaluate candidate responses and provide scores (1-5) and follow-up questions when needed. Always respond in JSON format.You are a construction industry interview expert. Evaluate candidate responses and provide scores (1-5) and follow-up questions when needed. Always respond in JSON format.You are a construction industry interview expert. Evaluate candidate responses and provide scores (1-5) and follow-up questions when needed. Always respond in JSON format.You are a construction industry interview expert. Evaluate candidate responses and provide scores (1-5) and follow-up questions when needed. Always respond in JSON format."); - System.out.println(md5s1); - } + } diff --git a/vetti-hotakes/src/main/java/com/vetti/hotake/service/impl/HotakeInitScreQuestionsReplyRecordInfoServiceImpl.java b/vetti-hotakes/src/main/java/com/vetti/hotake/service/impl/HotakeInitScreQuestionsReplyRecordInfoServiceImpl.java index cd3e583..dc664fe 100644 --- a/vetti-hotakes/src/main/java/com/vetti/hotake/service/impl/HotakeInitScreQuestionsReplyRecordInfoServiceImpl.java +++ b/vetti-hotakes/src/main/java/com/vetti/hotake/service/impl/HotakeInitScreQuestionsReplyRecordInfoServiceImpl.java @@ -1,9 +1,33 @@ package com.vetti.hotake.service.impl; +import java.io.InputStream; +import java.util.HashMap; +import java.util.LinkedList; import java.util.List; +import java.util.Map; +import cn.hutool.core.collection.CollectionUtil; +import cn.hutool.core.util.StrUtil; +import cn.hutool.crypto.digest.MD5; +import cn.hutool.json.JSONUtil; +import com.vetti.common.ai.gpt.ChatGPTClient; import com.vetti.common.core.service.BaseServiceImpl; +import com.vetti.common.enums.FillTypeEnum; +import com.vetti.common.enums.MinioBucketNameEnum; import com.vetti.common.utils.DateUtils; +import com.vetti.common.utils.SecurityUtils; +import com.vetti.common.utils.readFile.FileContentUtil; +import com.vetti.hotake.domain.HotakeCvInfo; +import com.vetti.hotake.domain.HotakeProblemBaseInfo; +import com.vetti.hotake.domain.HotakeRolesApplyInfo; +import com.vetti.hotake.domain.dto.HotakeCvInfoDto; +import com.vetti.hotake.domain.dto.VcDto.*; +import com.vetti.hotake.domain.vo.HotakeInitScreQuestionsReplyRecordInfoVo; +import com.vetti.hotake.mapper.HotakeCvInfoMapper; +import com.vetti.hotake.mapper.HotakeRolesApplyInfoMapper; +import io.minio.GetObjectArgs; +import io.minio.MinioClient; +import lombok.extern.slf4j.Slf4j; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; @@ -18,6 +42,7 @@ import com.vetti.hotake.service.IHotakeInitScreQuestionsReplyRecordInfoService; * @author wangxiangshun * @date 2025-12-14 */ +@Slf4j @SuppressWarnings("all") @Service public class HotakeInitScreQuestionsReplyRecordInfoServiceImpl extends BaseServiceImpl implements IHotakeInitScreQuestionsReplyRecordInfoService @@ -25,6 +50,19 @@ public class HotakeInitScreQuestionsReplyRecordInfoServiceImpl extends BaseServi @Autowired private HotakeInitScreQuestionsReplyRecordInfoMapper hotakeInitScreQuestionsReplyRecordInfoMapper; + @Autowired + private HotakeRolesApplyInfoMapper hotakeRolesApplyInfoMapper; + + @Autowired + private HotakeCvInfoMapper hotakeCvInfoMapper; + + @Autowired + private MinioClient minioClient; + + @Autowired + private ChatGPTClient chatGPTClient; + + /** * 查询初步筛选问题回答记录信息 * @@ -115,4 +153,242 @@ public class HotakeInitScreQuestionsReplyRecordInfoServiceImpl extends BaseServi public int batchInsertHotakeInitScreQuestionsReplyRecordInfo(List hotakeInitScreQuestionsReplyRecordInfoList){ return hotakeInitScreQuestionsReplyRecordInfoMapper.batchInsertHotakeInitScreQuestionsReplyRecordInfo(hotakeInitScreQuestionsReplyRecordInfoList); } + + /** + * 初步筛选问题回答记录信息批量保存 + * @param initScreQuestionsReplyRecordInfoList 初步筛选问题回答记录信息数据集合 + * @return + */ + @Override + public int saveHotakeInitScreQuestionsReplyRecordInfo(HotakeInitScreQuestionsReplyRecordInfoVo initScreQuestionsReplyRecordInfoVo) { + //先删除对应问题答案记录数据 + hotakeInitScreQuestionsReplyRecordInfoMapper.deleteHotakeInitScreQuestionsReplyRecordInfoByRoleApplyId(initScreQuestionsReplyRecordInfoVo.getRoleApplyId()); + //批量保存数据 + if (CollectionUtil.isNotEmpty(initScreQuestionsReplyRecordInfoVo.getInitScreQuestionsReplyRecordInfoList())) { + for (HotakeInitScreQuestionsReplyRecordInfo recordInfo : initScreQuestionsReplyRecordInfoVo.getInitScreQuestionsReplyRecordInfoList()) { + recordInfo.setCandidateId(SecurityUtils.getUserId()).setRoleId(initScreQuestionsReplyRecordInfoVo.getRoleApplyId()); + recordInfo.setRoleApplyId(initScreQuestionsReplyRecordInfoVo.getRoleApplyId()); + fill(FillTypeEnum.INSERT.getCode(), recordInfo); + } + batchInsertHotakeInitScreQuestionsReplyRecordInfo(initScreQuestionsReplyRecordInfoVo.getInitScreQuestionsReplyRecordInfoList()); + } + //获取申请的简历数据 + HotakeRolesApplyInfo applyInfo = hotakeRolesApplyInfoMapper.selectHotakeRolesApplyInfoById(initScreQuestionsReplyRecordInfoVo.getRoleApplyId()); + if (applyInfo != null) { + //查询候选人的当前最新简历信息 + HotakeCvInfo queryCv = new HotakeCvInfo(); + queryCv.setUserId(SecurityUtils.getUserId()); + queryCv.setCvFileType("cv"); + List cvInfos = hotakeCvInfoMapper.selectHotakeCvInfoList(queryCv); + HotakeCvInfo cvInfo = null; + if(CollectionUtil.isNotEmpty(cvInfos)) { + cvInfo = cvInfos.get(0); + } + //解析简历内容以及获取简历对应的评分数据 + log.info("开始处理简历"); + try { + InputStream inputStream = minioClient.getObject( + GetObjectArgs.builder() + .bucket(MinioBucketNameEnum.CV.getCode()) + .object(applyInfo.getCvFile()) + .build()); + String contents = FileContentUtil.readFileContent(inputStream, applyInfo.getCvFileSuffix()); + log.info("简历信息:{}", contents); + //验证文件内容是否改变,如果未改变不进行模型解析直接返回原有结果 + String md5Hash = MD5.create().digestHex16(contents); + if (StrUtil.isNotEmpty(md5Hash) && cvInfo != null && md5Hash.equals(cvInfo.getCvMd5())) { + //直接获取简历表中的简历解析的详细数据 + applyInfo.setCvScore(cvInfo.getCvScore()); + applyInfo.setCvTemplateJson(cvInfo.getCvTemplateJson()); + fill(FillTypeEnum.UPDATE.getCode(), applyInfo); + applyInfo.setCvMd5(md5Hash); + }else{ + //生成简历模版数据信息 + HotakeCvInfoDto cvInfoDto = handleAnalysisCvInfo(contents); + //生成对应的简历评分 + String resultMsg = handleHotakeCvInfoScore(cvInfoDto); + applyInfo.setCvScore(resultMsg); + applyInfo.setCvTemplateJson(JSONUtil.toJsonStr(cvInfoDto)); + fill(FillTypeEnum.UPDATE.getCode(), cvInfo); + applyInfo.setCvMd5(md5Hash); + } + //更新岗位申请数据记录 + applyInfo.setCandidateStatus("Pending"); + applyInfo.setStage(""); + hotakeRolesApplyInfoMapper.updateHotakeRolesApplyInfo(applyInfo); + } catch (Exception e) { + e.printStackTrace(); + } + return 0; + } + return 0; + } + + + + /** + * 简历解析数据 + * + * @param contents + * @return + */ + private HotakeCvInfoDto handleAnalysisCvInfo(String contents) { + log.info("开始简历解析"); + try { + List> list = new LinkedList(); + Map entity = new HashMap<>(); + entity.put("role","user"); + entity.put("content","从下面提供的文本中提取所有能识别到的简历信息,只提取原文中存在的内容,不要补充、不推测、不总结。需要提取的字段包括:name(姓名或人名)、phone(电话号码)、email(电子邮件地址)、position(岗位或者简历中自己期望的职位等)、location(地点或者地址、家庭住址)、links(所有链接地址)、currentWork(当前工作公司)、about(关于我/自我介绍)、skills_tools(关键资格(许可证、注册/会员资格、认证))、languages(语言能力,主要就是Languages下面的语言)、experience(工作经历,除了title、company、location、durationStart、durationEnd,其他的都放到description里面,并且description里面要根据换行符分成不同的content),日期要拆分成开始时间(durationStart)和结束时间(durationEnd))、education(教育经历,日期要拆分成开始时间(durationStart)和结束时间(durationEnd))。请将提取结果以结构化 JSON 格式返回,格式如下:{ \\\"name\\\": \\\"\\\", \\\"phone\\\": \\\"\\\", \\\"currentWork\\\": \\\"\\\", \\\"position\\\": \\\"\\\", \\\"location\\\": \\\"\\\", \\\"email\\\": \\\"\\\", \\\"links\\\": [{\\\"content\\\":\\\"\\\"}], \\\"about\\\": \\\"\\\", \\\"skillsTools\\\": [{\\\"content\\\":\\\"\\\"}], \\\"languages\\\": [{\\\"content\\\":\\\"\\\"}], \\\"experience\\\": [{\\\"title\\\": \\\"\\\", \\\"company\\\": \\\"\\\",\\\"location\\\": \\\"\\\",\\\"durationStart\\\": \\\"\\\",\\\"durationEnd\\\": \\\"\\\",\\\"description\\\": [{\\\"content\\\":\\\"\\\"}]}], \\\"education\\\": [{\\\"degree\\\": \\\"\\\",\\\"institution\\\": \\\"\\\",\\\"durationStart\\\": \\\"\\\",\\\"durationEnd\\\": \\\"\\\"}] }。字段不存在则返回 null 或空数组。只返回标准可解析的 JSON结构 ,不要多余的```json等信息,不要解释说明,不要改写内容。以下为待处理文本:"+contents); + //根据AI做 + list.add(entity); + String resultCv = chatGPTClient.handleAiChat(JSONUtil.toJsonStr(list), "JX"); + log.info("开始返回简历解析结果:{}", resultCv); + HotakeCvInfoDto cvInfoDto = JSONUtil.toBean(resultCv, HotakeCvInfoDto.class); + //数据添加默认值 + if(cvInfoDto != null){ + if(StrUtil.isEmpty(cvInfoDto.getName())){ + cvInfoDto.setName("-"); + } + if(StrUtil.isEmpty(cvInfoDto.getPhone())){ + cvInfoDto.setPhone("-"); + } + if(StrUtil.isEmpty(cvInfoDto.getEmail())){ + cvInfoDto.setEmail("-"); + } + if(StrUtil.isEmpty(cvInfoDto.getPosition())){ + cvInfoDto.setPosition("-"); + } + if(StrUtil.isEmpty(cvInfoDto.getLocation())){ + cvInfoDto.setLocation("-"); + } + if(StrUtil.isEmpty(cvInfoDto.getAbout())){ + cvInfoDto.setAbout("-"); + } + if (StrUtil.isEmpty(cvInfoDto.getCurrentWork())){ + cvInfoDto.setCurrentWork("-"); + } + if(CollectionUtil.isNotEmpty(cvInfoDto.getSkillsTools())){ + for (VcSkillsToolsDto toolsDto :cvInfoDto.getSkillsTools()) { + if(StrUtil.isEmpty(toolsDto.getContent())){ + toolsDto.setContent("-"); + } + } + } + if(CollectionUtil.isNotEmpty(cvInfoDto.getLinks())){ + for (VcLinksDto linksDto :cvInfoDto.getLinks()) { + if(StrUtil.isEmpty(linksDto.getContent())){ + linksDto.setContent("-"); + } + } + } + + if(CollectionUtil.isNotEmpty(cvInfoDto.getLanguages())){ + for (VcLanguagesDto languagesDto :cvInfoDto.getLanguages()) { + if(StrUtil.isEmpty(languagesDto.getContent())){ + languagesDto.setContent("-"); + } + } + } + + if(CollectionUtil.isNotEmpty(cvInfoDto.getExperience())){ + for (VcExperienceDto experienceDto :cvInfoDto.getExperience()) { + if (StrUtil.isEmpty(experienceDto.getTitle())){ + experienceDto.setTitle("-"); + } + if(StrUtil.isEmpty(experienceDto.getCompany())){ + experienceDto.setCompany("-"); + } + if(StrUtil.isEmpty(experienceDto.getLocation())){ + experienceDto.setLocation("-"); + } + if(StrUtil.isEmpty(experienceDto.getDurationStart())){ + experienceDto.setDurationStart("-"); + } + if(StrUtil.isEmpty(experienceDto.getDurationEnd())){ + experienceDto.setDurationEnd("-"); + } + if (CollectionUtil.isNotEmpty(experienceDto.getDescription())){ + for(VcExperienceDescriptionDto descriptionDto :experienceDto.getDescription()){ + if(StrUtil.isEmpty(descriptionDto.getContent())){ + descriptionDto.setContent("-"); + } + + } + } + } + } + + if(CollectionUtil.isNotEmpty(cvInfoDto.getEducation())){ + for (VcEducationDto educationDto :cvInfoDto.getEducation()) { + if (StrUtil.isEmpty(educationDto.getDegree())){ + educationDto.setDegree("-"); + } + if(StrUtil.isEmpty(educationDto.getInstitution())){ + educationDto.setInstitution("-"); + } + if(StrUtil.isEmpty(educationDto.getDurationStart())){ + educationDto.setDurationStart("-"); + } + if(StrUtil.isEmpty(educationDto.getDurationEnd())){ + educationDto.setDurationEnd("-"); + } + if(educationDto.getCertificate() != null){ + if(StrUtil.isEmpty(educationDto.getCertificate().getFileName())){ + educationDto.getCertificate().setFileName("-"); + } + if (StrUtil.isEmpty(educationDto.getCertificate().getFileSuffix())){ + educationDto.getCertificate().setFileSuffix("-"); + } + if (StrUtil.isEmpty(educationDto.getCertificate().getFileUrl())){ + educationDto.getCertificate().setFileUrl("-"); + } + if (StrUtil.isEmpty(educationDto.getCertificate().getFileSizeShow())){ + educationDto.getCertificate().setFileSizeShow("-"); + } + } + } + } + } + + return cvInfoDto; + } catch (Exception e) { + e.printStackTrace(); + } + return new HotakeCvInfoDto(); + } + + + /** + * 处理简历信息 + * + * @param hotakeCvInfo 简历信息 + * @return + */ + private String handleHotakeCvInfoScore(HotakeCvInfoDto cvInfoDto) { + String resultMsg = ""; + try { + //调用AI大模型 + List> list = new LinkedList(); + Map mapEntity = new HashMap<>(); + mapEntity.put("role", "system"); + mapEntity.put("content", "You are a construction industry HR expert. Evaluate resumes and provide scores and recommendations for construction management positions."); + list.add(mapEntity); + Map mapEntityOne = new HashMap<>(); + mapEntityOne.put("role", "user"); + mapEntityOne.put("content", "Position: Construction Labourer" + + "\\nCandidate: " + cvInfoDto.getName() + + "\\nResume Summary: " + JSONUtil.toJsonStr(cvInfoDto.getAbout()) + + "\\nSkills: " + JSONUtil.toJsonStr(cvInfoDto.getSkillsTools()) + + "\\nExperience: " + JSONUtil.toJsonStr(cvInfoDto.getExperience()) + + "\\nEducation: " + JSONUtil.toJsonStr(cvInfoDto.getEducation()) + + "\\nCertifications: " + JSONUtil.toJsonStr(cvInfoDto.getSkillsTools())); + list.add(mapEntityOne); + String promptText = JSONUtil.toJsonStr(list); + resultMsg = chatGPTClient.handleAiChat(promptText, "CV"); + log.info("返回简历评分数据:{}", resultMsg); + } catch (Exception e) { + e.printStackTrace(); + } + return resultMsg; + } } diff --git a/vetti-hotakes/src/main/java/com/vetti/hotake/service/impl/HotakeInitialScreeningQuestionsInfoServiceImpl.java b/vetti-hotakes/src/main/java/com/vetti/hotake/service/impl/HotakeInitialScreeningQuestionsInfoServiceImpl.java index 739de52..e013ef8 100644 --- a/vetti-hotakes/src/main/java/com/vetti/hotake/service/impl/HotakeInitialScreeningQuestionsInfoServiceImpl.java +++ b/vetti-hotakes/src/main/java/com/vetti/hotake/service/impl/HotakeInitialScreeningQuestionsInfoServiceImpl.java @@ -5,6 +5,7 @@ import cn.hutool.core.util.StrUtil; import cn.hutool.json.JSONUtil; import com.vetti.common.core.service.BaseServiceImpl; import com.vetti.common.enums.FillTypeEnum; +import com.vetti.common.utils.SecurityUtils; import com.vetti.hotake.domain.HotakeInitialScreeningQuestionsInfo; import com.vetti.hotake.domain.dto.AnswerOptionsDto; import com.vetti.hotake.mapper.HotakeInitialScreeningQuestionsInfoMapper; @@ -69,7 +70,7 @@ public class HotakeInitialScreeningQuestionsInfoServiceImpl extends BaseServiceI @Override public int insertHotakeInitialScreeningQuestionsInfo(HotakeInitialScreeningQuestionsInfo hotakeInitialScreeningQuestionsInfo) { - + hotakeInitialScreeningQuestionsInfo.setRecruiterId(SecurityUtils.getUserId()); fill(FillTypeEnum.INSERT.getCode(), hotakeInitialScreeningQuestionsInfo); if(CollectionUtil.isNotEmpty(hotakeInitialScreeningQuestionsInfo.getAnswerOptionsList())){ hotakeInitialScreeningQuestionsInfo.setAnswerOptions(JSONUtil.toJsonStr(hotakeInitialScreeningQuestionsInfo.getAnswerOptionsList())); @@ -89,6 +90,7 @@ public class HotakeInitialScreeningQuestionsInfoServiceImpl extends BaseServiceI @Override public int updateHotakeInitialScreeningQuestionsInfo(HotakeInitialScreeningQuestionsInfo hotakeInitialScreeningQuestionsInfo) { + hotakeInitialScreeningQuestionsInfo.setRecruiterId(SecurityUtils.getUserId()); fill(FillTypeEnum.UPDATE.getCode(), hotakeInitialScreeningQuestionsInfo); if(CollectionUtil.isNotEmpty(hotakeInitialScreeningQuestionsInfo.getAnswerOptionsList())){ hotakeInitialScreeningQuestionsInfo.setAnswerOptions(JSONUtil.toJsonStr(hotakeInitialScreeningQuestionsInfo.getAnswerOptionsList())); diff --git a/vetti-hotakes/src/main/java/com/vetti/hotake/service/impl/HotakeRolesApplyInfoServiceImpl.java b/vetti-hotakes/src/main/java/com/vetti/hotake/service/impl/HotakeRolesApplyInfoServiceImpl.java new file mode 100644 index 0000000..9285fe2 --- /dev/null +++ b/vetti-hotakes/src/main/java/com/vetti/hotake/service/impl/HotakeRolesApplyInfoServiceImpl.java @@ -0,0 +1,124 @@ +package com.vetti.hotake.service.impl; + +import java.util.List; + +import com.vetti.common.core.service.BaseServiceImpl; +import com.vetti.common.enums.FillTypeEnum; +import com.vetti.common.utils.DateUtils; +import com.vetti.common.utils.SecurityUtils; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import org.springframework.transaction.annotation.Transactional; + +import com.vetti.hotake.mapper.HotakeRolesApplyInfoMapper; +import com.vetti.hotake.domain.HotakeRolesApplyInfo; +import com.vetti.hotake.service.IHotakeRolesApplyInfoService; + +/** + * 候选人岗位申请信息Service业务层处理 + * + * @author wangxiangshun + * @date 2025-12-17 + */ +@SuppressWarnings("all") +@Service +public class HotakeRolesApplyInfoServiceImpl extends BaseServiceImpl implements IHotakeRolesApplyInfoService +{ + @Autowired + private HotakeRolesApplyInfoMapper hotakeRolesApplyInfoMapper; + + /** + * 查询候选人岗位申请信息 + * + * @param id 候选人岗位申请信息主键 + * @return 候选人岗位申请信息 + */ + @Transactional(readOnly = true) + @Override + public HotakeRolesApplyInfo selectHotakeRolesApplyInfoById(Long id) + { + return hotakeRolesApplyInfoMapper.selectHotakeRolesApplyInfoById(id); + } + + /** + * 查询候选人岗位申请信息列表 + * + * @param hotakeRolesApplyInfo 候选人岗位申请信息 + * @return 候选人岗位申请信息 + */ + @Transactional(readOnly = true) + @Override + public List selectHotakeRolesApplyInfoList(HotakeRolesApplyInfo hotakeRolesApplyInfo) + { + return hotakeRolesApplyInfoMapper.selectHotakeRolesApplyInfoList(hotakeRolesApplyInfo); + } + + /** + * 新增候选人岗位申请信息 + * + * @param hotakeRolesApplyInfo 候选人岗位申请信息 + * @return 结果 + */ + @Transactional(rollbackFor=Exception.class) + @Override + public HotakeRolesApplyInfo insertHotakeRolesApplyInfo(HotakeRolesApplyInfo hotakeRolesApplyInfo) + { + fill(FillTypeEnum.INSERT.getCode(), hotakeRolesApplyInfo); + hotakeRolesApplyInfo.setCandidateId(SecurityUtils.getUserId()); + int resultNum = hotakeRolesApplyInfoMapper.insertHotakeRolesApplyInfo(hotakeRolesApplyInfo); + return hotakeRolesApplyInfo; + } + + /** + * 修改候选人岗位申请信息 + * + * @param hotakeRolesApplyInfo 候选人岗位申请信息 + * @return 结果 + */ + @Transactional(rollbackFor=Exception.class) + @Override + public HotakeRolesApplyInfo updateHotakeRolesApplyInfo(HotakeRolesApplyInfo hotakeRolesApplyInfo) + { + fill(FillTypeEnum.UPDATE.getCode(), hotakeRolesApplyInfo); + hotakeRolesApplyInfo.setCandidateId(SecurityUtils.getUserId()); + int resultNum = hotakeRolesApplyInfoMapper.updateHotakeRolesApplyInfo(hotakeRolesApplyInfo); + return hotakeRolesApplyInfo; + } + + /** + * 批量删除候选人岗位申请信息 + * + * @param ids 需要删除的候选人岗位申请信息主键 + * @return 结果 + */ + @Transactional(rollbackFor=Exception.class) + @Override + public int deleteHotakeRolesApplyInfoByIds(Long[] ids) + { + return hotakeRolesApplyInfoMapper.deleteHotakeRolesApplyInfoByIds(ids); + } + + /** + * 删除候选人岗位申请信息信息 + * + * @param id 候选人岗位申请信息主键 + * @return 结果 + */ + @Transactional(rollbackFor=Exception.class) + @Override + public int deleteHotakeRolesApplyInfoById(Long id) + { + return hotakeRolesApplyInfoMapper.deleteHotakeRolesApplyInfoById(id); + } + /** + * 批量新增候选人岗位申请信息 + * + * @param hotakeRolesApplyInfoList 候选人岗位申请信息列表 + * @return 结果 + */ + @Transactional(rollbackFor=Exception.class) + @Override + public int batchInsertHotakeRolesApplyInfo(List hotakeRolesApplyInfoList){ + return hotakeRolesApplyInfoMapper.batchInsertHotakeRolesApplyInfo(hotakeRolesApplyInfoList); + } +} diff --git a/vetti-hotakes/src/main/resources/mapper/hotake/HotakeInitScreQuestionsReplyRecordInfoMapper.xml b/vetti-hotakes/src/main/resources/mapper/hotake/HotakeInitScreQuestionsReplyRecordInfoMapper.xml index c7fe633..9470d0e 100644 --- a/vetti-hotakes/src/main/resources/mapper/hotake/HotakeInitScreQuestionsReplyRecordInfoMapper.xml +++ b/vetti-hotakes/src/main/resources/mapper/hotake/HotakeInitScreQuestionsReplyRecordInfoMapper.xml @@ -6,6 +6,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" + @@ -19,12 +20,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - select id, role_id, candidate_id, question_id, answer_connect, del_flag, create_by, create_time, update_by, update_time, remark from hotake_init_scre_questions_reply_record_info + select id, role_apply_id,role_id, candidate_id, question_id, answer_connect, del_flag, create_by, create_time, update_by, update_time, remark from hotake_init_scre_questions_reply_record_info + + + and candidate_id = #{candidateId} + and role_id = #{roleId} + and full_name like concat('%', #{fullName}, '%') + and email = #{email} + and phone_number = #{phoneNumber} + and cv_file = #{cvFile} + and cv_file_suffix = #{cvFileSuffix} + + and cover_letter = #{coverLetter} + and candidate_status = #{candidateStatus} + and stage = #{stage} + and last_contact = #{lastContact} + and cv_template_json = #{cvTemplateJson} + and cv_score = #{cvScore} + and cv_md5 = #{cvMd5} + and experience = #{experience} + and ai_match_score = #{aiMatchScore} + and ai_match_score_percentage = #{aiMatchScorePercentage} + + + + + + + insert into hotake_roles_apply_info + + candidate_id, + role_id, + full_name, + email, + phone_number, + cv_file, + cv_file_suffix, + file_size_show, + cover_letter, + candidate_status, + stage, + last_contact, + cv_template_json, + cv_score, + cv_md5, + experience, + ai_match_score, + ai_match_score_percentage, + del_flag, + create_by, + create_time, + update_by, + update_time, + remark, + + + #{candidateId}, + #{roleId}, + #{fullName}, + #{email}, + #{phoneNumber}, + #{cvFile}, + #{cvFileSuffix}, + #{fileSizeShow}, + #{coverLetter}, + #{candidateStatus}, + #{stage}, + #{lastContact}, + #{cvTemplateJson}, + #{cvScore}, + #{cvMd5}, + #{experience}, + #{aiMatchScore}, + #{aiMatchScorePercentage}, + #{delFlag}, + #{createBy}, + #{createTime}, + #{updateBy}, + #{updateTime}, + #{remark}, + + + + + update hotake_roles_apply_info + + candidate_id = #{candidateId}, + role_id = #{roleId}, + full_name = #{fullName}, + email = #{email}, + phone_number = #{phoneNumber}, + cv_file = #{cvFile}, + cv_file_suffix = #{cvFileSuffix}, + file_size_show = #{fileSizeShow}, + cover_letter = #{coverLetter}, + candidate_status = #{candidateStatus}, + stage = #{stage}, + last_contact = #{lastContact}, + cv_template_json = #{cvTemplateJson}, + cv_score = #{cvScore}, + cv_md5 = #{cvMd5}, + experience = #{experience}, + ai_match_score = #{aiMatchScore}, + ai_match_score_percentage = #{aiMatchScorePercentage}, + del_flag = #{delFlag}, + create_by = #{createBy}, + create_time = #{createTime}, + update_by = #{updateBy}, + update_time = #{updateTime}, + remark = #{remark}, + + where id = #{id} + + + + delete from hotake_roles_apply_info where id = #{id} + + + + delete from hotake_roles_apply_info where id in + + #{id} + + + + + insert into hotake_roles_apply_info( id, candidate_id, role_id, full_name, email, phone_number, cv_file, cover_letter, candidate_status, stage, last_contact, cv_template_json, cv_score, cv_md5, experience, ai_match_score, ai_match_score_percentage, del_flag, create_by, create_time, update_by, update_time, remark) values + + ( #{item.id}, #{item.candidateId}, #{item.roleId}, #{item.fullName}, #{item.email}, #{item.phoneNumber}, #{item.cvFile}, #{item.coverLetter}, #{item.candidateStatus}, #{item.stage}, #{item.lastContact}, #{item.cvTemplateJson}, #{item.cvScore}, #{item.cvMd5}, #{item.experience}, #{item.aiMatchScore}, #{item.aiMatchScorePercentage}, #{item.delFlag}, #{item.createBy}, #{item.createTime}, #{item.updateBy}, #{item.updateTime}, #{item.remark}) + + + \ No newline at end of file