# -*- coding: utf-8 -*-
# Generated by Django 1.11 on 2017-07-10 14:40
from __future__ import unicode_literals

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


def create_admin(apps, schema_editor):
    from django.contrib.auth.models import User
    User.objects.create_superuser('admin', 'admin@example.com', 'admin')


class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='Activity',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=255)),
            ],
        ),
        migrations.CreateModel(
            name='UserAccount',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=255)),
                ('surname', models.CharField(max_length=255)),
                ('sex', models.CharField(choices=[(0, 'Male'), (1, 'Female')], max_length=1)),
                ('age', models.PositiveSmallIntegerField()),
            ],
        ),
        migrations.AddField(
            model_name='activity',
            name='user',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='activities', to='core.UserAccount'),
        ),
        migrations.RunPython(create_admin),
    ]
