# Generated by Django 2.0 on 2018-11-22 10:26

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='Forum',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('title', models.CharField(max_length=15, verbose_name='标题')),
                ('comment', models.TextField(verbose_name='帖子内容')),
                ('add_time', models.DateTimeField(auto_now_add=True, verbose_name='发帖时间')),
                ('author', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL, verbose_name='发帖作者')),
            ],
            options={
                'verbose_name': '帖子',
                'verbose_name_plural': '帖子',
            },
        ),
        migrations.CreateModel(
            name='ForumType',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('type_name', models.CharField(max_length=20, verbose_name='帖子类型')),
                ('add_time', models.DateTimeField(auto_now_add=True)),
            ],
            options={
                'verbose_name': '帖子类型',
                'verbose_name_plural': '帖子类型',
            },
        ),
        migrations.AddField(
            model_name='forum',
            name='forum_type',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='userforum.ForumType', verbose_name='帖子类型'),
        ),
    ]
