noscript varianten eingebaut, matomo integration erweitert und als konfiguration aufgenommen.
This commit is contained in:
@@ -463,10 +463,17 @@ class EventPublicController extends BaseController
|
||||
$fallbacks = $this->localeFallbackChain($locale, $eventDefaultLocale);
|
||||
|
||||
$rows = DB::table('tasks')
|
||||
->join('task_collection_task', 'tasks.id', '=', 'task_collection_task.task_id')
|
||||
->join('event_task_collection', 'task_collection_task.task_collection_id', '=', 'event_task_collection.task_collection_id')
|
||||
->leftJoin('task_collection_task', 'tasks.id', '=', 'task_collection_task.task_id')
|
||||
->leftJoin('event_task_collection', 'task_collection_task.task_collection_id', '=', 'event_task_collection.task_collection_id')
|
||||
->leftJoin('event_task', function ($join) use ($eventId) {
|
||||
$join->on('tasks.id', '=', 'event_task.task_id')
|
||||
->where('event_task.event_id', '=', $eventId);
|
||||
})
|
||||
->leftJoin('emotions', 'tasks.emotion_id', '=', 'emotions.id')
|
||||
->where('event_task_collection.event_id', $eventId)
|
||||
->where(function ($query) use ($eventId) {
|
||||
$query->where('event_task_collection.event_id', $eventId)
|
||||
->orWhereNotNull('event_task.event_id');
|
||||
})
|
||||
->select([
|
||||
'tasks.id',
|
||||
'tasks.title',
|
||||
@@ -474,10 +481,12 @@ class EventPublicController extends BaseController
|
||||
'tasks.example_text',
|
||||
'tasks.emotion_id',
|
||||
'tasks.sort_order',
|
||||
'event_task.sort_order as direct_sort_order',
|
||||
'event_task_collection.sort_order as collection_sort_order',
|
||||
'emotions.name as emotion_name',
|
||||
'emotions.id as emotion_lookup_id',
|
||||
])
|
||||
->orderBy('event_task_collection.sort_order')
|
||||
->orderByRaw('COALESCE(event_task_collection.sort_order, event_task.sort_order, tasks.sort_order, 0)')
|
||||
->orderBy('tasks.sort_order')
|
||||
->limit(20)
|
||||
->get();
|
||||
|
||||
@@ -182,7 +182,7 @@ class AppServiceProvider extends ServiceProvider
|
||||
Inertia::share('analytics', static function () {
|
||||
$config = config('services.matomo');
|
||||
|
||||
if (! ($config['enabled'] ?? false)) {
|
||||
if (! ($config['enabled'] ?? false) || empty($config['url']) || empty($config['site_id_marketing'])) {
|
||||
return [
|
||||
'matomo' => [
|
||||
'enabled' => false,
|
||||
@@ -194,7 +194,7 @@ class AppServiceProvider extends ServiceProvider
|
||||
'matomo' => [
|
||||
'enabled' => true,
|
||||
'url' => rtrim((string) ($config['url'] ?? ''), '/'),
|
||||
'siteId' => (string) ($config['site_id'] ?? ''),
|
||||
'siteId' => (string) ($config['site_id_marketing'] ?? ''),
|
||||
],
|
||||
];
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user