add event type to getWebsiteStats

pull/1921/head
Francis Cao 2023-04-19 09:13:16 -07:00
parent 083a9ffc2c
commit 2cd1f5541b
1 changed files with 2 additions and 1 deletions

View File

@ -41,7 +41,8 @@ async function relationalQuery(
join website join website
on website_event.website_id = website.website_id on website_event.website_id = website.website_id
${joinSession} ${joinSession}
where website.website_id = $1${toUuid()} where event_type = ${EVENT_TYPE.pageView}
and website.website_id = $1${toUuid()}
and website_event.created_at >= $2 and website_event.created_at >= $2
and website_event.created_at between $3 and $4 and website_event.created_at between $3 and $4
${filterQuery} ${filterQuery}