change(ui) - alert notification

This commit is contained in:
Shekar Siri 2022-11-18 12:29:56 +01:00
parent 4943cfd75a
commit d8056a3490

View file

@ -122,6 +122,9 @@ const NewAlert = (props: IProps) => {
) {
remove(instance.alertId).then(() => {
props.history.push(withSiteId(alerts(), siteId));
toast.success('Alert deleted');
}).catch(() => {
toast.error('Failed to delete an alert');
});
}
};
@ -135,6 +138,8 @@ const NewAlert = (props: IProps) => {
} else {
toast.success('Alert updated');
}
}).catch(() => {
toast.error('Failed to create an alert');
});
};