Add Reunions and Notifications views

This commit is contained in:
Timothée Goguely 2024-09-12 19:07:49 +02:00
parent 4e32368227
commit 3df97ca489
10 changed files with 163 additions and 7 deletions

View file

@ -0,0 +1,5 @@
Title: Notifications
----
Uuid: qBMncHJnGg7k439p

View file

@ -0,0 +1,5 @@
Title: Réunions
----
Uuid: Tml65cm3jdNuyDmF

View file

@ -11,7 +11,7 @@ return [
'pages/projects',
'pages/inspirations',
'pages/notifications',
'pages/events'
'pages/reunions'
];
$path = Kirby\Cms\App::instance()->path();
return
@ -49,20 +49,20 @@ return [
'-',
'notifications' => [
'label' => 'Notifications',
'icon' => 'bell',
'icon' => 'megaphone',
'link' => 'pages/notifications',
'current' => function (string $current): bool {
$path = Kirby\Cms\App::instance()->path();
return Str::contains($path, 'pages/notifications');
}
],
'events' => [
'label' => 'Événements',
'reunions' => [
'label' => 'Réunions',
'icon' => 'calendar',
'link' => 'pages/events',
'link' => 'pages/reunions',
'current' => function (string $current): bool {
$path = Kirby\Cms\App::instance()->path();
return Str::contains($path, 'pages/events');
return Str::contains($path, 'pages/reunions');
}
],
'-',

View file

@ -0,0 +1,9 @@
<?php
$specificData = [
'title' => $page->title()->value(),
];
$data = array_merge($genericData, $specificData);
echo json_encode($data);

View file

@ -0,0 +1 @@
<?php snippet('generic-template') ?>

View file

@ -0,0 +1,9 @@
<?php
$specificData = [
'title' => $page->title()->value(),
];
$data = array_merge($genericData, $specificData);
echo json_encode($data);

View file

@ -0,0 +1 @@
<?php snippet('generic-template') ?>