From e1b926e21c88195d522829a33bf045d9a5c33f66 Mon Sep 17 00:00:00 2001 From: liyawei Date: Fri, 1 Jul 2022 16:19:12 +0800 Subject: [PATCH] =?UTF-8?q?=E8=AE=A4=E8=AF=81-=E5=8F=82=E6=95=B0=E9=A1=B9?= =?UTF-8?q?=E6=94=B6=E9=9B=86-=E5=88=86=E9=A1=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/ParamsCollectManifestEOController.java | 9 ++++++--- .../ParamsCollectManifestHistoryEOController.java | 11 ++++++++--- .../collect/mapper/ParamsCollectManifestEOMapper.java | 3 +++ .../mapper/ParamsCollectManifestHistoryEOMapper.java | 3 +++ .../mapper/xml/ParamsCollectManifestEOMapper.xml | 7 +++++++ .../xml/ParamsCollectManifestHistoryEOMapper.xml | 7 +++++++ .../service/IParamsCollectManifestEOService.java | 4 +++- .../IParamsCollectManifestHistoryEOService.java | 4 +++- .../impl/ParamsCollectManifestEOServiceImpl.java | 9 ++++++--- .../ParamsCollectManifestHistoryEOServiceImpl.java | 9 ++++++--- 10 files changed, 52 insertions(+), 14 deletions(-) diff --git a/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/controller/ParamsCollectManifestEOController.java b/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/controller/ParamsCollectManifestEOController.java index c7a18846a..b3e4b0bed 100644 --- a/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/controller/ParamsCollectManifestEOController.java +++ b/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/controller/ParamsCollectManifestEOController.java @@ -74,8 +74,10 @@ public class ParamsCollectManifestEOController extends JeroController>> queryList(ParamsCollectManifestEO paramsCollectManifestEO, - @RequestParam(name = "cut") String cut) { + public Result queryList(ParamsCollectManifestEO paramsCollectManifestEO, + @RequestParam(name="pageNo", defaultValue="1") Integer pageNo, + @RequestParam(name="pageSize", defaultValue="500") Integer pageSize, + @RequestParam(name = "cut") String cut) { if (StringUtils.isNotEmpty(paramsCollectManifestEO.getNioNumber())) { paramsCollectManifestEO.setNioNumber(paramsCollectManifestEO.getNioNumber().replace("%","\\%")); } @@ -86,7 +88,8 @@ public class ParamsCollectManifestEOController extends JeroController> list = paramsCollectManifestEOService.queryList(paramsCollectManifestEO, cut); + IPage page = new Page(pageNo, pageSize); + IPage list = paramsCollectManifestEOService.queryList(page, paramsCollectManifestEO, cut); return Result.OK(list); } diff --git a/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/controller/ParamsCollectManifestHistoryEOController.java b/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/controller/ParamsCollectManifestHistoryEOController.java index fe62106ff..ba090fa7d 100644 --- a/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/controller/ParamsCollectManifestHistoryEOController.java +++ b/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/controller/ParamsCollectManifestHistoryEOController.java @@ -1,5 +1,7 @@ package com.jero.modules.cert.collect.controller; +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.jero.common.api.vo.Result; import com.jero.common.aspect.annotation.AutoLog; import com.jero.common.system.base.controller.JeroController; @@ -64,8 +66,10 @@ public class ParamsCollectManifestHistoryEOController extends JeroController>> queryList(ParamsCollectManifestEO paramsCollectManifestEO, - @RequestParam(name = "cut") String cut) { + public Result queryList(ParamsCollectManifestEO paramsCollectManifestEO, + @RequestParam(name="pageNo", defaultValue="1") Integer pageNo, + @RequestParam(name="pageSize", defaultValue="500") Integer pageSize, + @RequestParam(name = "cut") String cut) { if (StringUtils.isNotEmpty(paramsCollectManifestEO.getNioNumber())) { paramsCollectManifestEO.setNioNumber(paramsCollectManifestEO.getNioNumber().replace("%","\\%")); } @@ -76,7 +80,8 @@ public class ParamsCollectManifestHistoryEOController extends JeroController> list = paramsCollectManifestHistoryEOService.queryList(paramsCollectManifestEO, cut); + IPage page = new Page(pageNo, pageSize); + IPage list = paramsCollectManifestHistoryEOService.queryList(page, paramsCollectManifestEO, cut); return Result.OK(list); } diff --git a/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/mapper/ParamsCollectManifestEOMapper.java b/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/mapper/ParamsCollectManifestEOMapper.java index 47146746d..9c04eeaa3 100644 --- a/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/mapper/ParamsCollectManifestEOMapper.java +++ b/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/mapper/ParamsCollectManifestEOMapper.java @@ -2,6 +2,7 @@ package com.jero.modules.cert.collect.mapper; import java.util.List; +import com.baomidou.mybatisplus.core.metadata.IPage; import org.apache.ibatis.annotations.Param; import com.jero.modules.cert.collect.entity.ParamsCollectManifestEO; import com.baomidou.mybatisplus.core.mapper.BaseMapper; @@ -15,4 +16,6 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper; public interface ParamsCollectManifestEOMapper extends BaseMapper { List listInfo(@Param("paramsCollectManifestEO") ParamsCollectManifestEO paramsCollectManifestEO); + + IPage pageInfo(@Param("page") IPage page, @Param("paramsCollectManifestEO") ParamsCollectManifestEO paramsCollectManifestEO); } diff --git a/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/mapper/ParamsCollectManifestHistoryEOMapper.java b/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/mapper/ParamsCollectManifestHistoryEOMapper.java index 6478f1525..b2eafd59f 100644 --- a/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/mapper/ParamsCollectManifestHistoryEOMapper.java +++ b/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/mapper/ParamsCollectManifestHistoryEOMapper.java @@ -1,6 +1,7 @@ package com.jero.modules.cert.collect.mapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.baomidou.mybatisplus.core.metadata.IPage; import com.jero.modules.cert.collect.entity.ParamsCollectManifestEO; import com.jero.modules.cert.collect.entity.ParamsCollectManifestHistoryEO; import org.apache.ibatis.annotations.Param; @@ -16,4 +17,6 @@ import java.util.List; public interface ParamsCollectManifestHistoryEOMapper extends BaseMapper { List listInfo(@Param("paramsCollectManifestEO") ParamsCollectManifestEO paramsCollectManifestEO); + + IPage pageInfo(@Param("page") IPage page, @Param("paramsCollectManifestEO") ParamsCollectManifestEO paramsCollectManifestEO); } diff --git a/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/mapper/xml/ParamsCollectManifestEOMapper.xml b/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/mapper/xml/ParamsCollectManifestEOMapper.xml index 07e3d90c4..3b63ab594 100644 --- a/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/mapper/xml/ParamsCollectManifestEOMapper.xml +++ b/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/mapper/xml/ParamsCollectManifestEOMapper.xml @@ -79,4 +79,11 @@ order by del_flag desc, add_flag desc, change_flag desc, nio_number asc + + \ No newline at end of file diff --git a/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/mapper/xml/ParamsCollectManifestHistoryEOMapper.xml b/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/mapper/xml/ParamsCollectManifestHistoryEOMapper.xml index 8d45c4a10..6857bebfa 100644 --- a/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/mapper/xml/ParamsCollectManifestHistoryEOMapper.xml +++ b/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/mapper/xml/ParamsCollectManifestHistoryEOMapper.xml @@ -59,4 +59,11 @@ order by nio_number asc + + \ No newline at end of file diff --git a/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/service/IParamsCollectManifestEOService.java b/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/service/IParamsCollectManifestEOService.java index 0b4407b6f..7da49f229 100644 --- a/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/service/IParamsCollectManifestEOService.java +++ b/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/service/IParamsCollectManifestEOService.java @@ -1,5 +1,6 @@ package com.jero.modules.cert.collect.service; +import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.extension.service.IService; import com.jero.modules.cert.collect.entity.ParamsCollectManifestEO; import com.jero.modules.cert.collect.vo.ParamsCollectManifestVO; @@ -58,11 +59,12 @@ public interface IParamsCollectManifestEOService extends IService> queryList(ParamsCollectManifestEO paramsCollectManifestEO, String cut); + IPage queryList(IPage page, ParamsCollectManifestEO paramsCollectManifestEO, String cut); /** * 列表表头中英文切换 diff --git a/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/service/IParamsCollectManifestHistoryEOService.java b/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/service/IParamsCollectManifestHistoryEOService.java index 96c28fd2a..ca3d42c9d 100644 --- a/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/service/IParamsCollectManifestHistoryEOService.java +++ b/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/service/IParamsCollectManifestHistoryEOService.java @@ -1,5 +1,6 @@ package com.jero.modules.cert.collect.service; +import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.extension.service.IService; import com.jero.modules.cert.collect.entity.ParamsCollectManifestEO; import com.jero.modules.cert.collect.entity.ParamsCollectManifestHistoryEO; @@ -17,11 +18,12 @@ public interface IParamsCollectManifestHistoryEOService extends IService> queryList(ParamsCollectManifestEO paramsCollectManifestEO, String cut); + IPage queryList(IPage page, ParamsCollectManifestEO paramsCollectManifestEO, String cut); /** * 列表表头中英文切换 diff --git a/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/service/impl/ParamsCollectManifestEOServiceImpl.java b/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/service/impl/ParamsCollectManifestEOServiceImpl.java index eaa2b7af5..3e21b3141 100644 --- a/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/service/impl/ParamsCollectManifestEOServiceImpl.java +++ b/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/collect/service/impl/ParamsCollectManifestEOServiceImpl.java @@ -4,6 +4,7 @@ import cn.hutool.core.collection.CollectionUtil; import cn.hutool.core.util.ObjectUtil; 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.extension.service.impl.ServiceImpl; import com.google.common.collect.Lists; import com.jero.common.constant.CommonConstant; @@ -243,7 +244,7 @@ public class ParamsCollectManifestEOServiceImpl extends ServiceImpl> queryList(ParamsCollectManifestEO paramsCollectManifestEO, String cut) { + public IPage queryList(IPage page, ParamsCollectManifestEO paramsCollectManifestEO, String cut) { String paramsManifestId = paramsCollectManifestEO.getParamsManifestId(); String userTypes = paramsCollectManifestEO.getUserTypes(); @@ -273,7 +274,8 @@ public class ParamsCollectManifestEOServiceImpl extends ServiceImpl list = paramsCollectManifestEOMapper.listInfo(paramsCollectManifestEO); // 查询固定列 + IPage pageInfo = paramsCollectManifestEOMapper.pageInfo(page, paramsCollectManifestEO); // 查询固定列 + List list = pageInfo.getRecords(); // 查询固定列 List paramsConfigEOList = paramsConfigEOService.queryList(paramsManifestId); // 查询配置列 List paramsConfigIdList = paramsConfigEOList.stream().map(ParamsConfigEO::getId).collect(Collectors.toList()); List paramsConfigDataEOList = paramsConfigDataEOService.queryListByConfigIdList(paramsConfigIdList); // 查询所有配置数据 @@ -365,7 +367,8 @@ public class ParamsCollectManifestEOServiceImpl extends ServiceImpl> queryList(ParamsCollectManifestEO paramsCollectManifestEO, String cut) { + public IPage queryList(IPage page, ParamsCollectManifestEO paramsCollectManifestEO, String cut) { String paramsManifestId = paramsCollectManifestEO.getParamsManifestId(); - List list = paramsCollectManifestHistoryEOMapper.listInfo(paramsCollectManifestEO); // 查询固定列 + IPage pageInfo = paramsCollectManifestHistoryEOMapper.pageInfo(page, paramsCollectManifestEO); // 查询固定列 + List list = pageInfo.getRecords(); // 查询固定列 List paramsConfigEOList = paramsConfigHistoryEOService.queryList(paramsManifestId); // 查询配置列 List paramsConfigIdList = paramsConfigEOList.stream().map(ParamsConfigEO::getId).collect(Collectors.toList()); List paramsConfigDataEOList = paramsConfigDataHistoryEOService.queryListByConfigIdList(paramsConfigIdList); // 查询所有配置数据 @@ -168,7 +170,8 @@ public class ParamsCollectManifestHistoryEOServiceImpl extends ServiceImpl