This commit is contained in:
@@ -722,10 +722,11 @@ final class AccountPages
|
|||||||
$stmt = $pdo?->prepare(
|
$stmt = $pdo?->prepare(
|
||||||
'SELECT e.id, e.title, e.teaser_public, e.image_path, e.starts_at, e.city, e.visibility, e.status,
|
'SELECT e.id, e.title, e.teaser_public, e.image_path, e.starts_at, e.city, e.visibility, e.status,
|
||||||
ep.status AS participation_status,
|
ep.status AS participation_status,
|
||||||
u.display_name AS host_name
|
COALESCE(up.display_name, "Mitglied") AS host_name
|
||||||
FROM event_participants ep
|
FROM event_participants ep
|
||||||
INNER JOIN events e ON e.id = ep.event_id
|
INNER JOIN events e ON e.id = ep.event_id
|
||||||
INNER JOIN users u ON u.id = e.created_by
|
INNER JOIN users u ON u.id = e.created_by
|
||||||
|
LEFT JOIN user_profiles up ON up.user_id = u.id
|
||||||
WHERE ep.user_id = :id AND e.created_by <> :id AND e.starts_at >= NOW()
|
WHERE ep.user_id = :id AND e.created_by <> :id AND e.starts_at >= NOW()
|
||||||
ORDER BY e.starts_at ASC'
|
ORDER BY e.starts_at ASC'
|
||||||
);
|
);
|
||||||
@@ -735,10 +736,11 @@ final class AccountPages
|
|||||||
$stmt = $pdo?->prepare(
|
$stmt = $pdo?->prepare(
|
||||||
'SELECT e.id, e.title, e.teaser_public, e.image_path, e.starts_at, e.city, e.visibility, e.status,
|
'SELECT e.id, e.title, e.teaser_public, e.image_path, e.starts_at, e.city, e.visibility, e.status,
|
||||||
ep.status AS participation_status,
|
ep.status AS participation_status,
|
||||||
u.display_name AS host_name
|
COALESCE(up.display_name, "Mitglied") AS host_name
|
||||||
FROM event_participants ep
|
FROM event_participants ep
|
||||||
INNER JOIN events e ON e.id = ep.event_id
|
INNER JOIN events e ON e.id = ep.event_id
|
||||||
INNER JOIN users u ON u.id = e.created_by
|
INNER JOIN users u ON u.id = e.created_by
|
||||||
|
LEFT JOIN user_profiles up ON up.user_id = u.id
|
||||||
WHERE ep.user_id = :id AND e.created_by <> :id AND e.starts_at < NOW()
|
WHERE ep.user_id = :id AND e.created_by <> :id AND e.starts_at < NOW()
|
||||||
ORDER BY e.starts_at DESC'
|
ORDER BY e.starts_at DESC'
|
||||||
);
|
);
|
||||||
|
|||||||
Reference in New Issue
Block a user