mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-08-14 02:26:55 -07:00
Localize episode request popup
This commit is contained in:
parent
fa1e711a25
commit
5ac0aa34e5
3 changed files with 12 additions and 7 deletions
|
@ -20,8 +20,8 @@
|
|||
<mat-expansion-panel-header>
|
||||
<mat-panel-title>
|
||||
<mat-checkbox *ngIf="!season.seasonAvailable && isSeasonCheckable(season)" (click)="$event.stopPropagation();" (change)="seasonChanged($event, season)">
|
||||
Season {{season.seasonNumber}}</mat-checkbox>
|
||||
<span *ngIf="season.seasonAvailable || !isSeasonCheckable(season)">Season {{season.seasonNumber}}</span>
|
||||
{{ 'MediaDetails.EpisodeSelector.SeasonNumber' | translate: { number: season.seasonNumber } }}</mat-checkbox>
|
||||
<span *ngIf="season.seasonAvailable || !isSeasonCheckable(season)">{{ 'MediaDetails.EpisodeSelector.SeasonNumber' | translate: { number: season.seasonNumber } }}</span>
|
||||
</mat-panel-title>
|
||||
<mat-panel-description>
|
||||
<!-- Description -->
|
||||
|
|
|
@ -3,6 +3,7 @@ import { MatCheckboxChange } from "@angular/material/checkbox";
|
|||
import { MatDialog, MatDialogRef, MAT_DIALOG_DATA } from "@angular/material/dialog";
|
||||
import { ISearchTvResultV2 } from "../../interfaces/ISearchTvResultV2";
|
||||
import { MessageService } from "../../services";
|
||||
import { TranslateService } from "@ngx-translate/core";
|
||||
import { ISeasonsViewModel, IEpisodesRequests, INewSeasonRequests, ITvRequestViewModelV2, IRequestEngineResult, RequestType } from "../../interfaces";
|
||||
import { RequestServiceV2 } from "../../services/requestV2.service";
|
||||
import { AdminRequestDialogComponent } from "../admin-request-dialog/admin-request-dialog.component";
|
||||
|
@ -23,7 +24,8 @@ export class EpisodeRequestComponent {
|
|||
}
|
||||
|
||||
constructor(public dialogRef: MatDialogRef<EpisodeRequestComponent>, @Inject(MAT_DIALOG_DATA) public data: EpisodeRequestData,
|
||||
private requestService: RequestServiceV2, private notificationService: MessageService, private dialog: MatDialog) { }
|
||||
private requestService: RequestServiceV2, private notificationService: MessageService, private dialog: MatDialog,
|
||||
private translate: TranslateService) { }
|
||||
|
||||
|
||||
public async submitRequests() {
|
||||
|
@ -35,7 +37,7 @@ export class EpisodeRequestComponent {
|
|||
});
|
||||
|
||||
if (!selected && !this.data.series.requestAll && !this.data.series.firstSeason && !this.data.series.latestSeason) {
|
||||
this.notificationService.send("You need to select some episodes!", "OK");
|
||||
this.notificationService.send(this.translate.instant("Requests.NeedToSelectEpisodes"), "OK");
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -123,7 +125,7 @@ export class EpisodeRequestComponent {
|
|||
private postRequest(requestResult: IRequestEngineResult) {
|
||||
if (requestResult.result) {
|
||||
this.notificationService.send(
|
||||
`Request for ${this.data.series.title} has been added successfully`);
|
||||
this.translate.instant("Requests.RequestAddedSuccessfully", { title: this.data.series.title }));
|
||||
|
||||
this.data.series.seasonRequests.forEach((season) => {
|
||||
season.episodes.forEach((ep) => {
|
||||
|
|
|
@ -194,7 +194,9 @@
|
|||
"ChangeAvailability":"Mark Available",
|
||||
"Deleted": "Successfully deleted selected items",
|
||||
"Approved": "Successfully approved selected items"
|
||||
}
|
||||
},
|
||||
"NeedToSelectEpisodes": "You need to select some episodes!",
|
||||
"RequestAddedSuccessfully": "Request for {{title}} has been added successfully"
|
||||
},
|
||||
"Issues": {
|
||||
"Title": "Issues",
|
||||
|
@ -305,7 +307,8 @@
|
|||
"AllSeasonsTooltip": "This will request every season for this show",
|
||||
"FirstSeasonTooltip": "This will only request the First Season for this show",
|
||||
"LatestSeasonTooltip": "This will only request the Latest Season for this show",
|
||||
"NoEpisodes": "There unfortunately is no episode data for this show yet!"
|
||||
"NoEpisodes": "There unfortunately is no episode data for this show yet!",
|
||||
"SeasonNumber": "Season {{number}}"
|
||||
},
|
||||
"SonarrConfiguration": "Sonarr Configuration",
|
||||
"RadarrConfiguration": "Radarr Configuration",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue