SEO/AEO, Farb schema, breadcrumbs
This commit is contained in:
@@ -128,14 +128,21 @@ export class EditBusinessListingComponent {
|
||||
this.messageService.addMessage({ severity: 'success', text: 'Listing changes have been persisted', duration: 3000 });
|
||||
this.validationMessagesService.clearMessages(); // Löschen Sie alle bestehenden Validierungsnachrichten
|
||||
} catch (error) {
|
||||
this.messageService.addMessage({
|
||||
severity: 'danger',
|
||||
text: 'An error occurred while saving the profile - Please check your inputs',
|
||||
duration: 5000,
|
||||
});
|
||||
console.error('Error saving listing:', error);
|
||||
let errorText = 'An error occurred while saving the listing - Please check your inputs';
|
||||
|
||||
if (error.error && Array.isArray(error.error?.message)) {
|
||||
this.validationMessagesService.updateMessages(error.error.message);
|
||||
errorText = 'Please fix the validation errors highlighted in the form';
|
||||
} else if (error.error?.message) {
|
||||
errorText = `Error: ${error.error.message}`;
|
||||
}
|
||||
|
||||
this.messageService.addMessage({
|
||||
severity: 'danger',
|
||||
text: errorText,
|
||||
duration: 5000,
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user