Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
Z
zlmy-cloud
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
zlmy
zlmy-cloud
Commits
23a87c6c
Commit
23a87c6c
authored
Aug 11, 2025
by
鲁鸿波
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
隐患台账单位查询,导出bug修改
parent
c95f6655
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
38 additions
and
3 deletions
+38
-3
TSafeHazardOrgServiceImpl.java
...r/module/safe/service/impl/TSafeHazardOrgServiceImpl.java
+38
-3
No files found.
zlmy-modules/zlmy-boot/src/main/java/com/testor/module/safe/service/impl/TSafeHazardOrgServiceImpl.java
View file @
23a87c6c
...
...
@@ -183,7 +183,7 @@ public class TSafeHazardOrgServiceImpl extends SuperServiceImpl<TSafeHazardOrgDa
Page
<
TSafeHazardOrgDTO
>
resultPage
=
new
Page
<>(
page
,
limit
);
String
orgId
=
param
.
getOrgId
();
if
(
StringUtils
.
isBlank
(
orgId
))
{
if
(
StringUtils
.
isBlank
(
param
.
getOrgId
()
))
{
orgId
=
ContextUtils
.
getLoginUser
().
getOrgId
();
}
else
{
// 按逗号分割 orgIds 字符串
...
...
@@ -193,11 +193,18 @@ public class TSafeHazardOrgServiceImpl extends SuperServiceImpl<TSafeHazardOrgDa
}
List
<
String
>
orgIds
=
new
ArrayList
<>();
String
finalOrgId
=
orgId
;
if
(
param
.
getCondOrgIdList
()
!=
null
&&
param
.
getCondOrgIdList
().
size
()
>
0
)
{
/*
if (param.getCondOrgIdList() != null && param.getCondOrgIdList().size() > 0) {
orgIds = param.getCondOrgIdList();
}else {
orgIds = sysOrgService.list(new QueryWrapper<SysOrg>().and(sysOrgQueryWrapper -> sysOrgQueryWrapper.like(SysOrg.PARENT_IDS, finalOrgId).or().eq(SysOrg.ORG_ID, finalOrgId)).ne(SysOrg.STATUS, BizConstants.STATUS_DELETE).eq(SysOrg.IS_DEPT, 0).orderByAsc("tree_sort"))
.stream().map(SysOrg::getOrgId).collect(Collectors.toList());
}*/
if
(
StringUtils
.
isBlank
(
param
.
getOrgId
()))
{
orgIds
=
sysOrgService
.
list
(
new
QueryWrapper
<
SysOrg
>().
and
(
sysOrgQueryWrapper
->
sysOrgQueryWrapper
.
like
(
SysOrg
.
PARENT_IDS
,
finalOrgId
).
or
().
eq
(
SysOrg
.
ORG_ID
,
finalOrgId
)).
ne
(
SysOrg
.
STATUS
,
BizConstants
.
STATUS_DELETE
).
eq
(
SysOrg
.
IS_DEPT
,
0
).
orderByAsc
(
"tree_sort"
))
.
stream
().
map
(
SysOrg:
:
getOrgId
).
collect
(
Collectors
.
toList
());
}
else
{
orgIds
=
sysOrgService
.
list
(
new
QueryWrapper
<
SysOrg
>().
and
(
sysOrgQueryWrapper
->
sysOrgQueryWrapper
.
eq
(
SysOrg
.
ORG_ID
,
finalOrgId
)).
ne
(
SysOrg
.
STATUS
,
BizConstants
.
STATUS_DELETE
).
eq
(
SysOrg
.
IS_DEPT
,
0
).
orderByAsc
(
"tree_sort"
))
.
stream
().
map
(
SysOrg:
:
getOrgId
).
collect
(
Collectors
.
toList
());
}
if
(
param
.
getIds
()
==
null
)
{
param
.
setCondOrgIdList
(
orgIds
);
...
...
@@ -808,7 +815,7 @@ public class TSafeHazardOrgServiceImpl extends SuperServiceImpl<TSafeHazardOrgDa
@Override
public
Boolean
exportEntity
(
TSafeHazardOrgParam
param
,
HttpServletResponse
response
)
{
try
{
String
orgId
=
param
.
getOrgId
();
/*
String orgId = param.getOrgId();
if (StringUtils.isBlank(orgId)) {
orgId = ContextUtils.getLoginUser().getOrgId();
}
...
...
@@ -827,7 +834,35 @@ public class TSafeHazardOrgServiceImpl extends SuperServiceImpl<TSafeHazardOrgDa
orgIds.add(finalOrgId);
}
}
}*/
BaseResponse
<
BaseResponseList
<
TSafeHazardOrgDTO
>>
baseResponse
=
new
BaseResponse
<>();
Long
page
=
StringHelper
.
isEmpty
(
param
.
getPage
())
?
BizConstants
.
PAGE
:
Long
.
valueOf
(
param
.
getPage
());
Long
limit
=
StringHelper
.
isEmpty
(
param
.
getLimit
())
?
BizConstants
.
LIMIT
:
Long
.
valueOf
(
param
.
getLimit
());
Page
<
TSafeHazardOrgDTO
>
resultPage
=
new
Page
<>(
page
,
limit
);
String
orgId
=
param
.
getOrgId
();
if
(
StringUtils
.
isBlank
(
param
.
getOrgId
()))
{
orgId
=
ContextUtils
.
getLoginUser
().
getOrgId
();
}
else
{
// 按逗号分割 orgIds 字符串
String
[]
ids
=
orgId
.
split
(
","
);
// 获取数组中的最后一个元素
orgId
=
ids
[
ids
.
length
-
1
];
}
List
<
String
>
orgIds
=
new
ArrayList
<>();
String
finalOrgId
=
orgId
;
if
(
StringUtils
.
isBlank
(
param
.
getOrgId
()))
{
orgIds
=
sysOrgService
.
list
(
new
QueryWrapper
<
SysOrg
>().
and
(
sysOrgQueryWrapper
->
sysOrgQueryWrapper
.
like
(
SysOrg
.
PARENT_IDS
,
finalOrgId
).
or
().
eq
(
SysOrg
.
ORG_ID
,
finalOrgId
)).
ne
(
SysOrg
.
STATUS
,
BizConstants
.
STATUS_DELETE
).
eq
(
SysOrg
.
IS_DEPT
,
0
).
orderByAsc
(
"tree_sort"
))
.
stream
().
map
(
SysOrg:
:
getOrgId
).
collect
(
Collectors
.
toList
());
}
else
{
orgIds
=
sysOrgService
.
list
(
new
QueryWrapper
<
SysOrg
>().
and
(
sysOrgQueryWrapper
->
sysOrgQueryWrapper
.
eq
(
SysOrg
.
ORG_ID
,
finalOrgId
)).
ne
(
SysOrg
.
STATUS
,
BizConstants
.
STATUS_DELETE
).
eq
(
SysOrg
.
IS_DEPT
,
0
).
orderByAsc
(
"tree_sort"
))
.
stream
().
map
(
SysOrg:
:
getOrgId
).
collect
(
Collectors
.
toList
());
}
if
(
param
.
getIds
()
==
null
)
{
param
.
setCondOrgIdList
(
orgIds
);
}
param
.
setCondOrgIdList
(
orgIds
);
List
<
TSafeHazardExportVO
>
tSafeHazardExportVOS
=
exportBuild
(
param
);
logger
.
info
(
"**************************************写入模板*****************************"
);
...
...
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