From 274fdb99d22987ed058f48e71d6b4f4f08f6ca03 Mon Sep 17 00:00:00 2001
From: 田源 <lastanimals@163.com>
Date: 星期四, 07 十二月 2023 11:16:57 +0800
Subject: [PATCH] 导出下载错误信息更改
---
Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmIOServiceImpl.java | 10 +++++++---
1 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmIOServiceImpl.java b/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmIOServiceImpl.java
index 3f5a955..f0f570d 100644
--- a/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmIOServiceImpl.java
+++ b/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmIOServiceImpl.java
@@ -1831,10 +1831,10 @@
tableName = VciBaseUtil.getTableName(btmTypeId);
}
- String countSql = "select count(*) from (select * FROM " + tableName +" where 1=1" +
+ String countSql = "select count(*) from " + tableName +" where 1=1" +
" and lastr = '1'" +
" and lastv='1'" +
- " and codeclsfpath like '%" + exportAttrDTO.getCodeClassifyOid() + "%' {}";
+ " and codeclsfpath like '%" + exportAttrDTO.getCodeClassifyOid() + "%'";
//鍏堟煡璇㈡�绘暟
int total = 0;
@@ -1842,13 +1842,17 @@
&&exportAttrDTO.getPage() !=null && exportAttrDTO.getPage() >0
&&exportAttrDTO.getEndPage()>exportAttrDTO.getPage()){
//浠庡灏戦〉鍒板灏戦〉鐨勬煡璇㈡柟寮忥紝
+ String countPageSql = "select count(*) from (select * FROM " + tableName +" where 1=1" +
+ " and lastr = '1'" +
+ " and lastv='1'" +
+ " and codeclsfpath like '%" + exportAttrDTO.getCodeClassifyOid() + "%' {}";
for(int i = exportAttrDTO.getPage() ;i <= exportAttrDTO.getEndPage();i++){
PageHelper thisPage = new PageHelper(exportAttrDTO.getLimit()==null?-1:exportAttrDTO.getLimit());
thisPage.setPage(exportAttrDTO.getPage()==null?1:exportAttrDTO.getPage());
thisPage.setSort(exportAttrDTO.getSort());
thisPage.setOrder(exportAttrDTO.getOrder());
thisPage.addDefaultDesc("createTime");
- total += commonsMapper.queryCountBySql(StringUtil.format(countSql," limit " + exportAttrDTO.getLimit() +" offset "+ i +")subquery;"));
+ total += commonsMapper.queryCountBySql(StringUtil.format(countPageSql," limit " + exportAttrDTO.getLimit() +" offset "+ i +")subquery;"));
}
}else{
total = commonsMapper.queryCountBySql(countSql);
--
Gitblit v1.9.3