summaryrefslogtreecommitdiff
path: root/repoze/bfg/sampleapp/models.py
diff options
context:
space:
mode:
authorChris McDonough <chrism@agendaless.com>2008-08-24 01:59:07 +0000
committerChris McDonough <chrism@agendaless.com>2008-08-24 01:59:07 +0000
commit0a6da3800b963b2104c8e10598ac7589a81f981e (patch)
treea462056f22bcff3f08d82cec98682e1dfac7df5c /repoze/bfg/sampleapp/models.py
parent2c647036d9ed5e5a27cb6b2a5700a8f0d3a7d2a7 (diff)
downloadpyramid-0a6da3800b963b2104c8e10598ac7589a81f981e.tar.gz
pyramid-0a6da3800b963b2104c8e10598ac7589a81f981e.tar.bz2
pyramid-0a6da3800b963b2104c8e10598ac7589a81f981e.zip
- Remove ``sampleapp`` sample application from bfg package itself.
- Remove dependency on FormEncode (only needed by sampleapp). - Fix paster template generation so that case-sensitivity is preserved for project vs. package name. - Depend on ``z3c.pt`` version 1.0a1 (which requires the ``[lxml]`` extra currently).
Diffstat (limited to 'repoze/bfg/sampleapp/models.py')
-rw-r--r--repoze/bfg/sampleapp/models.py42
1 files changed, 0 insertions, 42 deletions
diff --git a/repoze/bfg/sampleapp/models.py b/repoze/bfg/sampleapp/models.py
deleted file mode 100644
index 7da6f1033..000000000
--- a/repoze/bfg/sampleapp/models.py
+++ /dev/null
@@ -1,42 +0,0 @@
-from zope.interface import Interface
-from zope.interface import implements
-from zope.location.interfaces import ILocation
-from zope.location.location import Location
-
-from repoze.bfg.security import Everyone
-from repoze.bfg.security import Allow
-
-import datetime
-
-class IMapping(Interface):
- pass
-
-class IBlog(Interface):
- pass
-
-class Blog(dict, Location):
- __acl__ = [
- (Allow, Everyone, 'view'),
- (Allow, 'group:editors', 'add'),
- (Allow, 'group:editors', 'edit'),
- ]
- implements(IBlog, IMapping, ILocation)
-
-class IBlogEntry(Interface):
- pass
-
-class BlogEntry(object):
- implements(IBlogEntry)
- def __init__(self, title, body, author):
- self.title = title
- self.body = body
- self.author = author
- self.created = datetime.datetime.now()
-
-blog = Blog()
-blog['sample'] = BlogEntry('Sample Blog Entry',
- '<p>This is a sample blog entry</p>',
- 'chrism')
-def get_root(environ):
- return blog
-