# Generated by Django 2.0.3 on 2019-09-22 16:46

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


class Migration(migrations.Migration):

    dependencies = [
        ('wxapi', '0019_auto_20190922_0019'),
    ]

    operations = [
        migrations.CreateModel(
            name='AdImage',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('image', models.FileField(upload_to='advertise/', verbose_name='宣传文章图片')),
                ('status', models.IntegerField(default=1, verbose_name='状态 1：有效， 0:无效')),
            ],
        ),
        migrations.CreateModel(
            name='AdToImage',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('status', models.IntegerField(default=1, verbose_name='状态 1：有效， 0:无效')),
            ],
        ),
        migrations.AddField(
            model_name='advertise',
            name='image',
            field=models.FileField(blank=True, null=True, upload_to='advertise/', verbose_name='宣传首页图片'),
        ),
        migrations.AddField(
            model_name='customer',
            name='key',
            field=models.CharField(blank=True, max_length=16, null=True, verbose_name='密匙'),
        ),
        migrations.RemoveField(
            model_name='advertise',
            name='images',
        ),
        migrations.AddField(
            model_name='adtoimage',
            name='ad',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='wxapi.Advertise', verbose_name='宣传文章'),
        ),
        migrations.AddField(
            model_name='adtoimage',
            name='image',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='wxapi.AdImage', verbose_name='宣传文章中的图片'),
        ),
        migrations.AddField(
            model_name='advertise',
            name='images',
            field=models.ManyToManyField(through='wxapi.AdToImage', to='wxapi.AdImage'),
        ),
    ]
