ソースを参照

面辅料导入

huxy 2 年 前
コミット
3437d1caaa

+ 16 - 6
jeecg-boot-module-system/src/main/java/org/jeecg/modules/splfi/entity/SyPackingListFabricItem.java

@@ -380,6 +380,16 @@ public class SyPackingListFabricItem implements Serializable {
 
 	}
 
+	public static boolean isNumeric(String str) {
+		String bigStr;
+		try {
+			bigStr = new BigDecimal(str).toString();
+		} catch (Exception e) {
+			return false;//异常 说明包含非数字。
+		}
+		return true;
+	}
+
 	public SyPackingListFabricItem(String [] strs,int num1){
 		this.num=num1;
 		for (int i=0;i<strs.length;i++){
@@ -428,18 +438,18 @@ public class SyPackingListFabricItem implements Serializable {
 		}else{
 			kaoClothWeight=new BigDecimal(strs[20] );//拷布重
 		}
-		if(strs[21]==null||strs[21].equals("")){//
+		if(strs[21+1]==null||strs[21+1].equals("")){//
 			actualDeclaredQuantity=new BigDecimal(0);//实际报关数量
 		}else{
 			actualDeclaredQuantity=new BigDecimal(strs[21]);//实际报关数量
 		}
-		mannerOfPacking=strs[22];//包装方式
-		treatmentMethod=strs[23];//处理方式
-		containerNumber=strs[24];//柜号
-		remarks2=strs[25];//备注
+		mannerOfPacking=strs[22+1];//包装方式
+		treatmentMethod=strs[23+1];//处理方式
+		containerNumber=strs[24+1];//柜号
+		remarks2=strs[25+1];//备注
 		BigDecimal width1=new BigDecimal("0");
 		BigDecimal gramWeight2=new BigDecimal("0");
-		if(width!=null&&!width.equals("")){
+		if(isNumeric(width)){
 			width1=new BigDecimal(width);
 		}else{
 			width="0";

+ 0 - 15
jeecg-boot-module-system/src/main/java/org/jeecg/modules/splt/controller/SyPackingListTailoringController.java

@@ -1481,21 +1481,6 @@ public class SyPackingListTailoringController {
 		 return  result;
 	 }
 
-	 @AutoLog(value = "调试接口-采购入库2")
-	 @ApiOperation(value="调试接口-采购入库2", notes="调试接口-采购入库2")
-	 @RequestMapping(value = "/pushJson15", method = {RequestMethod.POST})
-	 public Result json15(@RequestBody JSONArray jsonArray){
-		 //JSONArray jsonArray2= InterfaceConnUtils.doPost(jsonArray,"purchasein_import");
-		 Result result=new Result();
-		 JSONArray jsonArray2=new JSONArray();
-		 System.out.println("jsonarray.size\t"+jsonArray.size());
-		 for(int i = 0; i < jsonArray.size(); i++){
-			 JSONObject jsonObject= jsonArray.getJSONObject(i);
-			 jsonArray2.add(jsonObject);
-		 }
-		 result.setResult(jsonArray2);
-		 return  result;
-	 }
 
 	 @AutoLog(value = "调试接口-材料出库单")
 	 @ApiOperation(value="调试接口-材料出库单", notes="调试接口-材料出库单")