Playlist: update service so it supports both read+write (#55959)

This commit is contained in:
Ryan McKinley
2022-10-04 11:11:18 -04:00
committed by GitHub
parent d293055ef6
commit 3b1a8d45ed
14 changed files with 118 additions and 287 deletions
@@ -7,10 +7,6 @@
// Run `make gen-cue` from repository root to regenerate.
export interface Playlist {
/**
* Unique playlist identifier for internal use, set by Grafana.
*/
id: number;
/**
* Interval sets the time between switching views in a playlist.
* FIXME: Is this based on a standardized format or what options are available? Can datemath be used?
@@ -20,15 +16,6 @@ export interface Playlist {
* The ordered list of items that the playlist will iterate over.
*/
items?: Array<{
/**
* FIXME: The prefixDropper removes playlist from playlist_id, that doesn't work for us since it'll mean we'll have Id twice.
* ID of the playlist item for internal use by Grafana. Deprecated.
*/
id: number;
/**
* PlaylistID for the playlist containing the item. Deprecated.
*/
playlistid: number;
/**
* Type of the item.
*/
@@ -38,19 +25,16 @@ export interface Playlist {
*
* - dashboard_by_id: The value is an internal numerical identifier set by Grafana. This
* is not portable as the numerical identifier is non-deterministic between different instances.
* Will be replaced by dashboard_by_uid in the future.
* Will be replaced by dashboard_by_uid in the future. (deprecated)
* - dashboard_by_tag: The value is a tag which is set on any number of dashboards. All
* dashboards behind the tag will be added to the playlist.
* - dashboard_by_uid: The value is the dashboard UID
*/
value: string;
/**
* Title is the human-readable identifier for the playlist item.
* Title is an unused property -- it will be removed in the future
*/
title: string;
/**
* Order is the position in the list for the item. Deprecated.
*/
order: number;
}>;
/**
* Name of the playlist.