# Generated by Django 3.2.6 on 2021-09-13 04:18

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='Juego',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('nombre', models.CharField(blank=True, max_length=255, null=True)),
                ('descripcion', models.CharField(blank=True, max_length=255, null=True)),
            ],
            options={
                'db_table': 'juego',
            },
        ),
        migrations.CreateModel(
            name='Nivel',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('nombre', models.CharField(blank=True, max_length=255, null=True)),
                ('descripcion', models.CharField(blank=True, max_length=255, null=True)),
                ('puntajeMin', models.IntegerField(verbose_name='puntajeTotal')),
                ('puntajeMax', models.IntegerField(verbose_name='puntajeTotal')),
            ],
            options={
                'db_table': 'nivel',
            },
        ),
        migrations.CreateModel(
            name='Pregunta',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('titulo', models.CharField(blank=True, max_length=255, null=True)),
                ('descripcion', models.CharField(blank=True, max_length=255, null=True)),
                ('comentario', models.CharField(blank=True, max_length=255, null=True)),
                ('juegos', models.ManyToManyField(related_name='juegos', to='aplicacion.Juego')),
            ],
            options={
                'db_table': 'pregunta',
            },
        ),
        migrations.CreateModel(
            name='Usuario',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('nombre', models.CharField(blank=True, max_length=255, null=True)),
                ('apellido', models.CharField(blank=True, max_length=255, null=True)),
                ('nickName', models.CharField(blank=True, max_length=255, null=True)),
                ('isAdmin', models.BooleanField(blank=True, null=True)),
                ('pas', models.CharField(blank=True, max_length=255, null=True)),
                ('horaLogeo', models.DateTimeField(blank=True, null=True)),
                ('puntajeTotal', models.IntegerField(verbose_name='puntajeTotal')),
            ],
            options={
                'db_table': 'usuario',
            },
        ),
        migrations.CreateModel(
            name='Respuesta',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('descripcion', models.CharField(blank=True, max_length=255, null=True)),
                ('isCorrecta', models.BooleanField(default=True)),
                ('preguntas', models.ManyToManyField(related_name='preguntas', to='aplicacion.Pregunta')),
            ],
            options={
                'db_table': 'respuesta',
            },
        ),
        migrations.AddField(
            model_name='juego',
            name='juegan',
            field=models.ManyToManyField(related_name='juegos', to='aplicacion.Usuario'),
        ),
        migrations.AddField(
            model_name='juego',
            name='nivel',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='aplicacion.nivel'),
        ),
        migrations.AddField(
            model_name='juego',
            name='usuario',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='aplicacion.usuario'),
        ),
    ]
