add seatIsSelected to SelectedSeatService, so seats cannot be interacted with while cooking/reservation

This commit is contained in:
Marcel-Anker
2025-11-13 17:47:45 +01:00
parent a9e1d28f09
commit 769fb8b2cd
3 changed files with 15 additions and 2 deletions

View File

@@ -1,4 +1,4 @@
<button (click)="updateSelectedSeats(this.seat())" [disabled]="state() == TheaterSeatState.BOOKED || state() == TheaterSeatState.RESERVED" class="mx-1 hover:opacity-50">
<button (click)="updateSelectedSeats(this.seat())" [disabled]="state() == TheaterSeatState.BOOKED || state() == TheaterSeatState.RESERVED || !seatService.getSeatIsSelected()" class="mx-1 hover:opacity-50">
<mat-icon [ngStyle]="{'opacity': selected ? '0.5' : '1', color: getSeatStateColor() }" style="font-size: 30px; width: 30px; height: 30px">
@if(this.seat().row.category.id ==1){
event_seat