fix:需求单下推,需求单删除
This commit is contained in:
@@ -66,4 +66,7 @@ public class RegionConstant {
|
||||
*/
|
||||
public static final String R004 = "R004";
|
||||
|
||||
public static final String H001 = "H001";
|
||||
public static final String H002 = "H002";
|
||||
|
||||
}
|
||||
|
||||
@@ -172,7 +172,8 @@ public class MesToWmsController {
|
||||
pmDemandPlatingParams.add(param);
|
||||
} else if (RegionConstant.ASSEMBLY_PART_STORE_CODE.equals(warehouseCode)) {
|
||||
partDemandParams.add(param);
|
||||
} else if (RegionConstant.H005.equals(warehouseCode)) {
|
||||
} else if (RegionConstant.H005.equals(warehouseCode) ||
|
||||
RegionConstant.H001.equals(warehouseCode) || RegionConstant.H002.equals(warehouseCode)) {
|
||||
structureDemandParams.add(param);
|
||||
} else {
|
||||
pmDemandParams.add(param);
|
||||
|
||||
@@ -239,21 +239,23 @@ public class PmDemandServiceImpl extends ServiceImpl<PmDemandMapper, PmDemand> i
|
||||
for (PmDemand pmDemand : pmDemands) {
|
||||
ArrayList<PmDemandDto> pmDemandDtos = new ArrayList<>();
|
||||
String id = pmDemand.getId();
|
||||
PmDemandDto pmDemandDto = new PmDemandDto();
|
||||
pmDemandDto.setId(pmDemand.getId());
|
||||
pmDemandDto.setWorkOrder(pmDemand.getWork_order());
|
||||
pmDemandDto.setCreator(pmDemand.getCreator());
|
||||
pmDemandDto.setPriority(pmDemand.getPriority());
|
||||
pmDemandDto.setSkuCode(pmDemand.getSku_code());
|
||||
pmDemandDto.setSkuName(pmDemand.getSku_name());
|
||||
pmDemandDto.setQty(pmDemand.getQty());
|
||||
pmDemandDto.setUnit(pmDemand.getUnit());
|
||||
pmDemandDto.setTargetArea(pmDemand.getTarget_area());
|
||||
pmDemandDto.setProductionLine(pmDemand.getProduction_line());
|
||||
pmDemandDto.setCarrierType(pmDemand.getCarrier_type());
|
||||
pmDemandDto.setSn(pmDemand.getSn());
|
||||
pmDemandDtos.add(pmDemandDto);
|
||||
wmsToZDWmdService.syncDemandOrderDel(pmDemandDtos);
|
||||
if (RegionConstant.R001.equals(pmDemand.getInventory_dis()) && pmDemand.getStatus().equals(DemandStatus.SEND.getValue())){
|
||||
PmDemandDto pmDemandDto = new PmDemandDto();
|
||||
pmDemandDto.setId(pmDemand.getId());
|
||||
pmDemandDto.setWorkOrder(pmDemand.getWork_order());
|
||||
pmDemandDto.setCreator(pmDemand.getCreator());
|
||||
pmDemandDto.setPriority(pmDemand.getPriority());
|
||||
pmDemandDto.setSkuCode(pmDemand.getSku_code());
|
||||
pmDemandDto.setSkuName(pmDemand.getSku_name());
|
||||
pmDemandDto.setQty(pmDemand.getQty());
|
||||
pmDemandDto.setUnit(pmDemand.getUnit());
|
||||
pmDemandDto.setTargetArea(pmDemand.getTarget_area());
|
||||
pmDemandDto.setProductionLine(pmDemand.getProduction_line());
|
||||
pmDemandDto.setCarrierType(pmDemand.getCarrier_type());
|
||||
pmDemandDto.setSn(pmDemand.getSn());
|
||||
pmDemandDtos.add(pmDemandDto);
|
||||
wmsToZDWmdService.syncDemandOrderDel(pmDemandDtos);
|
||||
}
|
||||
mesApi.delMesDemand(id);
|
||||
this.update(new LambdaUpdateWrapper<PmDemand>()
|
||||
.eq(PmDemand::getId, id)
|
||||
|
||||
Reference in New Issue
Block a user