85 lines
2.5 KiB
C#
85 lines
2.5 KiB
C#
namespace PlotLine.Models;
|
|
|
|
public static class FeatureRequestStatuses
|
|
{
|
|
public const string New = "New";
|
|
public const string NeedsDetail = "Needs Detail";
|
|
public const string UnderReview = "Under Review";
|
|
public const string Candidate = "Candidate";
|
|
public const string Planned = "Planned";
|
|
public const string InProgress = "In Progress";
|
|
public const string Shipped = "Shipped";
|
|
public const string NotPlanned = "Not Planned";
|
|
|
|
public static IReadOnlyList<string> All { get; } =
|
|
[
|
|
New,
|
|
NeedsDetail,
|
|
UnderReview,
|
|
Candidate,
|
|
Planned,
|
|
InProgress,
|
|
Shipped,
|
|
NotPlanned
|
|
];
|
|
|
|
public static bool IsValid(string? status) => All.Contains(status ?? string.Empty, StringComparer.OrdinalIgnoreCase);
|
|
}
|
|
|
|
public static class FeatureRequestOptions
|
|
{
|
|
public static IReadOnlyList<string> AppAreas { get; } =
|
|
[
|
|
"Timeline",
|
|
"Characters",
|
|
"Locations",
|
|
"Assets",
|
|
"Plot Lines",
|
|
"Continuity",
|
|
"Writing Schedule",
|
|
"Word Companion",
|
|
"Import / Export",
|
|
"Billing / Account",
|
|
"Other"
|
|
];
|
|
|
|
public static IReadOnlyList<string> ImportanceOptions { get; } =
|
|
[
|
|
"Nice to have",
|
|
"Would save me time",
|
|
"Blocking my workflow"
|
|
];
|
|
}
|
|
|
|
public sealed class FeatureRequest
|
|
{
|
|
public int FeatureRequestID { get; set; }
|
|
public int UserID { get; set; }
|
|
public string? UserEmail { get; set; }
|
|
public string? UserDisplayName { get; set; }
|
|
public string Title { get; set; } = string.Empty;
|
|
public string Description { get; set; } = string.Empty;
|
|
public string? AppArea { get; set; }
|
|
public string? Importance { get; set; }
|
|
public string Status { get; set; } = FeatureRequestStatuses.New;
|
|
public bool IsPublicCandidate { get; set; }
|
|
public string? AdminNotes { get; set; }
|
|
public DateTime CreatedUtc { get; set; }
|
|
public DateTime UpdatedUtc { get; set; }
|
|
public DateTime? ClosedUtc { get; set; }
|
|
public DateTime? ShippedUtc { get; set; }
|
|
public DateTime? LatestActivityUtc { get; set; }
|
|
}
|
|
|
|
public sealed class FeatureRequestMessage
|
|
{
|
|
public int FeatureRequestMessageID { get; set; }
|
|
public int FeatureRequestID { get; set; }
|
|
public int? UserID { get; set; }
|
|
public string? UserEmail { get; set; }
|
|
public string? UserDisplayName { get; set; }
|
|
public bool IsAdmin { get; set; }
|
|
public string MessageBody { get; set; } = string.Empty;
|
|
public DateTime CreatedUtc { get; set; }
|
|
}
|