sys_message.go 2.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. // ==========================================================================
  2. // This is auto-generated by gf cli tool. Fill this file as you wish.
  3. // ==========================================================================
  4. package model
  5. import (
  6. "dashoo.cn/micro/app/model/internal"
  7. "dashoo.cn/opms_libary/request"
  8. "github.com/gogf/gf/os/gtime"
  9. )
  10. // SysMessage is the golang structure for table sys_message.
  11. type SysMessage internal.SysMessage
  12. // Fill with you ideas below.
  13. type SysMessageSearchReq struct {
  14. MsgTitle string `json:"msgTitle"`
  15. MsgType string `json:"msgType"`
  16. IsRead string `json:"isRead"` // 是否已读(10否20是)
  17. request.PageReq
  18. }
  19. type CreateSysMessageReq struct {
  20. MsgTitle string `json:"msgTitle" v:"required#消息标题不能为空"` // 消息标题
  21. MsgContent string `json:"msgContent" v:"required#消息内容不能为空"` // 消息内容
  22. MsgType string `json:"msgType" v:"required|in:10,20,30#消息类别不能为空|消息类别只能为10、20、30"` // 消息类别(10公告20消息30审批)
  23. MsgStatus string `json:"msgStatus" v:"required|in:10,20#消息状态不能为空|消息状态只能为10或20"` // 消息状态(10正常20关闭)
  24. RecvUserIds string `json:"recvUserIds"` // 接收用户
  25. SendType string `json:"sendType"` // 发送方式
  26. OpnUrl string `json:"opnUrl"` // 操作链接
  27. IsRead string `json:"isRead"` // 是否已读(10否20是)
  28. Remark string `json:"remark"` // 备注
  29. }
  30. type SendMessageReq struct {
  31. MsgTitle string `json:"msgTitle" v:"required#消息标题不能为空"` // 消息标题
  32. MsgContent string `json:"msgContent" v:"required#消息内容不能为空"` // 消息内容
  33. RecvUserIds string `json:"recvUserIds"` // 接收用户
  34. OpnUrl string `json:"opnUrl"` //附件地址
  35. }
  36. type UpdateSysMessageReq struct {
  37. Id int64 `json:"id" v:"required|min:1#主键ID不能为空|主键ID参数错误"`
  38. CreateSysMessageReq
  39. }
  40. type SysMessageUserRes struct {
  41. SysMessage
  42. IsRead string `orm:"is_read" json:"isRead"` // 是否已读(10否20是)
  43. ReadTime *gtime.Time `orm:"read_time" json:"readTime"` // 已读时间
  44. }