diff --git a/src/Ombi.Store/Entities/Requests/MovieRequests.cs b/src/Ombi.Store/Entities/Requests/MovieRequests.cs index 0ccf55f0b..8075ba9bc 100644 --- a/src/Ombi.Store/Entities/Requests/MovieRequests.cs +++ b/src/Ombi.Store/Entities/Requests/MovieRequests.cs @@ -33,5 +33,28 @@ namespace Ombi.Store.Entities.Requests [NotMapped] [JsonIgnore] public string LanguageCode => LangCode.IsNullOrEmpty() ? "en" : LangCode; + + [NotMapped] + public string RequestStatus { + get + { + if (Approved & Available) + { + return "Common.Available"; + } + + if (Approved & !Available) + { + return "Common.ProcessingRequest"; + } + + if (!Approved && !Available) + { + return "Common.PendingApproval"; + } + + return string.Empty; + } + } } } diff --git a/src/Ombi/ClientApp/src/app/interfaces/IRequestModel.ts b/src/Ombi/ClientApp/src/app/interfaces/IRequestModel.ts index 5e76f9b40..4efb5ee76 100644 --- a/src/Ombi/ClientApp/src/app/interfaces/IRequestModel.ts +++ b/src/Ombi/ClientApp/src/app/interfaces/IRequestModel.ts @@ -15,6 +15,7 @@ export interface IMovieRequests extends IFullBaseRequest { digitalReleaseDate: Date; subscribed: boolean; showSubscribe: boolean; + requestStatus: string; // For the UI rootPathOverrideTitle: string; diff --git a/src/Ombi/ClientApp/src/app/requests-list/components/movies-grid/movies-grid.component.html b/src/Ombi/ClientApp/src/app/requests-list/components/movies-grid/movies-grid.component.html index 3c3c975af..e4a670b9c 100644 --- a/src/Ombi/ClientApp/src/app/requests-list/components/movies-grid/movies-grid.component.html +++ b/src/Ombi/ClientApp/src/app/requests-list/components/movies-grid/movies-grid.component.html @@ -37,16 +37,8 @@ - Request Status - -
{{'Common.ProcessingRequest' | translate}}
-
{{'Common.PendingApproval' | - translate}} -
-
{{'Common.NotRequested' | - translate}} -
- + Request Status + {{element.requestStatus | translate}}