mirror of
https://github.com/bitwarden/browser
synced 2025-12-15 15:53:27 +00:00
[AC-2774] [AC-2781] Consolidated issues for Consolidated Billing (#9717)
* Rename provider client components for brevity * Make purchased seats dynamic on create client component * Fix access and empty state for service users * Refactor manage client subscription dialog * Fixed manage subscription dialog errors * Make unassigned seats dynamic for create client dialog * Expanded invoice statuses * Update invoice header on invoices component
This commit is contained in:
@@ -7,7 +7,7 @@ import { ConfigService } from "@bitwarden/common/platform/abstractions/config/co
|
||||
|
||||
type MaybeProvider = Provider | undefined;
|
||||
|
||||
export const canAccessBilling = (
|
||||
export const hasConsolidatedBilling = (
|
||||
configService: ConfigService,
|
||||
): OperatorFunction<MaybeProvider, boolean> =>
|
||||
switchMap<MaybeProvider, Observable<boolean>>((provider) =>
|
||||
@@ -16,9 +16,7 @@ export const canAccessBilling = (
|
||||
.pipe(
|
||||
map((consolidatedBillingEnabled) =>
|
||||
provider
|
||||
? provider.isProviderAdmin &&
|
||||
provider.providerStatus === ProviderStatusType.Billable &&
|
||||
consolidatedBillingEnabled
|
||||
? provider.providerStatus === ProviderStatusType.Billable && consolidatedBillingEnabled
|
||||
: false,
|
||||
),
|
||||
),
|
||||
|
||||
@@ -18,6 +18,7 @@ export class InvoiceResponse extends BaseResponse {
|
||||
number: string;
|
||||
total: number;
|
||||
status: string;
|
||||
dueDate: string;
|
||||
url: string;
|
||||
pdfUrl: string;
|
||||
|
||||
@@ -28,6 +29,7 @@ export class InvoiceResponse extends BaseResponse {
|
||||
this.number = this.getResponseProperty("Number");
|
||||
this.total = this.getResponseProperty("Total");
|
||||
this.status = this.getResponseProperty("Status");
|
||||
this.dueDate = this.getResponseProperty("DueDate");
|
||||
this.url = this.getResponseProperty("Url");
|
||||
this.pdfUrl = this.getResponseProperty("PdfUrl");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user