Compare commits
2
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
8becd9a49c
|
||
|
|
6ec7c4e212 |
No files matched your search
@@ -4,6 +4,7 @@ pub mod constants;
|
|||||||
pub mod coverart;
|
pub mod coverart;
|
||||||
pub mod ledger;
|
pub mod ledger;
|
||||||
pub mod login_result;
|
pub mod login_result;
|
||||||
|
pub mod playback_queue;
|
||||||
pub mod register_result;
|
pub mod register_result;
|
||||||
pub mod song;
|
pub mod song;
|
||||||
pub mod token;
|
pub mod token;
|
||||||
|
|||||||
@@ -0,0 +1,28 @@
|
|||||||
|
use serde::{Deserialize, Serialize};
|
||||||
|
use utoipa::ToSchema;
|
||||||
|
|
||||||
|
/// Playback queue device type - Browser
|
||||||
|
pub const PLAYBACK_QUEUE_DEVICE_TYPE_BROWSER: &str = "BROWSER";
|
||||||
|
/// Playback queue device type - Mobile
|
||||||
|
pub const PLAYBACK_QUEUE_DEVICE_TYPE_MOBILE: &str = "MOBILE";
|
||||||
|
|
||||||
|
#[derive(Debug, Default, Deserialize, Serialize, ToSchema)]
|
||||||
|
pub struct PlaybackQueue {
|
||||||
|
pub id: uuid::Uuid,
|
||||||
|
pub name: String,
|
||||||
|
pub device_type: String,
|
||||||
|
pub user_id: uuid::Uuid,
|
||||||
|
#[serde(with = "time::serde::rfc3339::option")]
|
||||||
|
pub date_created: Option<time::OffsetDateTime>,
|
||||||
|
}
|
||||||
|
|
||||||
|
#[derive(Debug, Default, Deserialize, Serialize, ToSchema)]
|
||||||
|
pub struct PlaybackQueueItem {
|
||||||
|
pub id: uuid::Uuid,
|
||||||
|
pub queue_index: i32,
|
||||||
|
pub playback_queue_id: uuid::Uuid,
|
||||||
|
pub song_id: uuid::Uuid,
|
||||||
|
#[serde(with = "time::serde::rfc3339::option")]
|
||||||
|
pub date_created: Option<time::OffsetDateTime>,
|
||||||
|
}
|
||||||
|
|
||||||
Reference in new issue
Block a user