فهرست منبع

Merge branch 'master' of https://gitee.com/antai-wuliu/ANTAI-API

Redeem 1 سال پیش
والد
کامیت
9208b95960

+ 5 - 4
src/main/java/com/steerinfo/dil/controller/BackgroundProcessingController.java

@@ -1,6 +1,7 @@
 package com.steerinfo.dil.controller;
 
 
+import com.steerinfo.dil.aspect.LogAspect;
 import com.steerinfo.dil.feign.SSOFeign;
 import com.steerinfo.dil.mapper.BackgroundProcessingMapper;
 import com.steerinfo.dil.mapper.OmstruckOrderMapper;
@@ -10,6 +11,7 @@ import com.steerinfo.dil.util.BaseRESTfulController;
 import com.steerinfo.dil.util.DataChange;
 import com.steerinfo.framework.controller.RESTfulResult;
 import io.swagger.annotations.ApiOperation;
+import org.apache.log4j.Logger;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.transaction.annotation.Transactional;
 import org.springframework.web.bind.annotation.*;
@@ -17,10 +19,7 @@ import com.steerinfo.dil.util.SSOUtil;
 
 import javax.annotation.Resource;
 import java.math.BigDecimal;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
+import java.util.*;
 
 /*
  * 后台处理程序
@@ -37,6 +36,8 @@ public class BackgroundProcessingController extends BaseRESTfulController {
     @Resource
     SSOUtil ssoUtil;
 
+    static final Logger log = Logger.getLogger(BackgroundProcessingController.class);
+
     @ApiOperation("登录接口")
     @PostMapping("bpLogin")
     public Map<String,Object> bpLogin(@RequestParam String loginName, @RequestParam String password,  @RequestParam String app_code) {

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

@@ -175,4 +175,20 @@ public class EMSController extends BaseRESTfulController {
         return emsFeign.faildMsg();
     }
 
+
+    @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 = "/getemssalarydetailsMonthyear")
+    Map<String, Object> getemssalarydetailsMonthyear(@RequestBody(required = false) Map<String, Object> mapValue,
+                                             Integer apiId,
+                                             Integer pageNum,
+                                             Integer pageSize
+    ) {
+        return emsFeign.getemssalarydetailsMonthyear(mapValue == null ? new HashMap<>() : mapValue, apiId, pageNum, pageSize);
+    }
 }

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

@@ -239,4 +239,11 @@ public class UniversalController extends BaseRESTfulController {
         PageListAdd pageList = columnDataUtil.tableColumnData(apiId, material);
         return success(pageList);
     }
+
+    @ApiOperation("根据车型获取剩余车辆")
+    @PostMapping("/getcountCar")
+    public RESTfulResult getcountCar(@RequestBody Map<String,Object> map) {
+        List<Map<String, Object>> material = universalMapper.getcountCar(map);
+        return success(material);
+    }
 }

+ 8 - 0
src/main/java/com/steerinfo/dil/feign/EmsFeign.java

@@ -62,6 +62,14 @@ public interface EmsFeign {
 
     @PostMapping("api/v1/ems/emsdetailsorders/faildMsg")
     Map<String, Object> faildMsg();
+
+
+    @PostMapping("api/v1/ems/emssalarydetailss/getemssalarydetailsMonthyear")
+    Map<String, Object> getemssalarydetailsMonthyear(@RequestBody(required = false) Map<String, Object> mapValue,
+                                             @RequestParam Integer apiId,
+                                             @RequestParam Integer pageNum,
+                                             @RequestParam Integer pageSize
+    );
 }
 
 

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

@@ -76,4 +76,7 @@ public interface UniversalMapper {
 
     List<Map<String, Object>> getMaterial(Map<String, Object> map);
 
+
+    //获取车型剩余的空闲车辆和已经派车的数量
+    List<Map<String, Object>> getcountCar(Map<String, Object> map);
 }

+ 3 - 3
src/main/java/com/steerinfo/dil/util/FtpFileUtil.java

@@ -32,7 +32,7 @@ public class FtpFileUtil {
      */
 
     // String FTP_ADDRESS;
-    private String FTP_ADDRESS = "172.16.90.238";
+    private String FTP_ADDRESS = "172.16.90.202";
 
     /**
      * 端口号
@@ -44,12 +44,12 @@ public class FtpFileUtil {
      * 用户名
      */
 
-    private String FTP_USERNAME = "ftptest";
+    private String FTP_USERNAME = "ftpuser";
     /**
      * 密码
      */
 
-    private String FTP_PASSWORD = "at286315";
+    private String FTP_PASSWORD = "123456";
 
     private FTPClient ftpClient = new FTPClient();
     private static final String SPOT = ".";

+ 4 - 1
src/main/resources/application-dev.yml

@@ -67,4 +67,7 @@ hystrix:
       execution:
         isolation:
           thread:
-            timeoutInMilliseconds: 15000 #设置熔断时间,单位毫秒
+            timeoutInMilliseconds: 15000 #设置熔断时间,单位毫秒
+          strategy: SEMAPHORE
+          semaphore:
+            maxConcurrentRequests: 1

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

@@ -2,8 +2,8 @@
 spring:
   datasource:
     url: jdbc:oracle:thin:@172.16.90.197:1521/ATTMS
-    password: SSO
-    username: SSO
+    password: gxmestest
+    username: gxmestest
     driver-class-name: oracle.jdbc.OracleDriver
   application:
     name: antai-api
@@ -68,4 +68,7 @@ hystrix:
       execution:
         isolation:
           thread:
-            timeoutInMilliseconds: 15000 #设置熔断时间,单位毫秒
+            timeoutInMilliseconds: 15000 #设置熔断时间,单位毫秒
+          strategy: SEMAPHORE
+          semaphore:
+            maxConcurrentRequests: 1

+ 32 - 0
src/main/resources/com/steerinfo/dil/mapper/UniversalMapper.xml

@@ -1078,4 +1078,36 @@
             AND APC.TRANS_PLAN_ID =#{transPlanId}
         </where>
     </select>
+
+    <select id="getcountCar" resultType = "java.util.Map">
+        SELECT
+            RCAOLD.a "oldcar",(RCA.b-RCAOLD.a)"nowcar"
+        FROM
+            (
+                SELECT
+                    COUNT( RCA.CAPACITY_NUMBER ) a
+                FROM
+                    RMS_CAPACITY RCA
+                        LEFT JOIN OMS_TRANS_ORDER OTO ON RCA.CAPACITY_ID = OTO.CAPACITY_ID
+
+                WHERE
+                    OTO.TRANS_ORDER_ID IS NOT NULL
+                  AND OTO.DELETED = 5
+                  <if test="capacityTypeId != null and capacityTypeId != ''" >
+                  AND RCA.CAPACITY_TYPE_ID = #{capacityTypeId}
+                  </if>
+                  AND RCA.DELETED !=  1
+            ) RCAOLD,
+            ( SELECT
+                  COUNT( RCA.CAPACITY_NUMBER) b
+              FROM
+                  RMS_CAPACITY RCA
+              WHERE
+             <if test="capacityTypeId != null and capacityTypeId != ''" >
+            RCA.CAPACITY_TYPE_ID = #{capacityTypeId}
+             AND
+            </if>
+                RCA.DELETED !=  1
+            ) RCA
+    </select>
 </mapper>