# Generated by Django 3.0.4 on 2020-03-19 05:32

import datetime
from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):

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

    operations = [
        migrations.CreateModel(
            name='Tema',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('titulo_tema', models.CharField(max_length=255)),
                ('imagen', models.FileField(blank=True, null=True, upload_to='temas/imagenes')),
                ('creacion_curso', models.DateTimeField(default=datetime.datetime.now)),
            ],
        ),
        migrations.RenameField(
            model_name='curso',
            old_name='titulo',
            new_name='titulo_curso',
        ),
        migrations.CreateModel(
            name='Video',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('titulo_video', models.CharField(max_length=255)),
                ('video', models.URLField()),
                ('created_video', models.DateTimeField(default=datetime.datetime.now)),
                ('tema_id', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='cursos.Tema')),
            ],
        ),
        migrations.AddField(
            model_name='tema',
            name='curso_id',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='cursos.Curso'),
        ),
        migrations.CreateModel(
            name='Documento',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('titulo_documento', models.CharField(max_length=255)),
                ('documento', models.FileField(blank=True, null=True, upload_to='pdf/%Y/%m/')),
                ('created_documento', models.DateTimeField(default=datetime.datetime.now)),
                ('tema_id', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='cursos.Tema')),
            ],
        ),
    ]
