diff --git a/blade-biz-common/src/main/java/org/springblade/common/cache/CacheObjNames.java b/blade-biz-common/src/main/java/org/springblade/common/cache/CacheObjNames.java new file mode 100644 index 000000000..960924ddd --- /dev/null +++ b/blade-biz-common/src/main/java/org/springblade/common/cache/CacheObjNames.java @@ -0,0 +1,33 @@ +package org.springblade.common.cache; + +import lombok.AllArgsConstructor; +import lombok.Data; +import lombok.Getter; + +/** + * 系统查询缓存名称定义 + */ +@AllArgsConstructor +@Getter +public enum CacheObjNames { + + /** + * 基础数据模块 当前登陆人操作仓库的缓存 + */ + basic_data_warehourse_list("getMyWarehouseList","basicdataWarehouseList"); + + + /** + * 缓存名称 + */ + final String cacheName; + + + /** + * 缓存前缀 + */ + final String keyPrefix; + + + +} diff --git a/blade-biz-common/src/main/java/org/springblade/common/constant/DictBizConstant.java b/blade-biz-common/src/main/java/org/springblade/common/constant/DictBizConstant.java index 5c8e470de..8617c95df 100644 --- a/blade-biz-common/src/main/java/org/springblade/common/constant/DictBizConstant.java +++ b/blade-biz-common/src/main/java/org/springblade/common/constant/DictBizConstant.java @@ -15,6 +15,7 @@ public class DictBizConstant { public static final String BASIC_GROUNDING = "basic_grounding";//上架状态 public static final String STOCKUP_STATUS = "stockup_status";//备货状态 + public static final String ORDER_STOCKUP_STATUS = "order_stockup_status";//订单备货状态 public static final String ORDER_RESERVATION_STATUS = "order_reservation_status";//订单预约状态 public static final String RESERVATION_STATUS = "reservation_status";//预约状态 @@ -103,4 +104,6 @@ public class DictBizConstant { public static final String ORDER_PACKAGE_LOADING_STATUS = "order_package_loading_status";//预约签收状态 // --------------2023-10-12 --------------------- public static final String WAREHOUSE_QUEST_STATUS = "warehouse_quest_status"; //盘点任务 + // --------------2023-11-04 --------------------- + public static final String WAREHOUSE_RETENTION_TYPE = "warehouse_retention_type"; //滞留类型 } diff --git a/blade-biz-common/src/main/java/org/springblade/common/constant/retention/RetentionTypeConstant.java b/blade-biz-common/src/main/java/org/springblade/common/constant/retention/RetentionTypeConstant.java new file mode 100644 index 000000000..eca334cad --- /dev/null +++ b/blade-biz-common/src/main/java/org/springblade/common/constant/retention/RetentionTypeConstant.java @@ -0,0 +1,47 @@ +package org.springblade.common.constant.retention; + +/** + * 订单冻结状态枚举 + * 对应码表 freeze_status + * @author pref + */ +public enum RetentionTypeConstant { + + zhuangchezhiliu("装车滞留",1), + peisongzhiliu("配送滞留",2), + chukuzhiliu("出库滞留",3), + quxiaozhiliu("取消滞留",4); + + + /** + * 状态 + */ + private String name; + + /** + * 值 + */ + private Integer value; + + + private RetentionTypeConstant(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; + } +} diff --git a/blade-service-api/logpm-basic-api/src/main/java/com/logpm/basic/entity/BasicDelineNodeEntity.java b/blade-service-api/logpm-basic-api/src/main/java/com/logpm/basic/entity/BasicDelineNodeEntity.java index 918451d43..c19eb66fb 100644 --- a/blade-service-api/logpm-basic-api/src/main/java/com/logpm/basic/entity/BasicDelineNodeEntity.java +++ b/blade-service-api/logpm-basic-api/src/main/java/com/logpm/basic/entity/BasicDelineNodeEntity.java @@ -35,6 +35,42 @@ import org.springblade.core.tenant.mp.TenantEntity; @EqualsAndHashCode(callSuper = true) public class BasicDelineNodeEntity extends TenantEntity { + /** + * 预留1 + */ + @ApiModelProperty(value = "预留1") + private String reserve1; + /** + * 预留2 + */ + @ApiModelProperty(value = "预留2") + private String reserve2; + /** + * 预留3 + */ + @ApiModelProperty(value = "预留3") + private String reserve3; + /** + * 预留4 + */ + @ApiModelProperty(value = "预留4") + private String reserve4; + /** + * 预留5 + */ + @ApiModelProperty(value = "预留5") + private String reserve5; + + /** + * 仓库id + */ + @ApiModelProperty(value = "仓库id") + private Long warehouseId; + /** + * 仓库名称 + */ + @ApiModelProperty(value = "仓库名称") + private String warehouseName; /** * 关联提货路线Id */ @@ -71,19 +107,9 @@ public class BasicDelineNodeEntity extends TenantEntity { @ApiModelProperty(value = "纬度") private String latitude; /** - * 预留3 - */ - @ApiModelProperty(value = "预留3") - private String reserve3; - /** - * 预留4 + * 备注 */ - @ApiModelProperty(value = "预留4") - private String reserve4; - /** - * 预留5 - */ - @ApiModelProperty(value = "预留5") - private String reserve5; + @ApiModelProperty(value = "备注") + private String remark; } diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionParcelListEntity.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionParcelListEntity.java index 50e716e84..a1c46e492 100644 --- a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionParcelListEntity.java +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionParcelListEntity.java @@ -141,6 +141,61 @@ public class DistributionParcelListEntity extends TenantEntity { @ApiModelProperty(value = "客户id") @TableField(exist = false) private Long marketId; + + /** + * 商场名称 + */ + @ApiModelProperty(value = "商场名称") + @TableField(exist = false) + private String mallName; + /** + * 商场名称 + */ + @ApiModelProperty(value = "分类") + @TableField(exist = false) + private String genre; + /** + * 商场名称 + */ + @ApiModelProperty(value = "零担标识") + @TableField(exist = false) + private String isZero; + /** + * 商场名称 + */ + @ApiModelProperty(value = "商场iD") + @TableField(exist = false) + private Long mallId; + /** + * 托盘ID + */ + @ApiModelProperty(value = "托盘ID") + @TableField(exist = false) + private String trayId; + /** + * 托盘编码 + */ + @ApiModelProperty(value = "托盘编码") + @TableField(exist = false) + private String trayCode; + /** + * 货位ID + */ + @ApiModelProperty(value = "货位ID") + @TableField(exist = false) + private String allocationId; + /** + * 完整货位 + */ + @ApiModelProperty(value = "完整货位") + @TableField(exist = false) + private String positionCode; + /** + * 库存品ID + */ + @ApiModelProperty(value = "库存品ID") + @TableField(exist = false) + private Long stockId; /** * 物料Id */ diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionRetentionScanEntity.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionRetentionScanEntity.java new file mode 100644 index 000000000..f5b0202b8 --- /dev/null +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionRetentionScanEntity.java @@ -0,0 +1,181 @@ +/* + * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * Neither the name of the dreamlu.net developer nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * Author: Chill 庄骞 (smallchill@163.com) + */ +package com.logpm.distribution.entity; + +import com.baomidou.mybatisplus.annotation.TableName; +import lombok.Data; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.util.Date; +import com.baomidou.mybatisplus.annotation.IdType; +import com.baomidou.mybatisplus.annotation.TableId; +import com.fasterxml.jackson.databind.annotation.JsonSerialize; +import com.fasterxml.jackson.databind.ser.std.ToStringSerializer; +import java.io.Serializable; + +/** + * 滞留扫描操作表 实体类 + * + * @author BladeX + * @since 2023-11-03 + */ +@Data +@TableName("logpm_distribution_retention_scan") +@ApiModel(value = "DistributionRetentionScan对象", description = "滞留扫描操作表") +public class DistributionRetentionScanEntity implements Serializable { + + private static final long serialVersionUID = 1L; + /** + * 主键 + */ + @JsonSerialize(using = ToStringSerializer.class) + @ApiModelProperty(value = "主键") + @TableId(value = "id", type = IdType.ASSIGN_ID) + private Long id; + + /** + * 租户号 + */ + @ApiModelProperty(value = "租户号") + private String tenantId; + /** + * 是否已删除 + */ + @ApiModelProperty(value = "是否已删除") + private Integer isDeleted; + /** + * 预留1 + */ + @ApiModelProperty(value = "预留1") + private String reserve1; + /** + * 预留2 + */ + @ApiModelProperty(value = "预留2") + private String reserve2; + /** + * 预留3 + */ + @ApiModelProperty(value = "预留3") + private String reserve3; + /** + * 预留4 + */ + @ApiModelProperty(value = "预留4") + private String reserve4; + /** + * 预留5 + */ + @ApiModelProperty(value = "预留5") + private String reserve5; + /** + * 配送车次号 + */ + @ApiModelProperty(value = "配送车次号") + private String trainNumber; + /** + * 订单ID + */ + @ApiModelProperty(value = "订单ID") + private Long orderId; + /** + * 库存品ID + */ + @ApiModelProperty(value = "库存品ID") + private Long inventoryId; + /** + * 滞留类型 1-包件、2-零担(这里会关联到具体的品类)、3-库存品 + */ + @ApiModelProperty(value = "滞留类型 1-包件、2-零担(这里会关联到具体的品类)、3-库存品") + private Integer conditions; + /** + * 物料编码(库存品) + */ + @ApiModelProperty(value = "物料编码(库存品)") + private String materialNumber; + /** + * 物料名称(库存品) + */ + @ApiModelProperty(value = "物料名称(库存品)") + private String materialName; + /** + * 预约客户ID + */ + @ApiModelProperty(value = "预约客户ID") + private Long reservationId; + /** + * 订单自编号(库存品没有) + */ + @ApiModelProperty(value = "订单自编号(库存品没有)") + private String orderCode; + /** + * 预约单号 + */ + @ApiModelProperty(value = "预约单号") + private String reservationCode; + /** + * 扫描类型:1-包件、2-订单、3-托盘、4... + */ + @ApiModelProperty(value = "扫描类型:1-包件、2-订单、3-托盘、4...") + private Integer scanType; + /** + * 包件ID + */ + @ApiModelProperty(value = "包件ID") + private Long orderPackageId; + /** + * 包条码 + */ + @ApiModelProperty(value = "包条码") + private String orderPackageCode; + /** + * 滞留数量 + */ + @ApiModelProperty(value = "滞留数量") + private Integer retentionQuantity; + /** + * 滞留扫描操作人名称 + */ + @ApiModelProperty(value = "滞留扫描操作人名称") + private String retentionScanUsername; + /** + * 滞留扫描操作人Id + */ + @ApiModelProperty(value = "滞留扫描操作人Id") + private String retentionScanUserId; + /** + * 滞留操作备注 + */ + @ApiModelProperty(value = "滞留操作备注") + private String remarks; + /** + * 滞留扫描时间 + */ + @ApiModelProperty(value = "滞留扫描时间") + private Date retentionScanTime; + /** + * 滞留方式 1-PDA、2-PC + */ + @ApiModelProperty(value = "滞留方式 1-PDA、2-PC") + private Integer retentionWay; + /** + * 配送任务ID + */ + @ApiModelProperty(value = "配送任务ID") + private Long deliveryListId; + +} diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionStockListEntity.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionStockListEntity.java index 2ff7f4ef8..a64c8eef3 100644 --- a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionStockListEntity.java +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionStockListEntity.java @@ -275,11 +275,11 @@ public class DistributionStockListEntity extends TenantEntity { */ @ApiModelProperty(value = "拆包ID") private Long pid; - /** - * 托盘ID - */ - @ApiModelProperty(value = "托盘ID") - private Long trayId; +// /** +// * 托盘ID +// */ +// @ApiModelProperty(value = "托盘ID") +// private Long trayId; /** * 托盘名称 */ diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionStockupEntity.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionStockupEntity.java index 1a5e61d73..c21ea65c6 100644 --- a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionStockupEntity.java +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionStockupEntity.java @@ -78,6 +78,13 @@ public class DistributionStockupEntity extends TenantEntity { */ @ApiModelProperty(value = "备货库位") private String stockipAllocation; + + /** + * 托盘位 + */ + @ApiModelProperty(value = "托盘位") + @TableField(exist = false) + private String pallet; /** * 备货区ID */ diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionDeliveryListClient.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionDeliveryListClient.java index 58513da3f..5ec37bca8 100644 --- a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionDeliveryListClient.java +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionDeliveryListClient.java @@ -16,13 +16,18 @@ */ package com.logpm.distribution.feign; +import com.logpm.distribution.entity.DistributionDeliveryDetailsEntity; import com.logpm.distribution.entity.DistributionDeliveryListEntity; +import com.logpm.distribution.vo.DistributionDeliveryListVO; +import com.logpm.distribution.vo.DistributionDeliverySelfVO; import org.springblade.common.constant.ModuleNameConstant; import org.springblade.core.mp.support.BladePage; import org.springframework.cloud.openfeign.FeignClient; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RequestParam; +import java.util.List; + /** * 配送管理 Feign接口类 * @@ -45,6 +50,15 @@ public interface IDistributionDeliveryListClient { * @return BladePage */ @GetMapping(TOP) - BladePage top(@RequestParam("current") Integer current, @RequestParam("size") Integer size); + BladePage deliveryListTop(@RequestParam("current") Integer current, @RequestParam("size") Integer size); + + + /** + * 根据配送任务ID查询配送司机信息 + * @param deliveryId + * @return + */ + @GetMapping(TOP+"/getDeliveryDriverInfo") + DistributionDeliveryListVO getDeliveryDriverInfo(@RequestParam("current") Long deliveryId); } diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionParcelListClient.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionParcelListClient.java index ec567b9fe..6b56d4cd6 100644 --- a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionParcelListClient.java +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionParcelListClient.java @@ -17,6 +17,8 @@ package com.logpm.distribution.feign; import com.logpm.distribution.entity.DistributionParcelListEntity; +import com.logpm.distribution.entity.DistributionStockArticleEntity; +import com.logpm.distribution.vo.DistributionParcelListVO; import org.springblade.common.constant.ModuleNameConstant; import org.springblade.core.mp.support.BladePage; import org.springframework.cloud.openfeign.FeignClient; @@ -41,6 +43,7 @@ public interface IDistributionParcelListClient { String API_PREFIX = "/client"; String TOP = API_PREFIX + "/top1"; String TOPPARCELLIST = API_PREFIX + "/getParcelList"; + String GETPARCELLISTINFO = API_PREFIX + "/getParcelListInfo"; @PostMapping(TOPPARCELLIST) List getParcelList(@RequestBody DistributionParcelListEntity parcelListEntity); @@ -102,4 +105,7 @@ public interface IDistributionParcelListClient { @GetMapping(API_PREFIX+"/updateStockArticleIdByOrderCode") void updateStockArticleIdByOrderCode(@RequestParam Long orderId, @RequestParam String orderCode); + + @PostMapping(GETPARCELLISTINFO) + List getParcelListInfo(@RequestBody DistributionParcelListVO parcelListVO); } diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionStockArticleClient.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionStockArticleClient.java index 0d293de12..ec0864d28 100644 --- a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionStockArticleClient.java +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionStockArticleClient.java @@ -41,6 +41,7 @@ public interface IDistributionStockArticleClient { String API_PREFIX = "/client"; String TOP = API_PREFIX + "/top12"; + String GETSTOCKARTICLEINFO = API_PREFIX + "/getStockArticleInfo"; /** * 获取配送在库订单列表 @@ -104,4 +105,11 @@ public interface IDistributionStockArticleClient { @GetMapping(API_PREFIX + "/submitHandleNumByOrderId") void submitHandleNumByOrderId(@RequestParam Integer subNum, @RequestParam Long articleId); + + /** + * 查询订单信息数据 + * @return + */ + @PostMapping(GETSTOCKARTICLEINFO) + List getStockArticleInfo(@RequestBody DistributionStockArticleEntity distributionStockArticleEntity); } diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionStockListClient.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionStockListClient.java index c261acfd2..07efc59be 100644 --- a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionStockListClient.java +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionStockListClient.java @@ -47,6 +47,7 @@ public interface IDistributionStockListClient { String ADDSTOCKLIST = API_PREFIX + "/addStockList"; String UPDATESTOCKLIST = API_PREFIX + "/updateStockList"; String PUTSTOCKLIST = API_PREFIX + "/putStockList"; + String GETSTOCKLISTINFO = API_PREFIX + "/getStockListInfo"; /** * 获取库存品管理列表 @@ -116,12 +117,12 @@ public interface IDistributionStockListClient { List getStockListByWarehouseIdAndMarketAndStockListInfo(@RequestParam("incomingBatch") String incomingBatch,@RequestParam("marketNames") List marketNames,@RequestParam("warehouseId") Long warehouseId); -// /** -// * 修改某个客户信息及物品信息 -// * -// * @return BladePage -// */ -// @PutMapping(PUTSTOCKLIST) -// Boolean putStockList(@RequestBody DistributionStockListEntity distributionStockListEntity); + /** + * 修改某个客户信息及物品信息 + * + * @return BladePage + */ + @PostMapping(GETSTOCKLISTINFO) + List getStockListInfo(@RequestBody DistributionStockListEntity distributionStockListEntity); } diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionAddvaluePackageVO.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionAddvaluePackageVO.java index a716b2e07..f05b5a9ee 100644 --- a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionAddvaluePackageVO.java +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionAddvaluePackageVO.java @@ -32,6 +32,14 @@ import lombok.EqualsAndHashCode; public class DistributionAddvaluePackageVO extends DistributionAddvaluePackageEntity { private static final long serialVersionUID = 1L; + /** + * 最大操作数量 零担需要先进行装车 + */ private Integer maxQuantity; + /** + * 计划数量 + */ + private Integer planQuantity; + } diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionParcelListVO.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionParcelListVO.java index 1523e5f82..961be6fd0 100644 --- a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionParcelListVO.java +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionParcelListVO.java @@ -100,6 +100,19 @@ public class DistributionParcelListVO extends DistributionParcelListEntity { */ private List warehouseIdList; + /** + * 商场id + */ + private Long mallId; + /** + * 商场id + */ + private String genre; + /** + * 商场id + */ + private String isZero; + /** * 装车数量 */ diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionParcelListZeroVO.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionParcelListZeroVO.java index f379ca68a..dfd0e25a6 100644 --- a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionParcelListZeroVO.java +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionParcelListZeroVO.java @@ -38,11 +38,21 @@ public class DistributionParcelListZeroVO implements Serializable { */ @ApiModelProperty(value = "填写数量") private Integer TiQuantity; + /** + * 冻结数量 + */ + @ApiModelProperty(value = "冻结数量") + private Integer deliveryQuantity; /** * 配送数量 */ @ApiModelProperty(value = "配送数量") - private Integer deliveryQuantity; + private Integer reservationQuantity; + /** + * 配送数量 + */ + @ApiModelProperty(value = "出库数量") + private Integer outboundQuantity; diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionRetentionScanVo.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionRetentionScanVo.java new file mode 100644 index 000000000..1fc248fae --- /dev/null +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionRetentionScanVo.java @@ -0,0 +1,84 @@ +package com.logpm.distribution.vo; + + +import lombok.Data; +import lombok.EqualsAndHashCode; + +/** + * 滞留扫描对象 + */ +@Data +//@EqualsAndHashCode(callSuper = true) +public class DistributionRetentionScanVo { + + /** + * 预约Id + */ + private Long reservationId; + + /** + * 预约Id + */ + private String reservationCode; + + /** + * 订单Id + */ + private Long orderId; + + /** + * 订单自编码 + */ + private String orderCode; + + /** + * 订单Id + */ + private Long inventoryId; + + + + /** + * 物料编码 + */ + private String materialNumber; + + /** + * 物料名称 + */ + private String materialName; + + /** + * 包件ID + */ + private Long orderPackageId; + + /** + * 包条码 + */ + private String orderPackageCode; + + /** + * 滞留数量 + */ + private Integer retentionQuantity; + + /** + * 类型 + */ + private Integer conditions; + + + /** + * 配送ID + */ + private Long deliveryId; + + + /** + * 配送车次 + */ + private String trainNumber; + + +} diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionSignforVO.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionSignforVO.java index bc17283f5..aaedc946d 100644 --- a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionSignforVO.java +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionSignforVO.java @@ -16,6 +16,7 @@ */ package com.logpm.distribution.vo; +import com.logpm.distribution.entity.DistributionSignPrintEntity; import com.logpm.distribution.entity.DistributionSignforEntity; import io.swagger.annotations.ApiModelProperty; import lombok.Data; @@ -150,6 +151,12 @@ public class DistributionSignforVO extends DistributionSignforEntity { @ApiModelProperty(value = "卸车班组") private String sijiSigningStatus; + /** + * 签收图片路径,多个 + */ + @ApiModelProperty(value = "卸车班组") + private List printVOList; + /** * 客户订单列表 */ diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionStockListVO.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionStockListVO.java index 99c8f0977..b7e23522d 100644 --- a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionStockListVO.java +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionStockListVO.java @@ -102,10 +102,30 @@ public class DistributionStockListVO extends DistributionStockListEntity { */ @ApiModelProperty(value = "托盘id") private String trayCode; + /** + * 托盘id + */ + @ApiModelProperty(value = "托盘id") + private String trayId; + /** + * 库位id + */ + @ApiModelProperty(value = "库位id") + private String allocationId; /** * 货位信息 */ @ApiModelProperty(value = "货位信息") private String positionCode; + /** + * 类型 + */ + @ApiModelProperty(value = "类型") + private Integer conditions; + /** + * 类型 + */ + @ApiModelProperty(value = "shan") + private String mallName; } diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionStockupOrderListVO.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionStockupOrderListVO.java index 80558e1aa..0f7f40d7b 100644 --- a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionStockupOrderListVO.java +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionStockupOrderListVO.java @@ -33,6 +33,8 @@ public class DistributionStockupOrderListVO implements Serializable { private Long areaId; //货区id private String trayId; //托盘id + private String customerAddress; //客户地址 + private String firstsNumber; //品类数量 private Long shelfId; //货架id private Long parcelListId; //包件id private Long stockId; //备货id diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionStockupVO.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionStockupVO.java index b7f18520b..718cacf3b 100644 --- a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionStockupVO.java +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionStockupVO.java @@ -72,6 +72,7 @@ public class DistributionStockupVO extends DistributionStockupEntity { private Integer number; private String goodsAllocation; //货位 private String stockipAllocation; //货位 + private String pallet; //托盘位 private Integer reservationStockListNum; //数量 private String reservationId; //预约ID private String stockListId; //库存品ID diff --git a/blade-service-api/logpm-old-project-api/src/main/java/com/logpm/oldproject/feign/IAdvanceClient.java b/blade-service-api/logpm-old-project-api/src/main/java/com/logpm/oldproject/feign/IAdvanceClient.java index b3810e619..f66963354 100644 --- a/blade-service-api/logpm-old-project-api/src/main/java/com/logpm/oldproject/feign/IAdvanceClient.java +++ b/blade-service-api/logpm-old-project-api/src/main/java/com/logpm/oldproject/feign/IAdvanceClient.java @@ -85,6 +85,16 @@ public interface IAdvanceClient { AdvanceEntity fingById(@RequestParam Integer advanceId); + /** + * 根据运单号和订单号查询老系统的开单对应的订单 + * @param logiBillNo + * @param orderCode + * @return + */ + @GetMapping(API_PREFIX + "/findAdvanceEntityByLogiBillNoAndOrderCode") + List findAdvanceEntityByLogiBillNoAndOrderCode(@RequestParam String logiBillNo,@RequestParam String orderCode); + + diff --git a/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/dto/BillladingDTO.java b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/dto/BillladingDTO.java new file mode 100644 index 000000000..affb80396 --- /dev/null +++ b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/dto/BillladingDTO.java @@ -0,0 +1,12 @@ +package com.logpm.trunkline.dto; + +import com.logpm.trunkline.entity.TrunklineBillladingEntity; +import lombok.Data; + +@Data +public class BillladingDTO extends TrunklineBillladingEntity { + + private Integer pageNum; + private Integer pageSize; + +} diff --git a/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/entity/TrunklineAdvanceDetailEntity.java b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/entity/TrunklineAdvanceDetailEntity.java new file mode 100644 index 000000000..5da3f739d --- /dev/null +++ b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/entity/TrunklineAdvanceDetailEntity.java @@ -0,0 +1,92 @@ +package com.logpm.trunkline.entity; + +import com.baomidou.mybatisplus.annotation.TableName; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; +import lombok.EqualsAndHashCode; +import org.springblade.core.tenant.mp.TenantEntity; + +@Data +@TableName("logpm_trunkline_advance_detail") +@ApiModel(value = "TrunklineAdvanceDetail对象", description = "暂存单包件数据表") +@EqualsAndHashCode(callSuper = true) +public class TrunklineAdvanceDetailEntity extends TenantEntity { + + /** 预留1 */ + @ApiModelProperty(name = "预留1",notes = "") + private String reserve1 ; + /** 预留2 */ + @ApiModelProperty(name = "预留2",notes = "") + private String reserve2 ; + /** 预留3 */ + @ApiModelProperty(name = "预留3",notes = "") + private String reserve3 ; + /** 预留4 */ + @ApiModelProperty(name = "预留4",notes = "") + private String reserve4 ; + /** 预留5 */ + @ApiModelProperty(name = "预留5",notes = "") + private String reserve5 ; + /** 仓库id */ + @ApiModelProperty(name = "仓库id",notes = "") + private Long warehouseId ; + /** 仓库名称 */ + @ApiModelProperty(name = "仓库名称",notes = "") + private String warehouseName ; + /** 暂存单id */ + @ApiModelProperty(name = "暂存单id",notes = "") + private Long advanceId ; + /** 订单自编号 */ + @ApiModelProperty(name = "订单自编号",notes = "") + private String orderCode ; + /** 品牌 */ + @ApiModelProperty(name = "品牌",notes = "") + private String brand ; + /** 订单来源 */ + @ApiModelProperty(name = "订单来源",notes = "") + private String systemType ; + /** 一级品类名称 */ + @ApiModelProperty(name = "一级品类名称",notes = "") + private String firstPackName ; + /** 一级品类编码 */ + @ApiModelProperty(name = "一级品类编码",notes = "") + private String firstPackCode ; + /** 二级品类名称 */ + @ApiModelProperty(name = "二级品类名称",notes = "") + private String secondPackName ; + /** 二级品类编码 */ + @ApiModelProperty(name = "二级品类编码",notes = "") + private String secondPackCode ; + /** 三级品类名称 */ + @ApiModelProperty(name = "三级品类名称",notes = "") + private String thirdPackName ; + /** 三级品类编码 */ + @ApiModelProperty(name = "三级品类编码",notes = "") + private String thirdPackCode ; + /** 基地名称 */ + @ApiModelProperty(name = "基地名称",notes = "") + private String siteName ; + /** 基地编码 */ + @ApiModelProperty(name = "基地编码",notes = "") + private String siteCode ; + /** 数量 */ + @ApiModelProperty(name = "数量",notes = "") + private Integer quantity ; + /** 包件码 */ + @ApiModelProperty(name = "包件码",notes = "") + private String orderPackageCode ; + /** 车次号 */ + @ApiModelProperty(name = "车次号",notes = "") + private String trainNumber ; + /** 服务号 */ + @ApiModelProperty(name = "服务号",notes = "") + private String serviceNum ; + /** 运单号 */ + @ApiModelProperty(name = "运单号",notes = "") + private String waybillNo ; + /** 包件状态 */ + @ApiModelProperty(name = "包件状态 0未入库 1已入库",notes = "") + private String packageStatus ; + +} diff --git a/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/entity/TrunklineAdvanceEntity.java b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/entity/TrunklineAdvanceEntity.java new file mode 100644 index 000000000..356ecc949 --- /dev/null +++ b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/entity/TrunklineAdvanceEntity.java @@ -0,0 +1,116 @@ +package com.logpm.trunkline.entity; + +import com.baomidou.mybatisplus.annotation.TableName; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; +import lombok.EqualsAndHashCode; +import org.springblade.core.tenant.mp.TenantEntity; + +@Data +@TableName("logpm_trunkline_advance") +@ApiModel(value = "TrunklineAdvance对象", description = "暂存单数据表") +@EqualsAndHashCode(callSuper = true) +public class TrunklineAdvanceEntity extends TenantEntity { + + /** 预留1 */ + @ApiModelProperty(name = "预留1",notes = "") + private String reserve1 ; + /** 预留2 */ + @ApiModelProperty(name = "预留2",notes = "") + private String reserve2 ; + /** 预留3 */ + @ApiModelProperty(name = "预留3",notes = "") + private String reserve3 ; + /** 预留4 */ + @ApiModelProperty(name = "预留4",notes = "") + private String reserve4 ; + /** 预留5 */ + @ApiModelProperty(name = "预留5",notes = "") + private String reserve5 ; + /** 仓库id */ + @ApiModelProperty(name = "仓库id",notes = "") + private Long warehouseId ; + /** 仓库名称 */ + @ApiModelProperty(name = "仓库名称",notes = "") + private String warehouseName ; + /** 订单自编码 */ + @ApiModelProperty(name = "订单自编码",notes = "") + private String orderCode ; + /** 基地 */ + @ApiModelProperty(name = "基地",notes = "") + private String siteName ; + /** 区域 */ + @ApiModelProperty(name = "区域",notes = "") + private String area ; + /** 订单类型 */ + @ApiModelProperty(name = "订单类型",notes = "") + private String orderType ; + /** 品牌 */ + @ApiModelProperty(name = "品牌",notes = "") + private String brand ; + /** 订单总数 */ + @ApiModelProperty(name = "订单总数",notes = "") + private Integer totalNum ; + /** 品名 */ + @ApiModelProperty(name = "品名",notes = "") + private String packName ; + /** 品名编码 */ + @ApiModelProperty(name = "品名编码",notes = "") + private String packCode ; + /** 商场编码 */ + @ApiModelProperty(name = "商场编码",notes = "") + private String dealerCode ; + /** 商场名称 */ + @ApiModelProperty(name = "商场名称",notes = "") + private String dealerName ; + /** 承运商 */ + @ApiModelProperty(name = "承运商",notes = "") + private String carrierName ; + /** 客户名称 */ + @ApiModelProperty(name = "客户名称",notes = "") + private String customerName ; + /** 客户电话 */ + @ApiModelProperty(name = "客户电话",notes = "") + private String customerPhone ; + /** 客户地址 */ + @ApiModelProperty(name = "客户地址",notes = "") + private String customerAddress ; + /** 订单来源 */ + @ApiModelProperty(name = "订单来源",notes = "") + private String systemType ; + /** 门店编码 */ + @ApiModelProperty(name = "门店编码",notes = "") + private String storeCode ; + /** 门店名称 */ + @ApiModelProperty(name = "门店名称",notes = "") + private String storeName ; + /** 服务号 */ + @ApiModelProperty(name = "服务号",notes = "") + private String serviceNum ; + /** 齐套状态 0未齐套 1齐套 2多仓齐套 */ + @ApiModelProperty(name = "齐套状态 0未齐套 1齐套 2多仓齐套",notes = "") + private String matingType ; + /** 发货人名称 */ + @ApiModelProperty(name = "发货人名称",notes = "") + private String senderName ; + /** 发货人电话 */ + @ApiModelProperty(name = "发货人电话",notes = "") + private String senderPhone ; + /** 发货人地址 */ + @ApiModelProperty(name = "发货人地址",notes = "") + private String senderAddress ; + /** 开单状态 0未开单 1已开单 */ + @ApiModelProperty(name = "开单状态 0未开单 1已开单",notes = "") + private String waybillStatus ; + /** 运单号 */ + @ApiModelProperty(name = "运单号",notes = "") + private String waybillNo ; + /** 车次号 */ + @ApiModelProperty(name = "车次号",notes = "") + private String trainNumber ; + /** 冻结状态 0未冻结 1已冻结 */ + @ApiModelProperty(name = "冻结状态 0未冻结 1已冻结",notes = "") + private String freezeStatus ; + +} diff --git a/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/entity/TrunklineBillladingEntity.java b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/entity/TrunklineBillladingEntity.java new file mode 100644 index 000000000..9f74fbb14 --- /dev/null +++ b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/entity/TrunklineBillladingEntity.java @@ -0,0 +1,106 @@ +package com.logpm.trunkline.entity; + +import com.baomidou.mybatisplus.annotation.TableName; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; +import lombok.EqualsAndHashCode; +import org.springblade.core.tenant.mp.TenantEntity; + +import java.util.Date; + +@Data +@TableName("logpm_trunkline_billlading") +@ApiModel(value = "TrunklineBilllading对象", description = "干线提货表") +@EqualsAndHashCode(callSuper = true) +public class TrunklineBillladingEntity extends TenantEntity { + + /** 预留1 */ + @ApiModelProperty(name = "预留1",notes = "") + private String reserve1 ; + /** 预留2 */ + @ApiModelProperty(name = "预留2",notes = "") + private String reserve2 ; + /** 预留3 */ + @ApiModelProperty(name = "预留3",notes = "") + private String reserve3 ; + /** 预留4 */ + @ApiModelProperty(name = "预留4",notes = "") + private String reserve4 ; + /** 预留5 */ + @ApiModelProperty(name = "预留5",notes = "") + private String reserve5 ; + /** 仓库id */ + @ApiModelProperty(name = "仓库id",notes = "") + private Long warehouseId ; + /** 仓库名称 */ + @ApiModelProperty(name = "仓库名称",notes = "") + private String warehouseName ; + /** 提货单号 */ + @ApiModelProperty(name = "提货单号",notes = "") + private String billladingCode ; + /** 车牌号 */ + @ApiModelProperty(name = "车牌号",notes = "") + private String carNumber ; + /** 司机id */ + @ApiModelProperty(name = "司机id",notes = "") + private Long driverId ; + /** 司机名称 */ + @ApiModelProperty(name = "司机名称",notes = "") + private String driverName ; + /** 司机电话 */ + @ApiModelProperty(name = "司机电话",notes = "") + private String driverPhone ; + /** 承运商 */ + @ApiModelProperty(name = "承运商",notes = "") + private String carrierName ; + /** 线路关联id */ + @ApiModelProperty(name = "线路关联id",notes = "") + private Long lineId ; + /** 线路名称 */ + @ApiModelProperty(name = "线路名称",notes = "") + private String lineNameTitle ; + /** 预计件数 */ + @ApiModelProperty(name = "预计件数",notes = "") + private int planNum ; + /** 预计重量 */ + @ApiModelProperty(name = "预计重量",notes = "") + private Double planWeight ; + /** 预计体积 */ + @ApiModelProperty(name = "预计体积",notes = "") + private Double planVolume ; + /** 实际件数 */ + @ApiModelProperty(name = "实际件数",notes = "") + private int realNum ; + /** 实际重量 */ + @ApiModelProperty(name = "实际重量",notes = "") + private Double realWeight ; + /** 实际体积 */ + @ApiModelProperty(name = "实际体积",notes = "") + private Double realVolume ; + /** 计费模式 1按件 2按重量 3按体积 */ + @ApiModelProperty(name = "计费模式 1按件 2按重量 3按体积",notes = "") + private String chargeType ; + /** 提货费用 */ + @ApiModelProperty(name = "提货费用",notes = "") + private Double totalFee ; + /** 提货单状态 1=未开始,2=提货中,3=已完成,4=已取消 */ + @ApiModelProperty(name = "提货单状态 1=未开始,2=提货中,3=已完成,4=已取消",notes = "") + private String billladingStatus ; + /** 提货开始时间 */ + @ApiModelProperty(name = "提货开始时间",notes = "") + private Date startTime ; + /** 提货完成时间 */ + @ApiModelProperty(name = "提货完成时间",notes = "") + private Date endTime ; + /** 结算时间 */ + @ApiModelProperty(name = "结算时间",notes = "") + private Date settlementTime ; + /** 结算人id */ + @ApiModelProperty(name = "结算人id",notes = "") + private Long settlementId ; + /** 结算人名称 */ + @ApiModelProperty(name = "结算人名称",notes = "") + private String settlementName ; + +} diff --git a/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/entity/TrunklineBillladingLineEntity.java b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/entity/TrunklineBillladingLineEntity.java new file mode 100644 index 000000000..c7b09f2e7 --- /dev/null +++ b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/entity/TrunklineBillladingLineEntity.java @@ -0,0 +1,56 @@ +package com.logpm.trunkline.entity; + +import com.baomidou.mybatisplus.annotation.TableName; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; +import lombok.EqualsAndHashCode; +import org.springblade.core.tenant.mp.TenantEntity; + +@Data +@TableName("logpm_trunkline_billlading_line") +@ApiModel(value = "TrunklineBillladingLine对象", description = "干线提货线路表") +@EqualsAndHashCode(callSuper = true) +public class TrunklineBillladingLineEntity extends TenantEntity { + + /** 预留1 */ + @ApiModelProperty(name = "预留1",notes = "") + private String reserve1 ; + /** 预留2 */ + @ApiModelProperty(name = "预留2",notes = "") + private String reserve2 ; + /** 预留3 */ + @ApiModelProperty(name = "预留3",notes = "") + private String reserve3 ; + /** 预留4 */ + @ApiModelProperty(name = "预留4",notes = "") + private String reserve4 ; + /** 预留5 */ + @ApiModelProperty(name = "预留5",notes = "") + private String reserve5 ; + /** 仓库id */ + @ApiModelProperty(name = "仓库id",notes = "") + private Long warehouseId ; + /** 仓库名称 */ + @ApiModelProperty(name = "仓库名称",notes = "") + private String warehouseName ; + /** 提货单id */ + @ApiModelProperty(name = "提货单id",notes = "") + private Long billladingId ; + /** 客户类型 1 工厂 2 商场 3装饰 4个人 */ + @ApiModelProperty(name = "客户类型 1 工厂 2 商场 3装饰 4个人",notes = "") + private String clientType ; + /** 联系人 */ + @ApiModelProperty(name = "联系人",notes = "") + private String linkMan ; + /** 联系电话 */ + @ApiModelProperty(name = "联系电话",notes = "") + private String linkPhone ; + /** 联系人地址 */ + @ApiModelProperty(name = "联系人地址",notes = "") + private String linkAddress ; + /** 排序 */ + @ApiModelProperty(name = "排序",notes = "") + private Integer sort ; + +} diff --git a/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/entity/TrunklineBillladingPackageEntity.java b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/entity/TrunklineBillladingPackageEntity.java new file mode 100644 index 000000000..fdb0bfc92 --- /dev/null +++ b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/entity/TrunklineBillladingPackageEntity.java @@ -0,0 +1,44 @@ +package com.logpm.trunkline.entity; + +import com.baomidou.mybatisplus.annotation.TableName; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; +import lombok.EqualsAndHashCode; +import org.springblade.core.tenant.mp.TenantEntity; + +@Data +@TableName("logpm_trunkline_billlading_package") +@ApiModel(value = "TrunklineBillladingPackage对象", description = "提货单包件明细表") +@EqualsAndHashCode(callSuper = true) +public class TrunklineBillladingPackageEntity extends TenantEntity { + + /** 预留1 */ + @ApiModelProperty(name = "预留1",notes = "") + private String reserve1 ; + /** 预留2 */ + @ApiModelProperty(name = "预留2",notes = "") + private String reserve2 ; + /** 预留3 */ + @ApiModelProperty(name = "预留3",notes = "") + private String reserve3 ; + /** 预留4 */ + @ApiModelProperty(name = "预留4",notes = "") + private String reserve4 ; + /** 预留5 */ + @ApiModelProperty(name = "预留5",notes = "") + private String reserve5 ; + /** 仓库id */ + @ApiModelProperty(name = "仓库id",notes = "") + private Long warehouseId ; + /** 仓库名称 */ + @ApiModelProperty(name = "仓库名称",notes = "") + private String warehouseName ; + /** 包件码 */ + @ApiModelProperty(name = "包件码",notes = "") + private String orderPackageCode ; + /** 提货单id */ + @ApiModelProperty(name = "提货单id",notes = "") + private Long billladingId ; + +} diff --git a/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/entity/TrunklineBillladingWaybillEntity.java b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/entity/TrunklineBillladingWaybillEntity.java new file mode 100644 index 000000000..a4b2603e2 --- /dev/null +++ b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/entity/TrunklineBillladingWaybillEntity.java @@ -0,0 +1,51 @@ +package com.logpm.trunkline.entity; + +import com.baomidou.mybatisplus.annotation.TableName; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; +import lombok.EqualsAndHashCode; +import org.springblade.core.tenant.mp.TenantEntity; + +@Data +@TableName("logpm_trunkline_billlading_waybill") +@ApiModel(value = "TrunklineBillladingWaybill对象", description = "提货运单关联表") +@EqualsAndHashCode(callSuper = true) +public class TrunklineBillladingWaybillEntity extends TenantEntity { + + /** 预留2 */ + @ApiModelProperty(name = "预留2",notes = "") + private String reserve2 ; + /** 预留3 */ + @ApiModelProperty(name = "预留3",notes = "") + private String reserve3 ; + /** 预留4 */ + @ApiModelProperty(name = "预留4",notes = "") + private String reserve4 ; + /** 预留5 */ + @ApiModelProperty(name = "预留5",notes = "") + private String reserve5 ; + /** 仓库id */ + @ApiModelProperty(name = "仓库id",notes = "") + private Long warehouseId ; + /** 提货单id */ + @ApiModelProperty(name = "提货单id",notes = "") + private Long billladingId ; + /** 提货单号 */ + @ApiModelProperty(name = "提货单号",notes = "") + private String billadingCode ; + /** 运单号 */ + @ApiModelProperty(name = "运单号",notes = "") + private String waybillNo ; + /** 提货数量 */ + @ApiModelProperty(name = "提货数量",notes = "") + private Integer realNum ; + /** 提货重量 */ + @ApiModelProperty(name = "提货重量",notes = "") + private Double realWeight ; + /** 提货体积 */ + @ApiModelProperty(name = "提货体积",notes = "") + private Double realVolume ; + + +} diff --git a/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/entity/TrunklineDetailProductEntity.java b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/entity/TrunklineDetailProductEntity.java new file mode 100644 index 000000000..a585d89a1 --- /dev/null +++ b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/entity/TrunklineDetailProductEntity.java @@ -0,0 +1,50 @@ +package com.logpm.trunkline.entity; + +import com.baomidou.mybatisplus.annotation.TableName; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; +import lombok.EqualsAndHashCode; +import org.springblade.core.tenant.mp.TenantEntity; + +@Data +@TableName("logpm_trunkline_detail_product") +@ApiModel(value = "TrunklineDetailProduct对象", description = "提货运单关联表") +@EqualsAndHashCode(callSuper = true) +public class TrunklineDetailProductEntity extends TenantEntity { + + /** 预留1 */ + @ApiModelProperty(name = "预留1",notes = "") + private String reserve1 ; + /** 预留2 */ + @ApiModelProperty(name = "预留2",notes = "") + private String reserve2 ; + /** 预留3 */ + @ApiModelProperty(name = "预留3",notes = "") + private String reserve3 ; + /** 预留4 */ + @ApiModelProperty(name = "预留4",notes = "") + private String reserve4 ; + /** 预留5 */ + @ApiModelProperty(name = "预留5",notes = "") + private String reserve5 ; + /** 仓库id */ + @ApiModelProperty(name = "仓库id",notes = "") + private Long warehouseId ; + /** 仓库名称 */ + @ApiModelProperty(name = "仓库名称",notes = "") + private String warehouseName ; + /** 包件码 */ + @ApiModelProperty(name = "包件码",notes = "") + private String unitNo ; + /** 货品代码 */ + @ApiModelProperty(name = "货品代码",notes = "") + private String productCode ; + /** 货品名称 */ + @ApiModelProperty(name = "货品名称",notes = "") + private String productName ; + /** 数量 */ + @ApiModelProperty(name = "数量",notes = "") + private Integer quantity ; + +} diff --git a/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/vo/TrunklineAdvanceDetailVO.java b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/vo/TrunklineAdvanceDetailVO.java new file mode 100644 index 000000000..bd47ed0ac --- /dev/null +++ b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/vo/TrunklineAdvanceDetailVO.java @@ -0,0 +1,8 @@ +package com.logpm.trunkline.vo; + +import com.logpm.trunkline.entity.TrunklineAdvanceDetailEntity; +import lombok.Data; + +@Data +public class TrunklineAdvanceDetailVO extends TrunklineAdvanceDetailEntity { +} diff --git a/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/vo/TrunklineAdvanceVO.java b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/vo/TrunklineAdvanceVO.java new file mode 100644 index 000000000..76afa1c32 --- /dev/null +++ b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/vo/TrunklineAdvanceVO.java @@ -0,0 +1,8 @@ +package com.logpm.trunkline.vo; + +import com.logpm.trunkline.entity.TrunklineAdvanceEntity; +import lombok.Data; + +@Data +public class TrunklineAdvanceVO extends TrunklineAdvanceEntity { +} diff --git a/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/vo/TrunklineBillladingLineVO.java b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/vo/TrunklineBillladingLineVO.java new file mode 100644 index 000000000..c838d6de1 --- /dev/null +++ b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/vo/TrunklineBillladingLineVO.java @@ -0,0 +1,11 @@ +package com.logpm.trunkline.vo; + +import com.logpm.trunkline.entity.TrunklineBillladingLineEntity; +import lombok.Data; + +@Data +public class TrunklineBillladingLineVO extends TrunklineBillladingLineEntity { + + + +} diff --git a/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/vo/TrunklineBillladingPackageVO.java b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/vo/TrunklineBillladingPackageVO.java new file mode 100644 index 000000000..a68ca455e --- /dev/null +++ b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/vo/TrunklineBillladingPackageVO.java @@ -0,0 +1,8 @@ +package com.logpm.trunkline.vo; + +import com.logpm.trunkline.entity.TrunklineBillladingPackageEntity; +import lombok.Data; + +@Data +public class TrunklineBillladingPackageVO extends TrunklineBillladingPackageEntity { +} diff --git a/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/vo/TrunklineBillladingVO.java b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/vo/TrunklineBillladingVO.java new file mode 100644 index 000000000..e8b653889 --- /dev/null +++ b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/vo/TrunklineBillladingVO.java @@ -0,0 +1,17 @@ +package com.logpm.trunkline.vo; + +import com.logpm.trunkline.entity.TrunklineBillladingEntity; +import lombok.Data; + +import java.math.BigDecimal; + +@Data +public class TrunklineBillladingVO extends TrunklineBillladingEntity { + + private Integer nodeNub; + private Integer waybillCount; + private Integer totalNum; + private BigDecimal totalWeight; + private BigDecimal totalVolume; + +} diff --git a/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/vo/TrunklineBillladingWaybillVO.java b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/vo/TrunklineBillladingWaybillVO.java new file mode 100644 index 000000000..accaed7d0 --- /dev/null +++ b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/vo/TrunklineBillladingWaybillVO.java @@ -0,0 +1,11 @@ +package com.logpm.trunkline.vo; + +import com.logpm.trunkline.entity.TrunklineBillladingWaybillEntity; +import lombok.Data; + +@Data +public class TrunklineBillladingWaybillVO extends TrunklineBillladingWaybillEntity { + + + +} diff --git a/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/vo/TrunklineDetailProductVO.java b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/vo/TrunklineDetailProductVO.java new file mode 100644 index 000000000..fbe8cc8eb --- /dev/null +++ b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/vo/TrunklineDetailProductVO.java @@ -0,0 +1,8 @@ +package com.logpm.trunkline.vo; + +import com.logpm.trunkline.entity.TrunklineDetailProductEntity; +import lombok.Data; + +@Data +public class TrunklineDetailProductVO extends TrunklineDetailProductEntity { +} diff --git a/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/entity/QuestDetailEntity.java b/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/entity/QuestDetailEntity.java index 2669c6ad3..798fcaac4 100644 --- a/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/entity/QuestDetailEntity.java +++ b/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/entity/QuestDetailEntity.java @@ -16,6 +16,7 @@ */ package com.logpm.warehouse.entity; +import com.baomidou.mybatisplus.annotation.TableField; import com.baomidou.mybatisplus.annotation.TableName; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; @@ -23,6 +24,8 @@ import lombok.Data; import lombok.EqualsAndHashCode; import org.springblade.core.tenant.mp.TenantEntity; +import java.util.List; + /** * 盘点明细 实体类 * @@ -120,6 +123,13 @@ public class QuestDetailEntity extends TenantEntity { */ @ApiModelProperty(value = "在库数量") private Integer stockNum; + + + /** + * 商场名称 + */ + @TableField(exist = false) + private List marketNames; /** * 仓库id */ @@ -146,12 +156,12 @@ public class QuestDetailEntity extends TenantEntity { * 托盘id */ @ApiModelProperty(value = "托盘id") - private Long trayId; + private String trayId; /** * 货位id */ @ApiModelProperty(value = "货位id") - private Long allocationId; + private String allocationId; /** * 是否是新增数据 diff --git a/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/entity/WarehouseRetentionRecordEntity.java b/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/entity/WarehouseRetentionRecordEntity.java index 75751929e..0dfae3096 100644 --- a/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/entity/WarehouseRetentionRecordEntity.java +++ b/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/entity/WarehouseRetentionRecordEntity.java @@ -138,4 +138,16 @@ public class WarehouseRetentionRecordEntity extends TenantEntity { @ApiModelProperty(value = "取消滞留备注") private String cancelRemark; + /** + * 任务Id + */ + @ApiModelProperty(value = "任务Id") + private Long taskId; + + /** + * 滞留数量 + */ + @ApiModelProperty(value = "滞留数量") + private Integer retentionQuantity; + } diff --git a/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/entity/WarehouseRetentionScanEntity.java b/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/entity/WarehouseRetentionScanEntity.java new file mode 100644 index 000000000..6fafd5599 --- /dev/null +++ b/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/entity/WarehouseRetentionScanEntity.java @@ -0,0 +1,189 @@ +/* + * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * Neither the name of the dreamlu.net developer nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * Author: Chill 庄骞 (smallchill@163.com) + */ +package com.logpm.warehouse.entity; + +import com.baomidou.mybatisplus.annotation.TableName; +import lombok.Data; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.util.Date; +import com.baomidou.mybatisplus.annotation.IdType; +import com.baomidou.mybatisplus.annotation.TableId; +import com.fasterxml.jackson.databind.annotation.JsonSerialize; +import com.fasterxml.jackson.databind.ser.std.ToStringSerializer; +import org.springblade.core.tenant.mp.TenantEntity; + +import java.io.Serializable; + +/** + * 滞留扫描记录 实体类 + * + * @author BladeX + * @since 2023-11-03 + */ +@Data +@TableName("logpm_warehouse_retention_scan") +@ApiModel(value = "WarehouseRetentionRecord对象", description = "滞留扫描记录") +public class WarehouseRetentionScanEntity extends TenantEntity { + + private static final long serialVersionUID = 1L; + /** + * 主键 + */ + @JsonSerialize(using = ToStringSerializer.class) + @ApiModelProperty(value = "主键") + @TableId(value = "id", type = IdType.ASSIGN_ID) + private Long id; + + /** + * 租户号 + */ + @ApiModelProperty(value = "租户号") + private String tenantId; + /** + * 是否已删除 + */ + @ApiModelProperty(value = "是否已删除") + private Integer isDeleted; + /** + * 预留1 + */ + @ApiModelProperty(value = "预留1") + private String reserve1; + /** + * 预留2 + */ + @ApiModelProperty(value = "预留2") + private String reserve2; + /** + * 预留3 + */ + @ApiModelProperty(value = "预留3") + private String reserve3; + /** + * 预留4 + */ + @ApiModelProperty(value = "预留4") + private String reserve4; + /** + * 预留5 + */ + @ApiModelProperty(value = "预留5") + private String reserve5; + /** + * 配送车次号 + */ + @ApiModelProperty(value = "配送车次号") + private String trainNumber; + /** + * 订单ID + */ + @ApiModelProperty(value = "订单ID") + private Long orderId; + /** + * 库存品ID + */ + @ApiModelProperty(value = "库存品ID") + private Long inventoryId; + /** + * 滞留类型 1-包件、2-零担(这里会关联到具体的品类)、3-库存品 + */ + @ApiModelProperty(value = "滞留类型 1-包件、2-零担(这里会关联到具体的品类)、3-库存品") + private Integer conditions; + /** + * 物料编码(库存品) + */ + @ApiModelProperty(value = "物料编码(库存品)") + private String materialNumber; + /** + * 物料名称(库存品) + */ + @ApiModelProperty(value = "物料名称(库存品)") + private String materialName; + /** + * 预约客户ID + */ + @ApiModelProperty(value = "预约客户ID") + private Long reservationId; + /** + * 订单自编号(库存品没有) + */ + @ApiModelProperty(value = "订单自编号(库存品没有)") + private String orderCode; + /** + * 预约单号 + */ + @ApiModelProperty(value = "预约单号") + private String reservationCode; + /** + * 扫描类型:1-包件、2-订单、3-托盘、4... + */ + @ApiModelProperty(value = "扫描类型:1-包件、2-订单、3-托盘、4...") + private Integer scanType; + /** + * 包件ID + */ + @ApiModelProperty(value = "包件ID") + private Long orderPackageId; + /** + * 包条码 + */ + @ApiModelProperty(value = "包条码") + private String orderPackageCode; + /** + * 滞留数量 + */ + @ApiModelProperty(value = "滞留数量") + private Integer retentionQuantity; + /** + * 滞留扫描操作人名称 + */ + @ApiModelProperty(value = "滞留扫描操作人名称") + private String retentionScanUsername; + /** + * 滞留扫描操作人Id + */ + @ApiModelProperty(value = "滞留扫描操作人Id") + private Long retentionScanUserId; + /** + * 滞留操作备注 + */ + @ApiModelProperty(value = "滞留操作备注") + private String remarks; + /** + * 滞留扫描时间 + */ + @ApiModelProperty(value = "滞留扫描时间") + private Date retentionScanTime; + /** + * 滞留方式 1-PDA、2-PC + */ + @ApiModelProperty(value = "滞留方式 1-PDA、2-PC") + private Integer retentionWay; + /** + * 配送任务ID + */ + @ApiModelProperty(value = "配送任务ID") + private Long deliveryId; + + /** + * 配送任务ID + */ + @ApiModelProperty(value = "配送任务ID") + private Long refId; + +} diff --git a/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/feign/IWarehouseRetentionScanClient.java b/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/feign/IWarehouseRetentionScanClient.java new file mode 100644 index 000000000..11fc23016 --- /dev/null +++ b/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/feign/IWarehouseRetentionScanClient.java @@ -0,0 +1,61 @@ +/* + * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * Neither the name of the dreamlu.net developer nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * Author: Chill 庄骞 (smallchill@163.com) + */ +package com.logpm.warehouse.feign; + +import com.logpm.warehouse.entity.WarehouseRetentionScanEntity; +import org.springblade.core.mp.support.BladePage; +import com.logpm.warehouse.entity.WarehouseRetentionRecordEntity; +import org.springblade.core.tool.api.R; +import org.springframework.cloud.openfeign.FeignClient; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestParam; + +/** + * 滞留扫描记录 Feign接口类 + * + * @author BladeX + * @since 2023-11-03 + */ +@FeignClient( + value = "warehouseRetentionScan" +) +public interface IWarehouseRetentionScanClient { + + String API_PREFIX = "retentionScan/client"; + String TOP = API_PREFIX + "/top"; + + /** + * 获取滞留扫描记录列表 + * + * @param current 页号 + * @param size 页数 + * @return BladePage + */ + @GetMapping(TOP) + BladePage retentionScanTop(@RequestParam("current") Integer current, @RequestParam("size") Integer size); + + + /** + * 保存扫描记录 + * @return BladePage + */ + @PostMapping(TOP+"/saveRetentionScan") + R saveRetentionScan(@RequestBody WarehouseRetentionScanEntity warehouseRetentionScanEntity); + +} diff --git a/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/vo/WarehouseRetentionRecordVO.java b/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/vo/WarehouseRetentionRecordVO.java index d2da6d1a2..b18f4ac00 100644 --- a/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/vo/WarehouseRetentionRecordVO.java +++ b/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/vo/WarehouseRetentionRecordVO.java @@ -20,6 +20,8 @@ import com.logpm.warehouse.entity.WarehouseRetentionRecordEntity; import lombok.Data; import lombok.EqualsAndHashCode; +import java.util.List; + /** * 滞留记录 视图实体类 * @@ -31,4 +33,9 @@ import lombok.EqualsAndHashCode; public class WarehouseRetentionRecordVO extends WarehouseRetentionRecordEntity { private static final long serialVersionUID = 1L; + + private List retentionScanVOList; + + private String retentionTypeName; + } diff --git a/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/vo/WarehouseRetentionScanVO.java b/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/vo/WarehouseRetentionScanVO.java new file mode 100644 index 000000000..2fdb632da --- /dev/null +++ b/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/vo/WarehouseRetentionScanVO.java @@ -0,0 +1,34 @@ +/* + * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * Neither the name of the dreamlu.net developer nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * Author: Chill 庄骞 (smallchill@163.com) + */ +package com.logpm.warehouse.vo; + +import com.logpm.warehouse.entity.WarehouseRetentionScanEntity; +import lombok.Data; +import lombok.EqualsAndHashCode; + +/** + * 滞留扫描记录 视图实体类 + * + * @author BladeX + * @since 2023-11-03 + */ +@Data +@EqualsAndHashCode(callSuper = true) +public class WarehouseRetentionScanVO extends WarehouseRetentionScanEntity { + private static final long serialVersionUID = 1L; + +} diff --git a/blade-service/logpm-basic/src/main/java/com/logpm/basic/controller/BasicDelineController.java b/blade-service/logpm-basic/src/main/java/com/logpm/basic/controller/BasicDelineController.java index e36da198f..1ca47841d 100644 --- a/blade-service/logpm-basic/src/main/java/com/logpm/basic/controller/BasicDelineController.java +++ b/blade-service/logpm-basic/src/main/java/com/logpm/basic/controller/BasicDelineController.java @@ -30,7 +30,6 @@ import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiParam; import lombok.AllArgsConstructor; import lombok.extern.slf4j.Slf4j; -import net.logstash.logback.encoder.org.apache.commons.lang3.StringEscapeUtils; import org.springblade.core.boot.ctrl.BladeController; import org.springblade.core.excel.util.ExcelUtil; import org.springblade.core.mp.support.Condition; @@ -47,6 +46,7 @@ import javax.servlet.http.HttpServletResponse; import javax.validation.Valid; import java.util.List; import java.util.Map; +import java.util.Objects; /** * 提货路线 控制器 @@ -104,10 +104,8 @@ public class BasicDelineController extends BladeController { @ApiOperation(value = "新增", notes = "传入basicDeline") public R save(@Valid @RequestBody BasicDelineDTO basicDeline) { //转义-> - basicDeline.setLineName(StringEscapeUtils.unescapeHtml4(basicDeline.getLineName())); - basicDelineService.save(basicDeline); - //新增关联表 - return R.status(basicDelineMiddleService.saveByDTO(basicDeline)); +// basicDeline.setLineName(StringEscapeUtils.unescapeHtml4(basicDeline.getLineName())); + return basicDelineService.saveDeline(basicDeline); } /** @@ -117,13 +115,12 @@ public class BasicDelineController extends BladeController { @ApiOperationSupport(order = 5) @ApiOperation(value = "修改", notes = "传入basicDeline") public R update(@Valid @RequestBody BasicDelineDTO basicDeline) { - //转义-> - basicDeline.setLineName(StringEscapeUtils.unescapeHtml4(basicDeline.getLineName())); - //删除所有中间表 - basicDelineMiddleService.deleteBydelineId(Func.toLongList(String.valueOf(basicDeline.getId()))); - //新增关联表 - basicDelineMiddleService.saveByDTO(basicDeline); - return R.status(basicDelineService.updateById(basicDeline)); + Long id = basicDeline.getId(); + if(Objects.isNull(id)){ + log.warn("#############update: id不能为空"); + return R.fail(403,"id不能为空"); + } + return basicDelineService.updateDeline(basicDeline); } /** diff --git a/blade-service/logpm-basic/src/main/java/com/logpm/basic/controller/BasicDelineNodeController.java b/blade-service/logpm-basic/src/main/java/com/logpm/basic/controller/BasicDelineNodeController.java index db76eed9e..39d664b38 100644 --- a/blade-service/logpm-basic/src/main/java/com/logpm/basic/controller/BasicDelineNodeController.java +++ b/blade-service/logpm-basic/src/main/java/com/logpm/basic/controller/BasicDelineNodeController.java @@ -97,8 +97,9 @@ public class BasicDelineNodeController extends BladeController { @GetMapping("/dictionary") @ApiOperationSupport(order = 3) @ApiOperation(value = "字典", notes = "传入basicDelineNode") - public R> dictionary() { - List basicDelineNodeVOS = basicDelineNodeService.selectBasicDelineNodeDictionary(); + public R> dictionary(BasicDelineNodeDTO basicDelineNode) { + String customer = basicDelineNode.getCustomer(); + List basicDelineNodeVOS = basicDelineNodeService.selectBasicDelineNodeDictionary(customer); return R.data(basicDelineNodeVOS); } diff --git a/blade-service/logpm-basic/src/main/java/com/logpm/basic/dto/BasicDelineNodeDTO.java b/blade-service/logpm-basic/src/main/java/com/logpm/basic/dto/BasicDelineNodeDTO.java index c86adac9d..6658a7ef1 100644 --- a/blade-service/logpm-basic/src/main/java/com/logpm/basic/dto/BasicDelineNodeDTO.java +++ b/blade-service/logpm-basic/src/main/java/com/logpm/basic/dto/BasicDelineNodeDTO.java @@ -51,6 +51,6 @@ public class BasicDelineNodeDTO extends BasicDelineNodeEntity { @ApiModelProperty(value = "主表Id") private Long delineId; - + private Integer sort; } diff --git a/blade-service/logpm-basic/src/main/java/com/logpm/basic/mapper/BasicDelineNodeMapper.java b/blade-service/logpm-basic/src/main/java/com/logpm/basic/mapper/BasicDelineNodeMapper.java index cdba385c4..d21d04bb8 100644 --- a/blade-service/logpm-basic/src/main/java/com/logpm/basic/mapper/BasicDelineNodeMapper.java +++ b/blade-service/logpm-basic/src/main/java/com/logpm/basic/mapper/BasicDelineNodeMapper.java @@ -57,5 +57,5 @@ public interface BasicDelineNodeMapper extends BaseMapper * * @return */ - List selectBasicDelineNodeDictionary(); + List selectBasicDelineNodeDictionary(@Param("customer") String customer); } diff --git a/blade-service/logpm-basic/src/main/java/com/logpm/basic/mapper/BasicDelineNodeMapper.xml b/blade-service/logpm-basic/src/main/java/com/logpm/basic/mapper/BasicDelineNodeMapper.xml index eb209946f..182c7b423 100644 --- a/blade-service/logpm-basic/src/main/java/com/logpm/basic/mapper/BasicDelineNodeMapper.xml +++ b/blade-service/logpm-basic/src/main/java/com/logpm/basic/mapper/BasicDelineNodeMapper.xml @@ -40,16 +40,13 @@ lbdn.contacts contacts, lbdn.address address, lbdn.telephone telephone, - lbdm.ageing ageing, - lbdm.route route + lbdn.longitude longitude, + lbdn.latitude latitude, + ldbn.remark remark FROM logpm_basic_deline_node lbdn - JOIN logpm_basic_deline_middle lbdm on lbdn.id = lbdm.node_id lbdn.is_deleted = 0 - AND lbdm.is_deleted = 0 - and lbdm.deline_id = #{param.delineId} - and lbdm.node_id = #{param.id} @@ -58,7 +55,12 @@ SELECT * FROM logpm_basic_deline_node ${ew.customSqlSegment} diff --git a/blade-service/logpm-basic/src/main/java/com/logpm/basic/service/IBasicDelineNodeService.java b/blade-service/logpm-basic/src/main/java/com/logpm/basic/service/IBasicDelineNodeService.java index 8320d2f44..e0b3b52e1 100644 --- a/blade-service/logpm-basic/src/main/java/com/logpm/basic/service/IBasicDelineNodeService.java +++ b/blade-service/logpm-basic/src/main/java/com/logpm/basic/service/IBasicDelineNodeService.java @@ -55,5 +55,5 @@ public interface IBasicDelineNodeService extends BaseService selectBasicDelineNodeDictionary(); + List selectBasicDelineNodeDictionary(String customer); } diff --git a/blade-service/logpm-basic/src/main/java/com/logpm/basic/service/IBasicDelineService.java b/blade-service/logpm-basic/src/main/java/com/logpm/basic/service/IBasicDelineService.java index 2f11f71c6..8d31db2b8 100644 --- a/blade-service/logpm-basic/src/main/java/com/logpm/basic/service/IBasicDelineService.java +++ b/blade-service/logpm-basic/src/main/java/com/logpm/basic/service/IBasicDelineService.java @@ -18,10 +18,12 @@ package com.logpm.basic.service; import com.baomidou.mybatisplus.core.conditions.Wrapper; import com.baomidou.mybatisplus.core.metadata.IPage; +import com.logpm.basic.dto.BasicDelineDTO; import com.logpm.basic.entity.BasicDelineEntity; import com.logpm.basic.excel.BasicDelineExcel; import com.logpm.basic.vo.BasicDelineVO; import org.springblade.core.mp.base.BaseService; +import org.springblade.core.tool.api.R; import java.util.List; @@ -50,4 +52,8 @@ public interface IBasicDelineService extends BaseService { */ List exportBasicDeline(Wrapper queryWrapper); + R saveDeline(BasicDelineDTO basicDelineDTO); + + R updateDeline(BasicDelineDTO basicDeline); + } diff --git a/blade-service/logpm-basic/src/main/java/com/logpm/basic/service/impl/BasicDelineNodeServiceImpl.java b/blade-service/logpm-basic/src/main/java/com/logpm/basic/service/impl/BasicDelineNodeServiceImpl.java index aca8b3b2b..d79d510be 100644 --- a/blade-service/logpm-basic/src/main/java/com/logpm/basic/service/impl/BasicDelineNodeServiceImpl.java +++ b/blade-service/logpm-basic/src/main/java/com/logpm/basic/service/impl/BasicDelineNodeServiceImpl.java @@ -54,8 +54,8 @@ public class BasicDelineNodeServiceImpl extends BaseServiceImpl selectBasicDelineNodeDictionary() { - return baseMapper.selectBasicDelineNodeDictionary(); + public List selectBasicDelineNodeDictionary(String customer) { + return baseMapper.selectBasicDelineNodeDictionary(customer); } } diff --git a/blade-service/logpm-basic/src/main/java/com/logpm/basic/service/impl/BasicDelineServiceImpl.java b/blade-service/logpm-basic/src/main/java/com/logpm/basic/service/impl/BasicDelineServiceImpl.java index 46ce9cd44..a28c84be1 100644 --- a/blade-service/logpm-basic/src/main/java/com/logpm/basic/service/impl/BasicDelineServiceImpl.java +++ b/blade-service/logpm-basic/src/main/java/com/logpm/basic/service/impl/BasicDelineServiceImpl.java @@ -18,14 +18,23 @@ package com.logpm.basic.service.impl; import com.baomidou.mybatisplus.core.conditions.Wrapper; import com.baomidou.mybatisplus.core.metadata.IPage; +import com.logpm.basic.dto.BasicDelineDTO; +import com.logpm.basic.dto.BasicDelineNodeDTO; import com.logpm.basic.entity.BasicDelineEntity; +import com.logpm.basic.entity.BasicDelineMiddleEntity; import com.logpm.basic.excel.BasicDelineExcel; import com.logpm.basic.mapper.BasicDelineMapper; +import com.logpm.basic.service.IBasicDelineMiddleService; import com.logpm.basic.service.IBasicDelineService; import com.logpm.basic.vo.BasicDelineVO; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; import org.springblade.core.mp.base.BaseServiceImpl; +import org.springblade.core.tool.api.R; +import org.springblade.core.tool.utils.BeanUtil; import org.springframework.stereotype.Service; +import java.util.ArrayList; import java.util.List; /** @@ -34,9 +43,13 @@ import java.util.List; * @author lmy * @since 2023-05-24 */ +@Slf4j @Service +@AllArgsConstructor public class BasicDelineServiceImpl extends BaseServiceImpl implements IBasicDelineService { + private final IBasicDelineMiddleService basicDelineMiddleService; + @Override public IPage selectBasicDelinePage(IPage page, BasicDelineVO basicDeline) { return page.setRecords(baseMapper.selectBasicDelinePage(page, basicDeline)); @@ -52,4 +65,56 @@ public class BasicDelineServiceImpl extends BaseServiceImpl delinenode = basicDelineDTO.getDelinenode(); + if(delinenode.size() < 2){ + log.warn("##############saveDeline: 节点选择有误"); + return R.fail(403,"节点选择有误"); + } + BasicDelineEntity basicDelineEntity = new BasicDelineEntity(); + BeanUtil.copy(basicDelineDTO,basicDelineEntity); + save(basicDelineEntity); + Long delineId = basicDelineEntity.getId(); + for (BasicDelineNodeDTO basicDelineNodeDTO:delinenode){ + BasicDelineMiddleEntity basicDelineMiddleEntity = new BasicDelineMiddleEntity(); + basicDelineMiddleEntity.setDelineId(delineId); + basicDelineMiddleEntity.setNodeId(basicDelineNodeDTO.getId()); + basicDelineMiddleEntity.setAgeing(basicDelineNodeDTO.getAgeing()); + basicDelineMiddleEntity.setRoute(basicDelineNodeDTO.getRoute()); + basicDelineMiddleService.save(basicDelineMiddleEntity); + } + return R.success("保存成功"); + } + + @Override + public R updateDeline(BasicDelineDTO basicDeline) { + log.info("#############updateDeline: 更新提货路线"); + List delinenode = basicDeline.getDelinenode(); + if(delinenode.size() < 2){ + log.warn("##############saveDeline: 节点选择有误"); + return R.fail(403,"节点选择有误"); + } + BasicDelineEntity basicDelineEntity = new BasicDelineEntity(); + BeanUtil.copy(basicDeline,basicDelineEntity); + updateById(basicDelineEntity); + Long delineId = basicDelineEntity.getId(); + //先删除以前的关联数据 + List delineIds = new ArrayList<>(); + delineIds.add(delineId); + basicDelineMiddleService.deleteBydelineId(delineIds); + + for (BasicDelineNodeDTO basicDelineNodeDTO:delinenode){ + BasicDelineMiddleEntity basicDelineMiddleEntity = new BasicDelineMiddleEntity(); + basicDelineMiddleEntity.setDelineId(delineId); + basicDelineMiddleEntity.setNodeId(basicDelineNodeDTO.getId()); + basicDelineMiddleEntity.setAgeing(basicDelineNodeDTO.getAgeing()); + basicDelineMiddleEntity.setRoute(basicDelineNodeDTO.getRoute()); + basicDelineMiddleService.save(basicDelineMiddleEntity); + } + + return R.success("更新成功"); + } + } diff --git a/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/controller/BasicdataWarehouseController.java b/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/controller/BasicdataWarehouseController.java index 7ecfb97b0..dfa8f2ad6 100644 --- a/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/controller/BasicdataWarehouseController.java +++ b/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/controller/BasicdataWarehouseController.java @@ -18,6 +18,7 @@ package com.logpm.basicdata.controller; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; +import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; import com.logpm.basicdata.dto.BasicdataWarehouseDTO; import com.logpm.basicdata.entity.BasicdataWarehouseEntity; @@ -32,11 +33,15 @@ import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiParam; import lombok.AllArgsConstructor; import lombok.extern.log4j.Log4j2; +import org.springblade.common.cache.CacheObjNames; import org.springblade.core.boot.ctrl.BladeController; +import org.springblade.core.cache.utils.CacheUtil; import org.springblade.core.excel.util.ExcelUtil; 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; import org.springblade.core.tool.constant.BladeConstant; import org.springblade.core.tool.utils.DateUtil; @@ -66,6 +71,8 @@ public class BasicdataWarehouseController extends BladeController { private final IBasicdataWarehouseClient basicdataWarehouseClient; + private final BladeRedis bladeRedis; + /** * 仓库 详情 */ @@ -177,6 +184,8 @@ public class BasicdataWarehouseController extends BladeController { @ApiOperationSupport(order = 4) @ApiOperation(value = "新增", notes = "传入warehouseWarehouse") public R save(@Valid @RequestBody BasicdataWarehouseEntity warehouseWarehouse) { + BladeUser user = AuthUtil.getUser(); + CacheUtil.evict(CacheObjNames.basic_data_warehourse_list.getCacheName(), CacheObjNames.basic_data_warehourse_list.getKeyPrefix(),user.getUserId()); warehouseWarehouse.setEnableStatus("2"); return R.status(warehouseService.save(warehouseWarehouse)); } @@ -198,6 +207,8 @@ public class BasicdataWarehouseController extends BladeController { @ApiOperationSupport(order = 6) @ApiOperation(value = "新增或修改", notes = "传入warehouseWarehouse") public R submit(@Valid @RequestBody BasicdataWarehouseEntity warehouseWarehouse) { + BladeUser user = AuthUtil.getUser(); + CacheUtil.evict(CacheObjNames.basic_data_warehourse_list.getCacheName(), CacheObjNames.basic_data_warehourse_list.getKeyPrefix(),user.getUserId()); return R.status(warehouseService.saveOrUpdate(warehouseWarehouse)); } @@ -211,6 +222,10 @@ public class BasicdataWarehouseController extends BladeController { @ApiOperationSupport(order = 7) @ApiOperation(value = "逻辑删除", notes = "传入ids") public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) { + BladeUser user = AuthUtil.getUser(); + + CacheUtil.evict(CacheObjNames.basic_data_warehourse_list.getCacheName(), CacheObjNames.basic_data_warehourse_list.getKeyPrefix(),user.getUserId()); + boolean result = warehouseService.removeWarehouse(ids); if (result) { return R.status(true); @@ -274,7 +289,15 @@ public class BasicdataWarehouseController extends BladeController { @GetMapping("/getMyWarehouseList") @ApiOperationSupport(order = 3) public R> getMyWarehouseList() { - List basicdataGoodsShelfVOList = warehouseService.getMyWarehouseList(); + + BladeUser user = AuthUtil.getUser(); + List basicdataGoodsShelfVOList = CacheUtil.get(CacheObjNames.basic_data_warehourse_list.getCacheName(), CacheObjNames.basic_data_warehourse_list.getKeyPrefix(), user.getUserId(),List.class); + + if(ObjectUtils.isNull(basicdataGoodsShelfVOList)){ + basicdataGoodsShelfVOList = warehouseService.getMyWarehouseList(); + CacheUtil.put(CacheObjNames.basic_data_warehourse_list.getCacheName(), CacheObjNames.basic_data_warehourse_list.getKeyPrefix(),user.getUserId(),basicdataGoodsShelfVOList); + } + return R.data(basicdataGoodsShelfVOList); } diff --git a/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/impl/BasicdataClientServiceImpl.java b/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/impl/BasicdataClientServiceImpl.java index f2397a0df..c5bce739d 100644 --- a/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/impl/BasicdataClientServiceImpl.java +++ b/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/impl/BasicdataClientServiceImpl.java @@ -269,6 +269,7 @@ public class BasicdataClientServiceImpl extends BaseServiceImpl data, Boolean isCovered) { log.info("客户导入数据"); List storeContactEntities = new ArrayList<>(); // 联系人 @@ -418,6 +419,9 @@ public class BasicdataClientServiceImpl extends BaseServiceImpl warehouseEntityList = baseMapper.selectList(Wrappers.query().lambda().in(BasicdataWarehouseEntity::getDepartment, deptIds)); -// String json = redis.get(CacheNames.tenantKeyObj(user.getTenantId(), CacheNames.USER_WAREHOUSE_KEY, user.getUserId())); -// if (warehouseEntityList.size() <= 1) { -// redis.setEx(CacheNames.tenantKeyObj(user.getTenantId(), CacheNames.USER_WAREHOUSE_KEY, user.getUserId()), warehouseEntityList.get(0), 30 * 24 * 60 * 60L); -// } - return warehouseEntityList; + if(deptIds.isEmpty()){ + return null; + } + return baseMapper.selectList(Wrappers.query().lambda().in(BasicdataWarehouseEntity::getDepartment, deptIds)); } @Override diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/appcontroller/DistributionAddvalueAppController.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/appcontroller/DistributionAddvalueAppController.java index 4135ac484..bf3201df7 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/appcontroller/DistributionAddvalueAppController.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/appcontroller/DistributionAddvalueAppController.java @@ -95,7 +95,6 @@ public class DistributionAddvalueAppController { return r; } - /** * 编辑保存 */ @@ -107,8 +106,6 @@ public class DistributionAddvalueAppController { return r; } - - /** * 查询编辑增值服务数据 */ @@ -120,8 +117,6 @@ public class DistributionAddvalueAppController { return r; } - - /** * 查询增值服务数据 */ diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/appcontroller/DistributionDeliveryAppController.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/appcontroller/DistributionDeliveryAppController.java index fbccbe226..86d98ec88 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/appcontroller/DistributionDeliveryAppController.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/appcontroller/DistributionDeliveryAppController.java @@ -5,9 +5,11 @@ import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; import com.logpm.distribution.bean.Resp; import com.logpm.distribution.dto.app.DistributionAppDeliveryListDTO; import com.logpm.distribution.dto.app.DistrilbutionloadingscanDTO; +import com.logpm.distribution.entity.DistributionParcelListEntity; import com.logpm.distribution.service.IDistributionDeliveryInfoService; import com.logpm.distribution.service.IDistributionDeliveryListService; import com.logpm.distribution.vo.DisStockListDetailVO; +import com.logpm.distribution.vo.DistributionParcelListVO; import com.logpm.distribution.vo.app.*; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; @@ -267,4 +269,37 @@ public class DistributionDeliveryAppController { } + + /** + * 扫描查询配送任务下的包件信息 + */ + @PostMapping("/retentionScan") + @ApiOperationSupport(order = 11) + public R retentionScan(@Valid @RequestBody DistrilbutionloadingscanDTO distrilbutionloadingscanDTO) { + R r = distributionDeliveryListService.retentionScan(distrilbutionloadingscanDTO); + return r; + } + + + /** + * 扫描查询配送任务下的包件信息 + */ + @PostMapping("/getZeroPackageInfo") + @ApiOperationSupport(order = 11) + public R getZeroPackageInfo(@Valid @RequestBody DistrilbutionloadingscanDTO distrilbutionloadingscanDTO) { + R distributionParcelListVOS = distributionDeliveryListService.getZeroPackageInfo(distrilbutionloadingscanDTO); + return R.data(distributionParcelListVOS); + } + + + /** + * 扫描查询配送任务下的包件信息 + */ + @PostMapping("/getInventoryInfo") + @ApiOperationSupport(order = 11) + public R getInventoryInfo(@Valid @RequestBody DistrilbutionloadingscanDTO distrilbutionloadingscanDTO) { + R r = distributionDeliveryListService.getInventoryInfo(distrilbutionloadingscanDTO); + return R.data(r); + } + } diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/appcontroller/DistributionStockupAppController.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/appcontroller/DistributionStockupAppController.java index f48758d45..c9f5a1d62 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/appcontroller/DistributionStockupAppController.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/appcontroller/DistributionStockupAppController.java @@ -610,6 +610,8 @@ public class DistributionStockupAppController extends BladeController { entity.setConditions("0"); entity.setType(2); distributionStockService.save(entity); + //修改订单备货状态 + distributionAsyncService.updateStockArticleStock(one.getStockArticleId()); // dataSourceTransactionManager.commit(transactionStatus);//提交 Map map = new HashMap<>(); diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionDeliveryListController.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionDeliveryListController.java index 5a7b18122..f008f3534 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionDeliveryListController.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionDeliveryListController.java @@ -244,12 +244,7 @@ public class DistributionDeliveryListController extends BladeController { @ApiOperationSupport(order = 9) @ApiOperation(value = "导出数据", notes = "传入distributionDeliveryList") public void exportDistributionDeliveryList(@ApiIgnore @RequestParam Map distributionDeliveryList, BladeUser bladeUser, HttpServletResponse response) { - QueryWrapper queryWrapper = Condition.getQueryWrapper(distributionDeliveryList, DistributionDeliveryListEntity.class); - //if (!AuthUtil.isAdministrator()) { - // queryWrapper.lambda().eq(DistributionDeliveryList::getTenantId, bladeUser.getTenantId()); - //} - queryWrapper.lambda().eq(DistributionDeliveryListEntity::getIsDeleted, BladeConstant.DB_NOT_DELETED); - List list = distributionDeliveryListService.exportDistributionDeliveryList(queryWrapper); + List list = distributionDeliveryListService.exportDistributionDeliveryList(distributionDeliveryList); ExcelUtil.export(response, "配送管理数据" + DateUtil.time(), "配送管理数据表", list, DistributionDeliveryListExcel.class); } diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionParcelListController.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionParcelListController.java index 7ca33b4aa..184ff88d9 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionParcelListController.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionParcelListController.java @@ -163,10 +163,10 @@ public class DistributionParcelListController extends BladeController { /** * 修改零担在库数量 */ - @GetMapping("/zeroUpdateMaterial") + @PutMapping("/zeroUpdateMaterial") @ApiOperationSupport(order = 2) @ApiOperation(value = "修改零担在库数量", notes = "传入distributionParcelList") - public R> getZeroUpdateMaterial(@ApiIgnore @RequestParam Map distributionParcelList, Query query) { + public R> getZeroUpdateMaterial(@RequestBody Map distributionParcelList, Query query) { int a = distributionParcelListService.getZeroUpdateMaterial(distributionParcelList); return a > 0 ? R.success("修改成功!") : R.fail("修改失败!"); } diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionReservationController.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionReservationController.java index 837dae2b5..4b4578a50 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionReservationController.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionReservationController.java @@ -183,12 +183,8 @@ public class DistributionReservationController extends BladeController { @ApiOperationSupport(order = 9) @ApiOperation(value = "导出数据", notes = "传入distrbutionReservation") public void exportDistrbutionReservation(@ApiIgnore @RequestParam Map distrbutionReservation, BladeUser bladeUser, HttpServletResponse response) { - QueryWrapper queryWrapper = Condition.getQueryWrapper(distrbutionReservation, DistributionReservationEntity.class); - //if (!AuthUtil.isAdministrator()) { - // queryWrapper.lambda().eq(DistrbutionReservation::getTenantId, bladeUser.getTenantId()); - //} - queryWrapper.lambda().eq(DistributionReservationEntity::getIsDeleted, BladeConstant.DB_NOT_DELETED); - List list = reservationService.exportDistrbutionReservation(queryWrapper); + + List list = reservationService.exportDistrbutionReservation(distrbutionReservation); ExcelUtil.export(response, "预约列表数据" + DateUtil.time(), "预约列表数据表", list, DistributionReservationExcel.class); } diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionSignforController.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionSignforController.java index c995518c2..7405a4d1f 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionSignforController.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionSignforController.java @@ -130,7 +130,7 @@ public class DistributionSignforController extends BladeController { @ApiOperationSupport(order = 1) @ApiOperation(value = "详情", notes = "传入distributionSignfor") public R> signforPackageList(Long signforId) { - List distributionSignforsnmbVO = distributionSignforService.signforPackageList(signforId); + List distributionSignforsnmbVO= distributionSignforService.signforPackageList(signforId); return R.data(distributionSignforsnmbVO); } @@ -255,13 +255,10 @@ public class DistributionSignforController extends BladeController { @PostMapping("/update") @ApiOperationSupport(order = 5) @ApiOperation(value = "修改", notes = "传入distributionSignfor") - public R update(@Valid @RequestBody DistributionSignforEntity distributionSignfor) { - distributionSignfor.setSigneeId(AuthUtil.getUser().getUserId()); - distributionSignfor.setSigneeName(AuthUtil.getUser().getUserName()); - Date date = new Date(); - SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); - distributionSignfor.setSigningTime(sdf.format(date)); - return R.status(distributionSignforService.updateById(distributionSignfor)); + public R update(@Valid @RequestBody DistributionSignforDTO distributionSignfor) { + R r = distributionSignforService.updateSign(distributionSignfor); +// return R.status(distributionSignforService.updateById(distributionSignfor)); + return r; } /** @@ -314,4 +311,19 @@ public class DistributionSignforController extends BladeController { } +// /** +// * 签收管理 修改签收照片信息 +// */ +// @PutMapping("/updatePCPicture") +// @ApiOperationSupport(order = 4) +// @ApiOperation(value = "修改签收照片信息", notes = "修改签收照片信息") +// public R updatePCPicture(@Valid @RequestBody DistributionSignforDTO distributionSignfor) { +// if(ObjectUtil.isNotEmpty(distributionSignfor.getReservationId())){ +// return R.data(distributionSignforService.updatePicture(distributionSignfor)); +// }else { +// return R.fail(3002,"参数不能为空不对!!"); +// } +// } + + } diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/dto/DistributionRetentionScanDTO.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/dto/DistributionRetentionScanDTO.java new file mode 100644 index 000000000..53be07ca2 --- /dev/null +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/dto/DistributionRetentionScanDTO.java @@ -0,0 +1,71 @@ +package com.logpm.distribution.dto; + + +import lombok.Data; + +/** + * 滞留扫描对象 + */ +@Data +//@EqualsAndHashCode(callSuper = true) +public class DistributionRetentionScanDTO { + + /** + * 预约Id + */ + private Long reservationId; + + /** + * 预约Id + */ + private String reservationCode; + + /** + * 订单Id + */ + private Long orderId; + + /** + * 订单自编码 + */ + private Long orderCode; + + /** + * 订单Id + */ + private Long inventoryId; + + + + /** + * 物料编码 + */ + private String materialNumber; + + /** + * 物料名称 + */ + private String materialName; + + /** + * 包件ID + */ + private Long orderPackageId; + + /** + * 包条码 + */ + private Long orderPackageCode; + + /** + * 滞留数量 + */ + private Long retentionQuantity; + + /** + * 类型 + */ + private Integer conditions; + + +} diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/dto/app/DistrilbutionloadingscanDTO.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/dto/app/DistrilbutionloadingscanDTO.java index da4d212ec..1ec1cb490 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/dto/app/DistrilbutionloadingscanDTO.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/dto/app/DistrilbutionloadingscanDTO.java @@ -45,6 +45,12 @@ public class DistrilbutionloadingscanDTO { @ApiModelProperty(value = "预约Id") private Long orderId; + /** + * 订单自编码 + */ + @ApiModelProperty(value = "预约Id") + private String orderCode; + // /** // * 扫描类型 @@ -88,6 +94,13 @@ public class DistrilbutionloadingscanDTO { // @NotEmpty(message = "扫描物品不能为空") private Integer type; + /** + * 滞留扫描类型 + */ + @ApiModelProperty(value = "扫描物品(1-包条,2-订单,3-托盘)") +// @NotEmpty(message = "扫描物品不能为空") + private Integer retentionType; + /** * 是否库存品 */ diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/excel/DistributionDeliveryListExcel.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/excel/DistributionDeliveryListExcel.java index 3f03bdb3f..8c7ee8cdc 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/excel/DistributionDeliveryListExcel.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/excel/DistributionDeliveryListExcel.java @@ -41,71 +41,37 @@ public class DistributionDeliveryListExcel implements Serializable { private static final long serialVersionUID = 1L; + /** - * 租户号 - */ - @ColumnWidth(20) - @ExcelProperty("租户号") - private String tenantId; - /** - * 是否已删除 - */ - @ColumnWidth(20) - @ExcelProperty("是否已删除") - private Integer isDeleted; - /** - * 预留1 - */ - @ColumnWidth(20) - @ExcelProperty("预留1") - private String reserve1; - /** - * 预留2 - */ - @ColumnWidth(20) - @ExcelProperty("预留2") - private String reserve2; - /** - * 预留3 - */ - @ColumnWidth(20) - @ExcelProperty("预留3") - private String reserve3; - /** - * 预留4 - */ - @ColumnWidth(20) - @ExcelProperty("预留4") - private String reserve4; - /** - * 预留5 + * 车次 */ @ColumnWidth(20) - @ExcelProperty("预留5") - private String reserve5; + @ExcelProperty("车次") + private String trainNumber; /** * 车次 */ @ColumnWidth(20) - @ExcelProperty("车次") - private String trainNumber; + @ExcelProperty("配送日期") + private String taskTime; + /** * 仓库 */ @ColumnWidth(20) @ExcelProperty("仓库") - private String warehouse; + private String warehouseName; /** * 配送类型;1-自主配送,2-三方配送 */ @ColumnWidth(20) - @ExcelProperty("配送类型;1-自主配送,2-三方配送") + @ExcelProperty("配送类型") private String type; /** * 配送种类;1-市配,2-商配 */ @ColumnWidth(20) - @ExcelProperty("配送种类;1-市配,2-商配") + @ExcelProperty("配送种类") private String kind; /** * 配送车辆 @@ -123,13 +89,13 @@ public class DistributionDeliveryListExcel implements Serializable { * 配送公司;1-货拉拉,2-京东 */ @ColumnWidth(20) - @ExcelProperty("配送公司;1-货拉拉,2-京东") + @ExcelProperty("配送公司") private String distributionCompany; /** * 配送状态;1-配送中,2-已完成 */ @ColumnWidth(20) - @ExcelProperty("配送状态;1-配送中,2-已完成") + @ExcelProperty("配送状态") private String state; /** * 配送客户数 @@ -143,12 +109,12 @@ public class DistributionDeliveryListExcel implements Serializable { @ColumnWidth(20) @ExcelProperty("配送价格") private BigDecimal price; - /** - * 增值服务表id - */ - @ColumnWidth(20) - @ExcelProperty("增值服务表id") - private Integer addedServicesId; +// /** +// * 增值服务表id +// */ +// @ColumnWidth(20) +// @ExcelProperty("增值服务表id") +// private Integer addedServicesId; /** * 订单总数 */ @@ -159,8 +125,14 @@ public class DistributionDeliveryListExcel implements Serializable { * 配送件数 */ @ColumnWidth(20) - @ExcelProperty("配送件数") + @ExcelProperty("配送包件数") private Integer deliveryNumber; + /** + * 配送件数 + */ + @ColumnWidth(20) + @ExcelProperty("配送库存品数") + private Integer inventoryNub; /** * 扫描件数 */ @@ -173,11 +145,11 @@ public class DistributionDeliveryListExcel implements Serializable { @ColumnWidth(20) @ExcelProperty("装卸班组") private String loadingTeam; - /** - * 预约表id - */ - @ColumnWidth(20) - @ExcelProperty("预约表id") - private String reservationId; +// /** +// * 预约表id +// */ +// @ColumnWidth(20) +// @ExcelProperty("预约表id") +// private String reservationId; } diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/excel/DistributionReservationExcel.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/excel/DistributionReservationExcel.java index 813edddaa..94227f448 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/excel/DistributionReservationExcel.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/excel/DistributionReservationExcel.java @@ -42,24 +42,44 @@ public class DistributionReservationExcel implements Serializable { private static final long serialVersionUID = 1L; + + /** + * 订单自编号;订单自编号,关联订单表 + */ + @ColumnWidth(20) + @ExcelProperty("预约单编号") + private String reservationCode; + /** + * 订单自编号;订单自编号,关联订单表 + */ + @ColumnWidth(20) + @ExcelProperty("订单号") + private String orderCode; /** - * 租户号 + * 订单自编号;订单自编号,关联订单表 */ @ColumnWidth(20) - @ExcelProperty("租户号") - private String tenantId; + @ExcelProperty("服务号") + private String serviceNumber; /** - * 是否已删除 + * 订单自编号;订单自编号,关联订单表 */ @ColumnWidth(20) - @ExcelProperty("是否已删除") - private Integer isDeleted; + @ExcelProperty("仓库") + private String warehouseName; /** * 订单自编号;订单自编号,关联订单表 */ @ColumnWidth(20) - @ExcelProperty("订单自编号;订单自编号,关联订单表") - private String orderId; + @ExcelProperty("商场") + private String mallName; + /** + * 订单自编号;订单自编号,关联订单表 + */ + @ColumnWidth(20) + @ExcelProperty("门店") + private String storeName; + /** * 收货人 */ @@ -78,18 +98,43 @@ public class DistributionReservationExcel implements Serializable { @ColumnWidth(20) @ExcelProperty("预约时间") private Date reservationData; + /** + * 预约时间 + */ + @ColumnWidth(20) + @ExcelProperty("预约包件数") + private Integer reservationNumber; + /** + * 预约时间 + */ + @ColumnWidth(20) + @ExcelProperty("预约库存品数") + private Integer stockListNumber; + /** + * 预约时间 + */ + @ColumnWidth(20) + @ExcelProperty("待收货款") + private BigDecimal dueSincere; + + /** + * 预约时间 + */ + @ColumnWidth(20) + @ExcelProperty("时段") + private String periodTimeName; /** * 服务类型;预约服务类型;1-上楼、2-超区、3-拆样、4-平移、5-分拣、6-搬运、7-返货; */ @ColumnWidth(20) - @ExcelProperty("服务类型;预约服务类型;1-上楼、2-超区、3-拆样、4-平移、5-分拣、6-搬运、7-返货;") - private String serveType; + @ExcelProperty("服务类型") + private String serveTypeName; /** * 配送方式;预约添加送货方式;1-送货(商配的唯一方式)、2-送货上楼、3-送装一体、4-装 */ @ColumnWidth(20) - @ExcelProperty("配送方式;预约添加送货方式;1-送货(商配的唯一方式)、2-送货上楼、3-送装一体、4-装") - private String deliveryType; + @ExcelProperty("配送方式") + private String deliveryTypeName; /** * 到付运费 */ @@ -107,66 +152,48 @@ public class DistributionReservationExcel implements Serializable { */ @ColumnWidth(20) @ExcelProperty("代付运费") - private String replaceFee; + private BigDecimal replaceFee; /** * 收件人电话 */ @ColumnWidth(20) @ExcelProperty("收件人电话") private String deliveryPhone; +// /** +// * 预约信息状态;预约列表信息状态;1-待确认、2-已确认 +// */ +// @ColumnWidth(20) +// @ExcelProperty("预约信息状态;预约列表信息状态;1-待确认、2-已确认") +// private String resvervationStatus; /** * 预约信息状态;预约列表信息状态;1-待确认、2-已确认 */ @ColumnWidth(20) - @ExcelProperty("预约信息状态;预约列表信息状态;1-待确认、2-已确认") - private String resvervationStatus; - /** - * 订单来源 - */ - @ColumnWidth(20) - @ExcelProperty("订单来源") - private String orderSource; + @ExcelProperty("预约信息状态") + private String resvervationStatusName; +// /** +// * 订单来源 +// */ +// @ColumnWidth(20) +// @ExcelProperty("订单来源") +// private String orderSource; +// /** +// * 备货状态;备货状态;1-未备货、2-待备货、3-已备货 +// */ +// @ColumnWidth(20) +// @ExcelProperty("备货状态") +// private String stockupStatus; /** * 备货状态;备货状态;1-未备货、2-待备货、3-已备货 */ @ColumnWidth(20) - @ExcelProperty("备货状态;备货状态;1-未备货、2-待备货、3-已备货") - private String stockupStatus; - /** - * 备货区编号 - */ - @ColumnWidth(20) - @ExcelProperty("备货区编号") - private String goodsShelfId; - /** - * 预留1 - */ - @ColumnWidth(20) - @ExcelProperty("预留1") - private String reserve1; - /** - * 预留2 - */ - @ColumnWidth(20) - @ExcelProperty("预留2") - private String reserve2; - /** - * 预留3 - */ - @ColumnWidth(20) - @ExcelProperty("预留3") - private String reserve3; - /** - * 预留4 - */ - @ColumnWidth(20) - @ExcelProperty("预留4") - private String reserve4; - /** - * 预留5 - */ - @ColumnWidth(20) - @ExcelProperty("预留5") - private String reserve5; + @ExcelProperty("备货状态") + private String stockupStatusName; +// /** +// * 备货区编号 +// */ +// @ColumnWidth(20) +// @ExcelProperty("备货区编号") +// private String goodsShelfId; } diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionDeliveryListClient.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionDeliveryListClient.java index 18f4d6d18..7271c787b 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionDeliveryListClient.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionDeliveryListClient.java @@ -19,6 +19,8 @@ package com.logpm.distribution.feign; import com.baomidou.mybatisplus.core.metadata.IPage; import com.logpm.distribution.entity.DistributionDeliveryListEntity; import com.logpm.distribution.service.IDistributionDeliveryListService; +import com.logpm.distribution.vo.DistributionDeliveryListVO; +import com.logpm.distribution.vo.DistributionDeliverySelfVO; import lombok.AllArgsConstructor; import org.springblade.core.mp.support.BladePage; import org.springblade.core.mp.support.Condition; @@ -27,6 +29,8 @@ import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RestController; import springfox.documentation.annotations.ApiIgnore; +import java.util.List; + /** * 配送管理 Feign实现类 * @@ -42,7 +46,7 @@ public class DistributionDeliveryListClient implements IDistributionDeliveryList @Override @GetMapping(TOP) - public BladePage top(Integer current, Integer size) { + public BladePage deliveryListTop(Integer current, Integer size) { Query query = new Query(); query.setCurrent(current); query.setSize(size); @@ -50,4 +54,9 @@ public class DistributionDeliveryListClient implements IDistributionDeliveryList return BladePage.of(page); } + @Override + public DistributionDeliveryListVO getDeliveryDriverInfo(Long deliveryId) { + return distributionDeliveryListService.getDeliveryList(deliveryId); + } + } diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionParcelListClient.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionParcelListClient.java index 1d15ec402..e8a8bb27b 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionParcelListClient.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionParcelListClient.java @@ -23,6 +23,7 @@ import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; import com.baomidou.mybatisplus.core.toolkit.Wrappers; import com.logpm.distribution.entity.DistributionParcelListEntity; import com.logpm.distribution.service.IDistributionParcelListService; +import com.logpm.distribution.vo.DistributionParcelListVO; import lombok.AllArgsConstructor; import org.springblade.core.mp.support.BladePage; import org.springblade.core.mp.support.Condition; @@ -172,4 +173,10 @@ public class DistributionParcelListClient implements IDistributionParcelListClie .eq("order_code",orderCode); distributionParcelListService.update(updateWrapper); } + + @Override + @PostMapping(GETPARCELLISTINFO) + public List getParcelListInfo(DistributionParcelListVO parcelListVO) { + return distributionParcelListService.getParcelListInfo(parcelListVO); + } } diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionStockArticleClient.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionStockArticleClient.java index 049aaf615..934f29137 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionStockArticleClient.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionStockArticleClient.java @@ -19,6 +19,8 @@ package com.logpm.distribution.feign; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; +import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; +import com.baomidou.mybatisplus.core.toolkit.Wrappers; import com.logpm.distribution.entity.DistributionParcelListEntity; import com.logpm.distribution.entity.DistributionStockArticleEntity; import com.logpm.distribution.service.IDistributionParcelListService; @@ -191,4 +193,22 @@ public class DistributionStockArticleClient implements IDistributionStockArticle distributionStockArticleService.submitHandleNumByOrderId(subNum,articleId); } + /** + * 查询订单数据 + * @param stockArticleEntity + * @return + */ + @Override + @PostMapping(GETSTOCKARTICLEINFO) + public List getStockArticleInfo(DistributionStockArticleEntity stockArticleEntity) { + return distributionStockArticleService.list(Wrappers.query().lambda() + .eq(DistributionStockArticleEntity::getWarehouseId,stockArticleEntity.getWarehouseId()) + .eq(ObjectUtils.isNotNull(stockArticleEntity.getMallId()),DistributionStockArticleEntity::getMallId,stockArticleEntity.getMallId()) + .eq(ObjectUtils.isNotNull(stockArticleEntity.getId()),DistributionStockArticleEntity::getId,stockArticleEntity.getId()) + .eq(ObjectUtils.isNotNull(stockArticleEntity.getGenre()),DistributionStockArticleEntity::getGenre,stockArticleEntity.getGenre()) + .eq(ObjectUtils.isNotNull(stockArticleEntity.getIsZero()),DistributionStockArticleEntity::getIsZero,stockArticleEntity.getIsZero()) + ); + + } + } diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionStockListClient.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionStockListClient.java index 01ce2518f..a6713755a 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionStockListClient.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionStockListClient.java @@ -173,4 +173,16 @@ public class DistributionStockListClient implements IDistributionStockListClient return distributionStockListService.list(stockListEntityLambdaQueryWrapper); } + /** + * 查询商场库存平 + * + * @param distributionStockListEntity + * @return + */ + @Override + @PostMapping(GETSTOCKLISTINFO) + public List getStockListInfo(DistributionStockListEntity distributionStockListEntity) { + return distributionStockListService.getStockListInfo(distributionStockListEntity); + } + } diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionAddvalueDetailMapper.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionAddvalueDetailMapper.java index 6cc5af367..f06dbdf17 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionAddvalueDetailMapper.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionAddvalueDetailMapper.java @@ -53,7 +53,7 @@ public interface DistributionAddvalueDetailMapper extends BaseMapper - + @@ -27,7 +28,7 @@ - DELETE FROM logpm_distribution_addvalue_detil WHERE addvalue_id = #{addvalueId} + DELETE FROM logpm_distribution_addvalue_detail WHERE addvalue_id = #{addvalueId} @@ -36,7 +37,8 @@ - SELECT * FROM logpm_distribution_addvalue_detail ${ew.customSqlSegment} diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionAddvalueMapper.xml b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionAddvalueMapper.xml index cd9be75a7..c651c45dc 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionAddvalueMapper.xml +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionAddvalueMapper.xml @@ -61,6 +61,7 @@ ldad.num AS num, ldad.flool_num AS floolNum, ldad.distance AS distance, + lda.addvalue_id AS addvalueId, ldad.id AS addvalueDetailId, GROUP_CONCAT(ldap.package_id) AS packageListIds, ldad.record_type AS isAll diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionAddvaluePackageMapper.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionAddvaluePackageMapper.java index 373f0c89b..bc6ce2c25 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionAddvaluePackageMapper.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionAddvaluePackageMapper.java @@ -57,7 +57,7 @@ public interface DistributionAddvaluePackageMapper extends BaseMapper exportDistributionDeliveryList(@Param("ew") Wrapper queryWrapper); + List exportDistributionDeliveryList(@Param("ew") Wrapper queryWrapper); /** * 商配车次 * @@ -410,4 +410,22 @@ public interface DistributionDeliveryListMapper extends BaseMapper selectDeliveryZeroOrderDetail(@Param("orderId") Long orderId,@Param("deliveryListId") Long deliveryId); + + /** + * 查询滞留库存品包件 + * @param stockPackageCode + * @param deliveryId + * @return + */ + DistributionRetentionScanVo selectRetentionInventoryPackage(@Param("stockPackageCode") String stockPackageCode,@Param("deliveryId") Long deliveryId); + + /** + * 查询滞留包件细腻系 + * @param orderPackageCode + * @param deliveryId + * @return + */ + DistributionRetentionScanVo selectRetentionPackage(@Param("orderPackageCode")String orderPackageCode,@Param("deliveryId") Long deliveryId); + + List selectRetentionZeroPackage(@Param("deliveryId")Long deliveryId, @Param("orderCode")String barcode); } diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryListMapper.xml b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryListMapper.xml index 45e9d0c85..e7d213a5a 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryListMapper.xml +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryListMapper.xml @@ -260,7 +260,7 @@ - SELECT * FROM logpm_distribution_delivery_list ${ew.customSqlSegment} + + + diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryTripartiteMapper.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryTripartiteMapper.java index 5d7876912..6128c9a4b 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryTripartiteMapper.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryTripartiteMapper.java @@ -67,4 +67,11 @@ public interface DistributionDeliveryTripartiteMapper extends BaseMapper select id id,driver_name driverName,vehicle_num vehicleNub FROM logpm_distribution_delivery_tripartite where delivery_id = #{deliveryId} + diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionParcelListMapper.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionParcelListMapper.java index 729bc5307..dad2f097c 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionParcelListMapper.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionParcelListMapper.java @@ -117,4 +117,6 @@ public interface DistributionParcelListMapper extends BaseMapper selectorderCodeByLike(@Param("condition") String condition,@Param("collect") List collect); List selectStockListByOderId(@Param("id")Long id,@Param("collect") List collect); + + List getParcelListInfo(@Param("param")DistributionParcelListVO parcelListVO); } diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionParcelListMapper.xml b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionParcelListMapper.xml index b478855fd..1392a7356 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionParcelListMapper.xml +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionParcelListMapper.xml @@ -34,9 +34,79 @@ + + from logpm_distribution_stock_article ldsa + LEFT JOIN logpm_distribution_parcel_list ldpl on ldsa.id = ldpl.stock_article_id + + ldsa.warehouse_id = #{param.warehouseId} and ldpl.order_package_status != '70' + and ldsa.mall_id = #{param.mallId} + and ldsa.genre = #{param.genre} + and ldsa.is_zero = #{param.isZero} + + + + - + SELECT * FROM logpm_distribution_reservation ${ew.customSqlSegment} + diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionStockListMapper.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionStockListMapper.java index 4fb031d6f..a399d0cda 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionStockListMapper.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionStockListMapper.java @@ -102,4 +102,11 @@ public interface DistributionStockListMapper extends BaseMapper selectAllStockList(@Param("par")DistributionStockListDTO stockListDTO); + + /** + * 查询库存平数据 + * @param distributionStockListEntity + * @return + */ + List getStockListInfo(@Param("par")DistributionStockListEntity distributionStockListEntity); } diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionStockListMapper.xml b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionStockListMapper.xml index a2d8476ec..35360436c 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionStockListMapper.xml +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionStockListMapper.xml @@ -93,7 +93,29 @@ select * from logpm_distribution_stock_list where is_deleted = 0 + diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionStockupMapper.xml b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionStockupMapper.xml index d7c346bac..87ede2189 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionStockupMapper.xml +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionStockupMapper.xml @@ -180,14 +180,15 @@ diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistrilbutionBillStockMapper.xml b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistrilbutionBillStockMapper.xml index 4057901cb..6d45ee5f1 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistrilbutionBillStockMapper.xml +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistrilbutionBillStockMapper.xml @@ -114,24 +114,27 @@ SELECT * FROM logpm_distrilbution_bill_stock ${ew.customSqlSegment} + + diff --git a/blade-service/logpm-old-project/src/main/java/com/logpm/oldproject/service/IAdvanceService.java b/blade-service/logpm-old-project/src/main/java/com/logpm/oldproject/service/IAdvanceService.java index da72ac72e..fa3053f58 100644 --- a/blade-service/logpm-old-project/src/main/java/com/logpm/oldproject/service/IAdvanceService.java +++ b/blade-service/logpm-old-project/src/main/java/com/logpm/oldproject/service/IAdvanceService.java @@ -43,4 +43,11 @@ public interface IAdvanceService { List getEntityByMctsTruck(String orderSelfNum, String mctsTruck); + /** + * 根据订单编号和运单号查询老信息的订单信息 + * @param logiBillNo + * @param orderCode + * @return + */ + List findAdvanceEntityByLogiBillNoAndOrderCode(String logiBillNo, String orderCode); } diff --git a/blade-service/logpm-old-project/src/main/java/com/logpm/oldproject/service/impl/AdvanceServiceImpl.java b/blade-service/logpm-old-project/src/main/java/com/logpm/oldproject/service/impl/AdvanceServiceImpl.java index e7a4f153a..2371f9481 100644 --- a/blade-service/logpm-old-project/src/main/java/com/logpm/oldproject/service/impl/AdvanceServiceImpl.java +++ b/blade-service/logpm-old-project/src/main/java/com/logpm/oldproject/service/impl/AdvanceServiceImpl.java @@ -69,4 +69,9 @@ public class AdvanceServiceImpl implements IAdvanceService { public List getEntityByMctsTruck(String orderSelfNum, String mctsTruck) { return advanceMapper.getEntityByMctsTruck(orderSelfNum,mctsTruck); } + + @Override + public List findAdvanceEntityByLogiBillNoAndOrderCode(String logiBillNo, String orderCode) { + return advanceMapper.findAdvanceEntityByLogiBillNoAndOrderCode(logiBillNo,orderCode); + } } diff --git a/blade-service/logpm-patch/src/main/java/com/logpm/patch/service/impl/SyncOrderInfoServiceImpl.java b/blade-service/logpm-patch/src/main/java/com/logpm/patch/service/impl/SyncOrderInfoServiceImpl.java index d9c0d990f..8642ad92f 100644 --- a/blade-service/logpm-patch/src/main/java/com/logpm/patch/service/impl/SyncOrderInfoServiceImpl.java +++ b/blade-service/logpm-patch/src/main/java/com/logpm/patch/service/impl/SyncOrderInfoServiceImpl.java @@ -246,7 +246,7 @@ public class SyncOrderInfoServiceImpl implements ISyncOrderInfoService { @Override public void supplementOrderInfo(String orderCode, Long newWarehouseId, Integer oldWarehouseId) { //通过订单号查询暂存单 - AdvanceEntity advanceEntity = advanceClient.getQueryDataOne(orderCode); + AdvanceEntity advanceEntity = advanceClient.getQueryDataOne(orderCode);//这个地方有问题 if(Objects.isNull(advanceEntity)){ log.warn("#################saveOrderInfo: 未查询单订单信息 orderCode={}",orderCode); throw new CustomerException(403,"未查询单订单信息"); diff --git a/blade-service/logpm-trunkline/pom.xml b/blade-service/logpm-trunkline/pom.xml index fbd20888c..b6a118986 100644 --- a/blade-service/logpm-trunkline/pom.xml +++ b/blade-service/logpm-trunkline/pom.xml @@ -39,6 +39,12 @@ 3.2.0.RELEASE compile + + org.springblade + logpm-basicdata-api + 3.2.0.RELEASE + compile + diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/controller/BillladingController.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/controller/BillladingController.java new file mode 100644 index 000000000..4b89ad954 --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/controller/BillladingController.java @@ -0,0 +1,61 @@ +package com.logpm.trunkline.controller; + +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; +import com.logpm.basicdata.entity.BasicdataWarehouseEntity; +import com.logpm.basicdata.feign.IBasicdataWarehouseClient; +import com.logpm.trunkline.dto.BillladingDTO; +import com.logpm.trunkline.service.ITrunklineBillladingService; +import com.logpm.trunkline.vo.TrunklineBillladingVO; +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.common.exception.CustomerException; +import org.springblade.core.tool.api.R; +import org.springframework.web.bind.annotation.*; + +import java.util.Objects; + +@Slf4j +@RestController +@AllArgsConstructor +@RequestMapping("/billlading") +@Api(value = "提货单控制类", tags = "提货单接口") +public class BillladingController { + + private final IBasicdataWarehouseClient warehouseClient; + + private final ITrunklineBillladingService trunklineBillladingService; + + @ResponseBody + @PostMapping("/pageList") + @ApiOperationSupport(order = 1) + @ApiOperation(value = "提货单列表", notes = "传入waybillDTO") + public R pageList(@RequestBody BillladingDTO billladingDTO) { + String method = "############pageList: "; + log.info(method+"请求参数{}",billladingDTO); + try{ + + //当前登录人选择的仓库 + BasicdataWarehouseEntity myCurrentWarehouse = warehouseClient.getMyCurrentWarehouse(); + if(Objects.isNull(myCurrentWarehouse)){ + log.warn(method+"仓库信息为空 myCurrentWarehouse={}",myCurrentWarehouse); + return R.fail(403,"仓库信息为空"); + } + billladingDTO.setWarehouseId(myCurrentWarehouse.getId()); + + IPage pages = trunklineBillladingService.pageList(billladingDTO); + + return R.data(pages); + }catch (CustomerException e){ + log.error(e.message,e); + return R.fail(e.code,e.message); + }catch (Exception e){ + log.error("############sendOrders: 系统异常",e); + return R.fail(500,"############sendOrders: 系统异常"); + } + } + + +} diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineAdvanceDetailMapper.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineAdvanceDetailMapper.java new file mode 100644 index 000000000..bb1f80689 --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineAdvanceDetailMapper.java @@ -0,0 +1,9 @@ +package com.logpm.trunkline.mapper; + +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.logpm.trunkline.entity.TrunklineAdvanceDetailEntity; +import org.apache.ibatis.annotations.Mapper; + +@Mapper +public interface TrunklineAdvanceDetailMapper extends BaseMapper { +} diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineAdvanceDetailMapper.xml b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineAdvanceDetailMapper.xml new file mode 100644 index 000000000..7494f0b97 --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineAdvanceDetailMapper.xml @@ -0,0 +1,6 @@ + + + + + + diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineAdvanceMapper.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineAdvanceMapper.java new file mode 100644 index 000000000..21c3207d8 --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineAdvanceMapper.java @@ -0,0 +1,9 @@ +package com.logpm.trunkline.mapper; + +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.logpm.trunkline.entity.TrunklineAdvanceEntity; +import org.apache.ibatis.annotations.Mapper; + +@Mapper +public interface TrunklineAdvanceMapper extends BaseMapper { +} diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineAdvanceMapper.xml b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineAdvanceMapper.xml new file mode 100644 index 000000000..f4ae64abc --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineAdvanceMapper.xml @@ -0,0 +1,6 @@ + + + + + + diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingLineMapper.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingLineMapper.java new file mode 100644 index 000000000..8e7b5fcab --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingLineMapper.java @@ -0,0 +1,9 @@ +package com.logpm.trunkline.mapper; + +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.logpm.trunkline.entity.TrunklineBillladingLineEntity; +import org.apache.ibatis.annotations.Mapper; + +@Mapper +public interface TrunklineBillladingLineMapper extends BaseMapper { +} diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingLineMapper.xml b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingLineMapper.xml new file mode 100644 index 000000000..b9de6ea86 --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingLineMapper.xml @@ -0,0 +1,6 @@ + + + + + + diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingMapper.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingMapper.java new file mode 100644 index 000000000..388a861f6 --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingMapper.java @@ -0,0 +1,16 @@ +package com.logpm.trunkline.mapper; + +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.logpm.trunkline.dto.BillladingDTO; +import com.logpm.trunkline.entity.TrunklineBillladingEntity; +import com.logpm.trunkline.vo.TrunklineBillladingVO; +import org.apache.ibatis.annotations.Mapper; +import org.apache.ibatis.annotations.Param; + +@Mapper +public interface TrunklineBillladingMapper extends BaseMapper { + + IPage pageList(IPage page, @Param("param") BillladingDTO billladingDTO); + +} diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingMapper.xml b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingMapper.xml new file mode 100644 index 000000000..242b9e754 --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingMapper.xml @@ -0,0 +1,78 @@ + + + + + + + diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingPackageMapper.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingPackageMapper.java new file mode 100644 index 000000000..ebe6c39c3 --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingPackageMapper.java @@ -0,0 +1,9 @@ +package com.logpm.trunkline.mapper; + +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.logpm.trunkline.entity.TrunklineBillladingPackageEntity; +import org.apache.ibatis.annotations.Mapper; + +@Mapper +public interface TrunklineBillladingPackageMapper extends BaseMapper { +} diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingPackageMapper.xml b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingPackageMapper.xml new file mode 100644 index 000000000..4d08ed327 --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingPackageMapper.xml @@ -0,0 +1,6 @@ + + + + + + diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingWaybillMapper.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingWaybillMapper.java new file mode 100644 index 000000000..258a45cef --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingWaybillMapper.java @@ -0,0 +1,9 @@ +package com.logpm.trunkline.mapper; + +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.logpm.trunkline.entity.TrunklineBillladingWaybillEntity; +import org.apache.ibatis.annotations.Mapper; + +@Mapper +public interface TrunklineBillladingWaybillMapper extends BaseMapper { +} diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingWaybillMapper.xml b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingWaybillMapper.xml new file mode 100644 index 000000000..a69a47ee8 --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingWaybillMapper.xml @@ -0,0 +1,6 @@ + + + + + + diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineDetailProductMapper.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineDetailProductMapper.java new file mode 100644 index 000000000..8e14bd93a --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineDetailProductMapper.java @@ -0,0 +1,9 @@ +package com.logpm.trunkline.mapper; + +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.logpm.trunkline.entity.TrunklineDetailProductEntity; +import org.apache.ibatis.annotations.Mapper; + +@Mapper +public interface TrunklineDetailProductMapper extends BaseMapper { +} diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineDetailProductMapper.xml b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineDetailProductMapper.xml new file mode 100644 index 000000000..a82c370dc --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineDetailProductMapper.xml @@ -0,0 +1,6 @@ + + + + + + diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineAdvanceDetailService.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineAdvanceDetailService.java new file mode 100644 index 000000000..688a20d52 --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineAdvanceDetailService.java @@ -0,0 +1,7 @@ +package com.logpm.trunkline.service; + +import com.logpm.trunkline.entity.TrunklineAdvanceDetailEntity; +import org.springblade.core.mp.base.BaseService; + +public interface ITrunklineAdvanceDetailService extends BaseService { +} diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineAdvanceService.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineAdvanceService.java new file mode 100644 index 000000000..9f0ac58cb --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineAdvanceService.java @@ -0,0 +1,7 @@ +package com.logpm.trunkline.service; + +import com.logpm.trunkline.entity.TrunklineAdvanceEntity; +import org.springblade.core.mp.base.BaseService; + +public interface ITrunklineAdvanceService extends BaseService { +} diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineBillladingLineService.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineBillladingLineService.java new file mode 100644 index 000000000..a402f8ca1 --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineBillladingLineService.java @@ -0,0 +1,7 @@ +package com.logpm.trunkline.service; + +import com.logpm.trunkline.entity.TrunklineBillladingLineEntity; +import org.springblade.core.mp.base.BaseService; + +public interface ITrunklineBillladingLineService extends BaseService { +} diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineBillladingPackageServicie.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineBillladingPackageServicie.java new file mode 100644 index 000000000..5ffb10433 --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineBillladingPackageServicie.java @@ -0,0 +1,7 @@ +package com.logpm.trunkline.service; + +import com.logpm.trunkline.entity.TrunklineBillladingPackageEntity; +import org.springblade.core.mp.base.BaseService; + +public interface ITrunklineBillladingPackageServicie extends BaseService { +} diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineBillladingService.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineBillladingService.java new file mode 100644 index 000000000..468e57250 --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineBillladingService.java @@ -0,0 +1,13 @@ +package com.logpm.trunkline.service; + +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.logpm.trunkline.dto.BillladingDTO; +import com.logpm.trunkline.entity.TrunklineBillladingEntity; +import com.logpm.trunkline.vo.TrunklineBillladingVO; +import org.springblade.core.mp.base.BaseService; + +public interface ITrunklineBillladingService extends BaseService { + + IPage pageList(BillladingDTO billladingDTO); + +} diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineBillladingWaybillService.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineBillladingWaybillService.java new file mode 100644 index 000000000..a94f4ab97 --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineBillladingWaybillService.java @@ -0,0 +1,7 @@ +package com.logpm.trunkline.service; + +import com.logpm.trunkline.entity.TrunklineBillladingWaybillEntity; +import org.springblade.core.mp.base.BaseService; + +public interface ITrunklineBillladingWaybillService extends BaseService { +} diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineDetailProductService.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineDetailProductService.java new file mode 100644 index 000000000..8fcf8d12e --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineDetailProductService.java @@ -0,0 +1,7 @@ +package com.logpm.trunkline.service; + +import com.logpm.trunkline.entity.TrunklineDetailProductEntity; +import org.springblade.core.mp.base.BaseService; + +public interface ITrunklineDetailProductService extends BaseService { +} diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineAdvanceDetailServiceImpl.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineAdvanceDetailServiceImpl.java new file mode 100644 index 000000000..dc14d9058 --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineAdvanceDetailServiceImpl.java @@ -0,0 +1,15 @@ +package com.logpm.trunkline.service.impl; + +import com.logpm.trunkline.entity.TrunklineAdvanceDetailEntity; +import com.logpm.trunkline.mapper.TrunklineAdvanceDetailMapper; +import com.logpm.trunkline.service.ITrunklineAdvanceDetailService; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springframework.stereotype.Service; + +@Slf4j +@Service +@AllArgsConstructor +public class TrunklineAdvanceDetailServiceImpl extends BaseServiceImpl implements ITrunklineAdvanceDetailService { +} diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineAdvanceServiceImpl.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineAdvanceServiceImpl.java new file mode 100644 index 000000000..58a87899f --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineAdvanceServiceImpl.java @@ -0,0 +1,15 @@ +package com.logpm.trunkline.service.impl; + +import com.logpm.trunkline.entity.TrunklineAdvanceEntity; +import com.logpm.trunkline.mapper.TrunklineAdvanceMapper; +import com.logpm.trunkline.service.ITrunklineAdvanceService; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springframework.stereotype.Service; + +@Slf4j +@Service +@AllArgsConstructor +public class TrunklineAdvanceServiceImpl extends BaseServiceImpl implements ITrunklineAdvanceService { +} diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineBillladingLineServiceImpl.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineBillladingLineServiceImpl.java new file mode 100644 index 000000000..f99f463c6 --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineBillladingLineServiceImpl.java @@ -0,0 +1,15 @@ +package com.logpm.trunkline.service.impl; + +import com.logpm.trunkline.entity.TrunklineBillladingLineEntity; +import com.logpm.trunkline.mapper.TrunklineBillladingLineMapper; +import com.logpm.trunkline.service.ITrunklineBillladingLineService; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springframework.stereotype.Service; + +@Slf4j +@AllArgsConstructor +@Service +public class TrunklineBillladingLineServiceImpl extends BaseServiceImpl implements ITrunklineBillladingLineService { +} diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineBillladingPackageServiceImpl.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineBillladingPackageServiceImpl.java new file mode 100644 index 000000000..cc968333e --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineBillladingPackageServiceImpl.java @@ -0,0 +1,15 @@ +package com.logpm.trunkline.service.impl; + +import com.logpm.trunkline.entity.TrunklineBillladingPackageEntity; +import com.logpm.trunkline.mapper.TrunklineBillladingPackageMapper; +import com.logpm.trunkline.service.ITrunklineBillladingPackageServicie; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springframework.stereotype.Service; + +@Slf4j +@Service +@AllArgsConstructor +public class TrunklineBillladingPackageServiceImpl extends BaseServiceImpl implements ITrunklineBillladingPackageServicie { +} diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineBillladingServiceImpl.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineBillladingServiceImpl.java new file mode 100644 index 000000000..95f0ac8db --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineBillladingServiceImpl.java @@ -0,0 +1,30 @@ +package com.logpm.trunkline.service.impl; + +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.baomidou.mybatisplus.extension.plugins.pagination.Page; +import com.logpm.trunkline.dto.BillladingDTO; +import com.logpm.trunkline.entity.TrunklineBillladingEntity; +import com.logpm.trunkline.mapper.TrunklineBillladingMapper; +import com.logpm.trunkline.service.ITrunklineBillladingService; +import com.logpm.trunkline.vo.TrunklineBillladingVO; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springframework.stereotype.Service; + +@Slf4j +@Service +@AllArgsConstructor +public class TrunklineBillladingServiceImpl extends BaseServiceImpl implements ITrunklineBillladingService { + + @Override + public IPage pageList(BillladingDTO billladingDTO) { + IPage page = new Page<>(); + page.setCurrent(billladingDTO.getPageNum()); + page.setSize(billladingDTO.getPageSize()); + + IPage pageList = baseMapper.pageList(page,billladingDTO); + + return null; + } +} diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineBillladingWaybillServiceImpl.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineBillladingWaybillServiceImpl.java new file mode 100644 index 000000000..c50f7c4b0 --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineBillladingWaybillServiceImpl.java @@ -0,0 +1,15 @@ +package com.logpm.trunkline.service.impl; + +import com.logpm.trunkline.entity.TrunklineBillladingWaybillEntity; +import com.logpm.trunkline.mapper.TrunklineBillladingWaybillMapper; +import com.logpm.trunkline.service.ITrunklineBillladingWaybillService; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springframework.stereotype.Service; + +@Slf4j +@Service +@AllArgsConstructor +public class TrunklineBillladingWaybillServiceImpl extends BaseServiceImpl implements ITrunklineBillladingWaybillService { +} diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineDetailProductServiceImpl.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineDetailProductServiceImpl.java new file mode 100644 index 000000000..ff3578623 --- /dev/null +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineDetailProductServiceImpl.java @@ -0,0 +1,15 @@ +package com.logpm.trunkline.service.impl; + +import com.logpm.trunkline.entity.TrunklineDetailProductEntity; +import com.logpm.trunkline.mapper.TrunklineDetailProductMapper; +import com.logpm.trunkline.service.ITrunklineDetailProductService; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springframework.stereotype.Service; + +@Slf4j +@Service +@AllArgsConstructor +public class TrunklineDetailProductServiceImpl extends BaseServiceImpl implements ITrunklineDetailProductService { +} diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/api/WarehouseRetentionApiController.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/api/WarehouseRetentionApiController.java index 46a924e3c..44ac0c11b 100644 --- a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/api/WarehouseRetentionApiController.java +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/api/WarehouseRetentionApiController.java @@ -1,8 +1,10 @@ package com.logpm.warehouse.api; import com.baomidou.mybatisplus.core.metadata.IPage; +import com.baomidou.mybatisplus.core.toolkit.Wrappers; import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; import com.logpm.warehouse.dto.RetentionDTO; +import com.logpm.warehouse.entity.WarehouseRetentionRecordEntity; import com.logpm.warehouse.service.IWarehouseRetentionRecordService; import com.logpm.warehouse.vo.WarehouseRetentionRecordVO; import io.swagger.annotations.Api; @@ -11,6 +13,7 @@ import lombok.AllArgsConstructor; import lombok.extern.log4j.Log4j2; import org.springblade.common.exception.CustomerException; import org.springblade.core.tool.api.R; +import org.springblade.core.tool.utils.Func; import org.springblade.core.tool.utils.StringUtil; import org.springframework.web.bind.annotation.*; @@ -25,60 +28,118 @@ public class WarehouseRetentionApiController { private final IWarehouseRetentionRecordService warehouseRetentionRecordService; + @ResponseBody @PostMapping("/retentionPackageList") @ApiOperationSupport(order = 1) @ApiOperation(value = "滞留包件列表", notes = "传入trayTypeDTO") public R> retentionPackageList(@RequestBody RetentionDTO retentionDTO) { String method = "###########retentionPackageList: "; - log.info(method+"滞留包件列表 retentionDTO={}",retentionDTO); + log.info(method + "滞留包件列表 retentionDTO={}", retentionDTO); Integer pageNum = retentionDTO.getPageNum(); Integer pageSize = retentionDTO.getPageSize(); - if(Objects.isNull(pageNum)){ + if (Objects.isNull(pageNum)) { retentionDTO.setPageNum(1); } - if(Objects.isNull(pageSize)){ + if (Objects.isNull(pageSize)) { retentionDTO.setPageSize(10); } - try{ + try { //查询订制品打托列表 IPage pages = warehouseRetentionRecordService.retentionPackageList(retentionDTO); return R.data(pages); - }catch (CustomerException e){ + } catch (CustomerException e) { log.warn(e.message); - return R.fail(e.code,e.message); - }catch (Exception e){ - log.error(method+"系统异常,联系管理员",e); - return R.fail(500,"系统异常,联系管理员"); + return R.fail(e.code, e.message); + } catch (Exception e) { + log.error(method + "系统异常,联系管理员", e); + return R.fail(500, "系统异常,联系管理员"); } } - @ResponseBody - @PostMapping("/retentionScanPackage") + // @GetMapping + @GetMapping("/initRetentionList") @ApiOperationSupport(order = 1) - @ApiOperation(value = "滞留扫描包件码", notes = "传入trayTypeDTO") - public R retentionScanPackage(@RequestBody RetentionDTO retentionDTO) { - String method = "###########retentionScanPackage: "; - log.info(method + "滞留扫描包件码 retentionDTO={}", retentionDTO); - String orderPackageCode = retentionDTO.getOrderPackageCode();//包件码 - try{ - if(StringUtil.isBlank(orderPackageCode)){ - log.warn("############retentionScanPackage: 包件码不能为空 orderPackageCode={}",orderPackageCode); - return R.fail(403,"包件码不能为空"); - } + @ApiOperation(value = "初始化滞留车次信息", notes = "传入trayTypeDTO") + public R initRetentionList(@RequestParam Long deliveryId) { + WarehouseRetentionRecordVO warehouseRetentionRecordVO = warehouseRetentionRecordService.initRetentionList(deliveryId); + return R.data(warehouseRetentionRecordVO); + } - //查询订制品打托列表 - return warehouseRetentionRecordService.retentionScanPackage(orderPackageCode); - }catch (CustomerException e){ - log.warn(e.message); - return R.fail(e.code,e.message); - }catch (Exception e){ - log.error(method+"系统异常,联系管理员",e); - return R.fail(500,"系统异常,联系管理员"); - } + @PostMapping("/saveRetentionList") + @ApiOperationSupport(order = 1) + @ApiOperation(value = "保存滞留扫描列表", notes = "传入trayTypeDTO") + public R saveRetentionList(@RequestBody RetentionDTO retentionDTO) { + R r = warehouseRetentionRecordService.saveRetentionList(retentionDTO); + return r; } + + +// @GetMapping("/initRetentionList") +// @ApiOperationSupport(order = 1) +// @ApiOperation(value = "初始化滞留车次信息", notes = "传入trayTypeDTO") +// public R initRetentionList(@RequestParam Long deliveryId) { +// WarehouseRetentionRecordVO warehouseRetentionRecordVO = warehouseRetentionRecordService.initRetentionList(deliveryId); +// return R.data(warehouseRetentionRecordVO); +// } + + +// +// +// @ResponseBody +// @PostMapping("/retentionScanPackage") +// @ApiOperationSupport(order = 1) +// @ApiOperation(value = "滞留扫描包件码", notes = "传入trayTypeDTO") +// public R retentionScanPackage(@RequestBody RetentionDTO retentionDTO) { +// String method = "###########retentionScanPackage: "; +// log.info(method + "滞留扫描包件码 retentionDTO={}", retentionDTO); +// String orderPackageCode = retentionDTO.getOrderPackageCode();//包件码 +// try{ +// if(StringUtil.isBlank(orderPackageCode)){ +// log.warn("############retentionScanPackage: 包件码不能为空 orderPackageCode={}",orderPackageCode); +// return R.fail(403,"包件码不能为空"); +// } +// +// //查询订制品打托列表 +// return warehouseRetentionRecordService.retentionScanPackage(orderPackageCode); +// }catch (CustomerException e){ +// log.warn(e.message); +// return R.fail(e.code,e.message); +// }catch (Exception e){ +// log.error(method+"系统异常,联系管理员",e); +// return R.fail(500,"系统异常,联系管理员"); +// } +// } + + +// @ResponseBody +// @PostMapping("/retentionScanPackage") +// @ApiOperationSupport(order = 1) +// @ApiOperation(value = "滞留扫描包件码", notes = "传入trayTypeDTO") +// public R retentionScanPackage(@RequestBody RetentionDTO retentionDTO) { +// String method = "###########retentionScanPackage: "; +// log.info(method + "滞留扫描包件码 retentionDTO={}", retentionDTO); +// String orderPackageCode = retentionDTO.getOrderPackageCode();//包件码 +// try{ +// if(StringUtil.isBlank(orderPackageCode)){ +// log.warn("############retentionScanPackage: 包件码不能为空 orderPackageCode={}",orderPackageCode); +// return R.fail(403,"包件码不能为空"); +// } +// +// //查询订制品打托列表 +// return warehouseRetentionRecordService.retentionScanPackage(orderPackageCode); +// }catch (CustomerException e){ +// log.warn(e.message); +// return R.fail(e.code,e.message); +// }catch (Exception e){ +// log.error(method+"系统异常,联系管理员",e); +// return R.fail(500,"系统异常,联系管理员"); +// } +// } + + } diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/controller/WarehouseRetentionScanController.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/controller/WarehouseRetentionScanController.java new file mode 100644 index 000000000..7a8fc93aa --- /dev/null +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/controller/WarehouseRetentionScanController.java @@ -0,0 +1,154 @@ +/* + * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * Neither the name of the dreamlu.net developer nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * Author: Chill 庄骞 (smallchill@163.com) + */ +package com.logpm.warehouse.controller; + +import com.logpm.warehouse.entity.WarehouseRetentionScanEntity; +import com.logpm.warehouse.excel.WarehouseRetentionScanExcel; +import com.logpm.warehouse.service.IWarehouseRetentionScanService; +import com.logpm.warehouse.vo.WarehouseRetentionScanVO; +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import io.swagger.annotations.ApiParam; +import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; +import lombok.AllArgsConstructor; +import javax.validation.Valid; + +import org.springblade.core.secure.BladeUser; +import org.springblade.core.mp.support.Condition; +import org.springblade.core.mp.support.Query; +import org.springblade.core.tool.api.R; +import org.springblade.core.tool.utils.Func; +import org.springframework.web.bind.annotation.*; +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.logpm.warehouse.entity.WarehouseRetentionRecordEntity; +import com.logpm.warehouse.vo.WarehouseRetentionRecordVO; +import com.logpm.warehouse.excel.WarehouseRetentionRecordExcel; +import com.logpm.warehouse.service.IWarehouseRetentionRecordService; +import org.springblade.core.boot.ctrl.BladeController; +import org.springblade.core.tool.utils.DateUtil; +import org.springblade.core.excel.util.ExcelUtil; +import org.springblade.core.tool.constant.BladeConstant; +import springfox.documentation.annotations.ApiIgnore; +import java.util.Map; +import java.util.List; +import javax.servlet.http.HttpServletResponse; + +/** + * 滞留扫描记录 控制器 + * + * @author BladeX + * @since 2023-11-03 + */ +@RestController +@AllArgsConstructor +@RequestMapping("/warehouseRetentionScan") +@Api(value = "滞留扫描记录", tags = "滞留扫描记录接口") +public class WarehouseRetentionScanController extends BladeController { + + private final IWarehouseRetentionScanService warehouseRetentionScanService; + + /** + * 滞留扫描记录 详情 + */ + @GetMapping("/detail") + @ApiOperationSupport(order = 1) + @ApiOperation(value = "详情", notes = "传入warehouseRetentionScan") + public R detail(WarehouseRetentionScanEntity warehouseRetentionScan) { + WarehouseRetentionScanEntity detail = warehouseRetentionScanService.getOne(Condition.getQueryWrapper(warehouseRetentionScan)); + return R.data(detail); + } + /** + * 滞留扫描记录 分页 + */ + @GetMapping("/list") + @ApiOperationSupport(order = 2) + @ApiOperation(value = "分页", notes = "传入warehouseRetentionScan") + public R> list(@ApiIgnore @RequestParam Map warehouseRetentionScan, Query query) { + IPage pages = warehouseRetentionScanService.page(Condition.getPage(query), Condition.getQueryWrapper(warehouseRetentionScan, WarehouseRetentionScanEntity.class)); + return R.data(pages); + } + + /** + * 滞留扫描记录 自定义分页 + */ + @GetMapping("/page") + @ApiOperationSupport(order = 3) + @ApiOperation(value = "分页", notes = "传入warehouseRetentionScan") + public R> page(WarehouseRetentionScanVO warehouseRetentionScan, Query query) { + IPage pages = warehouseRetentionScanService.selectWarehouseRetentionRecordPage(Condition.getPage(query), warehouseRetentionScan); + return R.data(pages); + } + + /** + * 滞留扫描记录 新增 + */ + @PostMapping("/save") + @ApiOperationSupport(order = 4) + @ApiOperation(value = "新增", notes = "传入warehouseRetentionScan") + public R save(@Valid @RequestBody WarehouseRetentionScanEntity warehouseRetentionScan) { + return R.status(warehouseRetentionScanService.save(warehouseRetentionScan)); + } + + /** + * 滞留扫描记录 修改 + */ + @PostMapping("/update") + @ApiOperationSupport(order = 5) + @ApiOperation(value = "修改", notes = "传入warehouseRetentionScan") + public R update(@Valid @RequestBody WarehouseRetentionScanEntity warehouseRetentionScan) { + return R.status(warehouseRetentionScanService.updateById(warehouseRetentionScan)); + } + + /** + * 滞留扫描记录 新增或修改 + */ + @PostMapping("/submit") + @ApiOperationSupport(order = 6) + @ApiOperation(value = "新增或修改", notes = "传入warehouseRetentionScan") + public R submit(@Valid @RequestBody WarehouseRetentionScanEntity warehouseRetentionScan) { + return R.status(warehouseRetentionScanService.saveOrUpdate(warehouseRetentionScan)); + } + + /** + * 滞留扫描记录 删除 + */ + @PostMapping("/remove") + @ApiOperationSupport(order = 7) + @ApiOperation(value = "删除", notes = "传入ids") + public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) { + return R.status(warehouseRetentionScanService.removeByIds(Func.toLongList(ids))); + } + + + /** + * 导出数据 + */ + @GetMapping("/export-warehouseRetentionScan") + @ApiOperationSupport(order = 9) + @ApiOperation(value = "导出数据", notes = "传入warehouseRetentionScan") + public void exportWarehouseRetentionScan(@ApiIgnore @RequestParam Map warehouseRetentionScan, BladeUser bladeUser, HttpServletResponse response) { + QueryWrapper queryWrapper = Condition.getQueryWrapper(warehouseRetentionScan, WarehouseRetentionScanEntity.class); + //if (!AuthUtil.isAdministrator()) { + // queryWrapper.lambda().eq(WarehouseRetentionScan::getTenantId, bladeUser.getTenantId()); + //} + queryWrapper.lambda().eq(WarehouseRetentionScanEntity::getIsDeleted, BladeConstant.DB_NOT_DELETED); + List list = warehouseRetentionScanService.exportWarehouseRetentionRecord(queryWrapper); + ExcelUtil.export(response, "滞留扫描记录数据" + DateUtil.time(), "滞留扫描记录数据表", list, WarehouseRetentionScanExcel.class); + } + +} diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/QuestDetailDTO.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/QuestDetailDTO.java index aa05b1f5a..668fbe006 100644 --- a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/QuestDetailDTO.java +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/QuestDetailDTO.java @@ -44,7 +44,7 @@ public class QuestDetailDTO extends QuestDetailEntity { private Integer noReceivedNum;//未入库数量 - private Long allocationId;//上架后的库位id + private String allocationId;//上架后的库位id } diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/RetentionDTO.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/RetentionDTO.java index d1ed25541..eeef525c9 100644 --- a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/RetentionDTO.java +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/RetentionDTO.java @@ -1,8 +1,13 @@ package com.logpm.warehouse.dto; +import com.logpm.distribution.entity.DisStockListDetailEntity; +import com.logpm.distribution.entity.DistributionParcelListEntity; +import com.logpm.distribution.entity.DistributionParcelNumberEntity; +import com.logpm.distribution.vo.DistributionParcelListVO; import lombok.Data; import java.io.Serializable; +import java.util.List; @Data public class RetentionDTO implements Serializable { @@ -15,4 +20,21 @@ public class RetentionDTO implements Serializable { private String orderPackageCode; + /** + * 配送任务ID + */ + private Long deliveryId; + + /** + * 配送任务ID + */ + private String remarks; + + + private List parcelListEntityList; + + private List parcelNumberEntityList; + + private List detailEntityList; + } diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/RetentionDistributionListDetailDTO.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/RetentionDistributionListDetailDTO.java new file mode 100644 index 000000000..3be7d0ec1 --- /dev/null +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/RetentionDistributionListDetailDTO.java @@ -0,0 +1,14 @@ +package com.logpm.warehouse.dto; + +import com.logpm.distribution.entity.DisStockListDetailEntity; +import lombok.Data; +import lombok.EqualsAndHashCode; + +@Data +@EqualsAndHashCode(callSuper = true) +public class RetentionDistributionListDetailDTO extends DisStockListDetailEntity { + + private String MaterialName; + + private String materialNumber; +} diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/RetentionParcelListDTO.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/RetentionParcelListDTO.java new file mode 100644 index 000000000..d6ddbdfae --- /dev/null +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/RetentionParcelListDTO.java @@ -0,0 +1,11 @@ +package com.logpm.warehouse.dto; + +import com.logpm.distribution.entity.DistributionParcelListEntity; +import lombok.Data; +import lombok.EqualsAndHashCode; + + +@Data +@EqualsAndHashCode(callSuper = true) +public class RetentionParcelListDTO extends DistributionParcelListEntity { +} diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/RetentionZeroParcelDTO.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/RetentionZeroParcelDTO.java new file mode 100644 index 000000000..3d13caac6 --- /dev/null +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/RetentionZeroParcelDTO.java @@ -0,0 +1,10 @@ +package com.logpm.warehouse.dto; + +import com.logpm.distribution.entity.DistributionParcelNumberEntity; +import lombok.Data; +import lombok.EqualsAndHashCode; + +@Data +@EqualsAndHashCode(callSuper = true) +public class RetentionZeroParcelDTO extends DistributionParcelNumberEntity { +} diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/TaskSearchDTO.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/TaskSearchDTO.java index b802f21ad..49f0a6f6d 100644 --- a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/TaskSearchDTO.java +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/TaskSearchDTO.java @@ -41,6 +41,8 @@ public class TaskSearchDTO { @ApiModelProperty(value = "任务id") private Long questId; + @ApiModelProperty(value = "任务编号") + private String questNum; @ApiModelProperty(value = "搜索code") private String code; @@ -83,9 +85,9 @@ public class TaskSearchDTO { private String goodsType; /** - * goodsType 合同号类型 + * 任务ID */ - @ApiModelProperty(value = "合同号类型; 1- 订制品、 2- 零担、3- 库存品") + @ApiModelProperty(value = "任务ID") private Long taskId; /** diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/WarehouseRetentionScanDTO.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/WarehouseRetentionScanDTO.java new file mode 100644 index 000000000..e3347140f --- /dev/null +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/WarehouseRetentionScanDTO.java @@ -0,0 +1,34 @@ +/* + * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * Neither the name of the dreamlu.net developer nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * Author: Chill 庄骞 (smallchill@163.com) + */ +package com.logpm.warehouse.dto; + +import com.logpm.warehouse.entity.WarehouseRetentionScanEntity; +import lombok.Data; +import lombok.EqualsAndHashCode; + +/** + * 滞留扫描记录 数据传输对象实体类 + * + * @author BladeX + * @since 2023-11-03 + */ +@Data +@EqualsAndHashCode(callSuper = true) +public class WarehouseRetentionScanDTO extends WarehouseRetentionScanEntity { + private static final long serialVersionUID = 1L; + +} diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/excel/WarehouseRetentionScanExcel.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/excel/WarehouseRetentionScanExcel.java new file mode 100644 index 000000000..953bed997 --- /dev/null +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/excel/WarehouseRetentionScanExcel.java @@ -0,0 +1,201 @@ +/* + * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * Neither the name of the dreamlu.net developer nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * Author: Chill 庄骞 (smallchill@163.com) + */ +package com.logpm.warehouse.excel; + + +import lombok.Data; + +import java.util.Date; +import com.alibaba.excel.annotation.ExcelProperty; +import com.alibaba.excel.annotation.write.style.ColumnWidth; +import com.alibaba.excel.annotation.write.style.ContentRowHeight; +import com.alibaba.excel.annotation.write.style.HeadRowHeight; +import java.io.Serializable; + + +/** + * 滞留扫描记录 Excel实体类 + * + * @author BladeX + * @since 2023-11-03 + */ +@Data +@ColumnWidth(25) +@HeadRowHeight(20) +@ContentRowHeight(18) +public class WarehouseRetentionScanExcel implements Serializable { + + private static final long serialVersionUID = 1L; + + /** + * 租户号 + */ + @ColumnWidth(20) + @ExcelProperty("租户号") + private String tenantId; + /** + * 是否已删除 + */ + @ColumnWidth(20) + @ExcelProperty("是否已删除") + private Integer isDeleted; + /** + * 预留1 + */ + @ColumnWidth(20) + @ExcelProperty("预留1") + private String reserve1; + /** + * 预留2 + */ + @ColumnWidth(20) + @ExcelProperty("预留2") + private String reserve2; + /** + * 预留3 + */ + @ColumnWidth(20) + @ExcelProperty("预留3") + private String reserve3; + /** + * 预留4 + */ + @ColumnWidth(20) + @ExcelProperty("预留4") + private String reserve4; + /** + * 预留5 + */ + @ColumnWidth(20) + @ExcelProperty("预留5") + private String reserve5; + /** + * 配送车次号 + */ + @ColumnWidth(20) + @ExcelProperty("配送车次号") + private String trainNumber; + /** + * 订单ID + */ + @ColumnWidth(20) + @ExcelProperty("订单ID") + private Long orderId; + /** + * 库存品ID + */ + @ColumnWidth(20) + @ExcelProperty("库存品ID") + private Long inventoryId; + /** + * 滞留类型 1-包件、2-零担(这里会关联到具体的品类)、3-库存品 + */ + @ColumnWidth(20) + @ExcelProperty("滞留类型 1-包件、2-零担(这里会关联到具体的品类)、3-库存品") + private Integer conditions; + /** + * 物料编码(库存品) + */ + @ColumnWidth(20) + @ExcelProperty("物料编码(库存品)") + private String materialNumber; + /** + * 物料名称(库存品) + */ + @ColumnWidth(20) + @ExcelProperty("物料名称(库存品)") + private String materialName; + /** + * 预约客户ID + */ + @ColumnWidth(20) + @ExcelProperty("预约客户ID") + private Long reservationId; + /** + * 订单自编号(库存品没有) + */ + @ColumnWidth(20) + @ExcelProperty("订单自编号(库存品没有)") + private String orderCode; + /** + * 预约单号 + */ + @ColumnWidth(20) + @ExcelProperty("预约单号") + private String reservationCode; + /** + * 扫描类型:1-包件、2-订单、3-托盘、4... + */ + @ColumnWidth(20) + @ExcelProperty("扫描类型:1-包件、2-订单、3-托盘、4...") + private Integer scanType; + /** + * 包件ID + */ + @ColumnWidth(20) + @ExcelProperty("包件ID") + private Long orderPackageId; + /** + * 包条码 + */ + @ColumnWidth(20) + @ExcelProperty("包条码") + private String orderPackageCode; + /** + * 滞留数量 + */ + @ColumnWidth(20) + @ExcelProperty("滞留数量") + private Integer retentionQuantity; + /** + * 滞留扫描操作人名称 + */ + @ColumnWidth(20) + @ExcelProperty("滞留扫描操作人名称") + private String retentionScanUsername; + /** + * 滞留扫描操作人Id + */ + @ColumnWidth(20) + @ExcelProperty("滞留扫描操作人Id") + private String retentionScanUserId; + /** + * 滞留操作备注 + */ + @ColumnWidth(20) + @ExcelProperty("滞留操作备注") + private String remarks; + /** + * 滞留扫描时间 + */ + @ColumnWidth(20) + @ExcelProperty("滞留扫描时间") + private Date retentionScanTime; + /** + * 滞留方式 1-PDA、2-PC + */ + @ColumnWidth(20) + @ExcelProperty("滞留方式 1-PDA、2-PC") + private Integer retentionWay; + /** + * 配送任务ID + */ + @ColumnWidth(20) + @ExcelProperty("配送任务ID") + private Long deliveryListId; + +} diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/feign/WarehouseRetentionScanClient.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/feign/WarehouseRetentionScanClient.java new file mode 100644 index 000000000..730cd1f55 --- /dev/null +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/feign/WarehouseRetentionScanClient.java @@ -0,0 +1,61 @@ +/* + * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * Neither the name of the dreamlu.net developer nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * Author: Chill 庄骞 (smallchill@163.com) + */ +package com.logpm.warehouse.feign; + +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.logpm.warehouse.entity.WarehouseRetentionScanEntity; +import com.logpm.warehouse.service.IWarehouseRetentionScanService; +import lombok.AllArgsConstructor; +import org.springblade.core.mp.support.BladePage; +import org.springblade.core.mp.support.Condition; +import org.springblade.core.mp.support.Query; +import com.logpm.warehouse.entity.WarehouseRetentionRecordEntity; +import com.logpm.warehouse.service.IWarehouseRetentionRecordService; +import org.springblade.core.tool.api.R; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.RestController; +import springfox.documentation.annotations.ApiIgnore; + +/** + * 滞留扫描记录 Feign实现类 + * + * @author BladeX + * @since 2023-11-03 + */ +@ApiIgnore() +@RestController +@AllArgsConstructor +public class WarehouseRetentionScanClient implements IWarehouseRetentionScanClient { + + private final IWarehouseRetentionScanService warehouseRetentionScanService; + + @Override + @GetMapping(TOP) + public BladePage retentionScanTop(Integer current, Integer size) { + Query query = new Query(); + query.setCurrent(current); + query.setSize(size); + IPage page = warehouseRetentionScanService.page(Condition.getPage(query)); + return BladePage.of(page); + } + + @Override + public R saveRetentionScan(WarehouseRetentionScanEntity warehouseRetentionScanEntity) { + return R.status(warehouseRetentionScanService.save(warehouseRetentionScanEntity)); + } + +} diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/TaskQuestMapper.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/TaskQuestMapper.java index d6f1bdb4b..d81d40c22 100644 --- a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/TaskQuestMapper.java +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/TaskQuestMapper.java @@ -17,6 +17,8 @@ package com.logpm.warehouse.mapper; import com.logpm.warehouse.dto.TaskSearchDTO; +import com.logpm.warehouse.entity.QuestDetailChildEntity; +import com.logpm.warehouse.entity.QuestDetailEntity; import com.logpm.warehouse.entity.TaskQuestEntity; import com.logpm.warehouse.entity.WarehouseTrayEntity; import com.logpm.warehouse.vo.*; @@ -55,7 +57,7 @@ public interface TaskQuestMapper extends BaseMapper { List selectTaskQuestApiPage(IPage page,@Param("param") TaskQuestApiVO taskQuest,@Param("collect") List collect); - List selectallocationList(@Param("param") TaskSearchDTO taskSearchDTO); + List selectallocationList(@Param("questNum")String questNum, @Param("param") TaskSearchDTO taskSearchDTO); List selectcontractList(IPage page, @Param("param") TaskSearchDTO taskSearchDTO,@Param("collect") List collect); @@ -84,4 +86,44 @@ public interface TaskQuestMapper extends BaseMapper { List selectInventoryListByQuestId(IPage page,@Param("questId") Long id); List selectZeroListByQuestId(IPage page,@Param("questId") Long id); + + + String selectExitsInfo(@Param("questNum")String questNum); + + int createdTable(@Param("questNum")String questNum); + + int createdTableChild(@Param("questNum")String s); + + int insertQuestDetail(@Param("questNum") String questNum,@Param("list")List detailEntityList); + + /** + *查询盘点数据list + * @param questNum + * @param questDetail + * @return + */ + List selectTaskInfo(@Param("questNum")String questNum,@Param("param") QuestDetailEntity questDetail); + /** + *根据ID查询盘点数据 + * @param questNum + * @param questDetail + * @return + */ + QuestDetailEntity selectOneTaskInfo(@Param("questNum")String questNum,@Param("param") QuestDetailEntity questDetail); + + /** + *根据查询盘点数据 + * @param questNum + * @param questDetail + * @return + */ + List selectQuestDetailList(@Param("questNum")String questNum,@Param("param") QuestDetailEntity questDetail); + + List selectTaskTrayInfo(@Param("questNum")String questNum,@Param("param") QuestDetailEntity questDetail); + + List getQuestDetailInfo(@Param("questNum")String questNum,@Param("param")QuestDetailChildEntity questDetailChildEntity); + + Integer updateQuestDetailQuestStatus(@Param("questNum")String questNum,@Param("param") QuestDetailEntity q); + + Integer updatePositionCodeList(@Param("questNum") String questNum, @Param("list") List ls); } diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/TaskQuestMapper.xml b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/TaskQuestMapper.xml index 560233460..8d09b4a08 100644 --- a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/TaskQuestMapper.xml +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/TaskQuestMapper.xml @@ -44,6 +44,191 @@ ORDER BY ltq.create_time desc + + + + CREATE TABLE ${questNum} ( + `id` bigint(20) NOT NULL COMMENT '主键', + `tenant_id` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '租户号', + `create_user` bigint(20) NULL DEFAULT NULL COMMENT '创建人', + `create_time` datetime(0) NULL DEFAULT NULL COMMENT '创建时间', + `update_user` bigint(20) NULL DEFAULT NULL COMMENT '更新人', + `update_time` datetime(0) NULL DEFAULT NULL COMMENT '更新时间', + `create_dept` bigint(20) NULL DEFAULT NULL COMMENT '创建部门', + `is_deleted` int(11) NULL DEFAULT NULL COMMENT '是否删除', + `status` int(11) NULL DEFAULT NULL COMMENT '状态', + `reserve1` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '预留1', + `reserve2` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '预留2', + `reserve3` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '预留3', + `reserve4` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '预留4', + `reserve5` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '预留5', + `quest_detail_id` bigint(20) NULL DEFAULT NULL COMMENT '盘点明细ID', + `cargo_name` varchar(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '货物状态;10 在库 20 破损 30丢失 40不可修复 50配送 60未入库', + `quest_num` int(10) NOT NULL DEFAULT 1 COMMENT '盘点数量', + `warehouse_id` bigint(20) NULL DEFAULT NULL COMMENT '仓库id', + PRIMARY KEY (`id`) USING BTREE, + INDEX `quest_detail_id_index`(`quest_detail_id`) USING BTREE COMMENT '盘点明细' + ) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '${questNum}盘点明细子表' ROW_FORMAT = Dynamic; + + + CREATE TABLE ${questNum} ( + `id` bigint(20) NOT NULL COMMENT '主键', + `tenant_id` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '租户号', + `create_user` bigint(20) NULL DEFAULT NULL COMMENT '创建人', + `create_time` datetime(0) NULL DEFAULT NULL COMMENT '创建时间', + `update_user` bigint(20) NULL DEFAULT NULL COMMENT '更新人', + `update_time` datetime(0) NULL DEFAULT NULL COMMENT '更新时间', + `create_dept` bigint(20) NULL DEFAULT NULL COMMENT '创建部门', + `is_deleted` int(11) NULL DEFAULT NULL COMMENT '是否删除', + `status` int(11) NULL DEFAULT NULL COMMENT '状态', + `reserve1` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '预留1', + `reserve2` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '预留2', + `reserve3` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '预留3', + `reserve4` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '预留4', + `reserve5` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '预留5', + `order_code` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '订单号', + `quest_id` bigint(20) NULL DEFAULT NULL COMMENT '任务ID', + `order_id` bigint(20) NULL DEFAULT NULL COMMENT '订单ID', + `quest_type` int(11) NULL DEFAULT NULL COMMENT '盘点方式;1. 随机 2 库位3 订单 4 托盘', + `quest_target` int(11) NULL DEFAULT NULL COMMENT '盘点对象;1.定制品 2零担 3 库存品', + `orde_package_code` varchar(120) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '包条码;对应定制品', + `order_package_id` bigint(20) NULL DEFAULT NULL COMMENT '包条ID;对应定制品', + `category_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '品类名称;对应零担', + `stock_id` bigint(20) NULL DEFAULT NULL COMMENT '库存品ID;对应库存品', + `quest_status` int(10) NOT NULL DEFAULT 0 COMMENT '盘点状态;0 待盘点 1. 已盘 2未盘点 3已排除', + `stock_num` int(10) NOT NULL DEFAULT 1 COMMENT '在库数量', + `warehouse_id` bigint(20) NULL DEFAULT NULL COMMENT '仓库id', + `position_code` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '完整货位(按库位)', + `tray_code` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '托盘码(按托盘)', + `tray_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '托盘id(按托盘)', + `allocation_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '货位id(按库位)', + `grounding_allocation_id` bigint(20) NULL DEFAULT NULL COMMENT '上架后的库位ID', + `is_new` int(20) NULL DEFAULT NULL COMMENT '是否是新增数据', + `grounding_position_code` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '上架后的完整库位', + `material_code` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '物料编码(库存品)', + `market_name` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '商场名称(库存品)', + `incoming_batch` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '批次号(库存品)', + `material_name` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '物料名称(库存品)', + `waybill_number` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '运单号', + PRIMARY KEY (`id`) USING BTREE, + INDEX `quest_id_index`(`quest_id`) USING BTREE COMMENT '任务id', + INDEX `order_id_index`(`order_id`) USING BTREE COMMENT '订单id', + INDEX `tenant_id_index`(`tenant_id`) USING BTREE COMMENT '租户id' + ) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '${questNum}盘点明细' ROW_FORMAT = Dynamic; + + + INSERT INTO ${questNum}(`id`, `tenant_id`, `create_user`, `create_time`, `update_user`, `update_time`, `create_dept`, + `is_deleted`, `status`, `reserve1`, `reserve2`, `reserve3`, `reserve4`, `reserve5`, `order_code`, `quest_id`, `order_id`, `quest_type`, `quest_target`, + `orde_package_code`, `order_package_id`, `category_name`, `stock_id`, `quest_status`, `stock_num`, `warehouse_id`, `position_code`, `tray_code`, `tray_id`, + `allocation_id`, `grounding_allocation_id`, `is_new`, `grounding_position_code`, `material_code`, `market_name`, `incoming_batch`, `material_name`, + `waybill_number`) VALUES + + (#{item.id}, #{item.tenantId}, #{item.createUser}, #{item.createTime}, #{item.updateUser}, #{item.updateTime}, #{item.createDept}, #{item.isDeleted} + , #{item.status}, #{item.reserve1}, #{item.reserve2}, #{item.reserve3}, #{item.reserve4}, #{item.reserve5}, #{item.orderCode}, #{item.questId}, #{item.orderId} + , #{item.questType}, #{item.questTarget}, #{item.ordePackageCode}, #{item.orderPackageId}, #{item.categoryName}, #{item.stockId}, #{item.questStatus}, + #{item.stockNum}, #{item.warehouseId} , #{item.positionCode}, #{item.trayCode}, #{item.trayId}, #{item.allocationId}, #{item.groundingAllocationId}, + #{item.isNew}, #{item.groundingPositionCode}, #{item.materialCode}, #{item.marketName} , #{item.incomingBatch}, #{item.materialName}, #{item.waybillNumber} + ) + + + + + + + + + update ${questNum} set quest_status = #{param.questStatus} + WHERE `id` = #{ param.id } + + + + update ${questNum} + + grounding_allocation_id = #{item. groundingAllocationId}, + grounding_position_code = #{item.groundingPositionCode }, + quest_status = #{item.questStatus }, + + + WHERE `id` = #{ param.id } + + + + + + diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseRetentionScanMapper.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseRetentionScanMapper.java new file mode 100644 index 000000000..b3334d03c --- /dev/null +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseRetentionScanMapper.java @@ -0,0 +1,57 @@ +/* + * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * Neither the name of the dreamlu.net developer nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * Author: Chill 庄骞 (smallchill@163.com) + */ +package com.logpm.warehouse.mapper; + +import com.logpm.warehouse.entity.WarehouseRetentionRecordEntity; +import com.logpm.warehouse.entity.WarehouseRetentionScanEntity; +import com.logpm.warehouse.excel.WarehouseRetentionScanExcel; +import com.logpm.warehouse.vo.WarehouseRetentionRecordVO; +import com.logpm.warehouse.excel.WarehouseRetentionRecordExcel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.baomidou.mybatisplus.core.conditions.Wrapper; +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.logpm.warehouse.vo.WarehouseRetentionScanVO; +import org.apache.ibatis.annotations.Param; +import java.util.List; + +/** + * 滞留扫描记录 Mapper 接口 + * + * @author BladeX + * @since 2023-11-03 + */ +public interface WarehouseRetentionScanMapper extends BaseMapper { + + /** + * 自定义分页 + * + * @param page + * @param warehouseRetentionScanVO + * @return + */ + List selectWarehouseRetentionRecordPage(IPage page, WarehouseRetentionScanVO warehouseRetentionScanVO); + + + /** + * 获取导出数据 + * + * @param queryWrapper + * @return + */ + List exportWarehouseRetentionRecord(@Param("ew") Wrapper queryWrapper); + +} diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseRetentionScanMapper.xml b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseRetentionScanMapper.xml new file mode 100644 index 000000000..7330ce208 --- /dev/null +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseRetentionScanMapper.xml @@ -0,0 +1,52 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseTaryAllocationMapper.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseTaryAllocationMapper.java index 9a2deb6d3..c2f37f2bd 100644 --- a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseTaryAllocationMapper.java +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseTaryAllocationMapper.java @@ -14,4 +14,5 @@ public interface WarehouseTaryAllocationMapper extends BaseMapper { */ R queryContract(TaskSearchDTO taskSearchDTO); + /** + * 盘点定制平数据 + * @param taskSearchDTO + * @return + */ List allocationDetailByPackage(TaskSearchDTO taskSearchDTO); + /** + * 盘点零担数据 + * @param taskSearchDTO + * @return + */ List allocationDetailByZero(TaskSearchDTO taskSearchDTO); + /** + * 盘点库存平数据 + * @param taskSearchDTO + * @return + */ List allocationDetailByStock(TaskSearchDTO taskSearchDTO); void updateQuestSetail(TaskSearchDTO taskSearchDTO); @@ -132,4 +147,12 @@ public interface ITaskQuestService extends BaseService { R questScanAllcation(TaskSearchDTO taskSearchDTO); R selectPackageInfo(TaskSearchDTO taskSearchDTO); + + /** + * 查询盘点任务数据任务 + * @param questNum + * @param questDetail + * @return + */ + List selectTaskInfo(String questNum, QuestDetailEntity questDetail); } diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/IWarehouseRetentionRecordService.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/IWarehouseRetentionRecordService.java index bcd26b8b6..7c1ff8c94 100644 --- a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/IWarehouseRetentionRecordService.java +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/IWarehouseRetentionRecordService.java @@ -62,4 +62,18 @@ public interface IWarehouseRetentionRecordService extends BaseService retentionPackageList(RetentionDTO retentionDTO); R retentionScanPackage(String orderPackageCode); + + /** + * PDA查询初始化滞留扫描页 + * @param deliveryId + * @return + */ + WarehouseRetentionRecordVO initRetentionList(Long deliveryId); + + /** + * 保存扫描记录 + * @param retentionDTO + * @return + */ + R saveRetentionList(RetentionDTO retentionDTO); } diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/IWarehouseRetentionScanService.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/IWarehouseRetentionScanService.java new file mode 100644 index 000000000..5c43e2950 --- /dev/null +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/IWarehouseRetentionScanService.java @@ -0,0 +1,55 @@ +/* + * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * Neither the name of the dreamlu.net developer nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * Author: Chill 庄骞 (smallchill@163.com) + */ +package com.logpm.warehouse.service; + +import com.baomidou.mybatisplus.core.conditions.Wrapper; +import com.logpm.warehouse.entity.WarehouseRetentionRecordEntity; +import com.logpm.warehouse.entity.WarehouseRetentionScanEntity; +import com.logpm.warehouse.excel.WarehouseRetentionScanExcel; +import com.logpm.warehouse.vo.WarehouseRetentionRecordVO; +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.baomidou.mybatisplus.extension.service.IService; +import com.logpm.warehouse.vo.WarehouseRetentionScanVO; + +import java.util.List; + +/** + * 滞留扫描记录 服务类 + * + * @author BladeX + * @since 2023-11-03 + */ +public interface IWarehouseRetentionScanService extends IService { + /** + * 自定义分页 + * + * @param page + * @param warehouseRetentionScanVO + * @return + */ + IPage selectWarehouseRetentionRecordPage(IPage page, WarehouseRetentionScanVO warehouseRetentionScanVO); + + + /** + * 导出数据 + * + * @param queryWrapper + * @return + */ + List exportWarehouseRetentionRecord(Wrapper queryWrapper); + +} diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/TaskQuestServiceImpl.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/TaskQuestServiceImpl.java index 1a6405871..12e5015fe 100644 --- a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/TaskQuestServiceImpl.java +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/TaskQuestServiceImpl.java @@ -16,11 +16,12 @@ */ package com.logpm.warehouse.service.impl; -import cn.hutool.log.Log; +import com.alibaba.nacos.plugin.auth.constant.Constants; import com.baomidou.mybatisplus.core.conditions.Wrapper; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; +import com.baomidou.mybatisplus.core.toolkit.BeanUtils; import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; import com.baomidou.mybatisplus.core.toolkit.Wrappers; import com.logpm.basicdata.entity.*; @@ -31,6 +32,7 @@ import com.logpm.distribution.entity.DistributionStockListEntity; import com.logpm.distribution.feign.IDistributionParcelListClient; import com.logpm.distribution.feign.IDistributionStockArticleClient; import com.logpm.distribution.feign.IDistributionStockListClient; +import com.logpm.distribution.vo.DistributionParcelListVO; import com.logpm.distribution.vo.DistributionStockListVO; import com.logpm.warehouse.bean.Resp; import com.logpm.warehouse.dto.QuestDetailDTO; @@ -45,13 +47,17 @@ import com.logpm.warehouse.service.*; import com.logpm.warehouse.vo.*; import lombok.AllArgsConstructor; import lombok.extern.log4j.Log4j2; +import org.apache.ibatis.annotations.Param; import org.springblade.common.constant.common.IsOrNoConstant; import org.springblade.common.constant.orderpackage.OrderPackageStatusConstant; import org.springblade.common.exception.CustomerException; import org.springblade.common.utils.CommonUtil; import org.springblade.core.log.exception.ServiceException; import org.springblade.core.mp.base.BaseServiceImpl; +import org.springblade.core.secure.BladeUser; +import org.springblade.core.secure.utils.AuthUtil; import org.springblade.core.tool.api.R; +import org.springblade.core.tool.utils.AesUtil; import org.springblade.core.tool.utils.BeanUtil; import org.springblade.core.tool.utils.Func; import org.springframework.stereotype.Service; @@ -122,6 +128,358 @@ public class TaskQuestServiceImpl extends BaseServiceImpl refId,String questNum,Long taskQuest){ + //查询表存在么 + String s = baseMapper.selectExitsInfo(questNum); + if(ObjectUtils.isNotNull(s)){ + throw new ServiceException("任务表已存在!"); + }else{ + //创建任务明细表 + baseMapper.createdTable(questNum); + //创建任务明细盘点表 + baseMapper.createdTableChild(questNum + "_child"); + } + if(ObjectUtils.isNull(refId) || refId.isEmpty()){ + //全部 + DistributionParcelListVO stockArticleEntity = new DistributionParcelListVO(); + stockArticleEntity.setWarehouseId(warehouseId); + getParcelListNumber(stockArticleEntity,questNum,taskQuest); + }else{ + //部分 + for (Long l : refId) { + DistributionParcelListVO stockArticleEntity = new DistributionParcelListVO(); + stockArticleEntity.setWarehouseId(warehouseId); + stockArticleEntity.setMallId(l); + getParcelListNumber(stockArticleEntity,questNum,taskQuest); + } + + } + + } + + /** + * 查询盘点包件数据 + * @param stockArticleEntity + * @param questNum + * @param taskQuest + */ + public void getParcelListNumber(DistributionParcelListVO stockArticleEntity,String questNum,Long taskQuest){ + List parcelListInfo = distributionParcelListClient.getParcelListInfo(stockArticleEntity); + BladeUser user = AuthUtil.getUser(); + if(!parcelListInfo.isEmpty()){ + List detailEntityList = new ArrayList<>(); + parcelListInfo.stream().forEach( i ->{ + + QuestDetailEntity detailEntity = new QuestDetailEntity(); + detailEntity.setId(getTaskID()); + detailEntity.setCreateTime(new Date()); + detailEntity.setTenantId(user.getTenantId()); + detailEntity.setCreateUser(user.getUserId()); + detailEntity.setCreateDept(Long.valueOf(user.getDeptId())); + detailEntity.setIsDeleted(0); + detailEntity.setStatus(1); + detailEntity.setQuestId(taskQuest); + detailEntity.setOrderCode(i.getOrderCode()); + detailEntity.setOrderId(i.getStockArticleId()); +// detailEntity.setQuestType(); + //盘点对象;1.定制品 2零担 3 库存品 + detailEntity.setQuestTarget(1); + detailEntity.setOrdePackageCode(i.getOrderPackageCode()); + detailEntity.setWaybillNumber(i.getWaybillNumber()); + detailEntity.setOrderPackageId(i.getId()); + detailEntity.setCategoryName(i.getFirsts()); + detailEntity.setStockId(i.getStockId()); //库存品ID + detailEntity.setQuestStatus(0); + detailEntity.setStockNum(ObjectUtils.isNotNull(i.getQuantity()) ? i.getQuantity() : 0); + detailEntity.setWarehouseId(i.getWarehouseId()); + detailEntity.setPositionCode(i.getPositionCode()); + detailEntity.setTrayCode(i.getTrayCode()); +// detailEntity.setGroundingAllocationId(); +// detailEntity.setGroundingPositionCode(); + detailEntity.setTrayId(i.getTrayId()); + detailEntity.setAllocationId(i.getAllocationId()); + detailEntity.setIsNew(0); + + detailEntity.setMaterialCode(i.getMaterialCode()); + detailEntity.setMaterialName(i.getMaterialName()); + detailEntity.setMarketName(i.getMallName()); + detailEntity.setIncomingBatch(i.getOrderCode()); + detailEntityList.add(detailEntity); + + }); + //查询零担数据 + DistributionStockArticleEntity stockArticle = new DistributionStockArticleEntity(); + stockArticle.setWarehouseId(stockArticleEntity.getWarehouseId()); + stockArticle.setMallId(ObjectUtils.isNotNull(stockArticleEntity.getMallId()) ? stockArticleEntity.getMallId() : null); + stockArticle.setIsZero("1"); + List stockArticleInfo = distributionStockArticleClient.getStockArticleInfo(stockArticle); + if(!stockArticleInfo.isEmpty()){ + detailEntityList.addAll(handleIsZeroList(stockArticleInfo,taskQuest)); + } + + //查询库存平数据 + DistributionStockListEntity stockListEntity = new DistributionStockListEntity(); + stockListEntity.setWarehouseId(stockArticleEntity.getWarehouseId()); + stockListEntity.setMarketId(ObjectUtils.isNotNull(stockArticleEntity.getMallId()) ? stockArticleEntity.getMallId() : null); + List stockListInfo = distributionStockListClient.getStockListInfo(stockListEntity); + if(!stockListInfo.isEmpty()){ + detailEntityList.addAll(handleStockList(stockListInfo,taskQuest)); +// stockListInfo.stream().forEach( li ->{ +// QuestDetailEntity detailListEntity = new QuestDetailEntity(); +// detailListEntity.setCreateTime(new Date()); +// detailListEntity.setTenantId(user.getTenantId()); +// detailListEntity.setCreateUser(user.getUserId()); +// detailListEntity.setCreateDept(Long.valueOf(user.getDeptId())); +// detailListEntity.setIsDeleted(0); +// detailListEntity.setStatus(1); +// detailListEntity.setQuestId(taskQuest); +// detailListEntity.setOrderCode(li.getOrderCode()); +// //盘点对象;1.定制品 2零担 3 库存品 +// detailListEntity.setQuestTarget(3); +// detailListEntity.setWaybillNumber(li.getIncomingBatch()); +// detailListEntity.setStockId(li.getId()); //库存品ID +// detailListEntity.setQuestStatus(0); +// detailListEntity.setStockNum(li.getQuantityStock()); +// detailListEntity.setWarehouseId(li.getWarehouseId()); +// detailListEntity.setPositionCode(li.getPositionCode()); +// detailListEntity.setTrayCode(li.getTrayCode()); +// detailListEntity.setTrayId(li.getTrayId()); +// detailListEntity.setAllocationId(li.getAllocationId()); +// detailListEntity.setIsNew(0); +// +// detailListEntity.setMaterialCode(li.getCargoNumber()); +// detailListEntity.setMaterialName(li.getDescriptionGoods()); +// detailListEntity.setMarketName(li.getMallName()); +// detailListEntity.setIncomingBatch(li.getIncomingBatch()); +// detailEntityList.add(detailListEntity); +// }); + } + + if(!detailEntityList.isEmpty()){ + + int batchSize = 1000; // 设置批处理的大小 + int totalSize = detailEntityList.size(); // 获取总数据量 + + for (int i = 0; i < totalSize; i += batchSize) { + int endIndex = Math.min(i + batchSize, totalSize); + List subList = detailEntityList.subList(i, endIndex); + baseMapper.insertQuestDetail(questNum, subList); + } + + } + + } +} + + /** + * 生成Id + * @return + */ + public Long getTaskID(){ + Random random = new Random(); + long min = 100000000000000000L; // 最小值为10的18次方 + long max = 9223372036854775807L; // Long类型的最大值 + return min + (long) (random.nextDouble() * (max - min)); +} + + /** + * 查询零担数据 + */ + public List handleIsZeroList(List stockArticleInfo,Long taskQuest){ + List detailEntityList = new ArrayList<>(); + BladeUser user = AuthUtil.getUser(); + //处理库位,托盘 + stockArticleInfo.stream().forEach( i ->{ + QuestDetailEntity detailEntity = new QuestDetailEntity(); + detailEntity.setId(getTaskID()); + detailEntity.setCreateTime(new Date()); + detailEntity.setTenantId(user.getTenantId()); + detailEntity.setCreateUser(user.getUserId()); + detailEntity.setCreateDept(Long.valueOf(user.getDeptId())); + detailEntity.setIsDeleted(0); + detailEntity.setStatus(1); + detailEntity.setQuestId(taskQuest); + detailEntity.setOrderCode(i.getOrderCode()); + detailEntity.setOrderId(i.getId()); +// detailEntity.setQuestType(); + //盘点对象;1.定制品 2零担 3 库存品 + detailEntity.setQuestTarget(2); +// detailEntity.setOrdePackageCode(i.getOrderPackageCode()); + detailEntity.setWaybillNumber(i.getWaybillNumber()); +// detailEntity.setOrderPackageId(i.getId()); + detailEntity.setCategoryName(i.getDescriptionGoods()); +// detailEntity.setStockId(i.getStockId()); //库存品ID + detailEntity.setQuestStatus(0); + detailEntity.setMarketName(i.getMallName()); + detailEntity.setIncomingBatch(i.getOrderCode()); + detailEntity.setWarehouseId(i.getWarehouseId()); + detailEntity.setIsNew(0); + //查询货位 + QueryWrapper qw = new QueryWrapper<>(); + qw.eq("warehouse_id",i.getWarehouseId()); + qw.eq("association_id",i.getId()); + qw.eq("incoming_batch",i.getOrderCode()); + qw.eq("market_id",i.getMallId()); + List updownGoodsList = warehouseUpdownGoodsMapper.selectList(qw); + if(!updownGoodsList.isEmpty()){ + updownGoodsList.stream().forEach( ii ->{ + QuestDetailEntity qq = new QuestDetailEntity(); + BeanUtil.copyProperties(detailEntity,qq); + qq.setId(getTaskID()); + qq.setPositionCode(ii.getPositionCode()); + qq.setAllocationId(String.valueOf(ii.getAllocationId())); + qq.setMaterialName(ii.getMarketName()); + BasicdataTrayEntity trayByAllocationId = taryAllocationService.getTrayByAllocationId(ii.getAllocationId()); + if(ObjectUtils.isNotNull(trayByAllocationId)){ + List tray = chuLiKuCun(i, trayByAllocationId.getId()); + if(!tray.isEmpty()){ + qq.setTrayCode(tray.get(0).getTrayCode()); + qq.setTrayId(String.valueOf(tray.get(0).getTrayId())); + qq.setStockNum(ObjectUtils.isNotNull(tray.get(0).getNum()) ? tray.get(0).getNum() : 0); + } + } + qq.setStockNum(ObjectUtils.isNotNull(ii.getNum()) ? ii.getNum() : 0); + detailEntityList.add(qq); + }); + }else{ + List warehouseTrayGoodsEntities = chuLiKuCun(i, null); + if(!warehouseTrayGoodsEntities.isEmpty()){ + warehouseTrayGoodsEntities.stream().forEach( ta ->{ + QuestDetailEntity aa = new QuestDetailEntity(); + BeanUtil.copyProperties(detailEntity,aa); + aa.setId(getTaskID()); + aa.setTrayCode(ta.getTrayCode()); + aa.setTrayId(String.valueOf(ta.getTrayId())); + aa.setStockNum(ObjectUtils.isNotNull(ta.getNum()) ? ta.getNum() : 0); + detailEntityList.add(aa); + }); + } + } + detailEntity.setStockNum(ObjectUtils.isNotNull(i.getHandQuantity()) ? i.getHandQuantity() : 0); + detailEntityList.add(detailEntity); + + }); + return detailEntityList; +} + + /** + * 查询库存平数据 + */ + public List handleStockList(List stockListInfo,Long taskQuest){ + List detailEntityList = new ArrayList<>(); + BladeUser user = AuthUtil.getUser(); + //处理库位,托盘 + stockListInfo.stream().forEach( i ->{ + QuestDetailEntity detailEntity = new QuestDetailEntity(); + detailEntity.setId(getTaskID()); + detailEntity.setCreateTime(new Date()); + detailEntity.setTenantId(user.getTenantId()); + detailEntity.setCreateUser(user.getUserId()); + detailEntity.setCreateDept(Long.valueOf(user.getDeptId())); + detailEntity.setIsDeleted(0); + detailEntity.setStatus(1); + detailEntity.setQuestId(taskQuest); + detailEntity.setOrderCode(i.getOrderCode()); + detailEntity.setOrderId(i.getId()); +// detailEntity.setQuestType(); + //盘点对象;1.定制品 2零担 3 库存品 + detailEntity.setQuestTarget(3); +// detailEntity.setOrdePackageCode(i.getOrderPackageCode()); + detailEntity.setWaybillNumber(i.getIncomingBatch()); +// detailEntity.setOrderPackageId(i.getId()); + detailEntity.setCategoryName(i.getDescriptionGoods()); + detailEntity.setStockId(i.getId()); //库存品ID + detailEntity.setQuestStatus(0); + detailEntity.setMarketName(i.getMallName()); + detailEntity.setIncomingBatch(i.getOrderCode()); + detailEntity.setWarehouseId(i.getWarehouseId()); + detailEntity.setIsNew(0); + //查询货位 + QueryWrapper qw = new QueryWrapper<>(); + qw.eq("warehouse_id",i.getWarehouseId()); + qw.eq("association_id",i.getMaterialId()); + qw.eq("incoming_batch",i.getIncomingBatch()); + qw.eq("market_id",i.getMarketId()); + List updownGoodsList = warehouseUpdownGoodsMapper.selectList(qw); + if(!updownGoodsList.isEmpty()){ + updownGoodsList.stream().forEach( ii ->{ + QuestDetailEntity a = new QuestDetailEntity(); + BeanUtil.copyProperties(detailEntity,a); + a.setId(getTaskID()); + a.setPositionCode(ii.getPositionCode()); + a.setAllocationId(String.valueOf(ii.getAllocationId())); + a.setMaterialName(ii.getMarketName()); + BasicdataTrayEntity trayByAllocationId = taryAllocationService.getTrayByAllocationId(ii.getAllocationId()); + if(ObjectUtils.isNotNull(trayByAllocationId)){ + List tray = chuLiKuCunLing(i, trayByAllocationId.getId()); + if(!tray.isEmpty()){ + a.setTrayCode(tray.get(0).getTrayCode()); + a.setTrayId(String.valueOf(tray.get(0).getTrayId())); + a.setStockNum(ObjectUtils.isNotNull(tray.get(0).getNum()) ? tray.get(0).getNum() : 0); + } + } + a.setStockNum(ObjectUtils.isNotNull(ii.getNum()) ? ii.getNum() : 0); + detailEntityList.add(a); + }); + }else{ + List warehouseTrayGoodsEntities = chuLiKuCunLing(i, null); + if(!warehouseTrayGoodsEntities.isEmpty()){ + warehouseTrayGoodsEntities.stream().forEach( ta ->{ + QuestDetailEntity detailEntityTray = new QuestDetailEntity(); + BeanUtil.copyProperties(detailEntity,detailEntityTray); + detailEntityTray.setId(getTaskID()); + detailEntityTray.setTrayCode(ta.getTrayCode()); + detailEntityTray.setTrayId(String.valueOf(ta.getTrayId())); + detailEntityTray.setStockNum(ObjectUtils.isNotNull(ta.getNum() ) ? ta.getNum() : 0); + detailEntityList.add(detailEntityTray); + }); + } + } + detailEntity.setStockNum(ObjectUtils.isNotNull( i.getQuantityStock()) ? i.getQuantityStock() : 0); + detailEntityList.add(detailEntity); + + }); + return detailEntityList; +} + + /** + * 查询零担托盘数据 + * @param distributionStockArticle + * @return + */ + public List chuLiKuCun(DistributionStockArticleEntity distributionStockArticle ,Long id){ + + QueryWrapper qw = new QueryWrapper<>(); + qw.eq("warehouse_id",distributionStockArticle.getWarehouseId()); + qw.eq("association_id",distributionStockArticle.getId()); + qw.eq("incoming_batch",distributionStockArticle.getOrderCode()); + qw.eq("market_id",distributionStockArticle.getMallId()); + if(ObjectUtils.isNotNull(id)){ + qw.eq("tray_id",id); + } + return warehouseTrayGoodsMapper.selectList(qw); + } + /** + * 查询库存托盘数据 + * @param distributionStockArticle + * @return + */ + public List chuLiKuCunLing(DistributionStockListEntity distributionStockArticle ,Long id){ + + QueryWrapper qw = new QueryWrapper<>(); + qw.eq("warehouse_id",distributionStockArticle.getWarehouseId()); + qw.eq("association_id",distributionStockArticle.getMaterialId()); + qw.eq("incoming_batch",distributionStockArticle.getIncomingBatch()); + qw.eq("market_id",distributionStockArticle.getMarketId()); + if(ObjectUtils.isNotNull(id)){ + qw.eq("tray_id",id); + } + return warehouseTrayGoodsMapper.selectList(qw); + } + @Override public R saveCustom(TaskQuestDTO taskQuest) { BasicdataWarehouseEntity myCurrentWarehouse = warehouseClient.getMyCurrentWarehouse(); @@ -133,7 +491,11 @@ public class TaskQuestServiceImpl extends BaseServiceImpl 0) { @@ -141,9 +503,16 @@ public class TaskQuestServiceImpl extends BaseServiceImpl collect = list.stream().map(TaskQuestChildEntity::getRefId).collect(Collectors.toList()); + addQuestDetail(myCurrentWarehouse.getId(),collect,questNum,taskQuest.getId()); + }else{ + addQuestDetail(myCurrentWarehouse.getId(),null,questNum,taskQuest.getId()); } + return save ? R.success("添加成功") : R.fail("添加失败"); } @@ -214,7 +583,15 @@ public class TaskQuestServiceImpl extends BaseServiceImpl selectallocationList(TaskSearchDTO taskSearchDTO) { - List list = baseMapper.selectallocationList(taskSearchDTO); + try { + TaskQuestEntity taskQuestEntity = baseMapper.selectById(taskSearchDTO.getQuestId()); + List list = baseMapper.selectallocationList(taskQuestEntity.getQuestNum(),taskSearchDTO); + return list; + }catch (Exception e){ + log.debug(e.getMessage()); + return new ArrayList<>(); + } + // if (!list.isEmpty()) { // for (TaskallocationVO taskallocationVO : list) { // Long allocationId = taskallocationVO.getAllocationId(); @@ -222,7 +599,6 @@ public class TaskQuestServiceImpl extends BaseServiceImpl collect = this.getmyWarehouseList(); baseMapper.setSqlMode(); String goodsType = taskSearchDTO.getGoodsType(); - LambdaQueryWrapper queryWrapper = Wrappers.query().lambda() - .eq(QuestDetailEntity::getQuestType, 3) - .eq(QuestDetailEntity::getQuestId, taskSearchDTO.getTaskId()); +// LambdaQueryWrapper queryWrapper = Wrappers.query().lambda() +// .eq(QuestDetailEntity::getQuestType, 3) +// .eq(QuestDetailEntity::getQuestId, taskSearchDTO.getTaskId()); List list = new ArrayList<>(); - List questDetailEntityList = questDetailService.list(queryWrapper); + TaskQuestEntity taskQuestEntity = baseMapper.selectById(taskSearchDTO.getTaskId()); + QuestDetailEntity questDetail = new QuestDetailEntity(); + questDetail.setQuestId( taskSearchDTO.getTaskId()); + List questDetailEntityList = baseMapper.selectTaskInfo(taskQuestEntity.getQuestNum(),questDetail); if (Func.isEmpty(questDetailEntityList)){ return null; } @@ -335,7 +714,7 @@ public class TaskQuestServiceImpl extends BaseServiceImpl { TaskTrayVO taskTrayVO = new TaskTrayVO(); - taskTrayVO.setTrayId(k); + taskTrayVO.setTrayId(Long.valueOf(k)); AtomicReference num = new AtomicReference<>(0); //总数 AtomicReference unTotal = new AtomicReference<>(0); //盘点数 v.forEach( p ->{ @@ -452,18 +831,21 @@ public class TaskQuestServiceImpl extends BaseServiceImpl{ - taskTrayVO.setTrayId(k); + taskTrayVO.setTrayId(Long.valueOf(k)); AtomicReference num = new AtomicReference<>(0); //总数 AtomicReference unTotal = new AtomicReference<>(0); //盘点数 List detailVOS = new ArrayList<>(); + v.forEach( p ->{ + TaskQuestEntity taskQuestEntity = baseMapper.selectById(p.getQuestId()); + taskTrayVO.setTrayCode(p.getTrayCode()); num.set(num.get() + p.getStockNum()); if(p.getQuestStatus().equals(1) && p.getIsNew().equals(0)){ - List list = questDetailChildService.list(Wrappers.query().lambda() - .eq(QuestDetailChildEntity::getQuestDetailId, p.getId()) - .eq(QuestDetailChildEntity::getWarehouseId, warehouseId) - ); + QuestDetailChildEntity questDetailChildEntity = new QuestDetailChildEntity(); + questDetailChildEntity.setQuestDetailId(p.getId()); + questDetailChildEntity.setWarehouseId(warehouseId); + List list = getQuestDetailInfo(taskQuestEntity.getQuestNum()+"_child",questDetailChildEntity); if(!list.isEmpty()){ int sum = list.stream().mapToInt(QuestDetailChildEntity::getQuestNum).sum(); unTotal.set(unTotal.get() + sum); @@ -490,11 +872,11 @@ public class TaskQuestServiceImpl extends BaseServiceImpl list = questDetailChildService.list(Wrappers.query().lambda() - .eq(QuestDetailChildEntity::getQuestDetailId, p.getId()) - .eq(QuestDetailChildEntity::getWarehouseId, p.getWarehouseId()) - .eq(QuestDetailChildEntity::getWarehouseId, p.getWarehouseId()) - ); + QuestDetailChildEntity questDetailChildEntity = new QuestDetailChildEntity(); + questDetailChildEntity.setQuestDetailId(p.getId()); + questDetailChildEntity.setWarehouseId(p.getWarehouseId()); + + List list = getQuestDetailInfo(taskQuestEntity.getQuestNum()+"_child",questDetailChildEntity); questDetailVO.setList(list); detailVOS.add(questDetailVO); }); @@ -506,6 +888,13 @@ public class TaskQuestServiceImpl extends BaseServiceImpl getQuestDetailInfo(String questNum, QuestDetailChildEntity questDetailChildEntity){ + + return baseMapper.getQuestDetailInfo(questNum,questDetailChildEntity); + } + + + /** * 查询托盘里面的信息 * @@ -515,12 +904,19 @@ public class TaskQuestServiceImpl extends BaseServiceImpl getQuestDetailList(TaskSearchDTO taskSearchDTO,Long warehouseId,Long trayId){ - return questDetailService.list(Wrappers.query().lambda() - .eq(QuestDetailEntity::getWarehouseId, warehouseId) - .eq(QuestDetailEntity::getQuestId, taskSearchDTO.getTaskId()) - .eq(ObjectUtils.isNotNull(trayId),QuestDetailEntity::getTrayId, trayId) - .eq(QuestDetailEntity::getQuestType, 4) - ); + TaskQuestEntity taskQuestEntity = baseMapper.selectById(taskSearchDTO.getTaskId()); +// Wrappers.query().lambda() +// .eq(QuestDetailEntity::getWarehouseId, warehouseId) +// .eq(QuestDetailEntity::getQuestId, taskSearchDTO.getTaskId()) +// .eq(c,QuestDetailEntity::getTrayId, trayId) +// .eq(QuestDetailEntity::getQuestType, 4); + QuestDetailEntity questDetail = new QuestDetailEntity(); + questDetail.setWarehouseId(warehouseId); + questDetail.setQuestId(taskSearchDTO.getTaskId()); + if(ObjectUtils.isNotNull(trayId)){ + questDetail.setTrayId(String.valueOf(trayId)); + } + return baseMapper.selectTaskTrayInfo(taskQuestEntity.getQuestNum(),questDetail); } /** @@ -544,16 +940,16 @@ public class TaskQuestServiceImpl extends BaseServiceImpl list = taskQuestChildService.list(Wrappers.query().lambda() - .eq(TaskQuestChildEntity::getQuestId, taskId) + .eq(TaskQuestChildEntity::getQuestId, taskSearchDTO.getTaskId()) ); if (!list.isEmpty()) { boolean b = list.stream().anyMatch(t -> ObjectUtils.isNotNull(t.getRefId())); @@ -567,7 +963,7 @@ public class TaskQuestServiceImpl extends BaseServiceImpl queryData1 = Optional.ofNullable(queryData); if(queryData1.isPresent()){ @@ -653,14 +1049,15 @@ public class TaskQuestServiceImpl extends BaseServiceImpl questDetailEntityQueryWrapper = new QueryWrapper<>(); - questDetailEntityQueryWrapper.eq("quest_id", questId) - .eq("quest_type", 2) - .eq("quest_target", 1) - .eq("warehouse_id", warehouseId) - .eq("allocation_id", allocationId) - .eq("is_deleted", 0); - List questDetailEntities = questDetailService.list(questDetailEntityQueryWrapper); +// QueryWrapper questDetailEntityQueryWrapper = new QueryWrapper<>(); +// questDetailEntityQueryWrapper.eq("quest_id", questId) +// .eq("quest_type", 2) +// .eq("quest_target", 1) +// .eq("warehouse_id", warehouseId) +// .eq("allocation_id", allocationId) +// .eq("is_deleted", 0); + TaskQuestEntity byId = baseMapper.selectById(questId); + QuestDetailEntity questDetail = new QuestDetailEntity(); + questDetail.setQuestId(questId); +// questDetail.setQuestType(2); + questDetail.setQuestTarget(1); + questDetail.setWarehouseId(warehouseId); + questDetail.setAllocationId(String.valueOf(allocationId)); + List questDetailEntities = baseMapper.selectTaskInfo(byId.getQuestNum(),questDetail); +// List questDetailEntities = questDetailService.list(questDetailEntityQueryWrapper); if (!questDetailEntities.isEmpty()) { return questDetailEntities; } - + return new ArrayList<>(); //如果还没有存入 //查询货位上的所有包条 //然后存入detail表 - List list = warehouseUpdownGoodsMapper.allocationDetailByPackage(taskSearchDTO); +// List list = warehouseUpdownGoodsMapper.allocationDetailByPackage(taskSearchDTO); // if(list.isEmpty()){ // log.warn("###########allocationDetailByPackage: 未有数据在盘点计划中 questId={}",questId); // throw new CustomerException(403,"未有数据在盘点计划中"); // } - questDetailService.saveList(list, questId); - - return list; +// questDetailService.saveList(list, questId); +// +// return list; } @Override @@ -804,29 +1209,38 @@ public class TaskQuestServiceImpl extends BaseServiceImpl questDetailEntityQueryWrapper = new QueryWrapper<>(); - questDetailEntityQueryWrapper.eq("quest_id", questId) - .eq("quest_type", 2) - .eq("quest_target", 2) - .eq("warehouse_id", warehouseId) - .eq("allocation_id", allocationId) - .eq("is_deleted", 0); - List questDetailEntities = questDetailService.list(questDetailEntityQueryWrapper); +// QueryWrapper questDetailEntityQueryWrapper = new QueryWrapper<>(); +// questDetailEntityQueryWrapper.eq("quest_id", questId) +// .eq("quest_type", 2) +// .eq("quest_target", 2) +// .eq("warehouse_id", warehouseId) +// .eq("allocation_id", allocationId) +// .eq("is_deleted", 0); + TaskQuestEntity byId = baseMapper.selectById(questId); + QuestDetailEntity questDetail = new QuestDetailEntity(); + questDetail.setQuestId(questId); +// questDetail.setQuestType(2); + questDetail.setQuestTarget(2); + questDetail.setWarehouseId(warehouseId); + questDetail.setAllocationId(String.valueOf(allocationId)); + List questDetailEntities = baseMapper.selectTaskInfo(byId.getQuestNum(),questDetail); +// List questDetailEntities = questDetailService.list(questDetailEntityQueryWrapper); if (!questDetailEntities.isEmpty()) { return questDetailEntities; } - + return new ArrayList<>(); //如果还没有存入 //查询货位上的所有包条 //然后存入detail表 - List list = warehouseUpdownGoodsMapper.allocationDetailByZero(taskSearchDTO); +// List list = warehouseUpdownGoodsMapper.allocationDetailByZero(taskSearchDTO); + // if(list.isEmpty()){ // log.warn("###########allocationDetailByZero: 未有数据在盘点计划中 questId={}",questId); // throw new CustomerException(403,"未有数据在盘点计划中"); // } - questDetailService.saveList(list,questId); +// questDetailService.saveList(list,questId); - return list; +// return list; } @Override @@ -853,29 +1267,36 @@ public class TaskQuestServiceImpl extends BaseServiceImpl questDetailEntityQueryWrapper = new QueryWrapper<>(); - questDetailEntityQueryWrapper.eq("quest_id", questId) - .eq("quest_type", 2) - .eq("quest_target", 3) - .eq("warehouse_id", warehouseId) - .eq("allocation_id", allocationId) - .eq("is_deleted", 0); - List questDetailEntities = questDetailService.list(questDetailEntityQueryWrapper); +// QueryWrapper questDetailEntityQueryWrapper = new QueryWrapper<>(); +// questDetailEntityQueryWrapper.eq("quest_id", questId) +// .eq("quest_type", 2) +// .eq("quest_target", 3) +// .eq("warehouse_id", warehouseId) +// .eq("allocation_id", allocationId) +// .eq("is_deleted", 0); + TaskQuestEntity byId = baseMapper.selectById(questId); + QuestDetailEntity questDetail = new QuestDetailEntity(); + questDetail.setQuestId(questId); +// questDetail.setQuestType(2); + questDetail.setQuestTarget(3); + questDetail.setWarehouseId(warehouseId); + questDetail.setAllocationId(String.valueOf(allocationId)); + List questDetailEntities = baseMapper.selectTaskInfo(byId.getQuestNum(),questDetail); if (!questDetailEntities.isEmpty()) { return questDetailEntities; } - + return new ArrayList<>(); //如果还没有存入 //查询货位上的所有包条 //然后存入detail表 - List list = warehouseUpdownGoodsMapper.allocationDetailByStock(taskSearchDTO); +// List list = warehouseUpdownGoodsMapper.allocationDetailByStock(taskSearchDTO); // if(list.isEmpty()){ // log.warn("###########allocationDetailByStock: 未有数据在盘点计划中 questId={}",questId); // throw new CustomerException(403,"未有数据在盘点计划中"); // } - questDetailService.saveList(list,questId); +// questDetailService.saveList(list,questId); - return list; +// return list; } @Transactional @@ -883,14 +1304,17 @@ public class TaskQuestServiceImpl extends BaseServiceImpl questDetailList = taskSearchDTO.getQuestDetailList(); for (QuestDetailDTO questDetailDTO : questDetailList) { Long questDetaiId = questDetailDTO.getId();//明细id - QuestDetailEntity detailEntity = questDetailService.getById(questDetaiId); +// QuestDetailEntity detailEntity = questDetailService.getById(questDetaiId); + QuestDetailEntity questDetail = new QuestDetailEntity(); + questDetail.setId(questDetaiId); + QuestDetailEntity detailEntity = baseMapper.selectOneTaskInfo(taskQuestEntity.getQuestNum(),questDetail); if(Objects.isNull(detailEntity)){ log.warn("###########updateQuestSetail: 盘点明细不存在 questDetaiId={}",questDetaiId); throw new CustomerException(403,"盘点明细不存在"); @@ -910,7 +1334,11 @@ public class TaskQuestServiceImpl extends BaseServiceImpl ls = new ArrayList<>(); for (QuestDetailDTO questDetailDTO : questDetailList) { Long questDetaiId = questDetailDTO.getId();//明细id - QuestDetailEntity detailEntity = questDetailService.getById(questDetaiId); + QuestDetailEntity questDetail = new QuestDetailEntity(); + questDetail.setId(questDetaiId); + QuestDetailEntity detailEntity = baseMapper.selectOneTaskInfo(taskSearchDTO.getQuestNum(),questDetail); if (Objects.isNull(detailEntity)) { log.warn("###########updateQuestSetail: 存在不在盘点计划中的数据 questDetaiId={}", questDetaiId); throw new CustomerException(403, "存在不在盘点计划中的数据"); } detailEntity.setGroundingAllocationId(allocationId); detailEntity.setGroundingPositionCode(goodsAreaEntity.getHeadline() + "-" + basicdataGoodsShelfEntity.getGoodsShelfName() + "-" + goodsAllocationEntity.getGoodsAllocationName()); + detailEntity.setId(questDetaiId); ls.add(detailEntity); } - questDetailService.updateBatchById(ls); +// questDetailService.updateBatchById(ls); + baseMapper.updatePositionCodeList(taskSearchDTO.getQuestNum(),ls); } @@ -981,15 +1413,19 @@ public class TaskQuestServiceImpl extends BaseServiceImpl ls = new ArrayList<>(); for (QuestDetailDTO questDetailDTO : questDetailList) { Long questDetaiId = questDetailDTO.getId();//明细id - QuestDetailEntity detailEntity = questDetailService.getById(questDetaiId); + QuestDetailEntity questDetail = new QuestDetailEntity(); + questDetail.setId(questDetaiId); + QuestDetailEntity detailEntity = baseMapper.selectOneTaskInfo(taskSearchDTO.getQuestNum(),questDetail); +// QuestDetailEntity detailEntity = questDetailService.getById(,detailEntity); if (Objects.isNull(detailEntity)) { log.warn("###########deleteQuestDetail: 存在不在盘点计划中的数据 questDetaiId={}", questDetaiId); throw new CustomerException(403, "存在不在盘点计划中的数据"); } detailEntity.setQuestStatus(3); + detailEntity.setId(questDetaiId); ls.add(detailEntity); } - questDetailService.updateBatchById(ls); + baseMapper.updatePositionCodeList(taskSearchDTO.getQuestNum(),ls); } @Override @@ -1121,12 +1557,14 @@ public class TaskQuestServiceImpl extends BaseServiceImpl list = new ArrayList<>(); + list.add(questDetailEntity); + baseMapper.insertQuestDetail(taskSearchDTO.getQuestNum(),list); Long questDetailId = questDetailEntity.getId(); Integer stockNum = questDetailEntity.getStockNum(); Integer lossNum = 0; @@ -1164,17 +1602,21 @@ public class TaskQuestServiceImpl extends BaseServiceImpl queryWrapper = Wrappers.query().lambda() - .eq(QuestDetailEntity::getQuestId, taskSearchDTO.getTaskId()) - .eq(QuestDetailEntity::getWarehouseId, taskSearchDTO.getWarehouseId()) - .eq(QuestDetailEntity::getQuestType, 3); + QuestDetailEntity detailEntity = new QuestDetailEntity(); + detailEntity.setQuestId(taskSearchDTO.getTaskId()); + detailEntity.setWarehouseId(taskSearchDTO.getWarehouseId()); + detailEntity.setQuestType(3); + +// LambdaQueryWrapper queryWrapper = Wrappers.query().lambda() +// .eq(QuestDetailEntity::getQuestId, taskSearchDTO.getTaskId()) +// .eq(QuestDetailEntity::getWarehouseId, taskSearchDTO.getWarehouseId()) +// .eq(QuestDetailEntity::getQuestType, 3); if (Func.equals(isInventory,1)){ - queryWrapper - .eq(QuestDetailEntity::getIncomingBatch, taskSearchDTO.getOrderCode()); + detailEntity.setIncomingBatch(taskSearchDTO.getOrderCode()); }else { - queryWrapper.eq(QuestDetailEntity::getOrderCode, taskSearchDTO.getOrderCode()); + detailEntity.setOrderCode(taskSearchDTO.getOrderCode()); } - List questDetailEntities = questDetailService.list(queryWrapper); + List questDetailEntities = baseMapper.selectTaskInfo(taskSearchDTO.getQuestNum(),detailEntity); List type = questDetailEntities.stream().filter(f -> Func.isNotEmpty(f.getQuestTarget())).map(QuestDetailEntity::getQuestTarget).distinct().collect(Collectors.toList()); if (Func.isEmpty(type)){ return null; @@ -1254,6 +1696,7 @@ public class TaskQuestServiceImpl extends BaseServiceImpl list = questDetailChildService.list(new QueryWrapper().lambda() .eq(QuestDetailChildEntity::getIsDeleted,0) .eq(QuestDetailChildEntity::getQuestDetailId,questDetailVO.getId()) @@ -1358,15 +1801,31 @@ public class TaskQuestServiceImpl extends BaseServiceImpl questDetailEntity = baseMapper.selectQuestDetailList(taskSearchDTO.getQuestNum(), questDetail); +// if(Objects.isNull(questDetailEntity)){ +// questDetailEntity = new QuestDetailEntity(); +// questDetailEntity.setOrdePackageCode(orderPackageCode); +// } return R.data(questDetailEntity); } + /** + * 查询盘点任务数据 + * @param questNum + * @param questDetail + * @return + */ + @Override + public List selectTaskInfo(String questNum, QuestDetailEntity questDetail) { + return baseMapper.selectTaskInfo(questNum,questDetail); + } + private QuestDetailChildEntity addQuestDetailChild(Integer num,String cargoName,Long questDetaiId,Long warehouseId){ @@ -1457,12 +1916,21 @@ public class TaskQuestServiceImpl extends BaseServiceImpl questDetailEntityList = questDetailService.list(Wrappers.query().lambda() - .eq(QuestDetailEntity::getQuestId, taskQuestId) - .like(QuestDetailEntity::getOrderCode, incomingBatch) - .eq(QuestDetailEntity::getQuestType, 3) - .in(QuestDetailEntity::getQuestTarget, 1,2) - .eq(QuestDetailEntity::getWarehouseId, taskSearchDTO.getWarehouseId())); +// List questDetailEntityList = questDetailService.list(Wrappers.query().lambda() +// .eq(QuestDetailEntity::getQuestId, taskQuestId) +// .like(QuestDetailEntity::getOrderCode, incomingBatch) +// .eq(QuestDetailEntity::getQuestType, 3) +// .in(QuestDetailEntity::getQuestTarget, 1,2) +// .eq(QuestDetailEntity::getWarehouseId, taskSearchDTO.getWarehouseId())); + + QuestDetailEntity questDetail = new QuestDetailEntity(); + questDetail.setQuestId(taskQuestId); + questDetail.setQuestType(3); + questDetail.setWarehouseId(taskSearchDTO.getWarehouseId()); + questDetail.setOrderCode(incomingBatch); + List questDetailEntityList = baseMapper.selectTaskInfo(taskSearchDTO.getQuestNum(),questDetail); + + if (Func.isNotEmpty(questDetailEntityList) && questDetailEntityList.size()>0){ TaskContractVO taskContractVO = new TaskContractVO(); Map> orderMap = questDetailEntityList.stream().collect(Collectors.groupingBy(QuestDetailEntity::getOrderCode)); @@ -1491,12 +1959,24 @@ public class TaskQuestServiceImpl extends BaseServiceImplquery().lambda() - .eq(QuestDetailEntity::getOrderId, distributionStockArticleEntity.getId()) - .eq(QuestDetailEntity::getQuestId, taskQuestId) - .eq(QuestDetailEntity::getQuestType, 3) - .eq(QuestDetailEntity::getQuestStatus, 1)); - taskContractVO.setUnTotal(count.intValue()); + QuestDetailEntity questDetai = new QuestDetailEntity(); + questDetai.setOrderId(distributionStockArticleEntity.getId()); + questDetai.setQuestId(taskQuestId); + questDetai.setQuestType(3); + questDetai.setQuestStatus(1); + List questDetailEntities = baseMapper.selectQuestDetailList(taskSearchDTO.getQuestNum(), questDetai); + if(questDetailEntities.isEmpty()){ + taskContractVO.setUnTotal(0); + }else{ + long count = questDetailEntities.stream().filter(w -> w.getQuestStatus().equals(1)).count(); + taskContractVO.setUnTotal((int) count); + } +// Long count = questDetailService.count(Wrappers.query().lambda() +// .eq(QuestDetailEntity::getOrderId, distributionStockArticleEntity.getId()) +// .eq(QuestDetailEntity::getQuestId, taskQuestId) +// .eq(QuestDetailEntity::getQuestType, 3) +// .eq(QuestDetailEntity::getQuestStatus, 1)); +// taskContractVO.setUnTotal(count.intValue()); taskContractVOS.add(taskContractVO); List parcelList = distributionParcelListClient.getParcelListByStockArticleId(distributionStockArticleEntity.getId()); if (Func.isEmpty(parcelList)) { @@ -1511,10 +1991,10 @@ public class TaskQuestServiceImpl extends BaseServiceImpl detailEntities = new ArrayList<>(); + detailEntities.add(questDetailEntity); + baseMapper.insertQuestDetail(taskSearchDTO.getQuestNum(),detailEntities); +// questDetailService.save(questDetailEntity); } }); taskContractVO.setZktotal(libNum.get()); @@ -1536,12 +2019,20 @@ public class TaskQuestServiceImpl extends BaseServiceImpl zeroQuestDetailEntityList = questDetailService.list(Wrappers.query().lambda() - .eq(QuestDetailEntity::getQuestId, taskQuestId) - .like(QuestDetailEntity::getOrderCode, incomingBatch) - .eq(QuestDetailEntity::getQuestType, 3) - .eq(QuestDetailEntity::getQuestTarget, 2) - .eq(QuestDetailEntity::getWarehouseId, taskSearchDTO.getWarehouseId())); +// List zeroQuestDetailEntityList = questDetailService.list(Wrappers.query().lambda() +// .eq(QuestDetailEntity::getQuestId, taskQuestId) +// .like(QuestDetailEntity::getOrderCode, incomingBatch) +// .eq(QuestDetailEntity::getQuestType, 3) +// .eq(QuestDetailEntity::getQuestTarget, 2) +// .eq(QuestDetailEntity::getWarehouseId, taskSearchDTO.getWarehouseId())); + QuestDetailEntity detail = new QuestDetailEntity(); + detail.setQuestId(taskQuestId); + detail.setOrderCode(incomingBatch); + detail.setQuestType(3); + detail.setQuestTarget(2); + detail.setWarehouseId(taskSearchDTO.getWarehouseId()); + List zeroQuestDetailEntityList = baseMapper.selectQuestDetailList(taskSearchDTO.getQuestNum(),detail); + if (Func.isNotEmpty(zeroQuestDetailEntityList)){ for (QuestDetailEntity questDetailEntity : zeroQuestDetailEntityList) { TaskContractVO contractVO = new TaskContractVO(); @@ -1571,7 +2062,7 @@ public class TaskQuestServiceImpl extends BaseServiceImpl detailEntities = new ArrayList<>(); + detailEntities.add(questDetailEntity); + baseMapper.insertQuestDetail(taskSearchDTO.getQuestNum(),detailEntities); +// questDetailService.save(questDetailEntity); taskContractVO.setIsZero(1); taskContractVO.setIsInventory(0); taskContractVOS.add(taskContractVO); @@ -1596,12 +2090,23 @@ public class TaskQuestServiceImpl extends BaseServiceImpl inventoryQuestDetailEntityList = questDetailService.list(Wrappers.query().lambda() + /*List inventoryQuestDetailEntityList = questDetailService.list(Wrappers.query().lambda() .eq(QuestDetailEntity::getQuestId, taskQuestId) .eq(QuestDetailEntity::getIncomingBatch,incomingBatch) .eq(QuestDetailEntity::getQuestType, 3) .eq(QuestDetailEntity::getQuestTarget, 3) - .eq(QuestDetailEntity::getWarehouseId, taskSearchDTO.getWarehouseId())); + .eq(QuestDetailEntity::getWarehouseId, taskSearchDTO.getWarehouseId()));*/ + + QuestDetailEntity detail = new QuestDetailEntity(); + detail.setQuestId(taskQuestId); + detail.setOrderCode(incomingBatch); + detail.setQuestType(3); + detail.setQuestTarget(3); + detail.setWarehouseId(taskSearchDTO.getWarehouseId()); + List inventoryQuestDetailEntityList = baseMapper.selectQuestDetailList(taskSearchDTO.getQuestNum(),detail); + + + if (Func.isNotEmpty(inventoryQuestDetailEntityList) && inventoryQuestDetailEntityList.size()>0){ int sum = inventoryQuestDetailEntityList.stream().filter(iqd -> Func.equals(iqd.getQuestStatus(), 1)).mapToInt(QuestDetailEntity::getStockNum).sum(); inventoryQuestDetailEntityList.forEach(iqd->{ @@ -1636,7 +2141,11 @@ public class TaskQuestServiceImpl extends BaseServiceImpl detailEntities = new ArrayList<>(); + detailEntities.add(questDetailEntity); + baseMapper.insertQuestDetail(taskSearchDTO.getQuestNum(),detailEntities); + +// questDetailService.save(questDetailEntity); TaskContractVO taskContractVO = new TaskContractVO(); taskContractVO.setOrderId(questDetailEntity.getStockId()); taskContractVO.setOrderCode(questDetailEntity.getOrderCode()); @@ -1657,7 +2166,7 @@ public class TaskQuestServiceImpl extends BaseServiceImpl implements IWarehouseRetentionRecordService { private final IDistributionLoadscanClient distributionLoadscanClient; private final IDistributionParcelListClient distributionParcelListClient; + private final IWarehouseRetentionScanService warehouseRetentionScanService; + private final IDistributionDeliveryListClient deliveryListClient; + private final IBasicdataWarehouseClient warehouseClient; @Override public IPage selectWarehouseRetentionRecordPage(IPage page, WarehouseRetentionRecordVO warehouseRetentionRecord) { @@ -117,4 +143,103 @@ public class WarehouseRetentionRecordServiceImpl extends BaseServiceImplquery().lambda() + .eq(WarehouseRetentionRecordEntity::getRetentionType, RetentionTypeConstant.peisongzhiliu.getValue()) + .eq(WarehouseRetentionRecordEntity::getTaskId, deliveryId)); + if (Func.isEmpty(retentionRecordEntity)){ + return null; + } + WarehouseRetentionRecordVO warehouseRetentionRecordVO = WarehouseRetentionRecordWrapper.build().entityVO(retentionRecordEntity); + //查询是否存在有对应的扫描列表 + List retentionScanEntityList = warehouseRetentionScanService.list(Wrappers.query().lambda() + .eq(WarehouseRetentionScanEntity::getDeliveryId, retentionRecordEntity.getTaskId()) + .eq(WarehouseRetentionScanEntity::getRefId, retentionRecordEntity.getId())); + if (Func.isNotEmpty(retentionScanEntityList)){ + warehouseRetentionRecordVO.setRetentionScanVOList(WarehouseRetentionScanWrapper.build().listVO(retentionScanEntityList)); + } + return warehouseRetentionRecordVO; + } + + @Override + public R saveRetentionList(RetentionDTO retentionDTO) { + DistributionDeliveryListVO deliveryDriverInfo = deliveryListClient.getDeliveryDriverInfo(retentionDTO.getDeliveryId()); + if (Func.isEmpty(deliveryDriverInfo)){ + //查询配送任务 + log.error("##############查询配送任务失败,deliveryId:{}",retentionDTO.getDeliveryId()); + } + BasicdataWarehouseEntity myCurrentWarehouse = warehouseClient.getMyCurrentWarehouse(); + if (Objects.isNull(myCurrentWarehouse)) { + throw new CustomerException(403, "仓库信息不能为空"); + } + if (Func.isEmpty(deliveryDriverInfo.getDeliverySelfVO())){ + log.error("##############查询配送任务司机失败"); + } + List deliverySelfVO = deliveryDriverInfo.getDeliverySelfVO(); + DistributionDeliverySelfVO distributionDeliverySelfVO = null; + if (deliveryDriverInfo.getKind().equals("1")){ + distributionDeliverySelfVO = deliverySelfVO.stream().filter(d -> d.getIsMaster() == 2).collect(Collectors.toList()).get(0); + }else if (deliveryDriverInfo.getKind().equals("2")){ + distributionDeliverySelfVO = deliverySelfVO.get(0); + + } + WarehouseRetentionRecordEntity warehouseRetentionRecordEntity = new WarehouseRetentionRecordEntity(); + warehouseRetentionRecordEntity.setRetentionType(RetentionTypeConstant.peisongzhiliu.getValue()); + warehouseRetentionRecordEntity.setRetentionWarehouseId(myCurrentWarehouse.getId()); + warehouseRetentionRecordEntity.setRetentionWarehouseName(myCurrentWarehouse.getName()); + warehouseRetentionRecordEntity.setRemark(retentionDTO.getRemarks()); + warehouseRetentionRecordEntity.setTaskId(retentionDTO.getDeliveryId()); + warehouseRetentionRecordEntity.setRetentionCarId(distributionDeliverySelfVO.getId()); + warehouseRetentionRecordEntity.setRetentionCarNo(deliveryDriverInfo.getTrainNumber()); + warehouseRetentionRecordEntity.setAssembleCarPersonId(distributionDeliverySelfVO.getDeliveryId()); + warehouseRetentionRecordEntity.setAssembleCarPersonName(distributionDeliverySelfVO.getDriverName()); + //统计数量 + AtomicInteger retentionQuantity = new AtomicInteger(); + List parcelListEntityList = retentionDTO.getParcelListEntityList(); + if (Func.isNotEmpty(parcelListEntityList)){ + parcelListEntityList.forEach(p->{ + WarehouseRetentionScanEntity warehouseRetentionScanEntity = new WarehouseRetentionScanEntity(); + warehouseRetentionScanEntity.setConditions(1); + warehouseRetentionScanEntity.setDeliveryId(deliveryDriverInfo.getId()); + warehouseRetentionScanEntity.setOrderCode(p.getOrderCode()); + warehouseRetentionScanEntity.setOrderPackageCode(p.getOrderPackageCode()); + warehouseRetentionScanEntity.setOrderId(p.getStockArticleId()); + warehouseRetentionScanEntity.setOrderPackageId(p.getId()); + warehouseRetentionScanService.save(warehouseRetentionScanEntity); + retentionQuantity.getAndAdd(p.getQuantity()); + //缺少一个进行解绑的远程 + }); + } + List parcelNumberEntityList = retentionDTO.getParcelNumberEntityList(); + if (Func.isNotEmpty(parcelNumberEntityList)){ + parcelNumberEntityList.forEach(pn->{ + WarehouseRetentionScanEntity warehouseRetentionScanEntity = new WarehouseRetentionScanEntity(); + warehouseRetentionScanEntity.setConditions(2); + warehouseRetentionScanEntity.setDeliveryId(deliveryDriverInfo.getId()); + warehouseRetentionScanEntity.setOrderId(pn.getStockArticleId()); + warehouseRetentionScanEntity.setOrderPackageId(pn.getParcelListId()); + warehouseRetentionScanService.save(warehouseRetentionScanEntity); + retentionQuantity.getAndAdd(pn.getQuantity()); + }); + } + List detailEntityList = retentionDTO.getDetailEntityList(); + if (Func.isNotEmpty(detailEntityList)){ + detailEntityList.forEach(d->{ + WarehouseRetentionScanEntity warehouseRetentionScanEntity = new WarehouseRetentionScanEntity(); + warehouseRetentionScanEntity.setConditions(3); + warehouseRetentionScanEntity.setDeliveryId(deliveryDriverInfo.getId()); + warehouseRetentionScanEntity.setInventoryId(d.getStockListId()); + warehouseRetentionScanEntity.setMaterialName(d.getMaterialName()); + warehouseRetentionScanEntity.setMaterialNumber(d.getMaterialNumber()); + warehouseRetentionScanEntity.setOrderPackageCode(d.getStockPackageCode()); + warehouseRetentionScanEntity.setOrderPackageId(d.getId()); + warehouseRetentionScanService.save(warehouseRetentionScanEntity); + retentionQuantity.getAndAdd(d.getNum()); + }); + } + + this.save(warehouseRetentionRecordEntity); + return Resp.scanSuccess("操作成功","操作成功"); + } } diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseRetentionScanServiceImpl.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseRetentionScanServiceImpl.java new file mode 100644 index 000000000..5b1e2265d --- /dev/null +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseRetentionScanServiceImpl.java @@ -0,0 +1,57 @@ +/* + * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * Neither the name of the dreamlu.net developer nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * Author: Chill 庄骞 (smallchill@163.com) + */ +package com.logpm.warehouse.service.impl; + +import com.logpm.warehouse.entity.WarehouseRetentionRecordEntity; +import com.logpm.warehouse.entity.WarehouseRetentionScanEntity; +import com.logpm.warehouse.excel.WarehouseRetentionScanExcel; +import com.logpm.warehouse.mapper.WarehouseRetentionScanMapper; +import com.logpm.warehouse.service.IWarehouseRetentionScanService; +import com.logpm.warehouse.vo.WarehouseRetentionRecordVO; +import com.logpm.warehouse.excel.WarehouseRetentionRecordExcel; +import com.logpm.warehouse.vo.WarehouseRetentionScanVO; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springframework.stereotype.Service; +import com.baomidou.mybatisplus.core.conditions.Wrapper; +import com.baomidou.mybatisplus.core.metadata.IPage; +import java.util.List; + +/** + * 滞留扫描记录 服务实现类 + * + * @author BladeX + * @since 2023-11-03 + */ +@Service +public class WarehouseRetentionScanServiceImpl extends BaseServiceImpl implements IWarehouseRetentionScanService { + + @Override + public IPage selectWarehouseRetentionRecordPage(IPage page, WarehouseRetentionScanVO warehouseRetentionScanVO) { + return page.setRecords(baseMapper.selectWarehouseRetentionRecordPage(page, warehouseRetentionScanVO)); + } + + + @Override + public List exportWarehouseRetentionRecord(Wrapper queryWrapper) { + List warehouseRetentionRecordList = baseMapper.exportWarehouseRetentionRecord(queryWrapper); + //warehouseRetentionRecordList.forEach(warehouseRetentionRecord -> { + // warehouseRetentionRecord.setTypeName(DictCache.getValue(DictEnum.YES_NO, WarehouseRetentionRecord.getType())); + //}); + return warehouseRetentionRecordList; + } + +} diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseTaryAllocationServiceImpl.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseTaryAllocationServiceImpl.java index 15fb75c4d..369f055f0 100644 --- a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseTaryAllocationServiceImpl.java +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseTaryAllocationServiceImpl.java @@ -48,4 +48,5 @@ public class WarehouseTaryAllocationServiceImpl extends BaseServiceImpl { + + public static WarehouseRetentionScanWrapper build() { + return new WarehouseRetentionScanWrapper(); + } + + @Override + public WarehouseRetentionScanVO entityVO(WarehouseRetentionScanEntity warehouseRetentionScanEntity) { + WarehouseRetentionScanVO warehouseRetentionScanVO = Objects.requireNonNull(BeanUtil.copy(warehouseRetentionScanEntity, WarehouseRetentionScanVO.class)); +// warehouseRetentionRecordVO.setRetentionTypeName(DictBizCache.getValue(DictBizConstant.WAREHOUSE_TRAY_BINDING_TYPE, warehouseRetentionRecord.getRetentionType())); + //User createUser = UserCache.getUser(warehouseRetentionRecord.getCreateUser()); + //User updateUser = UserCache.getUser(warehouseRetentionRecord.getUpdateUser()); + //warehouseRetentionRecordVO.setCreateUserName(createUser.getName()); + //warehouseRetentionRecordVO.setUpdateUserName(updateUser.getName()); + + return warehouseRetentionScanVO; + } + + +} diff --git a/blade-service/pom.xml b/blade-service/pom.xml index f1c7a59aa..7624a7b3a 100644 --- a/blade-service/pom.xml +++ b/blade-service/pom.xml @@ -49,6 +49,11 @@ blade-biz-common ${bladex.project.version} + + + org.springblade + blade-starter-metrics + org.springblade blade-starter-tenant