admin: add event transport forms

This commit is contained in:
Jens Langhammer
2021-01-12 22:03:33 +01:00
parent 6f56c37d2f
commit cac94792fa
4 changed files with 119 additions and 0 deletions

View File

@ -276,6 +276,9 @@ class NotificationTransport(models.Model):
except (SMTPException, ConnectionError) as exc:
raise NotificationTransportError from exc
def __str__(self) -> str:
return f"Notification Transport {self.name}"
class Meta:
verbose_name = _("Notification Transport")
@ -344,6 +347,9 @@ class NotificationTrigger(PolicyBindingModel):
on_delete=models.SET_NULL,
)
def __str__(self) -> str:
return f"Notification Trigger {self.name}"
class Meta:
verbose_name = _("Notification Trigger")