fix usage.
This commit is contained in:
@@ -6,8 +6,9 @@ import { getAllUserWebsitesIncludingTeamOwner, getEventDataUsage, getEventUsage
|
|||||||
import * as yup from 'yup';
|
import * as yup from 'yup';
|
||||||
|
|
||||||
export interface UserUsageRequestQuery {
|
export interface UserUsageRequestQuery {
|
||||||
id: string;
|
userId: string;
|
||||||
params: { startAt: string; endAt: string };
|
startAt: string;
|
||||||
|
endAt: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface UserUsageRequestResponse {
|
export interface UserUsageRequestResponse {
|
||||||
@@ -44,7 +45,7 @@ export default async (
|
|||||||
return unauthorized(res);
|
return unauthorized(res);
|
||||||
}
|
}
|
||||||
|
|
||||||
const { id: userId, startAt, endAt } = req.query;
|
const { userId, startAt, endAt } = req.query;
|
||||||
|
|
||||||
const startDate = new Date(+startAt);
|
const startDate = new Date(+startAt);
|
||||||
const endDate = new Date(+endAt);
|
const endDate = new Date(+endAt);
|
||||||
|
|||||||
Reference in New Issue
Block a user