mirror of
https://github.com/gabehf/Koito.git
synced 2026-03-09 15:38:17 -07:00
* add all time rank to item pages * fix artist albums component * add no rows check * fix rewind page
34 lines
1.1 KiB
Go
34 lines
1.1 KiB
Go
package models
|
|
|
|
import "github.com/google/uuid"
|
|
|
|
type Artist struct {
|
|
ID int32 `json:"id"`
|
|
MbzID *uuid.UUID `json:"musicbrainz_id"`
|
|
Name string `json:"name"`
|
|
Aliases []string `json:"aliases"`
|
|
Image *uuid.UUID `json:"image"`
|
|
ListenCount int64 `json:"listen_count"`
|
|
TimeListened int64 `json:"time_listened"`
|
|
FirstListen int64 `json:"first_listen"`
|
|
IsPrimary bool `json:"is_primary,omitempty"`
|
|
AllTimeRank int64 `json:"all_time_rank"`
|
|
}
|
|
|
|
type SimpleArtist struct {
|
|
ID int32 `json:"id"`
|
|
Name string `json:"name"`
|
|
}
|
|
|
|
type ArtistWithFullAliases struct {
|
|
ID int32 `json:"id"`
|
|
MbzID *uuid.UUID `json:"musicbrainz_id"`
|
|
Name string `json:"name"`
|
|
Aliases []Alias `json:"aliases"`
|
|
Image *uuid.UUID `json:"image"`
|
|
ImageSource string `json:"image_source,omitempty"`
|
|
ListenCount int64 `json:"listen_count"`
|
|
TimeListened int64 `json:"time_listened"`
|
|
FirstListen int64 `json:"first_listen"`
|
|
IsPrimary bool `json:"is_primary,omitempty"`
|
|
}
|