svn changes to tools/memberdata.py
from
jhammel@...
on Oct 12, 2006 06:32 PM
Hello,
I noticed that in svn the member search results were not working. Namely, that described in
http://plone.org/products/remember/issues/6
I have changed some code in tools/memberdata.py to try to fix this. No luck. Well, partial luck -- no crashes anymore. But now all search queries work. Working on it. Anyway, I'll paste my svn log message, so apologies in advance if you get this twice.
Switched the searchForMembers so that it returns brains instead of Member
objects. This fixes one problem -- namely, the search for members page
doesn't crash -- but the search still doesn't work. Namely, no matter what
login i search for, i will get back all the members. I don't know why this
is currently. Things to note: (also commented in code)
* indexes=Set(catalog.indexes()) # this is the empty set. should it be?
* indexes = indexes & Set(search_dict.keys()) # i switched this to the to union (|)...should it be? otherwise, combined with above bullet, there are no results* if results and not (search_dict.get('brains', True) or \
REQUEST.get('brains', False)): # i switched (search_dict.get('brains', False) to (search_dict.get('brains', True). this makes it return brains by default. I'm not sure what is the desired behavior, but the member search page will surely die if it is not brains, as member_search_results.pt
relies on the getUserId() function which the remember Member object does not have
Jeff