mirror of
https://github.com/C9Glax/tranga.git
synced 2025-10-16 10:20:46 +02:00
Enums as string
This commit is contained in:
@@ -42,16 +42,15 @@ public abstract class LibraryConnector : Identifiable
|
||||
internal abstract Task<bool> Test(CancellationToken ct);
|
||||
}
|
||||
|
||||
[JsonConverter(typeof(StringEnumConverter))]
|
||||
public enum LibraryType : byte
|
||||
public enum LibraryType
|
||||
{
|
||||
/// <summary>
|
||||
/// <seealso cref="Komga"/>
|
||||
/// </summary>
|
||||
Komga = 0,
|
||||
Komga,
|
||||
|
||||
/// <summary>
|
||||
/// <seealso cref="Kavita"/>
|
||||
/// </summary>
|
||||
Kavita = 1
|
||||
Kavita
|
||||
}
|
@@ -146,12 +146,11 @@ public class Manga : Identifiable
|
||||
public override string ToString() => $"{base.ToString()} {Name}";
|
||||
}
|
||||
|
||||
[JsonConverter(typeof(StringEnumConverter))]
|
||||
public enum MangaReleaseStatus : byte
|
||||
public enum MangaReleaseStatus
|
||||
{
|
||||
Continuing = 0,
|
||||
Completed = 1,
|
||||
OnHiatus = 2,
|
||||
Cancelled = 3,
|
||||
Unreleased = 4
|
||||
Continuing,
|
||||
Completed,
|
||||
OnHiatus,
|
||||
Cancelled,
|
||||
Unreleased
|
||||
}
|
@@ -50,10 +50,9 @@ public class Notification : Identifiable
|
||||
public override string ToString() => $"{base.ToString()} {Urgency} {Title} {Message}";
|
||||
}
|
||||
|
||||
[JsonConverter(typeof(StringEnumConverter))]
|
||||
public enum NotificationUrgency : byte
|
||||
public enum NotificationUrgency
|
||||
{
|
||||
Low = 1,
|
||||
Normal = 3,
|
||||
High = 5
|
||||
Low,
|
||||
Normal,
|
||||
High
|
||||
}
|
Reference in New Issue
Block a user