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
717bdc65
Commit
717bdc65
authored
Jun 13, 2022
by
吴迪
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
【修改】添加日志
parent
e2c7c49a
Hide whitespace changes
Inline
Side-by-side
Showing
28 changed files
with
409 additions
and
203 deletions
+409
-203
AnnounceController.java
.../office/modules/manage/controller/AnnounceController.java
+16
-6
BranchController.java
...io/office/modules/manage/controller/BranchController.java
+11
-5
CasesController.java
.../io/office/modules/manage/controller/CasesController.java
+14
-4
CenterController.java
...io/office/modules/manage/controller/CenterController.java
+17
-6
DocController.java
...va/io/office/modules/manage/controller/DocController.java
+18
-9
GlossaryController.java
.../office/modules/manage/controller/GlossaryController.java
+35
-28
HotFollowController.java
...office/modules/manage/controller/HotFollowController.java
+17
-7
IndexCarouselManageController.java
...ules/manage/controller/IndexCarouselManageController.java
+19
-9
KnowledgeinfoController.java
...ce/modules/manage/controller/KnowledgeinfoController.java
+16
-5
LogisticsController.java
...office/modules/manage/controller/LogisticsController.java
+17
-8
MedicalController.java
...o/office/modules/manage/controller/MedicalController.java
+24
-16
NewsController.java
...a/io/office/modules/manage/controller/NewsController.java
+18
-7
NewsMovieController.java
...office/modules/manage/controller/NewsMovieController.java
+10
-10
NewtopicController.java
.../office/modules/manage/controller/NewtopicController.java
+10
-10
PartnersController.java
.../office/modules/manage/controller/PartnersController.java
+15
-7
PcategoryController.java
...office/modules/manage/controller/PcategoryController.java
+11
-3
PictureController.java
...o/office/modules/manage/controller/PictureController.java
+21
-10
PlanBranchController.java
...ffice/modules/manage/controller/PlanBranchController.java
+8
-2
PolicyController.java
...io/office/modules/manage/controller/PolicyController.java
+38
-27
ProductController.java
...o/office/modules/manage/controller/ProductController.java
+15
-4
RetailpictureController.java
...ce/modules/manage/controller/RetailpictureController.java
+15
-4
RulesAndRegulationsController.java
...ules/manage/controller/RulesAndRegulationsController.java
+18
-6
TopicnewsController.java
...office/modules/manage/controller/TopicnewsController.java
+20
-8
PictureEntity.java
...n/java/io/office/modules/manage/entity/PictureEntity.java
+2
-0
PlanBranchEntity.java
...ava/io/office/modules/manage/entity/PlanBranchEntity.java
+1
-1
NewsMovieServiceImpl.java
...ice/modules/manage/service/impl/NewsMovieServiceImpl.java
+1
-1
PlanBranchServiceImpl.java
...ce/modules/manage/service/impl/PlanBranchServiceImpl.java
+1
-0
PictureDao.xml
src/main/resources/mapper/manage/PictureDao.xml
+1
-0
No files found.
src/main/java/io/office/modules/manage/controller/AnnounceController.java
View file @
717bdc65
...
...
@@ -7,12 +7,14 @@ import java.util.Map;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
io.office.common.annotation.SysLog
;
import
io.office.modules.manage.entity.GlossaryEntity
;
import
io.office.modules.manage.entity.NewsEntity
;
import
io.office.modules.manage.entity.dto.NewsParams
;
import
io.office.modules.sys.controller.AbstractController
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.web.bind.annotation.*
;
import
io.office.modules.manage.entity.AnnounceEntity
;
...
...
@@ -39,7 +41,7 @@ public class AnnounceController extends AbstractController {
* 列表
*/
@RequestMapping
(
"/list"
)
//
@RequiresPermissions("manage:announce:list")
@RequiresPermissions
(
"manage:announce:list"
)
public
R
list
(
@RequestBody
NewsParams
newsParams
){
Page
<
AnnounceEntity
>
page
=
this
.
announceService
.
selectAnnounceList
(
newsParams
,
new
Page
(
newsParams
.
getPage
(),
newsParams
.
getLimit
()));
...
...
@@ -52,7 +54,7 @@ public class AnnounceController extends AbstractController {
* 信息
*/
@RequestMapping
(
"/info/{id}"
)
//
@RequiresPermissions("manage:announce:info")
@RequiresPermissions
(
"manage:announce:info"
)
public
R
info
(
@PathVariable
(
"id"
)
Integer
id
){
AnnounceEntity
announce
=
announceService
.
getById
(
id
);
if
(
announce
.
getAnnouncetype
().
equals
(
"1"
)){
...
...
@@ -68,8 +70,10 @@ public class AnnounceController extends AbstractController {
/**
* 保存
*/
@SysLog
(
"保存公告[announce]"
)
@Transactional
@RequestMapping
(
"/save"
)
//
@RequiresPermissions("manage:announce:save")
@RequiresPermissions
(
"manage:announce:save"
)
public
R
save
(
@RequestBody
AnnounceEntity
announce
){
announceService
.
insertAnnounce
(
announce
,
getUser
());
return
R
.
ok
(
"新增成功!"
);
...
...
@@ -78,8 +82,10 @@ public class AnnounceController extends AbstractController {
/**
* 修改
*/
@SysLog
(
"修改公告[announce]"
)
@Transactional
@RequestMapping
(
"/update"
)
//
@RequiresPermissions("manage:announce:update")
@RequiresPermissions
(
"manage:announce:update"
)
public
R
update
(
@RequestBody
AnnounceEntity
announce
){
announce
.
setEditor
(
getUser
().
getUsername
());
announce
.
setUpdatedate
(
new
Date
());
...
...
@@ -90,8 +96,10 @@ public class AnnounceController extends AbstractController {
/**
* 删除
*/
@SysLog
(
"删除公告[announce]"
)
@Transactional
@RequestMapping
(
"/delete"
)
//
@RequiresPermissions("manage:announce:delete")
@RequiresPermissions
(
"manage:announce:delete"
)
public
R
delete
(
@RequestBody
List
<
String
>
ids
){
AnnounceEntity
announce
=
new
AnnounceEntity
();
announce
.
setEditor
(
getUser
().
getUsername
());
...
...
@@ -106,8 +114,10 @@ public class AnnounceController extends AbstractController {
/**
* 审核
*/
@SysLog
(
"审核公告[announce]"
)
@PostMapping
(
"/verify"
)
// @RequiresPermissions("manage:news:verify")
@Transactional
@RequiresPermissions
(
"manage:announce:check"
)
public
R
verify
(
@RequestBody
AnnounceEntity
announce
)
{
R
r
=
this
.
announceService
.
verify
(
announce
,
getUser
());
return
R
.
ok
(
"审核成功!"
);
...
...
src/main/java/io/office/modules/manage/controller/BranchController.java
View file @
717bdc65
...
...
@@ -4,6 +4,7 @@ import java.util.Arrays;
import
java.util.Map
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
io.office.common.annotation.SysLog
;
import
io.office.modules.app.annotation.Login
;
import
io.office.modules.manage.entity.DocEntity
;
import
io.office.modules.manage.service.CodeagentService
;
...
...
@@ -12,6 +13,7 @@ import io.office.modules.manage.vo.response.BranchEntityVo;
import
org.apache.commons.lang.ArrayUtils
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.web.bind.annotation.PathVariable
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestMapping
;
...
...
@@ -45,7 +47,7 @@ public class BranchController {
* 列表
*/
@RequestMapping
(
"/list"
)
//
@RequiresPermissions("manage:branch:list")
@RequiresPermissions
(
"manage:branch:list"
)
public
R
list
(
@RequestBody
Map
<
String
,
Object
>
params
){
Page
<
DocEntity
>
page
=
this
.
branchService
.
getListPage
(
params
,
new
Page
(
Integer
.
parseInt
(
params
.
get
(
"page"
).
toString
()),
Integer
.
parseInt
(
params
.
get
(
"limit"
).
toString
())));
...
...
@@ -58,7 +60,7 @@ public class BranchController {
* 信息
*/
@RequestMapping
(
"/info/{branchCode}"
)
//
@RequiresPermissions("manage:branch:info")
@RequiresPermissions
(
"manage:branch:info"
)
public
R
info
(
@PathVariable
(
"branchCode"
)
String
branchCode
){
BranchEntityVo
branch
=
branchService
.
getBranchDetail
(
branchCode
);
return
R
.
ok
().
put
(
"data"
,
branch
);
...
...
@@ -68,7 +70,7 @@ public class BranchController {
* 保存
*/
@RequestMapping
(
"/save"
)
//
@RequiresPermissions("manage:branch:save")
@RequiresPermissions
(
"manage:branch:save"
)
public
R
save
(
@RequestBody
BranchEntity
branch
){
branchService
.
save
(
branch
);
...
...
@@ -78,8 +80,10 @@ public class BranchController {
/**
* 修改
*/
@SysLog
(
"分支机构修改[branch]"
)
@Transactional
@RequestMapping
(
"/update"
)
//
@RequiresPermissions("manage:branch:update")
@RequiresPermissions
(
"manage:branch:update"
)
public
R
update
(
@RequestBody
BranchEntity
branch
){
branchService
.
updateById
(
branch
);
...
...
@@ -89,8 +93,10 @@ public class BranchController {
/**
* 删除
*/
@SysLog
(
"分支机构删除[branch]"
)
@Transactional
@RequestMapping
(
"/delete"
)
//
@RequiresPermissions("manage:branch:delete")
@RequiresPermissions
(
"manage:branch:delete"
)
public
R
delete
(
@RequestBody
String
[]
branchCodes
){
if
(
ArrayUtils
.
isNotEmpty
(
branchCodes
))
{
for
(
String
branchCode
:
branchCodes
)
{
...
...
src/main/java/io/office/modules/manage/controller/CasesController.java
View file @
717bdc65
...
...
@@ -6,6 +6,7 @@ import java.util.List;
import
java.util.Map
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
io.office.common.annotation.SysLog
;
import
io.office.modules.app.annotation.Login
;
import
io.office.modules.manage.entity.PartnersEntity
;
import
io.office.modules.manage.entity.dto.NewsParams
;
...
...
@@ -13,6 +14,7 @@ import io.office.modules.sys.controller.AbstractController;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.web.bind.annotation.*
;
import
io.office.modules.manage.entity.CasesEntity
;
...
...
@@ -77,8 +79,10 @@ public class CasesController extends AbstractController {
/**
* 保存
*/
@SysLog
(
"保存案例[cases]"
)
@Transactional
@RequestMapping
(
"/save"
)
// @RequiresPermissions("manage
:cases:save")
@RequiresPermissions
(
"standard
:cases:save"
)
public
R
save
(
@RequestBody
CasesEntity
cases
){
cases
.
setEditor
(
getUser
().
getUsername
());
cases
.
setLasteditor
(
getUser
().
getUsername
());
...
...
@@ -91,8 +95,10 @@ public class CasesController extends AbstractController {
/**
* 修改
*/
@SysLog
(
"修改案例[cases]"
)
@Transactional
@RequestMapping
(
"/update"
)
// @RequiresPermissions("manage
:cases:update")
@RequiresPermissions
(
"standard
:cases:update"
)
public
R
update
(
@RequestBody
CasesEntity
cases
){
cases
.
setEditor
(
getUser
().
getUsername
());
cases
.
setLasteditor
(
getUser
().
getUsername
());
...
...
@@ -104,8 +110,10 @@ public class CasesController extends AbstractController {
/**
* 删除
*/
@SysLog
(
"删除案例[cases]"
)
@Transactional
@RequestMapping
(
"/delete"
)
// @RequiresPermissions("manage
:cases:delete")
@RequiresPermissions
(
"standard
:cases:delete"
)
public
R
delete
(
@RequestBody
List
<
Long
>
ids
){
try
{
R
r
=
this
.
casesService
.
delete
(
ids
,
getUser
());
...
...
@@ -118,8 +126,10 @@ public class CasesController extends AbstractController {
/**
* 审核
*/
@SysLog
(
"审核案例[cases]"
)
@Transactional
@PostMapping
(
"/verify"
)
// @RequiresPermissions("manage:partners:delete
")
@RequiresPermissions
(
"standard:cases:verify
"
)
public
R
verify
(
@RequestBody
CasesEntity
casesEntity
){
try
{
R
r
=
this
.
casesService
.
verify
(
casesEntity
,
getUser
());
...
...
src/main/java/io/office/modules/manage/controller/CenterController.java
View file @
717bdc65
package
io
.
office
.
modules
.
manage
.
controller
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
io.office.common.annotation.SysLog
;
import
io.office.common.utils.PageUtils
;
import
io.office.common.utils.R
;
import
io.office.modules.manage.entity.NewsEntity
;
...
...
@@ -9,7 +10,9 @@ import io.office.modules.manage.entity.dto.NewsParams;
import
io.office.modules.manage.service.TopicnewsService
;
import
io.office.modules.sys.controller.AbstractController
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.web.bind.annotation.*
;
import
java.util.List
;
...
...
@@ -31,7 +34,7 @@ public class CenterController extends AbstractController {
* 列表
*/
@RequestMapping
(
"/list"
)
// @RequiresPermissions("generator:topicnews
:list")
@RequiresPermissions
(
"manage:center
:list"
)
public
R
list
(
@RequestBody
NewsParams
newsParams
){
newsParams
.
setClassId
(
429
);
Page
<
NewsEntity
>
page
=
this
.
topicnewsService
.
selectTopicList
(
newsParams
,
...
...
@@ -45,7 +48,7 @@ public class CenterController extends AbstractController {
* 信息
*/
@RequestMapping
(
"/info/{id}"
)
// @RequiresPermissions("generator:topicnews
:info")
@RequiresPermissions
(
"manage:center
:info"
)
public
R
info
(
@PathVariable
(
"id"
)
Integer
id
){
TopicnewsEntity
topicnews
=
topicnewsService
.
getById
(
id
);
...
...
@@ -55,8 +58,10 @@ public class CenterController extends AbstractController {
/**
* 保存
*/
@SysLog
(
"保存中央总局和精神[center]"
)
@Transactional
@RequestMapping
(
"/save"
)
// @RequiresPermissions("generator:topicnews
:save")
@RequiresPermissions
(
"manage:center
:save"
)
public
R
save
(
@RequestBody
NewsEntity
news
){
try
{
news
.
setClassid
(
429
);
...
...
@@ -71,8 +76,10 @@ public class CenterController extends AbstractController {
/**
* 修改
*/
@SysLog
(
"修改中央总局和精神[center]"
)
@Transactional
@RequestMapping
(
"/update"
)
// @RequiresPermissions("generator:topicnews
:update")
@RequiresPermissions
(
"manage:center
:update"
)
public
R
update
(
@RequestBody
NewsEntity
news
){
try
{
R
r
=
this
.
topicnewsService
.
updateHdbd
(
news
,
getUser
());
...
...
@@ -86,8 +93,10 @@ public class CenterController extends AbstractController {
/**
* 删除
*/
@SysLog
(
"删除中央总局和精神[center]"
)
@Transactional
@RequestMapping
(
"/delete"
)
// @RequiresPermissions("generator:topicnews
:delete")
@RequiresPermissions
(
"manage:center
:delete"
)
public
R
delete
(
@RequestBody
List
<
Long
>
ids
){
try
{
R
r
=
this
.
topicnewsService
.
deleteHdbd
(
ids
,
getUser
());
...
...
@@ -101,8 +110,10 @@ public class CenterController extends AbstractController {
/**
* 审核
*/
@SysLog
(
"审核中央总局和精神[center]"
)
@Transactional
@PostMapping
(
"/verifyTopic"
)
// @RequiresPermissions("manage:news:verify
")
@RequiresPermissions
(
"manage:center:check
"
)
public
R
verify
(
@RequestBody
NewsEntity
news
)
{
try
{
R
r
=
this
.
topicnewsService
.
verifyTopic
(
news
,
getUser
());
...
...
src/main/java/io/office/modules/manage/controller/DocController.java
View file @
717bdc65
package
io
.
office
.
modules
.
manage
.
controller
;
import
java.util.Arrays
;
import
java.util.List
;
import
java.util.Map
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
io.office.common.annotation.SysLog
;
import
io.office.modules.app.annotation.Login
;
import
io.office.modules.manage.entity.DocEntity
;
import
io.office.modules.manage.entity.NewsEntity
;
import
io.office.modules.manage.entity.dto.NewsParams
;
import
io.office.modules.manage.vo.request.TopicNewsPartyRequestVo
;
import
io.office.modules.sys.controller.AbstractController
;
import
io.office.modules.sys.entity.SysUserEntity
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.web.bind.annotation.*
;
import
io.office.modules.manage.service.DocService
;
import
io.office.common.utils.PageUtils
;
...
...
@@ -41,7 +42,7 @@ public class DocController extends AbstractController {
* 列表
*/
@RequestMapping
(
"/list"
)
//
@RequiresPermissions("manage:doc:list")
@RequiresPermissions
(
"manage:doc:list"
)
public
R
list
(
@RequestBody
NewsParams
newsParams
){
Page
<
DocEntity
>
page
=
this
.
docService
.
selectDocList
(
newsParams
,
new
Page
(
newsParams
.
getPage
(),
newsParams
.
getLimit
()));
...
...
@@ -54,7 +55,7 @@ public class DocController extends AbstractController {
* 信息
*/
@RequestMapping
(
"/info/{id}"
)
//
@RequiresPermissions("manage:doc:info")
@RequiresPermissions
(
"manage:doc:info"
)
public
R
info
(
@PathVariable
(
"id"
)
Integer
id
){
DocEntity
doc
=
docService
.
getById
(
id
);
...
...
@@ -64,8 +65,10 @@ public class DocController extends AbstractController {
/**
* 保存
*/
@SysLog
(
"保存文档管理[doc]"
)
@Transactional
@RequestMapping
(
"/save"
)
//
@RequiresPermissions("manage:doc:save")
@RequiresPermissions
(
"manage:doc:save"
)
public
R
save
(
@RequestBody
DocEntity
doc
){
docService
.
save
(
doc
);
return
R
.
ok
();
...
...
@@ -74,8 +77,10 @@ public class DocController extends AbstractController {
/**
* 修改
*/
@SysLog
(
"修改文档管理[doc]"
)
@Transactional
@RequestMapping
(
"/update"
)
//
@RequiresPermissions("manage:doc:update")
@RequiresPermissions
(
"manage:doc:update"
)
public
R
update
(
@RequestBody
DocEntity
doc
){
docService
.
updateById
(
doc
);
return
R
.
ok
();
...
...
@@ -84,8 +89,10 @@ public class DocController extends AbstractController {
/**
* 删除
*/
@SysLog
(
"删除文档管理[doc]"
)
@Transactional
@RequestMapping
(
"/delete"
)
//
@RequiresPermissions("manage:doc:delete")
@RequiresPermissions
(
"manage:doc:delete"
)
public
R
delete
(
@RequestBody
List
<
Long
>
ids
){
this
.
docService
.
deleteDoc
(
ids
);
return
R
.
ok
();
...
...
@@ -94,8 +101,10 @@ public class DocController extends AbstractController {
/**
* 审核
*/
@SysLog
(
"审核文档管理[doc]"
)
@Transactional
@RequestMapping
(
"/verify"
)
// @RequiresPermissions("manage:doc:verify
")
@RequiresPermissions
(
"manage:doc:check
"
)
public
R
verify
(
@RequestBody
DocEntity
doc
){
this
.
docService
.
verifyDoc
(
doc
,
getUser
());
return
R
.
ok
();
...
...
src/main/java/io/office/modules/manage/controller/GlossaryController.java
View file @
717bdc65
...
...
@@ -7,6 +7,7 @@ import java.util.Map;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
io.office.common.annotation.SysLog
;
import
io.office.common.utils.IPUtils
;
import
io.office.modules.app.annotation.Login
;
import
io.office.modules.manage.entity.MedicalEntity
;
...
...
@@ -22,6 +23,7 @@ import org.apache.commons.collections.CollectionUtils;
import
org.apache.commons.lang.StringUtils
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.web.bind.annotation.*
;
import
io.office.modules.manage.entity.GlossaryEntity
;
...
...
@@ -33,10 +35,10 @@ import javax.servlet.http.HttpServletRequest;
/**
*
* 术语管理
*
* @author rkl
* @email
* @email
* @date 2021-11-15 18:29:59
*/
@Slf4j
...
...
@@ -54,8 +56,8 @@ public class GlossaryController extends AbstractController {
* 列表
*/
@RequestMapping
(
"/list"
)
// @RequiresPermissions("manage:glossary:list")
public
R
list
(
@RequestParam
Map
<
String
,
Object
>
params
){
// @RequiresPermissions("manage:glossary:list")
public
R
list
(
@RequestParam
Map
<
String
,
Object
>
params
)
{
Page
<
GlossaryEntity
>
page
=
this
.
glossaryService
.
selectGlossaryList
(
params
,
new
Page
(
Integer
.
valueOf
(
params
.
get
(
"page"
).
toString
()),
Integer
.
valueOf
(
params
.
get
(
"limit"
).
toString
())));
...
...
@@ -67,9 +69,9 @@ public class GlossaryController extends AbstractController {
* 信息
*/
@RequestMapping
(
"/info/{id}"
)
// @RequiresPermissions("manage:glossary:info")
public
R
info
(
@PathVariable
(
"id"
)
Integer
id
){
GlossaryEntity
glossary
=
glossaryService
.
getById
(
id
);
// @RequiresPermissions("manage:glossary:info")
public
R
info
(
@PathVariable
(
"id"
)
Integer
id
)
{
GlossaryEntity
glossary
=
glossaryService
.
getById
(
id
);
return
R
.
ok
().
put
(
"glossary"
,
glossary
);
}
...
...
@@ -77,34 +79,40 @@ public class GlossaryController extends AbstractController {
/**
* 保存
*/
@SysLog
(
"保存术语[glossary]"
)
@Transactional
@RequestMapping
(
"/save"
)
// @RequiresPermissions("manag
e:glossary:save")
public
R
save
(
@RequestBody
GlossaryEntity
glossary
){
@RequiresPermissions
(
"plat
e:glossary:save"
)
public
R
save
(
@RequestBody
GlossaryEntity
glossary
)
{
glossary
.
setEditor
(
getUser
().
getUsername
());
glossary
.
setLasteditor
(
getUser
().
getUsername
());
glossaryService
.
save
(
glossary
);
glossaryService
.
save
(
glossary
);
return
R
.
ok
(
"术语新增成功!"
);
}
/**
* 修改
*/
@SysLog
(
"修改术语[glossary]"
)
@Transactional
@RequestMapping
(
"/update"
)
// @RequiresPermissions("manag
e:glossary:update")
public
R
update
(
@RequestBody
GlossaryEntity
glossary
){
@RequiresPermissions
(
"plat
e:glossary:update"
)
public
R
update
(
@RequestBody
GlossaryEntity
glossary
)
{
glossary
.
setEditor
(
getUser
().
getUsername
());
glossary
.
setLasteditor
(
getUser
().
getUsername
());
glossary
.
setUpdatedate
(
new
Date
());
glossaryService
.
updateById
(
glossary
);
glossaryService
.
updateById
(
glossary
);
return
R
.
ok
(
"术语修改成功!"
);
}
/**
* 删除
*/
@SysLog
(
"删除术语[glossary]"
)
@Transactional
@RequestMapping
(
"/delete"
)
// @RequiresPermissions("manag
e:glossary:delete")
public
R
delete
(
@RequestBody
List
<
String
>
ids
){
@RequiresPermissions
(
"plat
e:glossary:delete"
)
public
R
delete
(
@RequestBody
List
<
String
>
ids
)
{
GlossaryEntity
glossary
=
new
GlossaryEntity
();
glossary
.
setEditor
(
getUser
().
getUsername
());
glossary
.
setLasteditor
(
getUser
().
getUsername
());
...
...
@@ -121,11 +129,11 @@ public class GlossaryController extends AbstractController {
public
R
terminology
(
@RequestBody
TerminologyVo
terminologyVo
,
HttpServletRequest
request
)
{
try
{
if
(
StringUtils
.
isBlank
(
terminologyVo
.
getKeyword
()))
{
if
(
StringUtils
.
isBlank
(
terminologyVo
.
getKeyword
()))
{
return
R
.
error
(
"请输入查询条件!"
);
}
boolean
captcha
=
sysCaptchaService
.
validate
(
terminologyVo
.
getUuid
(),
terminologyVo
.
getCaptcha
());
if
(!
captcha
)
{
if
(!
captcha
)
{
return
R
.
error
(
"验证码不正确"
);
}
...
...
@@ -133,32 +141,32 @@ public class GlossaryController extends AbstractController {
searchgtinlogEntity
.
setCreatedate
(
new
Date
());
searchgtinlogEntity
.
setIp
(
IPUtils
.
getIpAddr
(
request
));
QueryWrapper
<
GlossaryEntity
>
queryWrapper
=
new
QueryWrapper
<>();
if
(
terminologyVo
.
getType
().
equals
(
"1"
))
{
if
(
terminologyVo
.
getType
().
equals
(
"1"
))
{
searchgtinlogEntity
.
setClassStr
(
"术语查询:中文标题查询"
);
queryWrapper
.
like
(
"title_CN"
,
terminologyVo
.
getKeyword
());
queryWrapper
.
like
(
"title_CN"
,
terminologyVo
.
getKeyword
());
}
if
(
terminologyVo
.
getType
().
equals
(
"2"
))
{
if
(
terminologyVo
.
getType
().
equals
(
"2"
))
{
searchgtinlogEntity
.
setClassStr
(
"术语查询:英文标题查询"
);
queryWrapper
.
like
(
"title_En"
,
terminologyVo
.
getKeyword
());
queryWrapper
.
like
(
"title_En"
,
terminologyVo
.
getKeyword
());
}
if
(
terminologyVo
.
getType
().
equals
(
"3"
))
{
if
(
terminologyVo
.
getType
().
equals
(
"3"
))
{
searchgtinlogEntity
.
setClassStr
(
"术语查询:关键字查询"
);
queryWrapper
.
like
(
"keyword"
,
terminologyVo
.
getKeyword
());
queryWrapper
.
like
(
"keyword"
,
terminologyVo
.
getKeyword
());
}
if
(
terminologyVo
.
getType
().
equals
(
"4"
))
{
if
(
terminologyVo
.
getType
().
equals
(
"4"
))
{
searchgtinlogEntity
.
setClassStr
(
"术语查询:术语解释查询"
);
queryWrapper
.
like
(
"content"
,
terminologyVo
.
getKeyword
());
queryWrapper
.
like
(
"content"
,
terminologyVo
.
getKeyword
());
}
searchgtinlogEntity
.
setKeyword
(
terminologyVo
.
getKeyword
());
searchgtinlogEntity
.
setSearchsource
(
0
);
//新增查询日志
searchgtinlogService
.
save
(
searchgtinlogEntity
);
List
<
GlossaryEntity
>
list
=
glossaryService
.
list
(
queryWrapper
);
if
(
CollectionUtils
.
isEmpty
(
list
))
{
if
(
CollectionUtils
.
isEmpty
(
list
))
{
return
R
.
error
(
"没有符合条件的记录!"
);
}
return
R
.
ok
().
put
(
"data"
,
list
);
return
R
.
ok
().
put
(
"data"
,
list
);
}
catch
(
Exception
e
)
{
log
.
error
(
"get4PartyTopNews error: {}"
,
e
);
return
R
.
error
(
e
.
getMessage
());
...
...
@@ -166,5 +174,4 @@ public class GlossaryController extends AbstractController {
}
}
src/main/java/io/office/modules/manage/controller/HotFollowController.java
View file @
717bdc65
package
io
.
office
.
modules
.
manage
.
controller
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
io.office.common.annotation.SysLog
;
import
io.office.common.utils.PageUtils
;
import
io.office.common.utils.R
;
import
io.office.modules.app.annotation.Login
;
...
...
@@ -10,7 +11,9 @@ import io.office.modules.manage.entity.dto.NewsParams;
import
io.office.modules.manage.service.TopicnewsService
;
import
io.office.modules.sys.controller.AbstractController
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.web.bind.annotation.*
;
import
java.util.List
;
...
...
@@ -32,7 +35,7 @@ public class HotFollowController extends AbstractController {
* 列表
*/
@RequestMapping
(
"/list"
)
// @RequiresPermissions("generator:topicnews
:list")
@RequiresPermissions
(
"manage:hotFlow
:list"
)
public
R
list
(
@RequestBody
NewsParams
newsParams
){
newsParams
.
setClassId
(
435
);
Page
<
NewsEntity
>
page
=
this
.
topicnewsService
.
selectTopicList
(
newsParams
,
...
...
@@ -46,7 +49,7 @@ public class HotFollowController extends AbstractController {
* 信息
*/
@RequestMapping
(
"/info/{id}"
)
// @RequiresPermissions("generator:topicnews
:info")
@RequiresPermissions
(
"manage:hotFlow
:info"
)
public
R
info
(
@PathVariable
(
"id"
)
Integer
id
){
TopicnewsEntity
topicnews
=
topicnewsService
.
getById
(
id
);
...
...
@@ -56,8 +59,10 @@ public class HotFollowController extends AbstractController {
/**
* 保存
*/
@SysLog
(
"保存热点关注[hotFlow]"
)
@Transactional
@RequestMapping
(
"/save"
)
// @RequiresPermissions("generator:topicnews
:save")
@RequiresPermissions
(
"manage:hotFlow
:save"
)
public
R
save
(
@RequestBody
NewsEntity
news
){
try
{
news
.
setClassid
(
435
);
...
...
@@ -72,8 +77,10 @@ public class HotFollowController extends AbstractController {
/**
* 修改
*/
@SysLog
(
"修改热点关注[hotFlow]"
)
@Transactional
@RequestMapping
(
"/update"
)
// @RequiresPermissions("generator:topicnews
:update")
@RequiresPermissions
(
"manage:hotFlow
:update"
)
public
R
update
(
@RequestBody
NewsEntity
news
){
try
{
R
r
=
this
.
topicnewsService
.
updateHdbd
(
news
,
getUser
());
...
...
@@ -87,8 +94,10 @@ public class HotFollowController extends AbstractController {
/**
* 删除
*/
@SysLog
(
"删除热点关注[hotFlow]"
)
@Transactional
@RequestMapping
(
"/delete"
)
// @RequiresPermissions("generator:topicnews
:delete")
@RequiresPermissions
(
"manage:hotFlow
:delete"
)
public
R
delete
(
@RequestBody
List
<
Long
>
ids
){
try
{
R
r
=
this
.
topicnewsService
.
deleteHdbd
(
ids
,
getUser
());
...
...
@@ -102,8 +111,10 @@ public class HotFollowController extends AbstractController {
/**
* 审核
*/
@SysLog
(
"审核热点关注[hotFlow]"
)
@Transactional
@PostMapping
(
"/verifyTopic"
)
// @RequiresPermissions("manage:news:verify
")
@RequiresPermissions
(
"manage:hotFlow:check
"
)
public
R
verify
(
@RequestBody
NewsEntity
news
)
{
try
{
R
r
=
this
.
topicnewsService
.
verifyTopic
(
news
,
getUser
());
...
...
@@ -121,7 +132,6 @@ public class HotFollowController extends AbstractController {
@Login
@GetMapping
(
"/api/hotFollowList"
)
// @RequiresPermissions("generator:indexcarouselmanage:pictureImageList")
public
R
getDetail
(
@RequestParam
Map
<
String
,
Object
>
params
)
{
// newsParams.setClassId(435);
// Page<NewsEntity> page = this.topicnewsService.selectTopicList(newsParams,
...
...
src/main/java/io/office/modules/manage/controller/IndexCarouselManageController.java
View file @
717bdc65
...
...
@@ -6,6 +6,7 @@ import java.util.Map;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
io.office.common.annotation.SysLog
;
import
io.office.common.utils.PageUtils
;
import
io.office.common.utils.R
;
import
io.office.modules.app.annotation.Login
;
...
...
@@ -17,6 +18,7 @@ import io.office.modules.sys.controller.AbstractController;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.web.bind.annotation.*
;
/**
...
...
@@ -37,7 +39,7 @@ public class IndexCarouselManageController extends AbstractController {
* 列表
*/
@RequestMapping
(
"/list"
)
// @RequiresPermissions("generator
:indexcarouselmanage:list")
@RequiresPermissions
(
"manage
:indexcarouselmanage:list"
)
public
R
list
(
@RequestBody
IndexCarouselManageParams
indexCarouselManage
){
Page
<
IndexCarouselManageEntity
>
page
=
this
.
indexCarouselManageService
.
selectIndexCarouselManageList
(
indexCarouselManage
,
new
Page
(
indexCarouselManage
.
getPage
(),
indexCarouselManage
.
getLimit
()));
...
...
@@ -51,7 +53,7 @@ public class IndexCarouselManageController extends AbstractController {
*/
@Login
@RequestMapping
(
"/info/{id}"
)
// @RequiresPermissions("generator
:indexcarouselmanage:info")
@RequiresPermissions
(
"manage
:indexcarouselmanage:info"
)
public
R
info
(
@PathVariable
(
"id"
)
Integer
id
){
IndexCarouselManageEntity
indexCarouselManage
=
indexCarouselManageService
.
getById
(
id
);
...
...
@@ -64,7 +66,7 @@ public class IndexCarouselManageController extends AbstractController {
*/
@Login
@RequestMapping
(
"/api/info/{id}"
)
// @RequiresPermissions("
generator
:indexcarouselmanage:info")
// @RequiresPermissions("
manage
:indexcarouselmanage:info")
public
R
apiInfo
(
@PathVariable
(
"id"
)
Integer
id
){
IndexCarouselManageEntity
indexCarouselManage
=
indexCarouselManageService
.
getById
(
id
);
...
...
@@ -75,8 +77,10 @@ public class IndexCarouselManageController extends AbstractController {
/**
* 保存
*/
@Transactional
@SysLog
(
"保存首页轮播[indexcarouselmanage]"
)
@RequestMapping
(
"/save"
)
// @RequiresPermissions("generator
:indexcarouselmanage:save")
@RequiresPermissions
(
"manage
:indexcarouselmanage:save"
)
public
R
save
(
@RequestBody
IndexCarouselManageEntity
indexCarouselManage
){
try
{
R
r
=
this
.
indexCarouselManageService
.
insertIndexCarouselManage
(
indexCarouselManage
,
getUser
());
...
...
@@ -90,8 +94,10 @@ public class IndexCarouselManageController extends AbstractController {
/**
* 修改
*/
@Transactional
@SysLog
(
"修改首页轮播[indexcarouselmanage]"
)
@RequestMapping
(
"/update"
)
// @RequiresPermissions("generator
:indexcarouselmanage:update")
@RequiresPermissions
(
"manage
:indexcarouselmanage:update"
)
public
R
update
(
@RequestBody
IndexCarouselManageEntity
indexCarouselManage
){
try
{
R
r
=
this
.
indexCarouselManageService
.
updateIndexCarouselManage
(
indexCarouselManage
,
getUser
());
...
...
@@ -105,8 +111,10 @@ public class IndexCarouselManageController extends AbstractController {
/**
* 删除
*/
@Transactional
@SysLog
(
"删除首页轮播[indexcarouselmanage]"
)
@RequestMapping
(
"/delete"
)
// @RequiresPermissions("generator
:indexcarouselmanage:delete")
@RequiresPermissions
(
"manage
:indexcarouselmanage:delete"
)
public
R
delete
(
@RequestBody
Integer
[]
ids
){
try
{
R
r
=
indexCarouselManageService
.
deleteIndexCarouselManage
(
Arrays
.
asList
(
ids
),
getUser
());
...
...
@@ -119,8 +127,10 @@ public class IndexCarouselManageController extends AbstractController {
/**
* 审核
*/
@Transactional
@SysLog
(
"审核首页轮播[indexcarouselmanage]"
)
@PostMapping
(
"/verifyIndexCarouselManage"
)
// @RequiresPermissions("generator:indexcarouselmanage:verify
")
@RequiresPermissions
(
"manage:indexcarouselmanage:check
"
)
public
R
verify
(
@RequestBody
IndexCarouselManageEntity
indexCarouselManage
)
{
try
{
R
r
=
this
.
indexCarouselManageService
.
verifyIndexCarouselManage
(
indexCarouselManage
,
getUser
());
...
...
@@ -135,7 +145,7 @@ public class IndexCarouselManageController extends AbstractController {
@Login
@PostMapping
(
"/api/bigImages"
)
// @RequiresPermissions("
generator
:indexcarouselmanage:bigImages")
// @RequiresPermissions("
manage
:indexcarouselmanage:bigImages")
public
R
bigImages
()
{
try
{
...
...
@@ -154,7 +164,7 @@ public class IndexCarouselManageController extends AbstractController {
@Login
@PostMapping
(
"/api/smallImages"
)
// @RequiresPermissions("
generator
:indexcarouselmanage:bigImages")
// @RequiresPermissions("
manage
:indexcarouselmanage:bigImages")
public
R
smallImages
()
{
try
{
...
...
src/main/java/io/office/modules/manage/controller/KnowledgeinfoController.java
View file @
717bdc65
...
...
@@ -8,11 +8,14 @@ import java.util.List;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
io.office.common.annotation.SysLog
;
import
io.office.modules.manage.entity.dto.KnowledgeCategoryVo
;
import
io.office.modules.sys.controller.AbstractController
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.web.bind.annotation.PathVariable
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestMapping
;
...
...
@@ -66,8 +69,10 @@ public class KnowledgeinfoController extends AbstractController {
/**
* 保存
*/
@SysLog
(
"保存知识[knowledgeinfo]"
)
@Transactional
@RequestMapping
(
"/save"
)
//
@RequiresPermissions("manage:knowledgeinfo:save")
@RequiresPermissions
(
"manage:knowledgeinfo:save"
)
public
R
save
(
@RequestBody
KnowledgeinfoEntity
knowledgeinfo
){
knowledgeinfo
.
setInputdate
(
new
Date
());
knowledgeinfo
.
setEditor
(
getUser
().
getUsername
());
...
...
@@ -78,8 +83,10 @@ public class KnowledgeinfoController extends AbstractController {
/**
* 修改
*/
@SysLog
(
"修改知识[knowledgeinfo]"
)
@Transactional
@RequestMapping
(
"/update"
)
//
@RequiresPermissions("manage:knowledgeinfo:update")
@RequiresPermissions
(
"manage:knowledgeinfo:update"
)
public
R
update
(
@RequestBody
KnowledgeinfoEntity
knowledgeinfo
){
knowledgeinfo
.
setEditor
(
getUser
().
getUsername
());
knowledgeinfoService
.
updateById
(
knowledgeinfo
);
...
...
@@ -89,8 +96,10 @@ public class KnowledgeinfoController extends AbstractController {
/**
* 删除
*/
@SysLog
(
"删除知识[knowledgeinfo]"
)
@Transactional
@RequestMapping
(
"/delete"
)
//
@RequiresPermissions("manage:knowledgeinfo:delete")
@RequiresPermissions
(
"manage:knowledgeinfo:delete"
)
public
R
delete
(
@RequestBody
List
<
String
>
knowledgeinfoids
){
KnowledgeinfoEntity
knowledgeinfo
=
new
KnowledgeinfoEntity
();
knowledgeinfo
.
setEditor
(
getUser
().
getUsername
());
...
...
@@ -102,10 +111,12 @@ public class KnowledgeinfoController extends AbstractController {
}
/**
*
删除
*
审核
*/
@SysLog
(
"审核知识[knowledgeinfo]"
)
@Transactional
@RequestMapping
(
"/verify"
)
// @RequiresPermissions("manage:knowledgeinfo:delete
")
@RequiresPermissions
(
"manage:knowledgeinfo:check
"
)
public
R
verify
(
@RequestBody
KnowledgeinfoEntity
knowledgeinfo
){
knowledgeinfo
.
setAuditor
(
getUser
().
getUsername
());
QueryWrapper
<
KnowledgeinfoEntity
>
queryWrapper
=
new
QueryWrapper
<>();
...
...
src/main/java/io/office/modules/manage/controller/LogisticsController.java
View file @
717bdc65
package
io
.
office
.
modules
.
manage
.
controller
;
import
java.util.Arrays
;
import
java.util.Date
;
import
java.util.List
;
import
java.util.Map
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
io.office.
modules.manage.entity.MedicalEntity
;
import
io.office.
common.annotation.SysLog
;
import
io.office.modules.manage.utils.IdKeysConstant
;
import
io.office.modules.manage.utils.IdWorkerUtils
;
import
io.office.modules.sys.controller.AbstractController
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.web.bind.annotation.*
;
import
io.office.modules.manage.entity.LogisticsEntity
;
...
...
@@ -37,7 +38,7 @@ public class LogisticsController extends AbstractController {
* 列表
*/
@RequestMapping
(
"/list"
)
//
@RequiresPermissions("manage:logistics:list")
@RequiresPermissions
(
"manage:logistics:list"
)
public
R
list
(
@RequestParam
Map
<
String
,
Object
>
params
){
PageUtils
page
=
logisticsService
.
queryPage
(
params
);
return
R
.
ok
().
put
(
"page"
,
page
);
...
...
@@ -48,7 +49,7 @@ public class LogisticsController extends AbstractController {
* 信息
*/
@RequestMapping
(
"/info/{id}"
)
//
@RequiresPermissions("manage:logistics:info")
@RequiresPermissions
(
"manage:logistics:info"
)
public
R
info
(
@PathVariable
(
"id"
)
String
id
){
LogisticsEntity
logistics
=
logisticsService
.
getById
(
id
);
...
...
@@ -58,8 +59,10 @@ public class LogisticsController extends AbstractController {
/**
* 保存
*/
@SysLog
(
"保存物流管理[logistics]"
)
@Transactional
@RequestMapping
(
"/save"
)
//
@RequiresPermissions("manage:logistics:save")
@RequiresPermissions
(
"manage:logistics:save"
)
public
R
save
(
@RequestBody
LogisticsEntity
logistics
){
logistics
.
setId
(
IdWorkerUtils
.
getSEQByKey
(
IdKeysConstant
.
ID_SEQ_KEY
));
logistics
.
setInputdate
(
new
Date
());
...
...
@@ -73,8 +76,10 @@ public class LogisticsController extends AbstractController {
/**
* 修改
*/
@SysLog
(
"修改物流管理[logistics]"
)
@Transactional
@RequestMapping
(
"/update"
)
//
@RequiresPermissions("manage:logistics:update")
@RequiresPermissions
(
"manage:logistics:update"
)
public
R
update
(
@RequestBody
LogisticsEntity
logistics
){
String
username
=
getUser
().
getUsername
();
logistics
.
setEditor
(
username
);
...
...
@@ -87,8 +92,10 @@ public class LogisticsController extends AbstractController {
/**
* 删除
*/
@SysLog
(
"删除物流管理[logistics]"
)
@Transactional
@RequestMapping
(
"/delete"
)
//
@RequiresPermissions("manage:logistics:delete")
@RequiresPermissions
(
"manage:logistics:delete"
)
public
R
delete
(
@RequestBody
List
<
String
>
ids
){
LogisticsEntity
logistics
=
new
LogisticsEntity
();
String
username
=
getUser
().
getUsername
();
...
...
@@ -102,8 +109,10 @@ public class LogisticsController extends AbstractController {
return
R
.
ok
(
"删除成功!"
);
}
@SysLog
(
"审核物流管理[logistics]"
)
@Transactional
@PostMapping
(
"/verifyLogistics"
)
@RequiresPermissions
(
"manage:logistics:check"
)
public
R
verifyMedical
(
@RequestBody
LogisticsEntity
logistics
){
String
username
=
getUser
().
getUsername
();
logistics
.
setEditor
(
username
);
...
...
src/main/java/io/office/modules/manage/controller/MedicalController.java
View file @
717bdc65
...
...
@@ -3,6 +3,7 @@ package io.office.modules.manage.controller;
import
java.util.*
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
io.office.common.annotation.SysLog
;
import
io.office.modules.app.annotation.Login
;
import
io.office.modules.manage.entity.MedicalEntity
;
import
io.office.modules.manage.service.MedicalService
;
...
...
@@ -12,6 +13,7 @@ import io.office.modules.sys.controller.AbstractController;
import
org.apache.commons.lang3.StringUtils
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.web.bind.annotation.*
;
import
io.office.common.utils.PageUtils
;
...
...
@@ -35,7 +37,7 @@ public class MedicalController extends AbstractController {
* 列表
*/
@RequestMapping
(
"/list"
)
//
@RequiresPermissions("manage:medical:list")
@RequiresPermissions
(
"manage:medical:list"
)
public
R
list
(
@RequestParam
Map
<
String
,
Object
>
params
)
{
PageUtils
page
=
medicalService
.
queryPage
(
params
);
return
R
.
ok
().
put
(
"page"
,
page
);
...
...
@@ -46,7 +48,7 @@ public class MedicalController extends AbstractController {
* 信息
*/
@RequestMapping
(
"/info/{id}"
)
//
@RequiresPermissions("manage:medical:info")
@RequiresPermissions
(
"manage:medical:info"
)
public
R
info
(
@PathVariable
(
"id"
)
String
id
)
{
MedicalEntity
medical
=
medicalService
.
getById
(
id
);
...
...
@@ -56,8 +58,10 @@ public class MedicalController extends AbstractController {
/**
* 保存
*/
@SysLog
(
"保存医疗管理[medical]"
)
@Transactional
@RequestMapping
(
"/save"
)
//
@RequiresPermissions("manage:medical:save")
@RequiresPermissions
(
"manage:medical:save"
)
public
R
save
(
@RequestBody
MedicalEntity
medical
)
{
medical
.
setId
(
IdWorkerUtils
.
getSEQByKey
(
IdKeysConstant
.
ID_SEQ_KEY
));
String
username
=
getUser
().
getUsername
();
...
...
@@ -71,8 +75,10 @@ public class MedicalController extends AbstractController {
/**
* 修改
*/
@SysLog
(
"修改医疗管理[medical]"
)
@Transactional
@RequestMapping
(
"/update"
)
//
@RequiresPermissions("manage:medical:update")
@RequiresPermissions
(
"manage:medical:update"
)
public
R
update
(
@RequestBody
MedicalEntity
medical
)
{
String
username
=
getUser
().
getUsername
();
medical
.
setEditor
(
username
);
...
...
@@ -85,8 +91,10 @@ public class MedicalController extends AbstractController {
/**
* 删除
*/
@SysLog
(
"删除医疗管理[medical]"
)
@Transactional
@RequestMapping
(
"/delete"
)
//
@RequiresPermissions("manage:medical:delete")
@RequiresPermissions
(
"manage:medical:delete"
)
public
R
delete
(
@RequestBody
List
<
String
>
ids
)
{
MedicalEntity
medical
=
new
MedicalEntity
();
String
username
=
getUser
().
getUsername
();
...
...
@@ -106,8 +114,10 @@ public class MedicalController extends AbstractController {
return
R
.
ok
().
put
(
"list"
,
list
);
}
@SysLog
(
"审核医疗管理[medical]"
)
@Transactional
@PostMapping
(
"/verifyMedical"
)
@RequiresPermissions
(
"manage:medical:check"
)
public
R
verifyMedical
(
@RequestBody
MedicalEntity
medical
)
{
String
username
=
getUser
().
getUsername
();
medical
.
setEditor
(
username
);
...
...
@@ -125,15 +135,15 @@ public class MedicalController extends AbstractController {
public
R
getList10ByType
(
@RequestBody
MedicalEntity
medical
)
{
QueryWrapper
<
MedicalEntity
>
queryWrapper
=
new
QueryWrapper
<>();
queryWrapper
.
select
(
"top 10 id,title "
);
queryWrapper
.
gt
(
"level"
,
"0"
);
queryWrapper
.
eq
(
"status"
,
"1"
);
if
(
StringUtils
.
isBlank
(
medical
.
getType
()))
{
queryWrapper
.
gt
(
"level"
,
"0"
);
queryWrapper
.
eq
(
"status"
,
"1"
);
if
(
StringUtils
.
isBlank
(
medical
.
getType
()))
{
return
R
.
error
(
"请输入分类"
);
}
queryWrapper
.
eq
(
"type"
,
medical
.
getType
());
queryWrapper
.
eq
(
"type"
,
medical
.
getType
());
queryWrapper
.
orderByDesc
(
"releaseTime"
);
return
R
.
ok
().
put
(
"data"
,
medicalService
.
list
(
queryWrapper
));
return
R
.
ok
().
put
(
"data"
,
medicalService
.
list
(
queryWrapper
));
}
...
...
@@ -142,20 +152,18 @@ public class MedicalController extends AbstractController {
public
R
getList3ByType
()
{
QueryWrapper
<
MedicalEntity
>
queryWrapper
=
new
QueryWrapper
<>();
queryWrapper
.
select
(
"top 3 id,title "
);
queryWrapper
.
gt
(
"level"
,
"0"
);
queryWrapper
.
gt
(
"level"
,
"0"
);
queryWrapper
.
orderByDesc
(
"releaseTime"
);
return
R
.
ok
().
put
(
"data"
,
medicalService
.
list
(
queryWrapper
));
return
R
.
ok
().
put
(
"data"
,
medicalService
.
list
(
queryWrapper
));
}
@PostMapping
(
"/api/getDetailById"
)
public
R
getDetailById
(
@RequestBody
MedicalEntity
medical
)
{
return
R
.
ok
().
put
(
"data"
,
medicalService
.
getById
(
medical
.
getId
()));
return
R
.
ok
().
put
(
"data"
,
medicalService
.
getById
(
medical
.
getId
()));
}
}
src/main/java/io/office/modules/manage/controller/NewsController.java
View file @
717bdc65
...
...
@@ -8,6 +8,7 @@ import java.util.Map;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
io.office.common.annotation.SysLog
;
import
io.office.modules.app.annotation.Login
;
import
io.office.modules.manage.entity.*
;
import
io.office.modules.manage.entity.dto.NewsParams
;
...
...
@@ -15,8 +16,10 @@ import io.office.modules.manage.service.*;
import
io.office.modules.manage.vo.response.SearchVo
;
import
io.office.modules.sys.controller.AbstractController
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.context.annotation.Lazy
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.web.bind.annotation.*
;
import
io.office.common.utils.PageUtils
;
...
...
@@ -43,7 +46,7 @@ public class NewsController extends AbstractController {
* 列表
*/
@PostMapping
(
"/list"
)
//
@RequiresPermissions("manage:news:list")
@RequiresPermissions
(
"manage:news:list"
)
public
R
list
(
@RequestBody
NewsParams
newsParams
)
{
Page
<
NewsEntity
>
page
=
this
.
newsService
.
selectNewsList
(
newsParams
,
new
Page
(
newsParams
.
getPage
(),
newsParams
.
getLimit
()));
...
...
@@ -56,7 +59,7 @@ public class NewsController extends AbstractController {
* 信息
*/
@RequestMapping
(
"/info/{id}"
)
//
@RequiresPermissions("manage:news:info")
@RequiresPermissions
(
"manage:news:info"
)
public
R
info
(
@PathVariable
(
"id"
)
Integer
id
)
{
NewsEntity
news
=
newsService
.
getById
(
id
);
String
name
=
this
.
newsService
.
selectClassName
(
news
.
getClassid
());
...
...
@@ -83,8 +86,10 @@ public class NewsController extends AbstractController {
* @author rkl
* @date 2021/10/13
*/
@SysLog
(
"保存文章管理[news]"
)
@Transactional
@PostMapping
(
"/save"
)
//
@RequiresPermissions("manage:news:save")
@RequiresPermissions
(
"manage:news:save"
)
public
R
save
(
@RequestBody
NewsEntity
news
)
{
try
{
R
r
=
this
.
newsService
.
insertNews
(
news
,
getUser
());
...
...
@@ -98,8 +103,10 @@ public class NewsController extends AbstractController {
/**
* 修改
*/
@SysLog
(
"修改文章管理[news]"
)
@Transactional
@PostMapping
(
"/update"
)
//
@RequiresPermissions("manage:news:update")
@RequiresPermissions
(
"manage:news:update"
)
public
R
update
(
@RequestBody
NewsEntity
news
)
{
try
{
R
r
=
this
.
newsService
.
updateNews
(
news
,
getUser
());
...
...
@@ -113,8 +120,10 @@ public class NewsController extends AbstractController {
/**
* 删除
*/
@SysLog
(
"删除文章管理[news]"
)
@Transactional
@PostMapping
(
"/delete"
)
//
@RequiresPermissions("manage:news:delete")
@RequiresPermissions
(
"manage:news:delete"
)
public
R
delete
(
@RequestBody
List
<
Long
>
ids
)
{
try
{
R
r
=
this
.
newsService
.
deleteNews
(
ids
,
getUser
());
...
...
@@ -128,8 +137,10 @@ public class NewsController extends AbstractController {
/**
* 审核
*/
@SysLog
(
"审核文章管理[news]"
)
@Transactional
@PostMapping
(
"/verifyNews"
)
// @RequiresPermissions("manage:news:verify
")
@RequiresPermissions
(
"manage:news:check
"
)
public
R
verify
(
@RequestBody
NewsEntity
news
)
{
try
{
R
r
=
this
.
newsService
.
verifyNews
(
news
,
getUser
());
...
...
@@ -696,7 +707,7 @@ public class NewsController extends AbstractController {
*应用领域列表
*/
@PostMapping
(
"/yylyList"
)
//
@RequiresPermissions("manage:news:list")
//@RequiresPermissions("manage:news:list")
public
R
yylyList
(
@RequestBody
NewsParams
newsParams
)
{
Page
<
NewsEntity
>
page
=
this
.
newsService
.
selectYylyList
(
newsParams
,
new
Page
(
newsParams
.
getPage
(),
newsParams
.
getLimit
()));
...
...
src/main/java/io/office/modules/manage/controller/NewsMovieController.java
View file @
717bdc65
...
...
@@ -50,7 +50,7 @@ public class NewsMovieController extends AbstractController {
* 列表
*/
@RequestMapping
(
"/list"
)
//
@RequiresPermissions("manage:newsmovie:list")
@RequiresPermissions
(
"manage:newsmovie:list"
)
public
R
list
(
@RequestBody
NewsParams
params
){
Page
<
NewsMovieEntity
>
page
=
this
.
newsMovieService
.
selectMoveList
(
params
,
new
Page
(
params
.
getPage
(),
params
.
getLimit
()));
...
...
@@ -63,7 +63,7 @@ public class NewsMovieController extends AbstractController {
* 信息
*/
@RequestMapping
(
"/info/{id}"
)
//
@RequiresPermissions("manage:newsmovie:info")
@RequiresPermissions
(
"manage:newsmovie:info"
)
public
R
info
(
@PathVariable
(
"id"
)
Integer
id
){
NewsMovieEntity
newsMovie
=
newsMovieService
.
getById
(
id
);
...
...
@@ -73,10 +73,10 @@ public class NewsMovieController extends AbstractController {
/**
* 保存
*/
@SysLog
(
"保存
newsMovie
"
)
@SysLog
(
"保存
视频管理[newsMovie]
"
)
@Transactional
@RequestMapping
(
"/save"
)
//
@RequiresPermissions("manage:newsmovie:save")
@RequiresPermissions
(
"manage:newsmovie:save"
)
public
R
save
(
@RequestBody
NewsMovieEntityVo
newsMovieEntityVo
){
SysUserEntity
user
=
getUser
();
newsMovieService
.
insert
(
newsMovieEntityVo
,
user
);
...
...
@@ -86,10 +86,10 @@ public class NewsMovieController extends AbstractController {
/**
* 修改
*/
@SysLog
(
"修改
newsMovie
"
)
@SysLog
(
"修改
视频管理[newsMovie]
"
)
@Transactional
@RequestMapping
(
"/update"
)
//
@RequiresPermissions("manage:newsmovie:update")
@RequiresPermissions
(
"manage:newsmovie:update"
)
public
R
update
(
@RequestBody
NewsMovieEntity
newsMovieEntity
){
SysUserEntity
user
=
getUser
();
newsMovieEntity
.
setLasteditor
(
user
.
getUsername
());
...
...
@@ -106,10 +106,10 @@ public class NewsMovieController extends AbstractController {
/**
* 删除
*/
@SysLog
(
"删除
newsMovie
"
)
@SysLog
(
"删除
视频管理[newsMovie]
"
)
@Transactional
@RequestMapping
(
"/delete"
)
//
@RequiresPermissions("manage:newsmovie:delete")
@RequiresPermissions
(
"manage:newsmovie:delete"
)
public
R
delete
(
@RequestBody
Integer
[]
ids
){
SysUserEntity
user
=
getUser
();
NewsMovieEntity
newsMovieEntity
=
new
NewsMovieEntity
();
...
...
@@ -122,10 +122,10 @@ public class NewsMovieController extends AbstractController {
}
@SysLog
(
"审核
newsMovie
"
)
@SysLog
(
"审核
视频管理[newsMovie]
"
)
@Transactional
@RequestMapping
(
"/verify"
)
// @RequiresPermissions("manage:newsmovie:verify
")
@RequiresPermissions
(
"manage:newsmovie:check
"
)
public
R
verify
(
@RequestBody
NewsMovieEntityVo
newsMovieEntityVo
)
{
SysUserEntity
user
=
getUser
();
...
...
src/main/java/io/office/modules/manage/controller/NewtopicController.java
View file @
717bdc65
...
...
@@ -46,7 +46,7 @@ public class NewtopicController extends AbstractController {
* 列表
*/
@RequestMapping
(
"/list"
)
//
@RequiresPermissions("manage:newtopic:list")
@RequiresPermissions
(
"manage:newtopic:list"
)
public
R
list
(
@RequestBody
Map
<
String
,
Object
>
params
)
{
PageUtils
page
=
newtopicService
.
queryPage
(
params
);
...
...
@@ -58,7 +58,7 @@ public class NewtopicController extends AbstractController {
* 信息
*/
@RequestMapping
(
"/info/{classid}"
)
//
@RequiresPermissions("manage:newtopic:info")
@RequiresPermissions
(
"manage:newtopic:info"
)
public
R
info
(
@PathVariable
(
"classid"
)
Integer
classid
)
{
NewtopicEntity
newtopic
=
newtopicService
.
getById
(
classid
);
...
...
@@ -68,9 +68,9 @@ public class NewtopicController extends AbstractController {
/**
* 保存
*/
@SysLog
(
"保存
newtopic
"
)
@SysLog
(
"保存
专题管理[newtopic]
"
)
@RequestMapping
(
"/save"
)
//
@RequiresPermissions("manage:newtopic:save")
@RequiresPermissions
(
"manage:newtopic:save"
)
public
R
save
(
@RequestBody
NewtopicEntityVo
newtopicVo
)
{
newtopicService
.
insert
(
newtopicVo
,
getUser
());
return
R
.
ok
(
"新增成功"
);
...
...
@@ -79,9 +79,9 @@ public class NewtopicController extends AbstractController {
/**
* 修改
*/
@SysLog
(
"修改
newtopic
"
)
@SysLog
(
"修改
专题管理[newtopic]
"
)
@RequestMapping
(
"/update"
)
//
@RequiresPermissions("manage:newtopic:update")
@RequiresPermissions
(
"manage:newtopic:update"
)
public
R
update
(
@RequestBody
NewtopicEntity
newtopic
)
{
Date
date
=
new
Date
();
...
...
@@ -96,10 +96,10 @@ public class NewtopicController extends AbstractController {
/**
* 删除
*/
@SysLog
(
"删除
newtopic
"
)
@SysLog
(
"删除
专题管理[newtopic]
"
)
@Transactional
@RequestMapping
(
"/delete"
)
//
@RequiresPermissions("manage:newtopic:delete")
@RequiresPermissions
(
"manage:newtopic:delete"
)
public
R
delete
(
@RequestBody
Integer
[]
classids
)
{
Date
date
=
new
Date
();
SysUserEntity
user
=
getUser
();
...
...
@@ -114,10 +114,10 @@ public class NewtopicController extends AbstractController {
}
@SysLog
(
"审核
newtopic
"
)
@SysLog
(
"审核
专题管理[newtopic]
"
)
@Transactional
@RequestMapping
(
"/verify"
)
// @RequiresPermissions("manage:newtopic:verify
")
@RequiresPermissions
(
"manage:newtopic:check
"
)
public
R
verify
(
@RequestBody
NewsParams
params
)
{
Date
date
=
new
Date
();
SysUserEntity
user
=
getUser
();
...
...
src/main/java/io/office/modules/manage/controller/PartnersController.java
View file @
717bdc65
package
io
.
office
.
modules
.
manage
.
controller
;
import
java.util.Arrays
;
import
java.util.Date
;
import
java.util.List
;
import
java.util.Map
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
io.office.common.annotation.SysLog
;
import
io.office.modules.app.annotation.Login
;
import
io.office.modules.manage.entity.ProductEntity
;
import
io.office.modules.manage.entity.dto.NewsParams
;
import
io.office.modules.sys.controller.AbstractController
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.web.bind.annotation.*
;
import
io.office.modules.manage.entity.PartnersEntity
;
...
...
@@ -66,7 +66,7 @@ public class PartnersController extends AbstractController {
* 信息
*/
@RequestMapping
(
"/info/{id}"
)
//
@RequiresPermissions("manage:partners:info")
//
@RequiresPermissions("manage:partners:info")
public
R
info
(
@PathVariable
(
"id"
)
Integer
id
){
PartnersEntity
partners
=
partnersService
.
getById
(
id
);
...
...
@@ -76,8 +76,10 @@ public class PartnersController extends AbstractController {
/**
* 保存
*/
@SysLog
(
"保存提供商[partners]"
)
@Transactional
@PostMapping
(
"/save"
)
// @RequiresPermissions("manage
:partners:save")
@RequiresPermissions
(
"standard
:partners:save"
)
public
R
save
(
@RequestBody
PartnersEntity
partners
){
partners
.
setEditor
(
getUser
().
getUsername
());
partners
.
setLasteditor
(
getUser
().
getUsername
());
...
...
@@ -90,8 +92,10 @@ public class PartnersController extends AbstractController {
/**
* 修改
*/
@SysLog
(
"修改提供商[partners]"
)
@Transactional
@PostMapping
(
"/update"
)
// @RequiresPermissions("manage
:partners:update")
@RequiresPermissions
(
"standard
:partners:update"
)
public
R
update
(
@RequestBody
PartnersEntity
partners
){
partners
.
setEditor
(
getUser
().
getUsername
());
partners
.
setLasteditor
(
getUser
().
getUsername
());
...
...
@@ -103,8 +107,10 @@ public class PartnersController extends AbstractController {
/**
* 删除
*/
@SysLog
(
"删除提供商[partners]"
)
@Transactional
@PostMapping
(
"/delete"
)
// @RequiresPermissions("manage
:partners:delete")
@RequiresPermissions
(
"standard
:partners:delete"
)
public
R
delete
(
@RequestBody
List
<
Long
>
ids
){
try
{
R
r
=
this
.
partnersService
.
deletePartners
(
ids
,
getUser
());
...
...
@@ -117,8 +123,10 @@ public class PartnersController extends AbstractController {
/**
* 审核
*/
@SysLog
(
"审核提供商[partners]"
)
@Transactional
@PostMapping
(
"/verifyPartners"
)
// @RequiresPermissions("manage:partners:delete
")
@RequiresPermissions
(
"standard:partners:check
"
)
public
R
verifyPartners
(
@RequestBody
PartnersEntity
partnersEntity
){
try
{
R
r
=
this
.
partnersService
.
verifyPartners
(
partnersEntity
,
getUser
());
...
...
src/main/java/io/office/modules/manage/controller/PcategoryController.java
View file @
717bdc65
...
...
@@ -4,10 +4,12 @@ import java.util.Arrays;
import
java.util.List
;
import
java.util.Map
;
import
io.office.common.annotation.SysLog
;
import
io.office.modules.sys.controller.AbstractController
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.web.bind.annotation.*
;
import
io.office.modules.manage.entity.PcategoryEntity
;
...
...
@@ -56,8 +58,10 @@ public class PcategoryController extends AbstractController {
/**
* 保存
*/
@SysLog
(
"保存商品分类[pcategory]"
)
@Transactional
@RequestMapping
(
"/save"
)
// @RequiresPermissions("manag
e:pcategory:save")
@RequiresPermissions
(
"plat
e:pcategory:save"
)
public
R
save
(
@RequestBody
PcategoryEntity
pcategory
){
try
{
R
r
=
this
.
pcategoryService
.
insertPcategory
(
pcategory
,
getUser
());
...
...
@@ -71,8 +75,10 @@ public class PcategoryController extends AbstractController {
/**
* 修改
*/
@SysLog
(
"修改商品分类[pcategory]"
)
@Transactional
@RequestMapping
(
"/update"
)
// @RequiresPermissions("manag
e:pcategory:update")
@RequiresPermissions
(
"plat
e:pcategory:update"
)
public
R
update
(
@RequestBody
PcategoryEntity
pcategory
){
try
{
R
r
=
this
.
pcategoryService
.
updatePcategory
(
pcategory
,
getUser
());
...
...
@@ -86,8 +92,10 @@ public class PcategoryController extends AbstractController {
/**
* 删除
*/
@SysLog
(
"删除商品分类[pcategory]"
)
@Transactional
@RequestMapping
(
"/delete"
)
// @RequiresPermissions("manag
e:pcategory:delete")
@RequiresPermissions
(
"plat
e:pcategory:delete"
)
public
R
delete
(
@RequestBody
Integer
[]
categoryids
){
pcategoryService
.
removeByIds
(
Arrays
.
asList
(
categoryids
));
return
R
.
ok
();
...
...
src/main/java/io/office/modules/manage/controller/PictureController.java
View file @
717bdc65
...
...
@@ -7,6 +7,7 @@ import java.util.Map;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
io.office.common.annotation.SysLog
;
import
io.office.common.utils.PageUtils
;
import
io.office.common.utils.R
;
import
io.office.modules.app.annotation.Login
;
...
...
@@ -16,7 +17,9 @@ import io.office.modules.manage.entity.dto.PictureParams;
import
io.office.modules.manage.service.PictureService
;
import
io.office.modules.sys.controller.AbstractController
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.web.bind.annotation.*
;
/**
...
...
@@ -37,7 +40,7 @@ public class PictureController extends AbstractController {
* 列表
*/
@RequestMapping
(
"/list"
)
// @RequiresPermissions("generator
:picture:list")
@RequiresPermissions
(
"manage
:picture:list"
)
public
R
list
(
@RequestBody
PictureParams
params
){
Page
<
PictureEntity
>
page
=
this
.
pictureService
.
selectPictureList
(
params
,
new
Page
(
params
.
getPage
(),
params
.
getLimit
()));
...
...
@@ -50,7 +53,7 @@ public class PictureController extends AbstractController {
* 信息
*/
@RequestMapping
(
"/info/{pictureid}"
)
// @RequiresPermissions("generator
:picture:info")
@RequiresPermissions
(
"manage
:picture:info"
)
public
R
info
(
@PathVariable
(
"pictureid"
)
Integer
pictureid
){
PictureEntity
picture
=
pictureService
.
getById
(
pictureid
);
...
...
@@ -60,8 +63,10 @@ public class PictureController extends AbstractController {
/**
* 保存
*/
@SysLog
(
"保存图片资讯[picture]"
)
@Transactional
@RequestMapping
(
"/save"
)
// @RequiresPermissions("generator
:picture:save")
@RequiresPermissions
(
"manage
:picture:save"
)
public
R
save
(
@RequestBody
PictureEntity
picture
){
try
{
R
r
=
this
.
pictureService
.
insertPicture
(
picture
,
getUser
());
...
...
@@ -75,8 +80,10 @@ public class PictureController extends AbstractController {
/**
* 修改
*/
@SysLog
(
"修改图片资讯[picture]"
)
@Transactional
@RequestMapping
(
"/update"
)
// @RequiresPermissions("generator
:picture:update")
@RequiresPermissions
(
"manage
:picture:update"
)
public
R
update
(
@RequestBody
PictureEntity
picture
){
try
{
R
r
=
this
.
pictureService
.
updatePicture
(
picture
,
getUser
());
...
...
@@ -90,8 +97,10 @@ public class PictureController extends AbstractController {
/**
* 删除
*/
@Transactional
@SysLog
(
"删除图片资讯[picture]"
)
@RequestMapping
(
"/delete"
)
// @RequiresPermissions("generator
:picture:delete")
@RequiresPermissions
(
"manage
:picture:delete"
)
public
R
delete
(
@RequestBody
List
<
Long
>
ids
){
try
{
R
r
=
this
.
pictureService
.
deletePicture
(
ids
,
getUser
());
...
...
@@ -105,8 +114,10 @@ public class PictureController extends AbstractController {
/**
* 审核
*/
@SysLog
(
"审核图片资讯[picture]"
)
@Transactional
@PostMapping
(
"/verifyPicture"
)
// @RequiresPermissions("manage:news:verify
")
@RequiresPermissions
(
"manage:picture:check
"
)
public
R
verify
(
@RequestBody
PictureEntity
picture
)
{
try
{
R
r
=
this
.
pictureService
.
verifyPicture
(
picture
,
getUser
());
...
...
@@ -119,7 +130,7 @@ public class PictureController extends AbstractController {
@Login
@PostMapping
(
"/api/pictureImageList"
)
// @RequiresPermissions("
generator
:indexcarouselmanage:pictureImageList")
// @RequiresPermissions("
manage
:indexcarouselmanage:pictureImageList")
public
R
bigImages
()
{
try
{
...
...
@@ -143,7 +154,7 @@ public class PictureController extends AbstractController {
@Login
@PostMapping
(
"/api/pictureList"
)
// @RequiresPermissions("
generator
:indexcarouselmanage:pictureImageList")
// @RequiresPermissions("
manage
:indexcarouselmanage:pictureImageList")
public
R
pictureList
(
@RequestBody
NewsParams
params
)
{
try
{
Page
<
PictureEntity
>
page
=
this
.
pictureService
.
selectPictureNewList
(
params
,
...
...
@@ -161,7 +172,7 @@ public class PictureController extends AbstractController {
*/
@Login
@RequestMapping
(
"/api/info/{pictureid}"
)
// @RequiresPermissions("
generator
:picture:info")
// @RequiresPermissions("
manage
:picture:info")
public
R
getDetail
(
@PathVariable
(
"pictureid"
)
Integer
pictureid
){
PictureEntity
picture
=
pictureService
.
getById
(
pictureid
);
return
R
.
ok
().
put
(
"data"
,
picture
);
...
...
@@ -170,7 +181,7 @@ public class PictureController extends AbstractController {
@Login
@PostMapping
(
"/api/retailPictureList"
)
// @RequiresPermissions("
generator
:indexcarouselmanage:pictureImageList")
// @RequiresPermissions("
manage
:indexcarouselmanage:pictureImageList")
public
R
retailPictureList
(
@RequestBody
Map
<
String
,
String
>
params
)
{
try
{
...
...
src/main/java/io/office/modules/manage/controller/PlanBranchController.java
View file @
717bdc65
package
io
.
office
.
modules
.
manage
.
controller
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
io.office.common.annotation.SysLog
;
import
io.office.common.utils.PageUtils
;
import
io.office.common.utils.R
;
import
io.office.modules.manage.entity.PlanBranchEntity
;
import
io.office.modules.manage.service.PlanBranchService
;
import
io.office.modules.manage.vo.request.PlanBranchVo
;
import
io.office.modules.sys.controller.AbstractController
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.web.bind.annotation.PathVariable
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestMapping
;
...
...
@@ -68,6 +71,8 @@ public class PlanBranchController extends AbstractController {
/**
* 修改
*/
@SysLog
(
"修改计划[planbranch]"
)
@Transactional
@RequestMapping
(
"/update"
)
// @RequiresPermissions("manage:planbranch:update")
public
R
update
(
@RequestBody
PlanBranchEntity
planBranch
){
...
...
@@ -101,9 +106,10 @@ public class PlanBranchController extends AbstractController {
}
@SysLog
(
"批量修改计划[planbranch]"
)
@Transactional
@RequestMapping
(
"/batchUpdateStatus"
)
// @RequiresPermissions("manage:planbranch:dele
te")
// @RequiresPermissions("manage:planbranch:batchupda
te")
public
R
batchUpdateStatus
(
@RequestBody
PlanBranchVo
planBranchVo
){
planBranchService
.
batchUpdateStatus
(
planBranchVo
,
getUser
());
...
...
src/main/java/io/office/modules/manage/controller/PolicyController.java
View file @
717bdc65
...
...
@@ -4,6 +4,7 @@ import java.util.List;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
io.office.common.annotation.SysLog
;
import
io.office.common.utils.PageUtils
;
import
io.office.common.utils.R
;
import
io.office.modules.app.annotation.Login
;
...
...
@@ -14,7 +15,9 @@ import io.office.modules.manage.entity.dto.PolicyParams;
import
io.office.modules.manage.service.PolicyService
;
import
io.office.modules.sys.controller.AbstractController
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.web.bind.annotation.*
;
...
...
@@ -36,11 +39,11 @@ public class PolicyController extends AbstractController {
* 列表
*/
@RequestMapping
(
"/list"
)
// @RequiresPermissions("generator
:policy:list")
public
R
list
(
@RequestBody
PolicyParams
params
){
@RequiresPermissions
(
"manage
:policy:list"
)
public
R
list
(
@RequestBody
PolicyParams
params
)
{
Page
<
PictureEntity
>
page
=
this
.
policyService
.
selectPolicyList
(
params
,
new
Page
(
params
.
getPage
(),
params
.
getLimit
()));
PageUtils
pageUtils
=
new
PageUtils
(
page
);
new
Page
(
params
.
getPage
(),
params
.
getLimit
()));
PageUtils
pageUtils
=
new
PageUtils
(
page
);
return
R
.
ok
().
put
(
"page"
,
pageUtils
);
}
...
...
@@ -49,9 +52,9 @@ public class PolicyController extends AbstractController {
* 信息
*/
@RequestMapping
(
"/info/{id}"
)
// @RequiresPermissions("generator
:policy:info")
public
R
info
(
@PathVariable
(
"id"
)
Integer
id
){
PolicyEntity
policy
=
policyService
.
getById
(
id
);
@RequiresPermissions
(
"manage
:policy:info"
)
public
R
info
(
@PathVariable
(
"id"
)
Integer
id
)
{
PolicyEntity
policy
=
policyService
.
getById
(
id
);
return
R
.
ok
().
put
(
"policy"
,
policy
);
}
...
...
@@ -59,9 +62,11 @@ public class PolicyController extends AbstractController {
/**
* 保存
*/
@SysLog
(
"保存政策法规规定管理[policy]"
)
@Transactional
@RequestMapping
(
"/save"
)
// @RequiresPermissions("generator
:policy:save")
public
R
save
(
@RequestBody
PolicyEntity
policy
){
@RequiresPermissions
(
"manage
:policy:save"
)
public
R
save
(
@RequestBody
PolicyEntity
policy
)
{
try
{
R
r
=
this
.
policyService
.
inserPolicy
(
policy
,
getUser
());
return
r
;
...
...
@@ -74,9 +79,11 @@ public class PolicyController extends AbstractController {
/**
* 修改
*/
@SysLog
(
"修改政策法规规定管理[policy]"
)
@Transactional
@RequestMapping
(
"/update"
)
// @RequiresPermissions("generator
:policy:update")
public
R
update
(
@RequestBody
PolicyEntity
policy
){
@RequiresPermissions
(
"manage
:policy:update"
)
public
R
update
(
@RequestBody
PolicyEntity
policy
)
{
try
{
R
r
=
this
.
policyService
.
updatePolicy
(
policy
,
getUser
());
return
r
;
...
...
@@ -89,9 +96,11 @@ public class PolicyController extends AbstractController {
/**
* 删除
*/
@SysLog
(
"删除政策法规规定管理[policy]"
)
@Transactional
@RequestMapping
(
"/delete"
)
// @RequiresPermissions("generator
:policy:delete")
public
R
delete
(
@RequestBody
Integer
[]
ids
){
@RequiresPermissions
(
"manage
:policy:delete"
)
public
R
delete
(
@RequestBody
Integer
[]
ids
)
{
try
{
R
r
=
this
.
policyService
.
deletePolicy
(
ids
,
getUser
());
return
r
;
...
...
@@ -100,14 +109,17 @@ public class PolicyController extends AbstractController {
return
R
.
error
(
e
.
getMessage
());
}
}
/**
* 审核
*/
@SysLog
(
"审核政策法规规定管理[policy]"
)
@Transactional
@PostMapping
(
"/verifyPolicy"
)
// @RequiresPermissions("manage:news:verify
")
@RequiresPermissions
(
"manage:policy:check
"
)
public
R
verify
(
@RequestBody
PolicyEntity
policyEntity
)
{
try
{
R
r
=
this
.
policyService
.
verifyTopic
(
policyEntity
,
getUser
());
R
r
=
this
.
policyService
.
verifyTopic
(
policyEntity
,
getUser
());
return
r
;
}
catch
(
Exception
e
)
{
log
.
error
(
"verifyPolicy error:"
,
e
);
...
...
@@ -116,29 +128,29 @@ public class PolicyController extends AbstractController {
}
@Login
@PostMapping
(
"/api/getTop4"
)
// @RequiresPermissions("
generator
:indexcarouselmanage:pictureImageList")
// @RequiresPermissions("
manage
:indexcarouselmanage:pictureImageList")
public
R
getTop4
()
{
try
{
QueryWrapper
<
PolicyEntity
>
policyEntityQueryWrapper
=
new
QueryWrapper
<>();
policyEntityQueryWrapper
.
select
(
"top 4 *"
);
policyEntityQueryWrapper
.
eq
(
"class"
,
"法律法规"
);
policyEntityQueryWrapper
.
gt
(
"levels"
,
"0"
);
policyEntityQueryWrapper
.
gt
(
"status "
,
"0"
);
policyEntityQueryWrapper
.
eq
(
"class"
,
"法律法规"
);
policyEntityQueryWrapper
.
gt
(
"levels"
,
"0"
);
policyEntityQueryWrapper
.
gt
(
"status "
,
"0"
);
policyEntityQueryWrapper
.
orderByDesc
(
"levels"
);
policyEntityQueryWrapper
.
orderByDesc
(
"releasedate"
);
return
R
.
ok
().
put
(
"data"
,
policyService
.
list
(
policyEntityQueryWrapper
));
return
R
.
ok
().
put
(
"data"
,
policyService
.
list
(
policyEntityQueryWrapper
));
}
catch
(
Exception
e
)
{
log
.
error
(
"get4PartyTopNews error: {}"
,
e
);
return
R
.
error
(
e
.
getMessage
());
}
}
@Login
@PostMapping
(
"/api/policyList"
)
// @RequiresPermissions("
generator
:indexcarouselmanage:pictureImageList")
// @RequiresPermissions("
manage
:indexcarouselmanage:pictureImageList")
public
R
policyList
(
@RequestBody
NewsParams
params
)
{
// try {
// QueryWrapper<PolicyEntity> policyEntityQueryWrapper = new QueryWrapper<>();
...
...
@@ -158,19 +170,18 @@ public class PolicyController extends AbstractController {
// return R.error(e.getMessage());
// }
Page
<
PolicyEntity
>
page
=
this
.
policyService
.
selectPolicyNewList
(
params
,
new
Page
(
params
.
getPage
(),
params
.
getLimit
()));
PageUtils
pageUtils
=
new
PageUtils
(
page
);
new
Page
(
params
.
getPage
(),
params
.
getLimit
()));
PageUtils
pageUtils
=
new
PageUtils
(
page
);
return
R
.
ok
().
put
(
"data"
,
pageUtils
);
}
@Login
@GetMapping
(
"/api/info/{id}"
)
// @RequiresPermissions("
generator
:indexcarouselmanage:pictureImageList")
public
R
getDetail
(
@PathVariable
(
"id"
)
Integer
id
){
// @RequiresPermissions("
manage
:indexcarouselmanage:pictureImageList")
public
R
getDetail
(
@PathVariable
(
"id"
)
Integer
id
)
{
PolicyEntity
policy
=
policyService
.
getById
(
id
);
return
R
.
ok
().
put
(
"data"
,
policy
);
}
}
src/main/java/io/office/modules/manage/controller/ProductController.java
View file @
717bdc65
...
...
@@ -3,10 +3,13 @@ package io.office.modules.manage.controller;
import
java.util.List
;
import
java.util.Map
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
io.office.common.annotation.SysLog
;
import
io.office.modules.app.annotation.Login
;
import
io.office.modules.sys.controller.AbstractController
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.web.bind.annotation.*
;
import
io.office.modules.manage.entity.ProductEntity
;
import
io.office.modules.manage.service.ProductService
;
...
...
@@ -57,8 +60,10 @@ public class ProductController extends AbstractController {
/**
* 保存
*/
@SysLog
(
"保存商品[product]"
)
@Transactional
@RequestMapping
(
"/save"
)
// @RequiresPermissions("manag
e:product:save")
@RequiresPermissions
(
"plat
e:product:save"
)
public
R
save
(
@RequestBody
ProductEntity
product
){
try
{
R
r
=
this
.
productService
.
insertProduct
(
product
,
getUser
());
...
...
@@ -72,8 +77,10 @@ public class ProductController extends AbstractController {
/**
* 修改
*/
@SysLog
(
"修改商品[product]"
)
@Transactional
@RequestMapping
(
"/update"
)
// @RequiresPermissions("manag
e:product:update")
@RequiresPermissions
(
"plat
e:product:update"
)
public
R
update
(
@RequestBody
ProductEntity
product
){
productService
.
updateById
(
product
);
return
R
.
ok
(
"修改成功!"
);
...
...
@@ -82,8 +89,10 @@ public class ProductController extends AbstractController {
/**
* 删除
*/
@SysLog
(
"删除商品[product]"
)
@Transactional
@RequestMapping
(
"/delete"
)
// @RequiresPermissions("manag
e:product:delete")
@RequiresPermissions
(
"plat
e:product:delete"
)
public
R
delete
(
@RequestBody
List
<
Long
>
ids
){
try
{
R
r
=
this
.
productService
.
deleteProduct
(
ids
,
getUser
());
...
...
@@ -97,8 +106,10 @@ public class ProductController extends AbstractController {
/**
* 审核
*/
@SysLog
(
"审核商品[product]"
)
@Transactional
@PostMapping
(
"/verifyProduct"
)
// @RequiresPermissions("manage:news:verify
")
@RequiresPermissions
(
"plate:product:check
"
)
public
R
verify
(
@RequestBody
ProductEntity
product
)
{
try
{
R
r
=
this
.
productService
.
verifyProduct
(
product
,
getUser
());
...
...
src/main/java/io/office/modules/manage/controller/RetailpictureController.java
View file @
717bdc65
...
...
@@ -3,13 +3,16 @@ package io.office.modules.manage.controller;
import
java.util.List
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
io.office.common.annotation.SysLog
;
import
io.office.modules.app.annotation.Login
;
import
io.office.modules.manage.entity.PictureEntity
;
import
io.office.modules.manage.entity.dto.PictureParams
;
import
io.office.modules.manage.entity.dto.RetailPictureParams
;
import
io.office.modules.sys.controller.AbstractController
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.web.bind.annotation.*
;
import
io.office.modules.manage.entity.RetailpictureEntity
;
...
...
@@ -60,8 +63,10 @@ public class RetailpictureController extends AbstractController {
/**
* 保存
*/
@SysLog
(
"保存零售图片[retailPicture]"
)
@Transactional
@RequestMapping
(
"/save"
)
// @RequiresPermissions("generator:p
icture:save")
@RequiresPermissions
(
"manage:retailP
icture:save"
)
public
R
save
(
@RequestBody
RetailpictureEntity
picture
){
try
{
R
r
=
this
.
retailpictureService
.
insertPicture
(
picture
,
getUser
());
...
...
@@ -75,8 +80,10 @@ public class RetailpictureController extends AbstractController {
/**
* 修改
*/
@SysLog
(
"修改零售图片[retailPicture]"
)
@Transactional
@RequestMapping
(
"/update"
)
// @RequiresPermissions("generator:p
icture:update")
@RequiresPermissions
(
"manage:retailP
icture:update"
)
public
R
update
(
@RequestBody
RetailpictureEntity
picture
){
try
{
R
r
=
this
.
retailpictureService
.
updatePicture
(
picture
,
getUser
());
...
...
@@ -90,8 +97,10 @@ public class RetailpictureController extends AbstractController {
/**
* 删除
*/
@SysLog
(
"删除零售图片[retailPicture]"
)
@Transactional
@RequestMapping
(
"/delete"
)
// @RequiresPermissions("generator:p
icture:delete")
@RequiresPermissions
(
"manage:retailP
icture:delete"
)
public
R
delete
(
@RequestBody
List
<
Long
>
ids
){
try
{
R
r
=
this
.
retailpictureService
.
deletePicture
(
ids
,
getUser
());
...
...
@@ -105,8 +114,10 @@ public class RetailpictureController extends AbstractController {
/**
* 审核
*/
@SysLog
(
"审核零售图片[retailPicture]"
)
@Transactional
@PostMapping
(
"/verifyPicture"
)
// @RequiresPermissions("manage:news:verify
")
@RequiresPermissions
(
"manage:retailPicture:check
"
)
public
R
verify
(
@RequestBody
RetailpictureEntity
picture
)
{
try
{
R
r
=
this
.
retailpictureService
.
verifyPicture
(
picture
,
getUser
());
...
...
src/main/java/io/office/modules/manage/controller/RulesAndRegulationsController.java
View file @
717bdc65
package
io
.
office
.
modules
.
manage
.
controller
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
io.office.common.annotation.SysLog
;
import
io.office.common.utils.PageUtils
;
import
io.office.common.utils.R
;
import
io.office.modules.manage.entity.NewsEntity
;
...
...
@@ -9,7 +10,9 @@ import io.office.modules.manage.entity.dto.NewsParams;
import
io.office.modules.manage.service.TopicnewsService
;
import
io.office.modules.sys.controller.AbstractController
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.web.bind.annotation.*
;
import
java.util.List
;
...
...
@@ -31,7 +34,8 @@ public class RulesAndRegulationsController extends AbstractController {
* 列表
*/
@RequestMapping
(
"/list"
)
// @RequiresPermissions("generator:topicnews:list")
@RequiresPermissions
(
"manage:rules:list"
)
public
R
list
(
@RequestBody
NewsParams
newsParams
){
newsParams
.
setClassId
(
430
);
Page
<
NewsEntity
>
page
=
this
.
topicnewsService
.
selectTopicList
(
newsParams
,
...
...
@@ -45,7 +49,7 @@ public class RulesAndRegulationsController extends AbstractController {
* 信息
*/
@RequestMapping
(
"/info/{id}"
)
// @RequiresPermissions("generator:topicnew
s:info")
@RequiresPermissions
(
"manage:rule
s:info"
)
public
R
info
(
@PathVariable
(
"id"
)
Integer
id
){
TopicnewsEntity
topicnews
=
topicnewsService
.
getById
(
id
);
...
...
@@ -55,8 +59,10 @@ public class RulesAndRegulationsController extends AbstractController {
/**
* 保存
*/
@SysLog
(
"保存规章制度[rules]"
)
@Transactional
@RequestMapping
(
"/save"
)
// @RequiresPermissions("generator:topicnew
s:save")
@RequiresPermissions
(
"manage:rule
s:save"
)
public
R
save
(
@RequestBody
NewsEntity
news
){
try
{
news
.
setClassid
(
430
);
...
...
@@ -71,8 +77,10 @@ public class RulesAndRegulationsController extends AbstractController {
/**
* 修改
*/
@SysLog
(
"修改规章制度[rules]"
)
@Transactional
@RequestMapping
(
"/update"
)
// @RequiresPermissions("generator:topicnew
s:update")
@RequiresPermissions
(
"manage:rule
s:update"
)
public
R
update
(
@RequestBody
NewsEntity
news
){
try
{
R
r
=
this
.
topicnewsService
.
updateHdbd
(
news
,
getUser
());
...
...
@@ -86,8 +94,10 @@ public class RulesAndRegulationsController extends AbstractController {
/**
* 删除
*/
@SysLog
(
"删除规章制度[rules]"
)
@Transactional
@RequestMapping
(
"/delete"
)
// @RequiresPermissions("generator:topicnew
s:delete")
@RequiresPermissions
(
"manage:rule
s:delete"
)
public
R
delete
(
@RequestBody
List
<
Long
>
ids
){
try
{
R
r
=
this
.
topicnewsService
.
deleteHdbd
(
ids
,
getUser
());
...
...
@@ -101,8 +111,10 @@ public class RulesAndRegulationsController extends AbstractController {
/**
* 审核
*/
@SysLog
(
"审核规章制度[rules]"
)
@Transactional
@PostMapping
(
"/verifyTopic"
)
// @RequiresPermissions("manage:news:verify
")
@RequiresPermissions
(
"manage:rules:check
"
)
public
R
verify
(
@RequestBody
NewsEntity
news
)
{
try
{
R
r
=
this
.
topicnewsService
.
verifyTopic
(
news
,
getUser
());
...
...
src/main/java/io/office/modules/manage/controller/TopicnewsController.java
View file @
717bdc65
...
...
@@ -3,6 +3,7 @@ package io.office.modules.manage.controller;
import
java.util.List
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
io.office.common.annotation.SysLog
;
import
io.office.common.utils.PageUtils
;
import
io.office.common.utils.R
;
import
io.office.modules.app.annotation.Login
;
...
...
@@ -13,7 +14,9 @@ import io.office.modules.manage.service.TopicnewsService;
import
io.office.modules.manage.vo.request.TopicNewsPartyRequestVo
;
import
io.office.modules.sys.controller.AbstractController
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.web.bind.annotation.*
;
...
...
@@ -34,8 +37,9 @@ public class TopicnewsController extends AbstractController {
/**
* 列表
*/
@RequestMapping
(
"/list"
)
// @RequiresPermissions("generator
:topicnews:list")
@RequiresPermissions
(
"manage
:topicnews:list"
)
public
R
list
(
@RequestBody
NewsParams
newsParams
){
newsParams
.
setClassId
(
428
);
Page
<
NewsEntity
>
page
=
this
.
topicnewsService
.
selectTopicList
(
newsParams
,
...
...
@@ -49,7 +53,7 @@ public class TopicnewsController extends AbstractController {
* 信息
*/
@RequestMapping
(
"/info/{id}"
)
// @RequiresPermissions("generator
:topicnews:info")
@RequiresPermissions
(
"manage
:topicnews:info"
)
public
R
info
(
@PathVariable
(
"id"
)
Integer
id
){
TopicnewsEntity
topicnews
=
topicnewsService
.
getById
(
id
);
...
...
@@ -59,8 +63,10 @@ public class TopicnewsController extends AbstractController {
/**
* 保存
*/
@SysLog
(
"保存活动报道[topicnews]"
)
@Transactional
@RequestMapping
(
"/save"
)
// @RequiresPermissions("generator
:topicnews:save")
@RequiresPermissions
(
"manage
:topicnews:save"
)
public
R
save
(
@RequestBody
NewsEntity
news
){
try
{
news
.
setClassid
(
428
);
...
...
@@ -75,8 +81,10 @@ public class TopicnewsController extends AbstractController {
/**
* 修改
*/
@SysLog
(
"修改活动报道[topicnews]"
)
@Transactional
@RequestMapping
(
"/update"
)
// @RequiresPermissions("generator
:topicnews:update")
@RequiresPermissions
(
"manage
:topicnews:update"
)
public
R
update
(
@RequestBody
NewsEntity
news
){
try
{
R
r
=
this
.
topicnewsService
.
updateHdbd
(
news
,
getUser
());
...
...
@@ -90,8 +98,10 @@ public class TopicnewsController extends AbstractController {
/**
* 删除
*/
@SysLog
(
"删除活动报道[topicnews]"
)
@Transactional
@RequestMapping
(
"/delete"
)
// @RequiresPermissions("generator
:topicnews:delete")
@RequiresPermissions
(
"manage
:topicnews:delete"
)
public
R
delete
(
@RequestBody
List
<
Long
>
ids
){
try
{
R
r
=
this
.
topicnewsService
.
deleteHdbd
(
ids
,
getUser
());
...
...
@@ -105,8 +115,10 @@ public class TopicnewsController extends AbstractController {
/**
* 审核
*/
@SysLog
(
"审核活动报道[topicnews]"
)
@Transactional
@PostMapping
(
"/verifyTopic"
)
// @RequiresPermissions("manage:news:verify
")
@RequiresPermissions
(
"manage:news:check
"
)
public
R
verify
(
@RequestBody
NewsEntity
news
)
{
try
{
R
r
=
this
.
topicnewsService
.
verifyTopic
(
news
,
getUser
());
...
...
@@ -120,7 +132,7 @@ public class TopicnewsController extends AbstractController {
@Login
@PostMapping
(
"/api/get4PartyTopNews"
)
// @RequiresPermissions("
generator
:indexcarouselmanage:pictureImageList")
// @RequiresPermissions("
manage
:indexcarouselmanage:pictureImageList")
public
R
get4PartyTopNews
(
@RequestBody
TopicNewsPartyRequestVo
topicNewsPartyRequestVo
)
{
try
{
return
R
.
ok
().
put
(
"data"
,
topicnewsService
.
getTopicNewsByCondition
(
topicNewsPartyRequestVo
));
...
...
@@ -132,7 +144,7 @@ public class TopicnewsController extends AbstractController {
@Login
@PostMapping
(
"/api/getHdbdList"
)
// @RequiresPermissions("
generator
:indexcarouselmanage:pictureImageList")
// @RequiresPermissions("
manage
:indexcarouselmanage:pictureImageList")
public
R
getHdbdList
(
@RequestBody
NewsParams
newsParams
)
{
Page
<
NewsEntity
>
page
=
this
.
topicnewsService
.
getHdbdList
(
newsParams
,
new
Page
(
newsParams
.
getPage
(),
newsParams
.
getLimit
()));
...
...
src/main/java/io/office/modules/manage/entity/PictureEntity.java
View file @
717bdc65
...
...
@@ -85,4 +85,6 @@ public class PictureEntity implements Serializable {
*/
private
String
lasteditor
;
private
String
flag
;
}
src/main/java/io/office/modules/manage/entity/PlanBranchEntity.java
View file @
717bdc65
...
...
@@ -59,6 +59,6 @@ public class PlanBranchEntity implements Serializable {
/**
* $column.comments
*/
p
rivate
Integer
checkflag
;
p
ublic
Integer
checkflag
;
}
src/main/java/io/office/modules/manage/service/impl/NewsMovieServiceImpl.java
View file @
717bdc65
...
...
@@ -58,7 +58,7 @@ public class NewsMovieServiceImpl extends ServiceImpl<NewsMovieDao, NewsMovieEnt
@Override
public
void
insert
(
NewsMovieEntityVo
newtopicEntityVo
,
SysUserEntity
user
)
{
Date
date
=
new
Date
();
newtopicEntityVo
.
setAuthor
(
user
.
getUsername
());
//
newtopicEntityVo.setAuthor(user.getUsername());
newtopicEntityVo
.
setReleasedate
(
date
);
newtopicEntityVo
.
setUpdatedate
(
date
);
newtopicEntityVo
.
setShowtime
(
DateUtils
.
format
(
date
,
DateUtils
.
DATE_PATTERN_1
));
...
...
src/main/java/io/office/modules/manage/service/impl/PlanBranchServiceImpl.java
View file @
717bdc65
...
...
@@ -38,6 +38,7 @@ public class PlanBranchServiceImpl extends ServiceImpl<PlanBranchDao, PlanBranch
public
void
batchUpdateStatus
(
PlanBranchVo
planBranchVo
,
SysUserEntity
user
)
{
planBranchVo
.
setLasteditor
(
user
.
getUsername
());
planBranchVo
.
setUpdatetime
(
new
Date
());
planBranchVo
.
setCheckflag
(
planBranchVo
.
getCheckflag
());
baseMapper
.
batchUpdateStatus
(
planBranchVo
);
}
...
...
src/main/resources/mapper/manage/PictureDao.xml
View file @
717bdc65
...
...
@@ -21,6 +21,7 @@
<result
property=
"showtime"
column=
"showtime"
/>
<result
property=
"auditor"
column=
"auditor"
/>
<result
property=
"lasteditor"
column=
"lasteditor"
/>
<result
property=
"flag"
column=
"flag"
/>
</resultMap>
<select
id=
"selectPictureList"
resultMap=
"pictureMap"
parameterType=
"io.office.modules.manage.entity.dto.PictureParams"
>
...
...
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