From e3a42c8342bba0db15e2ca9a78911121e5d539da Mon Sep 17 00:00:00 2001 From: polo Date: Thu, 29 Jan 2026 22:51:19 +0100 Subject: =?UTF-8?q?classe=20CalendarModalView,=20contr=C3=B4les=20getEleme?= =?UTF-8?q?ntOrThrow=20et=20assertElementType?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/controller/calendar.php | 27 ++++++++++++++++++--------- 1 file changed, 18 insertions(+), 9 deletions(-) (limited to 'src') diff --git a/src/controller/calendar.php b/src/controller/calendar.php index c15141a..47dc8b7 100644 --- a/src/controller/calendar.php +++ b/src/controller/calendar.php @@ -47,9 +47,9 @@ if($_SERVER['REQUEST_METHOD'] === 'GET' && isset($_GET['action']) && $_GET['acti [ 'id' => 1, 'title' => 'Évènement1', - 'description' => 'blablabla', - 'start' => '2025-06-03T05:00:00Z', // Z indique que l'heure est en UTC - 'end' => '2025-06-03T09:00:00Z', + 'description' => 'non allDay quelques heures', + 'start' => '2026-01-03T05:00:00Z', // Z indique que l'heure est en UTC + 'end' => '2026-01-03T09:00:00Z', 'allDay' => false, 'color' => '#ffa500', // couleur hexa, éviter les couleurs CSS qui ne fonctionnent pas dans value="" en HTML //'url' => 'https://dev.nageurs-bigoudens.fr', // comportement: https://fullcalendar.io/docs/eventClick @@ -57,21 +57,30 @@ if($_SERVER['REQUEST_METHOD'] === 'GET' && isset($_GET['action']) && $_GET['acti [ 'id' => 2, 'title' => 'Évènement2', - 'description' => 'truc machin', - 'start' => '2025-06-06T08:00:00Z', - 'end' => '2025-06-07T08:00:00Z', + 'description' => 'non allDay sur plusieurs jours', + 'start' => '2026-01-06T08:00:00Z', + 'end' => '2026-01-07T08:00:00Z', 'allDay' => false, 'color' => '#e01b24', ], [ 'id' => 3, 'title' => 'Évènement3', - 'description' => 'ça va chier', - 'start' => '2025-06-08', - 'end' => '2025-06-09', + 'description' => 'allDay un jour', + 'start' => '2026-01-08', + 'end' => '2026-01-09', 'allDay' => true, // pas d'heure 'color' => '#008000', ], + [ + 'id' => 4, + 'title' => 'Évènement4', + 'description' => 'allDay plusieurs jours', + 'start' => '2026-01-21', + 'end' => '2026-01-23', + 'allDay' => true, // pas d'heure + 'color' => '#0080f0', + ], ]; header('Content-Type: application/json'); -- cgit v1.2.3