# Generated by Django 3.1.2 on 2020-10-26 17:58

from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import uuid


class Migration(migrations.Migration):

    initial = True

    dependencies = [
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
        ('road', '0001_initial'),
    ]

    operations = [
        migrations.CreateModel(
            name='Dispatcher',
            fields=[
                ('id', models.UUIDField(default=uuid.uuid4, primary_key=True, serialize=False, verbose_name='id')),
                ('created_at', models.DateTimeField(auto_now_add=True)),
                ('first_name', models.CharField(max_length=75, verbose_name='имя')),
                ('surname', models.CharField(max_length=75, verbose_name='фамилия')),
                ('patronymic', models.CharField(max_length=75, verbose_name='отчество')),
                ('phone', models.CharField(max_length=11, unique=True, verbose_name='телефон')),
                ('road', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='road.road', verbose_name='трасса')),
                ('section', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='road.section', verbose_name='секция')),
                ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL, verbose_name='user')),
            ],
            options={
                'verbose_name': 'диспетчер',
                'verbose_name_plural': 'диспетчеры',
            },
        ),
        migrations.CreateModel(
            name='Commissioner',
            fields=[
                ('id', models.UUIDField(default=uuid.uuid4, primary_key=True, serialize=False, verbose_name='id')),
                ('created_at', models.DateTimeField(auto_now_add=True)),
                ('first_name', models.CharField(max_length=75, verbose_name='имя')),
                ('surname', models.CharField(max_length=75, verbose_name='фамилия')),
                ('patronymic', models.CharField(max_length=75, verbose_name='отчество')),
                ('phone', models.CharField(max_length=11, unique=True, verbose_name='телефон')),
                ('point', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='road.point', verbose_name='точка')),
                ('road', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='road.road', verbose_name='трасса')),
                ('section', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='road.section', verbose_name='секция')),
                ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL, verbose_name='user')),
            ],
            options={
                'verbose_name': 'дорожный комиссар',
                'verbose_name_plural': 'дорожные комиссары',
            },
        ),
    ]
