# Generated by Django 2.0.6 on 2018-06-24 20:59

from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import mptt.fields


class Migration(migrations.Migration):

    initial = True

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

    operations = [
        migrations.AddField(
            model_name='telephoneitem',
            name='author',
            field=models.ForeignKey(blank=True, editable=False, null=True, on_delete=django.db.models.deletion.PROTECT, to=settings.AUTH_USER_MODEL),
        ),
        migrations.AddField(
            model_name='telephoneitem',
            name='client_branch',
            field=models.ForeignKey(blank=True, db_column='client_branch', null=True, on_delete=django.db.models.deletion.PROTECT, to='client.ClientBranch'),
        ),
        migrations.AddField(
            model_name='socialnetworkitem',
            name='author',
            field=models.ForeignKey(blank=True, editable=False, null=True, on_delete=django.db.models.deletion.PROTECT, to=settings.AUTH_USER_MODEL),
        ),
        migrations.AddField(
            model_name='socialnetworkitem',
            name='client_branch',
            field=models.ForeignKey(blank=True, db_column='client_branch', null=True, on_delete=django.db.models.deletion.PROTECT, to='client.ClientBranch'),
        ),
        migrations.AddField(
            model_name='isicposition',
            name='author',
            field=models.ForeignKey(editable=False, help_text='antares.apps.client.models.isic_position.author_help', on_delete=django.db.models.deletion.PROTECT, to=settings.AUTH_USER_MODEL, verbose_name='antares.apps.client.models.isic_position.author'),
        ),
        migrations.AddField(
            model_name='isicposition',
            name='parent',
            field=mptt.fields.TreeForeignKey(blank=True, help_text='antares.apps.client.models.isic_position.parent_help', null=True, on_delete=django.db.models.deletion.CASCADE, related_name='children', to='client.IsicPosition', verbose_name='antares.apps.client.models.isic_position.parent'),
        ),
        migrations.AddField(
            model_name='identificationitem',
            name='author',
            field=models.ForeignKey(editable=False, on_delete=django.db.models.deletion.PROTECT, to=settings.AUTH_USER_MODEL),
        ),
        migrations.AddField(
            model_name='identificationitem',
            name='client',
            field=models.ForeignKey(db_column='client', on_delete=django.db.models.deletion.PROTECT, to='client.Client'),
        ),
        migrations.AddField(
            model_name='identificationitem',
            name='type',
            field=models.ForeignKey(db_column='type', on_delete=django.db.models.deletion.PROTECT, to='client.ClientIdentificationType'),
        ),
        migrations.AddField(
            model_name='emailitem',
            name='author',
            field=models.ForeignKey(blank=True, editable=False, null=True, on_delete=django.db.models.deletion.PROTECT, to=settings.AUTH_USER_MODEL),
        ),
        migrations.AddField(
            model_name='emailitem',
            name='client_branch',
            field=models.ForeignKey(blank=True, db_column='client_branch', null=True, on_delete=django.db.models.deletion.PROTECT, to='client.ClientBranch'),
        ),
        migrations.AddField(
            model_name='clientuserrelationpermission',
            name='author',
            field=models.ForeignKey(blank=True, editable=False, null=True, on_delete=django.db.models.deletion.PROTECT, related_name='client_user_relation_permission_author_set', to=settings.AUTH_USER_MODEL),
        ),
        migrations.AddField(
            model_name='clientuserrelationpermission',
            name='client_relation',
            field=models.ForeignKey(db_column='client_user_relation', on_delete=django.db.models.deletion.PROTECT, related_name='permission_set', to='client.ClientUserRelation'),
        ),
        migrations.AddField(
            model_name='clientuserrelation',
            name='author',
            field=models.ForeignKey(blank=True, editable=False, null=True, on_delete=django.db.models.deletion.PROTECT, related_name='client_user_relation_author_set', to=settings.AUTH_USER_MODEL),
        ),
        migrations.AddField(
            model_name='clientuserrelation',
            name='child_client',
            field=models.ForeignKey(db_column='child_client', on_delete=django.db.models.deletion.PROTECT, related_name='child_client_relation_set', to='client.Client'),
        ),
        migrations.AddField(
            model_name='clientuserrelation',
            name='parent_user',
            field=models.ForeignKey(db_column='parent_user', null=True, on_delete=django.db.models.deletion.PROTECT, related_name='client_user_relation_set', to=settings.AUTH_USER_MODEL),
        ),
        migrations.AddField(
            model_name='clienttype',
            name='author',
            field=models.ForeignKey(blank=True, editable=False, null=True, on_delete=django.db.models.deletion.PROTECT, to=settings.AUTH_USER_MODEL),
        ),
        migrations.AddField(
            model_name='clientidentificationtype',
            name='author',
            field=models.ForeignKey(editable=False, on_delete=django.db.models.deletion.PROTECT, to=settings.AUTH_USER_MODEL),
        ),
        migrations.AddField(
            model_name='clientbusinessclassification',
            name='author',
            field=models.ForeignKey(blank=True, editable=False, null=True, on_delete=django.db.models.deletion.PROTECT, to=settings.AUTH_USER_MODEL),
        ),
        migrations.AddField(
            model_name='clientbusinessclassification',
            name='business_classification',
            field=mptt.fields.TreeForeignKey(db_column='isic_position', on_delete=django.db.models.deletion.PROTECT, to='client.IsicPosition'),
        ),
        migrations.AddField(
            model_name='clientbusinessclassification',
            name='client_branch',
            field=models.ForeignKey(db_column='client_branch', on_delete=django.db.models.deletion.PROTECT, to='client.ClientBranch'),
        ),
        migrations.AddField(
            model_name='clientbranch',
            name='author',
            field=models.ForeignKey(blank=True, editable=False, null=True, on_delete=django.db.models.deletion.PROTECT, to=settings.AUTH_USER_MODEL),
        ),
        migrations.AddField(
            model_name='clientbranch',
            name='client',
            field=models.ForeignKey(db_column='client', on_delete=django.db.models.deletion.PROTECT, related_name='branch_set', to='client.Client'),
        ),
        migrations.AddField(
            model_name='clientattribute',
            name='attribute_definition',
            field=models.ForeignKey(blank=True, db_column='attribute_definition', null=True, on_delete=django.db.models.deletion.PROTECT, to='client.AttributeDefinition'),
        ),
        migrations.AddField(
            model_name='clientattribute',
            name='author',
            field=models.ForeignKey(blank=True, editable=False, null=True, on_delete=django.db.models.deletion.PROTECT, to=settings.AUTH_USER_MODEL),
        ),
        migrations.AddField(
            model_name='clientattribute',
            name='client',
            field=models.ForeignKey(blank=True, db_column='client', null=True, on_delete=django.db.models.deletion.PROTECT, to='client.Client'),
        ),
        migrations.AddField(
            model_name='client',
            name='author',
            field=models.ForeignKey(blank=True, editable=False, null=True, on_delete=django.db.models.deletion.PROTECT, related_name='client_author_set', to=settings.AUTH_USER_MODEL),
        ),
        migrations.AddField(
            model_name='client',
            name='client_type',
            field=models.ForeignKey(db_column='client_type', on_delete=django.db.models.deletion.PROTECT, to='client.ClientType'),
        ),
        migrations.AddField(
            model_name='client',
            name='user',
            field=models.OneToOneField(blank=True, null=True, on_delete=django.db.models.deletion.PROTECT, related_name='client', to=settings.AUTH_USER_MODEL),
        ),
        migrations.AddField(
            model_name='attributedefinition',
            name='author',
            field=models.ForeignKey(blank=True, editable=False, null=True, on_delete=django.db.models.deletion.PROTECT, to=settings.AUTH_USER_MODEL),
        ),
        migrations.AddField(
            model_name='addressitem',
            name='author',
            field=models.ForeignKey(blank=True, editable=False, null=True, on_delete=django.db.models.deletion.PROTECT, to=settings.AUTH_USER_MODEL),
        ),
        migrations.AddField(
            model_name='addressitem',
            name='client_branch',
            field=models.ForeignKey(blank=True, db_column='client_branch', null=True, on_delete=django.db.models.deletion.PROTECT, to='client.ClientBranch'),
        ),
        migrations.AlterUniqueTogether(
            name='isicposition',
            unique_together={('isic_code', 'language')},
        ),
        migrations.AlterUniqueTogether(
            name='clientbranch',
            unique_together={('client', 'branch_number')},
        ),
    ]
