# -*- coding: utf-8 -*-
# Generated by Django 1.10.2 on 2017-06-17 12:44
from __future__ import unicode_literals

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


class Migration(migrations.Migration):

    dependencies = [
        ('book', '0001_initial'),
    ]

    operations = [
        migrations.CreateModel(
            name='Genere',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=50)),
            ],
        ),
        migrations.CreateModel(
            name='Publication',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=100)),
            ],
        ),
        migrations.AddField(
            model_name='book',
            name='price',
            field=models.DecimalField(decimal_places=2, default=0.0, max_digits=10),
            preserve_default=False,
        ),
        migrations.AddField(
            model_name='book',
            name='publish_year',
            field=models.IntegerField(default=2017),
            preserve_default=False,
        ),
        migrations.AddField(
            model_name='book',
            name='rating',
            field=models.IntegerField(default=1),
        ),
        migrations.AddField(
            model_name='book',
            name='genere',
            field=models.ManyToManyField(to='book.Genere'),
        ),
        migrations.AddField(
            model_name='book',
            name='publication',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, to='book.Publication'),
        ),
    ]
