# Generated by Django 3.2.9 on 2021-12-05 09:29

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


class Migration(migrations.Migration):

    initial = True

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

    operations = [
        migrations.CreateModel(
            name='Store',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('storeName', models.CharField(max_length=20, unique=True, verbose_name='店铺名')),
                ('address', models.TextField(default='', verbose_name='店铺地址')),
                ('info', models.TextField(verbose_name='店铺介绍')),
                ('createDate', models.DateField(auto_now_add=True, verbose_name='创建时间')),
                ('owner', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='user.user')),
            ],
            options={
                'db_table': 'store',
            },
        ),
        migrations.CreateModel(
            name='Book',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('bookID', models.CharField(max_length=50, unique=True, verbose_name='书本ID')),
                ('stock', models.IntegerField(default=0, verbose_name='库存')),
                ('price', models.DecimalField(decimal_places=2, max_digits=10, verbose_name='价格')),
                ('isbn', models.CharField(max_length=50, verbose_name='ISBN')),
                ('title', models.CharField(max_length=50, verbose_name='书名')),
                ('author', models.CharField(max_length=50, verbose_name='作者')),
                ('publisher', models.CharField(max_length=50, verbose_name='出版社')),
                ('originalTitle', models.CharField(max_length=50, verbose_name='原名')),
                ('translator', models.CharField(max_length=50, verbose_name='翻译')),
                ('pubYear', models.CharField(max_length=50, verbose_name='出版时间')),
                ('pages', models.IntegerField(verbose_name='页数')),
                ('currencyUnit', models.CharField(max_length=50, verbose_name='')),
                ('binding', models.CharField(max_length=50, verbose_name='封面')),
                ('authorIntro', models.TextField(verbose_name='作者简介')),
                ('bookIntro', models.TextField(verbose_name='书本简介')),
                ('content', models.TextField(verbose_name='内容')),
                ('tags', models.CharField(max_length=50, verbose_name='标签')),
                ('picture', models.ImageField(upload_to='', verbose_name='图片')),
                ('store', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='store.store')),
            ],
            options={
                'db_table': 'book',
            },
        ),
    ]
