I am on Umbraco 10.
I am injecting the notificationsService into my Javascript files to send out information messages. It works great!
However, I noticed that notificationsService only has a ".success" method and I have the need to send out a Notification when a user enters something wrong in the backoffice. Note: notificationsService does not offer a ".error" method.
Does anyone know what service I would use to send out error notifications?
What's the opposite of notificationsService?
I am on Umbraco 10. I am injecting the notificationsService into my Javascript files to send out information messages. It works great!
However, I noticed that notificationsService only has a ".success" method and I have the need to send out a Notification when a user enters something wrong in the backoffice. Note: notificationsService does not offer a ".error" method.
Does anyone know what service I would use to send out error notifications?
Thanks
Tom
Hi Tom!
The notificationService should have an "'.error" method. According to the docs you should be able to do something like this:
You can read more about it here: https://apidocs.umbraco.com/v9/ui/#/api/umbraco.services.notificationsService
//Johannes
Thank you very much. That worked. Tom PS For me, Intellisense didn't report a .failure as an option.
is working on a reply...