# -*- coding: utf-8 -*-
# Generated by Django 1.10.1 on 2016-11-26 07:07
from __future__ import unicode_literals

from django.conf import settings
import django.core.validators
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='Book',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('title', models.CharField(max_length=200)),
                ('author', models.CharField(max_length=200)),
                ('year_published', models.IntegerField()),
                ('description', models.CharField(max_length=500)),
                ('cover_image', models.ImageField(blank=True, null=True, upload_to='cover_photos')),
                ('genre', models.IntegerField(choices=[(0, 'Science fiction'), (1, 'Drama'), (2, 'Action and Adventure'), (3, 'Romance'), (4, 'Mystery'), (5, 'Health'), (6, "Children's"), (7, 'Science'), (8, 'History'), (9, 'Biographies')])),
            ],
        ),
        migrations.CreateModel(
            name='BookForSale',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('cost', models.IntegerField()),
                ('sold', models.BooleanField(default=False)),
                ('condition', models.IntegerField(choices=[(0, 'Poor'), (1, 'Fair'), (2, 'Good'), (3, 'New')])),
                ('book', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='bookSell.Book')),
                ('userBought', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='user_bought', to=settings.AUTH_USER_MODEL)),
                ('userSelling', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='users_selling', to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='BookRating',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('rating', models.IntegerField(default=1, validators=[django.core.validators.MaxValueValidator(5), django.core.validators.MinValueValidator(1)])),
                ('comment', models.CharField(max_length=500)),
                ('book', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='bookSell.Book')),
            ],
        ),
        migrations.CreateModel(
            name='Payment',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('credit_card', models.CharField(max_length=150)),
                ('first_name', models.CharField(max_length=20)),
                ('last_name', models.CharField(max_length=20)),
                ('cvv', models.CharField(max_length=3)),
                ('year', models.IntegerField(choices=[(2016, 2016), (2017, 2017), (2018, 2018), (2019, 2019), (2020, 2020)], default=2016)),
                ('month', models.IntegerField(choices=[(0, 'Jan'), (1, 'Feb'), (2, 'Mar'), (3, 'Apr'), (4, 'May'), (5, 'Jun'), (6, 'Jul'), (7, 'Aug'), (8, 'Sept'), (9, 'Oct'), (10, 'Nov'), (11, 'Dec')], default=11)),
                ('street_address', models.CharField(default='', max_length=150)),
                ('city', models.CharField(max_length=30)),
                ('state', models.CharField(max_length=10)),
                ('postal', models.CharField(max_length=5)),
                ('country', models.CharField(max_length=10)),
                ('user', models.OneToOneField(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='user', to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='UserProfile',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('phone', models.CharField(max_length=30)),
                ('firstname', models.CharField(max_length=30)),
                ('lastname', models.CharField(max_length=30)),
                ('favorite_genre', models.IntegerField(choices=[(0, 'Science Fiction'), (1, 'Drama'), (2, 'Action and Adventure'), (3, 'Romance'), (4, 'Mystery'), (5, 'Health'), (6, 'Children'), (7, 'Science'), (8, 'History'), (9, 'Biographies')])),
                ('user', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='UserRating',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('rating', models.IntegerField(validators=[django.core.validators.MaxValueValidator(5), django.core.validators.MinValueValidator(1)])),
                ('comment', models.CharField(max_length=500)),
                ('book', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='bookSell.BookForSale')),
            ],
        ),
        migrations.CreateModel(
            name='Wishlist',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('costLessThan', models.IntegerField(validators=[django.core.validators.MinValueValidator(0)])),
                ('betterConditionThan', models.IntegerField(choices=[(0, 'Poor'), (1, 'Fair'), (2, 'Good'), (3, 'New')])),
                ('book', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='bookSell.Book')),
                ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.AddField(
            model_name='bookrating',
            name='user',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='bookSell.UserProfile'),
        ),
    ]

bbf039264191715a9084bc668973801c05e9e41b
<mask token>

<mask token>


class Migration(migrations.Migration):
    <mask token>
    <mask token>
    <mask token>

<mask token>


class Migration(migrations.Migration):
    initial = True
    dependencies = [migrations.swappable_dependency(settings.AUTH_USER_MODEL)]
    operations = [migrations.CreateModel(name='Book', fields=[('id', models
        .AutoField(auto_created=True, primary_key=True, serialize=False,
        verbose_name='ID')), ('title', models.CharField(max_length=200)), (
        'author', models.CharField(max_length=200)), ('year_published',
        models.IntegerField()), ('description', models.CharField(max_length
        =500)), ('cover_image', models.ImageField(blank=True, null=True,
        upload_to='cover_photos')), ('genre', models.IntegerField(choices=[
        (0, 'Science fiction'), (1, 'Drama'), (2, 'Action and Adventure'),
        (3, 'Romance'), (4, 'Mystery'), (5, 'Health'), (6, "Children's"), (
        7, 'Science'), (8, 'History'), (9, 'Biographies')]))]), migrations.
        CreateModel(name='BookForSale', fields=[('id', models.AutoField(
        auto_created=True, primary_key=True, serialize=False, verbose_name=
        'ID')), ('cost', models.IntegerField()), ('sold', models.
        BooleanField(default=False)), ('condition', models.IntegerField(
        choices=[(0, 'Poor'), (1, 'Fair'), (2, 'Good'), (3, 'New')])), (
        'book', models.ForeignKey(on_delete=django.db.models.deletion.
        CASCADE, to='bookSell.Book')), ('userBought', models.ForeignKey(
        blank=True, null=True, on_delete=django.db.models.deletion.CASCADE,
        related_name='user_bought', to=settings.AUTH_USER_MODEL)), (
        'userSelling', models.ForeignKey(null=True, on_delete=django.db.
        models.deletion.CASCADE, related_name='users_selling', to=settings.
        AUTH_USER_MODEL))]), migrations.CreateModel(name='BookRating',
        fields=[('id', models.AutoField(auto_created=True, primary_key=True,
        serialize=False, verbose_name='ID')), ('rating', models.
        IntegerField(default=1, validators=[django.core.validators.
        MaxValueValidator(5), django.core.validators.MinValueValidator(1)])
        ), ('comment', models.CharField(max_length=500)), ('book', models.
        ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=
        'bookSell.Book'))]), migrations.CreateModel(name='Payment', fields=
        [('id', models.AutoField(auto_created=True, primary_key=True,
        serialize=False, verbose_name='ID')), ('credit_card', models.
        CharField(max_length=150)), ('first_name', models.CharField(
        max_length=20)), ('last_name', models.CharField(max_length=20)), (
        'cvv', models.CharField(max_length=3)), ('year', models.
        IntegerField(choices=[(2016, 2016), (2017, 2017), (2018, 2018), (
        2019, 2019), (2020, 2020)], default=2016)), ('month', models.
        IntegerField(choices=[(0, 'Jan'), (1, 'Feb'), (2, 'Mar'), (3, 'Apr'
        ), (4, 'May'), (5, 'Jun'), (6, 'Jul'), (7, 'Aug'), (8, 'Sept'), (9,
        'Oct'), (10, 'Nov'), (11, 'Dec')], default=11)), ('street_address',
        models.CharField(default='', max_length=150)), ('city', models.
        CharField(max_length=30)), ('state', models.CharField(max_length=10
        )), ('postal', models.CharField(max_length=5)), ('country', models.
        CharField(max_length=10)), ('user', models.OneToOneField(null=True,
        on_delete=django.db.models.deletion.CASCADE, related_name='user',
        to=settings.AUTH_USER_MODEL))]), migrations.CreateModel(name=
        'UserProfile', fields=[('id', models.AutoField(auto_created=True,
        primary_key=True, serialize=False, verbose_name='ID')), ('phone',
        models.CharField(max_length=30)), ('firstname', models.CharField(
        max_length=30)), ('lastname', models.CharField(max_length=30)), (
        'favorite_genre', models.IntegerField(choices=[(0,
        'Science Fiction'), (1, 'Drama'), (2, 'Action and Adventure'), (3,
        'Romance'), (4, 'Mystery'), (5, 'Health'), (6, 'Children'), (7,
        'Science'), (8, 'History'), (9, 'Biographies')])), ('user', models.
        OneToOneField(on_delete=django.db.models.deletion.CASCADE, to=
        settings.AUTH_USER_MODEL))]), migrations.CreateModel(name=
        'UserRating', fields=[('id', models.AutoField(auto_created=True,
        primary_key=True, serialize=False, verbose_name='ID')), ('rating',
        models.IntegerField(validators=[django.core.validators.
        MaxValueValidator(5), django.core.validators.MinValueValidator(1)])
        ), ('comment', models.CharField(max_length=500)), ('book', models.
        ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=
        'bookSell.BookForSale'))]), migrations.CreateModel(name='Wishlist',
        fields=[('id', models.AutoField(auto_created=True, primary_key=True,
        serialize=False, verbose_name='ID')), ('costLessThan', models.
        IntegerField(validators=[django.core.validators.MinValueValidator(0
        )])), ('betterConditionThan', models.IntegerField(choices=[(0,
        'Poor'), (1, 'Fair'), (2, 'Good'), (3, 'New')])), ('book', models.
        ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=
        'bookSell.Book')), ('user', models.ForeignKey(on_delete=django.db.
        models.deletion.CASCADE, to=settings.AUTH_USER_MODEL))]),
        migrations.AddField(model_name='bookrating', name='user', field=
        models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=
        'bookSell.UserProfile'))]

from __future__ import unicode_literals
from django.conf import settings
import django.core.validators
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='Book', fields=[('id', models
        .AutoField(auto_created=True, primary_key=True, serialize=False,
        verbose_name='ID')), ('title', models.CharField(max_length=200)), (
        'author', models.CharField(max_length=200)), ('year_published',
        models.IntegerField()), ('description', models.CharField(max_length
        =500)), ('cover_image', models.ImageField(blank=True, null=True,
        upload_to='cover_photos')), ('genre', models.IntegerField(choices=[
        (0, 'Science fiction'), (1, 'Drama'), (2, 'Action and Adventure'),
        (3, 'Romance'), (4, 'Mystery'), (5, 'Health'), (6, "Children's"), (
        7, 'Science'), (8, 'History'), (9, 'Biographies')]))]), migrations.
        CreateModel(name='BookForSale', fields=[('id', models.AutoField(
        auto_created=True, primary_key=True, serialize=False, verbose_name=
        'ID')), ('cost', models.IntegerField()), ('sold', models.
        BooleanField(default=False)), ('condition', models.IntegerField(
        choices=[(0, 'Poor'), (1, 'Fair'), (2, 'Good'), (3, 'New')])), (
        'book', models.ForeignKey(on_delete=django.db.models.deletion.
        CASCADE, to='bookSell.Book')), ('userBought', models.ForeignKey(
        blank=True, null=True, on_delete=django.db.models.deletion.CASCADE,
        related_name='user_bought', to=settings.AUTH_USER_MODEL)), (
        'userSelling', models.ForeignKey(null=True, on_delete=django.db.
        models.deletion.CASCADE, related_name='users_selling', to=settings.
        AUTH_USER_MODEL))]), migrations.CreateModel(name='BookRating',
        fields=[('id', models.AutoField(auto_created=True, primary_key=True,
        serialize=False, verbose_name='ID')), ('rating', models.
        IntegerField(default=1, validators=[django.core.validators.
        MaxValueValidator(5), django.core.validators.MinValueValidator(1)])
        ), ('comment', models.CharField(max_length=500)), ('book', models.
        ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=
        'bookSell.Book'))]), migrations.CreateModel(name='Payment', fields=
        [('id', models.AutoField(auto_created=True, primary_key=True,
        serialize=False, verbose_name='ID')), ('credit_card', models.
        CharField(max_length=150)), ('first_name', models.CharField(
        max_length=20)), ('last_name', models.CharField(max_length=20)), (
        'cvv', models.CharField(max_length=3)), ('year', models.
        IntegerField(choices=[(2016, 2016), (2017, 2017), (2018, 2018), (
        2019, 2019), (2020, 2020)], default=2016)), ('month', models.
        IntegerField(choices=[(0, 'Jan'), (1, 'Feb'), (2, 'Mar'), (3, 'Apr'
        ), (4, 'May'), (5, 'Jun'), (6, 'Jul'), (7, 'Aug'), (8, 'Sept'), (9,
        'Oct'), (10, 'Nov'), (11, 'Dec')], default=11)), ('street_address',
        models.CharField(default='', max_length=150)), ('city', models.
        CharField(max_length=30)), ('state', models.CharField(max_length=10
        )), ('postal', models.CharField(max_length=5)), ('country', models.
        CharField(max_length=10)), ('user', models.OneToOneField(null=True,
        on_delete=django.db.models.deletion.CASCADE, related_name='user',
        to=settings.AUTH_USER_MODEL))]), migrations.CreateModel(name=
        'UserProfile', fields=[('id', models.AutoField(auto_created=True,
        primary_key=True, serialize=False, verbose_name='ID')), ('phone',
        models.CharField(max_length=30)), ('firstname', models.CharField(
        max_length=30)), ('lastname', models.CharField(max_length=30)), (
        'favorite_genre', models.IntegerField(choices=[(0,
        'Science Fiction'), (1, 'Drama'), (2, 'Action and Adventure'), (3,
        'Romance'), (4, 'Mystery'), (5, 'Health'), (6, 'Children'), (7,
        'Science'), (8, 'History'), (9, 'Biographies')])), ('user', models.
        OneToOneField(on_delete=django.db.models.deletion.CASCADE, to=
        settings.AUTH_USER_MODEL))]), migrations.CreateModel(name=
        'UserRating', fields=[('id', models.AutoField(auto_created=True,
        primary_key=True, serialize=False, verbose_name='ID')), ('rating',
        models.IntegerField(validators=[django.core.validators.
        MaxValueValidator(5), django.core.validators.MinValueValidator(1)])
        ), ('comment', models.CharField(max_length=500)), ('book', models.
        ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=
        'bookSell.BookForSale'))]), migrations.CreateModel(name='Wishlist',
        fields=[('id', models.AutoField(auto_created=True, primary_key=True,
        serialize=False, verbose_name='ID')), ('costLessThan', models.
        IntegerField(validators=[django.core.validators.MinValueValidator(0
        )])), ('betterConditionThan', models.IntegerField(choices=[(0,
        'Poor'), (1, 'Fair'), (2, 'Good'), (3, 'New')])), ('book', models.
        ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=
        'bookSell.Book')), ('user', models.ForeignKey(on_delete=django.db.
        models.deletion.CASCADE, to=settings.AUTH_USER_MODEL))]),
        migrations.AddField(model_name='bookrating', name='user', field=
        models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=
        'bookSell.UserProfile'))]

# -*- coding: utf-8 -*-
# Generated by Django 1.10.1 on 2016-11-26 07:07
from __future__ import unicode_literals

from django.conf import settings
import django.core.validators
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='Book',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('title', models.CharField(max_length=200)),
                ('author', models.CharField(max_length=200)),
                ('year_published', models.IntegerField()),
                ('description', models.CharField(max_length=500)),
                ('cover_image', models.ImageField(blank=True, null=True, upload_to='cover_photos')),
                ('genre', models.IntegerField(choices=[(0, 'Science fiction'), (1, 'Drama'), (2, 'Action and Adventure'), (3, 'Romance'), (4, 'Mystery'), (5, 'Health'), (6, "Children's"), (7, 'Science'), (8, 'History'), (9, 'Biographies')])),
            ],
        ),
        migrations.CreateModel(
            name='BookForSale',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('cost', models.IntegerField()),
                ('sold', models.BooleanField(default=False)),
                ('condition', models.IntegerField(choices=[(0, 'Poor'), (1, 'Fair'), (2, 'Good'), (3, 'New')])),
                ('book', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='bookSell.Book')),
                ('userBought', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='user_bought', to=settings.AUTH_USER_MODEL)),
                ('userSelling', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='users_selling', to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='BookRating',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('rating', models.IntegerField(default=1, validators=[django.core.validators.MaxValueValidator(5), django.core.validators.MinValueValidator(1)])),
                ('comment', models.CharField(max_length=500)),
                ('book', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='bookSell.Book')),
            ],
        ),
        migrations.CreateModel(
            name='Payment',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('credit_card', models.CharField(max_length=150)),
                ('first_name', models.CharField(max_length=20)),
                ('last_name', models.CharField(max_length=20)),
                ('cvv', models.CharField(max_length=3)),
                ('year', models.IntegerField(choices=[(2016, 2016), (2017, 2017), (2018, 2018), (2019, 2019), (2020, 2020)], default=2016)),
                ('month', models.IntegerField(choices=[(0, 'Jan'), (1, 'Feb'), (2, 'Mar'), (3, 'Apr'), (4, 'May'), (5, 'Jun'), (6, 'Jul'), (7, 'Aug'), (8, 'Sept'), (9, 'Oct'), (10, 'Nov'), (11, 'Dec')], default=11)),
                ('street_address', models.CharField(default='', max_length=150)),
                ('city', models.CharField(max_length=30)),
                ('state', models.CharField(max_length=10)),
                ('postal', models.CharField(max_length=5)),
                ('country', models.CharField(max_length=10)),
                ('user', models.OneToOneField(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='user', to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='UserProfile',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('phone', models.CharField(max_length=30)),
                ('firstname', models.CharField(max_length=30)),
                ('lastname', models.CharField(max_length=30)),
                ('favorite_genre', models.IntegerField(choices=[(0, 'Science Fiction'), (1, 'Drama'), (2, 'Action and Adventure'), (3, 'Romance'), (4, 'Mystery'), (5, 'Health'), (6, 'Children'), (7, 'Science'), (8, 'History'), (9, 'Biographies')])),
                ('user', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='UserRating',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('rating', models.IntegerField(validators=[django.core.validators.MaxValueValidator(5), django.core.validators.MinValueValidator(1)])),
                ('comment', models.CharField(max_length=500)),
                ('book', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='bookSell.BookForSale')),
            ],
        ),
        migrations.CreateModel(
            name='Wishlist',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('costLessThan', models.IntegerField(validators=[django.core.validators.MinValueValidator(0)])),
                ('betterConditionThan', models.IntegerField(choices=[(0, 'Poor'), (1, 'Fair'), (2, 'Good'), (3, 'New')])),
                ('book', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='bookSell.Book')),
                ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.AddField(
            model_name='bookrating',
            name='user',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='bookSell.UserProfile'),
        ),
    ]
