fix: zero month addition (#1733)

- Add zero month at the begining of each metric on the open page
This commit is contained in:
Ephraim Duncan
2025-04-01 11:12:41 +00:00
committed by GitHub
parent da71613c9f
commit 5e4956f3a2
5 changed files with 132 additions and 24 deletions

View File

@ -2,6 +2,8 @@ import { DateTime } from 'luxon';
import { kyselyPrisma, sql } from '@documenso/prisma';
import { addZeroMonth } from '../add-zero-month';
export const getSignerConversionMonthly = async (type: 'count' | 'cumulative' = 'count') => {
const qb = kyselyPrisma.$kysely
.selectFrom('Recipient')
@ -34,7 +36,7 @@ export const getSignerConversionMonthly = async (type: 'count' | 'cumulative' =
],
};
return transformedData;
return addZeroMonth(transformedData);
};
export type GetSignerConversionMonthlyResult = Awaited<