CMM 1 year ago
parent
commit
c804d71332
4 changed files with 14 additions and 8 deletions
  1. +4
    -0
      pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/entity/dto/DeclaredProjectDto.java
  2. +6
    -6
      pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/manage/DeclaredProjectManage.java
  3. +3
    -1
      pmapi/src/main/java/com/ningdatech/pmapi/todocenter/manage/TodoCenterManage.java
  4. +1
    -1
      pmapi/src/main/resources/application-dev.yml

+ 4
- 0
pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/entity/dto/DeclaredProjectDto.java View File

@@ -1,6 +1,7 @@
package com.ningdatech.pmapi.projectdeclared.entity.dto; package com.ningdatech.pmapi.projectdeclared.entity.dto;


import com.ningdatech.pmapi.projectlib.model.entity.Project; import com.ningdatech.pmapi.projectlib.model.entity.Project;
import com.wflow.workflow.bean.dto.ProcessInstanceUserDto;
import lombok.AllArgsConstructor; import lombok.AllArgsConstructor;
import lombok.Builder; import lombok.Builder;
import lombok.Data; import lombok.Data;
@@ -30,4 +31,7 @@ public class DeclaredProjectDto implements Serializable {


@NotBlank @NotBlank
private String regionCode; private String regionCode;

@NotNull
private ProcessInstanceUserDto user;
} }

+ 6
- 6
pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/manage/DeclaredProjectManage.java View File

@@ -140,12 +140,12 @@ public class DeclaredProjectManage {
} }


ProcessStartParamsVo params = new ProcessStartParamsVo(); ProcessStartParamsVo params = new ProcessStartParamsVo();
ProcessInstanceUserDto user = new ProcessInstanceUserDto();
user.setOrgCode("6179678");
user.setOrgName("数转办");
user.setUserId("381496");
user.setUserName("旅人");
params.setUser(user);
// ProcessInstanceUserDto user = new ProcessInstanceUserDto();
// user.setOrgCode("6179678");
// user.setOrgName("数转办");
// user.setUserId("381496");
// user.setUserName("旅人");
params.setUser(dto.getUser());
params.setProcessUsers(Collections.emptyMap()); params.setProcessUsers(Collections.emptyMap());
dto.getFormData().putAll( dto.getFormData().putAll(
JSON.parseObject(JSON.toJSONString(dto.getProjectInfo()), new TypeReference<Map<String, Object>>() { JSON.parseObject(JSON.toJSONString(dto.getProjectInfo()), new TypeReference<Map<String, Object>>() {


+ 3
- 1
pmapi/src/main/java/com/ningdatech/pmapi/todocenter/manage/TodoCenterManage.java View File

@@ -49,6 +49,7 @@ import com.wflow.exception.BusinessException;
import com.wflow.mapper.WflowCcTasksMapper; import com.wflow.mapper.WflowCcTasksMapper;
import com.wflow.mapper.WflowModelHistorysMapper; import com.wflow.mapper.WflowModelHistorysMapper;
import com.wflow.service.OrgRepositoryService; import com.wflow.service.OrgRepositoryService;
import com.wflow.utils.CodeUtil;
import com.wflow.workflow.bean.dto.ProcessInstanceUserDto; import com.wflow.workflow.bean.dto.ProcessInstanceUserDto;
import com.wflow.workflow.bean.process.OrgUser; import com.wflow.workflow.bean.process.OrgUser;
import com.wflow.workflow.bean.process.ProcessNode; import com.wflow.workflow.bean.process.ProcessNode;
@@ -743,7 +744,8 @@ public class TodoCenterManage {
.result(ProcessHandlerEnum.PASS) .result(ProcessHandlerEnum.PASS)
.build()); .build());
// 提取全量表单数据 // 提取全量表单数据
Map<String, Object> formData = formDatas.stream().collect(Collectors.toMap(HistoricVariableInstance::getVariableName, HistoricVariableInstance::getValue));
Map<String, Object> formData = formDatas.stream().filter(CodeUtil.distinctByKey(HistoricVariableInstance::getVariableName)).collect(Collectors.toMap(HistoricVariableInstance::getVariableName,
HistoricVariableInstance::getValue));
HistoricVariableInstance variableInstance = historyService.createHistoricVariableInstanceQuery() HistoricVariableInstance variableInstance = historyService.createHistoricVariableInstanceQuery()
.processInstanceId(instanceId).variableName("owner").singleResult(); .processInstanceId(instanceId).variableName("owner").singleResult();
ProcessInstanceUserDto owner = (ProcessInstanceUserDto) variableInstance.getValue(); ProcessInstanceUserDto owner = (ProcessInstanceUserDto) variableInstance.getValue();


+ 1
- 1
pmapi/src/main/resources/application-dev.yml View File

@@ -1,5 +1,5 @@
server: server:
port: 28888
port: 38888
servlet: servlet:
context-path: /pm context-path: /pm




Loading…
Cancel
Save