Documentation ¶
Overview ¶
Copyright 2019-2020 Axetroy. All rights reserved. MIT license.
Copyright 2019-2020 Axetroy. All rights reserved. MIT license.
Copyright 2019-2020 Axetroy. All rights reserved. MIT license.
Copyright 2019-2020 Axetroy. All rights reserved. MIT license.
Index ¶
- Variables
- func DeleteByUser(c helper.Context, messageId string) (res schema.Response)
- func DeleteMessageById(id string)
- func Get(c helper.Context, id string) (res schema.Response)
- func GetMessageListByUser(c helper.Context, input Query) (res schema.Response)
- func MarkRead(c helper.Context, id string) (res schema.Response)
- type Query
- type QueryAdmin
Constants ¶
This section is empty.
Variables ¶
View Source
var DeleteByUserRouter = router.Handler(func(c router.Context) { id := c.Param("message_id") c.ResponseFunc(nil, func() schema.Response { return DeleteByUser(helper.NewContext(&c), id) }) })
View Source
var GetMessageListByUserRouter = router.Handler(func(c router.Context) { var ( input Query ) c.ResponseFunc(c.ShouldBindQuery(&input), func() schema.Response { return GetMessageListByUser(helper.NewContext(&c), input) }) })
View Source
var GetRouter = router.Handler(func(c router.Context) { id := c.Param("message_id") c.ResponseFunc(nil, func() schema.Response { return Get(helper.NewContext(&c), id) }) })
GetRouter get Message detail router
Functions ¶
func DeleteMessageById ¶
func DeleteMessageById(id string)
func GetMessageListByUser ¶
用户获取自己的消息列表
Types ¶
type Query ¶
type Query struct { schema.Query Status *model.MessageStatus `json:"status" form:"status"` Read *bool `json:"read" form:"read"` }
type QueryAdmin ¶
Click to show internal directories.
Click to hide internal directories.