# -*- coding: utf-8 -*-
# Generated by Django 1.11.6 on 2019-03-08 22:16
from __future__ import unicode_literals

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


class Migration(migrations.Migration):

    dependencies = [
        ('baseball', '0007_team_franchise_code'),
    ]

    operations = [
        migrations.CreateModel(
            name='Player',
            fields=[
                ('birth_country', models.CharField(blank=True, max_length=100, null=True)),
                ('weight', models.IntegerField()),
                ('birth_state', models.CharField(max_length=100)),
                ('height_inches', models.IntegerField()),
                ('bats', models.CharField(max_length=1)),
                ('name_first', models.CharField(max_length=100)),
                ('birth_city', models.CharField(max_length=100)),
                ('height_feet', models.IntegerField()),
                ('pro_debut_date', models.DateField(blank=True, null=True)),
                ('birth_date', models.DateField()),
                ('throws', models.CharField(max_length=1)),
                ('position', models.IntegerField()),
                ('name_use', models.CharField(max_length=100)),
                ('player_id', models.IntegerField(editable=False, primary_key=True, serialize=False)),
                ('name_last', models.CharField(max_length=100)),
                ('service_years', models.IntegerField()),
            ],
        ),
        migrations.CreateModel(
            name='PlayerStats',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('year', models.IntegerField()),
                ('pitching_stats', jsonfield.fields.JSONField()),
                ('hitting_stats', jsonfield.fields.JSONField()),
                ('fielding_stats', jsonfield.fields.JSONField()),
                ('player', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='baseball.Player')),
            ],
        ),
        migrations.CreateModel(
            name='Team40ManRoster',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('players', models.ManyToManyField(to='baseball.Player')),
            ],
        ),
        migrations.AlterField(
            model_name='division',
            name='league',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='divisions', to='baseball.League'),
        ),
        migrations.AlterField(
            model_name='team',
            name='division',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='teams', to='baseball.Division'),
        ),
        migrations.AddField(
            model_name='team40manroster',
            name='team',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='rosters', to='baseball.Team'),
        ),
    ]
