mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-08-21 05:43:19 -07:00
parent
76a0d0d268
commit
031e2b9283
2 changed files with 6 additions and 5 deletions
|
@ -57,11 +57,11 @@
|
|||
<i class="far fa-play-circle fa-2x"></i>
|
||||
</a>
|
||||
</ng-container>
|
||||
<button *ngIf="!tv.fullyAvailable && !allEpisodesRequested()" mat-raised-button id="requestBtn" class="btn-spacing" color="primary"
|
||||
<button *ngIf="(!tv.fullyAvailable || (tv.fullyAvailable && tv.partlyAvailable)) && !allEpisodesRequestedOrAvailable()" mat-raised-button id="requestBtn" class="btn-spacing" color="primary"
|
||||
(click)="request()"><i class="fas fa-plus"></i>
|
||||
{{ 'Common.Request' | translate }}</button>
|
||||
|
||||
<button *ngIf="!tv.denied && allEpisodesRequested()" mat-raised-button class="btn-spacing" color="warn" [disabled]>
|
||||
<button *ngIf="!tv.denied && allEpisodesRequestedOrAvailable()" mat-raised-button class="btn-spacing" color="warn" [disabled]>
|
||||
<i class="fas fa-check"></i>
|
||||
{{ 'Common.Requested' | translate }}</button>
|
||||
|
||||
|
|
|
@ -126,9 +126,10 @@ export class TvDetailsComponent implements OnInit {
|
|||
}
|
||||
}
|
||||
|
||||
public allEpisodesRequested(): boolean {
|
||||
return this.tv.seasonRequests.every(e => e.episodes.every(x => x.approved || x.requested));
|
||||
public allEpisodesRequestedOrAvailable(): boolean {
|
||||
return this.tv.seasonRequests.every(e => e.episodes.every(x => x.available || x.approved || x.requested));
|
||||
}
|
||||
|
||||
private checkPoster() {
|
||||
if (this.tv.images.original == null) {
|
||||
this.tv.images.original = "../../../images/default_movie_poster.png";
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue