diff options
author | Wim <wim@42.be> | 2020-12-31 14:48:12 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-12-31 14:48:12 +0100 |
commit | 4f20ebead36876a88391bf033d1de3e4cf0228da (patch) | |
tree | 70b6fd79c6a5e00c958c29a7bd3926f074e76ba6 /vendor/github.com/mattermost/mattermost-server/v5/model/thread.go | |
parent | a9f89dbc645aafc68daa9fc8d589f55104b535c7 (diff) | |
download | matterbridge-msglm-4f20ebead36876a88391bf033d1de3e4cf0228da.tar.gz matterbridge-msglm-4f20ebead36876a88391bf033d1de3e4cf0228da.tar.bz2 matterbridge-msglm-4f20ebead36876a88391bf033d1de3e4cf0228da.zip |
Update vendor for next release (#1343)
Diffstat (limited to 'vendor/github.com/mattermost/mattermost-server/v5/model/thread.go')
-rw-r--r-- | vendor/github.com/mattermost/mattermost-server/v5/model/thread.go | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/vendor/github.com/mattermost/mattermost-server/v5/model/thread.go b/vendor/github.com/mattermost/mattermost-server/v5/model/thread.go index 71bf74f4..ec091c00 100644 --- a/vendor/github.com/mattermost/mattermost-server/v5/model/thread.go +++ b/vendor/github.com/mattermost/mattermost-server/v5/model/thread.go @@ -15,6 +15,42 @@ type Thread struct { Participants StringArray `json:"participants"` } +type ThreadResponse struct { + PostId string `json:"id"` + ReplyCount int64 `json:"reply_count"` + LastReplyAt int64 `json:"last_reply_at"` + LastViewedAt int64 `json:"last_viewed_at"` + Participants []*User `json:"participants"` + Post *Post `json:"post"` +} + +type Threads struct { + Total int64 `json:"total"` + Threads []*ThreadResponse `json:"threads"` +} + +type GetUserThreadsOpts struct { + // Page specifies which part of the results to return, by PageSize. Default = 0 + Page uint64 + + // PageSize specifies the size of the returned chunk of results. Default = 30 + PageSize uint64 + + // Extended will enrich the response with participant details. Default = false + Extended bool + + // Deleted will specify that even deleted threads should be returned (For mobile sync). Default = false + Deleted bool + + // Since filters the threads based on their LastUpdateAt timestamp. + Since uint64 +} + +func (o *Threads) ToJson() string { + b, _ := json.Marshal(o) + return string(b) +} + func (o *Thread) ToJson() string { b, _ := json.Marshal(o) return string(b) |