from Products.CPSInstaller.CPSInstaller import CPSInstaller from Products.CMFCore.CMFCorePermissions import View WAEUP_SKINS = { 'waeup_student' : 'Products/WAeUP/skins/waeup_student', } WAEUP_TYPES = { 'Student': { 'typeinfo_name': 'WAeUP: Student (Student)', 'add_meta_type': 'Factory-based Type Information', }, } WAEUP_ACTIONS = ( { 'tool' : 'portal_actions', 'id' : 'jambadmission', 'name' : 'action_jambadmission', 'action' : 'string:${portal_url}/jambadmission_input_form', 'permission': (View, ), 'condition' : '', 'category' : 'global', 'visible' : 1, }, ) def install(self): product_name = "WAeUP" installer = CPSInstaller(self, product_name) installer.log("Starting %(product_name)s install" % vars() ) installer.log("Verifying %(product_name)s permissions" % vars()) installer.verifySkins(WAEUP_SKINS) installer.resetSkinCache() installer.log("Verifying %(product_name)s schemas" % vars()) installer.verifySchemas(self.WAeUPSchemas()) installer.log("Verifying %(product_name)s layouts" % vars()) installer.verifyLayouts(self.WAeUPLayouts()) installer.verifyPortalTypes(WAEUP_TYPES) ## installer.log("Verifying %(product_name)s types" % vars()) ## installer.verifyContentTypes(WAEUP_TYPES) installer.log("Verifying %(product_name)s actions" % vars()) installer.verifyActions(WAEUP_ACTIONS) # This installs the *.po files in the i18n directory of the WAeUPStudent # product. installer.log("Installing translations") installer.finalize() installer.log("End of specific %(product_name)s install" % vars()) return installer.logResult()