JoseLuis de la Rosa Triviño wrote:
> We've seen for instances of glossary and image gallery that the list of
> local roles include Section * and Workspace * roles, no matter where the
> object is located (sections or workspaces).
> 
>  
> 
> We've found the code where the filtering is done and it seems that we
> should take into account the current location as a new filter of the
> context. Is this right?

Yes ideally...

>  
> 
> The snippet is in MembershipTool.py in the method getCPSCandidateLocalRoles:
> 
>  
> 
> ################
> 
> # filter roles by portal type using prefix
> 
>         # XXX TODO relevant roles should be store in the portal_types tool
> 
>         ptype_role_prefix = {'Section': ('Section',),
> 
>                              'Workspace': ('Workspace'),
> 
>                              'Wiki': ('Contributor', 'Reader'),
> 
>                              'Calendar': ('Workspace',),
> 
>                              'CPSForum': ('Forum',),
> 
>                              'Chat': ('Chat',),
> 
>                              'CPS Calendar': ('Attendee',),
> 
>                              'Blog': ('BlogManager', 'BlogPoster'),
> 
>                              }
> 
>         ptype = obj.portal_type
> 
>         if ptype in ptype_role_prefix.keys():
> 
> ########################
> 

There is an open ticket about this over there :
http://svn.nuxeo.org/trac/pub/ticket/661

        J.

-- 
Julien Anguenot | Nuxeo R&D (Paris, France)
Open Source ECM - www.nuxeo.com
CPS Platform - http://www.cps-project.org
Mobile: +33 (0) 6 72 57 57 66

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
cps-users mailing list
[email protected]
http://lists.nuxeo.com/mailman/listinfo/cps-users

Reply via email to