|
|
@ -2,8 +2,8 @@ package cn.stylefeng.guns.modular.system.message;
|
|
|
|
|
|
|
|
|
|
|
|
import cn.stylefeng.roses.kernel.message.api.MessageApi;
|
|
|
|
import cn.stylefeng.roses.kernel.message.api.MessageApi;
|
|
|
|
import cn.stylefeng.roses.kernel.message.api.enums.MessageReadFlagEnum;
|
|
|
|
import cn.stylefeng.roses.kernel.message.api.enums.MessageReadFlagEnum;
|
|
|
|
import cn.stylefeng.roses.kernel.message.api.pojo.MessageParam;
|
|
|
|
import cn.stylefeng.roses.kernel.message.api.pojo.request.MessageRequest;
|
|
|
|
import cn.stylefeng.roses.kernel.message.api.pojo.MessageResponse;
|
|
|
|
import cn.stylefeng.roses.kernel.message.api.pojo.response.MessageResponse;
|
|
|
|
import cn.stylefeng.roses.kernel.resource.api.annotation.ApiResource;
|
|
|
|
import cn.stylefeng.roses.kernel.resource.api.annotation.ApiResource;
|
|
|
|
import cn.stylefeng.roses.kernel.resource.api.annotation.GetResource;
|
|
|
|
import cn.stylefeng.roses.kernel.resource.api.annotation.GetResource;
|
|
|
|
import org.springframework.stereotype.Controller;
|
|
|
|
import org.springframework.stereotype.Controller;
|
|
|
@ -33,10 +33,10 @@ public class MessageViewController {
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
@GetResource(name = "系统消息界面", path = "/view/message", requiredPermission = false)
|
|
|
|
@GetResource(name = "系统消息界面", path = "/view/message", requiredPermission = false)
|
|
|
|
public String message(Model model) {
|
|
|
|
public String message(Model model) {
|
|
|
|
MessageParam messageParam = new MessageParam();
|
|
|
|
MessageRequest messageRequest = new MessageRequest();
|
|
|
|
messageParam.setReadFlag(MessageReadFlagEnum.UNREAD.getCode());
|
|
|
|
messageRequest.setReadFlag(MessageReadFlagEnum.UNREAD.getCode());
|
|
|
|
Integer messageCount = messageApi.queryCountCurrentUser(messageParam);
|
|
|
|
Integer messageCount = messageApi.queryCountCurrentUser(messageRequest);
|
|
|
|
List<MessageResponse> messageList = messageApi.queryListCurrentUser(messageParam);
|
|
|
|
List<MessageResponse> messageList = messageApi.queryListCurrentUser(messageRequest);
|
|
|
|
model.addAttribute("msgUnReadCount", messageCount);
|
|
|
|
model.addAttribute("msgUnReadCount", messageCount);
|
|
|
|
model.addAttribute("msgUnReadList", messageList);
|
|
|
|
model.addAttribute("msgUnReadList", messageList);
|
|
|
|
return "/modular/system/index/message.html";
|
|
|
|
return "/modular/system/index/message.html";
|
|
|
|