mirror of
https://github.com/ae-utbm/sith.git
synced 2025-07-09 19:40:19 +00:00
Add groups, allow to ban users from counters and from buying alcohol
This commit is contained in:
@ -127,7 +127,7 @@ class UserProfileForm(forms.ModelForm):
|
||||
fields = ['first_name', 'last_name', 'nick_name', 'email', 'date_of_birth', 'profile_pict', 'avatar_pict',
|
||||
'scrub_pict', 'sex', 'second_email', 'address', 'parent_address', 'phone', 'parent_phone',
|
||||
'tshirt_size', 'role', 'department', 'dpt_option', 'semester', 'quote', 'school', 'promo',
|
||||
'forum_signature', 'is_subscriber_viewable', 'is_banned_alcohol']
|
||||
'forum_signature', 'is_subscriber_viewable']
|
||||
widgets = {
|
||||
'date_of_birth': SelectDate,
|
||||
'profile_pict': forms.ClearableFileInput,
|
||||
|
@ -319,7 +319,7 @@ class UserUpdateProfileView(UserTabsMixin, CanEditMixin, UpdateView):
|
||||
form_class = UserProfileForm
|
||||
current_tab = "edit"
|
||||
edit_once = ['profile_pict', 'date_of_birth', 'first_name', 'last_name']
|
||||
board_only = ['is_banned_alcohol']
|
||||
board_only = []
|
||||
|
||||
def remove_restricted_fields(self, request):
|
||||
"""
|
||||
|
Reference in New Issue
Block a user