浏览代码

合同字段

ljy121 1 年之前
父节点
当前提交
d7f1ccbd61

+ 2 - 0
zjugis-business/src/main/java/com/zjugis/business/bean/response/ContractResponse.java

@@ -222,4 +222,6 @@ public class ContractResponse {
 
     private Integer flowStatus;
 
+    private String bz;
+
 }

+ 13 - 8
zjugis-business/src/main/java/com/zjugis/business/controller/ProjectMaterialController.java

@@ -1,12 +1,13 @@
 package com.zjugis.business.controller;
 
+import com.zjugis.business.bean.entity.Project;
 import com.zjugis.business.bean.entity.ProjectMaterial;
-import com.zjugis.business.bean.request.ProjectMaterialCategoryRequest;
 import com.zjugis.business.bean.request.ProjectMaterialRequest;
-import com.zjugis.business.bean.response.MaterialTreeNode;
 import com.zjugis.business.service.ProjectMaterialService;
+import com.zjugis.business.service.ProjectService;
 import com.zjugis.framework.common.pojo.CommonResult;
 import com.zjugis.framework.workflow.rpc.remote.WorkflowClient;
+import com.zjugis.framework.workflow.utils.zTree;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.web.bind.annotation.*;
 
@@ -28,6 +29,9 @@ public class ProjectMaterialController {
     @Resource
     private ProjectMaterialService projectMaterialService;
 
+    @Autowired
+    private ProjectService projectService;
+
     @Autowired
     WorkflowClient workflowClient;
 
@@ -55,14 +59,15 @@ public class ProjectMaterialController {
     }
 
 
-    @PostMapping("/project-material/category")
-    public CommonResult<Long> category(@Valid @RequestBody ProjectMaterialCategoryRequest category) throws Exception {
-        return CommonResult.success(projectMaterialService.category(category));
-    }
+//    @PostMapping("/project-material/category")
+//    public CommonResult<Long> category(@Valid @RequestBody ProjectMaterialCategoryRequest category) throws Exception {
+//        return CommonResult.success(projectMaterialService.category(category));
+//    }
 
     @PostMapping("/project-material/tree")
-    public CommonResult<List<MaterialTreeNode>> tree(@Valid @RequestBody ProjectMaterialRequest p) throws Exception {
-        return CommonResult.success(projectMaterialService.tree(p));
+    public CommonResult<List<zTree>> tree(@Valid @RequestBody ProjectMaterialRequest p) throws Exception {
+        Project project = projectService.selectDOById(p.getProjectId());
+        return workflowClient.getMaterialTree(project.getInstanceId(),null);
     }
 
     /**

+ 7 - 3
zjugis-framework/zjugis-spring-boot-starter-workflow/src/main/java/com/zjugis/framework/workflow/rpc/remote/WorkflowClient.java

@@ -2,8 +2,12 @@ package com.zjugis.framework.workflow.rpc.remote;
 
 import com.zjugis.framework.common.pojo.CommonResult;
 import com.zjugis.framework.workflow.model.*;
+import com.zjugis.framework.workflow.utils.zTree;
 import org.springframework.cloud.openfeign.FeignClient;
-import org.springframework.web.bind.annotation.*;
+import org.springframework.web.bind.annotation.GetMapping;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestParam;
 
 import javax.validation.Valid;
 import java.util.List;
@@ -55,6 +59,6 @@ public interface WorkflowClient {
     String getUserTreeAll();
 
 
-    @PostMapping("/ActivityInstanceApi/getTree")
-    String getTree(@RequestParam("flowInstanceId")String flowInstanceId, @RequestParam("activityInstanceId")String activityInstanceId);
+    @PostMapping("/ActivityInstanceApi/getMaterialTree")
+    CommonResult<List<zTree>> getMaterialTree(@RequestParam("flowInstanceId")String flowInstanceId, @RequestParam("activityInstanceId")String activityInstanceId);
 }

+ 1 - 1
zjugis-workflow/src/main/java/com/zjugis/z_workflow/serviceApi/ActivityInstanceApiController.java

@@ -195,7 +195,7 @@ public class ActivityInstanceApiController extends BaseController {
 
     @ResponseBody
     @RequestMapping
-    public CommonResult<List<zTree>> getTree(String flowInstanceId, String activityInstanceId) throws Exception {
+    public CommonResult<List<zTree>> getMaterialTree(String flowInstanceId, String activityInstanceId) throws Exception {
         return CommonResult.success(iFlowMaterialsTreeService.getTree(flowInstanceId, activityInstanceId));
     }
 }