# -*- coding: utf-8 -*-
from __future__ import unicode_literals

from django.db import models, migrations
import django_extensions.db.fields
import mtp.apps.common.utils
from django.conf import settings


class Migration(migrations.Migration):

    dependencies = [
        ('sync', '0001_initial'),
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
        ('trainings', '0003_auto_20150408_1620'),
    ]

    operations = [
        migrations.CreateModel(
            name='Brainstormer',
            fields=[
                ('is_deleted', models.BooleanField(default=False)),
                ('update_locally', models.BooleanField(default=False)),
                ('id', django_extensions.db.fields.UUIDField(blank=True, editable=False, serialize=False, primary_key=True)),
                ('first_update', models.ForeignKey(null=True, related_name='brainstormer_by_first', blank=True, to='sync.Update')),
                ('last_update', models.ForeignKey(null=True, related_name='brainstormer_by_last', blank=True, to='sync.Update')),
            ],
            options={
                'abstract': False,
            },
        ),
        migrations.CreateModel(
            name='BrainstormerActivity',
            fields=[
                ('is_deleted', models.BooleanField(default=False)),
                ('update_locally', models.BooleanField(default=False)),
                ('id', django_extensions.db.fields.UUIDField(blank=True, editable=False, serialize=False, primary_key=True)),
                ('title', models.CharField(max_length=100)),
                ('preview', models.ImageField(verbose_name='PreviewTheme', upload_to=mtp.apps.common.utils.upload_to_generator)),
                ('hash_preview', models.CharField(max_length=36, blank=True)),
                ('image', models.ImageField(blank=True, verbose_name='ImageTheme', upload_to=mtp.apps.common.utils.upload_to_generator)),
                ('hash_image', models.CharField(max_length=36, blank=True)),
                ('first_update', models.ForeignKey(null=True, related_name='brainstormeractivity_by_first', blank=True, to='sync.Update')),
                ('last_update', models.ForeignKey(null=True, related_name='brainstormeractivity_by_last', blank=True, to='sync.Update')),
                ('trainings', models.ManyToManyField(null=True, blank=True, to='trainings.Training')),
            ],
            options={
                'abstract': False,
            },
        ),
        migrations.CreateModel(
            name='BrainstormerProposition',
            fields=[
                ('is_deleted', models.BooleanField(default=False)),
                ('update_locally', models.BooleanField(default=False)),
                ('id', django_extensions.db.fields.UUIDField(blank=True, editable=False, serialize=False, primary_key=True)),
                ('text', models.CharField(max_length=100)),
                ('first_update', models.ForeignKey(null=True, related_name='brainstormerproposition_by_first', blank=True, to='sync.Update')),
            ],
            options={
                'abstract': False,
            },
        ),
        migrations.CreateModel(
            name='BrainstormerPropositionGroup',
            fields=[
                ('is_deleted', models.BooleanField(default=False)),
                ('update_locally', models.BooleanField(default=False)),
                ('id', django_extensions.db.fields.UUIDField(blank=True, editable=False, serialize=False, primary_key=True)),
                ('name', models.CharField(max_length=50, blank=True)),
                ('color', models.CharField(max_length=30, blank=True)),
                ('x', models.DecimalField(decimal_places=2, blank=True, default=0, max_digits=6)),
                ('y', models.DecimalField(decimal_places=2, blank=True, default=0, max_digits=6)),
                ('brainstormer', models.ForeignKey(related_name='groups', to='brainstormers.Brainstormer')),
                ('first_update', models.ForeignKey(null=True, related_name='brainstormerpropositiongroup_by_first', blank=True, to='sync.Update')),
                ('last_update', models.ForeignKey(null=True, related_name='brainstormerpropositiongroup_by_last', blank=True, to='sync.Update')),
            ],
            options={
                'abstract': False,
            },
        ),
        migrations.CreateModel(
            name='BrainstormerTemplate',
            fields=[
                ('is_deleted', models.BooleanField(default=False)),
                ('update_locally', models.BooleanField(default=False)),
                ('id', django_extensions.db.fields.UUIDField(blank=True, editable=False, serialize=False, primary_key=True)),
                ('title', models.CharField(max_length=100)),
                ('activity', models.ForeignKey(null=True, to='brainstormers.BrainstormerActivity', blank=True)),
                ('first_update', models.ForeignKey(null=True, related_name='brainstormertemplate_by_first', blank=True, to='sync.Update')),
                ('last_update', models.ForeignKey(null=True, related_name='brainstormertemplate_by_last', blank=True, to='sync.Update')),
                ('training', models.ForeignKey(null=True, to='trainings.Training', blank=True)),
            ],
            options={
                'abstract': False,
            },
        ),
        migrations.AddField(
            model_name='brainstormerproposition',
            name='group',
            field=models.ForeignKey(related_name='propositions', to='brainstormers.BrainstormerPropositionGroup'),
        ),
        migrations.AddField(
            model_name='brainstormerproposition',
            name='last_update',
            field=models.ForeignKey(null=True, related_name='brainstormerproposition_by_last', blank=True, to='sync.Update'),
        ),
        migrations.AddField(
            model_name='brainstormerproposition',
            name='user',
            field=models.ForeignKey(to=settings.AUTH_USER_MODEL),
        ),
        migrations.AddField(
            model_name='brainstormer',
            name='template',
            field=models.ForeignKey(to='brainstormers.BrainstormerTemplate'),
        ),
        migrations.AddField(
            model_name='brainstormer',
            name='training_session',
            field=models.ForeignKey(to='trainings.TrainingSession'),
        ),
    ]
