diff --git a/blade-service-api/logpm-basicdata-api/src/main/java/com/logpm/basicdata/entity/BasicdataClientEntity.java b/blade-service-api/logpm-basicdata-api/src/main/java/com/logpm/basicdata/entity/BasicdataClientEntity.java index b74446146..96e181915 100644 --- a/blade-service-api/logpm-basicdata-api/src/main/java/com/logpm/basicdata/entity/BasicdataClientEntity.java +++ b/blade-service-api/logpm-basicdata-api/src/main/java/com/logpm/basicdata/entity/BasicdataClientEntity.java @@ -105,6 +105,13 @@ public class BasicdataClientEntity extends TenantEntity { @ApiModelProperty(value = "服务类型 ") @TableField(exist = false) private List typeServiceList; + + /** + * 服务类型 + */ + @ApiModelProperty(value = "服务类型 ") + @TableField(exist = false) + private List typeServiceBusiness; /** * 联系人 */ @@ -119,6 +126,7 @@ public class BasicdataClientEntity extends TenantEntity { * 客户类型;1 C端 2 B端 */ @ApiModelProperty(value = "客户类型;1 C端 2 B端") + @TableField(exist = false) private Integer typeService; /** * 省份 diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionSignforEntity.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionSignforEntity.java index 91c62c989..733278373 100644 --- a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionSignforEntity.java +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionSignforEntity.java @@ -96,7 +96,22 @@ public class DistributionSignforEntity extends TenantEntity { * 服务类型 */ @ApiModelProperty(value = "服务类型;预约服务类型;1-上楼、2-超区、3-拆样、4-平移、5-分拣、6-搬运、7-返货;") - private String serveType; + private String deliveryWay; + /** + * 配送类型 + */ + @ApiModelProperty(value = "配送类型;1-商配、2-市配") + private String deliveryType; + /** + * 商城名称 + */ + @ApiModelProperty(value = "商城名称") + private String shoppingName; + /** + * 订单来源 + */ + @ApiModelProperty(value = "订单来源") + private String orderSource; /** * 配送仓库(id) */ @@ -170,10 +185,15 @@ public class DistributionSignforEntity extends TenantEntity { @ApiModelProperty(value = "签收人(名称)") private String signeeName; /** - * 签收状态;1-未签收,2-司机签收,3-文员签收 + * 文员签收状态;1-未签收,2-签收 */ - @ApiModelProperty(value = "签收状态;1-未签收,2-司机签收,3-文员签收") + @ApiModelProperty(value = "文员签收状态;1-未签收,2-签收") private String signingStatus; + /** + * 司机签收状态;1-未签收,2-签收 + */ + @ApiModelProperty(value = "司机签收状态;1-未签收,2-签收") + private String driverSigning; /** * 签收类型;1-签收,2-代签收 */ @@ -210,6 +230,12 @@ public class DistributionSignforEntity extends TenantEntity { @ApiModelProperty(value = "送货车辆(值)") private String deliveryVehicleName; + /** + * 编号 + */ + @ApiModelProperty(value = "编号") + private String number; + /** * 配送时间 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 3293b183d..ce4c6380b 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 @@ -72,6 +72,11 @@ public class DistributionStockListEntity extends TenantEntity { */ @ApiModelProperty(value = "在库订单ID") private Long stockArticleId; + /** + * 在库订单ID + */ + @ApiModelProperty(value = "在库订单ID") + private Long parcelListId; /** * 入库批次号 */ diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionUnpackingDetailsEntity.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionUnpackingDetailsEntity.java new file mode 100644 index 000000000..40d431b07 --- /dev/null +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionUnpackingDetailsEntity.java @@ -0,0 +1,95 @@ +/* + * 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 lombok.EqualsAndHashCode; +import org.springblade.core.tenant.mp.TenantEntity; + +/** + * 拆包明细记录 实体类 + * + * @author cyz + * @since 2023-07-03 + */ +@Data +@TableName("logpm_distribution_unpacking_details") +@ApiModel(value = "DistributionUnpackingDetails对象", description = "拆包明细记录") +@EqualsAndHashCode(callSuper = true) +public class DistributionUnpackingDetailsEntity 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; + /** + * 订单自编号 + */ + @ApiModelProperty(value = "订单自编号") + private String orderSelfNumber; + /** + * 订单ID + */ + @ApiModelProperty(value = "订单ID") + private String stockArticleId; + /** + * 库存品Id + */ + @ApiModelProperty(value = "库存品Id") + private String stockListId; + /** + * 包件id + */ + @ApiModelProperty(value = "包件id") + private String parcelListId; + /** + * 物品名称 + */ + @ApiModelProperty(value = "物品名称") + private String itemName; + /** + * 拆包数量 + */ + @ApiModelProperty(value = "拆包数量") + private Integer unpackingQuantity; + +} diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionParcelDetailsClient.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionParcelDetailsClient.java index 956ada4cd..26a2fcae2 100644 --- a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionParcelDetailsClient.java +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionParcelDetailsClient.java @@ -34,7 +34,7 @@ import org.springframework.web.bind.annotation.RequestParam; public interface IDistributionParcelDetailsClient { String API_PREFIX = "/client"; - String TOP = API_PREFIX + "/parceltop"; + String TOP = API_PREFIX + "/to1212p"; /** * 获取包件清单详情列表 diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionStockupInfoClient.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionStockupInfoClient.java index 9d48c459b..3cd94e481 100644 --- a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionStockupInfoClient.java +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionStockupInfoClient.java @@ -33,7 +33,7 @@ import org.springframework.web.bind.annotation.RequestParam; ) public interface IDistributionStockupInfoClient { - String API_PREFIX = "/client"; + String API_PREFIX = "reservationStockup/client"; String TOP = API_PREFIX + "/top"; /** diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionUnpackingDetailsClient.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionUnpackingDetailsClient.java new file mode 100644 index 000000000..f6525f130 --- /dev/null +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionUnpackingDetailsClient.java @@ -0,0 +1,49 @@ +/* + * 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.feign; + +import org.springblade.core.mp.support.BladePage; +import com.logpm.distribution.entity.DistributionUnpackingDetailsEntity; +import org.springframework.cloud.openfeign.FeignClient; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.RequestParam; + +/** + * 拆包明细记录 Feign接口类 + * + * @author cyz + * @since 2023-07-03 + */ +@FeignClient( + value = "blade-distributionUnpackingDetails" +) +public interface IDistributionUnpackingDetailsClient { + + String API_PREFIX = "/client"; + String TOP = API_PREFIX + "/to45p"; + + /** + * 获取拆包明细记录列表 + * + * @param current 页号 + * @param size 页数 + * @return BladePage + */ + @GetMapping(TOP) + BladePage top(@RequestParam("current") Integer current, @RequestParam("size") Integer size); + +} diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionSignforsnmbVO.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionSignforsnmbVO.java index b79928e5a..a77bef926 100644 --- a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionSignforsnmbVO.java +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionSignforsnmbVO.java @@ -13,27 +13,15 @@ import lombok.Data; public class DistributionSignforsnmbVO { /** - * 客户总数 + * 司机待签收 */ - @ApiModelProperty(value = "客户总数") - private Integer customNub; + @ApiModelProperty(value = "司机待签收") + private Integer driverNub; /** - * 订单总数 + * 文员待签收 */ - @ApiModelProperty(value = "订单总数") - private Integer ordersNub; - - /** - * 已签收总数 - */ - @ApiModelProperty(value = "已签收总数") - private Integer signedNub; - /** - * 未签收总数 - */ - @ApiModelProperty(value = "未签收总数") - private Integer unsignedNub; - + @ApiModelProperty(value = "文员待签收") + private Integer clerkNub; } diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionUnpackingDetailsVO.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionUnpackingDetailsVO.java new file mode 100644 index 000000000..41b77b57a --- /dev/null +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionUnpackingDetailsVO.java @@ -0,0 +1,35 @@ +/* + * 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.vo; + +import com.logpm.distribution.entity.DistributionUnpackingDetailsEntity; +import org.springblade.core.tool.node.INode; +import lombok.Data; +import lombok.EqualsAndHashCode; + +/** + * 拆包明细记录 视图实体类 + * + * @author cyz + * @since 2023-07-03 + */ +@Data +@EqualsAndHashCode(callSuper = true) +public class DistributionUnpackingDetailsVO extends DistributionUnpackingDetailsEntity { + private static final long serialVersionUID = 1L; + +} diff --git a/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/controller/BasicdataClientController.java b/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/controller/BasicdataClientController.java index f1beb05b6..74a13ac16 100644 --- a/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/controller/BasicdataClientController.java +++ b/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/controller/BasicdataClientController.java @@ -17,6 +17,7 @@ package com.logpm.basicdata.controller; import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; +import com.logpm.basicdata.service.IBasicdataStoreBusinessService; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiParam; @@ -67,7 +68,7 @@ public class BasicdataClientController extends BladeController { @ApiOperationSupport(order = 1) @ApiOperation(value = "详情", notes = "传入basicdataClient") public R detail(BasicdataClientEntity basicdataClient) { - BasicdataClientEntity detail = basicdataClientService.getOne(Condition.getQueryWrapper(basicdataClient)); + BasicdataClientEntity detail = basicdataClientService.getOneOwn(Condition.getQueryWrapper(basicdataClient)); return R.data(detail); } /** diff --git a/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/IBasicdataClientService.java b/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/IBasicdataClientService.java index 661262d96..ad72d8dab 100644 --- a/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/IBasicdataClientService.java +++ b/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/IBasicdataClientService.java @@ -17,6 +17,7 @@ package com.logpm.basicdata.service; import com.baomidou.mybatisplus.core.conditions.Wrapper; +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.logpm.basicdata.entity.BasicdataClientEntity; import com.logpm.basicdata.vo.BasicdataClientVO; import com.logpm.basicdata.excel.BasicdataClientExcel; @@ -59,4 +60,11 @@ public interface IBasicdataClientService extends BaseService listName(String name); Boolean ownDeleteLogic(List toLongList); + + /** + * 详情 + * @param queryWrapper + * @return + */ + BasicdataClientEntity getOneOwn(QueryWrapper queryWrapper); } 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 1cab165a8..cc1f42c6e 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 @@ -17,7 +17,9 @@ package com.logpm.basicdata.service.impl; import com.baomidou.mybatisplus.core.conditions.Wrapper; +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.StringUtils; import com.baomidou.mybatisplus.core.toolkit.Wrappers; @@ -29,10 +31,15 @@ import com.logpm.basicdata.vo.BasicdataClientVO; import lombok.AllArgsConstructor; import lombok.extern.slf4j.Slf4j; import org.springblade.core.mp.base.BaseServiceImpl; +import org.springblade.core.tool.utils.BeanUtil; +import org.springblade.core.tool.utils.Func; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; +import java.util.ArrayList; +import java.util.Iterator; import java.util.List; +import java.util.concurrent.locks.Condition; /** * 基础客户表 服务实现类 @@ -73,6 +80,51 @@ public class BasicdataClientServiceImpl extends BaseServiceImpl typeServiceBusiness = basicdataClient.getTypeServiceBusiness(); + List list = basicdataStoreBusinessService.list(Wrappers.query().lambda() + .eq(BasicdataStoreBusinessEntity::getClientId, basicdataClient.getId()) + ); + if(list.size() > 0){ + //有数据 + List stringList = new ArrayList<>(); + list.forEach ( i -> { + boolean b1 = basicdataClient.getTypeServiceList().stream().anyMatch(b -> b.equals(i.getTypeService())); + if(b1){ + //有 + Iterator iterator1 = basicdataClient.getTypeServiceList().iterator(); + while (iterator1.hasNext()){ + String next = iterator1.next(); + if(next.equals(i.getTypeService())){ + if(next.equals("3")){ + BasicdataStoreBusinessEntity businessEntity = new BasicdataStoreBusinessEntity(); + BeanUtil.copyProperties(i,businessEntity); + businessEntity.setMold(basicdataClient.getBusinessType()); + basicdataStoreBusinessService.updateById(businessEntity); + } + iterator1.remove(); + } + } + }else{ + //没有 + stringList.add(i.getId()); + } + }); + if(stringList.size() > 0){ + basicdataStoreBusinessService.deleteLogic(stringList); + } + + } + for (String s : basicdataClient.getTypeServiceList()) { + //添加服务类型 + BasicdataStoreBusinessEntity basicdataStoreBusinessEntity = new BasicdataStoreBusinessEntity(); + basicdataStoreBusinessEntity.setTypeService(s); + basicdataStoreBusinessEntity.setClientId(basicdataClient.getId().toString()); + if(s.equals("3")){ + basicdataStoreBusinessEntity.setMold(basicdataClient.getBusinessType()); + } + basicdataStoreBusinessService.save(basicdataStoreBusinessEntity); + } + }else{ String linkman = basicdataClient.getLinkman(); String phone = basicdataClient.getPhone(); @@ -155,4 +207,11 @@ public class BasicdataClientServiceImpl extends BaseServiceImpl queryWrapper) { + BasicdataClientEntity one = this.getOne(queryWrapper); + one.setTypeServiceBusiness(basicdataStoreBusinessService.list(Wrappers.query().lambda().eq(BasicdataStoreBusinessEntity::getClientId,one.getId()))); + return one; + } + } diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionParcelDetailsController.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionParcelDetailsController.java index ee9f0ddf7..ca80ff645 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionParcelDetailsController.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionParcelDetailsController.java @@ -16,6 +16,8 @@ */ package com.logpm.distribution.controller; +import com.alibaba.fastjson.JSONObject; +import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiParam; 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 2e787e528..04b17f822 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 @@ -116,7 +116,6 @@ public class DistributionSignforController extends BladeController { @ApiOperationSupport(order = 3) @ApiOperation(value = "分页", notes = "传入distributionSignfor") public R> page(DistributionSignforVO distributionSignfor, Query query) { - IPage pages = distributionSignforService.selectDistributionSignforPage(Condition.getPage(query), distributionSignfor); return R.data(pages); } diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionStockArticleController.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionStockArticleController.java index 8aaf10ebf..c5f5232c8 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionStockArticleController.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionStockArticleController.java @@ -16,41 +16,38 @@ */ package com.logpm.distribution.controller; +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; import com.logpm.distribution.dto.DistributionStockArticleDTO; +import com.logpm.distribution.entity.DistributionStockArticleEntity; +import com.logpm.distribution.excel.DistributionStockArticleExcel; +import com.logpm.distribution.service.IDistributionStockArticleService; +import com.logpm.distribution.vo.DistributionStockArticleVO; 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.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.secure.BladeUser; import org.springblade.core.tool.api.R; +import org.springblade.core.tool.constant.BladeConstant; +import org.springblade.core.tool.utils.DateUtil; import org.springblade.core.tool.utils.Func; -import org.springblade.system.entity.Dict; import org.springblade.system.entity.DictBiz; import org.springblade.system.feign.IDictBizClient; -import org.springblade.system.feign.IDictClient; import org.springframework.web.bind.annotation.*; -import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; -import com.baomidou.mybatisplus.core.metadata.IPage; -import com.logpm.distribution.entity.DistributionStockArticleEntity; -import com.logpm.distribution.vo.DistributionStockArticleVO; -import com.logpm.distribution.excel.DistributionStockArticleExcel; -import com.logpm.distribution.service.IDistributionStockArticleService; -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.text.SimpleDateFormat; +import javax.servlet.http.HttpServletResponse; +import javax.validation.Valid; import java.util.Date; -import java.util.Map; import java.util.List; -import javax.servlet.http.HttpServletResponse; +import java.util.Map; +import java.util.Objects; /** * 配送在库订单 控制器 @@ -87,6 +84,7 @@ public class DistributionStockArticleController extends BladeController { public R> list(@ApiIgnore @RequestParam Map distributionStockArticle, Query query) { IPage pages = distributionStockArticleService.page(Condition.getPage(query), Condition.getQueryWrapper(distributionStockArticle, DistributionStockArticleEntity.class)); pages.getRecords().forEach( i ->{ + Integer typeService = i.getTypeService(); //计算在库天数 // SimpleDateFormat simpleFormat = new SimpleDateFormat("yyyy-MM-dd hh:mm:ss"); long time1 = i.getWarehouseEntryTime().getTime(); //入库 @@ -108,31 +106,32 @@ public class DistributionStockArticleController extends BladeController { break; } R> distribution_type = dictBizClient.getList("distribution_type"); - if(Func.isNotEmpty(distribution_type.getData())){ - DictBiz dictBiz = distribution_type.getData().get(i.getTypeService()-1); - i.setTypeName(dictBiz.getDictValue()); - switch (i.getState()){ - case 1: - i.setStateName("待预约"); - break; - case 2: - i.setStateName("已预约"); - break; - case 3: - i.setStateName("待配送"); - break; - case 4: - i.setStateName("配送中"); - break; - case 5: - i.setStateName("已配送"); - break; - case 6: - i.setStateName("已完成"); - break; + if(!Objects.isNull(typeService)){ + if(Func.isNotEmpty(distribution_type.getData())){ + DictBiz dictBiz = distribution_type.getData().get(typeService-1); + i.setTypeName(dictBiz.getDictValue()); + switch (i.getState()){ + case 1: + i.setStateName("待预约"); + break; + case 2: + i.setStateName("已预约"); + break; + case 3: + i.setStateName("待配送"); + break; + case 4: + i.setStateName("配送中"); + break; + case 5: + i.setStateName("已配送"); + break; + case 6: + i.setStateName("已完成"); + break; + } } } - }); return R.data(pages); } diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionUnpackingDetailsController.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionUnpackingDetailsController.java new file mode 100644 index 000000000..9af6a3524 --- /dev/null +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionUnpackingDetailsController.java @@ -0,0 +1,150 @@ +/* + * 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.controller; + +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.distribution.entity.DistributionUnpackingDetailsEntity; +import com.logpm.distribution.vo.DistributionUnpackingDetailsVO; +import com.logpm.distribution.excel.DistributionUnpackingDetailsExcel; +import com.logpm.distribution.service.IDistributionUnpackingDetailsService; +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 cyz + * @since 2023-07-03 + */ +@RestController +@AllArgsConstructor +@RequestMapping("/distributionUnpackingDetails") +@Api(value = "拆包明细记录", tags = "拆包明细记录接口") +public class DistributionUnpackingDetailsController extends BladeController { + + private final IDistributionUnpackingDetailsService distributionUnpackingDetailsService; + + /** + * 拆包明细记录 详情 + */ + @GetMapping("/detail") + @ApiOperationSupport(order = 1) + @ApiOperation(value = "详情", notes = "传入distributionUnpackingDetails") + public R detail(DistributionUnpackingDetailsEntity distributionUnpackingDetails) { + DistributionUnpackingDetailsEntity detail = distributionUnpackingDetailsService.getOne(Condition.getQueryWrapper(distributionUnpackingDetails)); + return R.data(detail); + } + /** + * 拆包明细记录 分页 + */ + @GetMapping("/list") + @ApiOperationSupport(order = 2) + @ApiOperation(value = "分页", notes = "传入distributionUnpackingDetails") + public R> list(@ApiIgnore @RequestParam Map distributionUnpackingDetails, Query query) { + IPage pages = distributionUnpackingDetailsService.page(Condition.getPage(query), Condition.getQueryWrapper(distributionUnpackingDetails, DistributionUnpackingDetailsEntity.class)); + return R.data(pages); + } + + /** + * 拆包明细记录 自定义分页 + */ + @GetMapping("/page") + @ApiOperationSupport(order = 3) + @ApiOperation(value = "分页", notes = "传入distributionUnpackingDetails") + public R> page(DistributionUnpackingDetailsVO distributionUnpackingDetails, Query query) { + IPage pages = distributionUnpackingDetailsService.selectDistributionUnpackingDetailsPage(Condition.getPage(query), distributionUnpackingDetails); + return R.data(pages); + } + + /** + * 拆包明细记录 新增 + */ + @PostMapping("/save") + @ApiOperationSupport(order = 4) + @ApiOperation(value = "新增", notes = "传入distributionUnpackingDetails") + public R save(@Valid @RequestBody DistributionUnpackingDetailsEntity distributionUnpackingDetails) { + return R.status(distributionUnpackingDetailsService.save(distributionUnpackingDetails)); + } + + /** + * 拆包明细记录 修改 + */ + @PostMapping("/update") + @ApiOperationSupport(order = 5) + @ApiOperation(value = "修改", notes = "传入distributionUnpackingDetails") + public R update(@Valid @RequestBody DistributionUnpackingDetailsEntity distributionUnpackingDetails) { + return R.status(distributionUnpackingDetailsService.updateById(distributionUnpackingDetails)); + } + + /** + * 拆包明细记录 新增或修改 + */ + @PostMapping("/submit") + @ApiOperationSupport(order = 6) + @ApiOperation(value = "新增或修改", notes = "传入distributionUnpackingDetails") + public R submit(@Valid @RequestBody DistributionUnpackingDetailsEntity distributionUnpackingDetails) { + return R.status(distributionUnpackingDetailsService.saveOrUpdate(distributionUnpackingDetails)); + } + + /** + * 拆包明细记录 删除 + */ + @PostMapping("/remove") + @ApiOperationSupport(order = 7) + @ApiOperation(value = "逻辑删除", notes = "传入ids") + public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) { + return R.status(distributionUnpackingDetailsService.deleteLogic(Func.toLongList(ids))); + } + + + /** + * 导出数据 + */ + @GetMapping("/export-distributionUnpackingDetails") + @ApiOperationSupport(order = 9) + @ApiOperation(value = "导出数据", notes = "传入distributionUnpackingDetails") + public void exportDistributionUnpackingDetails(@ApiIgnore @RequestParam Map distributionUnpackingDetails, BladeUser bladeUser, HttpServletResponse response) { + QueryWrapper queryWrapper = Condition.getQueryWrapper(distributionUnpackingDetails, DistributionUnpackingDetailsEntity.class); + //if (!AuthUtil.isAdministrator()) { + // queryWrapper.lambda().eq(DistributionUnpackingDetails::getTenantId, bladeUser.getTenantId()); + //} + queryWrapper.lambda().eq(DistributionUnpackingDetailsEntity::getIsDeleted, BladeConstant.DB_NOT_DELETED); + List list = distributionUnpackingDetailsService.exportDistributionUnpackingDetails(queryWrapper); + ExcelUtil.export(response, "拆包明细记录数据" + DateUtil.time(), "拆包明细记录数据表", list, DistributionUnpackingDetailsExcel.class); + } + +} diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/dto/DistributionUnpackingDetailsDTO.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/dto/DistributionUnpackingDetailsDTO.java new file mode 100644 index 000000000..5eb5d3125 --- /dev/null +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/dto/DistributionUnpackingDetailsDTO.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.distribution.dto; + +import com.logpm.distribution.entity.DistributionUnpackingDetailsEntity; +import lombok.Data; +import lombok.EqualsAndHashCode; + +/** + * 拆包明细记录 数据传输对象实体类 + * + * @author cyz + * @since 2023-07-03 + */ +@Data +@EqualsAndHashCode(callSuper = true) +public class DistributionUnpackingDetailsDTO extends DistributionUnpackingDetailsEntity { + private static final long serialVersionUID = 1L; + +} diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/excel/DistributionUnpackingDetailsExcel.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/excel/DistributionUnpackingDetailsExcel.java new file mode 100644 index 000000000..7a6dc3e4b --- /dev/null +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/excel/DistributionUnpackingDetailsExcel.java @@ -0,0 +1,123 @@ +/* + * 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.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 cyz + * @since 2023-07-03 + */ +@Data +@ColumnWidth(25) +@HeadRowHeight(20) +@ContentRowHeight(18) +public class DistributionUnpackingDetailsExcel 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 orderSelfNumber; + /** + * 订单ID + */ + @ColumnWidth(20) + @ExcelProperty("订单ID") + private String stockArticleId; + /** + * 库存品Id + */ + @ColumnWidth(20) + @ExcelProperty("库存品Id") + private String stockListId; + /** + * 包件id + */ + @ColumnWidth(20) + @ExcelProperty("包件id") + private String parcelListId; + /** + * 物品名称 + */ + @ColumnWidth(20) + @ExcelProperty("物品名称") + private String itemName; + /** + * 拆包数量 + */ + @ColumnWidth(20) + @ExcelProperty("拆包数量") + private Integer unpackingQuantity; + +} diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionUnpackingDetailsClient.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionUnpackingDetailsClient.java new file mode 100644 index 000000000..cceed1607 --- /dev/null +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionUnpackingDetailsClient.java @@ -0,0 +1,53 @@ +/* + * 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.feign; + +import com.baomidou.mybatisplus.core.metadata.IPage; +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.distribution.entity.DistributionUnpackingDetailsEntity; +import com.logpm.distribution.service.IDistributionUnpackingDetailsService; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.RestController; +import springfox.documentation.annotations.ApiIgnore; + +/** + * 拆包明细记录 Feign实现类 + * + * @author cyz + * @since 2023-07-03 + */ +@ApiIgnore() +@RestController +@AllArgsConstructor +public class DistributionUnpackingDetailsClient implements IDistributionUnpackingDetailsClient { + + private final IDistributionUnpackingDetailsService distributionUnpackingDetailsService; + + @Override + @GetMapping(TOP) + public BladePage top(Integer current, Integer size) { + Query query = new Query(); + query.setCurrent(current); + query.setSize(size); + IPage page = distributionUnpackingDetailsService.page(Condition.getPage(query)); + return BladePage.of(page); + } + +} diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionSignforMapper.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionSignforMapper.java index a9995e8b2..f0dd1c313 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionSignforMapper.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionSignforMapper.java @@ -41,7 +41,7 @@ public interface DistributionSignforMapper extends BaseMapper selectDistributionSignforPage(IPage page, DistributionSignforVO distributionSignfor); + List selectDistributionSignforPage(IPage page,@Param("param") DistributionSignforVO distributionSignfor); /** @@ -79,4 +79,18 @@ public interface DistributionSignforMapper extends BaseMapper selectCustomNub(DistributionSignforDTO distributionSignfor); + /** + * 司机未签收 + * + * @param distributionSignfor + * @return + */ + Integer selectdriverNubCount(@Param("param") DistributionSignforDTO distributionSignfor); + /** + * 文员未签收 + * + * @param distributionSignfor + * @return + */ + Integer selectclerkNubCount(@Param("param") DistributionSignforDTO distributionSignfor); } 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 f98112f02..a8b68eb29 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 @@ -20,19 +20,22 @@ - + + - - + + - + + - + + @@ -43,8 +46,94 @@ - + SELECT + id id, + number number, + order_id orderId, + reservation_id reservationId, + consignee_id consigneeId, + consignee_name consigneeName, + delivery_phone deliveryPhone, + delivery_address delivery_Address, + delivery_type deliveryType, + delivery_way deliveryWay, + warehouse_name warehouseName, + warehouse_id warehouseId, + train_number trainNumber, + order_total orderTotal, + total total, + loaded_number loadedNumber, + received_quantity receivedQuantity, + delivery_driver_name deliveryDriverName, + delivery_driver_id deliveryDriverId, + delivery_driver_phone deliveryDriverPhone, + signing_time signingTime, + sjsigning_time sjsigningTime, + signee_name signeeName, + signee_id signeeId, + signing_status signingStatus, + driver_signing driverSigning, + signing_type signingType, + clerk_sign_pictures clerkSignPictures, + delivery_sign_pictures deliverySignPictures, + service_number serviceNumber, + notes notes, + delivery_time deliveryTime, + delivery_vehicle_id deliveryVehicleId, + delivery_vehicle_name deliveryVehicleName, + shopping_name shoppingName, + order_source orderSource + FROM + logpm_distribution_signfor + + is_deleted = 0 + + and number like concat('%',#{param.number},'%') + + + and shopping_name like concat('%',#{param.shoppingName},'%') + + + and date_format(delivery_time,'%y%m%d%') = date_format(#{param.deliveryTime},'%y%m%d%') + + + and date_format(signing_time,'%y%m%d%') = date_format(#{param.signingTime},'%y%m%d%') + + + and date_format(sjsigning_time,'%y%m%d%') = date_format(#{param.sjsigningTime},'%y%m%d%') + + + and order_id like concat('%',#{param.orderId},'%') + + + and consignee_name like concat('%',#{param.consigneeName},'%') + + + and delivery_type = #{param.deliveryType} + + + and signing_status = #{param.signingStatus} + + + and order_source = #{param.orderSource} + + + and delivery_phone = #{param.deliveryPhone} + + + and train_number like concat('%',#{param.trainNumber},'%') + + + and delivery_driver_name like concat('%',#{param.deliveryDriverName},'%') + + + and delivery_address like concat('%',#{param.deliveryAddress},'%') + + + and driver_signing = #{param.driverSigning} + + @@ -63,5 +152,101 @@ + + diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionUnpackingDetailsMapper.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionUnpackingDetailsMapper.java new file mode 100644 index 000000000..1fe3bad7f --- /dev/null +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionUnpackingDetailsMapper.java @@ -0,0 +1,54 @@ +/* + * 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.mapper; + +import com.logpm.distribution.entity.DistributionUnpackingDetailsEntity; +import com.logpm.distribution.vo.DistributionUnpackingDetailsVO; +import com.logpm.distribution.excel.DistributionUnpackingDetailsExcel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.baomidou.mybatisplus.core.conditions.Wrapper; +import com.baomidou.mybatisplus.core.metadata.IPage; +import org.apache.ibatis.annotations.Param; +import java.util.List; + +/** + * 拆包明细记录 Mapper 接口 + * + * @author cyz + * @since 2023-07-03 + */ +public interface DistributionUnpackingDetailsMapper extends BaseMapper { + + /** + * 自定义分页 + * + * @param page + * @param distributionUnpackingDetails + * @return + */ + List selectDistributionUnpackingDetailsPage(IPage page, DistributionUnpackingDetailsVO distributionUnpackingDetails); + + + /** + * 获取导出数据 + * + * @param queryWrapper + * @return + */ + List exportDistributionUnpackingDetails(@Param("ew") Wrapper queryWrapper); + +} diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionUnpackingDetailsMapper.xml b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionUnpackingDetailsMapper.xml new file mode 100644 index 000000000..567362857 --- /dev/null +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionUnpackingDetailsMapper.xml @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/IDistributionStockArticleService.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/IDistributionStockArticleService.java index caf99b517..f12166f3a 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/IDistributionStockArticleService.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/IDistributionStockArticleService.java @@ -62,6 +62,11 @@ public interface IDistributionStockArticleService extends BaseService addIncrement(Map addvalueInfo); + /** + * 转库存品 + * @param distributionStockArticleDTO + * @return + */ Boolean saveStockRow(DistributionStockArticleDTO distributionStockArticleDTO); R> getStockArticleInfo(String ids); diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/IDistributionUnpackingDetailsService.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/IDistributionUnpackingDetailsService.java new file mode 100644 index 000000000..0a191b48e --- /dev/null +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/IDistributionUnpackingDetailsService.java @@ -0,0 +1,52 @@ +/* + * 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.service; + +import com.baomidou.mybatisplus.core.conditions.Wrapper; +import com.logpm.distribution.entity.DistributionUnpackingDetailsEntity; +import com.logpm.distribution.vo.DistributionUnpackingDetailsVO; +import com.logpm.distribution.excel.DistributionUnpackingDetailsExcel; +import com.baomidou.mybatisplus.core.metadata.IPage; +import org.springblade.core.mp.base.BaseService; +import java.util.List; + +/** + * 拆包明细记录 服务类 + * + * @author cyz + * @since 2023-07-03 + */ +public interface IDistributionUnpackingDetailsService extends BaseService { + /** + * 自定义分页 + * + * @param page + * @param distributionUnpackingDetails + * @return + */ + IPage selectDistributionUnpackingDetailsPage(IPage page, DistributionUnpackingDetailsVO distributionUnpackingDetails); + + + /** + * 导出数据 + * + * @param queryWrapper + * @return + */ + List exportDistributionUnpackingDetails(Wrapper queryWrapper); + +} diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionSignforServiceImpl.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionSignforServiceImpl.java index 5ad0ad46e..1a2f7fda5 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionSignforServiceImpl.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionSignforServiceImpl.java @@ -16,6 +16,7 @@ */ package com.logpm.distribution.service.impl; +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.logpm.distribution.dto.DistributionSignforDTO; import com.logpm.distribution.entity.DistributionSignforEntity; import com.logpm.distribution.vo.DistributionSignforVO; @@ -59,23 +60,13 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl distributionSignforEntityList = baseMapper.selectCustomNub(distributionSignfor); - //订单总数 - Integer OrdersNub = baseMapper.selectOrdersNub(distributionSignfor); - //已签收总数 - Integer SignedNub = baseMapper.selectSignedNub(distributionSignfor); -// //未签收总数 -// Integer UnsignedNub = baseMapper.selectUnsignedNub(distributionSignfor); - distributionSignforsnmbVO.setCustomNub(distributionSignforEntityList.size()); - distributionSignforsnmbVO.setOrdersNub(OrdersNub); - distributionSignforsnmbVO.setUnsignedNub(OrdersNub - SignedNub); - distributionSignforsnmbVO.setSignedNub(SignedNub); + //司机待签收 + Integer driverNub = baseMapper.selectdriverNubCount(distributionSignfor); + //文员待签收 + Integer clerkNub = baseMapper.selectclerkNubCount(distributionSignfor); + distributionSignforsnmbVO.setClerkNub(clerkNub); + distributionSignforsnmbVO.setDriverNub(driverNub); return distributionSignforsnmbVO; } diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionStockArticleServiceImpl.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionStockArticleServiceImpl.java index 96f407714..39ab74430 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionStockArticleServiceImpl.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionStockArticleServiceImpl.java @@ -175,7 +175,7 @@ public class DistributionStockArticleServiceImpl extends BaseServiceImpl implements IDistributionUnpackingDetailsService { + + @Override + public IPage selectDistributionUnpackingDetailsPage(IPage page, DistributionUnpackingDetailsVO distributionUnpackingDetails) { + return page.setRecords(baseMapper.selectDistributionUnpackingDetailsPage(page, distributionUnpackingDetails)); + } + + + @Override + public List exportDistributionUnpackingDetails(Wrapper queryWrapper) { + List distributionUnpackingDetailsList = baseMapper.exportDistributionUnpackingDetails(queryWrapper); + //distributionUnpackingDetailsList.forEach(distributionUnpackingDetails -> { + // distributionUnpackingDetails.setTypeName(DictCache.getValue(DictEnum.YES_NO, DistributionUnpackingDetails.getType())); + //}); + return distributionUnpackingDetailsList; + } + +} diff --git a/blade-service/logpm-factory/src/main/java/com/logpm/factory/comfac/service/impl/AsyncDataServiceImpl.java b/blade-service/logpm-factory/src/main/java/com/logpm/factory/comfac/service/impl/AsyncDataServiceImpl.java index b0dd4754f..bea083d7f 100644 --- a/blade-service/logpm-factory/src/main/java/com/logpm/factory/comfac/service/impl/AsyncDataServiceImpl.java +++ b/blade-service/logpm-factory/src/main/java/com/logpm/factory/comfac/service/impl/AsyncDataServiceImpl.java @@ -78,7 +78,7 @@ public class AsyncDataServiceImpl implements IAsyncDataService { advanceEntity.setOrderTypeName(""); //订单类型名称 可以为空 advanceEntity.setOrderClassName("工厂"); //订单类型 可以为空 advanceEntity.setType(FactoryConstant.PIANO); - advanceEntity.setTotal(panFactoryOrder.getServiceCount()); //订单总数据 + advanceEntity.setTotal(panFactoryOrder.getTotalQuantity()); //订单总数据 advanceEntity.setMctsTruck(StringUtil.isBlank(panFactoryOrder.getDeliveryNumber())?"":panFactoryOrder.getDeliveryNumber()); //车次 advanceEntity.setMtdsNo("");// MTDS单号 可以为空 advanceEntity.setFirstPackName(""); //一级品类 diff --git a/doc/dpm/物流租户系统.pdma.json b/doc/dpm/物流租户系统.pdma.json index d0e55e830..211def179 100644 --- a/doc/dpm/物流租户系统.pdma.json +++ b/doc/dpm/物流租户系统.pdma.json @@ -4,7 +4,7 @@ "avatar": "", "version": "4.5.1", "createdTime": "2023-3-27 13:32:56", - "updatedTime": "2023-6-30 18:03:26", + "updatedTime": "2023-7-3 11:48:44", "dbConns": [], "profile": { "default": { @@ -53151,6 +53151,498 @@ ], "correlations": [], "indexes": [] + }, + { + "id": "34520BCA-7B04-4B57-949B-D386718B529D", + "env": { + "base": { + "nameSpace": "", + "codeRoot": "" + } + }, + "defKey": "logpm_distribution_Unpacking_Details", + "defName": "拆包明细", + "comment": "", + "properties": { + "partitioned by": "(date string)", + "row format delimited": "", + "fields terminated by ','": "", + "collection items terminated by '-'": "", + "map keys terminated by ':'": "", + "store as textfile;": "" + }, + "nameTemplate": "{defKey}[{defName}]", + "notes": {}, + "headers": [ + { + "refKey": "hideInGraph", + "hideInGraph": true + }, + { + "refKey": "defKey", + "freeze": false, + "hideInGraph": false + }, + { + "refKey": "defName", + "freeze": false, + "hideInGraph": false + }, + { + "refKey": "primaryKey", + "freeze": false, + "hideInGraph": false + }, + { + "refKey": "notNull", + "freeze": false, + "hideInGraph": true + }, + { + "refKey": "autoIncrement", + "freeze": false, + "hideInGraph": true + }, + { + "refKey": "domain", + "freeze": false, + "hideInGraph": true + }, + { + "refKey": "type", + "freeze": false, + "hideInGraph": false + }, + { + "refKey": "len", + "freeze": false, + "hideInGraph": false + }, + { + "refKey": "scale", + "freeze": false, + "hideInGraph": false + }, + { + "refKey": "comment", + "freeze": false, + "hideInGraph": true + }, + { + "refKey": "refDict", + "freeze": false, + "hideInGraph": true + }, + { + "refKey": "defaultValue", + "freeze": false, + "hideInGraph": true + }, + { + "refKey": "isStandard", + "freeze": false, + "hideInGraph": false + }, + { + "refKey": "uiHint", + "freeze": false, + "hideInGraph": true + }, + { + "refKey": "extProps", + "freeze": false, + "hideInGraph": true + }, + { + "refKey": "attr1", + "freeze": false, + "hideInGraph": true + }, + { + "refKey": "attr2", + "freeze": false, + "hideInGraph": true + }, + { + "refKey": "attr3", + "freeze": false, + "hideInGraph": true + }, + { + "refKey": "attr4", + "freeze": false, + "hideInGraph": true + }, + { + "refKey": "attr5", + "freeze": false, + "hideInGraph": true + }, + { + "refKey": "attr6", + "freeze": false, + "hideInGraph": true + }, + { + "refKey": "attr7", + "freeze": false, + "hideInGraph": true + }, + { + "refKey": "attr8", + "freeze": false, + "hideInGraph": true + }, + { + "refKey": "attr9", + "freeze": false, + "hideInGraph": true + } + ], + "fields": [ + { + "defKey": "tenant_id", + "defName": "租户号", + "comment": "", + "type": "", + "len": 32, + "scale": "", + "primaryKey": false, + "notNull": false, + "autoIncrement": false, + "defaultValue": "", + "hideInGraph": true, + "domain": "16120F75-6AA7-4483-868D-F07F511BB081", + "refDict": "", + "uiHint": "", + "id": "35E506DC-8AA0-4763-9D0E-EAC93F0A3E87" + }, + { + "defKey": "id", + "defName": "主键", + "comment": "", + "type": "INT", + "len": 20, + "scale": "", + "primaryKey": true, + "notNull": true, + "autoIncrement": false, + "defaultValue": "", + "hideInGraph": false, + "refDict": "", + "extProps": {}, + "domain": "", + "id": "EF08AA87-F15F-4018-A2A8-E64B18C707B0" + }, + { + "defKey": "create_user", + "defName": "创建人", + "comment": "", + "domain": "16120F75-6AA7-4483-868D-F07F511BB081", + "type": "", + "len": 32, + "scale": "", + "primaryKey": false, + "notNull": false, + "autoIncrement": false, + "defaultValue": "", + "hideInGraph": true, + "refDict": "", + "uiHint": "", + "id": "28537FEF-9CDF-475A-9490-39B67C1B6514" + }, + { + "defKey": "create_time", + "defName": "创建时间", + "comment": "", + "domain": "7CFFA0D3-6A93-4DDC-BC10-DF21211064DC", + "type": "", + "len": "", + "scale": "", + "primaryKey": false, + "notNull": false, + "autoIncrement": false, + "defaultValue": "", + "hideInGraph": true, + "refDict": "", + "uiHint": "", + "id": "112E43B5-5796-4581-B512-D786CB720DA4" + }, + { + "defKey": "update_user", + "defName": "更新人", + "comment": "", + "domain": "16120F75-6AA7-4483-868D-F07F511BB081", + "type": "", + "len": 32, + "scale": "", + "primaryKey": false, + "notNull": false, + "autoIncrement": false, + "defaultValue": "", + "hideInGraph": true, + "refDict": "", + "uiHint": "", + "id": "D66AC864-C644-4D34-94AA-A321D65757D4" + }, + { + "defKey": "update_time", + "defName": "更新时间", + "comment": "", + "domain": "7CFFA0D3-6A93-4DDC-BC10-DF21211064DC", + "type": "", + "len": "", + "scale": "", + "primaryKey": false, + "notNull": false, + "autoIncrement": false, + "defaultValue": "", + "hideInGraph": true, + "refDict": "", + "uiHint": "", + "id": "96C6EEC6-F896-422E-A25A-88508FEC0990" + }, + { + "defKey": "status", + "defName": "状态", + "comment": "", + "type": "INT", + "len": 2, + "scale": "", + "primaryKey": false, + "notNull": false, + "autoIncrement": false, + "defaultValue": "", + "hideInGraph": false, + "refDict": "", + "extProps": {}, + "domain": "", + "id": "30EA5BBD-B216-4496-975F-35E4AA6FD69F" + }, + { + "defKey": "is_deleted", + "defName": "是否已删除", + "comment": "", + "type": "INT", + "len": 2, + "scale": "", + "primaryKey": false, + "notNull": false, + "autoIncrement": false, + "defaultValue": "", + "hideInGraph": false, + "refDict": "", + "extProps": {}, + "domain": "", + "id": "E6088D60-4D95-41FA-A7C9-315DFB315ECE" + }, + { + "defKey": "create_dept", + "defName": "创建部门", + "comment": "", + "type": "", + "len": "", + "scale": "", + "primaryKey": false, + "notNull": false, + "autoIncrement": false, + "defaultValue": "", + "hideInGraph": false, + "refDict": "", + "extProps": {}, + "domain": "6BC8F04B-6CFA-4995-98D3-318F5CDD774E", + "id": "090FE123-8025-469C-AD9A-A7273ADB0315" + }, + { + "defKey": "reserve1", + "defName": "预留1", + "comment": "", + "type": "", + "len": "", + "scale": "", + "primaryKey": false, + "notNull": false, + "autoIncrement": false, + "defaultValue": "", + "hideInGraph": false, + "refDict": "", + "extProps": {}, + "domain": "9092C4E0-1A54-4859-ABBB-5B62DBC27573", + "id": "9588FDB5-747D-40A0-BDDB-1F7A39C75CC9" + }, + { + "defKey": "reserve2", + "defName": "预留2", + "comment": "", + "type": "", + "len": "", + "scale": "", + "primaryKey": false, + "notNull": false, + "autoIncrement": false, + "defaultValue": "", + "hideInGraph": false, + "refDict": "", + "extProps": {}, + "domain": "9092C4E0-1A54-4859-ABBB-5B62DBC27573", + "id": "3F49374E-3AF2-4A0C-A422-579CF5437952" + }, + { + "defKey": "reserve3", + "defName": "预留3", + "comment": "", + "type": "", + "len": "", + "scale": "", + "primaryKey": false, + "notNull": false, + "autoIncrement": false, + "defaultValue": "", + "hideInGraph": false, + "refDict": "", + "extProps": {}, + "domain": "9092C4E0-1A54-4859-ABBB-5B62DBC27573", + "id": "AF95E3C9-ACB0-446E-B3D7-E669923580DB" + }, + { + "defKey": "reserve4", + "defName": "预留4", + "comment": "", + "type": "", + "len": "", + "scale": "", + "primaryKey": false, + "notNull": false, + "autoIncrement": false, + "defaultValue": "", + "hideInGraph": false, + "refDict": "", + "extProps": {}, + "domain": "9092C4E0-1A54-4859-ABBB-5B62DBC27573", + "id": "DD7C6DFF-FF7B-4FDA-AA2A-01DB8D1CADC7" + }, + { + "defKey": "reserve5", + "defName": "预留5", + "comment": "", + "type": "", + "len": "", + "scale": "", + "primaryKey": false, + "notNull": false, + "autoIncrement": false, + "defaultValue": "", + "hideInGraph": false, + "refDict": "", + "extProps": {}, + "domain": "9092C4E0-1A54-4859-ABBB-5B62DBC27573", + "id": "72570763-05A1-421A-94B7-C726DE57392B" + }, + { + "defKey": "order_self_number", + "defName": "订单自编号", + "comment": "", + "type": "VARCHAR", + "len": 50, + "scale": "", + "primaryKey": false, + "notNull": false, + "autoIncrement": false, + "defaultValue": "", + "hideInGraph": false, + "refDict": "", + "extProps": {}, + "domain": "", + "id": "A933D74A-3A8C-455F-B8B8-B01D0EA443FB" + }, + { + "defKey": "stock_article_id", + "defName": "订单ID", + "comment": "", + "type": "VARCHAR", + "len": 20, + "scale": "", + "primaryKey": false, + "notNull": false, + "autoIncrement": false, + "defaultValue": "", + "hideInGraph": false, + "refDict": "", + "extProps": {}, + "domain": "", + "id": "40BB92FE-EE0A-4149-88E3-DA83C5AE55DB" + }, + { + "defKey": "stock_list_id", + "defName": "库存品Id", + "comment": "", + "type": "VARCHAR", + "len": 20, + "scale": "", + "primaryKey": false, + "notNull": false, + "autoIncrement": false, + "defaultValue": "", + "hideInGraph": false, + "refDict": "", + "extProps": {}, + "domain": "", + "id": "949BFD31-68ED-4AD8-A4CA-5C66464A03D8" + }, + { + "defKey": "parcel_list_id", + "defName": "包件id", + "comment": "", + "type": "VARCHAR", + "len": 20, + "scale": "", + "primaryKey": false, + "notNull": false, + "autoIncrement": false, + "defaultValue": "", + "hideInGraph": false, + "refDict": "", + "extProps": {}, + "domain": "", + "id": "20EEAA00-BE91-4CE2-8C7F-AE53114DC838" + }, + { + "defKey": "item_name", + "defName": "物品名称", + "comment": "", + "type": "VARCHAR", + "len": 50, + "scale": "", + "primaryKey": false, + "notNull": false, + "autoIncrement": false, + "defaultValue": "", + "hideInGraph": false, + "refDict": "", + "extProps": {}, + "domain": "", + "id": "85579FCC-C273-4018-8376-E88FE3959A79" + }, + { + "defKey": "unpacking_quantity", + "defName": "拆包数量", + "comment": "", + "type": "", + "len": "", + "scale": "", + "primaryKey": false, + "notNull": false, + "autoIncrement": false, + "defaultValue": "", + "hideInGraph": false, + "refDict": "", + "extProps": {}, + "domain": "6BC8F04B-6CFA-4995-98D3-318F5CDD774E", + "id": "D94AA249-5AE8-4E42-8F01-000A7636FA05" + } + ], + "correlations": [], + "indexes": [] } ], "views": [], @@ -53291,7 +53783,8 @@ "E3B3072D-E273-4E25-8E16-54665C5FF707", "26370030-9EE7-45D5-AC1E-8202547F84A0", "9E6A0AB6-F41E-4830-95BA-829BED345327", - "E49C4E0A-761C-48A9-AFDA-7F44465A94EA" + "E49C4E0A-761C-48A9-AFDA-7F44465A94EA", + "34520BCA-7B04-4B57-949B-D386718B529D" ], "refViews": [], "refDiagrams": [],