Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
elearn
Overview
Overview
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
hqzhdj
elearn
Commits
036e7127
Commit
036e7127
authored
Dec 19, 2024
by
阳浪
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
优化投稿列表查询
parent
90193cb8
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
1 deletions
+4
-1
cloud-system/src/main/java/com/yizhi/system/application/mapper/DictionaryMapper.java
+0
-1
cloud-system/src/main/java/com/yizhi/system/application/service/impl/DictionaryServiceImpl.java
+4
-0
No files found.
cloud-system/src/main/java/com/yizhi/system/application/mapper/DictionaryMapper.java
View file @
036e7127
...
...
@@ -25,7 +25,6 @@ public interface DictionaryMapper extends BaseMapper<Dictionary> {
* @param enabledSensitive true:仅取可用的数据字典,false:不管可用不可用都取
* @return
*/
@Select
(
"SELECT getDictChildList(#{id}, #{includeParent}, #{layer}, #{enabledSensitive})"
)
String
getDictChildList
(
@Param
(
"id"
)
Long
id
,
@Param
(
"includeParent"
)
Boolean
includeParent
,
@Param
(
"layer"
)
Integer
layer
,
...
...
cloud-system/src/main/java/com/yizhi/system/application/service/impl/DictionaryServiceImpl.java
View file @
036e7127
...
...
@@ -132,6 +132,9 @@ public class DictionaryServiceImpl extends ServiceImpl<DictionaryMapper, Diction
for
(
String
item
:
ids
)
{
idList
.
add
(
new
Long
(
item
));
}
if
(
includeParent
){
idList
.
add
(
id
);
}
return
this
.
selectBatchIds
(
idList
);
}
return
new
ArrayList
<
Dictionary
>();
...
...
@@ -143,6 +146,7 @@ public class DictionaryServiceImpl extends ServiceImpl<DictionaryMapper, Diction
StringBuilder
idsToDeleteSb
=
new
StringBuilder
();
for
(
int
i
=
0
;
i
<
ids
.
length
;
i
++)
{
idsToDeleteSb
.
append
(
","
+
dictionaryMapper
.
getDictChildList
(
ids
[
i
],
true
,
null
,
true
));
idsToDeleteSb
.
append
(
","
+
ids
[
i
]);
}
String
[]
idsToDeleteStr
=
idsToDeleteSb
.
toString
().
split
(
","
);
...
...
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