Skip to content
This repository was archived by the owner on Aug 21, 2024. It is now read-only.
This repository was archived by the owner on Aug 21, 2024. It is now read-only.

[Story] Show User ID and associated identity providers on /admin/users, allow for searching on identity-provider fields #7160

@barankyle

Description

@barankyle

Looking up users on /admin/users is currently confusing. If someone gives their userId, or says something like "I'm logged in with [email protected]", there's no way to match those to anything on the page. The only thing they can give that is look-uppable is username, but since that's not unique, that can be prone to collisions.

The ID should be shown for each user in the user's row. I would also like to display the associated identity-providers. I was thinking that if there were only one identity-provider (not a guest identity-provider), show the user-identifying field from it in the table, otherwise display something like "multiple linked accounts". In the user drawer, all of the identity-providers can be shown in a column.

identity-providers will need another column, I think, for this. Currently, what's stored in the 'token' field for OAuth providers is :::, where providerId is usually an ID coming from the provider, not a human-readable identifier. For instance, if logging in with google, the token is something like google:::117536434016124331462. The number doesn't tell you anything useful. I think there should be a new column 'accountIdentifier', where we store the user's identifying information, e.g. the email address from Google, GitHub/LinkedIn username, Twitter handle, etc. This is what will be shown in the user table if there's only one linked account. For email login, the email address is already in the token, so just duplicate it in accountIdentifier.

user.find should support the search parameter containing things other than name. It should search on the id as well, so you can just copy/paste the ID into the search bar and get a single match. It should also search on the new 'accountIdentifier' field in the associated identity-providers, so that one could enter '[email protected]' and get a single match.

  • Display userId in table on /admin/users
  • Save major username/email from each identity-provider in new accountIdentifier column
  • If one non-guest linked identity-provider, show accountIdentifier of that one IP in user table
  • If multiple linked IPs, show 'multiple linked acccounts'
  • Show ID and accountIdentifier of all linked IPs in user View drawer
  • user.find, when passed action: admin, will search the ID and linked accountIdentifiers as well as name

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions