From 9d6a02b54ea894771c48ff660d86b48990eccb7f Mon Sep 17 00:00:00 2001 From: skyouc Date: 星期六, 09 八月 2025 09:48:03 +0800 Subject: [PATCH] Merge branch 'ycds-wms-dev' of http://47.97.1.152:5880/r/zy-asrs-master into ycds-wms-dev --- zy-asrs-wms/src/main/java/com/zy/asrs/wms/asrs/service/impl/PickSheetServiceImpl.java | 14 ++++++++------ 1 files changed, 8 insertions(+), 6 deletions(-) diff --git a/zy-asrs-wms/src/main/java/com/zy/asrs/wms/asrs/service/impl/PickSheetServiceImpl.java b/zy-asrs-wms/src/main/java/com/zy/asrs/wms/asrs/service/impl/PickSheetServiceImpl.java index 5f2a4cf..cedf153 100644 --- a/zy-asrs-wms/src/main/java/com/zy/asrs/wms/asrs/service/impl/PickSheetServiceImpl.java +++ b/zy-asrs-wms/src/main/java/com/zy/asrs/wms/asrs/service/impl/PickSheetServiceImpl.java @@ -4,6 +4,7 @@ import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.mysql.cj.util.StringUtils; import com.zy.asrs.wms.asrs.entity.PickSheet; import com.zy.asrs.wms.asrs.entity.PickSheetDetl; import com.zy.asrs.wms.asrs.entity.param.PageRequest; @@ -14,6 +15,7 @@ import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; +import java.util.Map; import java.util.Objects; @Service @@ -30,13 +32,13 @@ @Override public IPage<PickSheet> getOutFlatSheet(PageRequest params) { LambdaQueryWrapper<PickSheet> lambdaQueryWrapper = new LambdaQueryWrapper<>(); - lambdaQueryWrapper.eq(PickSheet::getDeleted, 0).eq(PickSheet::getStatus, 1); - if (!Objects.isNull(params.getParams())) { - lambdaQueryWrapper.eq(!Objects.isNull(params.getParams().get("pickNo")),PickSheet::getPickNo, params.getParams().get("pickNo")) - .eq(!Objects.isNull(params.getParams().get("id")), PickSheet::getId, params.getParams().get("id")) - .eq(!Objects.isNull(params.getParams().get("waveNo")), PickSheet::getWaveNo, params.getParams().get("waveNo")); + lambdaQueryWrapper.eq(PickSheet::getDeleted, 0).eq(PickSheet::getStatus, 1).orderByDesc(PickSheet::getCreatedTime); + Map<String, Object> param = params.getParams(); + if (!Objects.isNull(param)) { + lambdaQueryWrapper.eq(!StringUtils.isNullOrEmpty(param.get("pickNo").toString()),PickSheet::getPickNo, param.get("pickNo")) + .eq(!StringUtils.isNullOrEmpty(param.get("waveNo").toString()), PickSheet::getWaveNo, param.get("waveNo")); } - return this.baseMapper.selectMapsPage(params.getPage(), lambdaQueryWrapper); + return this.baseMapper.selectPage(params.getPage(), lambdaQueryWrapper); } /** -- Gitblit v1.9.1