# Generated by Django 3.0.4 on 2020-05-11 18:53

from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone


class Migration(migrations.Migration):

    dependencies = [
        ('contenttypes', '0002_remove_content_type_name'),
        ('trilby_api', '0008_auto_20200424_1345'),
    ]

    operations = [
        migrations.CreateModel(
            name='RemotePerson',
            fields=[
                ('person_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='trilby_api.Person')),
                ('url', models.URLField(blank=True, max_length=255, null=True, unique=True)),
                ('username', models.CharField(blank=True, max_length=255, null=True)),
                ('inbox', models.URLField(blank=True, default=None, max_length=255, null=True)),
                ('icon', models.URLField(blank=True, default=None, max_length=255, null=True)),
                ('header', models.URLField(blank=True, default=None, max_length=255, null=True)),
                ('key_name', models.CharField(blank=True, default='', max_length=255, null=True)),
            ],
            options={
                'abstract': False,
                'base_manager_name': 'objects',
            },
            bases=('trilby_api.person',),
        ),
        migrations.AlterModelOptions(
            name='person',
            options={'base_manager_name': 'objects'},
        ),
        migrations.RemoveField(
            model_name='person',
            name='created_at',
        ),
        migrations.RemoveField(
            model_name='person',
            name='header_image',
        ),
        migrations.RemoveField(
            model_name='person',
            name='icon_image',
        ),
        migrations.RemoveField(
            model_name='person',
            name='local_user',
        ),
        migrations.RemoveField(
            model_name='person',
            name='privateKey',
        ),
        migrations.RemoveField(
            model_name='person',
            name='remote_url',
        ),
        migrations.RemoveField(
            model_name='person',
            name='remote_username',
        ),
        migrations.AddField(
            model_name='person',
            name='polymorphic_ctype',
            field=models.ForeignKey(editable=False, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='polymorphic_trilby_api.person_set+', to='contenttypes.ContentType'),
        ),
        migrations.CreateModel(
            name='LocalPerson',
            fields=[
                ('person_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='trilby_api.Person')),
                ('created_at', models.DateTimeField(default=django.utils.timezone.now)),
                ('privateKey', models.TextField(blank=True, null=True, verbose_name='private key')),
                ('icon_image', models.ImageField(blank=True, help_text='A small square image used to identify you.', null=True, upload_to='', verbose_name='icon')),
                ('header_image', models.ImageField(blank=True, help_text="A large image, wider than it's tall, which appears at the top of your profile page.", null=True, upload_to='', verbose_name='header image')),
                ('local_user', models.OneToOneField(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
            options={
                'abstract': False,
                'base_manager_name': 'objects',
            },
            bases=('trilby_api.person',),
        ),
    ]
