Commit 73492b23 authored by Sebastien Robin's avatar Sebastien Robin

added title on modules


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@1042 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 4cd8f22e
......@@ -209,6 +209,7 @@ class ModuleTemplateItem(Implicit):
def __init__(self, module, **kw):
self.__dict__.update(kw)
self.module_id = module.getId()
self.module_title = module.getTitle()
self.module_type = module.getPortalType()
self.module_permission_list = []
for p in module.ac_inherited_permissions(1):
......@@ -220,6 +221,7 @@ class ModuleTemplateItem(Implicit):
portal = local_configuration.getPortalObject()
if self.module_id not in portal.objectIds(): # No renaming mapping for now
module = portal.newContent(id=self.module_id, portal_type=self.module_type)
module.setTitle(getattr(self,'module_title',''))
for name,role_list in self.module_permission_list:
acquire = (type(role_list) == type([]))
try:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment