mirror of
https://github.com/bitwarden/server.git
synced 2025-05-05 11:42:22 -05:00

* Return collection with highest permission levels * Revert "Return collection with highest permission levels" This reverts commit 06e0f3b73e3d8f05f14849da4d0d8a1e9c6c6d58. * Combine duplicate collectionDetails * Update EF to combine duplicate CollectionDetails * Delete unneeded using statements
28 lines
568 B
Transact-SQL
28 lines
568 B
Transact-SQL
CREATE PROCEDURE [dbo].[Collection_ReadByIdUserId]
|
|
@Id UNIQUEIDENTIFIER,
|
|
@UserId UNIQUEIDENTIFIER
|
|
AS
|
|
BEGIN
|
|
SET NOCOUNT ON
|
|
SELECT
|
|
Id,
|
|
OrganizationId,
|
|
[Name],
|
|
CreationDate,
|
|
RevisionDate,
|
|
ExternalId,
|
|
MIN([ReadOnly]) AS [ReadOnly],
|
|
MIN([HidePasswords]) AS [HidePasswords]
|
|
FROM
|
|
[dbo].[UserCollectionDetails](@UserId)
|
|
WHERE
|
|
[Id] = @Id
|
|
GROUP BY
|
|
Id,
|
|
OrganizationId,
|
|
[Name],
|
|
CreationDate,
|
|
RevisionDate,
|
|
ExternalId
|
|
END
|