Mercurial > public > sg101
view news/migrations/0001_initial.py @ 1145:a469445d8be3
Convert fixed pages to V3 design.
author | Brian Neal <bgneal@gmail.com> |
---|---|
date | Mon, 14 Nov 2016 19:40:36 -0600 |
parents | ec28e9d1e82a |
children |
line wrap: on
line source
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import models, migrations from django.conf import settings import tagging.fields class Migration(migrations.Migration): dependencies = [ migrations.swappable_dependency(settings.AUTH_USER_MODEL), ] operations = [ migrations.CreateModel( name='Category', fields=[ ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)), ('title', models.CharField(max_length=64)), ('slug', models.SlugField(max_length=64)), ('icon', models.ImageField(upload_to=b'news/categories/', blank=True)), ], options={ 'ordering': ('title',), 'verbose_name_plural': 'Categories', }, bases=(models.Model,), ), migrations.CreateModel( name='PendingStory', fields=[ ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)), ('title', models.CharField(max_length=255)), ('short_text', models.TextField()), ('long_text', models.TextField(blank=True)), ('date_submitted', models.DateTimeField(db_index=True)), ('allow_comments', models.BooleanField(default=True)), ('tags', tagging.fields.TagField(max_length=255, blank=True)), ('front_page_expiration', models.DateField(null=True, blank=True)), ('update_date', models.DateTimeField(db_index=True, blank=True)), ('priority', models.IntegerField(default=0, db_index=True, blank=True)), ('meta_description', models.TextField(blank=True)), ('category', models.ForeignKey(to='news.Category')), ('submitter', models.ForeignKey(to=settings.AUTH_USER_MODEL)), ], options={ 'ordering': ('-date_submitted',), 'verbose_name_plural': 'Pending Stories', }, bases=(models.Model,), ), migrations.CreateModel( name='Story', fields=[ ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)), ('title', models.CharField(max_length=255)), ('short_text', models.TextField()), ('long_text', models.TextField(blank=True)), ('date_submitted', models.DateTimeField(db_index=True)), ('allow_comments', models.BooleanField(default=True)), ('tags', tagging.fields.TagField(max_length=255, blank=True)), ('front_page_expiration', models.DateField(null=True, blank=True)), ('update_date', models.DateTimeField(db_index=True, blank=True)), ('priority', models.IntegerField(default=0, db_index=True, blank=True)), ('meta_description', models.TextField(blank=True)), ('category', models.ForeignKey(to='news.Category')), ('submitter', models.ForeignKey(to=settings.AUTH_USER_MODEL)), ], options={ 'ordering': ('-date_submitted',), 'verbose_name': 'news story', 'verbose_name_plural': 'news stories', }, bases=(models.Model,), ), ]