mirror of
https://github.com/ae-utbm/sith.git
synced 2025-07-11 04:19:25 +00:00
Add moderation tool to Trombi
This commit is contained in:
@ -106,6 +106,7 @@ class TrombiComment(models.Model):
|
||||
author = models.ForeignKey(TrombiUser, verbose_name=_("author"), related_name='given_comments')
|
||||
target = models.ForeignKey(TrombiUser, verbose_name=_("target"), related_name='received_comments')
|
||||
content = models.TextField(_("content"), default="")
|
||||
is_moderated = models.BooleanField(_("is the comment moderated"), default=False)
|
||||
|
||||
def can_be_viewed_by(self, user):
|
||||
if user.id == self.target.user.id:
|
||||
|
Reference in New Issue
Block a user