change Club.unix_name to Club.slug_name and remove it from forms

This commit is contained in:
imperosol
2025-03-01 11:47:40 +01:00
parent f764ce1585
commit 805b146f17
21 changed files with 377 additions and 395 deletions

View File

@ -421,13 +421,9 @@ class User(AbstractUser):
def is_launderette_manager(self):
from club.models import Club
return (
Club.objects.filter(
unix_name=settings.SITH_LAUNDERETTE_MANAGER["unix_name"]
)
.first()
.get_membership_for(self)
)
return Club.objects.get(
id=settings.SITH_LAUNDERETTE_CLUB_ID
).get_membership_for(self)
@cached_property
def is_banned_alcohol(self) -> bool: