# 63 Mail data deleted
* adds mail sending if shared data is deleted * adds/updates translations * refactors recording mails into separate email template folder email/recording
This commit is contained in:
@@ -76,3 +76,17 @@ class User(AbstractUser):
|
||||
if notification_set:
|
||||
mailer = Mailer()
|
||||
mailer.send_mail_shared_data_unrecorded(obj_identifier, self)
|
||||
|
||||
def send_mail_shared_data_deleted(self, obj_identifier):
|
||||
""" Sends a mail to the user in case of shared data has been deleted
|
||||
|
||||
Args:
|
||||
obj_identifier ():
|
||||
|
||||
Returns:
|
||||
|
||||
"""
|
||||
notification_set = self.is_notification_setting_set(UserNotificationEnum.NOTIFY_ON_SHARED_DATA_DELETED)
|
||||
if notification_set:
|
||||
mailer = Mailer()
|
||||
mailer.send_mail_shared_data_deleted(obj_identifier, self)
|
||||
|
||||
@@ -49,9 +49,6 @@ class UserActionLogEntry(models.Model):
|
||||
"-timestamp",
|
||||
)
|
||||
|
||||
def __str__(self):
|
||||
return "{} | {} | {}".format(self.user.username, self.timestamp, self.action)
|
||||
|
||||
@property
|
||||
def action_humanize(self):
|
||||
""" Returns humanized version of enum
|
||||
|
||||
Reference in New Issue
Block a user