Converted StaleMediaTask to StaleMediaScanner for use in plugin home page. Also added a generic Media Info class that can be filtered to return the data you desire.

This commit is contained in:
2026-01-25 14:52:47 -07:00
parent 66716a9bc9
commit 04ef815a9b
10 changed files with 213 additions and 111 deletions

View File

@@ -0,0 +1,9 @@
using System;
namespace Jellyfin.Plugin.MediaCleaner.Models;
public abstract class MediaInfo
{
public required Guid Id { get; set; }
public required string Name { get; set; }
}

View File

@@ -0,0 +1,14 @@
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using Jellyfin.Plugin.MediaCleaner;
namespace Jellyfin.Plugin.MediaCleaner.Models;
/// <summary>
/// Contains Movie information.
/// </summary>
public class MovieInfo : MediaInfo
{
}

View File

@@ -1,26 +1,14 @@
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using Jellyfin.Plugin.MediaCleaner;
namespace Jellyfin.Plugin.MediaCleaner.Models;
/// <summary>
/// Contains series information.
/// </summary>
public class SeriesInfo
public class SeriesInfo : MediaInfo
{
/// <summary>
/// Gets or sets series identifier.
/// </summary>
public Guid Id { get; set; }
/// <summary>
/// Gets or sets series name.
/// </summary>
public string SeriesName { get; set; } = string.Empty;
/// <summary>
/// Gets or sets seasons.
/// </summary>
public IEnumerable<string> Seasons { get; set; } = [];
}