V2.4.1 发布~

pull/169/head v2.4.1(jdk17/21)
YunaiV 2025-02-09 12:35:47 +08:00
parent d27536ffc1
commit c2de5d9c8c
3 changed files with 46 additions and 2 deletions

View File

@ -30,7 +30,7 @@
<url>https://github.com/YunaiV/ruoyi-vue-pro</url> <url>https://github.com/YunaiV/ruoyi-vue-pro</url>
<properties> <properties>
<revision>2.4.0-SNAPSHOT</revision> <revision>2.4.1-SNAPSHOT</revision>
<!-- Maven 相关 --> <!-- Maven 相关 -->
<java.version>17</java.version> <java.version>17</java.version>
<maven.compiler.source>${java.version}</maven.compiler.source> <maven.compiler.source>${java.version}</maven.compiler.source>

View File

@ -14,7 +14,7 @@
<url>https://github.com/YunaiV/ruoyi-vue-pro</url> <url>https://github.com/YunaiV/ruoyi-vue-pro</url>
<properties> <properties>
<revision>2.4.0-SNAPSHOT</revision> <revision>2.4.1-SNAPSHOT</revision>
<flatten-maven-plugin.version>1.6.0</flatten-maven-plugin.version> <flatten-maven-plugin.version>1.6.0</flatten-maven-plugin.version>
<!-- 统一依赖管理 --> <!-- 统一依赖管理 -->
<spring.boot.version>3.4.1</spring.boot.version> <spring.boot.version>3.4.1</spring.boot.version>

View File

@ -0,0 +1,44 @@
package cn.iocoder.yudao.module.bpm.service.task.trigger;
import cn.hutool.core.collection.CollUtil;
import cn.iocoder.yudao.framework.common.util.json.JsonUtils;
import cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.model.simple.BpmSimpleModelNodeVO.TriggerSetting.NormalFormTriggerSetting;
import cn.iocoder.yudao.module.bpm.enums.definition.BpmTriggerTypeEnum;
import cn.iocoder.yudao.module.bpm.service.task.BpmProcessInstanceService;
import jakarta.annotation.Resource;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;
// TODO @jason改成 BpmFormUpdateTrigger
/**
* BPM
*
* @author jason
*/
@Component
@Slf4j
public class BpmUpdateNormalFormTrigger implements BpmTrigger {
@Resource
private BpmProcessInstanceService processInstanceService;
@Override
public BpmTriggerTypeEnum getType() {
return BpmTriggerTypeEnum.UPDATE_NORMAL_FORM;
}
@Override
public void execute(String processInstanceId, String param) {
// 1. 解析更新流程表单配置
NormalFormTriggerSetting setting = JsonUtils.parseObject(param, NormalFormTriggerSetting.class);
if (setting == null) {
log.error("[execute][流程({}) 更新流程表单触发器配置为空]", processInstanceId);
return;
}
// 2.更新流程变量
if (CollUtil.isNotEmpty(setting.getUpdateFormFields())) {
processInstanceService.updateProcessInstanceVariables(processInstanceId, setting.getUpdateFormFields());
}
}
}