mirror of
https://github.com/mattermost/focalboard.git
synced 2024-11-27 08:31:20 +02:00
154c344077
* Fix #2800. Add missing Swagger docs * Add note that timestamps are in miliseconds * Fix merge, update docs.
37 lines
702 B
Go
37 lines
702 B
Go
package model
|
|
|
|
import (
|
|
"encoding/json"
|
|
"io"
|
|
)
|
|
|
|
// Sharing is sharing information for a root block
|
|
// swagger:model
|
|
type Sharing struct {
|
|
// ID of the root block
|
|
// required: true
|
|
ID string `json:"id"`
|
|
|
|
// Is sharing enabled
|
|
// required: true
|
|
Enabled bool `json:"enabled"`
|
|
|
|
// Access token
|
|
// required: true
|
|
Token string `json:"token"`
|
|
|
|
// ID of the user who last modified this
|
|
// required: true
|
|
ModifiedBy string `json:"modifiedBy"`
|
|
|
|
// Updated time in miliseconds since the current epoch
|
|
// required: true
|
|
UpdateAt int64 `json:"update_at,omitempty"`
|
|
}
|
|
|
|
func SharingFromJSON(data io.Reader) Sharing {
|
|
var sharing Sharing
|
|
_ = json.NewDecoder(data).Decode(&sharing)
|
|
return sharing
|
|
}
|