# Generated by Django 2.0 on 2019-06-25 16:03

import ckeditor.fields
from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='Club',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=30, unique=True, verbose_name='社团名')),
                ('create_time', models.DateField(verbose_name='创建时间')),
                ('brief', models.TextField(default='', max_length=100, verbose_name='社团简介')),
                ('description', ckeditor.fields.RichTextField(verbose_name='社团描述')),
                ('icon', models.ImageField(default='default.jpeg', upload_to='images/clubs/icons/')),
                ('type', models.CharField(choices=[(1, '学术'), (2, '学艺'), (3, '体育'), (4, '服务'), (5, '康乐'), (6, '综合'), (7, '资质'), (8, '其他')], default=1, max_length=10, verbose_name='社团类型')),
                ('level', models.CharField(choices=[(1, '校级'), (2, '院级')], default=1, max_length=10)),
            ],
            options={
                'verbose_name': '社团',
                'verbose_name_plural': '社团',
            },
        ),
        migrations.CreateModel(
            name='Institute',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=20, unique=True, verbose_name='学院名称')),
            ],
            options={
                'verbose_name': '学院',
                'verbose_name_plural': '学院',
            },
        ),
        migrations.CreateModel(
            name='Notification',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('title', models.CharField(max_length=30, verbose_name='推送标题')),
                ('image', models.ImageField(upload_to='clubs/notifications/', verbose_name='推送图片')),
                ('content', ckeditor.fields.RichTextField(verbose_name='推送内容')),
                ('publish_date', models.DateField(verbose_name='发布时间')),
            ],
            options={
                'verbose_name': '社团推送',
                'verbose_name_plural': '社团推送',
            },
        ),
        migrations.AddField(
            model_name='club',
            name='notifications',
            field=models.ForeignKey(default=None, on_delete=django.db.models.deletion.CASCADE, to='clubs.Notification', verbose_name='推送'),
        ),
    ]
