diff --git a/.gitignore b/.gitignore index 5840c7e..f9d5a58 100644 --- a/.gitignore +++ b/.gitignore @@ -115,7 +115,7 @@ dmypy.json .pyre/ .idea/ -migrations/ +#migrations/ logs/ db/ !docker/ldap/data/var/ diff --git a/src/account_helper/migrations/0001_initial.py b/src/account_helper/migrations/0001_initial.py new file mode 100644 index 0000000..a7bd275 --- /dev/null +++ b/src/account_helper/migrations/0001_initial.py @@ -0,0 +1,27 @@ +# Generated by Django 2.1.7 on 2019-05-14 21:38 + +from django.db import migrations, models +import django.db.models.deletion + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ('auth', '0009_alter_user_last_name_max_length'), + ] + + operations = [ + migrations.CreateModel( + name='Realm', + fields=[ + ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('name', models.CharField(max_length=200, unique=True)), + ('email', models.CharField(max_length=200)), + ('ldap_base_dn', models.CharField(max_length=400, unique=True)), + ('admin_group', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.PROTECT, related_name='admin_groups', to='auth.Group')), + ('default_group', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.PROTECT, related_name='default_groups', to='auth.Group')), + ], + ), + ] diff --git a/src/account_helper/migrations/0002_deleteduser.py b/src/account_helper/migrations/0002_deleteduser.py new file mode 100644 index 0000000..27c79c9 --- /dev/null +++ b/src/account_helper/migrations/0002_deleteduser.py @@ -0,0 +1,24 @@ +# Generated by Django 2.1.7 on 2019-05-15 01:07 + +from django.conf import settings +from django.db import migrations, models +import django.db.models.deletion + + +class Migration(migrations.Migration): + + dependencies = [ + migrations.swappable_dependency(settings.AUTH_USER_MODEL), + ('account_helper', '0001_initial'), + ] + + operations = [ + migrations.CreateModel( + name='DeletedUser', + fields=[ + ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('deletion_date', models.DateField(auto_now=True)), + ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), + ], + ), + ] diff --git a/src/account_helper/migrations/__init__.py b/src/account_helper/migrations/__init__.py new file mode 100644 index 0000000..e69de29