From 1ace6c03e8a3d5d9fa3e42d87a6a79a45f600d57 Mon Sep 17 00:00:00 2001 From: PigBaoBei <2739175034@qq.com> Date: Thu, 12 Sep 2024 11:50:08 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BB=A3=E7=A0=81=E6=8F=90=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../feign/IBasicdataWarehouseClient.java | 10 +++ .../app/DistributionAppNewReservationVO.java | 1 + .../entity/WarehouseConfigEntity.java | 58 +++++++++++++++++ .../BasicdataWarehouseController.java | 11 ++++ .../feign/BasicdataWarehouseClient.java | 11 ++++ .../service/IBasicdataWarehouseService.java | 10 +++ .../impl/BasicdataWarehouseServiceImpl.java | 13 ++++ .../mapper/DistributionSignforMapper.xml | 3 +- .../controller/WarehouseConfigController.java | 65 +++++++++++++++++++ .../warehouse/dto/WarehouseConfigDTO.java | 35 ++++++++++ .../mapper/WarehouseConfigMapper.java | 10 +++ .../mapper/WarehouseConfigMapper.xml | 6 ++ .../service/IWarehouseConfigService.java | 10 +++ .../impl/WarehouseConfigServiceImpl.java | 22 +++++++ 14 files changed, 264 insertions(+), 1 deletion(-) create mode 100644 blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/entity/WarehouseConfigEntity.java create mode 100644 blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/controller/WarehouseConfigController.java create mode 100644 blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/WarehouseConfigDTO.java create mode 100644 blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseConfigMapper.java create mode 100644 blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseConfigMapper.xml create mode 100644 blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/IWarehouseConfigService.java create mode 100644 blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseConfigServiceImpl.java diff --git a/blade-service-api/logpm-basicdata-api/src/main/java/com/logpm/basicdata/feign/IBasicdataWarehouseClient.java b/blade-service-api/logpm-basicdata-api/src/main/java/com/logpm/basicdata/feign/IBasicdataWarehouseClient.java index d71f7d28b..3a0fed511 100644 --- a/blade-service-api/logpm-basicdata-api/src/main/java/com/logpm/basicdata/feign/IBasicdataWarehouseClient.java +++ b/blade-service-api/logpm-basicdata-api/src/main/java/com/logpm/basicdata/feign/IBasicdataWarehouseClient.java @@ -19,6 +19,7 @@ package com.logpm.basicdata.feign; import com.alibaba.fastjson.JSONObject; import com.logpm.basicdata.entity.BasicdataWarehouseEntity; +import com.logpm.basicdata.vo.BasicdataWarehouseVO; import org.springblade.common.constant.ModuleNameConstant; import org.springblade.core.mp.support.BladePage; import org.springblade.core.tool.api.R; @@ -104,6 +105,15 @@ public interface IBasicdataWarehouseClient { BasicdataWarehouseEntity getMyCurrentWarehouse(); + /** + * 根据当前用户查询缓存中仓库信息以及仓库的扩展配置 + * + * @return + */ + @GetMapping(API_PREFIX + "/getMyCurrentWarehouseAndConfig") + BasicdataWarehouseVO getMyCurrentWarehouseAndConfig(); + + /** * 获取当前登录人的能查看的仓库 * diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/app/DistributionAppNewReservationVO.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/app/DistributionAppNewReservationVO.java index ac5b9717e..876d28bdc 100644 --- a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/app/DistributionAppNewReservationVO.java +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/app/DistributionAppNewReservationVO.java @@ -50,6 +50,7 @@ public class DistributionAppNewReservationVO implements Serializable { private Integer trayNumber; private Integer loadingQuantity; private Integer signforQuantity; + private Integer isArrive; private List orderList = new ArrayList<>(); diff --git a/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/entity/WarehouseConfigEntity.java b/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/entity/WarehouseConfigEntity.java new file mode 100644 index 000000000..36063a04d --- /dev/null +++ b/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/entity/WarehouseConfigEntity.java @@ -0,0 +1,58 @@ +package com.logpm.warehouse.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.mp.base.BaseEntity; +import org.springblade.core.tenant.mp.TenantEntity; + +@Data +@TableName("logpm_warehouse_config") +@ApiModel(value = "WarehouseConfig对象", description = "仓库扩展配置") +@EqualsAndHashCode(callSuper = true) +public class WarehouseConfigEntity extends TenantEntity { + + + /** + * 仓库ID + */ + @ApiModelProperty(value = "仓库ID") + private Long warehouseId ; + + /** + * 是否严格装车 + */ + @ApiModelProperty(value = "仓库ID") + private Integer isStrictLoading; + + /** + * 预留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; + + + +} 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 c9db23068..83d8d1be8 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 @@ -89,6 +89,17 @@ public class BasicdataWarehouseController extends BladeController { return R.data(detail); } + /** + * 仓库 详情 + */ + @GetMapping("/newDetail") + @ApiOperationSupport(order = 1) + @ApiOperation(value = "详情", notes = "传入warehouseWarehouse") + public R newDetail(@RequestParam Long id) { + BasicdataWarehouseVO detail = warehouseService.newDetail(id); + return R.data(detail); + } + /** * 查询部门下的仓库 */ diff --git a/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/feign/BasicdataWarehouseClient.java b/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/feign/BasicdataWarehouseClient.java index 35ed03499..d1d21f088 100644 --- a/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/feign/BasicdataWarehouseClient.java +++ b/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/feign/BasicdataWarehouseClient.java @@ -27,6 +27,7 @@ import com.baomidou.mybatisplus.core.toolkit.StringUtils; import com.baomidou.mybatisplus.core.toolkit.Wrappers; import com.logpm.basicdata.entity.BasicdataWarehouseEntity; import com.logpm.basicdata.service.IBasicdataWarehouseService; +import com.logpm.basicdata.vo.BasicdataWarehouseVO; import lombok.AllArgsConstructor; import lombok.extern.slf4j.Slf4j; import org.springblade.common.constant.RedisKeyConstant; @@ -162,6 +163,16 @@ public class BasicdataWarehouseClient implements IBasicdataWarehouseClient { return warehouseWarehouseService.getMyCurrentWarehouse(); } + /** + * 根据当前登录人获取Redis中用户选择的仓库信息以及仓库的扩展配置 + * @return + */ + @GetMapping(API_PREFIX+"/getMyCurrentWarehouse") + @Override + public BasicdataWarehouseVO getMyCurrentWarehouseAndConfig() { + return warehouseWarehouseService.getMyCurrentWarehouseAndConfig(); + } + @Override @GetMapping(API_PREFIX+"/getMyWatchWarehouse") public List getMyWatchWarehouse() { diff --git a/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/IBasicdataWarehouseService.java b/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/IBasicdataWarehouseService.java index 714f5e894..e0eeb27d5 100644 --- a/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/IBasicdataWarehouseService.java +++ b/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/IBasicdataWarehouseService.java @@ -128,4 +128,14 @@ public interface IBasicdataWarehouseService extends BaseService detailWarehouse(); List findWarehouseList(String warehouseName); + + + BasicdataWarehouseVO getMyCurrentWarehouseAndConfig(); + + /** + * 查询仓库详情,连同扩展配置 + * @param id + * @return + */ + BasicdataWarehouseVO newDetail(Long id); } diff --git a/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/impl/BasicdataWarehouseServiceImpl.java b/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/impl/BasicdataWarehouseServiceImpl.java index e5043d769..e2a91879b 100644 --- a/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/impl/BasicdataWarehouseServiceImpl.java +++ b/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/impl/BasicdataWarehouseServiceImpl.java @@ -354,4 +354,17 @@ public class BasicdataWarehouseServiceImpl extends BaseServiceImpl findWarehouseList(String warehouseName) { return baseMapper.findWarehouseList(warehouseName); } + + @Override + public BasicdataWarehouseVO getMyCurrentWarehouseAndConfig() { + BasicdataWarehouseEntity myCurrentWarehouse = getMyCurrentWarehouse(); + + return null; + } + + @Override + public BasicdataWarehouseVO newDetail(Long id) { +// baseMapper. + return null; + } } diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionSignforMapper.xml b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionSignforMapper.xml index a8ff58424..543848fa7 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionSignforMapper.xml +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionSignforMapper.xml @@ -2114,7 +2114,8 @@ ) = (SELECT IFNULL(SUM(stock_quantity),0) FROM logpm_distribution_stock WHERE reservation_id = ldr.id), '是', '否' - ) AS isStock + ) AS isStock, + IF(lds.positioning is NULL,0,1) isArrive FROM logpm_distribution_signfor AS lds LEFT JOIN logpm_distribution_reservation AS ldr ON lds.reservation_id = ldr.id diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/controller/WarehouseConfigController.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/controller/WarehouseConfigController.java new file mode 100644 index 000000000..0f6efe6a3 --- /dev/null +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/controller/WarehouseConfigController.java @@ -0,0 +1,65 @@ +/* + * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. + * + * ReWarehouse and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * ReWarehouses of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * ReWarehouses 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 Warehouse. + * 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.baomidou.mybatisplus.core.metadata.IPage; +import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; +import com.logpm.warehouse.entity.WarehouseStockEntity; +import com.logpm.warehouse.excel.WarehouseStockExcel; +import com.logpm.warehouse.service.IWarehouseConfigService; +import com.logpm.warehouse.service.IWarehouseStockService; +import com.logpm.warehouse.vo.WarehouseScanInventoryRecordVO; +import com.logpm.warehouse.vo.WarehouseScanRecordVO; +import com.logpm.warehouse.vo.WarehouseStockVO; +import com.logpm.warehouse.wrapper.WarehouseStockVOWrapper; +import com.logpm.warehouse.wrapper.WarehouseStockWrapper; +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import io.swagger.annotations.ApiParam; +import lombok.AllArgsConstructor; +import org.springblade.core.boot.ctrl.BladeController; +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.tool.api.R; +import org.springblade.core.tool.utils.DateUtil; +import org.springblade.core.tool.utils.Func; +import org.springframework.web.bind.annotation.*; +import springfox.documentation.annotations.ApiIgnore; + +import javax.servlet.http.HttpServletResponse; +import javax.validation.Valid; +import java.util.List; +import java.util.Map; + +/** + * 备货扫描记录 控制器 + * + * @author lmy + * @since 2023-08-24 + */ +@RestController +@AllArgsConstructor +@RequestMapping("/warehouseConfig") +@Api(value = "备货扫描记录", tags = "备货扫描记录接口") +public class WarehouseConfigController extends BladeController { + + private final IWarehouseConfigService warehouseConfigService; + + + +} diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/WarehouseConfigDTO.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/WarehouseConfigDTO.java new file mode 100644 index 000000000..322ba8e23 --- /dev/null +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/dto/WarehouseConfigDTO.java @@ -0,0 +1,35 @@ +/* + * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. + * + * ReWarehouse and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * ReWarehouses of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * ReWarehouses 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 Warehouse. + * 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.WarehouseConfigEntity; +import com.logpm.warehouse.entity.WarehouseStockEntity; +import lombok.Data; +import lombok.EqualsAndHashCode; + +/** + * 仓库扩展配置 数据传输对象实体类 + * + * @author lmy + * @since 2023-08-24 + */ +@Data +@EqualsAndHashCode(callSuper = true) +public class WarehouseConfigDTO extends WarehouseConfigEntity { + private static final long serialVersionUID = 1L; + +} diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseConfigMapper.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseConfigMapper.java new file mode 100644 index 000000000..6edc8bf79 --- /dev/null +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseConfigMapper.java @@ -0,0 +1,10 @@ +package com.logpm.warehouse.mapper; + +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.logpm.warehouse.entity.WarehouseConfigEntity; +import com.logpm.warehouse.entity.WarehouseLog; +import org.apache.ibatis.annotations.Mapper; + +@Mapper +public interface WarehouseConfigMapper extends BaseMapper { +} diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseConfigMapper.xml b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseConfigMapper.xml new file mode 100644 index 000000000..c53015410 --- /dev/null +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseConfigMapper.xml @@ -0,0 +1,6 @@ + + + + + + diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/IWarehouseConfigService.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/IWarehouseConfigService.java new file mode 100644 index 000000000..602a6475d --- /dev/null +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/IWarehouseConfigService.java @@ -0,0 +1,10 @@ +package com.logpm.warehouse.service; + +import com.logpm.warehouse.entity.WarehouseConfigEntity; +import com.logpm.warehouse.entity.WarehouseLog; +import org.springblade.core.mp.base.BaseService; + +public interface IWarehouseConfigService extends BaseService { + + +} diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseConfigServiceImpl.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseConfigServiceImpl.java new file mode 100644 index 000000000..3f2ec193b --- /dev/null +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseConfigServiceImpl.java @@ -0,0 +1,22 @@ +package com.logpm.warehouse.service.impl; + +import com.logpm.warehouse.entity.WarehouseConfigEntity; +import com.logpm.warehouse.entity.WarehouseLog; +import com.logpm.warehouse.mapper.WarehouseConfigMapper; +import com.logpm.warehouse.mapper.WarehouseLogMapper; +import com.logpm.warehouse.service.IWarehouseConfigService; +import com.logpm.warehouse.service.IWarehouseLogService; +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 WarehouseConfigServiceImpl extends BaseServiceImpl implements IWarehouseConfigService { + + private final WarehouseConfigMapper warehouseConfigMapper; + + +}