Merge branch 'version_performance_2.0' of http://gitlab.ldxinyong.com/enterpriseManagement/lz_management into version_performance_2.0
This commit is contained in:
commit
79d36ae7b8
@ -52,6 +52,8 @@ public class StaffSimpleInfo implements Serializable {
|
||||
private ResultRecord resultRecord;
|
||||
//本次发起的任务信息
|
||||
private FlowStart flowStart;
|
||||
//当前操作的流程id
|
||||
private Long flowRecordId;
|
||||
|
||||
|
||||
|
||||
|
||||
@ -31,4 +31,6 @@ public interface FlowChangeMapper extends BaseMapper<FlowChange> {
|
||||
|
||||
|
||||
FlowChange selectFlowChangeByRecordIdAndToIdAndType(@Param("recordId") Long recordId, @Param("toStaffId") Long toStaffId, @Param("type") int type);
|
||||
|
||||
FlowChange selectFlowChangeByFlowRecordIdAndType(@Param("flowRecordId") Long flowRecordId, @Param("type") int type);
|
||||
}
|
||||
@ -35,4 +35,6 @@ public interface FlowChangeService extends IService<FlowChange> {
|
||||
void saveChange(ApprovalDto approvalDto, FlowRecord flowRecord, int i);
|
||||
|
||||
FlowChange selectFlowChangeByRecordIdAndToIdAndType(Long recordId, Long toStaffId, int type);
|
||||
|
||||
FlowChange selectFlowChangeByFlowRecordIdAndType(Long flowRecordId, int i);
|
||||
}
|
||||
@ -84,5 +84,10 @@ public class FlowChangeServiceImpl extends ServiceImpl<FlowChangeMapper, FlowCha
|
||||
return flowChangeMapper.selectFlowChangeByRecordIdAndToIdAndType(recordId, toStaffId, type);
|
||||
}
|
||||
|
||||
@Override
|
||||
public FlowChange selectFlowChangeByFlowRecordIdAndType(Long flowRecordId, int type){
|
||||
return flowChangeMapper.selectFlowChangeByFlowRecordIdAndType(flowRecordId, type);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@ -233,42 +233,44 @@ public class DingtalkBusiness {
|
||||
}
|
||||
|
||||
|
||||
//流程流转发送消息
|
||||
public String sendWorkMSGWithAsyn(Long resultRecordId , int type) {
|
||||
public String sendWorkMSGWithAsyn(Long resultRecordId ,Long flowRecordId, int type) {
|
||||
logger.info("开始处理数据");
|
||||
//流程跳转专用
|
||||
ResultRecord resultRecord = resultRecordService.selectResultRecordById(resultRecordId);
|
||||
if(resultRecord != null){
|
||||
FlowStart flowStart = flowStartService.selectFlowStartById(resultRecord.getStartId());
|
||||
StaffSimpleInfo fromStaff = staffService.selectStaffSimpleInfo(resultRecord.getStaffId());//查询来自那里
|
||||
fromStaff.setResultRecord(resultRecord);
|
||||
fromStaff.setFlowStart(flowStart);
|
||||
List<StaffSimpleInfo> toStaffids = new ArrayList<>();
|
||||
toStaffids.add(fromStaff);
|
||||
sendWorkMSGWithAsyn(null, toStaffids, WorkMsgTypeEnum.PROCESS.getType());
|
||||
fromStaff.setFlowRecordId(flowRecordId);
|
||||
if(type == WorkMsgTypeEnum.REJECT.getType()){//被拒
|
||||
|
||||
sendWorkMSGWithAsyn(null, toStaffids, WorkMsgTypeEnum.REJECT.getType());
|
||||
return sendWorkMSGWithAsyn(fromStaff, null, WorkMsgTypeEnum.REJECT.getType());
|
||||
}else if(type == WorkMsgTypeEnum.URGING.getType()){//被拒
|
||||
|
||||
sendWorkMSGWithAsyn(null, toStaffids, WorkMsgTypeEnum.URGING.getType());
|
||||
return sendWorkMSGWithAsyn(fromStaff, null, WorkMsgTypeEnum.URGING.getType());
|
||||
}else if(type == WorkMsgTypeEnum.SKIP.getType()){//被拒
|
||||
|
||||
sendWorkMSGWithAsyn(null, toStaffids, WorkMsgTypeEnum.SKIP.getType());
|
||||
return sendWorkMSGWithAsyn(fromStaff, null, WorkMsgTypeEnum.SKIP.getType());
|
||||
}else if(type == WorkMsgTypeEnum.TRANSFER.getType()){//被拒
|
||||
|
||||
sendWorkMSGWithAsyn(null, toStaffids, WorkMsgTypeEnum.TRANSFER.getType());
|
||||
return sendWorkMSGWithAsyn(fromStaff, null, WorkMsgTypeEnum.TRANSFER.getType());
|
||||
}else{
|
||||
sendWorkMSGWithAsyn(null, toStaffids, WorkMsgTypeEnum.PROCESS.getType());
|
||||
return sendWorkMSGWithAsyn(fromStaff, null, WorkMsgTypeEnum.PROCESS.getType());
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
logger.info("无记录");
|
||||
return "error";
|
||||
}
|
||||
//流程流转发送消息
|
||||
public String sendWorkMSGWithAsyn(Long resultRecordId , int type) {
|
||||
logger.info("流程流转发送消息");
|
||||
return sendWorkMSGWithAsyn(resultRecordId, 0L, type);
|
||||
|
||||
}
|
||||
|
||||
|
||||
public String sendWorkMSGWithAsyn(StaffSimpleInfo fromStaff, List<StaffSimpleInfo> toStaffids, int type) {
|
||||
if(toStaffids.size() > 0){
|
||||
if(toStaffids != null && toStaffids.size() > 0){
|
||||
if (toStaffids.get(0).getEmployeeId() == null || toStaffids.get(0).getEmployeeId().length() == 0) {
|
||||
//查询第三方id
|
||||
List<Long> ids = toStaffids.stream().map(new Function<StaffSimpleInfo, Long>() {
|
||||
@ -287,7 +289,7 @@ public class DingtalkBusiness {
|
||||
}
|
||||
WorkMsgTypeEnum workMsgTypeEnum = WorkMsgTypeEnum.findRoleTypeByCode(type);
|
||||
|
||||
ThreadSendMessage threadSendMessage = new ThreadSendMessage(toStaffids, workMsgTypeEnum, appid);
|
||||
ThreadSendMessage threadSendMessage = new ThreadSendMessage(fromStaff, toStaffids, workMsgTypeEnum, appid);
|
||||
Thread thread = new Thread(threadSendMessage);
|
||||
thread.start();
|
||||
|
||||
@ -369,12 +371,13 @@ public class DingtalkBusiness {
|
||||
|
||||
public class ThreadSendMessage implements Runnable{
|
||||
List<StaffSimpleInfo> toStaffids;
|
||||
//StaffSimpleInfo fromStaff = null;
|
||||
StaffSimpleInfo fromStaff = null;
|
||||
List<Long> recordIds;
|
||||
WorkMsgTypeEnum workMsgTypeEnum;
|
||||
String appid;
|
||||
String hostUrl = "https://lzmanagement.ldxinyong.com/digitization";
|
||||
public ThreadSendMessage(List<StaffSimpleInfo> toStaffids, WorkMsgTypeEnum typeEnum, String appid){
|
||||
public ThreadSendMessage(StaffSimpleInfo fromStaff, List<StaffSimpleInfo> toStaffids, WorkMsgTypeEnum typeEnum, String appid){
|
||||
this.fromStaff = fromStaff;
|
||||
this.toStaffids = toStaffids;
|
||||
workMsgTypeEnum = typeEnum;
|
||||
this.appid = appid;
|
||||
@ -416,53 +419,37 @@ public class DingtalkBusiness {
|
||||
|
||||
ThirdAppConfig thirdAppConfig = thirdAppConfigService.getByAppId(appid);
|
||||
String token = dingTalkUtil.getAccessTokenWitchEntity(thirdAppConfig);
|
||||
if(workMsgTypeEnum.getType() == WorkMsgTypeEnum.CLEARN.getType()){
|
||||
//绩效催办
|
||||
logger.info("绩效清空");
|
||||
if(token != null && token.length() > 0){
|
||||
if(workMsgTypeEnum.getType() == WorkMsgTypeEnum.CLEARN.getType()){
|
||||
//绩效催办
|
||||
logger.info("绩效清空");
|
||||
|
||||
|
||||
List<ThirdMsgSendRecord> threadSendMessages
|
||||
= thirdMsgSendRecordService.selectThirdMsgSendRecordsByRecordIds(recordIds, 1, 1);
|
||||
logger.info("需要删除的条数为{}", threadSendMessages.size());
|
||||
for (ThirdMsgSendRecord thirdMsgSendRecord:threadSendMessages
|
||||
) {
|
||||
dingTalkUtil.updateWorkMSG(thirdMsgSendRecord, token);
|
||||
}
|
||||
}else{
|
||||
logger.info("开始批量推送消息,数量{}, appid{}", toStaffids.size(), appid);
|
||||
for (StaffSimpleInfo info:toStaffids
|
||||
) {
|
||||
if(token != null && token.length() > 0){
|
||||
//下面防止第二次发送消息时钉钉不推送
|
||||
List<ThirdMsgSendRecord> threadSendMessages
|
||||
= thirdMsgSendRecordService.selectThirdMsgSendRecordsByRecordIds(recordIds, 1, 1);
|
||||
logger.info("需要删除的条数为{}", threadSendMessages.size());
|
||||
for (ThirdMsgSendRecord thirdMsgSendRecord:threadSendMessages
|
||||
) {
|
||||
dingTalkUtil.updateWorkMSG(thirdMsgSendRecord, token);
|
||||
}
|
||||
}else{
|
||||
logger.info("开始批量推送消息,数量{}, appid{}", toStaffids.size(), appid);
|
||||
|
||||
if(toStaffids == null){//流程流转走的代码
|
||||
String url = hostUrl;
|
||||
if(url.contains("?")){
|
||||
url += "&halokit=" + System.currentTimeMillis();
|
||||
}else{
|
||||
url += "?halokit=" + System.currentTimeMillis();
|
||||
}
|
||||
url += ("&detail=1&id=" + info.getResultRecord().getId());
|
||||
url += ("&detail=1&id=" + fromStaff.getResultRecord().getId());
|
||||
url = URLEncoder.encode(url);
|
||||
|
||||
|
||||
url = "dingtalk://dingtalkclient/action/openapp?corpid=" + thirdAppConfig.getCorpId() +
|
||||
"&container_type=work_platform&app_id=0_" +
|
||||
appid + "&redirect_type=jump&redirect_url=" + url;
|
||||
|
||||
if(workMsgTypeEnum.getType() == WorkMsgTypeEnum.START_WORK.getType()){
|
||||
//发送制定目标通知
|
||||
logger.info("目标制定");
|
||||
sendNotic(info.getId(), info.getEmployeeId(),
|
||||
"目标制定", info.getFlowStart().getName(),
|
||||
info.getResultRecord().getStaffName(), token, url, info.getResultRecord().getId());
|
||||
|
||||
}else if(workMsgTypeEnum.getType() == WorkMsgTypeEnum.START_SCORE.getType()){
|
||||
//发送开始评分通知
|
||||
logger.info("结果录入");
|
||||
sendNotic(info.getId(), info.getEmployeeId(),
|
||||
"结果录入", info.getFlowStart().getName(),
|
||||
info.getResultRecord().getStaffName(), token, url, info.getResultRecord().getId());
|
||||
|
||||
}else if(workMsgTypeEnum.getType() == WorkMsgTypeEnum.URGING.getType()){
|
||||
if(workMsgTypeEnum.getType() == WorkMsgTypeEnum.URGING.getType()){
|
||||
//绩效催办
|
||||
logger.info("绩效催办");
|
||||
}else {
|
||||
@ -472,56 +459,59 @@ public class DingtalkBusiness {
|
||||
//转交
|
||||
//并发转交会有问题
|
||||
logger.info("转交待办任务处理");
|
||||
FlowChange flowChange = flowChangeService.selectFlowChangeByRecordIdAndToIdAndType(info.getResultRecord().getId(),
|
||||
info.getId(), 0);
|
||||
ThirdMsgSendRecord thirdMsgSendRecord =
|
||||
thirdMsgSendRecordService.selectThirdMsgSendRecordByWorkIdAndStaffIdAndTypeAndStatus(
|
||||
info.getResultRecord().getId(), flowChange.getApprovalId(), 1, 1);
|
||||
if(thirdMsgSendRecord != null){//把原来的任务更新掉
|
||||
dingTalkUtil.updateWorkMSG(thirdMsgSendRecord, token);
|
||||
FlowChange flowChange = flowChangeService.selectFlowChangeByFlowRecordIdAndType(
|
||||
fromStaff.getFlowRecordId(),
|
||||
0);
|
||||
if(flowChange != null){
|
||||
ThirdMsgSendRecord thirdMsgSendRecord =
|
||||
thirdMsgSendRecordService.selectThirdMsgSendRecordByWorkIdAndStaffIdAndTypeAndStatus(
|
||||
fromStaff.getResultRecord().getId(), flowChange.getApprovalId(), 1, 1);
|
||||
if(thirdMsgSendRecord != null){//把原来的任务更新掉
|
||||
dingTalkUtil.updateWorkMSG(thirdMsgSendRecord, token);
|
||||
}
|
||||
FlowRecord flowRecord = flowRecordService.selectFlowRecordById(flowChange.getFlowRecordId());
|
||||
if(flowRecord != null && flowRecord.getStatus().intValue() == 2){
|
||||
logger.info("转交存在且为当前要处理的节点");
|
||||
StaffSimpleInfo staffSimpleInfo = staffService.selectStaffSimpleInfo(flowRecord.getApprovalStaffId());
|
||||
//List<FlowRecord> flowRecords = flowRecordService.selectFlowRecordByRecordIdStatus(info.getResultRecord().getId(), 2);
|
||||
//发送待办任务到新指定人员,转交过来一定会有数据
|
||||
sendNotic(staffSimpleInfo.getId(), staffSimpleInfo.getEmployeeId(),
|
||||
flowRecord.getFlowName(), fromStaff.getFlowStart().getName(),
|
||||
fromStaff.getResultRecord().getStaffName(), token, url, fromStaff.getResultRecord().getId());
|
||||
}else{
|
||||
logger.info("转交不存在,或者当前非处理节点无需发送");
|
||||
}
|
||||
}else{
|
||||
logger.info("流转变更记录不存在");
|
||||
}
|
||||
FlowRecord flowRecord = flowRecordService.selectFlowRecordById(flowChange.getFlowRecordId());
|
||||
StaffSimpleInfo staffSimpleInfo = staffService.selectStaffSimpleInfo(flowRecord.getApprovalStaffId());
|
||||
//List<FlowRecord> flowRecords = flowRecordService.selectFlowRecordByRecordIdStatus(info.getResultRecord().getId(), 2);
|
||||
//发送待办任务到新指定人员,转交过来一定会有数据
|
||||
sendNotic(info.getId(), staffSimpleInfo.getEmployeeId(),
|
||||
flowRecord.getFlowName(), info.getFlowStart().getName(),
|
||||
info.getResultRecord().getStaffName(), token, url, info.getResultRecord().getId());
|
||||
|
||||
|
||||
|
||||
}else if(workMsgTypeEnum.getType() == WorkMsgTypeEnum.SKIP.getType()){//跳过
|
||||
//跳过
|
||||
logger.info("跳过待办任务处理");
|
||||
|
||||
|
||||
List<FlowRecord> flowRecords =
|
||||
flowRecordService.selectSkipFlowRecordsById(info.getResultRecord().getId());//取消所有跳过的人
|
||||
flowRecordService.selectSkipFlowRecordsById(fromStaff.getResultRecord().getId());//取消所有跳过的人
|
||||
logger.info("查询到可能需要更新待办任务数量{}", flowRecords.size());
|
||||
if(flowRecords.size() > 0){
|
||||
//if(flowRecords.get(0).getType().intValue() == 1){
|
||||
//或签
|
||||
logger.info("或签,需要更新该节点下所有人员的待办任务");
|
||||
for (FlowRecord flowRecord:flowRecords
|
||||
) {
|
||||
//if(flowRecord.getApprovalStaffId().longValue() != info.getId()){
|
||||
logger.info("更新非直接跳关人员的待办任务,人员id:{}, 姓名:{}", flowRecord.getApprovalStaffId(),
|
||||
flowRecord.getApprovalStaffName());
|
||||
ThirdMsgSendRecord thirdMsgSendRecord =
|
||||
thirdMsgSendRecordService.selectThirdMsgSendRecordByWorkIdAndStaffIdAndTypeAndStatus(
|
||||
info.getResultRecord().getId(),
|
||||
flowRecord.getApprovalStaffId(), 1, 1);
|
||||
if(thirdMsgSendRecord != null){//把原来的任务更新掉
|
||||
dingTalkUtil.updateWorkMSG(thirdMsgSendRecord, token);
|
||||
}else{
|
||||
logger.info("无需更新");
|
||||
}
|
||||
//}
|
||||
//或签
|
||||
logger.info("或签,需要更新该节点下所有人员的待办任务");
|
||||
for (FlowRecord flowRecord:flowRecords
|
||||
) {
|
||||
logger.info("更新非直接跳关人员的待办任务,人员id:{}, 姓名:{}", flowRecord.getApprovalStaffId(),
|
||||
flowRecord.getApprovalStaffName());
|
||||
ThirdMsgSendRecord thirdMsgSendRecord =
|
||||
thirdMsgSendRecordService.selectThirdMsgSendRecordByWorkIdAndStaffIdAndTypeAndStatus(
|
||||
fromStaff.getResultRecord().getId(),
|
||||
flowRecord.getApprovalStaffId(), 1, 1);
|
||||
if(thirdMsgSendRecord != null){//把原来的任务更新掉
|
||||
dingTalkUtil.updateWorkMSG(thirdMsgSendRecord, token);
|
||||
}else{
|
||||
logger.info("无需更新");
|
||||
}
|
||||
//}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
List<FlowRecord> flowRecords = flowRecordService.selectFlowRecordByRecordIdStatus(info.getResultRecord().getId(), 2);
|
||||
List<FlowRecord> flowRecords = flowRecordService.selectFlowRecordByRecordIdStatus(fromStaff.getResultRecord().getId(), 2);
|
||||
if(flowRecords.size() > 0){//给下一步骤需要处理的人发送待办任务
|
||||
if(flowRecords.get(0).getFlowProcess().intValue() != 2){//执行中的不发送待办
|
||||
logger.info("非执行中的节点发送待办任务{}", flowRecords.get(0).getFlowName());
|
||||
@ -535,21 +525,21 @@ public class DingtalkBusiness {
|
||||
for (StaffSimpleInfo staffSimpleInfo:staffSimpleInfos
|
||||
) {
|
||||
sendNotic(staffSimpleInfo.getId(), staffSimpleInfo.getEmployeeId(),
|
||||
flowRecords.get(0).getFlowName(), info.getFlowStart().getName(),
|
||||
info.getResultRecord().getStaffName(), token, url, info.getResultRecord().getId());
|
||||
flowRecords.get(0).getFlowName(), fromStaff.getFlowStart().getName(),
|
||||
fromStaff.getResultRecord().getStaffName(), token, url, fromStaff.getResultRecord().getId());
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
//取消上一步骤发送的待办任务
|
||||
if(flowRecords.size() == 0){//任务结束了
|
||||
flowRecords = flowRecordService.selectLastFlowRecordsById(info.getResultRecord().getId());
|
||||
flowRecords = flowRecordService.selectLastFlowRecordsById(fromStaff.getResultRecord().getId());
|
||||
}else{
|
||||
if(workMsgTypeEnum.getType() == WorkMsgTypeEnum.REJECT.getType()){//被拒
|
||||
flowRecords = flowRecordService.selectLastFlowRecordsByIdAndFlowIndex(info.getResultRecord().getId()
|
||||
flowRecords = flowRecordService.selectLastFlowRecordsByIdAndFlowIndex(fromStaff.getResultRecord().getId()
|
||||
, flowRecords.get(0).getFlowIndex().intValue() + 1);//获取下一步的数据
|
||||
}else{
|
||||
flowRecords = flowRecordService.selectLastFlowRecordsByIdAndFlowIndex(info.getResultRecord().getId()
|
||||
flowRecords = flowRecordService.selectLastFlowRecordsByIdAndFlowIndex(fromStaff.getResultRecord().getId()
|
||||
, flowRecords.get(0).getFlowIndex().intValue() - 1);//获取上一步的数据
|
||||
}
|
||||
|
||||
@ -566,7 +556,7 @@ public class DingtalkBusiness {
|
||||
flowRecord.getApprovalStaffName());
|
||||
ThirdMsgSendRecord thirdMsgSendRecord =
|
||||
thirdMsgSendRecordService.selectThirdMsgSendRecordByWorkIdAndStaffIdAndTypeAndStatus(
|
||||
info.getResultRecord().getId(),
|
||||
fromStaff.getResultRecord().getId(),
|
||||
flowRecord.getApprovalStaffId(), 1, 1);
|
||||
if(thirdMsgSendRecord != null){//把原来的任务更新掉
|
||||
dingTalkUtil.updateWorkMSG(thirdMsgSendRecord, token);
|
||||
@ -578,10 +568,48 @@ public class DingtalkBusiness {
|
||||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
logger.info("ThreadSendMessage token无效"); ;
|
||||
|
||||
|
||||
}else{//批量推送给指定人员
|
||||
for (StaffSimpleInfo info:toStaffids
|
||||
) {
|
||||
|
||||
//下面防止第二次发送消息时钉钉不推送
|
||||
String url = hostUrl;
|
||||
if (url.contains("?")) {
|
||||
url += "&halokit=" + System.currentTimeMillis();
|
||||
} else {
|
||||
url += "?halokit=" + System.currentTimeMillis();
|
||||
}
|
||||
url += ("&detail=1&id=" + info.getResultRecord().getId());
|
||||
url = URLEncoder.encode(url);
|
||||
url = "dingtalk://dingtalkclient/action/openapp?corpid=" + thirdAppConfig.getCorpId() +
|
||||
"&container_type=work_platform&app_id=0_" +
|
||||
appid + "&redirect_type=jump&redirect_url=" + url;
|
||||
|
||||
if (workMsgTypeEnum.getType() == WorkMsgTypeEnum.START_WORK.getType()) {
|
||||
//发送制定目标通知
|
||||
logger.info("目标制定");
|
||||
sendNotic(info.getId(), info.getEmployeeId(),
|
||||
"目标制定", info.getFlowStart().getName(),
|
||||
info.getResultRecord().getStaffName(), token, url, info.getResultRecord().getId());
|
||||
|
||||
} else if (workMsgTypeEnum.getType() == WorkMsgTypeEnum.START_SCORE.getType()) {
|
||||
//发送开始评分通知
|
||||
logger.info("结果录入");
|
||||
sendNotic(info.getId(), info.getEmployeeId(),
|
||||
"结果录入", info.getFlowStart().getName(),
|
||||
info.getResultRecord().getStaffName(), token, url, info.getResultRecord().getId());
|
||||
|
||||
}else{
|
||||
logger.info("未定义消息类型");
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
logger.info("ThreadSendMessage token无效"); ;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -62,7 +62,7 @@ public class OAuth2Filter extends AuthenticatingFilter {
|
||||
httpResponse.setHeader("Access-Control-Allow-Credentials", "true");
|
||||
httpResponse.setHeader("Access-Control-Allow-Origin", HttpContextUtils.getOrigin());
|
||||
|
||||
String json = new Gson().toJson(R.error(HttpStatus.SC_UNAUTHORIZED, "invalid token"));
|
||||
String json = new Gson().toJson(R.error(HttpStatus.SC_UNAUTHORIZED, "登录已过期,请重新登录"));
|
||||
httpResponse.getWriter().print(json);
|
||||
|
||||
return false;
|
||||
|
||||
@ -937,7 +937,7 @@ public class ResultRecordServiceImpl extends ServiceImpl<ResultRecordMapper, Res
|
||||
newSubmit(approvalDto,FlowRecordStatusEnums.SKIP_STATUS.getStatus());
|
||||
}
|
||||
flowChangeService.saveChange(approvalDto, flowRecord, 0);
|
||||
dingtalkBusiness.sendWorkMSGWithAsyn(flowRecord.getRecordId(), WorkMsgTypeEnum. SKIP.getType());
|
||||
dingtalkBusiness.sendWorkMSGWithAsyn(flowRecord.getRecordId(),flowRecord.getId(), WorkMsgTypeEnum. SKIP.getType());
|
||||
return R.ok("恭喜您,跳过成功。");
|
||||
}
|
||||
|
||||
@ -948,7 +948,7 @@ public class ResultRecordServiceImpl extends ServiceImpl<ResultRecordMapper, Res
|
||||
flowRecord.setApprovalStaffId(staffEntity.getId());
|
||||
flowRecord.setApprovalStaffName(staffEntity.getName());
|
||||
flowRecordService.updateFlowRecordById(flowRecord);
|
||||
dingtalkBusiness.sendWorkMSGWithAsyn(flowRecord.getRecordId(), WorkMsgTypeEnum.TRANSFER.getType());
|
||||
dingtalkBusiness.sendWorkMSGWithAsyn(flowRecord.getRecordId(),flowRecord.getId(), WorkMsgTypeEnum.TRANSFER.getType());
|
||||
return R.ok("转交成功");
|
||||
}
|
||||
|
||||
|
||||
@ -103,5 +103,9 @@
|
||||
select * from lz_flow_change where record_id=#{recordId} and to_approval_id = #{toStaffId} and type = #{type} and is_delete = 0 limit 1
|
||||
</select>
|
||||
|
||||
<select id="selectFlowChangeByFlowRecordIdAndType" resultType="FlowChange" >
|
||||
select * from lz_flow_change where flow_record_id=#{flowRecordId} and type = #{type} and is_delete = 0 order by id desc limit 1
|
||||
</select>
|
||||
|
||||
</mapper>
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user