mirror of
https://github.com/coder/coder.git
synced 2026-09-24 15:04:27 +08:00
feat: Allow changing the 'group' oidc claim field (#6546)
* feat: Allow changing the 'group' oidc claim field * Enable empty groups support * fix: Delete was wiping all groups, not just the single user's groups * Update docs * fix: Dbfake delete group member fixed
This commit is contained in:
@@ -35,16 +35,10 @@ FROM
|
||||
|
||||
-- name: DeleteGroupMembersByOrgAndUser :exec
|
||||
DELETE FROM
|
||||
group_members
|
||||
USING
|
||||
group_members AS gm
|
||||
LEFT JOIN
|
||||
groups
|
||||
ON
|
||||
groups.id = gm.group_id
|
||||
group_members
|
||||
WHERE
|
||||
groups.organization_id = @organization_id AND
|
||||
gm.user_id = @user_id;
|
||||
group_members.user_id = @user_id
|
||||
AND group_id = ANY(SELECT id FROM groups WHERE organization_id = @organization_id);
|
||||
|
||||
-- name: InsertGroupMember :exec
|
||||
INSERT INTO
|
||||
|
||||
Reference in New Issue
Block a user