You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
description=_('The engagement "%(name)s" was deleted by %(user)s') % {
50
-
"name": instance.name, "user": le.actor}
51
-
create_notification(event="engagement_deleted", # template does not exists, it will default to "other" but this event name needs to stay because of unit testing
52
-
title=_("Deletion of %(name)s") % {"name": instance.name},
description=_('The engagement "%(name)s" was deleted by %(user)s') % {
54
+
"name": instance.name, "user": le.actor}
55
+
create_notification(event="engagement_deleted", # template does not exists, it will default to "other" but this event name needs to stay because of unit testing
56
+
title=_("Deletion of %(name)s") % {"name": instance.name},
description=_('The product "%(name)s" was deleted by %(user)s') % {
34
-
"name": instance.name, "user": le.actor}
35
-
create_notification(event="product_deleted", # template does not exists, it will default to "other" but this event name needs to stay because of unit testing
36
-
title=_("Deletion of %(name)s") % {"name": instance.name},
37
-
description=description,
38
-
url=reverse("product"),
39
-
icon="exclamation-triangle")
28
+
# Catch instances in async delete where a single object is deleted more than once
29
+
withcontextlib.suppress(sender.DoesNotExist):
30
+
description=_('The product "%(name)s" was deleted') % {"name": instance.name}
description=_('The product "%(name)s" was deleted by %(user)s') % {
38
+
"name": instance.name, "user": le.actor}
39
+
create_notification(event="product_deleted", # template does not exists, it will default to "other" but this event name needs to stay because of unit testing
40
+
title=_("Deletion of %(name)s") % {"name": instance.name},
description=_('The product type "%(name)s" was deleted by %(user)s') % {
34
-
"name": instance.name, "user": le.actor}
35
-
create_notification(event="product_type_deleted", # template does not exists, it will default to "other" but this event name needs to stay because of unit testing
36
-
title=_("Deletion of %(name)s") % {"name": instance.name},
37
-
description=description,
38
-
no_users=True,
39
-
url=reverse("product_type"),
40
-
icon="exclamation-triangle")
28
+
# Catch instances in async delete where a single object is deleted more than once
29
+
withcontextlib.suppress(sender.DoesNotExist):
30
+
description=_('The product type "%(name)s" was deleted') % {"name": instance.name}
description=_('The product type "%(name)s" was deleted by %(user)s') % {
38
+
"name": instance.name, "user": le.actor}
39
+
create_notification(event="product_type_deleted", # template does not exists, it will default to "other" but this event name needs to stay because of unit testing
40
+
title=_("Deletion of %(name)s") % {"name": instance.name},
description=_('The test "%(name)s" was deleted by %(user)s') % {
27
-
"name": str(instance), "user": le.actor}
28
-
create_notification(event="test_deleted", # template does not exists, it will default to "other" but this event name needs to stay because of unit testing
29
-
title=_("Deletion of %(name)s") % {"name": str(instance)},
description=_('The test "%(name)s" was deleted by %(user)s') % {
29
+
"name": str(instance), "user": le.actor}
30
+
create_notification(event="test_deleted", # Template does not exist, it will default to "other" but this event name needs to stay because of unit testing
31
+
title=_("Deletion of %(name)s") % {"name": str(instance)},
0 commit comments