# Generated by Django 3.2.4 on 2021-07-03 11:32

import ckeditor.fields
from django.conf import settings
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='Question',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('title', models.CharField(max_length=255)),
                ('question', ckeditor.fields.RichTextField(blank=True, null=True)),
                ('category', models.CharField(default='uncategorised', max_length=255)),
                ('answered', models.BooleanField(default=False)),
                ('created', models.DateTimeField(auto_now_add=True)),
                ('votesscore', models.IntegerField(default='0')),
                ('amountofvotes', models.IntegerField(default='0')),
                ('author', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='Answer',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('answer', ckeditor.fields.RichTextField(blank=True, null=True)),
                ('answered', models.BooleanField(default=True)),
                ('created', models.DateTimeField(auto_now_add=True)),
                ('votesscore', models.IntegerField(default='0')),
                ('amountofvotes', models.IntegerField(default='0')),
                ('author', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
                ('question_id', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, to='members.question')),
            ],
        ),
    ]
