Skip to content

Commit

Permalink
LP#2091015: Fix patron reservation screen advance on failure
Browse files Browse the repository at this point in the history
In the booking module, resolved an issue where clicking \"Confirm and Show Patron Reservations\" would advance to the reservation screen even if the reservation confirmation failed due to invalid inputs. The behavior is now corrected to remain on the reservation page when errors are present.

Release-Note: Prevents reservation screen navigation if reservation confirmation fails.

Steps to test:
- Navigate to the booking module.
- Try creating a reservation with invalid or incomplete data.
- Verify the error message appears.
- Confirm that clicking \"Confirm and Show Patron Reservations\" does not navigate to the next screen if errors exist.

Signed-off-by: IanSkelskey <ianskelskey@gmail.com>
Signed-off-by: Gina Monti <gmonti@biblio.org>
Signed-off-by: Jason Stephenson <jason@sigio.com>
  • Loading branch information
IanSkelskey authored and Dyrcona committed Dec 9, 2024
1 parent 0458ae0 commit e5f380c
Showing 1 changed file with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -183,8 +183,13 @@ export class CreateReservationDialogComponent
};

addBresvAndOpenPatronReservations = (): void => {
this.addBresv$()
.subscribe(() => this.openPatronReservations());
this.addBresv$().subscribe({
next: (response) => {
if (!('ilsevent' in response)) {
this.openPatronReservations();
}
}
});
};

searchPatrons() {
Expand Down

0 comments on commit e5f380c

Please sign in to comment.