Browse Source

成本报表 注释

liuchaohui 2 years ago
parent
commit
9d32a9c2d6

+ 0 - 31
jeecg-boot-module-system/src/main/java/org/jeecg/modules/cost/service/impl/SyCostAllocationServiceImpl.java

@@ -198,21 +198,6 @@ public class SyCostAllocationServiceImpl extends ServiceImpl<SyCostAllocationMap
         }
 
         /*查询U8数据 面料*/
-//        String sqlFabric = "SELECT cInvName as goodsName,sum(riQuantity) as usageQuantity,sum(biQuantity) as planQuantity,processUnit FROM (" +
-//                "select c.cInvName ,sum(r.iQuantity) as riQuantity,r.cBatch ,b.cSource,b.cPOID,sum(b.iQuantity) as biQuantity,v.cVenName as processUnit" +
-//                " FROM rdrecords11  r" +
-//                "  JOIN (" +
-//                "   SELECT od.MODetailsID,od.cInvCode,om.cVenCode  " +
-//                "   FROM OM_MOMain om LEFT JOIN OM_MODetails od ON om.MOID = od.MOID " +
-//                "   WHERE om.cState = 1 and om.cCode like '"+plannum+"%'" +
-//                "   ) o ON r.iOMoDID  = o.MODetailsID " +
-//                "  LEFT JOIN (SELECT * FROM  Inventory where (cInvCCode like '03%' or cInvCCode like '04%'  ) and cInvCCode != '0399' and cInvCCode != '0499') c on c.cInvCode=r.cInvCode" +
-//                " LEFT JOIN Vendor v ON o.cVenCode= v.cVenCode "+
-//                "  LEFT JOIN (" +
-//                "    SELECT r1.cSource,rs1.cBatch,rs1.cInvCode ,rs1.cPOID,rs1.iQuantity" +
-//                "    FROM rdrecords01 rs1 join rdrecord01 r1 on r1.id=rs1.id" +
-//                "    ) b on r.cBatch = b.cBatch and b.cInvCode=r.cInvCode " +
-//                "  GROUP BY c.cInvName,r.cBatch,b.cSource,b.cPOID,v.cVenName ) as ta GROUP BY cInvName,processUnit";
 
         String sqlFabric ="SELECT cInvName as goodsName,sum(yi) as usageQuantity,sum(ying) as planQuantity,sum(gou) as purchaseQuantity," +
                 "processUnit,isnull(sum(gou),0)-isnull(sum(yuu),0) as fabricremainingQuantity,sum(yu) as fabrictransferQuantity FROM (  " +
@@ -369,22 +354,6 @@ public class SyCostAllocationServiceImpl extends ServiceImpl<SyCostAllocationMap
 
 
         //查询U8数据 辅料
-//        String sqlIngredient = "SELECT cInvName as goodsName,sum(riQuantity) as usageQuantity,sum(biQuantity) as planQuantity,processUnit FROM (" +
-//                "select c.cInvName ,sum(r.iQuantity) as riQuantity,r.cBatch ,b.cSource,b.cPOID,sum(b.iQuantity) as biQuantity,v.cVenName as processUnit" +
-//                " FROM rdrecords11  r" +
-//                "  JOIN (" +
-//                "   SELECT od.MODetailsID,od.cInvCode,om.cVenCode " +
-//                "   FROM OM_MOMain om LEFT JOIN OM_MODetails od ON om.MOID = od.MOID " +
-//                "   WHERE om.cState = 1 and om.cCode like '"+plannum+"%'" +
-//                "   ) o ON r.iOMoDID  = o.MODetailsID " +
-//                "  LEFT JOIN (SELECT * FROM  Inventory where (cInvCCode like '05%' or cInvCCode like '06%' or cInvCCode like '07%' ) ) c on c.cInvCode=r.cInvCode" +
-//                " LEFT JOIN Vendor v ON o.cVenCode= v.cVenCode "+
-//                "  LEFT JOIN (" +
-//                "    SELECT r1.cSource,rs1.cBatch,rs1.cInvCode ,rs1.cPOID,rs1.iQuantity" +
-//                "    FROM rdrecords01 rs1 join rdrecord01 r1 on r1.id=rs1.id" +
-//                "    ) b on r.cBatch = b.cBatch and b.cInvCode=r.cInvCode " +
-//                "  GROUP BY c.cInvName,r.cBatch,b.cSource,b.cPOID,v.cVenName ) as ta GROUP BY cInvName,processUnit";
-
         String sqlIngredient ="SELECT cInvName as goodsName,sum(yi) as usageQuantity,sum(gou) as purchaseQuantity," +
                 "processUnit,isnull(sum(gou),0)-isnull(sum(yuu),0) as ingredientsRemainingQuantity,sum(yu) as ingredientsTransferQuantity FROM (  " +
                 " " +