# Generated by Django 3.2.16 on 2022-10-20 15:00

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='Brigada',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(help_text='Название Бригады', max_length=50, verbose_name='Бригада')),
                ('head', models.CharField(help_text='ФИО начальника', max_length=100, verbose_name='Начальник')),
                ('amount_people', models.IntegerField()),
                ('qualification', models.IntegerField()),
            ],
        ),
        migrations.CreateModel(
            name='City',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(help_text='Название города', max_length=50, verbose_name='Город')),
            ],
        ),
        migrations.CreateModel(
            name='Object',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(help_text='Название объкта', max_length=50, verbose_name='Объект')),
                ('head', models.CharField(help_text='ФИО начальника', max_length=100, verbose_name='Начальник')),
                ('amount_people', models.IntegerField()),
                ('qualification', models.IntegerField()),
                ('brigada', models.ForeignKey(help_text='Определите бригаду', on_delete=django.db.models.deletion.CASCADE, related_name='brigada', to='objects.brigada', verbose_name='бригада')),
            ],
        ),
        migrations.AddField(
            model_name='brigada',
            name='city',
            field=models.ForeignKey(help_text='Определите город', on_delete=django.db.models.deletion.CASCADE, related_name='city', to='objects.city', verbose_name='Город'),
        ),
    ]
