Mostly completed tags implementation; still need to add the UI option for the Add Movie popup, and I still need to fix the REALLY FAST horizontal scrolling issue (I'm thinking just %2 everything to slow it down). Oh, and also need to convert the quality profile Hashmap into a BiMap

This commit is contained in:
2023-08-08 10:50:05 -06:00
parent f92042fb21
commit 207b8a8c80
21 changed files with 948 additions and 344 deletions
+10 -1
View File
@@ -57,6 +57,7 @@ pub struct Movie {
pub quality_profile_id: Number,
pub minimum_availability: MinimumAvailability,
pub certification: Option<String>,
pub tags: Vec<Number>,
pub ratings: RatingsList,
pub movie_file: Option<MovieFile>,
pub collection: Option<Collection>,
@@ -169,13 +170,20 @@ pub struct DownloadRecord {
#[derive(Derivative, Deserialize, Debug)]
#[derivative(Default)]
#[serde(rename_all = "camelCase")]
pub struct QualityProfile {
#[derivative(Default(value = "Number::from(0)"))]
pub id: Number,
pub name: String,
}
#[derive(Derivative, Deserialize, Debug)]
#[derivative(Default)]
pub struct Tag {
#[derivative(Default(value = "Number::from(0)"))]
pub id: Number,
pub label: String,
}
#[derive(Deserialize, Default, Debug, Clone, PartialEq, Eq)]
#[serde(rename_all = "camelCase")]
pub struct MovieHistoryItem {
@@ -265,6 +273,7 @@ pub struct AddMovieBody {
pub quality_profile_id: u64,
pub minimum_availability: String,
pub monitored: bool,
pub tags: Vec<u64>,
pub add_options: AddOptions,
}