mirror of
https://github.com/umami-software/umami.git
synced 2026-02-10 23:57:12 +01:00
fix retention report dates and days
This commit is contained in:
parent
ef98ceac2f
commit
ff0c825a7b
2 changed files with 3 additions and 3 deletions
|
|
@ -58,7 +58,7 @@ export function RetentionTable({ days = DAYS }) {
|
||||||
if (totalDays - rowIndex < day) {
|
if (totalDays - rowIndex < day) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
const percentage = records[day]?.percentage;
|
const percentage = records.filter(a => a.day === day)[0]?.percentage;
|
||||||
return (
|
return (
|
||||||
<div
|
<div
|
||||||
key={day}
|
key={day}
|
||||||
|
|
|
||||||
|
|
@ -110,7 +110,7 @@ async function clickhouseQuery(
|
||||||
}[]
|
}[]
|
||||||
> {
|
> {
|
||||||
const { startDate, endDate, timezone = 'UTC' } = filters;
|
const { startDate, endDate, timezone = 'UTC' } = filters;
|
||||||
const { getDateSQL, getDateStringSQL, rawQuery } = clickhouse;
|
const { getDateSQL, rawQuery } = clickhouse;
|
||||||
const unit = 'day';
|
const unit = 'day';
|
||||||
|
|
||||||
return rawQuery(
|
return rawQuery(
|
||||||
|
|
@ -152,7 +152,7 @@ async function clickhouseQuery(
|
||||||
group by 1, 2
|
group by 1, 2
|
||||||
)
|
)
|
||||||
select
|
select
|
||||||
${getDateStringSQL('c.cohort_date', unit)} as date,
|
c.cohort_date as date,
|
||||||
c.day_number as day,
|
c.day_number as day,
|
||||||
s.visitors as visitors,
|
s.visitors as visitors,
|
||||||
c.visitors returnVisitors,
|
c.visitors returnVisitors,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue