# Generated by Django 2.2 on 2019-05-27 10:03

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),
        ('event', '0010_auto_20190522_1436'),
    ]

    operations = [
        migrations.CreateModel(
            name='Participation',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('amount', models.PositiveIntegerField(default=0, verbose_name='Amount paid')),
            ],
        ),
        migrations.RemoveField(
            model_name='event',
            name='presents',
        ),
        migrations.AddField(
            model_name='event',
            name='presents',
            field=models.ManyToManyField(blank=True, related_name='presents_events', through='event.Participation', to=settings.AUTH_USER_MODEL, verbose_name='Presents'),
        ),
        migrations.AddField(
            model_name='participation',
            name='event',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='event.Event'),
        ),
        migrations.AddField(
            model_name='participation',
            name='user',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL),
        ),
    ]
