# -*- coding: utf-8 -*-
# Generated by Django 1.11.6 on 2017-10-31 19:10
from __future__ import unicode_literals

import datetime
from django.conf import settings
import django.core.validators
from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):

    initial = True

    dependencies = [
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
    ]

    operations = [
        migrations.CreateModel(
            name='Comment',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('date_created', models.DateTimeField(default=datetime.datetime.now)),
            ],
        ),
        migrations.CreateModel(
            name='Suggestion',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('description', models.TextField(blank=True)),
                ('date_created', models.DateTimeField(default=datetime.datetime.now)),
            ],
        ),
        migrations.CreateModel(
            name='SuggestionBox',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('description', models.TextField(blank=True)),
                ('date_created', models.DateTimeField(default=datetime.datetime.now)),
                ('owner', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='Vote',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('opinion', models.IntegerField(default=0, validators=[django.core.validators.MinValueValidator(-1), django.core.validators.MaxValueValidator(1)])),
                ('date_created', models.DateTimeField(default=datetime.datetime.now)),
                ('suggestion', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='polls.Suggestion')),
            ],
        ),
        migrations.AddField(
            model_name='suggestion',
            name='suggestion_box',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='polls.SuggestionBox'),
        ),
        migrations.AddField(
            model_name='comment',
            name='suggestion',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='polls.Suggestion'),
        ),
    ]
