[Zope-PAS] Asymmetry between ZODBRoleManager and ZODBGroupManager
Jens Vagelpohl
jens at dataflake.org
Sun Dec 19 16:05:43 EST 2004
Hi Willi,
I'm sure that's an oversight - would you mind putting that into the
collector at...
http://zope.org/Members/urbanape/PluggableAuthService/Collector/
Thanks!
jens
On Dec 19, 2004, at 19:30, Willi Langenberger wrote:
> Hi!
>
> Both PAS plugins (ZODBRoleManager and ZODBGroupManager) have a
> "principal search form" (available when clicking on the 'assignments'
> column):
>
> Principal ID _________________ [search]
>
> Those forms look identical, but can yield different results.
>
> Reason: these forms call the functions 'listAvailablePrincipals' in
> ZODBRoleManager.py and ZODBGroupManager.py respectively, which in turn
> call the PAS searchPrincipals method. However, it is called
> differently: the role plugin uses the search string as the 'id'
> keyword argument, whereas the group plugin uses the search string as
> the 'name' keyword argument:
>
> ZODBRoleManager.py:
> [...]
> def listAvailablePrincipals( self, role_id, search_id ):
> [...]
> if search_id: # don't bother searching if no criteria
>
> parent = aq_parent( self )
>
> for info in parent.searchPrincipals( max_results=20
> , sort_by='id'
> ===> , id=search_id <===
> , exact_match=False
> ):
>
> ZODBGroupManager.py:
> [...]
> def listAvailablePrincipals( self, group_id, search_name ):
> [...]
> if search_name: # don't bother searching if no criteria
>
> parent = aq_parent( self )
>
> for info in parent.searchPrincipals( max_results=20
> , sort_by='id'
> ===> , name=search_name <===
> , exact_match=False
> ):
>
> Is this asymmetrie intended? If yes, what was the reason for this? I
> find it somewhat confusing...
>
>
> \wlang{}
>
> --
> Willi.Langenberger at wu-wien.ac.at Fax: +43/1/31336/9207
> Zentrum fuer Informatikdienste, Wirtschaftsuniversitaet Wien, Austria
> _______________________________________________
> Zope-PAS mailing list
> Zope-PAS at zope.org
> http://mail.zope.org/mailman/listinfo/zope-pas
>
---------------
Jens Vagelpohl jens at zetwork.com
Software Engineer +49-(0)441-36 18 14 38
Zetwork GmbH http://www.zetwork.com/
More information about the Zope-PAS
mailing list