mirror of
https://github.com/navidrome/navidrome.git
synced 2026-11-03 08:57:53 +01:00
feat: persist and expose plugin playlist ValidUntil in Subsonic API
Add a ValidUntil field to the Playlist model and persist it from the plugin's GetPlaylistResponse during sync. This allows clients to know when a plugin playlist's data will be refreshed. The value is exposed in the OpenSubsonic playlist response alongside the existing smart playlist ValidUntil calculation. The migration is consolidated into a single multi-statement ExecContext call.
This commit is contained in:
parent
a5fd18dc67
commit
9ddbcbf6b4
6 changed files with 33 additions and 22 deletions
|
|
@ -32,8 +32,9 @@ type Playlist struct {
|
|||
EvaluatedAt *time.Time `structs:"evaluated_at" json:"evaluatedAt"`
|
||||
|
||||
// Plugin playlist attributes
|
||||
PluginID string `structs:"plugin_id" json:"pluginId,omitempty"`
|
||||
PluginPlaylistID string `structs:"plugin_playlist_id" json:"pluginPlaylistId,omitempty"`
|
||||
PluginID string `structs:"plugin_id" json:"pluginId,omitempty"`
|
||||
PluginPlaylistID string `structs:"plugin_playlist_id" json:"pluginPlaylistId,omitempty"`
|
||||
ValidUntil *time.Time `structs:"valid_until" json:"validUntil,omitempty"`
|
||||
}
|
||||
|
||||
func (pls Playlist) IsReadOnly() bool {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue