mirror of
https://github.com/C9Glax/tranga.git
synced 2025-10-18 03:10:45 +02:00
Actions use enum
This commit is contained in:
@@ -3,15 +3,13 @@ using API.Schema.MangaContext;
|
||||
|
||||
namespace API.Schema.ActionsContext.Actions;
|
||||
|
||||
public sealed class ChapterDownloadedActionRecord(string action, DateTime performedAt, string chapterId) : ActionRecord(action, performedAt)
|
||||
public sealed class ChapterDownloadedActionRecord(ActionsEnum action, DateTime performedAt, string chapterId) : ActionRecord(action, performedAt)
|
||||
{
|
||||
public ChapterDownloadedActionRecord(Chapter chapter) : this(ChapterDownloadedAction, DateTime.UtcNow, chapter.Key) { }
|
||||
public ChapterDownloadedActionRecord(Chapter chapter) : this(ActionsEnum.ChapterDownloaded, DateTime.UtcNow, chapter.Key) { }
|
||||
|
||||
/// <summary>
|
||||
/// Chapter that was downloaded
|
||||
/// </summary>
|
||||
[StringLength(64)]
|
||||
public string ChapterId { get; init; } = chapterId;
|
||||
|
||||
public const string ChapterDownloadedAction = "Chapter.Downloaded";
|
||||
}
|
Reference in New Issue
Block a user