# Generated by Django 3.1.3 on 2021-06-23 20:03

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('schedules', '0001_initial'),
    ]

    operations = [
        migrations.CreateModel(
            name='Modules',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('module_code', models.SlugField(max_length=45)),
                ('name', models.CharField(max_length=256)),
                ('examination', models.BooleanField(default=False)),
                ('language', models.CharField(default='pl', max_length=2)),
                ('schedule', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='modules', to='schedules.schedules')),
            ],
            options={
                'ordering': ['module_code'],
                'unique_together': {('module_code', 'schedule')},
            },
        ),
        migrations.CreateModel(
            name='Classes',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=64)),
                ('classes_hours', models.PositiveIntegerField()),
                ('students_limit_per_group', models.PositiveIntegerField(null=True)),
                ('module', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='form_of_classes', to='modules.modules')),
            ],
            options={
                'ordering': ['module', 'name'],
                'unique_together': {('module', 'name')},
            },
        ),
    ]
