Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
guns-vip
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
chenjunxiong
guns-vip
Commits
87d40e80
Commit
87d40e80
authored
Dec 23, 2018
by
fengshuonan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
整理通知管理
parent
094e1b62
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
28 additions
and
1 deletions
+28
-1
src/main/java/cn/stylefeng/guns/modular/system/controller/NoticeController.java
+25
-1
src/main/java/cn/stylefeng/guns/modular/system/service/NoticeService.java
+3
-0
No files found.
src/main/java/cn/stylefeng/guns/modular/system/controller/NoticeController.java
View file @
87d40e80
...
@@ -57,6 +57,9 @@ public class NoticeController extends BaseController {
...
@@ -57,6 +57,9 @@ public class NoticeController extends BaseController {
/**
/**
* 跳转到通知列表首页
* 跳转到通知列表首页
*
* @author fengshuonan
* @Date 2018/12/23 6:06 PM
*/
*/
@RequestMapping
(
""
)
@RequestMapping
(
""
)
public
String
index
()
{
public
String
index
()
{
...
@@ -65,6 +68,9 @@ public class NoticeController extends BaseController {
...
@@ -65,6 +68,9 @@ public class NoticeController extends BaseController {
/**
/**
* 跳转到添加通知
* 跳转到添加通知
*
* @author fengshuonan
* @Date 2018/12/23 6:06 PM
*/
*/
@RequestMapping
(
"/notice_add"
)
@RequestMapping
(
"/notice_add"
)
public
String
noticeAdd
()
{
public
String
noticeAdd
()
{
...
@@ -73,6 +79,9 @@ public class NoticeController extends BaseController {
...
@@ -73,6 +79,9 @@ public class NoticeController extends BaseController {
/**
/**
* 跳转到修改通知
* 跳转到修改通知
*
* @author fengshuonan
* @Date 2018/12/23 6:06 PM
*/
*/
@RequestMapping
(
"/notice_update/{noticeId}"
)
@RequestMapping
(
"/notice_update/{noticeId}"
)
public
String
noticeUpdate
(
@PathVariable
Long
noticeId
,
Model
model
)
{
public
String
noticeUpdate
(
@PathVariable
Long
noticeId
,
Model
model
)
{
...
@@ -84,6 +93,9 @@ public class NoticeController extends BaseController {
...
@@ -84,6 +93,9 @@ public class NoticeController extends BaseController {
/**
/**
* 跳转到首页通知
* 跳转到首页通知
*
* @author fengshuonan
* @Date 2018/12/23 6:06 PM
*/
*/
@RequestMapping
(
"/hello"
)
@RequestMapping
(
"/hello"
)
public
String
hello
()
{
public
String
hello
()
{
...
@@ -94,6 +106,9 @@ public class NoticeController extends BaseController {
...
@@ -94,6 +106,9 @@ public class NoticeController extends BaseController {
/**
/**
* 获取通知列表
* 获取通知列表
*
* @author fengshuonan
* @Date 2018/12/23 6:06 PM
*/
*/
@RequestMapping
(
value
=
"/list"
)
@RequestMapping
(
value
=
"/list"
)
@ResponseBody
@ResponseBody
...
@@ -104,6 +119,9 @@ public class NoticeController extends BaseController {
...
@@ -104,6 +119,9 @@ public class NoticeController extends BaseController {
/**
/**
* 新增通知
* 新增通知
*
* @author fengshuonan
* @Date 2018/12/23 6:06 PM
*/
*/
@RequestMapping
(
value
=
"/add"
)
@RequestMapping
(
value
=
"/add"
)
@ResponseBody
@ResponseBody
...
@@ -112,7 +130,7 @@ public class NoticeController extends BaseController {
...
@@ -112,7 +130,7 @@ public class NoticeController extends BaseController {
if
(
ToolUtil
.
isOneEmpty
(
notice
,
notice
.
getTitle
(),
notice
.
getContent
()))
{
if
(
ToolUtil
.
isOneEmpty
(
notice
,
notice
.
getTitle
(),
notice
.
getContent
()))
{
throw
new
ServiceException
(
BizExceptionEnum
.
REQUEST_NULL
);
throw
new
ServiceException
(
BizExceptionEnum
.
REQUEST_NULL
);
}
}
notice
.
setCreateUser
(
ShiroKit
.
getUser
().
getId
());
notice
.
setCreateUser
(
ShiroKit
.
getUser
NotNull
().
getId
());
notice
.
setCreateTime
(
new
Date
());
notice
.
setCreateTime
(
new
Date
());
this
.
noticeService
.
insert
(
notice
);
this
.
noticeService
.
insert
(
notice
);
return
SUCCESS_TIP
;
return
SUCCESS_TIP
;
...
@@ -120,6 +138,9 @@ public class NoticeController extends BaseController {
...
@@ -120,6 +138,9 @@ public class NoticeController extends BaseController {
/**
/**
* 删除通知
* 删除通知
*
* @author fengshuonan
* @Date 2018/12/23 6:06 PM
*/
*/
@RequestMapping
(
value
=
"/delete"
)
@RequestMapping
(
value
=
"/delete"
)
@ResponseBody
@ResponseBody
...
@@ -136,6 +157,9 @@ public class NoticeController extends BaseController {
...
@@ -136,6 +157,9 @@ public class NoticeController extends BaseController {
/**
/**
* 修改通知
* 修改通知
*
* @author fengshuonan
* @Date 2018/12/23 6:06 PM
*/
*/
@RequestMapping
(
value
=
"/update"
)
@RequestMapping
(
value
=
"/update"
)
@ResponseBody
@ResponseBody
...
...
src/main/java/cn/stylefeng/guns/modular/system/service/NoticeService.java
View file @
87d40e80
...
@@ -21,6 +21,9 @@ public class NoticeService extends ServiceImpl<NoticeMapper, Notice> {
...
@@ -21,6 +21,9 @@ public class NoticeService extends ServiceImpl<NoticeMapper, Notice> {
/**
/**
* 获取通知列表
* 获取通知列表
*
* @author fengshuonan
* @Date 2018/12/23 6:05 PM
*/
*/
public
List
<
Map
<
String
,
Object
>>
list
(
String
condition
)
{
public
List
<
Map
<
String
,
Object
>>
list
(
String
condition
)
{
return
this
.
baseMapper
.
list
(
condition
);
return
this
.
baseMapper
.
list
(
condition
);
...
...
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