Skip to content
Browse files

adding pages app for section model

  • Loading branch information...
1 parent 334e22a commit 0bd7192c7c5c670a3839040375e646b473bdedee @rmyers rmyers committed Apr 28, 2012
Showing with 22 additions and 0 deletions.
  1. 0 july/pages/__init__.py
  2. +6 −0 july/pages/admin.py
  3. +15 −0 july/pages/models.py
  4. +1 −0 july/settings.py
View
0 july/pages/__init__.py
No changes.
View
6 july/pages/admin.py
@@ -0,0 +1,6 @@
+
+from gae_django import admin
+
+from models import Section
+
+admin.site.register(Section, list_display=['title', 'order'])
View
15 july/pages/models.py
@@ -0,0 +1,15 @@
+
+from google.appengine.ext import db
+
+class Section(db.Model):
+ """Simple model for handling section content"""
+
+ title = db.StringProperty(required=True)
+ order = db.IntegerProperty(default=1)
+ blurb_one = db.TextProperty()
+ blurb_two = db.TextProperty()
+ blurb_three = db.TextProperty()
+
+ def __unicode__(self):
+ return self.title
+
View
1 july/settings.py
@@ -146,6 +146,7 @@ def custom_show_toolbar(request):
'gae_django.admin',
'gae_django.auth',
'july',
+ 'july.pages',
)
AUTHENTICATION_BACKENDS = ['gae_django.auth.backend.GAEBackend', 'gae_django.auth.backend.GAETwitterBackend']

0 comments on commit 0bd7192

Please sign in to comment.
Something went wrong with that request. Please try again.