Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
C
chnmuseum-party
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
liqin
chnmuseum-party
Commits
07159043
Commit
07159043
authored
Mar 30, 2021
by
liqin
💬
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bug fixed
parent
be56aaef
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
4 deletions
+12
-4
LearningContentController.java
...useum/party/web/controller/LearningContentController.java
+12
-4
No files found.
src/main/java/cn/wisenergy/chnmuseum/party/web/controller/LearningContentController.java
View file @
07159043
...
@@ -70,6 +70,14 @@ public class LearningContentController extends BaseController {
...
@@ -70,6 +70,14 @@ public class LearningContentController extends BaseController {
learningContent
.
setOrganId
(
orgId
);
learningContent
.
setOrganId
(
orgId
);
learningContent
.
setAuditStatus
(
AuditStatusEnum
.
TBC
.
name
());
learningContent
.
setAuditStatus
(
AuditStatusEnum
.
TBC
.
name
());
learningContent
.
setIsPublished
(
false
);
learningContent
.
setIsPublished
(
false
);
QueryWrapper
<
LearningContent
>
queryWrapper
=
new
QueryWrapper
<>();
queryWrapper
.
select
(
"max(sortorder) as sortorder"
);
LearningContent
content
=
this
.
learningContentService
.
getOne
(
queryWrapper
);
if
(
content
!=
null
)
{
learningContent
.
setSortorder
(
content
.
getSortorder
()
+
1
);
}
else
{
learningContent
.
setSortorder
(
1
);
}
// 保存业务节点信息
// 保存业务节点信息
boolean
result
=
learningContentService
.
save
(
learningContent
);
boolean
result
=
learningContentService
.
save
(
learningContent
);
final
String
learningContentId
=
learningContent
.
getId
();
final
String
learningContentId
=
learningContent
.
getId
();
...
@@ -89,9 +97,9 @@ public class LearningContentController extends BaseController {
...
@@ -89,9 +97,9 @@ public class LearningContentController extends BaseController {
final
List
<
String
>
exhibitionBoardIdList
=
learningContent
.
getExhibitionBoardIdList
();
final
List
<
String
>
exhibitionBoardIdList
=
learningContent
.
getExhibitionBoardIdList
();
for
(
String
exhibitionBoardId
:
exhibitionBoardIdList
)
{
for
(
String
exhibitionBoardId
:
exhibitionBoardIdList
)
{
LearningContentBoard
learningContentBoard
=
LearningContentBoard
.
builder
().
exhibitionBoardId
(
exhibitionBoardId
).
learningContentId
(
learningContentId
).
build
();
LearningContentBoard
learningContentBoard
=
LearningContentBoard
.
builder
().
exhibitionBoardId
(
exhibitionBoardId
).
learningContentId
(
learningContentId
).
build
();
QueryWrapper
<
LearningContentBoard
>
q
ueryWrapper
=
new
QueryWrapper
<>();
QueryWrapper
<
LearningContentBoard
>
learningContentBoardQ
ueryWrapper
=
new
QueryWrapper
<>();
queryWrapper
.
select
(
"max(sortorder) as sortorder"
);
queryWrapper
.
select
(
"max(sortorder) as sortorder"
);
LearningContentBoard
one
=
this
.
learningContentBoardService
.
getOne
(
q
ueryWrapper
);
LearningContentBoard
one
=
this
.
learningContentBoardService
.
getOne
(
learningContentBoardQ
ueryWrapper
);
if
(
one
!=
null
)
{
if
(
one
!=
null
)
{
learningContentBoard
.
setSortorder
(
one
.
getSortorder
()
+
1
);
learningContentBoard
.
setSortorder
(
one
.
getSortorder
()
+
1
);
}
else
{
}
else
{
...
@@ -221,11 +229,11 @@ public class LearningContentController extends BaseController {
...
@@ -221,11 +229,11 @@ public class LearningContentController extends BaseController {
LambdaQueryWrapper
<
LearningContent
>
queryWrapper
=
new
LambdaQueryWrapper
<>();
LambdaQueryWrapper
<
LearningContent
>
queryWrapper
=
new
LambdaQueryWrapper
<>();
// 对名称或编码模糊查询
// 对名称或编码模糊查询
if
(
StringUtils
.
isNotBlank
(
learningProjectId
))
{
if
(
StringUtils
.
isNotBlank
(
learningProjectId
))
{
queryWrapper
.
like
(
LearningContent:
:
getLearningProjectId
,
learningProjectId
);
queryWrapper
.
eq
(
LearningContent:
:
getLearningProjectId
,
learningProjectId
);
}
}
// 根据创建时间区间检索
// 根据创建时间区间检索
if
(
genericPageParam
.
getIsPublished
()
!=
null
)
{
if
(
genericPageParam
.
getIsPublished
()
!=
null
)
{
queryWrapper
.
like
(
LearningContent:
:
getIsPublished
,
genericPageParam
.
getIsPublished
());
queryWrapper
.
eq
(
LearningContent:
:
getIsPublished
,
genericPageParam
.
getIsPublished
());
}
}
// 对名称或编码模糊查询
// 对名称或编码模糊查询
if
(
StringUtils
.
isNotBlank
(
genericPageParam
.
getNameOrCode
()))
{
if
(
StringUtils
.
isNotBlank
(
genericPageParam
.
getNameOrCode
()))
{
...
...
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