Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
zh-baseversion-project
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
王浩
zh-baseversion-project
Commits
2a7def09
Commit
2a7def09
authored
Jul 18, 2024
by
wanghao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1 大屏端全局搜索调整
2 根据不同角色 动态导出不同字段功能研究实现。-在老旧管网改造上已调整。
parent
7cfa8945
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
24 additions
and
5 deletions
+24
-5
TPipeOldPlanProcessController.java
...ntroller/oldpipesystem/TPipeOldPlanProcessController.java
+3
-1
ExcelUtil.java
.../src/main/java/com/zehong/common/utils/poi/ExcelUtil.java
+10
-0
TPipeOldPlanProcess.java
...in/java/com/zehong/system/domain/TPipeOldPlanProcess.java
+2
-0
TPipeOldPlanProcessServiceImpl.java
...g/system/service/impl/TPipeOldPlanProcessServiceImpl.java
+8
-3
TDeviceInfoMapper.xml
...em/src/main/resources/mapper/system/TDeviceInfoMapper.xml
+1
-1
No files found.
zh-baseversion-admin/src/main/java/com/zehong/web/controller/oldpipesystem/TPipeOldPlanProcessController.java
View file @
2a7def09
...
@@ -64,7 +64,9 @@ public class TPipeOldPlanProcessController extends BaseController
...
@@ -64,7 +64,9 @@ public class TPipeOldPlanProcessController extends BaseController
{
{
List
<
TPipeOldPlanProcess
>
list
=
tPipeOldPlanProcessService
.
exportTPipeOldPlanProcessList
(
tPipeOldPlanProcess
);
List
<
TPipeOldPlanProcess
>
list
=
tPipeOldPlanProcessService
.
exportTPipeOldPlanProcessList
(
tPipeOldPlanProcess
);
ExcelUtil
<
TPipeOldPlanProcess
>
util
=
new
ExcelUtil
<
TPipeOldPlanProcess
>(
TPipeOldPlanProcess
.
class
);
ExcelUtil
<
TPipeOldPlanProcess
>
util
=
new
ExcelUtil
<
TPipeOldPlanProcess
>(
TPipeOldPlanProcess
.
class
);
return
util
.
exportExcel
(
list
,
"老旧管网-改造计划和进度数据"
);
AjaxResult
ajaxResult
=
util
.
exportExcel
(
list
,
"老旧管网-改造计划和进度数据"
);
ExcelUtil
.
hiddencolumns
.
clear
();
return
ajaxResult
;
}
}
/**
/**
...
...
zh-baseversion-common/src/main/java/com/zehong/common/utils/poi/ExcelUtil.java
View file @
2a7def09
...
@@ -19,6 +19,7 @@ import java.util.Set;
...
@@ -19,6 +19,7 @@ import java.util.Set;
import
java.util.UUID
;
import
java.util.UUID
;
import
java.util.stream.Collectors
;
import
java.util.stream.Collectors
;
import
org.apache.commons.collections4.bag.SynchronizedSortedBag
;
import
org.apache.poi.ss.usermodel.*
;
import
org.apache.poi.ss.usermodel.*
;
import
org.apache.poi.ss.util.CellRangeAddressList
;
import
org.apache.poi.ss.util.CellRangeAddressList
;
import
org.apache.poi.xssf.streaming.SXSSFWorkbook
;
import
org.apache.poi.xssf.streaming.SXSSFWorkbook
;
...
@@ -110,6 +111,10 @@ public class ExcelUtil<T>
...
@@ -110,6 +111,10 @@ public class ExcelUtil<T>
*/
*/
public
Class
<
T
>
clazz
;
public
Class
<
T
>
clazz
;
/**
* 隐藏的列号
*/
public
static
ArrayList
<
Integer
>
hiddencolumns
=
new
ArrayList
<>();
public
ExcelUtil
(
Class
<
T
>
clazz
)
public
ExcelUtil
(
Class
<
T
>
clazz
)
{
{
this
.
clazz
=
clazz
;
this
.
clazz
=
clazz
;
...
@@ -368,6 +373,11 @@ public class ExcelUtil<T>
...
@@ -368,6 +373,11 @@ public class ExcelUtil<T>
}
}
String
filename
=
encodingFilename
(
sheetName
);
String
filename
=
encodingFilename
(
sheetName
);
out
=
new
FileOutputStream
(
getAbsoluteFile
(
filename
));
out
=
new
FileOutputStream
(
getAbsoluteFile
(
filename
));
if
(
hiddencolumns
!=
null
&&
hiddencolumns
.
size
()
>
0
)
{
for
(
Integer
hiddencolumn
:
hiddencolumns
)
{
this
.
sheet
.
setColumnHidden
(
hiddencolumn
,
true
);
}
}
wb
.
write
(
out
);
wb
.
write
(
out
);
return
AjaxResult
.
success
(
filename
);
return
AjaxResult
.
success
(
filename
);
}
}
...
...
zh-baseversion-system/src/main/java/com/zehong/system/domain/TPipeOldPlanProcess.java
View file @
2a7def09
...
@@ -124,10 +124,12 @@ public class TPipeOldPlanProcess extends BaseEntity
...
@@ -124,10 +124,12 @@ public class TPipeOldPlanProcess extends BaseEntity
* 政府端上传数据
* 政府端上传数据
*/
*/
/** 是否已上传,1-是,0-否 */
/** 是否已上传,1-是,0-否 */
@Excel
(
name
=
" 上传状态"
,
readConverterExp
=
"1=已上传,0=未上传"
)
private
String
govUploadState
;
private
String
govUploadState
;
/** 政府端上传时间,yyyy-MM-dd hh:mm:ss */
/** 政府端上传时间,yyyy-MM-dd hh:mm:ss */
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
)
@Excel
(
name
=
" 上传时间"
)
private
Date
govUploadTime
;
private
Date
govUploadTime
;
public
String
getEnterpriseName
()
{
public
String
getEnterpriseName
()
{
...
...
zh-baseversion-system/src/main/java/com/zehong/system/service/impl/TPipeOldPlanProcessServiceImpl.java
View file @
2a7def09
...
@@ -7,6 +7,7 @@ import com.zehong.common.utils.GovernmentDataCopyUtil;
...
@@ -7,6 +7,7 @@ import com.zehong.common.utils.GovernmentDataCopyUtil;
import
com.zehong.common.utils.GovernmentDataUtil
;
import
com.zehong.common.utils.GovernmentDataUtil
;
import
com.zehong.common.utils.SecurityUtils
;
import
com.zehong.common.utils.SecurityUtils
;
import
com.zehong.common.utils.ServletUtils
;
import
com.zehong.common.utils.ServletUtils
;
import
com.zehong.common.utils.poi.ExcelUtil
;
import
com.zehong.common.utils.uuid.IdUtils
;
import
com.zehong.common.utils.uuid.IdUtils
;
import
com.zehong.system.domain.TPipeOldPlanProcess
;
import
com.zehong.system.domain.TPipeOldPlanProcess
;
import
com.zehong.system.domain.vo.TPipeOldPlanProcessVo
;
import
com.zehong.system.domain.vo.TPipeOldPlanProcessVo
;
...
@@ -83,9 +84,13 @@ public class TPipeOldPlanProcessServiceImpl implements ITPipeOldPlanProcessServi
...
@@ -83,9 +84,13 @@ public class TPipeOldPlanProcessServiceImpl implements ITPipeOldPlanProcessServi
List
<
TPipeOldPlanProcess
>
tPipeOldPlanProcesses
=
tPipeOldPlanProcessMapper
.
exportPipeOldPlanProcessList
(
tPipeOldPlanProcess
);
List
<
TPipeOldPlanProcess
>
tPipeOldPlanProcesses
=
tPipeOldPlanProcessMapper
.
exportPipeOldPlanProcessList
(
tPipeOldPlanProcess
);
if
(
loginUser
.
getUser
().
getRoles
().
get
(
0
).
getRoleId
()==
3
){
if
(
loginUser
.
getUser
().
getRoles
().
get
(
0
).
getRoleId
()==
3
){
if
(
tPipeOldPlanProcesses
.
size
()
>
0
)
{
ExcelUtil
.
hiddencolumns
.
add
(
13
);
return
tPipeOldPlanProcesses
.
stream
().
peek
(
TPipeOldPlanProcess:
:
updateFields
).
collect
(
Collectors
.
toList
());
ExcelUtil
.
hiddencolumns
.
add
(
14
);
}
}
if
(
loginUser
.
getUser
().
getRoles
().
get
(
0
).
getRoleId
()==
5
)
{
ExcelUtil
.
hiddencolumns
.
add
(
15
);
ExcelUtil
.
hiddencolumns
.
add
(
16
);
}
}
return
tPipeOldPlanProcesses
;
return
tPipeOldPlanProcesses
;
...
...
zh-baseversion-system/src/main/resources/mapper/system/TDeviceInfoMapper.xml
View file @
2a7def09
...
@@ -135,7 +135,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
...
@@ -135,7 +135,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
where b2.is_del = '0' and b3.is_del = '0' ) b
where b2.is_del = '0' and b3.is_del = '0' ) b
group by b.user_id,b.detector_type
group by b.user_id,b.detector_type
) t2 on t2.userId = t1.userId
where
<if
test=
"name != null and name != ''"
>
t1.nickName like concat('%', #{name}, '%')
</if>
UNION
) t2 on t2.userId = t1.userId
<if
test=
"name != null and name != ''"
>
where
t1.nickName like concat('%', #{name}, '%')
</if>
UNION
SELECT
SELECT
video_manager_id AS id,
video_manager_id AS id,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment