# Generated by Django 2.2.14 on 2020-08-03 04:50

import arvestust.models.image
import arvestust.models.validators.file
from django.db import migrations, models
import django.db.models.deletion
import uuid


class Migration(migrations.Migration):

    dependencies = [
        ('contenttypes', '0002_remove_content_type_name'),
        ('arvestust', '0009_auto_20200730_1900'),
    ]

    operations = [
        migrations.CreateModel(
            name='Image',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('object_id', models.PositiveIntegerField()),
                ('file', models.ImageField(storage='ekletik.settings.storage.PublicFileStorage', upload_to=arvestust.models.image.file_upload_path, validators=[arvestust.models.validators.file.validate_file_size], verbose_name='file')),
                ('uuid', models.UUIDField(default=uuid.uuid4, editable=False)),
                ('slug', models.SlugField(blank=True, editable=False, max_length=250, unique=True, verbose_name='slug')),
                ('created_at', models.DateTimeField(auto_now_add=True, verbose_name='created at')),
                ('updated_at', models.DateTimeField(auto_now=True, verbose_name='updated at')),
                ('content_type', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='image', to='contenttypes.ContentType')),
            ],
            options={
                'db_table': 'arvestust_images',
                'ordering': ['-created_at'],
            },
        ),
        migrations.AddIndex(
            model_name='image',
            index=models.Index(fields=['created_at'], name='arvestust_i_created_1596b1_idx'),
        ),
    ]
