mirror of
https://github.com/kremalicious/umami.git
synced 2024-11-15 17:55:08 +01:00
Merge pull request #1329 from Maxime-J/mysql-fix
follow-up - reverted getDateQuery logic
This commit is contained in:
commit
6f92677f10
@ -22,7 +22,7 @@ npm install -g yarn
|
||||
### Get the source code and install packages
|
||||
|
||||
```
|
||||
git clone https://github.com/mikecao/umami.git
|
||||
git clone https://github.com/umami-software/umami.git
|
||||
cd umami
|
||||
yarn install
|
||||
```
|
||||
|
2
app.json
2
app.json
@ -3,7 +3,7 @@
|
||||
"description": "Umami is a simple, fast, website analytics alternative to Google Analytics.",
|
||||
"keywords": ["analytics", "charts", "statistics", "web-analytics"],
|
||||
"website": "https://umami.is",
|
||||
"repository": "https://github.com/mikecao/umami",
|
||||
"repository": "https://github.com/umami-software/umami",
|
||||
"addons": ["heroku-postgresql"],
|
||||
"env": {
|
||||
"HASH_SALT": {
|
||||
|
@ -2,7 +2,7 @@
|
||||
version: '3'
|
||||
services:
|
||||
umami:
|
||||
image: ghcr.io/mikecao/umami:postgresql-latest
|
||||
image: ghcr.io/umami-software/umami:postgresql-latest
|
||||
ports:
|
||||
- "3000:3000"
|
||||
environment:
|
||||
|
@ -21,7 +21,7 @@ export function getDateQuery(field, unit, timezone) {
|
||||
if (timezone) {
|
||||
return `to_char(date_trunc('${unit}', ${field} at time zone '${timezone}'), '${POSTGRESQL_DATE_FORMATS[unit]}')`;
|
||||
}
|
||||
return `date_trunc('${unit}', ${field})`;
|
||||
return `to_char(date_trunc('${unit}', ${field}), '${POSTGRESQL_DATE_FORMATS[unit]}')`;
|
||||
}
|
||||
|
||||
if (db === MYSQL) {
|
||||
@ -31,7 +31,7 @@ export function getDateQuery(field, unit, timezone) {
|
||||
return `date_format(convert_tz(${field},'+00:00','${tz}'), '${MYSQL_DATE_FORMATS[unit]}')`;
|
||||
}
|
||||
|
||||
return `${field}`;
|
||||
return `date_format(${field}, '${MYSQL_DATE_FORMATS[unit]}')`;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "umami",
|
||||
"version": "1.34.0",
|
||||
"version": "1.35.0",
|
||||
"description": "A simple, fast, privacy-focused alternative to Google Analytics.",
|
||||
"author": "Mike Cao <mike@mikecao.com>",
|
||||
"license": "MIT",
|
||||
|
Loading…
Reference in New Issue
Block a user