|
|
|
@ -538,8 +538,8 @@ public class WmsRawOutstockServiceImpl implements IWmsRawOutstockService {
|
|
|
|
|
wmsStockTotal.setUpdateBy(userName);
|
|
|
|
|
wmsStockTotalMapper.updateWmsStockTotal(wmsStockTotal);
|
|
|
|
|
|
|
|
|
|
WmsRawOutstock toInsertedRawOutstock = getWmsRawOutstock(baseWarehouse, planCode, planDetailCode,
|
|
|
|
|
rawOutstockDetail.getMaterialId(), taskCode, taskType, wmsRawOutstock.getApplyReason(),
|
|
|
|
|
WmsRawOutstock toInsertedRawOutstock = getWmsRawOutstock(baseWarehouse, wmsRawOutstock,
|
|
|
|
|
rawOutstockDetail.getMaterialId(), taskCode, taskType,
|
|
|
|
|
planAmount, currentDate, userName, wmsStockTotal.getStockTotalId());
|
|
|
|
|
toInsertedRawOutstocks.add(toInsertedRawOutstock);
|
|
|
|
|
|
|
|
|
@ -562,8 +562,7 @@ public class WmsRawOutstockServiceImpl implements IWmsRawOutstockService {
|
|
|
|
|
* 获取待保存的原材料出库记录
|
|
|
|
|
*
|
|
|
|
|
* @param baseWarehouse
|
|
|
|
|
* @param planCode
|
|
|
|
|
* @param planDetailCode
|
|
|
|
|
* @param wmsRawOutstockParam
|
|
|
|
|
* @param materialId
|
|
|
|
|
* @param taskCode
|
|
|
|
|
* @param planAmount
|
|
|
|
@ -571,8 +570,8 @@ public class WmsRawOutstockServiceImpl implements IWmsRawOutstockService {
|
|
|
|
|
* @param userName
|
|
|
|
|
* @return
|
|
|
|
|
*/
|
|
|
|
|
private WmsRawOutstock getWmsRawOutstock(WmsBaseWarehouse baseWarehouse,
|
|
|
|
|
String planCode, String planDetailCode, Long materialId, String taskCode, String taskType, String applyReason,
|
|
|
|
|
private WmsRawOutstock getWmsRawOutstock(WmsBaseWarehouse baseWarehouse, WmsRawOutstock wmsRawOutstockParam,
|
|
|
|
|
Long materialId, String taskCode, String taskType,
|
|
|
|
|
BigDecimal planAmount, Date currentDate, String userName, Long stockTotalId) {
|
|
|
|
|
//出库要求 (0申请出库,1申请审核出库,2直接出库)
|
|
|
|
|
String outRequirement = baseWarehouse.getOutRequirement();
|
|
|
|
@ -596,18 +595,18 @@ public class WmsRawOutstockServiceImpl implements IWmsRawOutstockService {
|
|
|
|
|
toInsertedRawOutstock.setTaskCode(taskCode);
|
|
|
|
|
toInsertedRawOutstock.setWarehouseId(baseWarehouse.getWarehouseId());
|
|
|
|
|
// toInsertedRawOutstock.setLocationCode(wmsRawStock.getLocationCode());
|
|
|
|
|
toInsertedRawOutstock.setStationId(SecurityUtils.getStationId());
|
|
|
|
|
toInsertedRawOutstock.setStationId(wmsRawOutstockParam.getStationId());
|
|
|
|
|
toInsertedRawOutstock.setStockTotalId(stockTotalId);
|
|
|
|
|
// toInsertedRawOutstock.setPalletInfoCode(wmsRawStock.getPalletInfoCode());
|
|
|
|
|
toInsertedRawOutstock.setOperationType(operationType);
|
|
|
|
|
toInsertedRawOutstock.setApplyBy(userName);
|
|
|
|
|
toInsertedRawOutstock.setApplyReason(applyReason);
|
|
|
|
|
toInsertedRawOutstock.setApplyReason(wmsRawOutstockParam.getApplyReason());
|
|
|
|
|
toInsertedRawOutstock.setApplyDate(currentDate);
|
|
|
|
|
toInsertedRawOutstock.setEndStationCode(SecurityUtils.getStationCode());
|
|
|
|
|
toInsertedRawOutstock.setEndStationCode(wmsRawOutstockParam.getEndStationCode());
|
|
|
|
|
toInsertedRawOutstock.setMaterialId(materialId);
|
|
|
|
|
toInsertedRawOutstock.setOutstockAmount(planAmount);
|
|
|
|
|
toInsertedRawOutstock.setPlanCode(planCode);
|
|
|
|
|
toInsertedRawOutstock.setPlanDetailCode(planDetailCode);
|
|
|
|
|
toInsertedRawOutstock.setPlanCode(wmsRawOutstockParam.getPlanCode());
|
|
|
|
|
toInsertedRawOutstock.setPlanDetailCode(wmsRawOutstockParam.getPlanDetailCode());
|
|
|
|
|
// toInsertedRawOutstock.setMaterialBatch(wmsRawStock.getInstockBatch());//申请出库时不指定某个物料
|
|
|
|
|
toInsertedRawOutstock.setTaskType(taskType);
|
|
|
|
|
toInsertedRawOutstock.setCreateTime(currentDate);
|
|
|
|
@ -634,7 +633,7 @@ public class WmsRawOutstockServiceImpl implements IWmsRawOutstockService {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
wmsRawOutstock.setTaskCode(Seq.getId(Seq.rawOutstockSeqType, Seq.rawOutstockSeqCode));
|
|
|
|
|
wmsRawOutstock.setStationId(SecurityUtils.getStationId());
|
|
|
|
|
// wmsRawOutstock.setStationId(SecurityUtils.getStationId());
|
|
|
|
|
|
|
|
|
|
wmsRawOutstock.setOperationType(operationType);
|
|
|
|
|
wmsRawOutstock.setApplyBy(userName);
|
|
|
|
@ -650,12 +649,12 @@ public class WmsRawOutstockServiceImpl implements IWmsRawOutstockService {
|
|
|
|
|
toInsertedRawOutstock.setTaskCode(Seq.getId(Seq.rawOutstockSeqType, Seq.rawOutstockSeqCode));
|
|
|
|
|
toInsertedRawOutstock.setWarehouseId(wmsRawOutstock.getWarehouseId());
|
|
|
|
|
toInsertedRawOutstock.setLocationCode(wmsRawOutstockDetail.getLocationCode());
|
|
|
|
|
toInsertedRawOutstock.setStationId(SecurityUtils.getStationId());
|
|
|
|
|
// toInsertedRawOutstock.setStationId(SecurityUtils.getStationId());
|
|
|
|
|
toInsertedRawOutstock.setPalletInfoCode(wmsRawOutstockDetail.getPalletInfoCode());
|
|
|
|
|
toInsertedRawOutstock.setOperationType(operationType);
|
|
|
|
|
toInsertedRawOutstock.setApplyBy(userName);
|
|
|
|
|
toInsertedRawOutstock.setApplyDate(currentDate);
|
|
|
|
|
toInsertedRawOutstock.setEndStationCode(SecurityUtils.getStationCode());
|
|
|
|
|
// toInsertedRawOutstock.setEndStationCode(SecurityUtils.getStationCode());
|
|
|
|
|
toInsertedRawOutstock.setPlanCode(wmsRawOutstock.getPlanCode());
|
|
|
|
|
toInsertedRawOutstock.setPlanDetailCode(wmsRawOutstock.getPlanDetailCode());
|
|
|
|
|
toInsertedRawOutstock.setMaterialBatch(wmsRawOutstockDetail.getInstockBatch());
|
|
|
|
@ -1120,7 +1119,7 @@ public class WmsRawOutstockServiceImpl implements IWmsRawOutstockService {
|
|
|
|
|
|
|
|
|
|
wmsRawOutstock.setTaskCode(Seq.getId(Seq.rawOutstockSeqType, Seq.rawOutstockSeqCode));
|
|
|
|
|
wmsRawOutstock.setWarehouseId(baseLocation.getWarehouseId());
|
|
|
|
|
wmsRawOutstock.setStationId(SecurityUtils.getStationId());
|
|
|
|
|
// wmsRawOutstock.setStationId(SecurityUtils.getStationId());
|
|
|
|
|
wmsRawOutstock.setMaterialId(baseBarcodeInfo.getMaterialId());
|
|
|
|
|
wmsRawOutstock.setMaterialBatch(baseBarcodeInfo.getBatchCode());
|
|
|
|
|
wmsRawOutstock.setRealOutstockAmount(outstockAmount);
|
|
|
|
|