diff --git a/nladmin-system/wms-server/src/main/java/org/nl/wms/pm_manage/sap/outBoundDelivery/enums/OutboundDeliveryBillType.java b/nladmin-system/wms-server/src/main/java/org/nl/wms/pm_manage/sap/outBoundDelivery/enums/OutboundDeliveryBillType.java index c885654e..1fddfa08 100644 --- a/nladmin-system/wms-server/src/main/java/org/nl/wms/pm_manage/sap/outBoundDelivery/enums/OutboundDeliveryBillType.java +++ b/nladmin-system/wms-server/src/main/java/org/nl/wms/pm_manage/sap/outBoundDelivery/enums/OutboundDeliveryBillType.java @@ -10,7 +10,8 @@ public enum OutboundDeliveryBillType { SUBCONTRACT_OUT("SUBCONTRACT_OUT", "委外交货出库", "LB", "其他出库", false), TRANSFER_IN("TRANSFER_IN", "公司间调拨收货", "NLCC", null, true), SALES_OUT("SALES_OUT", "原材料销售出库", "ZLF4", "销售出库", false), - SALES_RETURN_IN("SALES_RETURN_IN", "原材料销售退货", "ZLR1", null, true); + SALES_RETURN_IN("SALES_RETURN_IN", "原材料销售退货", "ZLR1", null, true), + TRANSFER_OUT("TRANSFER_OUT", "SAP公司间调拨出货", "NL", null, false); private final String code; private final String name; diff --git a/nladmin-system/wms-server/src/main/java/org/nl/wms/warehouse_manage/inAndOut/service/impl/OutBillServiceImpl.java b/nladmin-system/wms-server/src/main/java/org/nl/wms/warehouse_manage/inAndOut/service/impl/OutBillServiceImpl.java index 437c440c..97757b16 100644 --- a/nladmin-system/wms-server/src/main/java/org/nl/wms/warehouse_manage/inAndOut/service/impl/OutBillServiceImpl.java +++ b/nladmin-system/wms-server/src/main/java/org/nl/wms/warehouse_manage/inAndOut/service/impl/OutBillServiceImpl.java @@ -648,49 +648,6 @@ public class OutBillServiceImpl extends ServiceImpl i String iostorinv_id = whereJson.getString("iostorinv_id"); String regionCode = whereJson.getString("region_code"); -// if (SpringContextHolder.getBean(org.nl.wms.welding_manage.service.work_order.impl.WorkOrderOutboundService.class).isWorkOrderBill(whereJson.getString("iostorinv_id"))) { -// List ioStorInvDisList = ioStorInvDisMapper.selectList(new LambdaQueryWrapper() -// .eq(IOStorInvDis::getIostorinv_id, iostorinv_id) -// .eq(IOStorInvDis::getWork_status, IOSEnum.INBILL_DIS_STATUS.code("生成")) -// .and(wrapper -> wrapper.isNotNull(IOStorInvDis::getStruct_code) -// .ne(IOStorInvDis::getStruct_code, "")) -// .select(IOStorInvDis::getIostorinvdis_id -// , IOStorInvDis::getStruct_code -// , IOStorInvDis::getStoragevehicle_code) -// ); -// if (ObjectUtil.isEmpty(ioStorInvDisList)) { -// throw new BadRequestException("当前没有可设置的分配明细"); -// } -// //仓储出入任务 -// StOutTask stOutTask = SpringContextHolder.getBean("STOutTask"); -// //分配明细中同分配到同载具的进行合并 -// Map> groupDis = ioStorInvDisList.stream().collect(Collectors.groupingBy(dis -> dis.getStoragevehicle_code())); -// for (String storageVehicleCode : groupDis.keySet()) { -// List disList = groupDis.get(storageVehicleCode); -// IOStorInvDis item = disList.get(0); -// //创建任务 -// JSONObject task_form = new JSONObject(); -// task_form.put("task_type", "STOutTask"); -// task_form.put("TaskCode", CodeUtil.getNewCode("TASK_CODE")); -// task_form.put("PickingLocation", item.getStruct_code()); -// task_form.put("PlacedLocation", item.getPoint_code()); -// task_form.put("vehicle_code", item.getStoragevehicle_code()); -// String task_id = stOutTask.create(task_form); -// ioStorInvDisMapper.update(null, new LambdaUpdateWrapper() -// .set(IOStorInvDis::getTask_id, task_id) -// .set(IOStorInvDis::getIs_issued, BaseDataEnum.IS_YES_NOT.code("是")) -// .set(IOStorInvDis::getWork_status, IOSEnum.INBILL_DIS_STATUS.code("执行中")) -// .in(IOStorInvDis::getIostorinvdis_id, disList.stream() -// .map(IOStorInvDis::getIostorinvdis_id).collect(Collectors.toList()))); -// } -// return; -// } - - //出库点 -// if (StrUtil.isBlank(whereJson.getString("point_code"))) { -// throw new BadRequestException("未选择出库点"); -// } - //----根据区域找点,特殊业务比如找空点位在这边---- List pointList = schBasePointMapper.selectList(new LambdaQueryWrapper() .eq(SchBasePoint::getRegion_code, regionCode) @@ -722,10 +679,11 @@ public class OutBillServiceImpl extends ServiceImpl i throw new BadRequestException("当前没有可设置的分配明细"); } //仓储出入任务:部门领料单(SAP PP113)下发专属任务,任务完成后由 PDA 拣选确认按实际数量出库 - boolean deptPickingBill = ioStorInvDtlMapper.selectCount(new LambdaQueryWrapper() - .eq(IOStorInvDtl::getIostorinv_id, iostorinv_id) - .eq(IOStorInvDtl::getSource_bill_type, SourceBillTypeEnum.SAP_DEPT_PICKING.getBillType())) > 0; - String taskBeanName = deptPickingBill ? "DeptPickingOutTask" : "STOutTask"; +// boolean deptPickingBill = ioStorInvDtlMapper.selectCount(new LambdaQueryWrapper() +// .eq(IOStorInvDtl::getIostorinv_id, iostorinv_id) +// .eq(IOStorInvDtl::getSource_bill_type, SourceBillTypeEnum.SAP_DEPT_PICKING.getBillType())) > 0; + String taskBeanName = "DeptPickingOutTask"; + //所有出库都需要在PDA做出库确认 AbstractTask outTask = SpringContextHolder.getBean(taskBeanName); //分配明细中同分配到同载具的进行合并 Map> groupDis = ioStorInvDisList.stream().collect(Collectors.groupingBy(dis -> dis.getStoragevehicle_code())); diff --git a/nladmin-ui/src/views/wms/pm_manage/sap/outBoundDelivery/index.vue b/nladmin-ui/src/views/wms/pm_manage/sap/outBoundDelivery/index.vue index 44a12e2a..d004634f 100644 --- a/nladmin-ui/src/views/wms/pm_manage/sap/outBoundDelivery/index.vue +++ b/nladmin-ui/src/views/wms/pm_manage/sap/outBoundDelivery/index.vue @@ -333,6 +333,7 @@ export default { { value: 'SUBCONTRACT_OUT', label: '委外交货出库' }, { value: 'TRANSFER_IN', label: '公司间调拨收货' }, { value: 'SALES_OUT', label: '原材料销售出库' }, + { value: 'TRANSFER_OUT', label: '原材料销售出库' }, { value: 'SALES_RETURN_IN', label: '原材料销售退货' } ], storageOnlyBilltypes: ['TRANSFER_IN', 'SALES_RETURN_IN'],