quintodrome/model/annotation.go

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

18 lines
549 B
Go
Raw Normal View History

2020-01-21 19:01:43 -09:00
package model
import "time"
type Annotations struct {
2024-09-09 15:45:02 -08:00
PlayCount int64 `structs:"play_count" json:"playCount"`
PlayDate *time.Time `structs:"play_date" json:"playDate" `
Rating int `structs:"rating" json:"rating" `
Starred bool `structs:"starred" json:"starred" `
StarredAt *time.Time `structs:"starred_at" json:"starredAt"`
}
2020-01-31 17:09:23 -09:00
type AnnotatedRepository interface {
IncPlayCount(itemID string, ts time.Time) error
SetStar(starred bool, itemIDs ...string) error
SetRating(rating int, itemID string) error
2020-01-21 19:01:43 -09:00
}