# Generated by Django 3.0.3 on 2020-04-17 13:17

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='Champ',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('nom', models.CharField(max_length=50)),
            ],
        ),
        migrations.CreateModel(
            name='Critere',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('libelle_critere', models.CharField(max_length=50)),
            ],
        ),
        migrations.CreateModel(
            name='PoidsChamps',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('poids_champ', models.IntegerField(blank=True, default=0)),
                ('champ', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='criterion.Champ')),
                ('critere', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='criterion.Critere')),
            ],
        ),
        migrations.AddField(
            model_name='critere',
            name='champs',
            field=models.ManyToManyField(related_name='champs', through='criterion.PoidsChamps', to='criterion.Champ'),
        ),
    ]
