From 8c0411dc207bb0c5c58932b9f5a686cf7e03286f Mon Sep 17 00:00:00 2001 From: Jaanus Sellin <sellinjaanus@gmail.com> Date: Fri, 3 Mar 2023 14:31:27 +0200 Subject: [PATCH] feat: invoices created date (#3250) --- .../BillingPlan/BillingPlan.tsx | 17 +++++++++-------- .../billing/BillingHistory/BillingHistory.tsx | 12 ++++++++---- 2 files changed, 17 insertions(+), 12 deletions(-) diff --git a/frontend/src/component/admin/billing/BillingDashboard/BillingPlan/BillingPlan.tsx b/frontend/src/component/admin/billing/BillingDashboard/BillingPlan/BillingPlan.tsx index 2fb1514e82..d5e67e046c 100644 --- a/frontend/src/component/admin/billing/BillingDashboard/BillingPlan/BillingPlan.tsx +++ b/frontend/src/component/admin/billing/BillingDashboard/BillingPlan/BillingPlan.tsx @@ -162,16 +162,19 @@ export const BillingPlan: FC<IBillingPlanProps> = ({ instanceStatus }) => { marginBottom: theme.spacing(1.5), })} > - <GridCol> + <GridCol vertical> <Typography> - <strong>{seats}</strong> team - members + <strong>Included members</strong> <GridColLink> <Link to="/admin/users"> - {freeAssigned} assigned + {freeAssigned} of 5 assigned </Link> </GridColLink> </Typography> + <StyledInfoLabel> + You have 5 team members included in + your PRO plan + </StyledInfoLabel> </GridCol> <GridCol> <StyledCheckIcon /> @@ -183,7 +186,7 @@ export const BillingPlan: FC<IBillingPlanProps> = ({ instanceStatus }) => { <GridRow> <GridCol vertical> <Typography> - Paid members + <strong>Paid members</strong> <GridColLink> <Link to="/admin/users"> {paidAssigned} assigned @@ -191,9 +194,7 @@ export const BillingPlan: FC<IBillingPlanProps> = ({ instanceStatus }) => { </GridColLink> </Typography> <StyledInfoLabel> - Add up to 15 extra paid members - $ - {price.user} - /month per member + $15/month per paid member </StyledInfoLabel> </GridCol> <GridCol> diff --git a/frontend/src/component/admin/billing/BillingHistory/BillingHistory.tsx b/frontend/src/component/admin/billing/BillingHistory/BillingHistory.tsx index 373f8cf4c6..6364975d41 100644 --- a/frontend/src/component/admin/billing/BillingHistory/BillingHistory.tsx +++ b/frontend/src/component/admin/billing/BillingHistory/BillingHistory.tsx @@ -37,9 +37,13 @@ const columns = [ disableGlobalFilter: true, }, { - Header: 'Due date', - accessor: 'dueDate', - Cell: DateCell, + Header: 'Created date', + accessor: 'created', + Cell: ({ value }: { value: number }) => { + return ( + <DateCell value={value ? new Date(value * 1000) : undefined} /> + ); + }, sortType: 'date', disableGlobalFilter: true, }, @@ -69,7 +73,7 @@ export const BillingHistory: VFC<IBillingHistoryProps> = ({ }) => { const initialState = useMemo( () => ({ - sortBy: [{ id: 'dueDate' }], + sortBy: [{ id: 'created' }], }), [] );