[Zope-CMF] Proposal: Additional member properties to allow anonymous viewof the member roster
Tres Seaver
tseaver@palladion.com
Tue, 05 Jun 2001 13:25:13 -0400
Grégoire Weber wrote:
> Shane,
>
> I am very pleased about your (and the other peoples at DC)
> prompt answers! Thanks!
>
> Ok, I've found the checkbox. Sorry, I didn't look at this
> management screen before.
>
> But it didn't solve the problem entirely because 'getRoster'
> is declared protected. I changed it to declarePublic (see
> diff below). This solved the problem with the redirect to
> the login_form!
>
> Did I found a bug or is it intended not to show the roster
> to anonymous surfers?
CMFDefault.MembershipTool.getRoster is protected by the permission,
'List portal members.' If you want to expose the roster to anonymous
users, simply map that permission only the Anonymous role.
>
> So far so good.
>
> getRoster with only especialy selected members
> ----------------------------------------------
>
> Additionaly, I would be interested in a feature to get only
> especially selected members (selection by Manager). I'd like
> to list only special members (or organisations, see my first
> e-mail below) at the front portals page.
>
> e.g. if I call portal_membership.getRoster(onlySelected=1)
> in a DTML file i get only the selected ones. To achieve this
> behaviour there is a need of an additional property.
>
> I would be interested to implement this small enhancement.
> Could you point out where possible changes have to be made?
If your MemberDataTool has a property, "selected_for_listing" (or
whatever), then you can implement a custom MembershipTool, overriding
the 'getRoster' implementation to filter on that property (instead
of on 'isManager or member.listed').
Tres.
--
===============================================================
Tres Seaver tseaver@digicool.com
Digital Creations "Zope Dealers" http://www.zope.org