txf 3 rokov pred
rodič
commit
4670be262d

+ 8 - 4
src/main/java/com/steerinfo/dil/controller/UniversalController.java

@@ -243,10 +243,11 @@ public class UniversalController extends BaseRESTfulController {
     })
     @PostMapping("/queryAPOMaterialByLike")
     public RESTfulResult queryAPOMaterialByLike(@RequestBody(required = false) Map<String,Object> mapValue,
-                                             Integer pageNum,
-                                             Integer pageSize,
-                                             Integer apiId,
-                                             String index) {
+                                                Integer pageNum,
+                                                Integer pageSize,
+                                                Integer apiId,
+                                                String index,
+                                                Integer supplierId) {
 
         if(mapValue == null) {
             mapValue = new HashMap<>();
@@ -254,6 +255,9 @@ public class UniversalController extends BaseRESTfulController {
         if(index != null && !"".equals(index) &&!"null".equals(index)){
             mapValue.put("index", index);
         }
+        if(supplierId != null){
+            mapValue.put("supplierId", supplierId);
+        }
         PageHelper.startPage(pageNum, pageSize);
         //分页查询数据
         List<Map<String, Object>> columnList = universalMapper.queryAPOMaterialByLike(mapValue);

+ 1 - 1
src/main/resources/application-prod.yml

@@ -31,7 +31,7 @@ openfeign:
   WMSFeign:
     url: ${WMSFEIGN_URL:172.16.33.162:8012}
   OMSFeign:
-    url: ${OMSFEIGN_URL:172.16.33.166:8095}
+    url: ${OMSFEIGN_URL:localhost:8095}
   RmsFeign:
     url: ${RMSFEIGN_URL:172.16.33.166:8060}
 

+ 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

+ 4 - 1
src/main/resources/com/steerinfo/dil/mapper/UniversalMapper.xml

@@ -71,8 +71,11 @@
                     JOIN RMS_MATERIAL RM
                         ON RM.MATERIAL_ID = DB.MATERIAL_ID
                 <where>
+                    <if test="supplierId != null">
+                        and APO.SUPPLIER_UNIT_ID = #{supplierId}
+                    </if>
                     <if test="index != null">
-                        (instr(RM.MATERIAL_NAME, #{index}) > 0 or instr(RM.MATERIAL_SPECIFICATION,#{index}) >0 or instr(RM.MATERIAL_MODEL,#{index}) >0)
+                        and (instr(RM.MATERIAL_NAME, #{index}) > 0 or instr(RM.MATERIAL_SPECIFICATION,#{index}) >0 or instr(RM.MATERIAL_MODEL,#{index}) >0)
                     </if>
                 </where>
                  group by RM.MATERIAL_ID,RM.MATERIAL_NAME,RM.MATERIAL_CODE,RM.MATERIAL_SPECIFICATION,RM.MATERIAL_MODEL