# Generated by Django 2.2.7 on 2019-11-23 10:01

import datetime
import django.contrib.postgres.fields.jsonb
from django.db import migrations, models
import django.db.models.deletion
from django.utils.timezone import utc


class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='Mouvement',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=250)),
                ('description', models.TextField()),
            ],
        ),
        migrations.CreateModel(
            name='Score',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('score', django.contrib.postgres.fields.jsonb.JSONField()),
                ('comment', models.TextField()),
            ],
        ),
        migrations.CreateModel(
            name='Skill',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('mouvements', models.ManyToManyField(to='crossfit.Mouvement')),
            ],
        ),
        migrations.CreateModel(
            name='TypeOfWod',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=100)),
            ],
        ),
        migrations.CreateModel(
            name='Wod',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('type', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='crossfit.TypeOfWod')),
            ],
        ),
        migrations.CreateModel(
            name='Workout',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('date', models.DateField(default=datetime.datetime(2019, 11, 23, 10, 1, 54, 446775, tzinfo=utc))),
                ('comment', models.TextField()),
                ('score', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='crossfit.Score')),
                ('skill', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='crossfit.Skill')),
                ('wod', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='crossfit.Wod')),
            ],
        ),
    ]
