generated from dxfeng/secondev-chapanda-feishu
Merge pull request 'feature/dxf' (#5) from feature/dxf into develop
Reviewed-on: http://221.226.25.34:3000/dxfeng/weaver-hrm-recruit/pulls/5
This commit is contained in:
commit
1a0185a8f2
|
|
@ -1,5 +1,7 @@
|
|||
#\u805A\u624D\u6797\u62DB\u8058\u6D88\u606F\u63D0\u9192\uFF0C\u6D88\u606F\u6765\u6E90
|
||||
RECRUIT_MESSAGE_TYPE=2022061063
|
||||
|
||||
|
||||
#\u9762\u8BD5\u76F8\u5173\u6D88\u606F\u63D0\u9192\uFF0C\u6D88\u606F\u6765\u6E90
|
||||
INTERVIEW_MESSAGE_TYPE=2022061063
|
||||
#\u6DFB\u52A0\u9762\u8BD5\u6D88\u606F\u63D0\u9192\u6807\u9898
|
||||
|
|
@ -8,8 +10,15 @@ INTERVIEW_ADD_MESSAGE_TITLE=\u9762\u8BD5\u5B89\u6392\u63D0\u9192
|
|||
INTERVIEW_CANCEL_MESSAGE_TITLE=\u53D6\u6D88\u9762\u8BD5\u63D0\u9192
|
||||
#\u9762\u8BD5\u8BC4\u4EF7\u6D88\u606F\u63D0\u9192\u6807\u9898
|
||||
INTERVIEW_EVALUATE_MESSAGE_TITLE=\u9762\u8BD5\u8BC4\u4EF7\u63D0\u9192
|
||||
|
||||
|
||||
#\u4EBA\u624D\u9ED1\u540D\u5355\u901A\u77E5
|
||||
JOIN_BLACKLIST_MESSAGE_TITLE=\u4EBA\u624D\u9ED1\u540D\u5355\u901A\u77E5
|
||||
|
||||
#\u7B5B\u9009\u53CD\u9988
|
||||
SCREENING_MESSAGE_TYPE=2022061063
|
||||
SCREENING_MESSAGE_TITLE=\u7B80\u5386\u7B5B\u9009
|
||||
SCREENING_MESSAGE_URL=/wui/index.html#/main/cube/search?customid=65
|
||||
|
||||
#\u5E94\u8058\u8005\u7B80\u5386\u5B58\u653E\u76EE\u5F55ID
|
||||
APPLICANTS_RESUMES_CATEGORY=110
|
||||
|
|
@ -0,0 +1,12 @@
|
|||
package com.api.recruit.controller;
|
||||
|
||||
import javax.ws.rs.Path;
|
||||
|
||||
/**
|
||||
* @author:dxfeng
|
||||
* @createTime: 2023/10/20
|
||||
* @version: 1.0
|
||||
*/
|
||||
@Path("/jcl/recruit/talentpool")
|
||||
public class TalentPoolController extends com.engine.recruit.controller.TalentPoolController{
|
||||
}
|
||||
|
|
@ -0,0 +1,37 @@
|
|||
package com.engine.recruit.controller;
|
||||
|
||||
import com.engine.common.util.ParamUtil;
|
||||
import com.engine.common.util.ServiceUtil;
|
||||
import com.engine.recruit.util.ResponseResult;
|
||||
import com.engine.recruit.wrapper.TalentPoolWrapper;
|
||||
import weaver.hrm.HrmUserVarify;
|
||||
import weaver.hrm.User;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import javax.ws.rs.POST;
|
||||
import javax.ws.rs.Path;
|
||||
import javax.ws.rs.Produces;
|
||||
import javax.ws.rs.core.Context;
|
||||
import javax.ws.rs.core.MediaType;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @author:dxfeng
|
||||
* @createTime: 2023/10/20
|
||||
* @version: 1.0
|
||||
*/
|
||||
public class TalentPoolController {
|
||||
public TalentPoolWrapper getTalentPoolWrapper(User user) {
|
||||
return ServiceUtil.getService(TalentPoolWrapper.class, user);
|
||||
}
|
||||
|
||||
@POST
|
||||
@Path("/removeBlacklist")
|
||||
@Produces(MediaType.APPLICATION_JSON)
|
||||
public String removeBlacklist(@Context HttpServletRequest request, @Context HttpServletResponse response) {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
Map<String, Object> param = ParamUtil.request2Map(request);
|
||||
return new ResponseResult<Map<String, Object>, Map<String, Object>>(user).run(getTalentPoolWrapper(user)::removeBlacklist, param);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,19 @@
|
|||
package com.engine.recruit.service;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @author:dxfeng
|
||||
* @createTime: 2023/10/20
|
||||
* @version: 1.0
|
||||
*/
|
||||
public interface TalentPoolService {
|
||||
|
||||
/**
|
||||
* 移出黑名单
|
||||
*
|
||||
* @param param
|
||||
* @return
|
||||
*/
|
||||
Map<String, Object> removeBlacklist(Map<String, Object> param);
|
||||
}
|
||||
|
|
@ -0,0 +1,28 @@
|
|||
package com.engine.recruit.service.impl;
|
||||
|
||||
import com.engine.core.impl.Service;
|
||||
import com.engine.recruit.exception.CustomizeRunTimeException;
|
||||
import com.engine.recruit.service.TalentPoolService;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import weaver.conn.RecordSet;
|
||||
import weaver.general.Util;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @author:dxfeng
|
||||
* @createTime: 2023/10/20
|
||||
* @version: 1.0
|
||||
*/
|
||||
public class TalentPoolServiceImpl extends Service implements TalentPoolService {
|
||||
@Override
|
||||
public Map<String, Object> removeBlacklist(Map<String, Object> param) {
|
||||
String ids = Util.null2String(param.get("ids"));
|
||||
if (StringUtils.isBlank(ids)) {
|
||||
throw new CustomizeRunTimeException("");
|
||||
}
|
||||
RecordSet rs = new RecordSet();
|
||||
rs.executeUpdate("update uf_jcl_rck set sfjrhmd = 1 where id in (" + ids + ")");
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,24 @@
|
|||
package com.engine.recruit.wrapper;
|
||||
|
||||
import com.engine.common.util.ServiceUtil;
|
||||
import com.engine.core.impl.Service;
|
||||
import com.engine.recruit.service.TalentPoolService;
|
||||
import com.engine.recruit.service.impl.TalentPoolServiceImpl;
|
||||
import weaver.hrm.User;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @author:dxfeng
|
||||
* @createTime: 2023/10/20
|
||||
* @version: 1.0
|
||||
*/
|
||||
public class TalentPoolWrapper extends Service {
|
||||
private TalentPoolService getTalentPoolService(User user) {
|
||||
return ServiceUtil.getService(TalentPoolServiceImpl.class, user);
|
||||
}
|
||||
|
||||
public Map<String, Object> removeBlacklist(Map<String, Object> param) {
|
||||
return getTalentPoolService(user).removeBlacklist(param);
|
||||
}
|
||||
}
|
||||
|
|
@ -5,6 +5,8 @@ import org.apache.commons.lang3.StringUtils;
|
|||
import weaver.common.DateUtil;
|
||||
import weaver.conn.RecordSet;
|
||||
import weaver.formmode.customjavacode.AbstractModeExpandJavaCodeNew;
|
||||
import weaver.formmode.recruit.modeexpand.util.ApplicantCommonInfo;
|
||||
import weaver.formmode.recruit.modeexpand.util.RecruitModeUtil;
|
||||
import weaver.formmode.setup.ModeRightInfo;
|
||||
import weaver.general.BaseBean;
|
||||
import weaver.general.Util;
|
||||
|
|
@ -75,6 +77,8 @@ public class BatchAddDeptScreeningModeExpand extends AbstractModeExpandJavaCodeN
|
|||
detailMapList.add(detailDataMap);
|
||||
}
|
||||
|
||||
StringBuilder msgBuilder = new StringBuilder();
|
||||
msgBuilder.append(user.getLastname()).append("给你发来简历进行筛选,请查看。<br/>");
|
||||
for (Map<String, Object> detailDataMap : detailMapList) {
|
||||
List<List<Object>> paramList = new ArrayList<>();
|
||||
buildParamList(detailDataMap, paramList);
|
||||
|
|
@ -87,7 +91,18 @@ public class BatchAddDeptScreeningModeExpand extends AbstractModeExpandJavaCodeN
|
|||
refreshRight(rs, uuid, formModeId);
|
||||
}
|
||||
}
|
||||
String applicantName = ApplicantCommonInfo.getApplicantName(Util.null2String(detailDataMap.get("ypz")));
|
||||
String applicantPosition = ApplicantCommonInfo.getApplicantPosition(Util.null2String(detailDataMap.get("ypzw")));
|
||||
msgBuilder.append("【应聘者:").append(applicantName).append(",应聘职位:").append(applicantPosition).append("】").append("<br/>");
|
||||
}
|
||||
|
||||
// 发送待办消息
|
||||
String messageType = RecruitModeUtil.getRecruitPropValue("SCREENING_MESSAGE_TYPE");
|
||||
String messageTitle = RecruitModeUtil.getRecruitPropValue("SCREENING_MESSAGE_TITLE");
|
||||
String linkUrl = RecruitModeUtil.getRecruitPropValue("SCREENING_MESSAGE_URL");
|
||||
String fkr = Util.null2String(mainDataMap.get("fkr"));
|
||||
Set<String> userIdSet = new HashSet<>(Arrays.asList(fkr.split(",")));
|
||||
RecruitModeUtil.messagePush(messageType, messageTitle, msgBuilder.toString(), userIdSet, user.getUID(), linkUrl, "");
|
||||
}
|
||||
} catch (Exception e) {
|
||||
new BaseBean().writeLog(e);
|
||||
|
|
|
|||
|
|
@ -5,6 +5,8 @@ import org.apache.commons.lang3.StringUtils;
|
|||
import weaver.common.DateUtil;
|
||||
import weaver.conn.RecordSet;
|
||||
import weaver.formmode.customjavacode.AbstractModeExpandJavaCodeNew;
|
||||
import weaver.formmode.recruit.modeexpand.util.ApplicantCommonInfo;
|
||||
import weaver.formmode.recruit.modeexpand.util.RecruitModeUtil;
|
||||
import weaver.formmode.setup.ModeRightInfo;
|
||||
import weaver.general.BaseBean;
|
||||
import weaver.general.Util;
|
||||
|
|
@ -76,6 +78,18 @@ public class SingleAddDeptScreeningModeExpand extends AbstractModeExpandJavaCode
|
|||
refreshRight(rs, uuid, formModeId);
|
||||
}
|
||||
}
|
||||
// 发送待办消息
|
||||
String messageType = RecruitModeUtil.getRecruitPropValue("SCREENING_MESSAGE_TYPE");
|
||||
String messageTitle = RecruitModeUtil.getRecruitPropValue("SCREENING_MESSAGE_TITLE");
|
||||
String linkUrl = RecruitModeUtil.getRecruitPropValue("SCREENING_MESSAGE_URL");
|
||||
String fkr = Util.null2String(dataMap.get("fkr"));
|
||||
String applicantName = ApplicantCommonInfo.getApplicantName(Util.null2String(param.get("ypz")));
|
||||
String applicantPosition = ApplicantCommonInfo.getApplicantPosition(Util.null2String(param.get("ypzw")));
|
||||
String messageContent = user.getLastname() + "给你发来简历进行筛选,请查看。<br/>" +
|
||||
"【应聘者:" + applicantName + ",应聘职位:" + applicantPosition + "】";
|
||||
|
||||
Set<String> userIdSet = new HashSet<>(Arrays.asList(fkr.split(",")));
|
||||
RecruitModeUtil.messagePush(messageType, messageTitle, messageContent, userIdSet, user.getUID(), linkUrl, "");
|
||||
}
|
||||
} catch (Exception e) {
|
||||
new BaseBean().writeLog(e);
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@ import weaver.general.Util;
|
|||
import weaver.hrm.User;
|
||||
import weaver.soa.workflow.request.*;
|
||||
|
||||
import java.io.UnsupportedEncodingException;
|
||||
import java.util.*;
|
||||
|
||||
/**
|
||||
|
|
@ -36,9 +35,9 @@ public class BatchAddInterviewResultModeExpand extends AbstractModeExpandJavaCod
|
|||
*/
|
||||
private final String title;
|
||||
|
||||
public BatchAddInterviewResultModeExpand() throws UnsupportedEncodingException {
|
||||
public BatchAddInterviewResultModeExpand() {
|
||||
super();
|
||||
messageType = RecruitModeUtil.getRecruitPropValue("RECRUIT_MESSAGE_TYPE");
|
||||
messageType = RecruitModeUtil.getRecruitPropValue("INTERVIEW_MESSAGE_TYPE");
|
||||
title = RecruitModeUtil.getRecruitPropValue("INTERVIEW_ADD_MESSAGE_TITLE");
|
||||
}
|
||||
|
||||
|
|
@ -188,7 +187,6 @@ public class BatchAddInterviewResultModeExpand extends AbstractModeExpandJavaCod
|
|||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 获取应聘者信息
|
||||
*
|
||||
|
|
|
|||
|
|
@ -65,7 +65,7 @@ public class CreateInterviewModeExpand extends AbstractModeExpandJavaCodeNew {
|
|||
InterviewOperateTypeEnum operateTypeEnum = InterviewOperateTypeEnum.getOperateType(operateType);
|
||||
switch (operateTypeEnum) {
|
||||
case ARRANGE:
|
||||
messageType = RecruitModeUtil.getRecruitPropValue("RECRUIT_MESSAGE_TYPE");
|
||||
messageType = RecruitModeUtil.getRecruitPropValue("INTERVIEW_MESSAGE_TYPE");
|
||||
title = RecruitModeUtil.getRecruitPropValue("INTERVIEW_ADD_MESSAGE_TITLE");
|
||||
arrangeInterview(user, mainDataMap);
|
||||
sendMessage(billId);
|
||||
|
|
|
|||
|
|
@ -63,13 +63,13 @@ public class UpdateInterviewModeExpand extends AbstractModeExpandJavaCodeNew {
|
|||
switch (operateTypeEnum) {
|
||||
case EVALUATE:
|
||||
// 面试评价
|
||||
messageType = RecruitModeUtil.getRecruitPropValue("RECRUIT_MESSAGE_TYPE");
|
||||
messageType = RecruitModeUtil.getRecruitPropValue("INTERVIEW_MESSAGE_TYPE");
|
||||
title = RecruitModeUtil.getRecruitPropValue("INTERVIEW_EVALUATE_MESSAGE_TITLE");
|
||||
evaluateInterview(params, requestInfo.getCreatorid(), mainDataMap);
|
||||
break;
|
||||
case CANCEL:
|
||||
// 面试取消
|
||||
messageType = RecruitModeUtil.getRecruitPropValue("RECRUIT_MESSAGE_TYPE");
|
||||
messageType = RecruitModeUtil.getRecruitPropValue("INTERVIEW_MESSAGE_TYPE");
|
||||
title = RecruitModeUtil.getRecruitPropValue("INTERVIEW_CANCEL_MESSAGE_TITLE");
|
||||
cancelInterView(params, requestInfo, billId, mainDataMap);
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -38,9 +38,22 @@ public class RecruitModeUtil {
|
|||
* @param creater 消息创建者
|
||||
*/
|
||||
public static void messagePush(String messageType, String title, String context, Set<String> userIdList, Integer creater) {
|
||||
messagePush(messageType, title, context, userIdList, creater, "", "");
|
||||
}
|
||||
|
||||
/**
|
||||
* @param messageType 消息来源
|
||||
* @param title 消息标题
|
||||
* @param context 消息内容
|
||||
* @param userIdList 接收人ID集合
|
||||
* @param creater 消息创建者
|
||||
* @param linkUrl 待办跳转地址
|
||||
* @param linkMobileUrl 移动端跳转地址
|
||||
*/
|
||||
public static void messagePush(String messageType, String title, String context, Set<String> userIdList, Integer creater, String linkUrl, String linkMobileUrl) {
|
||||
MessageType message = MessageType.newInstance(Integer.parseInt(messageType));
|
||||
try {
|
||||
MessageBean messageBean = Util_Message.createMessage(message, userIdList, title, context, "", "");
|
||||
MessageBean messageBean = Util_Message.createMessage(message, userIdList, title, context, linkUrl, linkMobileUrl);
|
||||
messageBean.setCreater(creater);
|
||||
Util_Message.store(messageBean);
|
||||
} catch (IOException e) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue