ask for user confirmation if its role was moved out of presidency

This commit is contained in:
imperosol
2026-04-17 22:49:45 +02:00
parent b02ec4e812
commit eac730e7a9
5 changed files with 256 additions and 14 deletions
+1 -1
View File
@@ -240,7 +240,7 @@ class Club(models.Model):
def can_roles_be_edited_by(self, user: User) -> bool:
"""Return True if the given user can edit the roles of this club"""
return (
return user.is_authenticated and (
user.has_perm("club.change_clubrole")
or self.members.ongoing().filter(user=user, role__is_presidency=True).exists()
)