From 3a7b424d7f60cc37c0b54a00fdd8ad4e30321b81 Mon Sep 17 00:00:00 2001 From: caoyizhong <1270296080> Date: Fri, 12 Jan 2024 00:43:32 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E8=87=AA=E6=8F=90=E8=AE=A2?= =?UTF-8?q?=E5=8D=95=E6=89=AB=E6=8F=8F=E4=BA=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mapper/DistrilbutionBillStockMapper.xml | 2 +- .../impl/DistrilbutionBillStockServiceImpl.java | 17 ++++++++++++++++- 2 files changed, 17 insertions(+), 2 deletions(-) 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 5823f6fcb..4fcb51969 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 @@ -186,7 +186,7 @@ LEFT JOIN logpm_distrilbution_bill_package ldbp on ldbl.id = ldbp.bill_lading_id LEFT JOIN logpm_distribution_parcel_list ldpl ON ldbp.parce_list_id = ldpl.id LEFT JOIN logpm_distribution_stock lds on lds.parcel_list_id = ldpl.id - LEFT JOIN logpm_distribution_bill_lading_scan ldbls on ldbls.packet_bar_code = lds.coding + LEFT JOIN logpm_distribution_bill_lading_scan ldbls on ldbls.packet_bar_code = ldpl.order_package_code LEFT JOIN logpm_warehouse_tray_goods lwtg ON lwtg.association_id = ldpl.id AND lwtg.association_type = '3' LEFT JOIN logpm_warehouse_updown_goods lwug ON lwug.association_id = ldpl.id AND lwug.association_type = '3' diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistrilbutionBillStockServiceImpl.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistrilbutionBillStockServiceImpl.java index 05ae94dac..1f9f8a339 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistrilbutionBillStockServiceImpl.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistrilbutionBillStockServiceImpl.java @@ -19,6 +19,7 @@ package com.logpm.distribution.service.impl; import com.alibaba.fastjson.JSON; import com.baomidou.mybatisplus.core.conditions.Wrapper; import com.baomidou.mybatisplus.core.metadata.IPage; +import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; import com.baomidou.mybatisplus.core.toolkit.StringUtils; import com.logpm.distribution.dto.app.StockupDTO; import com.logpm.distribution.entity.DistrilbutionBillStockEntity; @@ -26,9 +27,13 @@ import com.logpm.distribution.excel.DistrilbutionBillStockExcel; import com.logpm.distribution.mapper.DistrilbutionBillStockMapper; import com.logpm.distribution.service.IDistrilbutionBillStockService; import com.logpm.distribution.vo.*; +import lombok.AllArgsConstructor; import org.springblade.common.constant.DictBizConstant; import org.springblade.core.mp.base.BaseServiceImpl; +import org.springblade.core.tool.api.R; import org.springblade.system.cache.DictBizCache; +import org.springblade.system.entity.User; +import org.springblade.system.feign.IUserClient; import org.springframework.stereotype.Service; import java.util.List; @@ -41,8 +46,11 @@ import java.util.Map; * @since 2023-07-25 */ @Service +@AllArgsConstructor public class DistrilbutionBillStockServiceImpl extends BaseServiceImpl implements IDistrilbutionBillStockService { + private final IUserClient userClient; + @Override public IPage selectDistrilbutionBillStockPage(IPage page, DistrilbutionBillStockVO distrilbutionBillStock) { return page.setRecords(baseMapper.selectDistrilbutionBillStockPage(page, distrilbutionBillStock)); @@ -80,7 +88,14 @@ public class DistrilbutionBillStockServiceImpl extends BaseServiceImpl getBillOrderPack(Map distrilbutionBillStock, IPage page) { DistrilbutionBillStockEntity billStock = JSON.parseObject(JSON.toJSONString(distrilbutionBillStock), DistrilbutionBillStockEntity.class); - return baseMapper.getBillOrderPack(page,billStock); + IPage billOrderPack = baseMapper.getBillOrderPack(page, billStock); + billOrderPack.getRecords().forEach(i -> { + R userR = userClient.userInfoById(Long.valueOf(i.getStockupCreateUser())); + if(userR.isSuccess() && ObjectUtils.isNotNull(userR.getData())){ + i.setStockupCreateUser(userR.getData().getRealName()); + } + }); + return billOrderPack; } @Override