This commit is contained in:
郭飞 2025-04-23 18:34:18 +08:00
commit 00214095e4
5 changed files with 1595 additions and 10 deletions

View File

@ -118,6 +118,7 @@ public class NoChargeStockIn {
//3遍历map中的值 //3遍历map中的值
Iterator it = linkedHashMap.entrySet().iterator(); Iterator it = linkedHashMap.entrySet().iterator();
//校验仓库和货位的对应关系是否存在 //校验仓库和货位的对应关系是否存在
while (it.hasNext()) { while (it.hasNext()) {
Map.Entry entry = (Map.Entry) it.next(); Map.Entry entry = (Map.Entry) it.next();
Map NoPoList=(Map) entry.getValue(); Map NoPoList=(Map) entry.getValue();
@ -141,6 +142,7 @@ public class NoChargeStockIn {
.selectByKey(materialSpecKey); .selectByKey(materialSpecKey);
String maturationflag = materialSpec.getMATURATIONFLAG();//熟化标识 String maturationflag = materialSpec.getMATURATIONFLAG();//熟化标识
String is_CON_TEMP = materialSpec.getIS_CON_TEMP();//恒温恒湿 String is_CON_TEMP = materialSpec.getIS_CON_TEMP();//恒温恒湿
/*
//判断仓库是否启用了货位但货位为空 //判断仓库是否启用了货位但货位为空
String sql = "SELECT be.USE_LOCATION,be.CONST_TEMP,be.IS_OVEN FROM BS_ERPLOCATION be WHERE be.ERPLOCATIONNAME = :ERPLOCATION"; String sql = "SELECT be.USE_LOCATION,be.CONST_TEMP,be.IS_OVEN FROM BS_ERPLOCATION be WHERE be.ERPLOCATIONNAME = :ERPLOCATION";
Map<String, Object> hashMap = new HashMap<String,Object> (); Map<String, Object> hashMap = new HashMap<String,Object> ();
@ -159,6 +161,7 @@ public class NoChargeStockIn {
if ("N".equals(string) && (!"".equals(LOCATIONNAME)) ) { if ("N".equals(string) && (!"".equals(LOCATIONNAME)) ) {
throw new RuntimeException("仓库未启用货位,货位为空"); throw new RuntimeException("仓库未启用货位,货位为空");
} }
if (!"".equals(LOCATIONNAME)) { if (!"".equals(LOCATIONNAME)) {
String sql2 = "SELECT * FROM STORAGESPEC S WHERE S.STORAGENAME = :LOCATIONNAME AND S.ERPLOCATION = :ERPLOCATION "; String sql2 = "SELECT * FROM STORAGESPEC S WHERE S.STORAGENAME = :LOCATIONNAME AND S.ERPLOCATION = :ERPLOCATION ";
List<Map<String, Object>> queryForList2 = IDMFrameServiceProxy.getSqlTemplate().queryForList(sql2, hashMap); List<Map<String, Object>> queryForList2 = IDMFrameServiceProxy.getSqlTemplate().queryForList(sql2, hashMap);
@ -166,6 +169,7 @@ public class NoChargeStockIn {
throw new RuntimeException("仓库与货位对应关系不正确"); throw new RuntimeException("仓库与货位对应关系不正确");
} }
} }
String ckhw = "Y".equals(const_temp) ? "恒温恒湿" : "非恒温恒湿"; String ckhw = "Y".equals(const_temp) ? "恒温恒湿" : "非恒温恒湿";
String wlhw = "Y".equals(is_CON_TEMP) ? "恒温恒湿" : "非恒温恒湿"; String wlhw = "Y".equals(is_CON_TEMP) ? "恒温恒湿" : "非恒温恒湿";
@ -181,7 +185,9 @@ public class NoChargeStockIn {
} }
} }
*/
} }
Iterator its = linkedHashMap.entrySet().iterator(); Iterator its = linkedHashMap.entrySet().iterator();
while (its.hasNext()) { while (its.hasNext()) {
Map.Entry entry = (Map.Entry) its.next(); Map.Entry entry = (Map.Entry) its.next();

View File

@ -2,8 +2,12 @@ package com.cim.idm.service;
import com.cim.idm.exception.GlobalException; import com.cim.idm.exception.GlobalException;
import com.cim.idm.framework.data.EventInfo;
import com.cim.idm.model.OutStockDto; import com.cim.idm.model.OutStockDto;
import com.cim.idm.utils.AjaxResult;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map; import java.util.Map;
public interface IMaterialShipService { public interface IMaterialShipService {
@ -31,4 +35,31 @@ public interface IMaterialShipService {
*/ */
String outStockCheck(OutStockDto outStockDto) throws GlobalException; String outStockCheck(OutStockDto outStockDto) throws GlobalException;
/**
*辅材出库确认备货
* @param eventInfo 事件信息
* @param siteName 现地
* @param shipRequestName 单号
* @param boxList 出库的物料信息
* @return 返回信息
*/
AjaxResult MaterialShipRequestAuxiliaryConfirmStocking(EventInfo eventInfo, String siteName, String shipRequestName, String user, List<LinkedHashMap<String,String>> boxList);
/**
*辅材出库过账
* @param eventInfo 事件信息
* @param siteName 现地
* @param shipRequestName 单号
* @param boxList 出库的物料信息
* @return 返回信息
*/
AjaxResult MaterialShipRequestAuxiliaryStockOut(EventInfo eventInfo, String siteName, String shipRequestName, String user, List<LinkedHashMap<String,String>> boxList, String commitDate)throws Exception;
/**
*辅材出库取下确认备货
* @param eventInfo 事件信息
* @param siteName 现地
* @param shipRequestName 单号
* @return 返回信息
*/
AjaxResult MaterialShipRequestAuxiliaryCancelConfirmStocking(EventInfo eventInfo, String siteName, String shipRequestName, String user);
} }

View File

@ -51,4 +51,8 @@ public class AjaxResult {
return this; return this;
} }
public AjaxResult toAjax(int rows)
{
return rows > 0 ? setSuccess(true) : setErrorCode(400);
}
} }

View File

@ -1,13 +1,9 @@
package com.cim.idm.mwmsextend.materialshiprequest.service; package com.cim.idm.mwmsextend.materialshiprequest.service;
import java.math.BigDecimal;
import java.sql.Timestamp; import java.sql.Timestamp;
import java.text.SimpleDateFormat; import java.text.SimpleDateFormat;
import java.util.ArrayList; import java.util.*;
import java.util.Date;
import java.util.HashMap;
import java.util.Iterator;
import java.util.List;
import java.util.Map;
import java.text.ParseException; import java.text.ParseException;