Browse Source

预装箱单导入调整

huxy 2 years ago
parent
commit
e75b09abc6

+ 9 - 9
jeecg-boot-module-system/src/main/java/org/jeecg/modules/scas/mapper/xml/SupplierCapacityMapper.xml

@@ -190,11 +190,11 @@
         p.dArriveDate,
         sum(p.iQuantity) iQuantity,
         sum(p.iReceivedQTY) iReceivedQTY,
-        cast(isnull(p.coefficient,'0') as decimal) coefficient
+        sum(cast(isnull(p.coefficient,'0') as decimal)) coefficient
          from Supplier_Capacity_Test p
            ${ew.customSqlSegment}
-        group by p.cDepCode,p.cVenCode,p.dArriveDate,p.coefficient
-        order by p.cDepCode,p.cVenCode,p.dArriveDate,p.coefficient
+        group by p.cDepCode,p.cVenCode,p.dArriveDate
+        order by p.cDepCode,p.cVenCode,p.dArriveDate
     </select>
 
     <select id="excel002" resultType="org.jeecg.modules.scas.entity.vo.SupplierCapacityVo2">
@@ -241,11 +241,11 @@
         p.dArriveDate,
         sum(p.iQuantity) iQuantity,
         sum(p.iReceivedQTY) iReceivedQTY,
-        cast(isnull(p.coefficient,'0') as decimal) coefficient
+        sum(cast(isnull(p.coefficient,'0') as decimal)) coefficient
          from Supplier_Capacity_Test p
            ${ew.customSqlSegment}
-   group by p.cDepCode,p.dArriveDate,p.coefficient
-    order  by p.cDepCode,p.dArriveDate,p.coefficient
+   group by p.cDepCode,p.dArriveDate
+    order  by p.cDepCode,p.dArriveDate
     </select>
 
 
@@ -292,11 +292,11 @@
             p.dArriveDate,
             sum(p.iQuantity) iQuantity,
             sum(p.iReceivedQTY) iReceivedQTY,
-            cast(isnull(p.coefficient,'0') as decimal) coefficient
+            sum(cast(isnull(p.coefficient,'0') as decimal)) coefficient
          from Supplier_Capacity_Test p
            ${ew.customSqlSegment}
-         group by p.cVenCode,p.dArriveDate,p.coefficient
-         order by p.cVenCode,p.dArriveDate,p.coefficient
+         group by p.cVenCode,p.dArriveDate
+         order by p.cVenCode,p.dArriveDate
     </select>
 
 </mapper>

+ 10 - 0
jeecg-boot-module-system/src/main/java/org/jeecg/modules/spapl/controller/SyPreAssembledPackingListController.java

@@ -1896,6 +1896,16 @@ public class SyPreAssembledPackingListController extends JeecgController<SyPreAs
             list.add("PREACKSKU");
             list.add("净净重");
             list.add("配码规格");
+
+            list.add("件数/包");
+            list.add("包数/箱");
+            list.add("件数/箱");
+            list.add("包数");
+            list.add("PCS/PACK");//英文
+            list.add("PACKS/CTN");//英文
+            list.add("PCS/CTN");//英文
+            list.add("PACK QTY");//英文
+
             System.out.println("第"+num+"页");
             int num1=10;
             for (int x=0;x<=sheet.getLastRowNum();x++){

+ 25 - 3
jeecg-boot-module-system/src/main/java/org/jeecg/modules/spapl/entity/SyPreAssembledPackingListItem.java

@@ -336,7 +336,14 @@ public class SyPreAssembledPackingListItem implements Serializable {
 			endCaseNumber=parsms[5];
 			itemCode=parsms[6];
 			prepackSku=parsms[7];
-			totalPack=new BigDecimal(parsms[8]);//件数包
+
+			if(parsms[8]==null||parsms[8].length()==0){
+				totalPack=new BigDecimal("0");//件数包
+			}else{
+				totalPack=new BigDecimal(parsms[8]);//件数包
+			}
+			//totalPack=new BigDecimal(parsms[8]);
+
 			colour=parsms[9];
 			unitPrice=new BigDecimal("0");//初始化
 			totalPrice=new BigDecimal("0");//初始化
@@ -353,9 +360,24 @@ public class SyPreAssembledPackingListItem implements Serializable {
 				netWeightToo=new BigDecimal(parsms[15]);
 			}*/
 			withCode=parsms[17];//配码
-			packBox=new BigDecimal(parsms[18]);//包数/箱
+			if(parsms[18]==null||parsms[18].length()==0){
+				packBox=new BigDecimal("0");//件数包
+			}else{
+				packBox=new BigDecimal(parsms[18]);//件数包
+			}
+			/*if(parsms[19]==null||parsms[19].length()==0){
+				piecesBox=new BigDecimal("0");//件数包
+			}else{
+				piecesBox=new BigDecimal(parsms[8]);//件数包
+			}*/
+			if(parsms[20]==null||parsms[20].length()==0){
+				packs=new BigDecimal("0");//件数包
+			}else{
+				packs=new BigDecimal(parsms[20]);//件数包
+			}
+			/*packBox=new BigDecimal(parsms[18]);//包数/箱
 			piecesBox=new BigDecimal(parsms[19]);//件数/箱
-			packs=new BigDecimal(parsms[20]);//包数
+			packs=new BigDecimal(parsms[20]);//包数*/
 
 			//发运明细分组ID	发运明细主表ID	申报要素ID
 			groupId=parsms[16+6+4];//分组id

+ 0 - 3
jeecg-boot-module-system/src/main/java/org/jeecg/modules/splfi/service/impl/SyPackingListFabricServiceImpl.java

@@ -2029,10 +2029,7 @@ public class SyPackingListFabricServiceImpl extends ServiceImpl<SyPackingListFab
 					"a.id u8Id,       \n" +
 					"a.ccode as documentNo,\n"+
 					"f.ID as  fId, \n"+
-
 					"a.cDefine3 as  containerNumber, \n"+
-
-
 					"'1' as is_U8_Data,    \n" +
 					"a.cMemo memo,    \n" +
 					"0 as delflag,    \n" +