适配 Vue3 工作流的预览版
This commit is contained in:
parent
7b74c28148
commit
a3ec21cb0f
@ -44,7 +44,7 @@
|
|||||||
<opentracing.version>0.33.0</opentracing.version>
|
<opentracing.version>0.33.0</opentracing.version>
|
||||||
<!-- Test 测试相关 -->
|
<!-- Test 测试相关 -->
|
||||||
<podam.version>7.2.11.RELEASE</podam.version>
|
<podam.version>7.2.11.RELEASE</podam.version>
|
||||||
<jedis-mock.version>1.0.5</jedis-mock.version>
|
<jedis-mock.version>1.0.6</jedis-mock.version>
|
||||||
<mockito-inline.version>4.11.0</mockito-inline.version>
|
<mockito-inline.version>4.11.0</mockito-inline.version>
|
||||||
<!-- Bpm 工作流相关 -->
|
<!-- Bpm 工作流相关 -->
|
||||||
<flowable.version>6.8.0</flowable.version>
|
<flowable.version>6.8.0</flowable.version>
|
||||||
|
@ -21,12 +21,8 @@ public class BpmTaskTodoPageReqVO extends PageParam {
|
|||||||
@ApiModelProperty(value = "流程任务名", example = "芋道")
|
@ApiModelProperty(value = "流程任务名", example = "芋道")
|
||||||
private String name;
|
private String name;
|
||||||
|
|
||||||
@ApiModelProperty(value = "开始的创建收间")
|
@ApiModelProperty(value = "创建收间")
|
||||||
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
private LocalDateTime beginCreateTime;
|
private LocalDateTime[] createTime;
|
||||||
|
|
||||||
@ApiModelProperty(value = "结束的创建时间")
|
|
||||||
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
|
||||||
private LocalDateTime endCreateTime;
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -3,7 +3,6 @@ package cn.iocoder.yudao.module.bpm.service.definition;
|
|||||||
import cn.hutool.core.lang.Assert;
|
import cn.hutool.core.lang.Assert;
|
||||||
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
import cn.iocoder.yudao.framework.common.util.json.JsonUtils;
|
import cn.iocoder.yudao.framework.common.util.json.JsonUtils;
|
||||||
import cn.iocoder.yudao.framework.common.util.validation.ValidationUtils;
|
|
||||||
import cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.form.BpmFormCreateReqVO;
|
import cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.form.BpmFormCreateReqVO;
|
||||||
import cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.form.BpmFormPageReqVO;
|
import cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.form.BpmFormPageReqVO;
|
||||||
import cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.form.BpmFormUpdateReqVO;
|
import cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.form.BpmFormUpdateReqVO;
|
||||||
@ -21,7 +20,8 @@ import javax.annotation.Resource;
|
|||||||
import java.util.*;
|
import java.util.*;
|
||||||
|
|
||||||
import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception;
|
import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception;
|
||||||
import static cn.iocoder.yudao.module.bpm.enums.ErrorCodeConstants.*;
|
import static cn.iocoder.yudao.module.bpm.enums.ErrorCodeConstants.FORM_NOT_EXISTS;
|
||||||
|
import static cn.iocoder.yudao.module.bpm.enums.ErrorCodeConstants.MODEL_DEPLOY_FAIL_FORM_NOT_CONFIG;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 动态表单 Service 实现类
|
* 动态表单 Service 实现类
|
||||||
@ -107,17 +107,15 @@ public class BpmFormServiceImpl implements BpmFormService {
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void checkKeyNCName(String key) {
|
|
||||||
if (!ValidationUtils.isXmlNCName(key)) {
|
|
||||||
throw exception(MODEL_KEY_VALID);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
/**
|
||||||
* 校验 Field,避免 field 重复
|
* 校验 Field,避免 field 重复
|
||||||
*
|
*
|
||||||
* @param fields field 数组
|
* @param fields field 数组
|
||||||
*/
|
*/
|
||||||
private void checkFields(List<String> fields) {
|
private void checkFields(List<String> fields) {
|
||||||
|
if (true) { // TODO 芋艿:兼容 Vue3 工作流:因为采用了新的表单设计器,所以暂时不校验
|
||||||
|
return;
|
||||||
|
}
|
||||||
Map<String, String> fieldMap = new HashMap<>(); // key 是 vModel,value 是 label
|
Map<String, String> fieldMap = new HashMap<>(); // key 是 vModel,value 是 label
|
||||||
for (String field : fields) {
|
for (String field : fields) {
|
||||||
BpmFormFieldRespDTO fieldDTO = JsonUtils.parseObject(field, BpmFormFieldRespDTO.class);
|
BpmFormFieldRespDTO fieldDTO = JsonUtils.parseObject(field, BpmFormFieldRespDTO.class);
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
package cn.iocoder.yudao.module.bpm.service.task;
|
package cn.iocoder.yudao.module.bpm.service.task;
|
||||||
|
|
||||||
import cn.hutool.core.collection.CollUtil;
|
import cn.hutool.core.collection.CollUtil;
|
||||||
|
import cn.hutool.core.util.ArrayUtil;
|
||||||
import cn.hutool.core.util.StrUtil;
|
import cn.hutool.core.util.StrUtil;
|
||||||
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
import cn.iocoder.yudao.framework.common.util.date.DateUtils;
|
import cn.iocoder.yudao.framework.common.util.date.DateUtils;
|
||||||
@ -75,11 +76,11 @@ public class BpmTaskServiceImpl implements BpmTaskService {
|
|||||||
if (StrUtil.isNotBlank(pageVO.getName())) {
|
if (StrUtil.isNotBlank(pageVO.getName())) {
|
||||||
taskQuery.taskNameLike("%" + pageVO.getName() + "%");
|
taskQuery.taskNameLike("%" + pageVO.getName() + "%");
|
||||||
}
|
}
|
||||||
if (pageVO.getBeginCreateTime() != null) {
|
if (ArrayUtil.get(pageVO.getCreateTime(), 0) != null) {
|
||||||
taskQuery.taskCreatedAfter(DateUtils.of(pageVO.getBeginCreateTime()));
|
taskQuery.taskCreatedAfter(DateUtils.of(pageVO.getCreateTime()[0]));
|
||||||
}
|
}
|
||||||
if (pageVO.getEndCreateTime() != null) {
|
if (ArrayUtil.get(pageVO.getCreateTime(), 1) != null) {
|
||||||
taskQuery.taskCreatedBefore(DateUtils.of(pageVO.getEndCreateTime()));
|
taskQuery.taskCreatedBefore(DateUtils.of(pageVO.getCreateTime()[1]));
|
||||||
}
|
}
|
||||||
// 执行查询
|
// 执行查询
|
||||||
List<Task> tasks = taskQuery.listPage(PageUtils.getStart(pageVO), pageVO.getPageSize());
|
List<Task> tasks = taskQuery.listPage(PageUtils.getStart(pageVO), pageVO.getPageSize());
|
||||||
|
Loading…
Reference in New Issue
Block a user