mirror of
https://github.com/coder/coder.git
synced 2026-09-22 05:05:20 +08:00
feat: support filtering users table by login type (#17238)
#15896 Mentions ability to add support for filtering by login type The issue mentions that backend API support exists but the backend did not seem to have the support for this filter. So I have added the ability to filter it. I also added a corresponding update to readme file to make sure the docs will correctly showcase this feature
This commit is contained in:
@@ -260,6 +260,12 @@ WHERE
|
||||
github_com_user_id = @github_com_user_id
|
||||
ELSE true
|
||||
END
|
||||
-- Filter by login_type
|
||||
AND CASE
|
||||
WHEN cardinality(@login_type :: login_type[]) > 0 THEN
|
||||
login_type = ANY(@login_type :: login_type[])
|
||||
ELSE true
|
||||
END
|
||||
-- End of filters
|
||||
|
||||
-- Authorize Filter clause will be injected below in GetAuthorizedUsers
|
||||
|
||||
Reference in New Issue
Block a user