Skip to content

Commit

Permalink
WebUI file summary: return import folder ID instead of name
Browse files Browse the repository at this point in the history
  • Loading branch information
harshithmohan committed Jan 22, 2025
1 parent 26190ef commit 59c8210
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Shoko.Server/API/v3/Models/Shoko/WebUI.cs
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ public WebUISeriesFileSummary(
if (groupByCriteria.Contains(FileSummaryGroupByCriteria.FileIsDeprecated))
groupByDetails.FileIsDeprecated = anidbFile?.IsDeprecated ?? false;
if (groupByCriteria.Contains(FileSummaryGroupByCriteria.ImportFolder))
groupByDetails.ImportFolder = $"{location.ImportFolder?.ImportFolderName ?? "N/A"} (ID: {location.ImportFolderID})";
groupByDetails.ImportFolder = location.ImportFolderID;
if (groupByCriteria.Contains(FileSummaryGroupByCriteria.ED2K))
groupByDetails.ED2K = $"{file.Hash}+{file.FileSize}";

Expand Down Expand Up @@ -529,7 +529,7 @@ public class EpisodeGroupSummary(Dictionary<EpisodeType, EpisodeRangeByType> ran
/// The import folder name of the files in this range.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string? ImportFolder { get; set; }
public int? ImportFolder { get; set; }

/// <summary>
/// The ED2K hash + file size of the file in this range.
Expand Down Expand Up @@ -801,7 +801,7 @@ private class GroupByDetails : IEquatable<GroupByDetails>

public bool? FileIsDeprecated { get; set; }

public string? ImportFolder { get; set; }
public int? ImportFolder { get; set; }

public string? ED2K { get; set; }

Expand Down

0 comments on commit 59c8210

Please sign in to comment.