mirror of
https://github.com/retspen/webvirtcloud
synced 2025-07-31 12:41:08 +00:00
lint with black python. convert f style strings to old one. some small fixes
This commit is contained in:
parent
c20c353a40
commit
508e3609be
54 changed files with 2123 additions and 1824 deletions
|
@ -8,7 +8,7 @@ def apply_change_password(sender, **kwargs):
|
|||
Depending on settings SHOW_PROFILE_EDIT_PASSWORD
|
||||
'''
|
||||
from django.conf import settings
|
||||
from django.contrib.auth.models import User, Permission
|
||||
from django.contrib.auth.models import Permission, User
|
||||
if hasattr(settings, 'SHOW_PROFILE_EDIT_PASSWORD'):
|
||||
print('\033[1m! \033[92mSHOW_PROFILE_EDIT_PASSWORD is found inside settings.py\033[0m')
|
||||
print('\033[1m* \033[92mApplying permission can_change_password for all users\033[0m')
|
||||
|
@ -29,8 +29,8 @@ def create_admin(sender, **kwargs):
|
|||
'''
|
||||
Create initial admin user
|
||||
'''
|
||||
from django.contrib.auth.models import User
|
||||
from accounts.models import UserAttributes
|
||||
from django.contrib.auth.models import User
|
||||
|
||||
plan = kwargs.get('plan', [])
|
||||
for migration, rolled_back in plan:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue