# Generated by Django 2.2.1 on 2019-05-09 17:46

from django.db import migrations, models


class Migration(migrations.Migration):

    dependencies = [
        ('apartments_analyzer', '0013_areaofinterest'),
    ]

    operations = [
        migrations.CreateModel(
            name='UserSearchContact',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('created_at', models.DateTimeField(auto_now_add=True)),
                ('updated_at', models.DateTimeField(auto_now=True)),
                ('contact_type', models.CharField(choices=[('E', 'Email'), ('T', 'Telegram messenger')], max_length=1)),
                ('contact_identifier', models.CharField(max_length=120)),
            ],
            options={
                'verbose_name_plural': 'User contacts',
            },
        ),
        migrations.AlterModelOptions(
            name='areaofinterest',
            options={'ordering': ('name',), 'verbose_name_plural': 'Areas of interest'},
        ),
        migrations.CreateModel(
            name='UserSearch',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('created_at', models.DateTimeField(auto_now_add=True)),
                ('updated_at', models.DateTimeField(auto_now=True)),
                ('min_price', models.PositiveIntegerField(default=0)),
                ('max_price', models.PositiveIntegerField()),
                ('apartment_type', models.CharField(choices=[('S', 'На продажу'), ('R', 'В аренду')], max_length=1)),
                ('contacts', models.ManyToManyField(to='apartments_analyzer.UserSearchContact')),
            ],
            options={
                'abstract': False,
            },
        ),
    ]
