1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-15 15:53:27 +00:00

[PM-13187] Hide "Assign To Collections" when the user has no orgs (#11668)

* web - hide assign to collections button when the user has no organizations

* browser - hide assign to collections button when the user has no organizations

* hide assign to collections in the bulk edit menu when the user doesn't belong to an organization
This commit is contained in:
Nick Krantz
2024-10-24 10:30:46 -05:00
committed by GitHub
parent 548abfe906
commit 44e182e32e
4 changed files with 18 additions and 4 deletions

View File

@@ -92,7 +92,7 @@ export class VaultCipherRowComponent implements OnInit {
}
protected get showAssignToCollections() {
return this.canEditCipher && !this.cipher.isDeleted;
return this.organizations?.length && this.canEditCipher && !this.cipher.isDeleted;
}
protected get showClone() {

View File

@@ -299,6 +299,11 @@ export class VaultItemsComponent {
return false;
}
// When the user doesn't belong to an organization, hide assign to collections
if (this.allOrganizations.length === 0) {
return false;
}
if (this.selection.selected.length === 0) {
return true;
}