|
|
|
@ -1020,6 +1020,18 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl<Distribution
|
|
|
|
|
@Override |
|
|
|
|
@Transactional |
|
|
|
|
public R signfor(DistrilbutionAppsignforDTO distrilbutionloadingscanDTO) { |
|
|
|
|
String nickName = null; |
|
|
|
|
Long userId = null; |
|
|
|
|
|
|
|
|
|
try { |
|
|
|
|
|
|
|
|
|
nickName = AuthUtil.getNickName(); |
|
|
|
|
userId = AuthUtil.getUserId(); |
|
|
|
|
} catch (Exception e) { |
|
|
|
|
log.error(">>>>> 签收异常报错", e); |
|
|
|
|
throw new CustomerException("当前登录信息不已失效,请重新登录"); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss.SSS"); |
|
|
|
|
// ---------------------------------2023-09-09 包件签收调整---------------------------------------------------------------
|
|
|
|
@ -1072,17 +1084,7 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl<Distribution
|
|
|
|
|
loadscanEntity.setSignforState(2); |
|
|
|
|
loadscanEntity.setReceivedQuantity(loadscanEntity.getLoadedNub()); |
|
|
|
|
|
|
|
|
|
String nickName = AuthUtil.getNickName(); |
|
|
|
|
Long userId = AuthUtil.getUserId(); |
|
|
|
|
|
|
|
|
|
try { |
|
|
|
|
|
|
|
|
|
nickName = AuthUtil.getNickName(); |
|
|
|
|
userId = AuthUtil.getUserId(); |
|
|
|
|
} catch (Exception e) { |
|
|
|
|
log.error(">>>>> 签收异常报错", e); |
|
|
|
|
throw new CustomerException("当前登录信息不已失效,请重新登录"); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
loadscanEntity.setSigningUser(nickName); |
|
|
|
|
loadscanEntity.setSigningUserId(userId); |
|
|
|
@ -1174,7 +1176,10 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl<Distribution
|
|
|
|
|
//维护签收包件状态
|
|
|
|
|
distributionStockArticleService.maintenanceOrderInfo(collect.get(0).getOrderCode(),myCurrentWarehouse.getId()); |
|
|
|
|
//推送信息至工厂
|
|
|
|
|
distributionAsyncService.sendFactory(collect.get(0), distributionReservationEntity.getId(), distributionReservationEntity.getReservationCode(), myCurrentWarehouse.getName()); |
|
|
|
|
|
|
|
|
|
distributionAsyncService.sendFactory(collect.get(0), simpleDateFormat.format(new Date()), distributionReservationEntity.getId(), distributionReservationEntity.getReservationCode(), myCurrentWarehouse.getName(),nickName); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//TODO 这里就需要一个异步的包件状态维护方法
|
|
|
|
|
} else if (Func.isEmpty(collect)) { |
|
|
|
|
//这里就需要对该包件信息是否属于该配送计划进行判定。如果属于该配送计划则是串货。不是那么则需要提示是否异常签收或者返回的操作
|
|
|
|
@ -1223,6 +1228,18 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl<Distribution
|
|
|
|
|
@Transactional |
|
|
|
|
public R signforPC(DistrilbutionAppsignforDTO distrilbutionloadingscanDTO) { |
|
|
|
|
|
|
|
|
|
String nickName =null; |
|
|
|
|
Long userId = null; |
|
|
|
|
|
|
|
|
|
try { |
|
|
|
|
|
|
|
|
|
nickName = AuthUtil.getNickName(); |
|
|
|
|
userId = AuthUtil.getUserId(); |
|
|
|
|
} catch (Exception e) { |
|
|
|
|
log.error(">>>>> 签收异常报错", e); |
|
|
|
|
throw new CustomerException("当前登录信息不已失效,请重新登录"); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss.SSS"); |
|
|
|
|
// ---------------------------------2023-09-09 包件签收调整---------------------------------------------------------------
|
|
|
|
|
|
|
|
|
@ -1283,22 +1300,10 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl<Distribution
|
|
|
|
|
loadscanEntity.setSignforState(2); |
|
|
|
|
loadscanEntity.setReceivedQuantity(loadscanEntity.getLoadedNub()); |
|
|
|
|
|
|
|
|
|
String nickName = AuthUtil.getNickName(); |
|
|
|
|
Long userId = AuthUtil.getUserId(); |
|
|
|
|
|
|
|
|
|
try { |
|
|
|
|
|
|
|
|
|
nickName = AuthUtil.getNickName(); |
|
|
|
|
userId = AuthUtil.getUserId(); |
|
|
|
|
} catch (Exception e) { |
|
|
|
|
log.error(">>>>> 签收异常报错", e); |
|
|
|
|
throw new CustomerException("当前登录信息不已失效,请重新登录"); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
loadscanEntity.setSigningUser(nickName); |
|
|
|
|
loadscanEntity.setSigningUserId(userId); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
distributionLoadscanService.updateById(loadscanEntity); |
|
|
|
|
//缺少一个异步维护包件签收的方法
|
|
|
|
|
// distributionAsyncService.changeOrderSignforStatus(collect.get(0));
|
|
|
|
@ -1385,7 +1390,7 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl<Distribution
|
|
|
|
|
//维护签收包件状态
|
|
|
|
|
distributionStockArticleService.maintenanceOrderInfo(collect.get(0).getOrderCode(),myCurrentWarehouse.getId()); |
|
|
|
|
//推送信息至工厂
|
|
|
|
|
distributionAsyncService.sendFactory(collect.get(0), distributionReservationEntity.getId(), distributionReservationEntity.getReservationCode(), myCurrentWarehouse.getName()); |
|
|
|
|
distributionAsyncService.sendFactory(collect.get(0),simpleDateFormat.format(new Date()), distributionReservationEntity.getId(), distributionReservationEntity.getReservationCode(), myCurrentWarehouse.getName(), nickName); |
|
|
|
|
//收集包件
|
|
|
|
|
orderpackages.add(collect.get(0).getOrderPackageCode()); |
|
|
|
|
} else { |
|
|
|
@ -2617,6 +2622,8 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl<Distribution
|
|
|
|
|
@Override |
|
|
|
|
@Transactional |
|
|
|
|
public R oneclick(DistributionSignforDTO distributionSignfor) { |
|
|
|
|
|
|
|
|
|
BladeUser user = AuthUtil.getUser(); |
|
|
|
|
BasicdataWarehouseEntity myCurrentWarehouse = basicdataWarehouseClient.getMyCurrentWarehouse(); |
|
|
|
|
if (Objects.isNull(myCurrentWarehouse)) { |
|
|
|
|
throw new CustomerException(403, "仓库信息不能为空"); |
|
|
|
@ -2678,7 +2685,6 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl<Distribution
|
|
|
|
|
log.error("###############重复签收+{" + distributionSignforEntity + "}"); |
|
|
|
|
return R.fail("签收失败"); |
|
|
|
|
} |
|
|
|
|
BladeUser user = AuthUtil.getUser(); |
|
|
|
|
//处理库存品
|
|
|
|
|
//查询出该客户下的库存品信息
|
|
|
|
|
List<DisStockListDetailEntity> detailEntities = distributionReservationMapper.selectInventoryListByReservation(distributionSignforEntity.getReservationId()); |
|
|
|
@ -3018,7 +3024,7 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl<Distribution
|
|
|
|
|
distributionAsyncService.checkSignStatus(loadscanEntities.getPackageId(), loadscanEntities.getReservationId(), loadscanEntities.getDeliveryId()); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
distributionAsyncService.sendFactory(parcelListEntity, reservationEntity.getId(), reservationEntity.getReservationCode(), myCurrentWarehouse.getName()); |
|
|
|
|
distributionAsyncService.sendFactory(parcelListEntity,simpleDateFormat.format(new Date()), reservationEntity.getId(), reservationEntity.getReservationCode(), myCurrentWarehouse.getName(),user.getNickName()); |
|
|
|
|
packageIds.add(parcelListEntity.getId()); |
|
|
|
|
orderCodes.add(parcelListEntity.getOrderCode()); |
|
|
|
|
} |
|
|
|
|