Browse Source

Merge branch 'dev' into pre-production

chenglong
汤建军 1 year ago
parent
commit
ab701db77a
  1. 5
      blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/UpDownStockupAreaVO.java
  2. 2
      blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/entity/WarehouseUpdownStockupAreaEntity.java
  3. 2
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DisStockListDetailMapper.xml
  4. 4
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionSignforServiceImpl.java
  5. 14
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/UpStockupAreaPackageDTO.java
  6. 53
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseUpdownStockupAreaServiceImpl.java

5
blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/UpDownStockupAreaVO.java

@ -26,9 +26,14 @@ public class UpDownStockupAreaVO {
private String goodsType; private String goodsType;
private String orderCode; private String orderCode;
private String materielCode;
private String materielName;
private Long orderId; private Long orderId;
private Integer num;
} }

2
blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/entity/WarehouseUpdownStockupAreaEntity.java

@ -84,7 +84,7 @@ public class WarehouseUpdownStockupAreaEntity extends TenantEntity {
private String materielCode ; private String materielCode ;
/** 物料名称 */ /** 物料名称 */
@ApiModelProperty(name = "物料名称",notes = "") @ApiModelProperty(name = "物料名称",notes = "")
private String materielName ; private String materielName;
/** 仓库id */ /** 仓库id */
@ApiModelProperty(name = "仓库id",notes = "") @ApiModelProperty(name = "仓库id",notes = "")
private Long warehouseId; private Long warehouseId;

2
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DisStockListDetailMapper.xml

@ -61,7 +61,7 @@
ldsl.id AS orderId, ldsl.id AS orderId,
ldsl.order_code AS orderCode, ldsl.order_code AS orderCode,
ldsl.incoming_batch AS incomingBatch, ldsl.incoming_batch AS incomingBatch,
#{warehouseId} AS warehouseId, #{warehouseId} AS warehouseId
FROM FROM
logpm_dis_stock_list_detail AS ldsld logpm_dis_stock_list_detail AS ldsld
LEFT JOIN logpm_distribution_stock_list AS ldsl ON ldsld.stock_list_id = ldsl.id LEFT JOIN logpm_distribution_stock_list AS ldsl ON ldsld.stock_list_id = ldsl.id

4
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionSignforServiceImpl.java

@ -47,6 +47,7 @@ import com.logpm.distribution.wrapper.DistributionStockArticleWrapper;
import com.logpm.warehouse.feign.IWarehouseUpdownTypeClient; import com.logpm.warehouse.feign.IWarehouseUpdownTypeClient;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang.StringUtils; import org.apache.commons.lang.StringUtils;
import org.apache.logging.log4j.util.Strings;
import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.NotNull;
import org.springblade.common.constant.DictBizConstant; import org.springblade.common.constant.DictBizConstant;
import org.springblade.common.constant.DistributionTypeConstant; import org.springblade.common.constant.DistributionTypeConstant;
@ -782,6 +783,9 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl<Distribution
@Override @Override
public R signingPackageDetail(Long reservationId) { public R signingPackageDetail(Long reservationId) {
List<DistributionAppPackageDetailVO> details = baseMapper.signingPackageDetail(reservationId); List<DistributionAppPackageDetailVO> details = baseMapper.signingPackageDetail(reservationId);
if (Func.isNotEmpty(details)){
details = details.stream().filter(f-> !Strings.isBlank(f.getOrderPackageCode())).collect(Collectors.toList());
}
return R.data(details); return R.data(details);
} }

14
blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/UpStockupAreaPackageDTO.java

@ -36,7 +36,7 @@ public class UpStockupAreaPackageDTO implements Serializable {
/** /**
* 绑定ID 与上方对应 * 绑定ID 与上方对应
*/ */
private String associationId; private Long associationId;
/** /**
* 批次号 库存品专属 * 批次号 库存品专属
@ -48,6 +48,18 @@ public class UpStockupAreaPackageDTO implements Serializable {
*/ */
private String goodsType; private String goodsType;
/**
* 物料编码
*/
private String materielCode; /**
* 物料名称
*/
private String materielName;
/**
* 数量
*/
private Integer num;

53
blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseUpdownStockupAreaServiceImpl.java

@ -28,8 +28,10 @@ import com.logpm.basicdata.feign.IBasicdataGoodsAreaClient;
import com.logpm.basicdata.feign.IBasicdataGoodsShelfClient; import com.logpm.basicdata.feign.IBasicdataGoodsShelfClient;
import com.logpm.basicdata.feign.IBasicdataWarehouseClient; import com.logpm.basicdata.feign.IBasicdataWarehouseClient;
import com.logpm.distribution.entity.DistributionParcelListEntity; import com.logpm.distribution.entity.DistributionParcelListEntity;
import com.logpm.distribution.entity.DistributionStockArticleEntity;
import com.logpm.distribution.feign.IDisStockListDetailClient; import com.logpm.distribution.feign.IDisStockListDetailClient;
import com.logpm.distribution.feign.IDistributionParcelListClient; import com.logpm.distribution.feign.IDistributionParcelListClient;
import com.logpm.distribution.feign.IDistributionStockArticleClient;
import com.logpm.distribution.vo.UpDownStockupAreaVO; import com.logpm.distribution.vo.UpDownStockupAreaVO;
import com.logpm.warehouse.dto.UpShelfPackageDTO; import com.logpm.warehouse.dto.UpShelfPackageDTO;
import com.logpm.warehouse.dto.UpStockupAreaPackageDTO; import com.logpm.warehouse.dto.UpStockupAreaPackageDTO;
@ -86,6 +88,8 @@ public class WarehouseUpdownStockupAreaServiceImpl extends BaseServiceImpl<Wareh
private final IWarehouseUpdownStockupAreaLogService warehouseUpdownStockupAreaLogService; private final IWarehouseUpdownStockupAreaLogService warehouseUpdownStockupAreaLogService;
private final IDistributionStockArticleClient distributionStockArticleClient;
/** /**
@ -99,6 +103,8 @@ public class WarehouseUpdownStockupAreaServiceImpl extends BaseServiceImpl<Wareh
//这里有可能会查询出订制品包件和有数据的库存品包件 //这里有可能会查询出订制品包件和有数据的库存品包件
DistributionParcelListEntity parcelListEntity = parcelListClient.findByPacketBarCodeAndWarehouseId( orderPackageCode,warehouseId); DistributionParcelListEntity parcelListEntity = parcelListClient.findByPacketBarCodeAndWarehouseId( orderPackageCode,warehouseId);
if (Func.isNotEmpty(parcelListEntity)){ if (Func.isNotEmpty(parcelListEntity)){
DistributionStockArticleEntity entityByStockArticleId = distributionStockArticleClient.findEntityByStockArticleId(parcelListEntity.getStockArticleId());
UpDownStockupAreaVO stockupAreaVo = Func.copy(parcelListEntity, UpDownStockupAreaVO.class); UpDownStockupAreaVO stockupAreaVo = Func.copy(parcelListEntity, UpDownStockupAreaVO.class);
if (Func.isNotEmpty(parcelListEntity.getMallId())){ if (Func.isNotEmpty(parcelListEntity.getMallId())){
stockupAreaVo.setMarketId(parcelListEntity.getMallId()); stockupAreaVo.setMarketId(parcelListEntity.getMallId());
@ -110,16 +116,23 @@ public class WarehouseUpdownStockupAreaServiceImpl extends BaseServiceImpl<Wareh
stockupAreaVo.setOrderId(parcelListEntity.getStockArticleId()); stockupAreaVo.setOrderId(parcelListEntity.getStockArticleId());
stockupAreaVo.setAssociationId(parcelListEntity.getId()); stockupAreaVo.setAssociationId(parcelListEntity.getId());
stockupAreaVo.setAssociationValue(parcelListEntity.getOrderPackageCode()); stockupAreaVo.setAssociationValue(parcelListEntity.getOrderPackageCode());
stockupAreaVo.setNum(parcelListEntity.getQuantity());
stockupAreaVo.setMarketId(entityByStockArticleId.getMallId());
stockupAreaVo.setMarketName(entityByStockArticleId.getMallName());
if (1==parcelListEntity.getConditions()){ if (1==parcelListEntity.getConditions()){
stockupAreaVo.setAssociationType("2"); stockupAreaVo.setAssociationType("2");
}else { }else {
stockupAreaVo.setAssociationType("3"); stockupAreaVo.setAssociationType("3");
stockupAreaVo.setIncomingBatch(parcelListEntity.getOrderCode());
stockupAreaVo.setMaterielCode(parcelListEntity.getMaterialCode());
stockupAreaVo.setMaterielName(parcelListEntity.getMaterialName());
} }
return stockupAreaVo; return stockupAreaVo;
} }
if (Func.isEmpty(parcelListEntity)){ if (Func.isEmpty(parcelListEntity)){
//查询无数据已备货库存品包件 //查询无数据已备货库存品包件
UpDownStockupAreaVO stockupAreaVo =disStockListDetailClient.findByPacketBarCodeAndWarehouseId(warehouseId,orderPackageCode); UpDownStockupAreaVO stockupAreaVo =disStockListDetailClient.findByPacketBarCodeAndWarehouseId(warehouseId,orderPackageCode);
//按照无数据进行上架数据整理
if (Func.isNotEmpty(stockupAreaVo)){ if (Func.isNotEmpty(stockupAreaVo)){
return stockupAreaVo; return stockupAreaVo;
} }
@ -196,22 +209,32 @@ public class WarehouseUpdownStockupAreaServiceImpl extends BaseServiceImpl<Wareh
waitUpShelfPackageDTO.add(upShelfPackageDTO); waitUpShelfPackageDTO.add(upShelfPackageDTO);
} }
} }
WarehouseUpdownStockupAreaEntity updownStockupAreaEntity = BeanUtil.copy(upStockupAreaPackageDTO, WarehouseUpdownStockupAreaEntity.class); //查询是否已经进行上架了 如果进行上架了则不需要进行重复添加
updownStockupAreaEntity.setAreaTitle(goodsAreaEntity.getHeadline()); WarehouseUpdownStockupAreaEntity isHave = this.getOne(Wrappers.<WarehouseUpdownStockupAreaEntity>query().lambda()
updownStockupAreaEntity.setAreaId(goodsAreaEntity.getId()); .eq(WarehouseUpdownStockupAreaEntity::getWarehouseId, warehouseId)
updownStockupAreaEntity.setShelfId(goodsShelfEntity.getId()); .eq(WarehouseUpdownStockupAreaEntity::getAssociationValue, upStockupAreaPackageDTO.getAssociationValue())
updownStockupAreaEntity.setShelfTitle(goodsShelfEntity.getGoodsShelfName()); .eq(WarehouseUpdownStockupAreaEntity::getAssociationType, upStockupAreaPackageDTO.getAssociationType())
updownStockupAreaEntity.setAllocationId(goodsAllocationEntity.getId()); .eq(WarehouseUpdownStockupAreaEntity::getAllocationId, upStockupAreaPackageDTO.getAssociationId())
updownStockupAreaEntity.setAllocationTitle(goodsAllocationEntity.getGoodsAllocationName()); .eq(WarehouseUpdownStockupAreaEntity::getGoodsType, upStockupAreaPackageDTO.getGoodsType())
updownStockupAreaEntity.setPositionCode(goodsAllocationEntity.getQrCode()); );
updownStockupAreaEntity.setUpdownType("包条"); if (Objects.isNull(isHave)){
waitSaveWarehouseUpdownStockupAreaEntity.add(updownStockupAreaEntity); WarehouseUpdownStockupAreaEntity updownStockupAreaEntity = BeanUtil.copy(upStockupAreaPackageDTO, WarehouseUpdownStockupAreaEntity.class);
WarehouseUpdownStockupAreaLogEntity warehouseUpdownStockupAreaLogEntity = BeanUtil.copy(updownStockupAreaEntity, WarehouseUpdownStockupAreaLogEntity.class); updownStockupAreaEntity.setAreaTitle(goodsAreaEntity.getHeadline());
warehouseUpdownStockupAreaLogEntity.setRemark("扫描上架:包条上架"); updownStockupAreaEntity.setAreaId(goodsAreaEntity.getId());
warehouseUpdownStockupAreaLogEntity.setBindingType(1); updownStockupAreaEntity.setShelfId(goodsShelfEntity.getId());
waitSaveWarehouseUpdownStockupAreaLogEntity.add(warehouseUpdownStockupAreaLogEntity); updownStockupAreaEntity.setShelfTitle(goodsShelfEntity.getGoodsShelfName());
updownStockupAreaEntity.setAllocationId(goodsAllocationEntity.getId());
updownStockupAreaEntity.setAllocationTitle(goodsAllocationEntity.getGoodsAllocationName());
updownStockupAreaEntity.setPositionCode(goodsAllocationEntity.getQrCode());
updownStockupAreaEntity.setWarehouseId(warehouseId);
updownStockupAreaEntity.setUpdownType("包条");
waitSaveWarehouseUpdownStockupAreaEntity.add(updownStockupAreaEntity);
WarehouseUpdownStockupAreaLogEntity warehouseUpdownStockupAreaLogEntity = BeanUtil.copy(updownStockupAreaEntity, WarehouseUpdownStockupAreaLogEntity.class);
warehouseUpdownStockupAreaLogEntity.setRemark("扫描上架:包条上架");
warehouseUpdownStockupAreaLogEntity.setBindingType(1);
waitSaveWarehouseUpdownStockupAreaLogEntity.add(warehouseUpdownStockupAreaLogEntity);
}
//查询是否进行了上架,如果进行了上架需要进行对原库位进行下架, //查询是否进行了上架,如果进行了上架需要进行对原库位进行下架,
} }
if (Func.isNotEmpty(waitUpShelfPackageDTO)){ if (Func.isNotEmpty(waitUpShelfPackageDTO)){
//存在需要进行下架操作的包件 //存在需要进行下架操作的包件

Loading…
Cancel
Save