# Generated by Django 3.1.3 on 2020-11-21 05:08 from django.conf import settings from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): initial = True dependencies = [ migrations.swappable_dependency(settings.AUTH_USER_MODEL), ] operations = [ migrations.CreateModel( name='Categoria', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('nombre', models.CharField(max_length=50)), ('created', models.DateTimeField(auto_now_add=True)), ('updated', models.DateTimeField(auto_now_add=True)), ], options={ 'verbose_name': 'categoria', 'verbose_name_plural': 'categorias', }, ), migrations.CreateModel( name='Entrada', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('titulo', models.CharField(max_length=50)), ('contenido', models.CharField(max_length=50)), ('imagen', models.ImageField(blank=True, null=True, upload_to='blog')), ('created', models.DateTimeField(auto_now_add=True)), ('updated', models.DateTimeField(auto_now_add=True)), ('autor', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ('categorias', models.ManyToManyField(to='blog.Categoria')), ], options={ 'verbose_name': 'entrada', 'verbose_name_plural': 'entradas', }, ), ]