# Generated by Django 2.1.2 on 2019-01-13 11:06

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


class Migration(migrations.Migration):

    initial = True

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

    operations = [
        migrations.CreateModel(
            name='Meme',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('image', models.FileField(blank=True, upload_to='memes')),
                ('sound', models.FileField(blank=True, upload_to='sounds')),
                ('text', models.CharField(max_length=300, null=True)),
                ('account_type', models.IntegerField(default=-1, help_text='Alum = 0 & Student = 1')),
                ('type', models.IntegerField(default=-1, help_text='Fail = 0 & Success = 1')),
            ],
            options={
                'verbose_name_plural': 'Meme',
            },
        ),
        migrations.CreateModel(
            name='Music',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('music', models.FileField(upload_to='musics')),
            ],
        ),
        migrations.CreateModel(
            name='Puzzle',
            fields=[
                ('id', models.IntegerField(primary_key=True, serialize=False)),
                ('info', models.CharField(blank=True, max_length=300, null=True)),
                ('info_link', models.URLField(blank=True, null=True)),
                ('title', models.CharField(blank=True, max_length=100, null=True)),
                ('fact', models.CharField(blank=True, max_length=300, null=True)),
                ('image', models.FileField(null=True, upload_to=puzzle.models.user_directory_path)),
                ('ans', models.CharField(max_length=200)),
                ('visible', models.BooleanField(default=False)),
            ],
            options={
                'verbose_name_plural': 'Puzzle',
            },
        ),
        migrations.CreateModel(
            name='Submission',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('updated_at', models.DateTimeField(auto_now=True)),
                ('tried', models.IntegerField(default=0)),
                ('accepted', models.BooleanField(default=False)),
                ('showed_meme', models.BooleanField(default=False)),
                ('puzzle', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='puzzle.Puzzle')),
                ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='Submitted',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('text', models.CharField(max_length=100)),
                ('puzzle', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='puzzle.Puzzle')),
                ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='Tag',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=100)),
            ],
            options={
                'verbose_name_plural': 'Tag',
            },
        ),
        migrations.AddField(
            model_name='puzzle',
            name='tag',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='tag', to='puzzle.Tag'),
        ),
    ]
