Ver Fonte

合并订单更新客户订单优化

DLC há 1 ano atrás
pai
commit
63a4c073ed

+ 1 - 13
cx-aps/cx-aps-common/src/main/java/com/rongwei/bscommon/sys/dao/ApsProductDetailDao.java

@@ -31,25 +31,13 @@ public interface ApsProductDetailDao extends BaseMapper<ApsProductDetailDo> {
     List<ApsProductionMergeOrderDo> getProductionMergeOrders(@Param("orderNos") List<String> orderNos);
 
     @Select({" <script>",
-            "select d.* from aps_product_detail d\n" +
-            "left join aps_production_order o on o.DELETED='0' and o.ID=d.MAINID\n" +
-            "where d.DELETED='0' and IFNULL(d.CUSTOMORDERDETAILID,'')!='' and o.CUSTOMORDERNO in",
+            "select * from aps_product_detail where DELETED='0' and CUSTOMORDERNO in\n" +
             " <foreach collection=\"orderNos\" item=\"orderno\" index=\"index\" open=\"(\" close=\")\" separator=\",\"> ",
             "  #{orderno}",
             "</foreach>",
             "</script>"})
     List<ApsProductDetailDo> getProductDetails(@Param("orderNos") List<String> orderNos);
 
-    @Select({" <script>",
-            "select d.* from aps_product_detail d\n" +
-                    "left join aps_production_merge_order o on o.DELETED='0' and o.ID=d.MAINID\n" +
-                    "where d.DELETED='0' and IFNULL(d.CUSTOMORDERDETAILID,'')!='' and o.CUSTOMORDERNO in",
-            " <foreach collection=\"orderNos\" item=\"orderno\" index=\"index\" open=\"(\" close=\")\" separator=\",\"> ",
-            "  #{orderno}",
-            "</foreach>",
-            "</script>"})
-    List<ApsProductDetailDo> getProductMergeDetails(@Param("orderNos") List<String> orderNos);
-
     @Select("select ID,CUSTOMERNAME,DELIVERYTIME from aps_customer_management where DELETED='0'")
     List<ApsCustomerManagementDo> getCustomerData();
 

+ 1 - 0
cx-aps/cx-aps-common/src/main/java/com/rongwei/bscommon/sys/service/impl/ApsProcessOperationServiceImpl.java

@@ -707,6 +707,7 @@ public class ApsProcessOperationServiceImpl extends ServiceImpl<ApsProcessOperat
                         }
                     }
                     apsProcessOperationDo.setPlanoutput(planoutsb.toString());
+                    apsProcessOperationDo.setInputunqualifiedroll(apsProcessOperationOutMaterDo.getFailrollnum());
 
                     apsProcessOperationDoList.add(apsProcessOperationDo);
                 }

+ 3 - 1
cx-aps/cx-aps-common/src/main/java/com/rongwei/bscommon/sys/service/impl/ApsProductDetailServiceImpl.java

@@ -153,6 +153,7 @@ public class ApsProductDetailServiceImpl extends ServiceImpl<ApsProductDetailDao
                 apsProductDetailDo.setMainid(apsProductionOrderDo.getId());
                 apsProductDetailDo.setCustomorderdetailid(vNcOrderDetailVo.getId());
                 apsProductDetailDo.setTenantid(apsProductionOrderDo.getTenantid());
+                apsProductDetailDo.setCustomorderno(apsProductionOrderDo.getCustomorderno());
 
                 apsProductDetailDoList.add(apsProductDetailDo);
             }
@@ -205,7 +206,7 @@ public class ApsProductDetailServiceImpl extends ServiceImpl<ApsProductDetailDao
 
         //本系统的订单信息
         List<ApsProductionMergeOrderDo> apsProductionMergeOrderDos = apsProductDetailDao.getProductionMergeOrders(hasOrderNos);
-        List<ApsProductDetailDo> apsProductDetailDos = apsProductDetailDao.getProductMergeDetails(hasOrderNos);
+        List<ApsProductDetailDo> apsProductDetailDos = apsProductDetailDao.getProductDetails(hasOrderNos);
         List<ApsProductionMergeOrderDo> apsProductionMergeOrderDoList = new ArrayList<>();
         List<ApsProductDetailDo> apsProductDetailDoList = new ArrayList<>();
         List<String> delProductDetailIdList = new ArrayList<>();
@@ -266,6 +267,7 @@ public class ApsProductDetailServiceImpl extends ServiceImpl<ApsProductDetailDao
                 apsProductDetailDo.setMainid(apsProductionMergeOrderDo.getId());
                 apsProductDetailDo.setCustomorderdetailid(vNcOrderDetailVo.getId());
                 apsProductDetailDo.setTenantid(apsProductionMergeOrderDo.getTenantid());
+                apsProductDetailDo.setCustomorderno(apsProductionMergeOrderDo.getCustomorderno());
 
                 apsProductDetailDoList.add(apsProductDetailDo);
             }

+ 5 - 0
cx-aps/cx-aps-entity/src/main/java/com/rongwei/bsentity/domain/ApsProductDetailDo.java

@@ -147,5 +147,10 @@ public class ApsProductDetailDo extends BaseDo {
      */
     private String customorderdetailid;
 
+    /**
+     * 客户订单号
+     */
+    private String customorderno;
+
     private static final long serialVersionUID = 1L;
 }