# Generated by Django 4.0.7 on 2023-03-10 02:21

from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
import smart_media.modelfields


class Migration(migrations.Migration):

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

    operations = [
        migrations.AlterModelOptions(
            name='directory',
            options={'ordering': ['path'], 'verbose_name': 'Directory', 'verbose_name_plural': 'Directories'},
        ),
        migrations.AlterModelOptions(
            name='mediafile',
            options={'ordering': ['path'], 'verbose_name': 'MediaFile', 'verbose_name_plural': 'MediaFiles'},
        ),
        migrations.AddField(
            model_name='directory',
            name='checksum',
            field=models.CharField(blank=True, default='', help_text='A blake2 hash for directory information checksum.', max_length=50, verbose_name='checksum'),
        ),
        migrations.AddField(
            model_name='directory',
            name='cover',
            field=smart_media.modelfields.SmartMediaField(blank=True, default=None, help_text='Directory cover image.', max_length=255, null=True, upload_to='directory/cover/%y/%m', verbose_name='cover image'),
        ),
        migrations.AddField(
            model_name='directory',
            name='last_update',
            field=models.DateTimeField(db_index=True, default=django.utils.timezone.now, help_text='The last update date for this object.', verbose_name='last update'),
        ),
        migrations.AddField(
            model_name='directory',
            name='payload',
            field=models.TextField(blank=True, default='{}', help_text='Extra directory informations. Structure may vary from a directory to another.', verbose_name='JSON payload'),
        ),
        migrations.AddField(
            model_name='directory',
            name='released',
            field=models.DateField(blank=True, db_index=True, default=None, help_text='Released/On Air date for a serie directory or video set directory. This is not related to media collection or file creation.', null=True, verbose_name='released date'),
        ),
        migrations.AddField(
            model_name='mediafile',
            name='cover',
            field=smart_media.modelfields.SmartMediaField(blank=True, default=None, help_text='Media cover image.', max_length=255, null=True, upload_to='mediafile/cover/%y/%m', verbose_name='cover image'),
        ),
        migrations.AlterField(
            model_name='directory',
            name='created_date',
            field=models.DateTimeField(db_index=True, default=django.utils.timezone.now, help_text='The creation date for this object.', verbose_name='created date'),
        ),
        migrations.AlterField(
            model_name='directory',
            name='device',
            field=models.ForeignKey(default=None, help_text='The device which holds this directory.', on_delete=django.db.models.deletion.CASCADE, related_name='directories', to='django_deovi.device', verbose_name='Related device'),
        ),
        migrations.AlterField(
            model_name='mediafile',
            name='directory',
            field=models.ForeignKey(default=None, help_text='The directory which holds this file.', on_delete=django.db.models.deletion.CASCADE, related_name='mediafiles', to='django_deovi.directory', verbose_name='Related directory'),
        ),
    ]
