diff --git a/zi-wms-pda/src/main/java/com/cim/idm/controller/InvoiceController.java b/zi-wms-pda/src/main/java/com/cim/idm/controller/InvoiceController.java index fda6dd3..78e3dba 100644 --- a/zi-wms-pda/src/main/java/com/cim/idm/controller/InvoiceController.java +++ b/zi-wms-pda/src/main/java/com/cim/idm/controller/InvoiceController.java @@ -1794,7 +1794,7 @@ public class InvoiceController { String ressSql = "SELECT\r\n" + " A.MATERIALPACKINGNAME ,A.MATERIALSPECNAME,A.MATERIALQUANTITY, CASE WHEN MATERIALQUANTITY2 > 0 THEN A.MATERIALQUANTITY2 " + " ELSE A.MATERIALQUANTITY END MATERIALQUANTITY2,A.AREANAME ,A.SHELFNAME ,\r\n" + - " A.CHARGE ,\r\n" + + " A.CHARGE ,A.SALESHIPREQUESTNAME,A.SALESHIPREQUESTDETAILNAME,\r\n" + " TO_CHAR(A.RECEIVETIME, 'YYYY-MM-DD') RECEIVETIME,A.SDK_ID,A.PHASE,\r\n" + " be.DESCRIPTION ERPLOCATION,\r\n" + " s.DESCRIPTION LOCATIONNAME,\r\n" + @@ -1832,6 +1832,21 @@ public class InvoiceController { hashMap.put("SITENAME", "SDK"); hashMap.put("SHIPREQUESTNAME", shipRequestName); List> queryForList = IDMFrameServiceProxy.getSqlTemplate().queryForList(ressSql, hashMap); + + // 如果是需要判定E库存的话,则进行判定 + String EStockSql = "SELECT ENUMVALUE FROM ENUMDEFVALUE WHERE ENUMNAME = 'EStockType'"; + List> EnumList = IDMFrameServiceProxy.getSqlTemplate().queryForList(EStockSql); + String enumvalue = EnumList.get(0).get("ENUMVALUE").toString(); + if("Y".equals(enumvalue)) { + for (int i = 0; i < queryForList.size(); i++) { + + String saleshiprequestname = queryForList.get(i).get("SALESHIPREQUESTNAME") == null ? "" : queryForList.get(i).get("SALESHIPREQUESTNAME").toString(); + if(!saleshiprequestname.isEmpty() && !saleshiprequestname.equals(shipRequestName)) { + queryForList.remove(i); + } + } + } + return AjaxResult.me().setResultObj(queryForList); } diff --git a/zi-wms-pda/src/main/java/com/cim/idm/service/Impl/ProductIntoServiceImpl.java b/zi-wms-pda/src/main/java/com/cim/idm/service/Impl/ProductIntoServiceImpl.java index 8689c77..8cab8c6 100644 --- a/zi-wms-pda/src/main/java/com/cim/idm/service/Impl/ProductIntoServiceImpl.java +++ b/zi-wms-pda/src/main/java/com/cim/idm/service/Impl/ProductIntoServiceImpl.java @@ -775,9 +775,14 @@ public class ProductIntoServiceImpl implements FGStockInService { if("Y".equals(is_oven)) { bindMap.put("MATURATIONINTIME", eventInfo.getEventTime());//熟化入库时间 } - bindMap.put("saleShipRequestName", queryForList.get(0).get("SALESHIPREQUESTNAME") == null ? "" : queryForList.get(0).get("SALESHIPREQUESTNAME").toString() ); + String saleShipRequestName = queryForList.get(0).get("SALESHIPREQUESTNAME") == null ? "" : queryForList.get(0).get("SALESHIPREQUESTNAME").toString(); + bindMap.put("saleShipRequestName", saleShipRequestName); bindMap.put("saleShipRequestDetailName", queryForList.get(0).get("SALESHIPREQUESTDETAILNAME") == null ? "" : queryForList.get(0).get("SALESHIPREQUESTDETAILNAME").toString() ); + if(!saleShipRequestName.isEmpty()) { + String POCATEGORY = "4"; + bindMap.put("POCATEGORY", POCATEGORY); + } //增加立库相关信息T.LK_DURABLENAME,T.LK_AREANAME,T.LK_PRODUCTLINE,T.LK_WIDTH ,T.LK_DEVIATION,T.LK_WEIGHT,T.LK_DIAMETER,T.LK_SHELFNAME bindMap.put("durableName", queryForList.get(0).get("LK_DURABLENAME")); bindMap.put("areaName", queryForList.get(0).get("LK_AREANAME"));