fix: round revenue calculation in AnalyticSchema
Some checks failed
CI / build (push) Has been cancelled

- Added logic to round the revenue value to the nearest whole number before returning the analytic data.
- This change aims to ensure that revenue figures are presented in a more user-friendly format, enhancing clarity in analytic reports.
This commit is contained in:
2025-01-18 21:26:06 +07:00
parent 0117d81818
commit 11221b5702

View File

@@ -461,6 +461,8 @@ export class AnalyticSchema extends PothosSchema {
revenue += actualRevenue;
}
}
// round revenue to number
revenue = Math.round(revenue);
// return analytic
return {
topServices: topServices,