1
0
mirror of https://github.com/bitwarden/browser.git synced 2024-12-27 17:18:04 +01:00

[EC-151] Hide Subscription/Billing information for Provider-managed organizations (#777)

* add canManageBilling permission and hasProvider helper method
This commit is contained in:
Thomas Rittson 2022-05-06 06:24:40 +10:00 committed by GitHub
parent 80c834b52a
commit 52321c51cc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 9 additions and 0 deletions

View File

@ -24,4 +24,5 @@ export enum Permissions {
EditAssignedCollections,
DeleteAssignedCollections,
ManageSso,
ManageBilling,
}

View File

@ -181,4 +181,12 @@ export class Organization {
get isExemptFromPolicies() {
return this.canManagePolicies;
}
get canManageBilling() {
return this.isOwner && (this.isProviderUser || !this.hasProvider);
}
get hasProvider() {
return this.providerId != null || this.providerName != null;
}
}