Made filters work for all reports.
This commit is contained in:
@@ -15,6 +15,7 @@ export async function POST(request: Request) {
|
||||
websiteId,
|
||||
dateRange: { startDate, endDate, unit },
|
||||
parameters: { currency },
|
||||
...filters
|
||||
} = body;
|
||||
|
||||
if (!(await canViewWebsite(auth, websiteId))) {
|
||||
@@ -22,6 +23,7 @@ export async function POST(request: Request) {
|
||||
}
|
||||
|
||||
const data = await getRevenue(websiteId, {
|
||||
...filters,
|
||||
startDate: new Date(startDate),
|
||||
endDate: new Date(endDate),
|
||||
unit,
|
||||
|
||||
Reference in New Issue
Block a user