# Generated by Django 2.0.7 on 2018-09-12 18:27

import DjangoUeditor.models
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone


class Migration(migrations.Migration):

    initial = True

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

    operations = [
        migrations.CreateModel(
            name='PictureTextColumn',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=256, verbose_name='图文栏目名称')),
                ('introduce', models.TextField(default='', verbose_name='栏目简介')),
            ],
            options={
                'ordering': ['pk'],
                'verbose_name_plural': '图文栏目',
                'verbose_name': '图文栏目',
            },
        ),
        migrations.CreateModel(
            name='PictureTextPaper',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=256, verbose_name='图文标题')),
                ('introduce', models.TextField(default='', verbose_name='图文简介')),
                ('image', models.ImageField(upload_to='image', verbose_name='封面')),
                ('register_date', models.DateTimeField(default=django.utils.timezone.now, editable=False, verbose_name='发表时间')),
                ('content', DjangoUeditor.models.UEditorField(blank=True, default='', verbose_name='图文内容')),
                ('views_count', models.IntegerField(default=0, editable=False, verbose_name='浏览次数')),
                ('column', models.ForeignKey(blank=True, on_delete=django.db.models.deletion.CASCADE, to='PictureText.PictureTextColumn', verbose_name='所属栏目')),
            ],
            options={
                'verbose_name_plural': '图文文章',
                'verbose_name': '图文文章',
            },
        ),
        migrations.CreateModel(
            name='PictureTextPaperComment',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('message', models.CharField(max_length=256, verbose_name='图文评论')),
                ('register_date', models.DateTimeField(auto_now_add=True, verbose_name='评论时间')),
                ('ascription', models.ForeignKey(blank=True, on_delete=django.db.models.deletion.CASCADE, to='PictureText.PictureTextPaper', verbose_name='所属图文')),
                ('author', models.ForeignKey(blank=True, on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL, verbose_name='作者')),
            ],
            options={
                'ordering': ['-register_date'],
                'verbose_name_plural': '图文评论',
                'verbose_name': '图文评论',
            },
        ),
    ]
