From 33b69307f43aca92d9dffcce94f15d7aa1f87430 Mon Sep 17 00:00:00 2001 From: Rui Tome Date: Tue, 28 Nov 2023 13:54:57 +0000 Subject: [PATCH] [AC-1139] Added back the deprecation of methods canEditAssignedCollections, canDeleteAssignedCollections, canViewAssignedCollections --- .../admin-console/models/domain/organization.ts | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/libs/common/src/admin-console/models/domain/organization.ts b/libs/common/src/admin-console/models/domain/organization.ts index 802fe6fcf8c..25dd35cf2b9 100644 --- a/libs/common/src/admin-console/models/domain/organization.ts +++ b/libs/common/src/admin-console/models/domain/organization.ts @@ -184,14 +184,29 @@ export class Organization { return this.canEditAnyCollection || this.canDeleteAnyCollection; } + /** + * @deprecated + * This is deprecated with the introduction of Flexible Collections. + * This will always return false if FlexibleCollections flag is on. + */ get canEditAssignedCollections() { return this.isManager || this.permissions.editAssignedCollections; } + /** + * @deprecated + * This is deprecated with the introduction of Flexible Collections. + * This will always return false if FlexibleCollections flag is on. + */ get canDeleteAssignedCollections() { return this.isManager || this.permissions.deleteAssignedCollections; } + /** + * @deprecated + * This is deprecated with the introduction of Flexible Collections. + * This will always return false if FlexibleCollections flag is on. + */ get canViewAssignedCollections() { return this.canDeleteAssignedCollections || this.canEditAssignedCollections; }