mirror of https://github.com/jumpserver/jumpserver
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
22 lines
486 B
22 lines
486 B
# Generated by Django 4.1.10 on 2023-09-27 06:56
|
|
|
|
from django.db import migrations
|
|
|
|
|
|
def migrate_user_default_email(apps, *args):
|
|
user_cls = apps.get_model('users', 'User')
|
|
user_cls.objects\
|
|
.filter(email='admin@mycomany.com')\
|
|
.update(email='admin@example.com')
|
|
|
|
|
|
class Migration(migrations.Migration):
|
|
|
|
dependencies = [
|
|
('users', '0045_delete_usersession'),
|
|
]
|
|
|
|
operations = [
|
|
migrations.RunPython(migrate_user_default_email),
|
|
]
|