1
0
mirror of https://github.com/bitwarden/server.git synced 2025-07-10 12:24:50 -05:00

return if org user has sso binding (#839)

This commit is contained in:
Kyle Spearrin
2020-07-28 21:11:45 -04:00
committed by GitHub
parent 2c4752f4ac
commit c53e8cbf9d
7 changed files with 83 additions and 4 deletions

View File

@ -20,8 +20,11 @@ SELECT
O.[MaxStorageGb],
OU.[Key],
OU.[Status],
OU.[Type]
OU.[Type],
SU.[ExternalId] SsoExternalId
FROM
[dbo].[OrganizationUser] OU
INNER JOIN
[dbo].[Organization] O ON O.[Id] = OU.[OrganizationId]
[dbo].[Organization] O ON O.[Id] = OU.[OrganizationId]
LEFT JOIN
[dbo].[SsoUser] SU ON SU.[UserId] = OU.[UserId] AND SU.[OrganizationId] = OU.[OrganizationId]

View File

@ -11,8 +11,11 @@ SELECT
OU.[Status],
OU.[Type],
OU.[AccessAll],
OU.[ExternalId]
OU.[ExternalId],
SU.[ExternalId] SsoExternalId
FROM
[dbo].[OrganizationUser] OU
LEFT JOIN
[dbo].[User] U ON U.[Id] = OU.[UserId]
[dbo].[User] U ON U.[Id] = OU.[UserId]
LEFT JOIN
[dbo].[SsoUser] SU ON SU.[UserId] = OU.[UserId] AND SU.[OrganizationId] = OU.[OrganizationId]