From 7f4741f464610eeb123cdb6107596f6c5db73739 Mon Sep 17 00:00:00 2001 From: Robyn MacCallum Date: Fri, 4 Aug 2023 10:04:53 -0400 Subject: [PATCH] Remove provider orgs from org dropdown in the collection dialog (#5941) --- .../collection-dialog/collection-dialog.component.ts | 2 +- apps/web/src/app/vault/individual-vault/vault.component.ts | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/apps/web/src/app/vault/components/collection-dialog/collection-dialog.component.ts b/apps/web/src/app/vault/components/collection-dialog/collection-dialog.component.ts index 74b7d0fdd35..1a1d0e645b2 100644 --- a/apps/web/src/app/vault/components/collection-dialog/collection-dialog.component.ts +++ b/apps/web/src/app/vault/components/collection-dialog/collection-dialog.component.ts @@ -110,7 +110,7 @@ export class CollectionDialogComponent implements OnInit, OnDestroy { this.organizations$ = this.organizationService.organizations$.pipe( map((orgs) => orgs - .filter((o) => o.canCreateNewCollections) + .filter((o) => o.canCreateNewCollections && !o.isProviderUser) .sort(Utils.getSortFunction(this.i18nService, "name")) ) ); diff --git a/apps/web/src/app/vault/individual-vault/vault.component.ts b/apps/web/src/app/vault/individual-vault/vault.component.ts index fc3f2165cdb..00e26b305de 100644 --- a/apps/web/src/app/vault/individual-vault/vault.component.ts +++ b/apps/web/src/app/vault/individual-vault/vault.component.ts @@ -385,7 +385,9 @@ export class VaultComponent implements OnInit, OnDestroy { this.collections = collections; this.selectedCollection = selectedCollection; - this.canCreateCollections = allOrganizations?.some((o) => o.canCreateNewCollections); + this.canCreateCollections = allOrganizations?.some( + (o) => o.canCreateNewCollections && !o.isProviderUser + ); this.showBulkMove = filter.type !== "trash" &&