Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gs1-office-web-sit
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
吴迪
gs1-office-web-sit
Commits
f76e592d
Commit
f76e592d
authored
Jan 23, 2022
by
rongkailun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
【修改】专题管理添加筛选条件,审核接口修改
parent
f4723e02
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
25 additions
and
3 deletions
+25
-3
NewtopicController.java
.../office/modules/manage/controller/NewtopicController.java
+3
-1
NewtopicServiceImpl.java
...fice/modules/manage/service/impl/NewtopicServiceImpl.java
+22
-2
No files found.
src/main/java/io/office/modules/manage/controller/NewtopicController.java
View file @
f76e592d
...
...
@@ -7,6 +7,7 @@ import java.util.Map;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
io.office.common.annotation.SysLog
;
import
io.office.modules.manage.entity.dto.NewsParams
;
import
io.office.modules.manage.vo.request.NewtopicEntityVo
;
import
io.office.modules.sys.controller.AbstractController
;
import
io.office.modules.sys.entity.SysUserEntity
;
...
...
@@ -116,11 +117,12 @@ public class NewtopicController extends AbstractController {
@Transactional
@RequestMapping
(
"/verify"
)
// @RequiresPermissions("manage:newtopic:verify")
public
R
verify
(
@RequestBody
New
topicEntityVo
newtopicVo
)
{
public
R
verify
(
@RequestBody
New
sParams
params
)
{
Date
date
=
new
Date
();
SysUserEntity
user
=
getUser
();
NewtopicEntity
newtopicEntity
=
new
NewtopicEntity
();
newtopicEntity
.
setAuditor
(
user
.
getUsername
());
newtopicEntity
.
setCheckflag
(
Integer
.
valueOf
(
params
.
getStatus
()));
QueryWrapper
<
NewtopicEntity
>
newtopicEntityQueryWrapper
=
new
QueryWrapper
<>();
newtopicEntityQueryWrapper
.
eq
(
"classid"
,
newtopicEntity
.
getClassid
());
newtopicService
.
update
(
newtopicEntity
,
newtopicEntityQueryWrapper
);
...
...
src/main/java/io/office/modules/manage/service/impl/NewtopicServiceImpl.java
View file @
f76e592d
...
...
@@ -2,6 +2,7 @@ package io.office.modules.manage.service.impl;
import
io.office.modules.manage.vo.request.NewtopicEntityVo
;
import
io.office.modules.sys.entity.SysUserEntity
;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.cglib.beans.BeanCopier
;
import
org.springframework.stereotype.Service
;
...
...
@@ -35,9 +36,28 @@ public class NewtopicServiceImpl extends ServiceImpl<NewtopicDao, NewtopicEntity
}
else
{
queryWrapper
.
gt
(
"levels"
,
0
);
}
queryWrapper
.
select
(
"classid,title,levels,categoryID,Time,Lastupdate,editor,lasteditor,auditor,checkflag"
);
if
(
params
.
containsKey
(
"status"
))
{
if
(
StringUtils
.
isNotBlank
(
String
.
valueOf
(
params
.
get
(
"status"
))))
{
queryWrapper
.
eq
(
"checkflag"
,
params
.
get
(
"status"
));
}
}
if
(
params
.
containsKey
(
"inputDateStart"
))
{
if
(
StringUtils
.
isNotBlank
(
String
.
valueOf
(
params
.
get
(
"inputDateStart"
)))){
queryWrapper
.
ge
(
"Time"
,
params
.
get
(
"inputDateStart"
));
}
}
if
(
params
.
containsKey
(
"inputDateEnd"
))
{
if
(
StringUtils
.
isNotBlank
(
String
.
valueOf
(
params
.
get
(
"inputDateEnd"
)))){
queryWrapper
.
ge
(
"Time"
,
params
.
get
(
"inputDateEnd"
));
}
}
if
(
params
.
containsKey
(
"title"
))
{
if
(
StringUtils
.
isNotBlank
(
String
.
valueOf
(
params
.
get
(
"title"
)))){
queryWrapper
.
like
(
"title"
,
params
.
get
(
"title"
));
}
}
queryWrapper
.
select
(
"classid,title,levels,categoryID,showtime,Time,Lastupdate,editor,lasteditor,auditor,checkflag"
);
IPage
<
NewtopicEntity
>
page
=
baseMapper
.
selectPage
(
new
Query
<
NewtopicEntity
>().
getPage
(
params
),
queryWrapper
);
return
new
PageUtils
(
page
);
}
...
...
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