通用模块-公共消息
This commit is contained in:
@@ -2,7 +2,6 @@ package com.peanut.modules.master.controller;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.github.yulichang.wrapper.MPJLambdaWrapper;
|
||||
import com.peanut.common.utils.R;
|
||||
import com.peanut.modules.common.entity.Message;
|
||||
import com.peanut.modules.master.service.MessageService;
|
||||
@@ -12,9 +11,11 @@ import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 公共消息
|
||||
*/
|
||||
@Slf4j
|
||||
@RestController("masterMessage")
|
||||
@RequestMapping("master/message")
|
||||
@@ -47,6 +48,11 @@ public class MessageController {
|
||||
return R.ok().put("result", page);
|
||||
}
|
||||
|
||||
@RequestMapping("/getMessageById")
|
||||
public R getMessageById(String id) {
|
||||
return R.ok().put("result", messageService.getById(id));
|
||||
}
|
||||
|
||||
@RequestMapping("/saveOrUpdateMessage")
|
||||
public R saveOrUpdateMessage(@RequestBody Message message) {
|
||||
messageService.saveOrUpdate(message);
|
||||
|
||||
Reference in New Issue
Block a user