from django.db import migrations, models


class Migration(migrations.Migration):
    dependencies = [('deals', '0005_alter_ayurvedavendorlisting_options_and_more')]

    operations = [
        migrations.CreateModel(
            name='WebsiteImage',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('page_path', models.CharField(blank=True, help_text='HTML filename, for example asnjewels.html. Leave blank to replace the image site-wide.', max_length=255)),
                ('label', models.CharField(blank=True, max_length=160)),
                ('original_path', models.CharField(help_text='Current image path or URL used by the website.', max_length=700)),
                ('replacement_image', models.ImageField(blank=True, upload_to='cms/site-images/')),
                ('replacement_url', models.CharField(blank=True, help_text='Optional external image URL used when no image is uploaded.', max_length=700)),
                ('active', models.BooleanField(default=True)),
                ('updated_at', models.DateTimeField(auto_now=True)),
            ],
            options={'ordering': ('page_path', 'label', 'original_path'), 'verbose_name': 'website image', 'verbose_name_plural': 'website images'},
        ),
        migrations.AddConstraint(model_name='websiteimage', constraint=models.UniqueConstraint(fields=('page_path', 'original_path'), name='unique_cms_image_per_page')),
    ]
