1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586 |
- # Generated by Django 2.0.3 on 2018-04-04 15:39
- 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='Canvas',
- fields=[
- ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
- ('title', models.CharField(db_index=True, help_text='The title of the canvas', max_length=255)),
- ('date_created', models.DateTimeField(auto_now_add=True, db_index=True)),
- ('date_modified', models.DateTimeField(auto_now=True, db_index=True)),
- ('public', models.BooleanField(db_index=True, default=False)),
- ('admins', models.ManyToManyField(related_name='admins', to=settings.AUTH_USER_MODEL)),
- ('users', models.ManyToManyField(related_name='users', to=settings.AUTH_USER_MODEL)),
- ],
- options={
- 'ordering': ('date_modified',),
- },
- ),
- migrations.CreateModel(
- name='CanvasTag',
- fields=[
- ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
- ('text', models.CharField(max_length=255)),
- ],
- ),
- migrations.CreateModel(
- name='Comment',
- fields=[
- ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
- ('text', models.CharField(help_text='Type a comment', max_length=255)),
- ('resolved', models.BooleanField(db_index=True, default=False)),
- ],
- options={
- 'ordering': ('resolved',),
- },
- ),
- migrations.CreateModel(
- name='Idea',
- fields=[
- ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
- ('text', models.CharField(help_text='The description of the idea', max_length=255)),
- ('date_created', models.DateTimeField(auto_now_add=True, db_index=True)),
- ('date_modified', models.DateTimeField(auto_now=True, db_index=True)),
- ('canvas', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, to='catalog.Canvas')),
- ('canvas_tags', models.ManyToManyField(blank=True, related_name='canvas_tags', to='catalog.CanvasTag')),
- ],
- options={
- 'ordering': ('date_created',),
- },
- ),
- migrations.CreateModel(
- name='IdeaCategory',
- fields=[
- ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
- ('description', models.CharField(help_text='Category Description', max_length=50)),
- ],
- ),
- migrations.AddField(
- model_name='idea',
- name='category',
- field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, to='catalog.IdeaCategory'),
- ),
- migrations.AddField(
- model_name='comment',
- name='idea',
- field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, to='catalog.Idea'),
- ),
- migrations.AddField(
- model_name='comment',
- name='user',
- field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL),
- ),
- ]
|