[CPS-users] Some local roles include both workspace and section roles.

Julien Anguenot ja at nuxeo.com
Thu Aug 3 03:11:00 CEST 2006


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

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 252 bytes
Desc: OpenPGP digital signature
Url : http://lists.nuxeo.com/pipermail/cps-users/attachments/20060803/8d234b8e/signature.pgp


More information about the cps-users mailing list

This list archive provided by Nuxeo, the leaders of open source ECM. Check out the Nuxeo 5 open source, standards-based ECM project.