# Copyright © 2004 Saugus.net, Inc. # All Rights Reserved. # This software is subject to the provisions of the Zope Public License, # Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution. # THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED # WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED # WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS # FOR A PARTICULAR PURPOSE. # Get the FactoryDispatcher. product=container.manage_addProduct['CMFCalendar'] # Build the instance. product.addEvent(id) # Fetch it, wrapped in container. item=getattr(container,id) # Perform other initialization. item.manage_addProperty('formatted_title','','string') item.manage_addProperty('long_description','','text') item.manage_addProperty('rank',0,'int') item.manage_addProperty('price',0,'int') item.manage_addProperty('rain_date',context.ZopeTime(),'date') item.manage_addProperty('performers',[],'lines') item.manage_addProperty('event_email','','string') item.manage_addProperty('event_phone','','string') item.manage_addProperty('event_fax','','string') item.manage_addProperty('contact_night_phone','','string') item.manage_addProperty('schedule_status','','string') item.manage_addProperty('repeat_status','','string') item.manage_addProperty('early_birds_okay',0,'boolean') item.manage_addProperty('html_allowed',0,'boolean') # Return it to the type object. return item