-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy path0001_initial.py
33 lines (27 loc) · 1.21 KB
/
0001_initial.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
# Generated by Django 2.2.1 on 2019-05-16 17:09
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
import martor.models
class Migration(migrations.Migration):
initial = True
dependencies = [
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
]
operations = [
migrations.CreateModel(
name='Post',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('slug', models.SlugField(blank=True, max_length=100, null=True, unique=True)),
('title', models.CharField(max_length=200)),
('description', models.CharField(blank=True, max_length=200)),
('content', martor.models.MartorField()),
('draft', models.BooleanField(default=True)),
('created', models.DateTimeField(default=django.utils.timezone.now)),
('updated', models.DateTimeField(auto_now=True)),
('author', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
],
),
]