yourName 1 년 전
부모
커밋
1f72e768f8

+ 0 - 4
.gitignore

@@ -6,10 +6,6 @@ rebel.xml
 out/artifacts/
 dil-api.iml
 src/test
-/src/main/resources/application-dev.yml
-/src/main/resources/application-prod.yml
-/src/main/resources/bootstrap.yml
-.gitignore
 # Compiled class file
 *.class
 

+ 5 - 1
pom.xml

@@ -70,7 +70,11 @@
             <artifactId>mybatis-plus-boot-starter</artifactId>
             <version>3.4.2</version>
         </dependency>
-
+        <dependency>
+            <groupId>commons-io</groupId>
+            <artifactId>commons-io</artifactId>
+            <version>2.11.0</version>
+        </dependency>
 <!--        <dependency>-->
 <!--            <groupId>org.springframework.boot</groupId>-->
 <!--            <artifactId>spring-boot-starter-security</artifactId>-->

+ 1 - 1
src/main/java/com/steerinfo/dil/annotaion/RequestLimit.java

@@ -10,5 +10,5 @@ import java.lang.annotation.*;
 @Documented
 public @interface RequestLimit {
     int seconds() default 1;//秒
-    int maxCount() default 1;//最大访问次数
+    int maxCount() default 100;//最大访问次数
 }

+ 1 - 1
src/main/java/com/steerinfo/dil/config/RepeatRequestIntercept.java

@@ -44,7 +44,7 @@ public class RepeatRequestIntercept extends HandlerInterceptorAdapter {
                 //判断是否超过最大限定请求次数
                 if (requestCount < max) {
                     //未超过则请求次数+1
-                    redisUtils.incr(key, 1);
+                    redisUtils.incr(key, 100);
                 } else {
                     //否则拒绝请求并返回信息
                     refuse(response);

+ 4 - 3
src/main/java/com/steerinfo/dil/config/RequestFilter.java

@@ -70,9 +70,10 @@ public class RequestFilter implements Filter {
            httpRequest.setAttribute("userId", userId);
            httpRequest.setAttribute("userName", userName);
            httpRequest.setAttribute("orgCode", orgCode);
-           httpRequest.setAttribute("roleCodes", roleCodes);
+           Object roleCodesObject = JSONObject.parse(roleCodes);
+           httpRequest.setAttribute("roleCodes", roleCodesObject);
            Object dilCompanyListObject = JSONObject.parse(dilCompanyList);
-           httpRequest.setAttribute("dilCompanyList",dilCompanyListObject);;
+           httpRequest.setAttribute("dilCompanyList",dilCompanyListObject);
            Object rootCompanyMapObject = JSONObject.parse(rootCompanyMap);
            httpRequest.setAttribute("rootCompanyMap",rootCompanyMapObject);
            //获取RequestBody数据
@@ -88,7 +89,7 @@ public class RequestFilter implements Filter {
                params.put("userId", userId);
                params.put("userName", userName);
                params.put("orgCode", orgCode);
-               params.put("roleCodes",roleCodes);
+               params.put("roleCodes",roleCodesObject);
                params.put("dilCompanyList",dilCompanyListObject);
                params.put("rootCompanyMap",rootCompanyMapObject);
                params.put("accessToken",accessToken);

+ 1 - 1
src/main/java/com/steerinfo/dil/config/SessionInterceptor.java

@@ -39,7 +39,7 @@ public class SessionInterceptor extends HandlerInterceptorAdapter {
             //无权访问
             response.setCharacterEncoding("UTF-8");
             response.setContentType("application/json; charset=utf-8");
-            RESTfulResult result =new RESTfulResult("500", "无权访问", "无权访问");
+            RESTfulResult result =new RESTfulResult("500", "无权访问111", "无权访问");
             response.getWriter().write(JSONObject.toJSONString(result));
             return false;
         }

+ 12 - 5
src/main/java/com/steerinfo/dil/controller/AMScontroller.java

@@ -124,8 +124,6 @@ public class AMScontroller {
             Date dueTime = simpleDateFormat.parse(map.get("dueTime").toString());
             map.put("dueTime", dueTime);
         }
-
-
         return amsFeign.productionRequirementAdd(map);
     }
 
@@ -430,9 +428,9 @@ public class AMScontroller {
 
     @ApiOperation(value = "撤销退货", notes = "根据发货单号将发货单的退货记录清除")
     @ApiImplicitParam(name = "id", value = "查询内容", required = false, dataType = "String")
-    @PostMapping(value = "revokeReturnGoods/{id}")
-    public RESTfulResult revokeReturnGoods(@PathVariable("id") String id) {
-        return amsFeign.revokeReturnGoods(id);
+    @PostMapping(value = "revokeReturnGoods")
+    public RESTfulResult revokeReturnGoods(@RequestBody Map<String, Object> params) {
+        return amsFeign.revokeReturnGoods(params);
     }
 
     @ApiOperation(value = "查询发货单第几次退库", notes = "查询发货单第几次退库")
@@ -728,4 +726,13 @@ public class AMScontroller {
     public RESTfulResult getUpdateDlivDirno(@RequestBody Map<String, Object> map) {
         return amsFeign.getUpdateDlivDirno(map);
     }
+
+    @ApiOperation(value = "发运通知单修改", notes = "发运通知单修改")
+    @ApiImplicitParams({
+            @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map<String,Object>")
+    })
+    @PostMapping(value = "/saleUpdate")
+    public RESTfulResult saleUpdate(@RequestBody Map<String, Object> map) {
+        return amsFeign.saleUpdate(map);
+    }
 }

+ 1 - 1
src/main/java/com/steerinfo/dil/controller/EMSController.java

@@ -148,7 +148,7 @@ public class EMSController extends BaseRESTfulController {
                                              Integer pageNum,
                                              Integer pageSize
     ) {
-        return emsFeign.emsdetailsordersList(mapValue == null ? new HashMap<>() : mapValue, apiId, pageNum, pageSize);
+        return emsFeign.emssalarydetailsList(mapValue == null ? new HashMap<>() : mapValue, apiId, pageNum, pageSize);
     }
 
     @ApiOperation(value = "新增详单明细")

+ 37 - 0
src/main/java/com/steerinfo/dil/controller/ReportController.java

@@ -0,0 +1,37 @@
+package com.steerinfo.dil.controller;
+
+import com.steerinfo.dil.feign.ReportFeign;
+import io.swagger.annotations.ApiImplicitParam;
+import io.swagger.annotations.ApiImplicitParams;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+
+import java.util.HashMap;
+import java.util.Map;
+
+@RestController
+@RequestMapping("${api.version}/report")
+public class ReportController {
+
+    @Autowired
+    ReportFeign reportFeign;
+
+    @ApiOperation(value="展示汽运监控")
+    @ApiImplicitParams({
+            @ApiImplicitParam(name = "mapValue", value = "参数", required = false, dataType = "map"),
+            @ApiImplicitParam(name = "apiId()", value = "动态表头", required = false, dataType = "Integer"),
+            @ApiImplicitParam(name = "pageNum", value = "页码", required = false, dataType = "Integer"),
+            @ApiImplicitParam(name = "pageSize", value = "页", required = false, dataType = "Integer"),
+    })
+    @PostMapping(value = "/getQYMonitors")
+    Map<String, Object> getQYMonitors(@RequestBody(required=false) HashMap<String,Object> mapValue,
+                                        Integer apiId,
+                                        Integer pageNum,
+                                        Integer pageSize){
+        return reportFeign.getQYMonitors(mapValue == null ? new HashMap<>() : mapValue,apiId,pageNum,pageSize);
+    }
+}

+ 117 - 28
src/main/java/com/steerinfo/dil/controller/SystemFileController.java

@@ -16,16 +16,23 @@ import io.swagger.annotations.ApiOperation;
 import org.apache.commons.lang3.StringUtils;
 import org.apache.shiro.authz.annotation.RequiresPermissions;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.util.MultiValueMap;
 import org.springframework.web.bind.annotation.*;
 import org.springframework.web.multipart.MultipartFile;
 import org.springframework.web.multipart.MultipartRequest;
 
 import javax.annotation.Resource;
+import javax.imageio.ImageIO;
+import java.awt.*;
+import java.awt.image.BufferedImage;
+import java.io.ByteArrayInputStream;
+import java.io.ByteArrayOutputStream;
 import java.io.IOException;
 import java.io.InputStream;
 import java.text.SimpleDateFormat;
 import java.util.*;
 import java.math.BigDecimal;
+import java.util.List;
 
 /**
  * SystemFile RESTful接口:
@@ -157,11 +164,11 @@ public class SystemFileController extends BaseRESTfulController {
     public RESTfulResult insertFiles(String[] fileUuids, String[] fileNames, String[] fileTypes, Map<Object, MultipartFile> FileList, MultipartRequest request) throws Exception {
 
 
-        List<MultipartFile> files  = new ArrayList<>();
-        int index=-1;
-        for(int j = 0 ; j < fileTypes.length ; j ++ ) {
-            for(int i=0;i<21;i++) {
-                MultipartFile file = request.getFile("file" +j +"" + i);
+        List<MultipartFile> files = new ArrayList<>();
+        int index = -1;
+        for (int j = 0; j < fileTypes.length; j++) {
+            for (int i = 0; i < 21; i++) {
+                MultipartFile file = request.getFile("file" + j + "" + i);
                 if (file != null) {
                     files.add(file);
                     if (index < 0) {
@@ -171,7 +178,7 @@ public class SystemFileController extends BaseRESTfulController {
             }
         }
 
-        if(files.size() == 0) {
+        if (files.size() == 0) {
             return failed("传输失败");
         }
         for (int i = 0; i < fileUuids.length; i++) {
@@ -233,22 +240,22 @@ public class SystemFileController extends BaseRESTfulController {
 
         SystemFile value = systemFileMapper.selectByPrimaryKey(parmas.get("id").toString());
 
-            String fileName = value.getFilename();
-            String filepath = value.getFilepath();
-            if (fileName == null || fileName.isEmpty()) {
-                return failed("该图片不存在!");
-            }
-            if (filepath == null || filepath.isEmpty()) {
-                return failed("该图片地址不存在!");
-            }
+        String fileName = value.getFilename();
+        String filepath = value.getFilepath();
+        if (fileName == null || fileName.isEmpty()) {
+            return failed("该图片不存在!");
+        }
+        if (filepath == null || filepath.isEmpty()) {
+            return failed("该图片地址不存在!");
+        }
 
-            try {
-                String result = ftpFileUtil.downloadFile(fileName, filepath);
-                return success(result);
-            } catch (IOException e) {
-                e.getMessage();
-                return failed();
-            }
+        try {
+            String result = ftpFileUtil.downloadFile(fileName, filepath);
+            return success(result);
+        } catch (IOException e) {
+            e.getMessage();
+            return failed();
+        }
 
     }
 
@@ -303,22 +310,24 @@ public class SystemFileController extends BaseRESTfulController {
 
     @PostMapping("/previewfileList")
     public RESTfulResult previewfileList(@RequestBody HashMap map) {
-        String uuid =  map.get("uuid").toString();
+        String uuid = map.get("uuid").toString();
         String[] uuidList = uuid.split(";");
         //遍历数组,去找文件名称和路径
-        List<Map<String,Object>> mapList = systemFileMapper.getFileInfo(uuidList);
-        List<Map<String,Object>> resultList = new ArrayList<>();
-        for (Map<String,Object> parmas : mapList) {
+        List<Map<String, Object>> mapList = systemFileMapper.getFileInfo(uuidList);
+        List<Map<String, Object>> resultList = new ArrayList<>();
+        for (Map<String, Object> parmas : mapList) {
             String filename = parmas.get("FILENAME").toString();
             String filepath = parmas.get("FILEPATH").toString();
-            if (filename == null ||filename.isEmpty()) {
+            if (filename == null || filename.isEmpty()) {
                 return failed("该图片不存在!");
             }
-            if (filepath == null ||filepath.isEmpty()) {
+            if (filepath == null || filepath.isEmpty()) {
                 return failed("该图片地址不存在!");
             }
             try {
-                Map<String,Object> result = ftpFileUtil.downloadFileNew(filename, filepath);
+                Map<String, Object> result = ftpFileUtil.downloadFileNew(filename, filepath);
+                //如果是返回base64,则给这个;网络路径则给netUrl
+                result.put("dataType","base");
                 resultList.add(result);
             } catch (IOException e) {
                 e.getMessage();
@@ -330,4 +339,84 @@ public class SystemFileController extends BaseRESTfulController {
     }
 
 
+    @PostMapping("/insertFilesReal")
+    public RESTfulResult insertFilesReal(MultipartRequest request, String[] uuidTypes) throws Exception {
+        //List<MultipartFile> files  = new ArrayList<>();
+        //获取多个文件
+        MultiValueMap<String, MultipartFile> multiFileMap = request.getMultiFileMap();
+        List<MultipartFile> files = multiFileMap.get("file");
+        System.out.println(uuidTypes + "uuidTypes");
+        System.out.println(request);
+        if (files.size() == 0) {
+            return failed("传输失败");
+        }
+        int index = 0;
+        for (MultipartFile file : files) {
+            String uuidType = uuidTypes[index];
+            String fileMediaType = file.getContentType();
+            String newName = uuidType.split(";")[0];
+
+            String uuid = uuidType.split(";")[0];
+            String fileType = uuidType.split(";")[1];
+            InputStream inputStream = file.getInputStream();
+            if (fileMediaType != null && fileMediaType.contains("image")) {
+                newName = uuidType.split(";")[0] + "." +fileMediaType.split("/")[1];
+                ////如果是图片
+                //BufferedImage originalImage = ImageIO.read(inputStream);
+                //// 确保原始图片有效且可以读取
+                //if (originalImage != null) {
+                //    // 添加水印逻辑
+                //    inputStream = addWatermark(originalImage);
+                //    // 保存或返回带有水印的图片
+                //    // ...
+                //}
+            }
+            SimpleDateFormat simpleDateFormat = new SimpleDateFormat("/yyyy/MM/dd");
+            String filePath = simpleDateFormat.format(new Date()) + "/" + fileType;
+            boolean result = ftpFileUtil.uploadToFtp(inputStream, filePath, newName, false);
+            inputStream.close();
+            if (result) {
+                SystemFile uploadFile = new SystemFile();
+                uploadFile.setFilename(newName);
+                uploadFile.setFilepath(filePath + "/" + newName);
+                uploadFile.setId(uuid);
+                SystemFile modela = systemFileService.add(uploadFile);
+                if (modela != null) {
+                    uuid += "," + modela.getId();
+                }
+            } else {
+                return failed(null, "上传文件失败");
+            }
+            index++;
+        }
+        return success();
+}
+
+    //private InputStream addWatermark(BufferedImage originalImage) {
+    //    int width = originalImage.getWidth();
+    //    int height = originalImage.getHeight();
+    //
+    //    //BufferedImage watermarkedImage = Scalr.resize(originalImage, width, height, Scalr.Mode.FIT_EXACT);
+    //
+    //    Graphics2D graphics = watermarkedImage.createGraphics();
+    //
+    //    // 设置水印样式
+    //    graphics.setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING, RenderingHints.VALUE_TEXT_ANTIALIAS_ON);
+    //    Font font = new Font("Arial", Font.BOLD, 30);
+    //    graphics.setFont(font);
+    //    Color color = new Color(255, 0, 0, 128);
+    //    graphics.setColor(color);
+    //
+    //    // 添加水印文字
+    //    graphics.drawString("Your Watermark Text", 10, height - 40); // 示例位置
+    //
+    //    graphics.dispose();
+    //
+    //    // 将带水印的图片转为InputStream
+    //    ByteArrayOutputStream baos = new ByteArrayOutputStream();
+    //    ImageIO.write(watermarkedImage, "jpg", baos);
+    //    InputStream watermarkedStream = new ByteArrayInputStream(baos.toByteArray());
+    //
+    //    return watermarkedStream;
+    //}
 }

+ 13 - 0
src/main/java/com/steerinfo/dil/controller/TMSController.java

@@ -190,6 +190,7 @@ public class TMSController extends BaseRESTfulController {
     @ApiImplicitParam(name = "map", value = "JSON格式数据", required = true, dataType = "Map<String, Object>")
     @PostMapping(value = "/startend")
     @LogAround(foreignKeys = {"resultId"}, foreignKeyTypes = {"计时"})
+    @RequestLimit
     public Map<String, Object> start(@RequestBody(required = false) Map<String, Object> map) {
         return tmsFeign.startend(map);
     }
@@ -687,4 +688,16 @@ public class TMSController extends BaseRESTfulController {
     public RESTfulResult selectDlivDirnoSeqDetails(@RequestBody  Map<String,Object> map) {
         return tmsFeign.selectDlivDirnoSeqDetails(map);
     }
+
+    @ApiOperation("查询订单厂内轨迹")
+    @PostMapping("/getPathByOrder")
+    public RESTfulResult getPathByOrder(@RequestBody  Map<String,Object> map) {
+        return tmsFeign.getPathByOrder(map);
+    }
+
+    @ApiOperation("上传定位,更新路径")
+    @PostMapping("/uploadLocation")
+    public RESTfulResult uploadLocation(@RequestBody  Map<String,Object> map) {
+        return tmsFeign.uploadLocation(map);
+    }
 }

+ 9 - 0
src/main/java/com/steerinfo/dil/controller/UniversalController.java

@@ -65,6 +65,8 @@ public class UniversalController extends BaseRESTfulController {
         return success(list);
     }
 
+
+
     @ApiModelProperty(value = "边输边查运力类型")
     @PostMapping("/getCapacityTypeByLike")
     public RESTfulResult getCapacityTypeByLike(@RequestBody(required = false) Map<String,Object> map) {
@@ -224,4 +226,11 @@ public class UniversalController extends BaseRESTfulController {
         String idCardCode = universalMapper.getIdCardCode(map);
         return success(idCardCode);
     }
+
+    @ApiOperation("根据物料编码获取物料信息")
+    @PostMapping("/getMaterial")
+    public RESTfulResult getMaterial(@RequestBody Map<String,Object> map) {
+        List<Map<String, Object>> material = universalMapper.getMaterial(map);
+        return success(material);
+    }
 }

+ 6 - 3
src/main/java/com/steerinfo/dil/feign/AmsFeign.java

@@ -166,8 +166,8 @@ public interface AmsFeign {
     @PostMapping(value = "api/v1/ams/amsrequirementchilds/returnGoods")
     RESTfulResult returnGoods(@RequestBody(required = false) HashMap<String, Object> params);
 
-    @PostMapping(value = "api/v1/ams/amsrequirementchilds/revokeReturnGoods/{id}")
-    RESTfulResult revokeReturnGoods(@PathVariable("id") String id);
+    @PostMapping(value = "api/v1/ams/amsrequirementchilds/revokeReturnGoods")
+    RESTfulResult revokeReturnGoods(@RequestBody Map<String, Object> params);
 
     @GetMapping(value = "api/v1/ams/amsrequirementchilds/getcut/{dlivDirno}")
     RESTfulResult getcut(@PathVariable String dlivDirno);
@@ -265,6 +265,9 @@ public interface AmsFeign {
                                  @RequestParam Integer pageSize);
 
     @PostMapping(value = "api/v1/ams/amstransrequirements/getUpdateDlivDirno")
-    public RESTfulResult getUpdateDlivDirno(@RequestBody Map<String, Object> map);
+    RESTfulResult getUpdateDlivDirno(@RequestBody Map<String, Object> map);
+
+    @PostMapping(value = "api/v1/ams/amstransrequirements/saleUpdate")
+    RESTfulResult saleUpdate(@RequestBody Map<String, Object> map);
 
 }

+ 19 - 0
src/main/java/com/steerinfo/dil/feign/ReportFeign.java

@@ -0,0 +1,19 @@
+package com.steerinfo.dil.feign;
+
+import org.springframework.cloud.openfeign.FeignClient;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestParam;
+
+import java.util.HashMap;
+import java.util.Map;
+
+@FeignClient(value = "ANTAI-REPORT-API", url = "${openfeign.REPORTFeign.url}")
+public interface ReportFeign {
+
+    @PostMapping(value = "api/v1/report/monitors/getQYMonitors")
+    Map<String, Object> getQYMonitors(@RequestBody(required = false) HashMap<String, Object> map,
+                                        @RequestParam Integer apiId,
+                                        @RequestParam  Integer pageNum,
+                                        @RequestParam  Integer pageSize);
+}

+ 6 - 0
src/main/java/com/steerinfo/dil/feign/TmsFeign.java

@@ -248,6 +248,12 @@ public interface TmsFeign {
     @PostMapping(value = "/api/v1/tms/omstransorders/selectDlivDirnoSeqDetails")
     RESTfulResult selectDlivDirnoSeqDetails(@RequestBody Map<String, Object> map);
 
+
+    @PostMapping(value = "/api/v1/tms/tmsrouteresults/getPathByOrder")
+    RESTfulResult getPathByOrder(@RequestBody Map<String, Object> map);
+
+    @PostMapping(value = "/api/v1/tms/tmsrouteresults/uploadLocation")
+    RESTfulResult uploadLocation(@RequestBody Map<String, Object> map);
 }
 
 

+ 2 - 0
src/main/java/com/steerinfo/dil/mapper/UniversalMapper.java

@@ -71,4 +71,6 @@ public interface UniversalMapper {
 
     String getIdCardCode(Map<String, Object> map);
 
+    List<Map<String, Object>> getMaterial(Map<String, Object> map);
+
 }

+ 1 - 1
src/main/java/com/steerinfo/dil/util/poiutil.java

@@ -15,7 +15,7 @@ import java.nio.charset.StandardCharsets;
 import java.util.*;
 
 
-//导excle工具类
+//导excle工具类
 
 public class poiutil {
     private final static String xls = "xls";

+ 8 - 6
src/main/resources/application-dev.yml

@@ -41,15 +41,15 @@ openfeign:
   ColumnDataFeign:
     url: ${COLUMNDATAFEIGN_URL:172.16.90.214:8083}
   AmsFeign:
-    url: ${AMSFEIGN_URL:localhost:9996}
+    url: ${AMSFEIGN_URL:localhost:8079}
   BmsFeign:
-    url: ${BMSFEIGN_URL:localhost:8078}
+    url: ${BMSFEIGN_URL:172.16.90.214:8078}
   TmsFeign:
     url: ${TMSFEIGN_URL:localhost:8086}
   WMSFeign:
-    url: ${WMSFEIGN_URL:172.16.90.214:8093}
+    url: ${WMSFEIGN_URL:localhost:8093}
   OMSFeign:
-    url: ${OMSFEIGN_URL:localhost:8095}
+    url: ${OMSFEIGN_URL:172.16.90.214:8095}
   RmsFeign:
     url: ${RMSFEIGN_URL:localhost:8060}
   IntegrationFeign:
@@ -57,11 +57,13 @@ openfeign:
   OTMSFeign:
     url: ${OTMSFEIGN_URL:localhost:8038}
   EmsFeign:
-    url: ${TMSFEIGN_URL:localhost:9997}
+    url: ${TMSFEIGN_URL:localhost:8096}
   WebSocketFeign:
-    url: ${WEBSOCKETFEIGN_URL:localhost:9998}
+    url: ${WEBSOCKETFEIGN_URL:localhost:8000}
   SSOFeign:
     url: ${SSOFEIGN_URL:172.16.90.214:9001}
+  REPORTFeign:
+    url: ${REPORTFEIGN_URL:localhost:8055}
 
 
 #远程调用

+ 5 - 3
src/main/resources/application-prod.yml

@@ -26,7 +26,7 @@ openfeign:
   ColumnDataFeign:
     url: ${COLUMNDATAFEIGN_URL:172.16.90.214:8083}
   AmsFeign:
-    url: ${AMSFEIGN_URL:172.16.90.214:9996}
+    url: ${AMSFEIGN_URL:172.16.90.214:8079}
   BmsFeign:
     url: ${BMSFEIGN_URL:172.16.90.214:8078}
   TmsFeign:
@@ -42,11 +42,13 @@ openfeign:
   OTMSFeign:
     url: ${OTMSFEIGN_URL:172.16.90.214:8038}
   EmsFeign:
-    url: ${TMSFEIGN_URL:172.16.90.214:9997}
+    url: ${TMSFEIGN_URL:172.16.90.214:8096}
   SSOFeign:
     url: ${SSOFEIGN_URL:172.16.90.214:9001}
   WebSocketFeign:
-    url: ${WEBSOCKETFEIGN_URL:172.16.90.214:9998}
+    url: ${WEBSOCKETFEIGN_URL:172.16.90.214:8000}
+  REPORTFeign:
+    url: ${REPORTFEIGN_URL:172.16.90.214:8055}
 
 
 #远程调用

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

@@ -1,7 +1,7 @@
 api.version: api/v1
 spring:
   profiles:
-    include: ${SPRING_PROFILES:dev}
+    include: ${SPRING_PROFILES:prod}
   jackson:
     date-format: yyyy-MM-dd HH:mm:ss
     time-zone: GMT+8

+ 71 - 5
src/main/resources/com/steerinfo/dil/mapper/UniversalMapper.xml

@@ -240,11 +240,14 @@
         select * from(
         select * from(
         select
+        MATERIAL_TYPE_ID "operationsNameId",
+        MATERIAL_TYPE_NAME "operationsName",
         MATERIAL_TYPE_ID "id",
         MATERIAL_TYPE_ID "value",
         MATERIAL_TYPE_NAME "label",
         MATERIAL_TYPE_NAME "text",
-        REMARK "remark"
+        REMARK "remark",
+        'operationsName' "prop"
         from RMS_MATERIAL_TYPE
         where DELETED = 0
         )
@@ -475,12 +478,16 @@
         select
         RC.TRANS_RANGE_ID "transrangeId",
             RC.TRANS_RANGE_NAME "transrangeName",
+        RC.TRANS_RANGE_ID "operationRangeId",
+        RC.TRANS_RANGE_NAME "operationRangeName",
         RC.TRANS_RANGE_ID "id",
         RC.TRANS_RANGE_ID "value",
         RC.TRANS_RANGE_NAME "label",
         RC.TRANS_RANGE_NAME "text",
         rc.START_POINT_ID   "shippingPointId",
-        rc.END_POINT_ID     "receivingPointId"
+        rc.END_POINT_ID     "receivingPointId",
+        rc.LINE_ID  "lineId",
+        'operationRangeName' "prop"
         from RMS_TRANS_RANGE RC
         where DELETED = 0
         )
@@ -536,7 +543,9 @@
         RCT.CAPACITY_TYPE_NAME "text",
         RCT .CAPACITY_MAX_LOAD "capacityMaxLoad",
         '[' || listagg (RCFT .FUEL_TYPE_ID, ',') WITHIN GROUP (ORDER BY RCT .CAPACITY_TYPE_ID) || ']' "fuelTypeIds",
-        listagg (RFT .FUEL_TYPE_NAME, '/') WITHIN GROUP (ORDER BY RCT .CAPACITY_TYPE_ID) "fuelTypes"
+
+        listagg (RFT .FUEL_TYPE_NAME, '/') WITHIN GROUP (ORDER BY RCT .CAPACITY_TYPE_ID) "fuelTypes",
+        'capacityTypeName' "prop"
         from RMS_CAPACITY_TYPE RCT
         LEFT JOIN RMS_CAPACITY_FUEL_TYPE RCFT ON RCFT.CAPACITY_TYPE_ID = RCT .CAPACITY_TYPE_ID
         LEFT JOIN RMS_FUEL_TYPE RFT ON RFT .FUEL_TYPE_ID = RCFT.FUEL_TYPE_ID
@@ -585,7 +594,9 @@
         RL.LINE_NAME "label",
         RL.LINE_NAME "text",
         NVL(RL_TEMP."points",'无') "points",
-        RL.LINE_TYPE    "lineType"
+
+        RL.LINE_TYPE    "lineType",
+        'lineName' "prop"
         from RMS_LINE RL
         LEFT JOIN
         (
@@ -649,6 +660,8 @@
     <select id="getMaterialByLike" resultType="java.util.Map">
         select * from(
         select
+        RC.MATERIAL_ID "materialId",
+        RC.MATERIAL_NAME "materialName",
         RC.MATERIAL_ID "id",
         RC.MATERIAL_ID "value",
         RC.MATERIAL_CODE || '-' || RC.MATERIAL_NAME ||
@@ -658,7 +671,9 @@
         THEN '-' || RC.MATERIAL_MODEL
         ELSE ''
         END) "label",
-        RC.MATERIAL_NAME "text"
+
+        RC.MATERIAL_NAME "text",
+        'materialName' "prop"
         from RMS_MATERIAL RC
         <where>
             DELETED = 0
@@ -902,4 +917,55 @@
         FETCH NEXT 1 ROWS ONLY
     </select>
 
+    <select id="getMaterial" parameterType="java.util.Map" resultType="java.util.Map">
+        select t.prod_code_pk as "prodCodePk",
+               b.material_id as "materialId",
+               b.material_code as "prodCode",
+               b.material_name as "prodName",
+               b.material_model as "steelName",
+               t.create_emp as "createEmp",
+               t.create_time as "createTime",
+               b.material_specification as "specName",
+               nvl(substr(b.material_specification,
+                          decode(instr(b.material_specification, '/'),
+                                 0,
+                                 100,
+                                 instr(b.material_specification, '/')) + 1),
+                   12) * b.material_theoretical_weight / 1000 as "weight"
+        from rms_material b
+                 left join rms_material_map t
+                           on t.prod_code_l = b.material_code
+        <where>
+            <if test="prodCode != null and prodCode != ''">
+                and t.prod_code = #{prodCode}
+            </if>
+            <if test="materialId != null and materialId != ''">
+                and b.material_id = #{materialId}
+            </if>
+        </where>
+        union all
+        select '' as "prodCodePk",
+               b.material_id as "materialId",
+               b.material_code as "prodCode",
+               b.material_name as "prodName",
+               b.material_model as "steelName",
+               '' as "createEmp",
+               sysdate as "createTime",
+               b.material_specification as "specName",
+               nvl(substr(b.material_specification,
+                          decode(instr(b.material_specification, '/'),
+                                 0,
+                                 100,
+                                 instr(b.material_specification, '/')) + 1),
+                   12) * b.material_theoretical_weight / 1000 as "weight"
+        from rms_material b
+        <where>
+            <if test="prodCode != null and prodCode != ''">
+                and t.prod_code = #{prodCode}
+            </if>
+            <if test="materialId != null and materialId != ''">
+                and b.material_id = #{materialId}
+            </if>
+        </where>
+    </select>
 </mapper>