Back to index

plone3  3.1.7
__init__.py
Go to the documentation of this file.
00001 from Products.CMFCore import utils, DirectoryView
00002 from Products.Archetypes.atapi import *
00003 from Products.Archetypes import listTypes
00004 
00005 ADD_CONTENT_PERMISSION = '''Add FAQ content'''
00006 PROJECTNAME = "FAQ"
00007 
00008 product_globals=globals()
00009 
00010 DirectoryView.registerDirectory('skins', product_globals)
00011 DirectoryView.registerDirectory('skins/faq', product_globals)
00012 
00013 
00014 def initialize(context):
00015     ##Import Types here to register them (were removed by pyflake check!)
00016     import FAQ
00017     import FAQQuestion
00018 
00019     content_types, constructors, ftis = process_types(
00020         listTypes(PROJECTNAME),
00021         PROJECTNAME)
00022 
00023     utils.ContentInit(
00024         PROJECTNAME + ' Content',
00025         content_types      = content_types,
00026         permission         = ADD_CONTENT_PERMISSION,
00027         extra_constructors = constructors,
00028         fti                = ftis,
00029         ).initialize(context)