From 5468b7ccda5943b4c7b5732b68bbbdeafdfb217a Mon Sep 17 00:00:00 2001 From: Loewy Date: Tue, 12 Nov 2024 13:00:18 -0800 Subject: [PATCH] add createdAt dateRangeFilter --- src/index.tsx | 6 ++++-- src/operations/user.gql | 4 ++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/index.tsx b/src/index.tsx index b4b8e80..07186aa 100644 --- a/src/index.tsx +++ b/src/index.tsx @@ -3322,6 +3322,7 @@ export type GetLoggedInUserQuery = { export type GetUserPlayTimeQueryVariables = Exact<{ userId: Scalars["Int"]["input"]; + filters?: InputMaybe; }>; export type GetUserPlayTimeQuery = { @@ -5620,8 +5621,8 @@ export type GetLoggedInUserQueryResult = Apollo.QueryResult< GetLoggedInUserQueryVariables >; export const GetUserPlayTimeDocument = gql` - query GetUserPlayTime($userId: Int!) { - getPlayTime(userId: $userId) { + query GetUserPlayTime($userId: Int!, $filters: VideoFilterInput) { + getPlayTime(userId: $userId, filters: $filters) { totalSeconds } } @@ -5640,6 +5641,7 @@ export const GetUserPlayTimeDocument = gql` * const { data, loading, error } = useGetUserPlayTimeQuery({ * variables: { * userId: // value for 'userId' + * filters: // value for 'filters' * }, * }); */ diff --git a/src/operations/user.gql b/src/operations/user.gql index e00eb54..e5e597b 100644 --- a/src/operations/user.gql +++ b/src/operations/user.gql @@ -45,8 +45,8 @@ query getLoggedInUser { } } -query GetUserPlayTime($userId: Int!) { - getPlayTime(userId: $userId) { +query GetUserPlayTime($userId: Int!, $filters: VideoFilterInput) { + getPlayTime(userId: $userId, filters: $filters) { totalSeconds } }