From b96e71091f436a1433c7b8fa4723f8d06b830691 Mon Sep 17 00:00:00 2001 From: Elena ``of Valhalla'' Grandi Date: Sat, 27 Jan 2024 11:34:55 +0100 Subject: Read / Write fields can be empty --- rrd/models.py | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'rrd/models.py') diff --git a/rrd/models.py b/rrd/models.py index 2dc629a..7ccc89a 100644 --- a/rrd/models.py +++ b/rrd/models.py @@ -23,19 +23,23 @@ def _sanitize_path(path): class ModelWithPerms(models.Model): users_read = models.ManyToManyField( amodels.User, - related_name="%(class)s_read" + related_name="%(class)s_read", + blank=True, ) users_write = models.ManyToManyField( amodels.User, - related_name="%(class)s_write" + related_name="%(class)s_write", + blank=True, ) groups_read = models.ManyToManyField( amodels.Group, - related_name="%(class)s_read" + related_name="%(class)s_read", + blank=True, ) groups_write = models.ManyToManyField( amodels.Group, - related_name="%(class)s_write" + related_name="%(class)s_write", + blank=True, ) class Meta: -- cgit v1.2.3