mirror of
https://github.com/bitwarden/server
synced 2026-01-05 10:03:23 +00:00
Fix conflicting group permissions (#1473)
* Return collection with highest permission levels
* Revert "Return collection with highest permission levels"
This reverts commit 06e0f3b73e.
* Combine duplicate collectionDetails
* Update EF to combine duplicate CollectionDetails
* Delete unneeded using statements
This commit is contained in:
@@ -4,12 +4,24 @@
|
||||
AS
|
||||
BEGIN
|
||||
SET NOCOUNT ON
|
||||
SELECT TOP 1
|
||||
*
|
||||
SELECT
|
||||
Id,
|
||||
OrganizationId,
|
||||
[Name],
|
||||
CreationDate,
|
||||
RevisionDate,
|
||||
ExternalId,
|
||||
MIN([ReadOnly]) AS [ReadOnly],
|
||||
MIN([HidePasswords]) AS [HidePasswords]
|
||||
FROM
|
||||
[dbo].[UserCollectionDetails](@UserId)
|
||||
WHERE
|
||||
[Id] = @Id
|
||||
ORDER BY
|
||||
[ReadOnly] ASC
|
||||
END
|
||||
GROUP BY
|
||||
Id,
|
||||
OrganizationId,
|
||||
[Name],
|
||||
CreationDate,
|
||||
RevisionDate,
|
||||
ExternalId
|
||||
END
|
||||
|
||||
@@ -5,7 +5,21 @@ BEGIN
|
||||
SET NOCOUNT ON
|
||||
|
||||
SELECT
|
||||
*
|
||||
Id,
|
||||
OrganizationId,
|
||||
[Name],
|
||||
CreationDate,
|
||||
RevisionDate,
|
||||
ExternalId,
|
||||
MIN([ReadOnly]) AS [ReadOnly],
|
||||
MIN([HidePasswords]) AS [HidePasswords]
|
||||
FROM
|
||||
[dbo].[UserCollectionDetails](@UserId)
|
||||
END
|
||||
GROUP BY
|
||||
Id,
|
||||
OrganizationId,
|
||||
[Name],
|
||||
CreationDate,
|
||||
RevisionDate,
|
||||
ExternalId
|
||||
END
|
||||
|
||||
Reference in New Issue
Block a user