Skip to content

armgit / dub

Public Imported from GitHub
0

The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.

fix timezone issue

Steven Tey05158f50fe61
diff --git a/apps/web/app/(ee)/admin.dub.co/(dashboard)/revenue/page.tsx b/apps/web/app/(ee)/admin.dub.co/(dashboard)/revenue/page.tsx
index a041a9f853..3da96e5c97 100644
--- a/apps/web/app/(ee)/admin.dub.co/(dashboard)/revenue/page.tsx
+++ b/apps/web/app/(ee)/admin.dub.co/(dashboard)/revenue/page.tsx
@@ -214,7 +214,10 @@ function RevenuePageClient() {
</button>
))}
</div>
- <div className="p-5 sm:p-10">
+ <div className="relative p-5 sm:p-10">
+ <span className="absolute right-10 top-5 rounded-md border border-neutral-200 bg-neutral-50 px-2 py-1 text-xs text-neutral-600">
+ All times in UTC
+ </span>
<div className="flex h-96 w-full items-center justify-center">
{chartData ? (
chartData.length > 0 ? (
diff --git a/apps/web/app/(ee)/api/admin/revenue/get-mrr-timeseries.ts b/apps/web/app/(ee)/api/admin/revenue/get-mrr-timeseries.ts
index bf8020ec49..69381501f2 100644
--- a/apps/web/app/(ee)/api/admin/revenue/get-mrr-timeseries.ts
+++ b/apps/web/app/(ee)/api/admin/revenue/get-mrr-timeseries.ts
@@ -77,6 +77,7 @@ export async function getMrrByBucket({
ends_at: min([endDate, new Date()]),
granularity: getStripeGranularity({ granularity, startDate, endDate }),
currency: "usd",
+ timezone: "UTC",
}),
},
);