# -*- coding: utf-8 -*-
# Generated by Django 1.11.6 on 2018-01-12 17:40
from __future__ import unicode_literals

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


class Migration(migrations.Migration):

    dependencies = [
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
        ('chaos', '0003_auto_20180104_1742'),
    ]

    operations = [
        migrations.CreateModel(
            name='Entrepreneur',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('date_created', models.DateTimeField(auto_now_add=True, verbose_name='Date Created')),
                ('date_updated', models.DateTimeField(auto_now=True, verbose_name='Date Updated')),
                ('name', models.CharField(help_text='Entrepreneur Name', max_length=200, verbose_name='Name')),
                ('nickname', models.CharField(max_length=200, null=True, verbose_name='Nickname')),
                ('document_number', models.CharField(max_length=64, null=True, verbose_name='Document Number')),
                ('description', models.TextField(null=True, verbose_name='Description')),
                ('created_by', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL, verbose_name='User')),
            ],
            options={
                'verbose_name': 'Entrepreneur',
                'verbose_name_plural': 'Entrepreneurs',
            },
        ),
        migrations.CreateModel(
            name='EntrepreneurHasEnterprise',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('date_created', models.DateTimeField(auto_now_add=True, verbose_name='Date Created')),
                ('date_updated', models.DateTimeField(auto_now=True, verbose_name='Date Updated')),
                ('enterprise', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='chaos.Enterprise')),
                ('entrepreneur', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='chaos.Entrepreneur')),
            ],
            options={
                'abstract': False,
            },
        ),
        migrations.AddField(
            model_name='entrepreneur',
            name='enterprises',
            field=models.ManyToManyField(related_name='entrepreneurs', through='chaos.EntrepreneurHasEnterprise', to='chaos.Enterprise'),
        ),
    ]
