# Generated by Django 2.2.15 on 2021-01-03 06:25

from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
import django_extensions.db.fields
import model_utils.fields


class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='Marker',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('created', model_utils.fields.AutoCreatedField(default=django.utils.timezone.now, editable=False, verbose_name='created')),
                ('modified', model_utils.fields.AutoLastModifiedField(default=django.utils.timezone.now, editable=False, verbose_name='modified')),
                ('name', models.CharField(default='标签', max_length=256, verbose_name='标签')),
                ('time', models.FloatField(blank=True, null=True, verbose_name='时间')),
                ('fps', models.FloatField(blank=True, null=True, verbose_name='帧率')),
                ('notes', models.TextField(blank=True, verbose_name='备注')),
            ],
            options={
                'verbose_name': '标记',
                'verbose_name_plural': '标记',
                'abstract': False,
            },
        ),
        migrations.CreateModel(
            name='VideosPlay',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('vkey', models.CharField(blank=True, max_length=256, verbose_name='vkey')),
                ('title', models.CharField(blank=True, max_length=256, verbose_name='标题')),
                ('title_cn', models.CharField(blank=True, max_length=256, verbose_name='中文标题')),
                ('thumbnail', models.CharField(blank=True, max_length=100, verbose_name='高清缩略图')),
                ('pornstars_name', models.CharField(blank=True, max_length=256, null=True, verbose_name='色情明星')),
                ('user_type', models.CharField(blank=True, max_length=256, null=True, verbose_name='色情明星类型')),
                ('is_hd', models.BooleanField(default=False, verbose_name='高清')),
                ('width', models.IntegerField(default=0, verbose_name='宽度')),
                ('high', models.IntegerField(default=0, verbose_name='高')),
                ('bitrate', models.IntegerField(default=0, verbose_name='比特率')),
                ('md5', models.CharField(blank=True, max_length=32, verbose_name='MD5')),
                ('video_file_dir', models.CharField(blank=True, max_length=256, verbose_name='文件所在路径')),
                ('video_file_name', models.CharField(blank=True, max_length=256, verbose_name='文件名')),
                ('video_extension', models.CharField(blank=True, max_length=50, verbose_name='后缀名')),
                ('video_file_size', models.IntegerField(default=0, verbose_name='文件大小')),
                ('views', models.CharField(blank=True, max_length=50, verbose_name='观看次数')),
                ('added', models.CharField(blank=True, max_length=100, verbose_name='添加于')),
                ('type', models.CharField(blank=True, max_length=50, null=True, verbose_name='类型')),
                ('is_mosaic', models.BooleanField(default=False, verbose_name='马赛克')),
                ('is_watermark', models.BooleanField(default=False, verbose_name='水印')),
                ('descriptions', models.TextField(blank=True, verbose_name='描述')),
                ('tags_text', models.CharField(blank=True, max_length=365, verbose_name='标签文本')),
                ('is_pbf', models.BooleanField(default=False, verbose_name='暴风影音书签')),
                ('notes', models.TextField(blank=True, verbose_name='备注')),
                ('source', models.CharField(blank=True, max_length=256, verbose_name='资料来源')),
                ('is_delete', models.BooleanField(default=False, verbose_name='删除')),
                ('is_favorite', models.BooleanField(default=False, verbose_name='收藏')),
                ('is_download', models.BooleanField(default=False, verbose_name='下载')),
                ('is_err', models.BooleanField(default=False, verbose_name='错误')),
                ('err_info', models.TextField(blank=True, verbose_name='错误信息')),
                ('is_ignore', models.BooleanField(default=False, verbose_name='忽略')),
                ('save_as', models.CharField(blank=True, max_length=500, null=True, verbose_name='文件保存在')),
                ('create_name', models.CharField(blank=True, max_length=100, verbose_name='创建者名称')),
                ('write_name', models.CharField(blank=True, max_length=100, verbose_name='最后修改者名称')),
                ('created', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')),
                ('modified', django_extensions.db.fields.ModificationDateTimeField(auto_now=True, verbose_name='修改时间')),
                ('is_repeat', models.BooleanField(default=False, verbose_name='重复')),
                ('views_count', models.IntegerField(default=0, verbose_name='查看次数')),
                ('last_viewed_time', models.DateTimeField(blank=True, null=True, verbose_name='上次查看时间')),
            ],
            options={
                'verbose_name': 'Videos Play',
                'verbose_name_plural': 'Videos Play',
            },
        ),
        migrations.CreateModel(
            name='VideosPlayThrough',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('created', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')),
                ('marker', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='video_play.Marker')),
                ('video', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='video_play.VideosPlay')),
            ],
        ),
        migrations.AddField(
            model_name='videosplay',
            name='markers',
            field=models.ManyToManyField(through='video_play.VideosPlayThrough', to='video_play.Marker'),
        ),
        migrations.AddField(
            model_name='videosplay',
            name='related_file',
            field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='video_play.VideosPlay', verbose_name='相关文件'),
        ),
    ]
