# Generated by Django 2.0.6 on 2020-09-16 14:51

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='Student',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('is_delete', models.BooleanField(default=False)),
                ('create_time', models.DateTimeField(auto_now_add=True)),
                ('status', models.BooleanField(default=True)),
                ('username', models.CharField(max_length=40)),
                ('age', models.SmallIntegerField()),
                ('gender', models.SmallIntegerField(choices=[(0, 'male'), (1, 'female'), (2, 'other')], default=0)),
                ('phone', models.CharField(max_length=40)),
                ('email', models.CharField(max_length=40)),
            ],
            options={
                'verbose_name': '学生表',
                'verbose_name_plural': '学生表',
                'db_table': 'db_student',
            },
        ),
        migrations.CreateModel(
            name='Team',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('is_delete', models.BooleanField(default=False)),
                ('create_time', models.DateTimeField(auto_now_add=True)),
                ('status', models.BooleanField(default=True)),
                ('classname', models.CharField(max_length=40)),
                ('subject', models.CharField(max_length=40)),
            ],
            options={
                'verbose_name': '班级',
                'verbose_name_plural': '班级',
                'db_table': 'db_team',
            },
        ),
        migrations.AddField(
            model_name='student',
            name='team_id',
            field=models.ForeignKey(db_constraint=False, on_delete=django.db.models.deletion.CASCADE, related_name='students', to='studentapp.Team'),
        ),
    ]
