Browse Source

bug 修改

wang 4 weeks ago
parent
commit
ebb21d32b8

+ 1 - 1
system/src/main/resources/bootstrap.yml

@@ -1,3 +1,3 @@
 spring:
   profiles:
-    active: test
+    active: pro

+ 0 - 16
test/src/main/java/com/tofly/StartApplication.java

@@ -1,16 +0,0 @@
-package com.tofly;
-
-import org.springframework.boot.SpringApplication;
-import org.springframework.boot.autoconfigure.SpringBootApplication;
-import org.springframework.cloud.openfeign.EnableFeignClients;
-
-@SpringBootApplication
-@EnableFeignClients
-public class StartApplication {
-
-    public static void main(String[] args) {
-        SpringApplication.run(StartApplication.class, args);
-    }
-
-
-}

+ 0 - 96
test/src/main/java/com/tofly/controller/TestController.java

@@ -1,96 +0,0 @@
-package com.tofly.controller;
-
-import com.tofly.client.MinioFileClient;
-import com.tofly.client.MinioFileUploadClient;
-import com.tofly.common.core.result.ResultData;
-import com.tofly.vo.FileInfo;
-import com.tofly.vo.FileUploadResponse;
-import feign.Response;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.http.HttpHeaders;
-import org.springframework.http.MediaType;
-import org.springframework.http.ResponseEntity;
-import org.springframework.web.bind.annotation.*;
-import org.springframework.web.multipart.MultipartFile;
-
-import javax.servlet.http.HttpServletResponse;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.OutputStream;
-import java.util.List;
-
-
-@RestController
-@RequestMapping("testupload")
-public class TestController {
-@Autowired
-private MinioFileClient minioFileClient;
-
-    @RequestMapping("/getFile")
-    public ResultData  test2(){
-        final FileInfo byFileId = minioFileClient.getByFileId("1");
-        return new ResultData().ok(byFileId);
-    }
-    @PostMapping("/uploadFile")
-    public ResultData  test3(@RequestPart("file") MultipartFile file){
-        final FileUploadResponse test = minioFileClient.uploadFile(file);
-        return new ResultData().ok(test);
-    }
-    @PostMapping("/uploadZip")
-    public ResultData  testuploadzip(@RequestPart("file") MultipartFile file){
-        final ResponseEntity<List<FileInfo>> listResponseEntity = minioFileClient.uploadZip( file);
-        return new ResultData().ok(listResponseEntity.getBody());
-    }
-
-    @GetMapping("/downZip")
-    public void  testDownloadzip(String[] fileNames, HttpServletResponse response){
-        final ResponseEntity<byte[]> responseEntity = minioFileClient.downloadZip(fileNames);
-        final byte[] zipContent = responseEntity.getBody();
-
-        if (zipContent != null) {
-            response.setStatus(HttpServletResponse.SC_OK);
-            response.setHeader(HttpHeaders.CONTENT_DISPOSITION, "attachment; filename=downloaded_files.zip");
-            response.setContentType(MediaType.APPLICATION_OCTET_STREAM_VALUE);
-            response.setContentLength(zipContent.length);
-            try {
-                response.getOutputStream().write(zipContent);
-                response.getOutputStream().flush();
-            } catch (IOException e) {
-                e.printStackTrace();
-                response.setStatus(HttpServletResponse.SC_INTERNAL_SERVER_ERROR);
-            }
-        } else {
-            response.setStatus(HttpServletResponse.SC_INTERNAL_SERVER_ERROR);
-        }
-    }
-
-    @GetMapping("/getFileInfo")
-    public ResultData  test3(String fileName){
-        final FileInfo fileInfo = minioFileClient.getFileInfo(fileName);
-
-        return new ResultData().ok(fileInfo);
-    }
-
-    @GetMapping("/download")
-    public void  test3(String fileName, HttpServletResponse response){
-        Response feignResponse = minioFileClient.download(fileName);
-
-        response.setContentType("application/octet-stream");
-        response.setHeader("Content-Disposition", "attachment; filename=\"" + fileName + "\"");
-
-        try (InputStream inputStream = feignResponse.body().asInputStream();
-             OutputStream outputStream = response.getOutputStream()) {
-
-            byte[] buffer = new byte[8192];
-            int bytesRead;
-
-            while ((bytesRead = inputStream.read(buffer)) != -1) {
-                outputStream.write(buffer, 0, bytesRead);
-            }
-        } catch (IOException e) {
-            e.printStackTrace();
-            // Handle exception
-        }
-
-    }
-}

+ 0 - 39
test/src/main/resources/bootstrap-dev.yml

@@ -1,39 +0,0 @@
-spring:
-   cloud:
-      nacos:
-         config:
-            # nacos配置中心指定空间
-            namespace: tofly-zmrq
-            # nacos部署IP
-            server-addr: 192.168.2.6:8848
-            # 配置后缀
-            file-extension: yaml
-            shared-configs[0]:
-               dataId: public_config_public.yaml
-            shared-configs[1]:
-               dataId: public_config_oracle.yaml
-            shared-configs[2]:
-               dataId: public_config_ftp.yaml
-            shared-configs[3]:
-               dataId: public_config_redis.yaml
-            username: nacos
-            password: nacos
-         discovery:
-            # nacos配置中心指定空间
-            namespace: tofly-zmrq
-            # nacos部署IP
-            server-addr: 192.168.2.6:8848
-         username: nacos
-         password: nacos
-   application:
-      # 该应用在nacos配置中的名称
-      name: tofly-flow-test
-
-
-tofly:
-   filecenter:
-      url: http://192.168.2.6:29001/
-   bucket:
-      name: test18
-   minio:
-      localDownUrl: http://192.168.2.15/tofly-flow-test/

+ 0 - 3
test/src/main/resources/bootstrap.yml

@@ -1,3 +0,0 @@
-spring:
-  profiles:
-    active: dev

+ 5 - 4
workflow/src/main/java/com/tofly/workflow/process/service/impl/TfProcessNodeLServiceImpl.java

@@ -476,10 +476,11 @@ public class TfProcessNodeLServiceImpl extends ServiceImpl<TfProcessNodeLMapper,
                 .eq(TfProcessNodeL::getIsTemp, FlowConstant.SHORT_ZERO)
                 .and(r -> r.eq(TfProcessNodeL::getNodeState, FlowConstant.SHORT_ZERO).or().eq(TfProcessNodeL::getNodeState, FlowConstant.SHORT_ONE)));
 
-        Long deptId = CollUtil.isEmpty(SecurityUtils.getUserDeptIds()) ? null : SecurityUtils.getUserDeptIds().get(0);
-        Long postId = CollUtil.isEmpty(SecurityUtils.getUserPostIds()) ? null : SecurityUtils.getUserPostIds().get(0);
-
-        /**本步骤流程配置*/
+     //   Long deptId = CollUtil.isEmpty(SecurityUtils.getUserDeptIds()) ? null : SecurityUtils.getUserDeptIds().get(0);
+      //  Long postId = CollUtil.isEmpty(SecurityUtils.getUserPostIds()) ? null : SecurityUtils.getUserPostIds().get(0);
+        Long deptId=1648492484781731841L;
+        Long postId =1630377365073883139L;
+                /**本步骤流程配置*/
         TfProcessConfigStepL pcs = pCStepService.getOne(new QueryWrapper<TfProcessConfigStepL>().lambda()
                 .eq(TfProcessConfigStepL::getConfigId, processL.getConfigId())
                 .eq(TfProcessConfigStepL::getStepOrder, pNode.getProcessStep())

+ 7 - 0
workflow/src/main/java/com/tofly/workflow/wzyy/service/impl/MaterialOutInServiceImpl.java

@@ -245,6 +245,12 @@ public class MaterialOutInServiceImpl extends ServiceImpl<MaterialOutInMapper, M
         retDto.set_status(FlowConstant.INSERT);
         retDto.setResubmitCheckKey(String.valueOf(parseLong));
         retDto.setAccountOrg(yyOrg.getOrgCode());
+        //库管员和 部门id
+
+        retDto.setStockMgr(pm.getHandleUser());
+        //
+        retDto.setDepartment(pm.getDeptCode());
+
         //自定义项特征
         OutDefineDto defineDto = new OutDefineDto();
         // 租户id用友不允许用 ytenant ytenantid
@@ -254,6 +260,7 @@ public class MaterialOutInServiceImpl extends ServiceImpl<MaterialOutInMapper, M
 //        defineDto.setXm001Name(pm.getProjectName());
         //defineDto.setXmgly(String.valueOf(pm.getDutyUser()));
         defineDto.setXmglyName(pm.getDutyUserNAME());
+        defineDto.setDz(pm.getAddr());
         defineDto.setA001(pm.getStaffName());
         defineDto.setA02(pm.getProcessNumber());
         defineDto.setXmx(pm.getProjectName());

+ 1 - 1
workflow/src/main/resources/bootstrap.yml

@@ -1,3 +1,3 @@
 spring:
   profiles:
-    active: pro
+    active: wz

File diff suppressed because it is too large
+ 14 - 0
workflow/src/test/java/com/tofly/workflow/FlowApplicationTest.java