Ticket #6853 (closed Bug: fixed)
User search doesn't match on username, only on fullname
| Reported by: | limi | Owned by: | erikrose |
|---|---|---|---|
| Priority: | major | Milestone: | 3.0.4 |
| Component: | Users/Groups | Keywords: | |
| Cc: |
Description
When trying to add local sharing permissions to people, I discovered that the search doesn't match on username, which is odd.
How to reproduce:
- Create a user with the ID "testuser" and full name "Test User"
- Go to a folder, click the Sharing tab
- Try searching for "testuser" — it doesn't show up — searching for "test user" instead works
Change History
comment:2 Changed 4 years ago by wichert
- Owner changed from wichert to limi
The problem here is that the user interface (or the underlying view) expects magic that is not there: with PAS you always search for a user property. And there is no property which contains both the userid and the username, and it would not make sense since they are very different things.
You could update code to do two searches: one on the full name and one on the userid. Or you could restore the old Plone behaviour where you had a dropdown which allowed you to select what kind of search key you want to use.
At any rate this is not a problem in the user management part of Plone.
comment:3 Changed 4 years ago by cbcunc
Just reporting that this *is* a problem in the user mgmt part of Plone. Optilude is right. It does show up on the users/groups admin page. 2.5.x allowed searching on either userid or fullname without a dropdown. Even older versions allowed searching on email address. As an admin of many Plone sites with lots of users, these things get used every day. Dropdown with fullname preselected would probably be OK solution.

This seems to be a general problem with acl_users.searchUsers(). I've got the same problem in borg.project, for example. I think it's also a problem on the user/groups admin page.