Add missing "payment never made" subscription status to superadmin org list (#2457)
This commit is contained in:
parent
fa05d68292
commit
8078f3866b
@ -703,6 +703,17 @@ export class OrgsList extends BtrixElement {
|
||||
description: msg("Canceled"),
|
||||
};
|
||||
break;
|
||||
case SubscriptionStatus.PaymentNeverMade:
|
||||
subscription = {
|
||||
icon: html`<sl-icon
|
||||
class="text-base text-neutral-400"
|
||||
name="dash-square-fill"
|
||||
label=${msg("Payment Never Made")}
|
||||
>
|
||||
</sl-icon>`,
|
||||
description: msg("Payment Never Made"),
|
||||
};
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
@ -22,6 +22,7 @@ export function computeStats(orgData: OrgData[] = []) {
|
||||
trialing: 0,
|
||||
trialingCancelled: 0,
|
||||
pausedPaymentFailed: 0,
|
||||
paymentNeverMade: 0,
|
||||
cancelled: 0,
|
||||
};
|
||||
|
||||
@ -50,6 +51,9 @@ export function computeStats(orgData: OrgData[] = []) {
|
||||
case SubscriptionStatus.PausedPaymentFailed:
|
||||
subscriptions.pausedPaymentFailed++;
|
||||
break;
|
||||
case SubscriptionStatus.PaymentNeverMade:
|
||||
subscriptions.paymentNeverMade++;
|
||||
break;
|
||||
case SubscriptionStatus.Cancelled:
|
||||
subscriptions.cancelled++;
|
||||
break;
|
||||
@ -164,6 +168,12 @@ export class Component extends BtrixElement {
|
||||
subscriptions.pausedPaymentFailed,
|
||||
)}`}</span
|
||||
>
|
||||
${msg("Payment never made")}:
|
||||
<span class="text-left font-bold text-white"
|
||||
>${html`${this.localize.number(
|
||||
subscriptions.paymentNeverMade,
|
||||
)}`}</span
|
||||
>
|
||||
${msg("Cancelled subscriptions")}:
|
||||
<span class="text-left font-bold text-white"
|
||||
>${html`${this.localize.number(subscriptions.cancelled)}`}</span
|
||||
|
@ -7,6 +7,7 @@ export enum SubscriptionStatus {
|
||||
Trialing = "trialing",
|
||||
TrialingCanceled = "trialing_canceled",
|
||||
PausedPaymentFailed = "paused_payment_failed",
|
||||
PaymentNeverMade = "payment_never_made",
|
||||
Cancelled = "cancelled",
|
||||
}
|
||||
export const subscriptionStatusSchema = z.nativeEnum(SubscriptionStatus);
|
||||
|
Loading…
Reference in New Issue
Block a user