|
|
|
@ -40,6 +40,7 @@ import com.logpm.distribution.entity.*;
|
|
|
|
|
import com.logpm.distribution.excel.DistributionCityExcel; |
|
|
|
|
import com.logpm.distribution.excel.DistributionMarketExcel; |
|
|
|
|
import com.logpm.distribution.excel.DistributionSelfExcel; |
|
|
|
|
import com.logpm.distribution.excel.DistributionStockupPackageListDetailExcel; |
|
|
|
|
import com.logpm.distribution.mapper.*; |
|
|
|
|
import com.logpm.distribution.service.*; |
|
|
|
|
import com.logpm.distribution.vo.*; |
|
|
|
@ -54,6 +55,7 @@ import lombok.AllArgsConstructor;
|
|
|
|
|
import lombok.extern.slf4j.Slf4j; |
|
|
|
|
import org.springblade.common.constant.CodeDesEnum; |
|
|
|
|
import org.springblade.common.constant.DictBizConstant; |
|
|
|
|
import org.springblade.common.constant.common.IsOrNoConstant; |
|
|
|
|
import org.springblade.common.constant.orderpackage.OrderPackageStockupStatusConstant; |
|
|
|
|
import org.springblade.common.constant.pda.PdaAudioLingoStatus; |
|
|
|
|
import org.springblade.common.constant.stocklist.StockLockingStatusConstant; |
|
|
|
@ -199,6 +201,7 @@ public class DistributionStockupServiceImpl extends BaseServiceImpl<Distribution
|
|
|
|
|
@Autowired |
|
|
|
|
private DistributionStockListInfoMapper distributionStockListInfoMapper; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
|
public IPage<DistributionStockupVO> selectDistributionStockupPage(IPage<DistributionStockupVO> page, DistributionStockupVO distributionStockup) { |
|
|
|
|
return page.setRecords(baseMapper.selectDistributionStockupPage(page, distributionStockup)); |
|
|
|
@ -2904,7 +2907,6 @@ public class DistributionStockupServiceImpl extends BaseServiceImpl<Distribution
|
|
|
|
|
log.info("#############缺少库位ID:{}",stockupDTO.getAllocationId()); |
|
|
|
|
return null; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
//根据物料查询出多个库存品信息
|
|
|
|
|
List<DistributionStockListEntity> distributionStockListEntities = distributionStockListMapper.selectList(Wrappers.<DistributionStockListEntity>query().lambda() |
|
|
|
|
.eq(DistributionStockListEntity::getCargoNumber, stockupDTO.getCargoNumber()) |
|
|
|
@ -2963,11 +2965,14 @@ public class DistributionStockupServiceImpl extends BaseServiceImpl<Distribution
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
List<StockConfigOrderPackageListVO> ls = new ArrayList<>(); |
|
|
|
|
//过滤出同物料库存品的ID信息
|
|
|
|
|
List<Long> stockListIds = distributionStockListEntities.stream().map(DistributionStockListEntity::getId).collect(Collectors.toList()); |
|
|
|
|
LambdaQueryWrapper<DistributionStockEntity> lambdaQueryWrapper = new LambdaQueryWrapper<>(); |
|
|
|
|
lambdaQueryWrapper.eq(DistributionStockEntity::getReservationId, stockupDTO.getReservationId()); |
|
|
|
|
lambdaQueryWrapper.eq(DistributionStockEntity::getAllocationId, stockupDTO.getAllocationId()); |
|
|
|
|
lambdaQueryWrapper.eq(DistributionStockEntity::getType, 2); |
|
|
|
|
lambdaQueryWrapper.eq(DistributionStockEntity::getStockupId, stockupDTO.getStockupId()); |
|
|
|
|
lambdaQueryWrapper.in(DistributionStockEntity::getStockListId, stockListIds); |
|
|
|
|
List<DistributionStockEntity> distributionStockEntities = distributionStockMapper.selectList(lambdaQueryWrapper); |
|
|
|
|
for (DistributionStockEntity distributionStockEntity : distributionStockEntities) { |
|
|
|
|
StockConfigOrderPackageListVO stockConfigOrderPackageListVO = new StockConfigOrderPackageListVO(); |
|
|
|
@ -3116,4 +3121,42 @@ public class DistributionStockupServiceImpl extends BaseServiceImpl<Distribution
|
|
|
|
|
} |
|
|
|
|
return R.success("成功!!"); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
|
public List<DistributionStockupPackageListDetailExcel> exportStockUptDetail(List<Long> list) { |
|
|
|
|
List<DistributionStockupPackageListDetailExcel> stockupPackageListDetailExcels = baseMapper.exportStockUptOrderDetail(list); |
|
|
|
|
if (Func.isNotEmpty(stockupPackageListDetailExcels)){ |
|
|
|
|
for (DistributionStockupPackageListDetailExcel stockupPackageListDetailExcel : stockupPackageListDetailExcels) { |
|
|
|
|
if (stockupPackageListDetailExcel.getIsZero().equals(IsOrNoConstant.no.getValue())){ |
|
|
|
|
//订制品订单 查询托盘和库位
|
|
|
|
|
String trayName = warehouseTrayGoodsClient.getTrayNameByOrderPackageCode(stockupPackageListDetailExcel.getOrderPackageCode(),3); |
|
|
|
|
if (Func.isNotBlank(trayName)){ |
|
|
|
|
stockupPackageListDetailExcel.setTrayNames(trayName); |
|
|
|
|
} |
|
|
|
|
String allocationName = warehouseUpdownGoodsClient.getAllocationNameByOrderPackageCode(stockupPackageListDetailExcel.getOrderPackageCode(),3); |
|
|
|
|
if (Func.isNotBlank(allocationName)){ |
|
|
|
|
stockupPackageListDetailExcel.setAllocationNames(allocationName); |
|
|
|
|
} |
|
|
|
|
}else { |
|
|
|
|
//零担
|
|
|
|
|
String trayName = warehouseTrayGoodsClient.getTrayNameByOrderPackageCode(stockupPackageListDetailExcel.getOrderCode(),1); |
|
|
|
|
if (Func.isNotBlank(trayName)){ |
|
|
|
|
stockupPackageListDetailExcel.setTrayNames(trayName); |
|
|
|
|
} |
|
|
|
|
String allocationName = warehouseUpdownGoodsClient.getAllocationNameByOrderPackageCode(stockupPackageListDetailExcel.getOrderCode(),1); |
|
|
|
|
if (Func.isNotBlank(allocationName)){ |
|
|
|
|
stockupPackageListDetailExcel.setAllocationNames(allocationName); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//库存品
|
|
|
|
|
// List<DistributionStockupPackageListDetailExcel> stockupInventoryListDetailExcels = baseMapper.exportStockUptInventoryDetail(list);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return stockupPackageListDetailExcels; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|