# Generated by Django 2.0.2 on 2018-02-26 23:53

from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):

    initial = True

    dependencies = [
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
    ]

    operations = [
        migrations.CreateModel(
            name='Event',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=255)),
                ('code', models.CharField(max_length=10, unique=True)),
                ('timing', models.CharField(max_length=250, null=True)),
                ('additional_data', models.TextField()),
                ('amount', models.CharField(max_length=10, null=True)),
                ('is_team_event', models.BooleanField(default=False)),
                ('venue', models.CharField(max_length=500)),
            ],
        ),
        migrations.CreateModel(
            name='Organizer',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=255)),
                ('code', models.CharField(max_length=10, unique=True)),
            ],
        ),
        migrations.CreateModel(
            name='Profile',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=500)),
                ('email', models.EmailField(max_length=254)),
                ('phone', models.CharField(max_length=15, unique=True)),
                ('college', models.CharField(max_length=500)),
                ('id_code', models.CharField(max_length=250)),
            ],
        ),
        migrations.CreateModel(
            name='Registration',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('additional_data', models.TextField(null=True)),
                ('event', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='EventManagement.Event')),
                ('profile', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='EventManagement.Profile')),
                ('registrar', models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='Volunteer',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('phone', models.CharField(max_length=15)),
            ],
        ),
        migrations.CreateModel(
            name='Workshop',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=255)),
                ('code', models.CharField(max_length=10)),
                ('timing', models.DateTimeField(null=True)),
                ('amount', models.CharField(max_length=10, null=True)),
                ('is_team_event', models.BooleanField(default=False)),
                ('venue', models.CharField(max_length=500)),
                ('organizer', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, to='EventManagement.Organizer')),
            ],
        ),
        migrations.CreateModel(
            name='WorkshopRegistration',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('additional_data', models.TextField()),
                ('profile', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='EventManagement.Profile')),
                ('registrar', models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, to=settings.AUTH_USER_MODEL)),
                ('workshop', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='EventManagement.Workshop')),
            ],
        ),
        migrations.CreateModel(
            name='EventVolunteer',
            fields=[
                ('volunteer_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='EventManagement.Volunteer')),
                ('organizer', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='EventManagement.Organizer')),
            ],
            bases=('EventManagement.volunteer',),
        ),
        migrations.AddField(
            model_name='volunteer',
            name='user',
            field=models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL),
        ),
        migrations.AddField(
            model_name='event',
            name='organizer',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='EventManagement.Organizer'),
        ),
        migrations.CreateModel(
            name='RegistrationDesk',
            fields=[
            ],
            options={
                'proxy': True,
                'indexes': [],
            },
            bases=('EventManagement.volunteer',),
        ),
        migrations.CreateModel(
            name='RituAdmin',
            fields=[
            ],
            options={
                'proxy': True,
                'indexes': [],
            },
            bases=('EventManagement.volunteer',),
        ),
        migrations.AlterUniqueTogether(
            name='workshopregistration',
            unique_together={('profile', 'workshop')},
        ),
        migrations.AlterUniqueTogether(
            name='registration',
            unique_together={('profile', 'event')},
        ),
    ]
