mirror of
https://github.com/kremalicious/umami.git
synced 2024-12-24 02:06:19 +01:00
More resetDate conversion.
This commit is contained in:
parent
e63591e35d
commit
03ba225587
@ -47,7 +47,7 @@ async function relationalQuery(
|
||||
) {
|
||||
const { toUuid, rawQuery, getDateQuery, getFilterQuery } = prisma;
|
||||
const website = await loadWebsite(websiteId);
|
||||
const resetDate = website?.resetAt || website?.createdAt;
|
||||
const resetDate = new Date(website?.resetAt || website?.createdAt);
|
||||
const params: any = [websiteId, resetDate, startDate, endDate];
|
||||
const filterQuery = getFilterQuery(filters, params);
|
||||
|
||||
@ -89,7 +89,7 @@ async function clickhouseQuery(
|
||||
) {
|
||||
const { rawQuery, getDateQuery, getDateFormat, getBetweenDates, getFilterQuery } = clickhouse;
|
||||
const website = await loadWebsite(websiteId);
|
||||
const resetDate = website?.resetAt || website?.createdAt;
|
||||
const resetDate = new Date(website?.resetAt || website?.createdAt);
|
||||
const params = { websiteId };
|
||||
|
||||
return rawQuery(
|
||||
|
@ -49,7 +49,7 @@ async function relationalQuery(
|
||||
const { startDate, endDate, timeSeries, eventName, urlPath, filters } = data;
|
||||
const { toUuid, rawQuery, getEventDataFilterQuery, getDateQuery } = prisma;
|
||||
const website = await loadWebsite(websiteId);
|
||||
const resetDate = website?.resetAt || website?.createdAt;
|
||||
const resetDate = new Date(website?.resetAt || website?.createdAt);
|
||||
const params: any = [websiteId, resetDate, startDate, endDate, eventName || ''];
|
||||
|
||||
return rawQuery(
|
||||
@ -99,7 +99,7 @@ async function clickhouseQuery(
|
||||
const { rawQuery, getDateFormat, getBetweenDates, getDateQuery, getEventDataFilterQuery } =
|
||||
clickhouse;
|
||||
const website = await loadWebsite(websiteId);
|
||||
const resetDate = website?.resetAt || website?.createdAt;
|
||||
const resetDate = new Date(website?.resetAt || website?.createdAt);
|
||||
const params = { websiteId };
|
||||
|
||||
return rawQuery(
|
||||
|
@ -33,7 +33,7 @@ async function relationalQuery(
|
||||
const { startDate, endDate, filters = {}, column } = criteria;
|
||||
const { rawQuery, parseFilters, toUuid } = prisma;
|
||||
const website = await loadWebsite(websiteId);
|
||||
const resetDate = website?.resetAt || website?.createdAt;
|
||||
const resetDate = new Date(website?.resetAt || website?.createdAt);
|
||||
const params: any = [
|
||||
websiteId,
|
||||
resetDate,
|
||||
@ -80,7 +80,7 @@ async function clickhouseQuery(
|
||||
const { startDate, endDate, filters = {}, column } = criteria;
|
||||
const { rawQuery, getDateFormat, parseFilters, getBetweenDates } = clickhouse;
|
||||
const website = await loadWebsite(websiteId);
|
||||
const resetDate = website?.resetAt || website?.createdAt;
|
||||
const resetDate = new Date(website?.resetAt || website?.createdAt);
|
||||
const params = {
|
||||
websiteId,
|
||||
eventType: column === 'event_name' ? EVENT_TYPE.customEvent : EVENT_TYPE.pageView,
|
||||
|
@ -47,7 +47,7 @@ async function relationalQuery(
|
||||
} = criteria;
|
||||
const { toUuid, getDateQuery, parseFilters, rawQuery } = prisma;
|
||||
const website = await loadWebsite(websiteId);
|
||||
const resetDate = website?.resetAt || website?.createdAt;
|
||||
const resetDate = new Date(website?.resetAt || website?.createdAt);
|
||||
const params: any = [websiteId, resetDate, startDate, endDate];
|
||||
const { filterQuery, joinSession } = parseFilters(filters, params);
|
||||
|
||||
@ -95,7 +95,7 @@ async function clickhouseQuery(
|
||||
getBetweenDates,
|
||||
} = clickhouse;
|
||||
const website = await loadWebsite(websiteId);
|
||||
const resetDate = website?.resetAt || website?.createdAt;
|
||||
const resetDate = new Date(website?.resetAt || website?.createdAt);
|
||||
const params = { websiteId };
|
||||
const { filterQuery } = parseFilters(filters, params);
|
||||
|
||||
|
@ -21,7 +21,7 @@ async function relationalQuery(
|
||||
criteria: { startDate: Date; endDate: Date; column: string; filters: object },
|
||||
) {
|
||||
const website = await loadWebsite(websiteId);
|
||||
const resetDate = website?.resetAt || website?.createdAt;
|
||||
const resetDate = new Date(website?.resetAt || website?.createdAt);
|
||||
const { startDate, endDate, column, filters = {} } = criteria;
|
||||
const { toUuid, parseFilters, rawQuery } = prisma;
|
||||
const params: any = [websiteId, resetDate, startDate, endDate];
|
||||
@ -55,7 +55,7 @@ async function clickhouseQuery(
|
||||
const { startDate, endDate, column, filters = {} } = data;
|
||||
const { getDateFormat, parseFilters, getBetweenDates, rawQuery } = clickhouse;
|
||||
const website = await loadWebsite(websiteId);
|
||||
const resetDate = website?.resetAt || website?.createdAt;
|
||||
const resetDate = new Date(website?.resetAt || website?.createdAt);
|
||||
const params = { websiteId };
|
||||
const { filterQuery } = parseFilters(filters, params);
|
||||
|
||||
|
@ -59,7 +59,7 @@ async function clickhouseQuery(
|
||||
const { startDate, endDate, filters = {} } = criteria;
|
||||
const { rawQuery, getDateFormat, getDateQuery, getBetweenDates, parseFilters } = clickhouse;
|
||||
const website = await loadWebsite(websiteId);
|
||||
const resetDate = website?.resetAt || website?.createdAt;
|
||||
const resetDate = new Date(website?.resetAt || website?.createdAt);
|
||||
const params = { websiteId };
|
||||
const { filterQuery } = parseFilters(filters, params);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user