# -*- coding: utf-8 -*-
# Generated by Django 1.11.7 on 2017-12-01 18:09
from __future__ import unicode_literals

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='Group',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(default=b'-', max_length=100)),
            ],
            options={
                'db_table': 'group',
            },
        ),
        migrations.CreateModel(
            name='Injury',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(default=b'-', max_length=100)),
            ],
            options={
                'db_table': 'injury',
            },
        ),
        migrations.CreateModel(
            name='InjuryPlayer',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('injury_id', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='rules.Injury')),
            ],
            options={
                'db_table': 'injury_player',
            },
        ),
        migrations.CreateModel(
            name='Player',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(blank=True, max_length=20)),
                ('position', models.CharField(blank=True, max_length=20)),
                ('cost', models.IntegerField(default=0)),
            ],
            options={
                'db_table': 'player',
            },
        ),
        migrations.CreateModel(
            name='PlayerSkill',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('origin', models.BooleanField(default=True)),
                ('cost', models.IntegerField(default=0)),
                ('player_id', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='rules.Player')),
            ],
            options={
                'db_table': 'player_skill',
            },
        ),
        migrations.CreateModel(
            name='Skill',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(default=b'-', max_length=100)),
                ('description', models.CharField(default=b'-', max_length=500)),
                ('group_id', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='rules.Group')),
            ],
            options={
                'db_table': 'skill',
            },
        ),
        migrations.CreateModel(
            name='Stat',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(default=b'-', max_length=50)),
                ('code', models.CharField(default=b'-', max_length=2)),
            ],
            options={
                'db_table': 'stat',
            },
        ),
        migrations.CreateModel(
            name='StatPlayer',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('value', models.IntegerField(default=0)),
                ('cost', models.IntegerField(default=True)),
                ('origin', models.BooleanField(default=True)),
                ('player_id', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='rules.Player')),
                ('stat_id', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='rules.Stat')),
            ],
            options={
                'db_table': 'group',
            },
        ),
        migrations.CreateModel(
            name='Team',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=50)),
                ('race', models.CharField(max_length=80)),
                ('description', models.CharField(blank=True, max_length=500)),
            ],
            options={
                'db_table': 'team',
            },
        ),
        migrations.AddField(
            model_name='playerskill',
            name='skill_id',
            field=models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='rules.Skill'),
        ),
        migrations.AddField(
            model_name='player',
            name='skill_id',
            field=models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='rules.Skill'),
        ),
        migrations.AddField(
            model_name='player',
            name='stat_id',
            field=models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='rules.Stat'),
        ),
        migrations.AddField(
            model_name='player',
            name='team_id',
            field=models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='rules.Team'),
        ),
        migrations.AddField(
            model_name='injuryplayer',
            name='player_id',
            field=models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='rules.Player'),
        ),
        migrations.AddField(
            model_name='injury',
            name='stat_id',
            field=models.ForeignKey(blank=True, on_delete=django.db.models.deletion.PROTECT, to='rules.Stat'),
        ),
    ]
