feat: Display total disk usage for series in the Library view to mirror Radarr functionality [#44]

This commit is contained in:
2025-08-11 10:24:00 -06:00
parent e96af7410e
commit 1f4870d082
5 changed files with 52 additions and 17 deletions
@@ -302,6 +302,15 @@ fn series_sorting_options() -> Vec<SortOption<Series>> {
name: "Language",
cmp_fn: Some(|a, b| a.language_profile_id.cmp(&b.language_profile_id)),
},
SortOption {
name: "Size",
cmp_fn: Some(|a, b| {
a.statistics
.as_ref()
.map_or(0, |stats| stats.size_on_disk)
.cmp(&b.statistics.as_ref().map_or(0, |stats| stats.size_on_disk))
}),
},
SortOption {
name: "Monitored",
cmp_fn: Some(|a, b| a.monitored.cmp(&b.monitored)),