# -*- coding: utf-8 -*-
# Generated by Django 1.9.8 on 2016-09-07 03:40
from __future__ import unicode_literals

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='Badge',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(default='none', max_length=50)),
            ],
        ),
        migrations.CreateModel(
            name='Chatroom',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('content', models.CharField(max_length=50)),
                ('date_time', models.DateTimeField()),
            ],
        ),
        migrations.CreateModel(
            name='file_info',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('local_name', models.CharField(max_length=50)),
                ('upload_name', models.CharField(max_length=50)),
            ],
        ),
        migrations.CreateModel(
            name='Interest',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(default='Medical Health', max_length=50)),
            ],
        ),
        migrations.CreateModel(
            name='Student',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('realname', models.CharField(default='', max_length=50)),
                ('nickname', models.CharField(max_length=50)),
                ('department', models.CharField(max_length=50)),
                ('motto', models.CharField(blank=True, max_length=20)),
                ('badge', models.ManyToManyField(default=1, to='profiles.Badge')),
                ('follow', models.ManyToManyField(blank=True, to='profiles.Student')),
                ('interest', models.ForeignKey(default=1, on_delete=django.db.models.deletion.CASCADE, to='profiles.Interest')),
                ('name', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL, unique=True)),
            ],
            options={
                'permissions': (('can_edit_base_profile', 'Can edit base profile'), ('can_view_base_profile', 'Can view base profile')),
            },
        ),
        migrations.CreateModel(
            name='Talent',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(default='Math', max_length=50)),
            ],
        ),
        migrations.CreateModel(
            name='Team',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(default='none', max_length=50)),
                ('need', models.IntegerField(default=0, max_length=5)),
                ('interest', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='profiles.Interest')),
            ],
        ),
        migrations.CreateModel(
            name='up_file',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('upload_datetime', models.DateTimeField()),
                ('student', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, to='profiles.Student')),
            ],
        ),
        migrations.AddField(
            model_name='student',
            name='talent',
            field=models.ForeignKey(default=1, on_delete=django.db.models.deletion.CASCADE, to='profiles.Talent'),
        ),
        migrations.AddField(
            model_name='student',
            name='team',
            field=models.ForeignKey(default=1, on_delete=django.db.models.deletion.CASCADE, to='profiles.Team'),
        ),
        migrations.AddField(
            model_name='file_info',
            name='File',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, to='profiles.up_file'),
        ),
        migrations.AddField(
            model_name='chatroom',
            name='student1',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='student1', to='profiles.Student'),
        ),
        migrations.AddField(
            model_name='chatroom',
            name='student2',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='student2', to='profiles.Student'),
        ),
    ]
