mirror of
https://github.com/kremalicious/umami.git
synced 2024-11-15 17:55:08 +01:00
Merge remote-tracking branch 'origin/dev' into dev
This commit is contained in:
commit
10e82a9ef6
@ -158,11 +158,7 @@ export async function createSession(website_id, data) {
|
||||
return runQuery(
|
||||
prisma.session.create({
|
||||
data: {
|
||||
website: {
|
||||
connect: {
|
||||
website_id,
|
||||
},
|
||||
},
|
||||
website_id,
|
||||
...data,
|
||||
},
|
||||
select: {
|
||||
@ -186,16 +182,8 @@ export async function savePageView(website_id, session_id, url, referrer) {
|
||||
return runQuery(
|
||||
prisma.pageview.create({
|
||||
data: {
|
||||
website: {
|
||||
connect: {
|
||||
website_id,
|
||||
},
|
||||
},
|
||||
session: {
|
||||
connect: {
|
||||
session_id,
|
||||
},
|
||||
},
|
||||
website_id,
|
||||
session_id,
|
||||
url: url.substr(0, URL_LENGTH),
|
||||
referrer: referrer.substr(0, URL_LENGTH),
|
||||
},
|
||||
@ -207,16 +195,8 @@ export async function saveEvent(website_id, session_id, url, event_type, event_v
|
||||
return runQuery(
|
||||
prisma.event.create({
|
||||
data: {
|
||||
website: {
|
||||
connect: {
|
||||
website_id,
|
||||
},
|
||||
},
|
||||
session: {
|
||||
connect: {
|
||||
session_id,
|
||||
},
|
||||
},
|
||||
website_id,
|
||||
session_id,
|
||||
url: url.substr(0, URL_LENGTH),
|
||||
event_type,
|
||||
event_value,
|
||||
|
Loading…
Reference in New Issue
Block a user