Browse Source

Merge remote-tracking branch 'origin/dev' into dev

training
caoyizhong 2 years ago
parent
commit
3e703ad3cb
  1. 46
      blade-biz-common/src/main/java/org/springblade/common/constant/loading/LoadingAbnormalAuditingStatusConstant.java
  2. 22
      blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionLoadscanAbnormalEntity.java
  3. 4
      blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionLoadscanEntity.java
  4. 2
      blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionAddvalueVO.java
  5. 11
      blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/app/DistributionAppReservationVO.java
  6. 34
      blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/app/queryOrderVO.java
  7. 1
      blade-service/logpm-basic/src/main/java/com/logpm/basic/controller/BasicMaterialController.java
  8. 2
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/appcontroller/DistributionAddvalueAppController.java
  9. 16
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/appcontroller/DistributionDeliveryAppController.java
  10. 50
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/appcontroller/DistributionInQueryApiController.java
  11. 4
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/appcontroller/DistributionStockupAppController.java
  12. 21
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/config/RedissonConfig.java
  13. 17
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/dto/app/queryOrderDTO.java
  14. 3
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionAddvalueMapper.xml
  15. 8
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryListMapper.java
  16. 66
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryListMapper.xml
  17. 8
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionParcelListMapper.java
  18. 52
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionParcelListMapper.xml
  19. 5
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionStockArticleMapper.java
  20. 25
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionStockArticleMapper.xml
  21. 19
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/IDistributionAsyncService.java
  22. 7
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/IDistributionDeliveryListService.java
  23. 11
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/IDistributionStockArticleService.java
  24. 5
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionAddvalueServiceImpl.java
  25. 153
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionAsyncServiceImpl.java
  26. 187
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionDeliveryListServiceImpl.java
  27. 7
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionReservationServiceImpl.java
  28. 70
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionStockArticleServiceImpl.java
  29. 26
      blade-service/logpm-distribution/src/main/resources/application-prod.yml
  30. 2
      blade-service/logpm-factory/src/main/java/com/logpm/factory/oupai/receiver/OpReceivingDataHandler.java
  31. 28
      blade-service/logpm-factory/src/test/java/com/logpm/factory/TestService.java
  32. 1
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseUpdownGoodsLogMapper.xml
  33. 3
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseWarehousingEntryServiceImpl.java

46
blade-biz-common/src/main/java/org/springblade/common/constant/loading/LoadingAbnormalAuditingStatusConstant.java

@ -0,0 +1,46 @@
package org.springblade.common.constant.loading;
/**
* 异常装车审核枚举
* 对应码表 freeze_status
* @author TJJ
*/
public enum LoadingAbnormalAuditingStatusConstant {
daishenhe("待审核",1),
yishenhe("已审核",2),
yichang("异常",3);
/**
* 状态
*/
private String name;
/**
*
*/
private Integer value;
private LoadingAbnormalAuditingStatusConstant(String name, Integer value) {
this.name = name;
this.value = value;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public Integer getValue() {
return value;
}
public void setValue(Integer value) {
this.value = value;
}
}

22
blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionLoadscanAbnormalEntity.java

@ -40,32 +40,32 @@ public class DistributionLoadscanAbnormalEntity extends TenantEntity {
* 预约ID
*/
@ApiModelProperty(value = "预约ID")
private String reservationId;
private Long reservationId;
/**
* 配送管理ID
*/
@ApiModelProperty(value = "配送管理ID")
private String deliveryListId;
private Long deliveryListId;
/**
* 包件ID
*/
@ApiModelProperty(value = "包件ID")
private String packageId;
private Long packageId;
/**
* 订单ID
*/
@ApiModelProperty(value = "订单ID")
private String stockArticleId;
private Long stockArticleId;
/**
* 扫描操作人
*/
@ApiModelProperty(value = "扫描操作人")
private String sacnUser;
private String scanUser;
/**
* 扫描操作时间
*/
@ApiModelProperty(value = "扫描操作时间")
private String scanTime;
private Date scanTime;
/**
* 包条码
*/
@ -80,7 +80,7 @@ public class DistributionLoadscanAbnormalEntity extends TenantEntity {
* 司机ID
*/
@ApiModelProperty(value = "司机ID")
private String driverId;
private Long driverId;
/**
* 司机名称
*/
@ -90,7 +90,7 @@ public class DistributionLoadscanAbnormalEntity extends TenantEntity {
* 车辆ID
*/
@ApiModelProperty(value = "车辆ID")
private String vehicleId;
private Long vehicleId;
/**
* 车牌号
*/
@ -120,7 +120,7 @@ public class DistributionLoadscanAbnormalEntity extends TenantEntity {
* 审核时间
*/
@ApiModelProperty(value = "审核时间")
private String auditingTime;
private Date auditingTime;
/**
* 包件配送类型 1 - 商配 2-市配
*/
@ -135,12 +135,12 @@ public class DistributionLoadscanAbnormalEntity extends TenantEntity {
* 审核状态 1-未审核 2- 已审核 3 - 异常
*/
@ApiModelProperty(value = "审核状态 1-未审核 2- 已审核 3 - 异常")
private String auditingStatus;
private Integer auditingStatus;
/**
* 装车数量
*/
@ApiModelProperty(value = "装车数量")
private String loadingQuantity;
private Integer loadingQuantity;
/**
* 预留1
*/

4
blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionLoadscanEntity.java

@ -340,11 +340,11 @@ public class DistributionLoadscanEntity extends TenantEntity {
* 是否异常签收 1- 2-
*/
@ApiModelProperty(value = "是否异常签收 1-否 2-是")
private Long isAbnormalSigning;
private String isAbnormalSigning;
/**
* 是否异常装车 1- 2-
*/
@ApiModelProperty(value = "是否异常装车 1-否 2-是")
private Long isAbnormalLoading;
private String isAbnormalLoading;
}

2
blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionAddvalueVO.java

@ -53,5 +53,7 @@ public class DistributionAddvalueVO extends DistributionAddvalueEntity {
private Long addvalueDetailId;
private Integer isAll;
}

11
blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/app/DistributionAppReservationVO.java

@ -16,11 +16,15 @@
*/
package com.logpm.distribution.vo.app;
import com.logpm.distribution.entity.DistributionParcelListEntity;
import com.logpm.distribution.entity.DistributionReservationEntity;
import com.logpm.distribution.vo.DistributionParcelListVO;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import java.util.List;
/**
* 预约列表 App视图实体类
*
@ -98,6 +102,13 @@ public class DistributionAppReservationVO extends DistributionReservationEntity
private String goodsNames;
/**
* 包件信息
*/
@ApiModelProperty(value = "包件信息")
private List<DistributionParcelListVO> packageList;
}

34
blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/app/queryOrderVO.java

@ -0,0 +1,34 @@
package com.logpm.distribution.vo.app;
import com.logpm.distribution.entity.DistributionParcelListEntity;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import java.util.ArrayList;
import java.util.List;
@Data
@EqualsAndHashCode(callSuper = true)
public class queryOrderVO extends DistributionParcelListEntity {
private static final long serialVersionUID = 1L;
/**
* 包件列表
*/
@ApiModelProperty(value = "包件列表")
private List<DistributionParcelListEntity> list = new ArrayList<>();
/**
* 定制品
*/
@ApiModelProperty(value = "定制品数量")
private Integer wrapNum;
/**
* 库存品数量
*/
@ApiModelProperty(value = "定制品数量")
private Integer inventoryNum;
}

1
blade-service/logpm-basic/src/main/java/com/logpm/basic/controller/BasicMaterialController.java

@ -191,6 +191,7 @@ public class BasicMaterialController extends BladeController {
basicMaterialExcel.setLogpmUnit("1");
basicMaterialExcel.setPackageNum("3");
basicMaterialExcel.setWeight(BigDecimal.valueOf(0));
list.add(basicMaterialExcel);
ExcelUtil.export(response, "物料基础信息数据模板" + DateUtil.time(), "物料基础信息数据模板表", list, BasicMaterialExcel.class);
}

2
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/appcontroller/DistributionAddvalueAppController.java

@ -122,7 +122,7 @@ public class DistributionAddvalueAppController {
/**
* 查询编辑增值服务数据
* 查询增值服务数据
*/
@PostMapping("/addvalueInfo")
@ApiOperationSupport(order = 1)

16
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/appcontroller/DistributionDeliveryAppController.java

@ -13,6 +13,7 @@ import io.swagger.annotations.ApiOperation;
import lombok.AllArgsConstructor;
import org.springblade.core.mp.support.Condition;
import org.springblade.core.mp.support.Query;
import org.springblade.core.redis.cache.BladeRedis;
import org.springblade.core.tool.api.R;
import org.springframework.web.bind.annotation.*;
@ -36,6 +37,7 @@ public class DistributionDeliveryAppController {
/**
* 配送管理 列表
*/
@ -80,6 +82,8 @@ public class DistributionDeliveryAppController {
return R.data(pages);
}
/**
* 配送 查看订单
*/
@ -136,6 +140,18 @@ public class DistributionDeliveryAppController {
return msg;
}
/**
* 异常装车
*/
@PostMapping("/abnormalLoading")
@ApiOperationSupport(order = 3)
@ApiOperation(value = "详情", notes = "传入DistributionDeliveryListDTO")
public R abnormalLoading(@Valid @RequestBody DistrilbutionloadingscanDTO distrilbutionloadingscanDTO) {
R r= distributionDeliveryListService.abnormalLoading(distrilbutionloadingscanDTO);
return r;
}
/**
* 配送管理 库存品装车
*/

50
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/appcontroller/DistributionInQueryApiController.java

@ -0,0 +1,50 @@
package com.logpm.distribution.appcontroller;
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
import com.logpm.distribution.dto.app.queryOrderDTO;
import com.logpm.distribution.service.IDistributionStockArticleService;
import com.logpm.distribution.vo.app.queryOrderVO;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.AllArgsConstructor;
import lombok.extern.log4j.Log4j2;
import org.springblade.core.tool.api.R;
import org.springframework.web.bind.annotation.*;
import java.util.List;
@Log4j2
@RestController
@AllArgsConstructor
@RequestMapping("/app/distributionInQuery")
@Api(value = "库内查询", tags = "库内查询")
public class DistributionInQueryApiController {
private final IDistributionStockArticleService distributionStockArticleService;
@ResponseBody
@PostMapping("/order")
@ApiOperationSupport(order = 1)
@ApiOperation(value = "查询订单", notes = "传入trayTypeDTO")
public R order(@RequestBody queryOrderDTO queryrderDTO) {
if (null == queryrderDTO.getType()){
return R.fail("查询类型为空");
}
queryOrderVO q = distributionStockArticleService.queryOrder(queryrderDTO);
return R.data(q);
}
@ResponseBody
@PostMapping("/fuzzy")
@ApiOperationSupport(order = 1)
@ApiOperation(value = "模糊查询", notes = "传入trayTypeDTO")
public R fuzzy(@RequestBody queryOrderDTO queryrderDTO) {
if (null == queryrderDTO.getType()){
return R.fail("查询类型为空");
}
List<String> q = distributionStockArticleService.queryFuzzy(queryrderDTO);
return R.data(q);
}
}

4
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/appcontroller/DistributionStockupAppController.java

@ -451,7 +451,9 @@ public class DistributionStockupAppController extends BladeController {
// try{
//设置lockey
String lockKey = stockupDTO.getPacketBarCode()+stockupDTO.getStockupId();
RLock lock = new RedissonConfig().redisson().getLock(lockKey);
RLock lock =
new RedissonConfig().redisson().getLock(lockKey);
if(lock.isLocked()){
String audioValue2 = DictBizCache.getValue(DictBizConstant.PDA_AUDIO, "2");
return Resp.scanFail("重复扫描!", audioValue2);

21
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/config/RedissonConfig.java

@ -2,17 +2,34 @@ package com.logpm.distribution.config;
import org.redisson.Redisson;
import org.redisson.config.Config;
import org.springblade.core.redis.cache.BladeRedis;
import org.springblade.core.tool.utils.SpringUtil;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.data.redis.connection.RedisConnectionFactory;
import org.springframework.data.redis.connection.lettuce.LettuceConnectionFactory;
import org.springframework.stereotype.Component;
@Configuration
public class RedissonConfig {
@Bean
public Redisson redisson() {
// 单机模式
Config config = new Config();
config.useSingleServer().setAddress("redis://192.168.10.100:6379").setDatabase(0);
config.useSingleServer().setPassword("A0c415");
BladeRedis bean = SpringUtil.getBean(BladeRedis.class);
RedisConnectionFactory connectionFactory = bean.getRedisTemplate().getConnectionFactory();
LettuceConnectionFactory factory = (LettuceConnectionFactory) connectionFactory;
String hostName = factory.getHostName();
int port = factory.getPort();
String password = factory.getPassword();
config.useSingleServer().setAddress("redis://"+hostName+":"+port).setDatabase(1);
config.useSingleServer().setPassword(password);
return (Redisson) Redisson.create(config);
}

17
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/dto/app/queryOrderDTO.java

@ -0,0 +1,17 @@
package com.logpm.distribution.dto.app;
import lombok.Data;
@Data
public class queryOrderDTO {
/**
* 查询条件
*/
private String condition;
/**
* 类型1-包条,2-订单
*/
private Integer type;
}

3
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionAddvalueMapper.xml

@ -62,7 +62,8 @@
ldad.flool_num AS floolNum,
ldad.distance AS distance,
ldad.id AS addvalueDetailId,
GROUP_CONCAT(ldap.package_id) AS packageListIds
GROUP_CONCAT(ldap.package_id) AS packageListIds,
ldad.record_type AS isAll
FROM
logpm_distribution_addvalue AS lda
INNER JOIN logpm_distribution_addvalue_detail AS ldad ON lda.id = ldad.addvalue_id

8
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryListMapper.java

@ -377,4 +377,12 @@ public interface DistributionDeliveryListMapper extends BaseMapper<DistributionD
* @return
*/
DistributionReservationEntity selectReservationByDeliveryListIdAndCustomerUnit(@Param("deliveryListId")Long deliveryListEntityId,@Param("receivingUnit") String k);
/**
* 查找包件属于哪个预约任务
* @param orderPackageCode
* @param deliveryId
* @return
*/
DistributionReservationEntity selectReservationByPackageAndDeliveryId(@Param("orderPackageCode") String orderPackageCode,@Param("deliveryListId") Long deliveryId);
}

66
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryListMapper.xml

@ -1130,6 +1130,7 @@
ldr.loading_status,
ldr.signing_status,
ldr.stockup_status,
ldr.receiving_unit,
ldr.is_urgent,
ldr.collection_fee
FROM
@ -1407,5 +1408,70 @@
</if>
</where>
</select>
<select id="selectReservationByPackageAndDeliveryId"
resultType="com.logpm.distribution.entity.DistributionReservationEntity">
SELECT
ldr.id,
ldr.tenant_id,
ldr.create_user,
ldr.create_time,
ldr.update_user,
ldr.update_time,
ldr.status,
ldr.is_deleted,
ldr.create_dept,
ldr.stock_article_id,
ldr.mall_id,
ldr.mail_phone,
ldr.mall_name,
ldr.store_id,
ldr.store_name,
ldr.consignee,
ldr.delivery_address,
ldr.reservation_date,
ldr.serve_type,
ldr.delivery_way,
ldr.delivery_type,
ldr.collect_fee,
ldr.other_fee,
ldr.replace_fee,
ldr.delivery_phone,
ldr.reservation_status,
ldr.order_source,
ldr.stockup_status,
ldr.signing_status,
ldr.loading_status,
ldr.goods_area_name,
ldr.goods_area_id,
ldr.reserve1,
ldr.reserve2,
ldr.reserve3,
ldr.reserve4,
ldr.reserve5,
ldr.remarks,
ldr.shopping_id,
ldr.period_of_time,
ldr.fee,
ldr.reservation_num,
ldr.reservation_stock_list_num,
ldr.reservation_code,
ldr.service_number,
ldr.cancel_reason,
ldr.is_urgent,
ldr.collection_fee,
ldr.warehouse_name,
ldr.warehouse_id,
ldr.receiving_unit,
ldr.waybill_id,
ldr.waybill_no
FROM
logpm_distribution_delivery_list AS lddl
LEFT JOIN logpm_distribution_signfor AS lds ON lds.delivery_id = lddl.id
LEFT JOIN logpm_distribution_reservation AS ldr ON lds.reservation_id = ldr.id
LEFT JOIN logpm_distribution_reservation_package AS ldrp ON ldrp.reservation_id = ldr.id
INNER JOIN logpm_distribution_parcel_list AS ldpl ON ldrp.parce_list_id = ldpl.id
WHERE
lddl.id = #{deliveryListId} AND ldrp.packet_bar_status IN ('1','3') AND ldrp.packet_bar_code = #{orderPackageCode}
</select>
</mapper>

8
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionParcelListMapper.java

@ -28,6 +28,7 @@ import com.logpm.distribution.vo.DistributionParcelListVO;
import com.logpm.distribution.vo.PackageStockupVO;
import org.apache.ibatis.annotations.Param;
import java.util.ArrayList;
import java.util.List;
/**
@ -106,4 +107,11 @@ public interface DistributionParcelListMapper extends BaseMapper<DistributionPar
* @return
*/
List<DistributionParcelListEntity> getPackageList(@Param("stockArticleId") Long id);
List<DistributionParcelListEntity> selectListByOderId(@Param("id")Long id,@Param("collect") List<Long> collect);
ArrayList<String> selectorderPackageCodeByLike(@Param("condition") String condition,@Param("collect") List<Long> collect);
ArrayList<String> selectorderCodeByLike(@Param("condition") String condition,@Param("collect") List<Long> collect);
}

52
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionParcelListMapper.xml

@ -504,5 +504,57 @@
ldpl.stock_article_id = #{stockArticleId} and ldpl.order_package_reservation_status in ('10','20') and ldpl.order_package_reservation_status = '10'
</select>
<select id="selectListByOderId" resultType="com.logpm.distribution.entity.DistributionParcelListEntity">
SELECT
ldpl.id id,
ldpl.order_package_code orderPackageCode,
ldpl.warehouse warehouse,
ldpl.firsts firsts,
ldpl.SECOND SECOND,
ldpl.third_product thirdProduct,
ldpl.material_name materialName,
ldpl.order_package_status orderPackageStatus,
lwug.position_code goodsAllocation
FROM
logpm_distribution_parcel_list ldpl
JOIN logpm_distribution_stock_article ldsa ON ldpl.stock_article_id = ldsa.id
LEFT JOIN logpm_warehouse_updown_goods lwug ON lwug.association_id = ldpl.id
<where>
ldsa.is_deleted = 0
AND ldpl.conditions =1
<if test="id != null and id != ''" > and ldsa.id = #{id} </if>
<!-- <if test="condition != null and condition != ''" > and ldsa.order_code = #{condition} </if>-->
<if test="collect != null and @org.apache.commons.collections4.CollectionUtils@isNotEmpty(collect)">
and ldpl.warehouse_id in
<foreach collection="collect" item="item" open="(" close=")" separator=",">
#{item}
</foreach>
</if>
</where>
</select>
<select id="selectorderPackageCodeByLike" resultType="java.lang.String">
select order_package_code from logpm_distribution_parcel_list
<where>
is_deleted = 0 and order_package_code like concat('%',#{condition},'%')
<if test="collect != null and @org.apache.commons.collections4.CollectionUtils@isNotEmpty(collect)">
and warehouse_id in
<foreach collection="collect" item="item" open="(" close=")" separator=",">
#{item}
</foreach>
</if>
</where>
</select>
<select id="selectorderCodeByLike" resultType="java.lang.String">
select order_code from logpm_distribution_stock_article
<where>
is_deleted = 0 and order_code like concat('%',#{condition},'%')
<if test="collect != null and @org.apache.commons.collections4.CollectionUtils@isNotEmpty(collect)">
and warehouse_id in
<foreach collection="collect" item="item" open="(" close=")" separator=",">
#{item}
</foreach>
</if>
</where>
</select>
</mapper>

5
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionStockArticleMapper.java

@ -25,6 +25,7 @@ import com.logpm.distribution.entity.DistributionStockArticleEntity;
import com.logpm.distribution.excel.DistributionStockArticleExcel;
import com.logpm.distribution.vo.DistributionStockArticleQRCodeVO;
import com.logpm.distribution.vo.DistributionStockArticleVO;
import com.logpm.distribution.vo.app.queryOrderVO;
import org.apache.ibatis.annotations.Param;
import java.util.List;
@ -92,4 +93,8 @@ public interface DistributionStockArticleMapper extends BaseMapper<DistributionS
void updateGroundingStatus(@Param("orderCode") String orderCode, @Param("groundingStatus") String groundingStatus);
IPage<DistributionStockArticleEntity> pageListOwe(IPage page,@Param("param")DistributionStockArticleOweDTO stockArticleEntity);
queryOrderVO selectOneByWrap(@Param("condition") String condition,@Param("collect") List<Long> collect);
queryOrderVO selectOneByOrder(@Param("condition") String condition,@Param("collect") List<Long> collect);
}

25
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionStockArticleMapper.xml

@ -404,6 +404,31 @@
</where>
GROUP BY ldsa.id ,ldpl.id
</select>
<select id="selectOneByWrap" resultType="com.logpm.distribution.vo.app.queryOrderVO">
SELECT ldsa.* FROM logpm_distribution_parcel_list ldpl join logpm_distribution_stock_article ldsa on ldpl.stock_article_id = ldsa.id
<where>
ldsa.is_deleted =0 and ldpl.order_package_code = #{condition}
<if test="collect != null and @org.apache.commons.collections4.CollectionUtils@isNotEmpty(collect)">
and ldsa.warehouse_id in
<foreach collection="collect" item="item" open="(" close=")" separator=",">
#{item}
</foreach>
</if>
</where>
</select>
<select id="selectOneByOrder" resultType="com.logpm.distribution.vo.app.queryOrderVO">
SELECT ldsa.* FROM logpm_distribution_stock_article ldsa
<where>
ldsa.is_deleted =0 and ldsa.order_code = #{condition}
<if test="collect != null and @org.apache.commons.collections4.CollectionUtils@isNotEmpty(collect)">
and ldsa.warehouse_id in
<foreach collection="collect" item="item" open="(" close=")" separator=",">
#{item}
</foreach>
</if>
</where>
</select>
<update id="updateGroundingStatus" >
update logpm_distribution_stock_article

19
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/IDistributionAsyncService.java

@ -167,4 +167,23 @@ public interface IDistributionAsyncService {
* @param stockupDTO
*/
void stockupSelfOffShelf(StockupDTO stockupDTO) throws InterruptedException;
/**
* 检查维护装车状态
* @param parcelListEntity
* @param deliveryId
*/
void checkLoadingByPackage(DistributionParcelListEntity parcelListEntity, Long deliveryId);
/**
* 托盘装车 维护装车状态
* @param deliveryId
*/
void checkLoadingByDelivery(Long deliveryId);
/**
* 维护包件订单装车和出库状态
* @param parcelListEntity
*/
void checkOrderLoadingStatus(DistributionParcelListEntity parcelListEntity);
}

7
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/IDistributionDeliveryListService.java

@ -257,4 +257,11 @@ public interface IDistributionDeliveryListService extends BaseService<Distributi
* @return
*/
IPage<DistributionAppReservationVO> getAppDeliveryreservationTraysPage(IPage<DistributionAppReservationVO> page, DistributionAppDeliveryListDTO distributionDeliveryList);
/**
* 异常装车
* @param distrilbutionloadingscanDTO
* @return
*/
R abnormalLoading(DistrilbutionloadingscanDTO distrilbutionloadingscanDTO);
}

11
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/IDistributionStockArticleService.java

@ -19,10 +19,12 @@ package com.logpm.distribution.service;
import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.logpm.distribution.dto.DistributionStockArticleDTO;
import com.logpm.distribution.dto.app.queryOrderDTO;
import com.logpm.distribution.entity.DistributionStockArticleEntity;
import com.logpm.distribution.excel.DistributionStockArticleExcel;
import com.logpm.distribution.vo.DistributionStockArticleVO;
import com.logpm.distribution.vo.OrderPackgeCodeDataVO;
import com.logpm.distribution.vo.app.queryOrderVO;
import org.springblade.core.mp.base.BaseService;
import org.springblade.core.mp.support.Query;
import org.springblade.core.tool.api.R;
@ -135,4 +137,13 @@ public interface IDistributionStockArticleService extends BaseService<Distributi
* @return
*/
R selectStockArticleInfoList(Map<String, Object> distributionStockArticle, Query query);
/**
* 订单查询
* @param queryrderDTO
*/
queryOrderVO queryOrder(queryOrderDTO queryrderDTO);
queryOrderVO queryOrderVOCont(String condition,Integer i);
List<String> queryFuzzy(queryOrderDTO queryrderDTO);
}

5
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionAddvalueServiceImpl.java

@ -249,6 +249,11 @@ public class DistributionAddvalueServiceImpl extends BaseServiceImpl<Distributio
distributionAddvalueEntity.setDeliveryListId(distributionAppAddvalueDTO.getDeliveryId());
this.save(distributionAddvalueEntity);
distributionAddvalueDetailEntity.setAddvalueId(distributionAddvalueEntity.getId());
distributionAddvalueDetailEntity.setRecordType(2);
List<DistributionParcelListEntity> parcelListEntities = distributionReservationMapper.selectPackageListByReservationId(distributionAppAddvalueDTO.getReservationId());
if (parcelListEntities.size() == packageEntityList.size()){
distributionAddvalueDetailEntity.setRecordType(1);
}
distributionAddvalueDetailService.save(distributionAddvalueDetailEntity);
packageEntityList.stream().forEach(p->p.setAddvalueDetailId(distributionAddvalueDetailEntity.getId()));
distributionAddvaluePackageService.saveBatch(packageEntityList);

153
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionAsyncServiceImpl.java

@ -38,6 +38,7 @@ import org.springframework.transaction.annotation.Transactional;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import java.util.Map;
import java.util.concurrent.atomic.AtomicInteger;
import java.util.concurrent.atomic.AtomicReference;
import java.util.stream.Collectors;
@ -660,6 +661,152 @@ public class DistributionAsyncServiceImpl implements IDistributionAsyncService {
}*/
}
@Override
public void checkLoadingByPackage(DistributionParcelListEntity parcelListEntity, Long deliveryId) {
//首先能够进入这个检测方法那么此包件就是进行装车了,这里对包件装车状态再次进行维护
if (parcelListEntity.getOrderPackageLoadingStatus().equals(OrderPackageLoadingStatusConstant.weizhuancghe.getValue())){
parcelListEntity.setOrderPackageStatus(OrderPackageStatusConstant.yichuku.getValue());
parcelListEntity.setOrderPackageLoadingStatus(OrderPackageLoadingStatusConstant.yizhuangche.getValue());
distributionParcelListService.updateById(parcelListEntity);
}
//维护此包件对应的订单装车状态
DistributionStockArticleEntity stockArticleEntity = distributionStockArticleService.getById(parcelListEntity.getStockArticleId());
if (Func.isNotEmpty(stockArticleEntity)){
//查询订单的所有包件
List<DistributionParcelListEntity> parcelListEntities = distributionParcelListService.list(Wrappers.<DistributionParcelListEntity>query().lambda().eq(DistributionParcelListEntity::getStockArticleId, stockArticleEntity.getId()));
boolean orderLoadingFlag = parcelListEntities.stream().allMatch(p -> p.getOrderPackageLoadingStatus().equals(OrderPackageLoadingStatusConstant.yizhuangche.getValue()));
if (orderLoadingFlag){
stockArticleEntity.setOrderStatus(OrderStatusConstant.chuku.getValue());
}else {
orderLoadingFlag = parcelListEntities.stream().allMatch(p -> p.getOrderPackageLoadingStatus().equals(OrderPackageLoadingStatusConstant.weizhuancghe.getValue()));
if (!orderLoadingFlag){
stockArticleEntity.setOrderStatus(OrderStatusConstant.bufenchuku.getValue());
}
}
distributionStockArticleService.updateById(stockArticleEntity);
}
//维护预约计划
List<DistributionReservationEntity> reservationEntityList = distributionDeliveryListMapper.selectReservationByDeliveryListId(deliveryId);
if (Func.isNotEmpty(reservationEntityList) && reservationEntityList.size()>0){
for (DistributionReservationEntity reservationEntity : reservationEntityList) {
List<DistributionParcelListEntity> reservationParcelListEntities = distributionReservationMapper.selectPackageListByReservationId(reservationEntity.getId());
if (Func.isNotEmpty(reservationParcelListEntities)&& reservationParcelListEntities.size()>0){
boolean reservationLoadingFlag = reservationParcelListEntities.stream().allMatch(p -> p.getOrderPackageLoadingStatus().equals(OrderPackageLoadingStatusConstant.yizhuangche.getValue()));
if (reservationLoadingFlag){
reservationEntity.setLoadingStatus(ReservationLoadingStatusConstant.yizhuangche.getValue());
}else {
reservationLoadingFlag = reservationParcelListEntities.stream().allMatch(p -> p.getOrderPackageLoadingStatus().equals(OrderPackageLoadingStatusConstant.weizhuancghe.getValue()));
if (reservationLoadingFlag){
reservationEntity.setLoadingStatus(ReservationLoadingStatusConstant.daizhuangche.getValue());
}else {
reservationEntity.setLoadingStatus(ReservationLoadingStatusConstant.bufenzhuangche.getValue());
}
}
distributionReservationMapper.updateById(reservationEntity);
}
}
}
//维护配送计划
DistributionDeliveryListEntity deliveryListEntity = distributionDeliveryListMapper.selectById(deliveryId);
if (Func.isNotEmpty(deliveryListEntity)){
List<DistributionParcelListEntity> deliveryParcelListEntities = distributionDeliveryListMapper.selectPackageListByDeliveryListId(deliveryId);
if (Func.isNotEmpty(deliveryParcelListEntities) && deliveryParcelListEntities.size()>0){
boolean deliveryLoadingFlag = deliveryParcelListEntities.stream().allMatch(p -> p.getOrderPackageLoadingStatus().equals(OrderPackageLoadingStatusConstant.yizhuangche.getValue()));
if (deliveryLoadingFlag){
deliveryListEntity.setDeliveryListLoadingStatus(DeliveryLoadingStatusConstant.yizhuangche.getValue());
}else {
deliveryLoadingFlag = deliveryParcelListEntities.stream().allMatch(p -> p.getOrderPackageLoadingStatus().equals(OrderPackageLoadingStatusConstant.weizhuancghe.getValue()));
if (deliveryLoadingFlag){
deliveryListEntity.setDeliveryListLoadingStatus(DeliveryLoadingStatusConstant.weizhuangche.getValue());
}else {
deliveryListEntity.setDeliveryListLoadingStatus(DeliveryLoadingStatusConstant.bunfenzhuangche.getValue());
}
}
distributionDeliveryListMapper.updateById(deliveryListEntity);
}
}
}
@Override
public void checkLoadingByDelivery(Long deliveryId) {
DistributionDeliveryListEntity deliveryListEntity = distributionDeliveryListMapper.selectById(deliveryId);
if (Func.isNotEmpty(deliveryListEntity)){
List<DistributionParcelListEntity> deliveryParcelListEntities = distributionDeliveryListMapper.selectPackageListByDeliveryListId(deliveryId);
boolean deliveryLoadingFlag = deliveryParcelListEntities.stream().allMatch(p->p.getOrderPackageLoadingStatus().equals(OrderPackageLoadingStatusConstant.yizhuangche.getValue()));
if (deliveryLoadingFlag){
deliveryListEntity.setDeliveryListLoadingStatus(DeliveryLoadingStatusConstant.yizhuangche.getValue());
}else {
deliveryLoadingFlag = deliveryParcelListEntities.stream().allMatch(p->p.getOrderPackageLoadingStatus().equals(OrderPackageLoadingStatusConstant.weizhuancghe.getValue()));
if (deliveryLoadingFlag){
deliveryListEntity.setDeliveryListLoadingStatus(DeliveryLoadingStatusConstant.weizhuangche.getValue());
}else {
deliveryListEntity.setDeliveryListLoadingStatus(DeliveryLoadingStatusConstant.bunfenzhuangche.getValue());
}
}
distributionDeliveryListMapper.updateById(deliveryListEntity);
}
List<DistributionReservationEntity> reservationEntityList = distributionDeliveryListMapper.selectReservationByDeliveryListId(deliveryId);
if (Func.isNotEmpty(reservationEntityList) && reservationEntityList.size()>0){
for (DistributionReservationEntity reservationEntity : reservationEntityList) {
List<DistributionParcelListEntity> parcelListEntities = distributionReservationMapper.selectPackageListByReservationId(reservationEntity.getId());
Map<Long, List<DistributionParcelListEntity>> order = parcelListEntities.stream().collect(Collectors.groupingBy(DistributionParcelListEntity::getStockArticleId));
order.forEach((k,v)->{
DistributionStockArticleEntity stockArticleEntity = distributionStockArticleService.getById(k);
List<DistributionParcelListEntity> stockArticlePackageList = distributionParcelListService.list(Wrappers.<DistributionParcelListEntity>query().lambda().eq(DistributionParcelListEntity::getStockArticleId, k));
if (stockArticlePackageList.size() == v.size()){
boolean orderLoadingFlag = v.stream().allMatch(p -> p.getOrderPackageLoadingStatus().equals(OrderPackageLoadingStatusConstant.yizhuangche.getValue()));
if (orderLoadingFlag){
stockArticleEntity.setOrderStatus(OrderStatusConstant.chuku.getValue());
}else {
orderLoadingFlag = v.stream().allMatch(p -> p.getOrderPackageLoadingStatus().equals(OrderPackageLoadingStatusConstant.weizhuancghe.getValue()));
if (!orderLoadingFlag){
stockArticleEntity.setOrderStatus(OrderStatusConstant.bufenchuku.getValue());
}
}
}else {
boolean orderbufenLoadingFlag = v.stream().allMatch(p -> p.getOrderPackageLoadingStatus().equals(OrderPackageLoadingStatusConstant.yizhuangche.getValue()));
if (orderbufenLoadingFlag){
stockArticleEntity.setOrderStatus(OrderStatusConstant.bufenchuku.getValue());
}
}
distributionStockArticleService.updateById(stockArticleEntity);
});
boolean reservationLoadingFlag = parcelListEntities.stream().allMatch(p -> p.getOrderPackageLoadingStatus().equals(OrderPackageLoadingStatusConstant.yizhuangche.getValue()));
if (reservationLoadingFlag){
reservationEntity.setLoadingStatus(ReservationLoadingStatusConstant.yizhuangche.getValue());
}else {
reservationLoadingFlag = parcelListEntities.stream().allMatch(p -> p.getOrderPackageLoadingStatus().equals(OrderPackageLoadingStatusConstant.weizhuancghe.getValue()));
if (reservationLoadingFlag){
reservationEntity.setLoadingStatus(ReservationLoadingStatusConstant.daizhuangche.getValue());
}else {
reservationEntity.setLoadingStatus(ReservationLoadingStatusConstant.bufenzhuangche.getValue());
}
}
distributionReservationMapper.updateById(reservationEntity);
}
}
}
@Override
public void checkOrderLoadingStatus(DistributionParcelListEntity parcelListEntity) {
DistributionStockArticleEntity stockArticleEntity = distributionStockArticleService.getById(parcelListEntity.getStockArticleId());
List<DistributionParcelListEntity> parcelListEntityList = distributionParcelListService.list(Wrappers.<DistributionParcelListEntity>query().lambda()
.eq(DistributionParcelListEntity::getStockArticleId, parcelListEntity.getStockArticleId()));
boolean flag = parcelListEntityList.stream().allMatch(p -> p.getOrderPackageLoadingStatus().equals(OrderPackageLoadingStatusConstant.yizhuangche.getValue()));
if (flag){
stockArticleEntity.setOrderStatus(OrderStatusConstant.chuku.getValue());
}else {
flag = parcelListEntityList.stream().allMatch(p -> p.getOrderPackageLoadingStatus().equals(OrderPackageLoadingStatusConstant.weizhuancghe.getValue()));
if (!flag){
stockArticleEntity.setOrderStatus(OrderStatusConstant.bufenchuku.getValue());
}
}
distributionStockArticleService.updateById(stockArticleEntity);
}
/**
* 自提签收片段是否签收完全
@ -927,10 +1074,10 @@ public class DistributionAsyncServiceImpl implements IDistributionAsyncService {
//这里表示所有的包件都是已装车,进行订单状态修改已出库
stockArticleEntity.setOrderStatus(OrderStatusConstant.chuku.getValue());
} else {
flag = parcelListEntityList.stream().allMatch(pack -> pack.getOrderPackageReservationStatus().equals(OrderPackageReservationStatusConstant.daiyuyue.getValue()));
if (flag) {
flag = parcelListEntityList.stream().allMatch(pack -> pack.getOrderPackageReservationStatus().equals(OrderPackageLoadingStatusConstant.weizhuancghe.getValue()));
if (!flag) {
//全部未装车
stockArticleEntity.setOrderStatus(OrderStatusConstant.ruku.getValue());
stockArticleEntity.setOrderStatus(OrderStatusConstant.bufenchuku.getValue());
} else {
//部分预约
stockArticleEntity.setOrderStatus(OrderStatusConstant.bufenchuku.getValue());

187
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionDeliveryListServiceImpl.java

@ -58,6 +58,7 @@ import org.springblade.common.constant.DistributionTypeConstant;
import org.springblade.common.constant.Inventory.InventoryLoadingStatusConstant;
import org.springblade.common.constant.delivery.DeliveryLoadingStatusConstant;
import org.springblade.common.constant.delivery.DeliveryStatusConstant;
import org.springblade.common.constant.loading.LoadingAbnormalAuditingStatusConstant;
import org.springblade.common.constant.loading.LoadingIsInsertConstant;
import org.springblade.common.constant.loading.LoadingStatusConstant;
import org.springblade.common.constant.order.OrderStatusConstant;
@ -78,6 +79,7 @@ import org.springblade.core.log.exception.ServiceException;
import org.springblade.core.mp.base.BaseServiceImpl;
import org.springblade.core.mp.support.Condition;
import org.springblade.core.mp.support.Query;
import org.springblade.core.redis.cache.BladeRedis;
import org.springblade.core.secure.BladeUser;
import org.springblade.core.secure.utils.AuthUtil;
import org.springblade.core.tool.api.R;
@ -144,6 +146,9 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
private final IWarehouseUpdownTypeClient warehouseUpdownTypeClient;
private final IBasicPrintTemplateClient basicPrintTemplateClient;
private final IWarehouseTrayTypeClient warehouseTrayTypeClient;
private final IDistributionLoadscanAbnormalService distributionLoadscanAbnormalService;
// private final BladeRedis redis;
@Override
public IPage<DistributionDeliveryListEntity> selectDistributionDeliveryListPage(IPage<DistributionDeliveryListEntity> page, DistributionDeliveryListDTO distributionDeliveryList) {
@ -431,7 +436,6 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
.eq(DistributionLoadscanEntity::getDeliveryId, distrilbutionloadingscanDTO.getDeliveryId())
.eq(DistributionLoadscanEntity::getOrderPackageCode, distrilbutionloadingscanDTO.getBarcode())
.ne(DistributionLoadscanEntity::getScanStatus, LoadingStatusConstant.quxiao.getValue()));
if (Func.isNotEmpty(distributionLoadscanEntitiesflag) && distributionLoadscanEntitiesflag.size() == 1) {
return Resp.scanSuccess("重复扫码", "重复扫码");
}
@ -460,15 +464,20 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
loadscanEntity.setPackageId(parcelListEntity.getId());
loadscanEntity.setOrderPackageCode(parcelListEntity.getOrderPackageCode());
loadscanEntity.setPackageNub(parcelListEntity.getQuantity());
loadscanEntity.setReservationId(distrilbutionloadingscanDTO.getReservationId());
DistributionReservationEntity reservationEntity = distributionDeliveryListMapper.selectReservationByPackageAndDeliveryId(parcelListEntity.getOrderPackageCode(), distrilbutionloadingscanDTO.getDeliveryId());
loadscanEntity.setReservationId(reservationEntity.getId());
loadscanEntity.setDeliveryId(distrilbutionloadingscanDTO.getDeliveryId());
loadscanEntity.setOrderId(parcelListEntity.getStockArticleId());
loadscanEntity.setScanTime(new Date());
BladeUser user = AuthUtil.getUser();
loadscanEntity.setScanUser(user.getUserName());
loadscanEntity.setLoadingId(distrilbutionloadingscanDTO.getLoadingId());
loadscanEntity.setIsAbnormalLoading("1");
//出库
warehouseUpdownTypeClient.downPackage(distrilbutionloadingscanDTO.getBarcode());
distributionLoadscanService.save(loadscanEntity);
//查询本车次是否第一次扫码,没有则更新上车时间
Integer i = distributionDeliveryListMapper.updateloadingTimeById(distrilbutionloadingscanDTO.getDeliveryId());
@ -476,6 +485,8 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
Integer j = distributionSignforMapper.updateloadByReservationId(loadscanEntity.getDeliveryId(), loadscanEntity.getReservationId(), loadscanEntity.getPackageNub());
//这里还需要一个维护状态的方法
//异步维护状态
distributionAsyncService.checkLoadingByPackage(parcelListEntity, distrilbutionloadingscanDTO.getDeliveryId());
} else if (parcelListEntityList.size() == 0) {
//查找出该包件信息
@ -521,8 +532,15 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
if (voGoodsLsit.size() == trayGoodIds.size()) {
List<DistributionParcelListEntity> parcelListEntities = distributionParcelListService.listByIds(trayGoodIds);
boolean trayLoadingStatus = parcelListEntities.stream().allMatch(p -> p.getOrderPackageLoadingStatus().equals(OrderPackageLoadingStatusConstant.yizhuangche.getValue()));
if (trayLoadingStatus){
return Resp.scanFail("托盘装车完毕","托盘装车完毕");
// if (trayLoadingStatus){
// return Resp.scanFail("托盘装车完毕","托盘货物已装车完毕");
// }
List<DistributionLoadscanEntity> loadscanEntityList = distributionLoadscanService.list(Wrappers.<DistributionLoadscanEntity>query().lambda()
.eq(DistributionLoadscanEntity::getDeliveryId, distrilbutionloadingscanDTO.getDeliveryId())
.ne(DistributionLoadscanEntity::getScanStatus, 1)
.eq(DistributionLoadscanEntity::getTrayNo, distrilbutionloadingscanDTO.getBarcode()));
if (Func.isNotEmpty(loadscanEntityList) && loadscanEntityList.size() > 0 && trayLoadingStatus) {
return Resp.scanFail("重复扫描", "重复扫描");
}
if (Func.isEmpty(parcelListEntities) || parcelListEntities.size() <= 0) {
return Resp.scanFail("操作失败", "该托盘上无货物信息");
@ -572,11 +590,11 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
loadscanEntity.setMsg("司机按照预约整托装车");
loadscanEntity.setTrayNo(trayTypeDataVO.getTrayCode());
reservationLoadscanEntities.add(loadscanEntity);
Integer i = distributionDeliveryListMapper.updateloadingTimeById(distrilbutionloadingscanDTO.getDeliveryId());
//更新签收表的装车数量
Integer j = distributionSignforMapper.updateloadByReservationId(loadscanEntity.getDeliveryId(), loadscanEntity.getReservationId(), loadscanEntity.getPackageNub());
}
//TODO 需要一个维护状态的异步方法
}
distributionLoadscanService.saveBatch(reservationLoadscanEntities);
//这里则进行整托装车的数据构建
@ -592,6 +610,8 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
List<DistributionLoadscanEntity> deliveryLoadscanEntities = new ArrayList<>();
for (DistributionParcelListEntity parcelListEntity : parcelListEntities) {
if (parcelListEntity.getOrderPackageLoadingStatus().equals(OrderPackageLoadingStatusConstant.weizhuancghe.getValue())) {
//查询出这个包件属于哪个客户
DistributionReservationEntity reservationEntity = distributionDeliveryListMapper.selectReservationByPackageAndDeliveryId(parcelListEntity.getOrderPackageCode(), distrilbutionloadingscanDTO.getDeliveryId());
parcelListEntity.setOrderPackageLoadingStatus(OrderPackageLoadingStatusConstant.yizhuangche.getValue());
parcelListEntity.setOrderPackageStatus(OrderPackageStatusConstant.yichuku.getValue());
distributionParcelListService.updateById(parcelListEntity);
@ -613,10 +633,14 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
}
loadscanEntity.setOrderId(parcelListEntity.getStockArticleId());
loadscanEntity.setOrderPackageCode(parcelListEntity.getOrderPackageCode());
//查询出这个包件属于哪个客户
loadscanEntity.setReservationId(distrilbutionloadingscanDTO.getReservationId());
loadscanEntity.setDeliveryId(distrilbutionloadingscanDTO.getDeliveryId());
loadscanEntity.setTrainNumber(distributionDeliveryListEntity.getTrainNumber());
loadscanEntity.setPackageNub(parcelListEntity.getQuantity());
loadscanEntity.setPackageId(parcelListEntity.getId());
loadscanEntity.setReservationId(reservationEntity.getId());
loadscanEntity.setScanTime(new Date());
BladeUser user = AuthUtil.getUser();
loadscanEntity.setScanUser(user.getUserName());
@ -633,7 +657,6 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
//更新签收表的装车数量
Integer j = distributionSignforMapper.updateloadByReservationId(loadscanEntity.getDeliveryId(), loadscanEntity.getReservationId(), loadscanEntity.getPackageNub());
}
//TODO 需要一个维护状态的异步方法
}
distributionLoadscanService.saveBatch(deliveryLoadscanEntities);
//这里则进行整托装车的数据构建
@ -641,6 +664,9 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
return Resp.scanFail("整托装车失败", "存在其他客户货物");
}
}
//进行装车状态维护
//TODO 需要一个维护状态的异步方法
distributionAsyncService.checkLoadingByDelivery(distrilbutionloadingscanDTO.getDeliveryId());
} else {
log.error("托盘存放货物类型不单一:{}", trayTypeDataVO);
}
@ -3499,6 +3525,7 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
/**
* 批量打印预约单
*
* @param ids
* @return
*/
@ -3547,9 +3574,156 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
public IPage<DistributionAppReservationVO> getAppDeliveryreservationTraysPage(IPage<DistributionAppReservationVO> page, DistributionAppDeliveryListDTO distributionDeliveryList) {
// ---------------------------------2023-09-25 新增托盘详情---------------------------------------------------------------------------------------
List<DistributionAppReservationVO> customList = distributionDeliveryInfoMapper.selectAppTarysListPage(page, Long.parseLong(distributionDeliveryList.getReservationId()));
customList.forEach(c -> {
TrayTypeDataVO trayTypeDataVO = warehouseTrayTypeClient.selectListByTrayCode(c.getTrayCode());
List<DistributionParcelListEntity> parcelListEntities = distributionParcelListService.listByIds(trayTypeDataVO.getGoodsLsit());
c.setPackageList(DistributionParcelListWrapper.build().listVO(parcelListEntities));
});
return page.setRecords(customList);
}
@Override
public R abnormalLoading(DistrilbutionloadingscanDTO distrilbutionloadingscanDTO) {
DistributionDeliveryListEntity deliveryListEntity = distributionDeliveryListMapper.selectById(distrilbutionloadingscanDTO.getDeliveryId());
if (Func.isEmpty(deliveryListEntity)) {
log.error("配送计划null:{}", deliveryListEntity);
return Resp.scanFail("操作失败", "服务器正忙...");
}
List<DistributionParcelListEntity> parcelListEntities = distributionParcelListService.list(Wrappers.<DistributionParcelListEntity>query().lambda()
.eq(DistributionParcelListEntity::getOrderPackageCode, distrilbutionloadingscanDTO.getBarcode()));
if (Func.isNotEmpty(parcelListEntities) && parcelListEntities.size() == 1){
DistributionParcelListEntity parcelListEntity = parcelListEntities.get(0);
DistributionStockArticleEntity stockArticleEntity = distributionStockArticleService.getById(parcelListEntity.getStockArticleId());
if (Func.isEmpty(stockArticleEntity)){
log.error("###############订单异常:{}",stockArticleEntity);
return Resp.scanFail("操作失败", "服务器正忙...");
}
DistributionDeliverySelfEntity distributionDeliverySelfEntity = new DistributionDeliverySelfDTO();
if (StringUtils.isBlank(distrilbutionloadingscanDTO.getLoadingId())) {
if (deliveryListEntity.getKind().equals("1")) {
distributionDeliverySelfEntity = distributionDeliverySelfMapper.selectOne(new QueryWrapper<DistributionDeliverySelfEntity>().lambda()
.eq(DistributionDeliverySelfEntity::getIsMaster, ServiceConstant.IS_MASTER_YES)
.eq(DistributionDeliverySelfEntity::getDeliveryId, distrilbutionloadingscanDTO.getDeliveryId())
);
} else {
DistributionDeliveryTripartiteEntity distributionDeliveryTripartiteEntity = distributionDeliveryTripartiteMapper.selectOne(new QueryWrapper<DistributionDeliveryTripartiteEntity>().lambda()
.eq(DistributionDeliveryTripartiteEntity::getDeliveryId, distrilbutionloadingscanDTO.getDeliveryId())
);
BeanUtils.copyProperties(distributionDeliveryTripartiteEntity, distributionDeliverySelfEntity);
}
} else {
if (deliveryListEntity.getKind().equals("1")) {
distributionDeliverySelfEntity = distributionDeliverySelfMapper.selectById(distrilbutionloadingscanDTO.getLoadingId());
} else {
DistributionDeliveryTripartiteEntity distributionDeliveryTripartiteEntity = distributionDeliveryTripartiteMapper.selectById(distrilbutionloadingscanDTO.getLoadingId());
BeanUtils.copyProperties(distributionDeliveryTripartiteEntity, distributionDeliverySelfEntity);
}
}
List<DistributionLoadscanAbnormalEntity> loadscanAbnormalEntityList = distributionLoadscanAbnormalService.list(Wrappers.<DistributionLoadscanAbnormalEntity>query().lambda()
.eq(DistributionLoadscanAbnormalEntity::getDeliveryListId, distrilbutionloadingscanDTO.getDeliveryId())
.eq(DistributionLoadscanAbnormalEntity::getPackageCode, distrilbutionloadingscanDTO.getBarcode())
.ne(DistributionLoadscanAbnormalEntity::getAuditingStatus, "1"));
if (Func.isNotEmpty(loadscanAbnormalEntityList) && loadscanAbnormalEntityList.size() == 1){
return Resp.scanFail("操作失败", "重复添加");
}
DistributionLoadscanAbnormalEntity distributionLoadscanAbnormalEntity = new DistributionLoadscanAbnormalEntity();
BladeUser user = AuthUtil.getUser();
DistributionLoadscanEntity loadscanEntity = new DistributionLoadscanEntity();
DistributionReservationEntity reservationEntity = null;
switch (deliveryListEntity.getType()) {
case "1":
//商配 需要满足订单的收货单位和当前配送计划中的预约客户名称一样
List<DistributionReservationEntity> shangpeiReservationEntityList = distributionDeliveryListMapper.selectReservationByDeliveryListId(distrilbutionloadingscanDTO.getDeliveryId());
Map<String, DistributionReservationEntity> reservationEntityMap = shangpeiReservationEntityList.stream().filter(r -> Func.isNotEmpty(r.getConsignee())).collect(Collectors.toMap(DistributionReservationEntity::getReceivingUnit, Function.identity(), (k1, k2) -> k2));
if (Func.isEmpty(reservationEntityMap.get(stockArticleEntity.getConsigneeUnit()))){
return Resp.scanFail("操作失败", "配送任务无该客户");
}
reservationEntity = reservationEntityMap.get(stockArticleEntity.getConsigneeUnit());
//查询是否已经异常装车了
//构建异常装车数据
//完成对该客户的异常装车数据和数量维护
break;
case "2":
List<DistributionReservationEntity> shipeiReservationEntityList = distributionDeliveryListMapper.selectReservationByDeliveryListId(distrilbutionloadingscanDTO.getDeliveryId());
Map<String, DistributionReservationEntity> shipeiReservationEntityMap = shipeiReservationEntityList.stream().collect(Collectors.toMap(DistributionReservationEntity::getConsignee, Function.identity(), (k1, k2) -> k2));
DistributionReservationEntity distributionReservationEntity = shipeiReservationEntityMap.get(stockArticleEntity.getCustomerName());
if (Func.isEmpty(distributionReservationEntity)){
return Resp.scanFail("操作失败","配送任务无该客户");
}
if (!distributionReservationEntity.getDeliveryAddress().equals(stockArticleEntity.getCustomerAddress())
|| !stockArticleEntity.getCustomerTelephone().equals(distributionReservationEntity.getDeliveryPhone())
|| !distributionReservationEntity.getMallName().equals(stockArticleEntity.getMallName())){
return Resp.scanFail("操作失败","配送任务无该客户");
}
reservationEntity = distributionReservationEntity;
//市配
break;
}
distributionLoadscanAbnormalEntity.setAuditingStatus(LoadingAbnormalAuditingStatusConstant.daishenhe.getValue());
distributionLoadscanAbnormalEntity.setTrainNumber(deliveryListEntity.getTrainNumber());
distributionLoadscanAbnormalEntity.setDriverName(distributionDeliverySelfEntity.getDriverName());
distributionLoadscanAbnormalEntity.setDriverId(Long.parseLong(distributionDeliverySelfEntity.getDriverId()));
distributionLoadscanAbnormalEntity.setDriverPhone(distributionDeliverySelfEntity.getDriverPhone());
distributionLoadscanAbnormalEntity.setDeliveryListId(deliveryListEntity.getId());
distributionLoadscanAbnormalEntity.setReservationId(reservationEntity.getId());
distributionLoadscanAbnormalEntity.setDeliveryType(deliveryListEntity.getType());
distributionLoadscanAbnormalEntity.setScanUser(user.getUserName());
distributionLoadscanAbnormalEntity.setScanTime(new Date());
distributionLoadscanAbnormalEntity.setLoadingQuantity(parcelListEntity.getQuantity());
distributionLoadscanAbnormalEntity.setPackageCode(parcelListEntity.getOrderPackageCode());
distributionLoadscanAbnormalEntity.setPackageId(parcelListEntity.getId());
distributionLoadscanAbnormalService.save(distributionLoadscanAbnormalEntity);
//修改包件状态 维护订单状态
parcelListEntity.setOrderPackageLoadingStatus(OrderPackageLoadingStatusConstant.yizhuangche.getValue());
parcelListEntity.setOrderPackageStatus(OrderPackageStatusConstant.yichuku.getValue());
distributionParcelListService.updateById(parcelListEntity);
//添加包件数据至扫描表中
if (Func.isNotEmpty(distributionDeliverySelfEntity.getDeliveryId())) {
loadscanEntity.setDriverId(distributionDeliverySelfEntity.getDriverId());
}
if (Func.isNotEmpty(distributionDeliverySelfEntity.getDriverName())) {
loadscanEntity.setDriverName(distributionDeliverySelfEntity.getDriverName());
}
if (Func.isNotEmpty(distributionDeliverySelfEntity.getVehicleNub())) {
loadscanEntity.setVehicleName(distributionDeliverySelfEntity.getVehicleNub());
}
if (Func.isNotEmpty(distributionDeliverySelfEntity.getVehicleId())) {
loadscanEntity.setVehicleId(distributionDeliverySelfEntity.getVehicleId());
}
if (Func.isNotEmpty(distributionDeliverySelfEntity.getDriverPhone())) {
loadscanEntity.setDriverPhone(distributionDeliverySelfEntity.getDriverPhone());
}
loadscanEntity.setTrainNumber(deliveryListEntity.getTrainNumber());
loadscanEntity.setScanStatus(LoadingStatusConstant.saomiao.getValue());
loadscanEntity.setScanType("1");
loadscanEntity.setOneClick(1);
loadscanEntity.setPackageId(parcelListEntity.getId());
loadscanEntity.setOrderPackageCode(parcelListEntity.getOrderPackageCode());
loadscanEntity.setPackageNub(parcelListEntity.getQuantity());
// DistributionReservationEntity reservationEntity = distributionDeliveryListMapper.selectReservationByPackageAndDeliveryId(parcelListEntity.getOrderPackageCode(), distrilbutionloadingscanDTO.getDeliveryId());
loadscanEntity.setReservationId(reservationEntity.getId());
loadscanEntity.setDeliveryId(distrilbutionloadingscanDTO.getDeliveryId());
loadscanEntity.setOrderId(parcelListEntity.getStockArticleId());
loadscanEntity.setScanTime(new Date());
loadscanEntity.setScanUser(user.getUserName());
loadscanEntity.setLoadingId(distrilbutionloadingscanDTO.getLoadingId());
loadscanEntity.setIsAbnormalLoading("1");
//出库
warehouseUpdownTypeClient.downPackage(distrilbutionloadingscanDTO.getBarcode());
//查询本车次是否第一次扫码,没有则更新上车时间
Integer i = distributionDeliveryListMapper.updateloadingTimeById(distrilbutionloadingscanDTO.getDeliveryId());
//更新签收表的装车数量
Integer j = distributionSignforMapper.updateloadByReservationId(loadscanEntity.getDeliveryId(), loadscanEntity.getReservationId(), loadscanEntity.getPackageNub());
//异步维护此异常装车包件的订单状态
distributionAsyncService.checkOrderLoadingStatus(parcelListEntity);
}else {
log.error("#################出现相同的包件信息:{}",parcelListEntities);
return Resp.scanFail("操作失败", "服务器正忙...");
}
return Resp.scanSuccess("操作成功","操作成功");
}
public Map<String, String> getDriverCar(String kind, Long deliveryListEntityId) {
Map<String, String> map = new HashMap<>();
String dirverName = null;
@ -3797,6 +3971,7 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
/**
* 构建预约数据
*
* @param map
* @param distributionReservationEntity
*/

7
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionReservationServiceImpl.java

@ -816,7 +816,8 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
//设置车次号
// String today = DateUtil.today();
// String random = Func.random(7, RandomType.ALL);
distributionDeliveryListEntity.setTrainNumber(trainNumberMa());
String numberMa = trainNumberMa();
distributionDeliveryListEntity.setTrainNumber(numberMa);
distributionDeliveryListEntity.setFee(BigDecimal.ZERO);
distributionDeliveryListEntity.setPrice(BigDecimal.ZERO);
distributionDeliveryListService.save(distributionDeliveryListEntity);
@ -887,7 +888,8 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
reservationEntity.setStockupStatus(ReservationStockupStatusConstant.daibeihuo.getValue());
}
DistributionSignforEntity distributionSignforEntity = new DistributionSignforEntity();
distributionSignforEntity.setTrainNumber(trainNumberMa());
// String trainNumberMa = trainNumberMa();
distributionSignforEntity.setTrainNumber(numberMa);
distributionSignforEntity.setReservationId(reservationEntity.getId());
distributionSignforEntity.setDeliveryId(distributionDeliveryListEntity.getId());
distributionSignforEntity.setSigningStatus(SignforStatusConstant.daiqianshou.getValue());
@ -1605,6 +1607,7 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
reservationEntity.setStockupStatus(ReservationStockupStatusConstant.daibeihuo.getValue());
reservationEntity.setPeriodOfTime(ServiceConstant.RESERVATION_PERIOED_TIME_DAY);
reservationEntity.setStockArticleId(String.join(",", orderNumber));
reservationEntity.setReceivingUnit(k);
reservationEntity.setServiceNumber(String.join(",", serviceNumber));
reservationEntity.setWarehouseName(String.join(",", warehouseName));
reservationEntity.setWaybillNo(String.join(",", waybillNo));

70
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionStockArticleServiceImpl.java

@ -32,6 +32,7 @@ import com.logpm.basicdata.entity.BasicdataWarehouseEntity;
import com.logpm.basicdata.feign.IBasicdataWarehouseClient;
import com.logpm.distribution.dto.DistributionStockArticleDTO;
import com.logpm.distribution.dto.DistributionStockArticleOweDTO;
import com.logpm.distribution.dto.app.queryOrderDTO;
import com.logpm.distribution.entity.*;
import com.logpm.distribution.excel.DistributionStockArticleExcel;
import com.logpm.distribution.mapper.DistributionAddvalueMapper;
@ -43,6 +44,7 @@ import com.logpm.distribution.vo.DistributionParcelListVO;
import com.logpm.distribution.vo.DistributionStockArticleQRCodeVO;
import com.logpm.distribution.vo.DistributionStockArticleVO;
import com.logpm.distribution.vo.OrderPackgeCodeDataVO;
import com.logpm.distribution.vo.app.queryOrderVO;
import com.logpm.distribution.wrapper.DistributionParcelListWrapper;
import com.logpm.distribution.wrapper.DistributionStockArticleWrapper;
import lombok.AllArgsConstructor;
@ -779,6 +781,74 @@ public class DistributionStockArticleServiceImpl extends BaseServiceImpl<Distrib
return R.data(distributionStockArticleVOIPage);
}
@Override
public queryOrderVO queryOrder(queryOrderDTO queryrderDTO) {
queryOrderVO queryOrderVO =new queryOrderVO();
//查询类型
switch (queryrderDTO.getType()){
case 1:
//查询包条
queryOrderVO = this.queryOrderVOCont(queryrderDTO.getCondition(),1);
break;
case 2:
//查询订单
queryOrderVO = this.queryOrderVOCont(queryrderDTO.getCondition(),2);
break;
};
return queryOrderVO;
}
@Override
public queryOrderVO queryOrderVOCont(String condition,Integer i) {
//获取当前登录人仓库
List<BasicdataWarehouseEntity> myWarehouseList = warehouseClient.getMyWatchWarehouse();
List<Long> collect = myWarehouseList.stream()
.map(BasicdataWarehouseEntity::getId)
.collect(Collectors.toList());
//查询包条所在订单
queryOrderVO queryOrderVO;
if (i ==1){
queryOrderVO = distributionStockArticleMapper.selectOneByWrap(condition,collect);
}else {
//根据订单自编码查询该订单
queryOrderVO = distributionStockArticleMapper.selectOneByOrder(condition,collect);
}
if (null == queryOrderVO){
return new queryOrderVO();
}
Long id = queryOrderVO.getId();
//查询订单下的所有包条
List<DistributionParcelListEntity> distributionParcelListEntitys = distributionParcelListMapper.selectListByOderId(id,collect);
queryOrderVO.setWrapNum(distributionParcelListEntitys.size());
queryOrderVO.setInventoryNum(0);
queryOrderVO.setList(distributionParcelListEntitys);
return queryOrderVO;
}
@Override
public List<String> queryFuzzy(queryOrderDTO queryrderDTO) {
ArrayList<String> arrayList = new ArrayList<>();
//获取当前登录人仓库
List<BasicdataWarehouseEntity> myWarehouseList = warehouseClient.getMyWatchWarehouse();
List<Long> collect = myWarehouseList.stream()
.map(BasicdataWarehouseEntity::getId)
.collect(Collectors.toList());
//查询类型
switch (queryrderDTO.getType()){
case 1:
//查询包条
arrayList =distributionParcelListMapper.selectorderPackageCodeByLike(queryrderDTO.getCondition(),collect);
break;
case 2:
//查询订单
arrayList =distributionParcelListMapper.selectorderCodeByLike(queryrderDTO.getCondition(),collect);
break;
};
return arrayList;
}
@Override
public DistributionStockArticleEntity findStockArticleByOrderCodeAndWarehouseId(String orderCode, Long warehouseId) {
QueryWrapper<DistributionStockArticleEntity> queryWrapper = new QueryWrapper<>();

26
blade-service/logpm-distribution/src/main/resources/application-prod.yml

@ -55,29 +55,3 @@ spring:
acknowledge-mode: manual
template:
mandatory: true
#rabbitmq配置
rabbitmq:
host: 172.16.128.145
port: 5672
username: admin
password: Slwk@123654
#虚拟host 可以不设置,使用server默认host
virtual-host: /
#确认消息已发送到队列(Queue)
publisher-returns: true
publisher-confirm-type: correlated
# 手动提交消息
listener:
simple:
acknowledge-mode: auto
default-requeue-rejected: false
retry:
enabled: true # 开启消费者失败重试
initial-interval: 1000 # 初识的失败等待时长为1秒
multiplier: 1 # 失败的等待时长倍数,下次等待时长 = multiplier * last-interval
max-attempts: 3 # 最大重试次数
stateless: true # true无状态;false有状态。如果业务中包含事务,这里改为false
direct:
acknowledge-mode: manual
template:
mandatory: true

2
blade-service/logpm-factory/src/main/java/com/logpm/factory/oupai/receiver/OpReceivingDataHandler.java

@ -41,7 +41,7 @@ public class OpReceivingDataHandler {
panFactoryDataService.handleDataToPlatform(orderPackageCode, receivingTime);
} catch (Exception e) {
log.error("##################opReceivingDataHandler: 处理欧派收货数据到新系统,orderPackageCode:{},receivingTime{}",
log.error("##################opReceivingDataHandler: 处理欧派收货数据到新系统,orderPackageCode:{},receivingTime:{}",
orderPackageCode,receivingTime);
}

28
blade-service/logpm-factory/src/test/java/com/logpm/factory/TestService.java

@ -45,15 +45,20 @@ import org.junit.jupiter.api.extension.ExtendWith;
import org.springblade.common.utils.CommonUtil;
import org.springblade.common.utils.FileLogsUtil;
import org.springblade.core.oss.model.BladeFile;
import org.springblade.core.redis.cache.BladeRedis;
import org.springblade.core.test.BladeBootTest;
import org.springblade.core.test.BladeSpringExtension;
import org.springblade.core.tool.api.R;
import org.springblade.core.tool.api.ResultCode;
import org.springblade.core.tool.utils.SpringUtil;
import org.springblade.core.tool.utils.StringUtil;
import org.springblade.resource.feign.IOssClient;
import org.springframework.amqp.core.Message;
import org.springframework.amqp.rabbit.annotation.RabbitHandler;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.redis.connection.RedisConnection;
import org.springframework.data.redis.connection.RedisConnectionFactory;
import org.springframework.data.redis.connection.lettuce.LettuceConnectionFactory;
import org.springframework.http.MediaType;
import org.springframework.web.multipart.MultipartFile;
import org.springframework.web.multipart.commons.CommonsMultipartFile;
@ -272,5 +277,28 @@ public class TestService {
}
@Test
public void test6(){
BladeRedis bean = SpringUtil.getBean(BladeRedis.class);
RedisConnectionFactory connectionFactory = bean.getRedisTemplate().getConnectionFactory();
LettuceConnectionFactory factory = (LettuceConnectionFactory) connectionFactory;
String hostName = factory.getHostName();
int port = factory.getPort();
String password = factory.getPassword();
System.out.println(hostName);
System.out.println(port);
System.out.println(password);
assert false;
}
}

1
blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseUpdownGoodsLogMapper.xml

@ -92,7 +92,6 @@
<if test="param.bindingType!=null and param.bindingType!=''">
and lwup.binding_type = #{param.bindingType}
</if>
</where>
</select>

3
blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseWarehousingEntryServiceImpl.java

@ -47,6 +47,7 @@ import com.logpm.warehouse.service.IWarehouseWarehousingDetailService;
import com.logpm.warehouse.service.IWarehouseWarehousingEntryService;
import com.logpm.warehouse.vo.WarehouseWarehousingEntryVO;
import lombok.AllArgsConstructor;
import lombok.extern.log4j.Log4j2;
import org.springblade.core.log.exception.ServiceException;
import org.springblade.core.mp.base.BaseServiceImpl;
import org.springblade.core.mp.support.Condition;
@ -71,6 +72,7 @@ import java.util.stream.Collectors;
*/
@AllArgsConstructor
@Service
@Log4j2
public class WarehouseWarehousingEntryServiceImpl extends BaseServiceImpl<WarehouseWarehousingEntryMapper, WarehouseWarehousingEntryEntity> implements IWarehouseWarehousingEntryService {
private final IWarehouseWarehousingDetailService warehouseWarehousingDetailService;
private final IDistributionStockListClient distributionStockListClient;
@ -361,6 +363,7 @@ public class WarehouseWarehousingEntryServiceImpl extends BaseServiceImpl<Wareho
@Override
public WarehouseWarehousingEntryVO getOneOwn(WarehouseWarehousingEntryEntity warehouseWarehousingEntry) {
WarehouseWarehousingEntryEntity one = this.getOne(Condition.getQueryWrapper(warehouseWarehousingEntry));
log.info("one>>>>>>>>>>>>{}",one);
if(ObjectUtils.isNotNull(one) && ObjectUtils.isNotNull(one.getId())){
List<WarehouseWarehousingDetailEntity> list = warehouseWarehousingDetailService.list(Wrappers.<WarehouseWarehousingDetailEntity>query().lambda()
.eq(WarehouseWarehousingDetailEntity::getWarehousingEntryId, one.getId())

Loading…
Cancel
Save