MODIFY-"招聘需求计划申请"流程,简化配置项

This commit is contained in:
dxfeng 2024-06-26 14:38:59 +08:00
parent 73aaa2db96
commit f51e107293
1 changed files with 21 additions and 23 deletions

View File

@ -5,13 +5,15 @@ import com.cloudstore.dev.api.bean.MessageType;
import com.cloudstore.dev.api.util.Util_Message;
import com.engine.recruit.conn.ApplicantCommonInfo;
import com.engine.recruit.conn.RecruitRecordSet;
import com.engine.recruit.constant.RecruitConstant;
import org.apache.commons.collections.CollectionUtils;
import org.apache.commons.lang.StringUtils;
import weaver.common.DateUtil;
import weaver.conn.RecordSetTrans;
import weaver.formmode.recruit.modeexpand.util.RecruitModeUtil;
import weaver.formmode.setup.ModeRightInfo;
import weaver.general.BaseBean;
import weaver.general.Util;
import weaver.hrm.User;
import weaver.hrm.resource.ResourceComInfo;
import weaver.interfaces.workflow.action.Action;
import weaver.soa.workflow.request.*;
@ -47,6 +49,7 @@ public class RecruitFlowToModeAction implements Action {
MainTableInfo mainTableInfo = requestInfo.getMainTableInfo();
int billId = requestInfo.getRequestManager().getBillid();
int formid = requestInfo.getRequestManager().getFormid();
User user = requestInfo.getRequestManager().getUser();
DetailTableInfo detailTableInfo = requestInfo.getDetailTableInfo();
DetailTable detailTable = detailTableInfo.getDetailTable(0);
@ -119,9 +122,24 @@ public class RecruitFlowToModeAction implements Action {
Set<String> managerSet = new HashSet<>();
managerSet.add(manager);
// 获取消息类型默认值
if (StringUtils.isBlank(messageType)) {
messageType = RecruitConstant.RECRUIT_MESSAGE_TYPE;
}
if (StringUtils.isBlank(title)) {
title = "【招聘需求管理】";
}
if (StringUtils.isBlank(linkUrl)) {
linkUrl = "/spa/cube/index.html#/main/cube/card?type=0&modeId=$modeId$&formId=$formId$&billid=$billid$";
}
if (StringUtils.isBlank(linkMobileUrl)) {
linkMobileUrl = "/mobilemode/browserLinkTransit.jsp?billid=$billid$&modeId=$modeId$&formId=$formId$";
}
String url = replaceUrlKeys(linkUrl, messageMap);
String mobileUrl = replaceUrlKeys(linkMobileUrl, messageMap);
// 消息提醒
messagePush(applicantName + ",你申请的“" + requirementName + "”招聘需求,正在进行中,请知悉。", messageMap, applicantSet);
messagePush("您有一个新的”" + requirementName + "“招聘需求,请查收。", messageMap, managerSet);
RecruitModeUtil.messagePush(messageType, applicantName + ",你申请的“" + requirementName + "”招聘需求,正在进行中,请知悉。", title, applicantSet, user.getUID(), url, mobileUrl);
RecruitModeUtil.messagePush(messageType, "您有一个新的”" + requirementName + "“招聘需求,请查收。", title, managerSet, user.getUID(), url, mobileUrl);
}
rst.commit();
} catch (Exception e) {
@ -206,26 +224,6 @@ public class RecruitFlowToModeAction implements Action {
}
/**
* 权限重构
*
* @param rst RecordSetTrans
* @param uuid UUID
* @param formModeId 建模ID
* @throws Exception Exception
*/
private void refreshRight(RecordSetTrans rst, String uuid, int formModeId) throws Exception {
rst.executeQuery("select id from " + MODE_TABLE_NAME + " where modeuuid='" + uuid + "'");
if (rst.next()) {
//建模数据的id
int bid = Util.getIntValue(rst.getString("id"));
ModeRightInfo modeRightInfo = new ModeRightInfo();
modeRightInfo.setNewRight(true);
//新建的时候添加共享
modeRightInfo.editModeDataShare(1, formModeId, bid);
}
}
/**
* 消息推送
*