Update migrations after previous change
This commit is contained in:
parent
e685a35d19
commit
1b2a9a3e0b
1 changed files with 6 additions and 2 deletions
|
@ -1,4 +1,4 @@
|
||||||
# Generated by Django 3.0.8 on 2020-07-22 02:25
|
# Generated by Django 3.0.8 on 2020-07-22 13:42
|
||||||
|
|
||||||
from django.conf import settings
|
from django.conf import settings
|
||||||
from django.db import migrations, models
|
from django.db import migrations, models
|
||||||
|
@ -27,9 +27,13 @@ class Migration(migrations.Migration):
|
||||||
name='EventRegistration',
|
name='EventRegistration',
|
||||||
fields=[
|
fields=[
|
||||||
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||||
('state', models.CharField(choices=[('I', 'Interested'), ('A', 'Admitted'), ('D', 'Denied')], max_length=1)),
|
('state', models.CharField(choices=[('I', 'Interested'), ('A', 'Admitted')], max_length=1)),
|
||||||
('event', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='events.Event')),
|
('event', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='events.Event')),
|
||||||
('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
|
('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
|
migrations.AddConstraint(
|
||||||
|
model_name='eventregistration',
|
||||||
|
constraint=models.UniqueConstraint(fields=('event', 'user'), name='user can only register once per event'),
|
||||||
|
),
|
||||||
]
|
]
|
||||||
|
|
Loading…
Reference in a new issue