# Generated by Django 2.2.15 on 2020-09-24 00:37

from django.db import migrations, models
import django.db.models.deletion
import edivorce.apps.core.redis


class Migration(migrations.Migration):

    dependencies = [
        ('core', '0020_auto_20200903_2328'),
    ]

    operations = [
        migrations.CreateModel(
            name='Document',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('filename', models.CharField(max_length=128, null=True)),
                ('size', models.IntegerField(default=0)),
                ('file', models.FileField(storage=edivorce.apps.core.redis.RedisStorage(), upload_to=edivorce.apps.core.redis.generate_unique_filename)),
                ('doc_type', models.CharField(blank=True, max_length=4, null=True)),
                ('party_code', models.IntegerField(default=0)),
                ('sort_order', models.IntegerField(default=1)),
                ('rotation', models.IntegerField(default=0)),
                ('date_uploaded', models.DateTimeField(auto_now_add=True)),
                ('bceid_user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='uploads', to='core.BceidUser')),
            ],
            options={
                'unique_together': {('bceid_user', 'doc_type', 'party_code', 'filename', 'size')},
            },
        ),
    ]
