Md-dialog close after notification
Md-dialog close after notification I have dialog box where user can enter data and after clicking on "create", my dialog box gets close and user gets notification. I want to close my dialog box after user get notification and if user enters wrong data, user should get notification for that too and dialog box should not get close. Currently, everything is working properly but I want my dialog box should disappear after notification (toster service). Can anyone help me with this thing so that my dialog box will stay till i get notification for success and also for error? exhibit.component.ts (main component) createExhibit(event: any) { let context = this; this.createDialogRef = this.dialog.open(CreateExhibitDialogComponent, { width: '45em', data: {} }); this.createDialogRef.afterClosed().subscribe( (newExhibit: Exhibit) => { if (newExhibit.latitude) { newExhibit.latitude = newExhibit.latitude.toString().replace(/,/g, '.'); } ...
