prepare("SELECT * FROM daily_plans WHERE user_id = ? AND plan_date = ?"); $stmtPlan->execute([$userId, $today]); $dailyPlan = $stmtPlan->fetch(); if (!$dailyPlan) { $stmtCreatePlan = $db->prepare(" INSERT INTO daily_plans (user_id, plan_date, focus_goal) VALUES (?, ?, 'Mijn belangrijkste doel van vandaag behalen') "); $stmtCreatePlan->execute([$userId, $today]); $planId = (int)$db->lastInsertId(); $dailyPlan = ['id' => $planId, 'plan_date' => $today, 'focus_goal' => 'Mijn belangrijkste doel van vandaag behalen', 'notes' => '']; } // Haal taken op voor vandaag $stmtTasks = $db->prepare(" SELECT * FROM tasks WHERE user_id = ? AND (daily_plan_id = ? OR daily_plan_id IS NULL) ORDER BY is_completed ASC, priority ASC, time_block_start ASC, created_at DESC "); $stmtTasks->execute([$userId, $dailyPlan['id']]); $tasks = $stmtTasks->fetchAll(); // Outlook demo / gesynchroniseerde events $outlookEvents = [ [ 'id' => 'evt-1', 'subject' => 'Daily Team Standup & Focus Sync', 'start' => '09:00', 'end' => '09:30', 'location' => 'Microsoft Teams', 'meeting_url' => 'https://teams.microsoft.com', ], [ 'id' => 'evt-2', 'subject' => 'Sprint & Roadmap Review met Stakeholders', 'start' => '11:00', 'end' => '12:00', 'location' => 'Vergaderruimte A & Teams', 'meeting_url' => 'https://teams.microsoft.com', ], [ 'id' => 'evt-3', 'subject' => 'Architectuur & MariaDB Database Evaluatie', 'start' => '14:30', 'end' => '15:30', 'location' => 'Online Teams Call', 'meeting_url' => 'https://teams.microsoft.com', ] ]; $hours = ["08:00", "09:00", "10:00", "11:00", "12:00", "13:00", "14:00", "15:00", "16:00", "17:00"]; // Nederlandse datumformattering $dutchDays = ['Zondag', 'Maandag', 'Dinsdag', 'Woensdag', 'Donderdag', 'Vrijdag', 'Zaterdag']; $dutchMonths = ['', 'januari', 'februari', 'maart', 'april', 'mei', 'juni', 'juli', 'augustus', 'september', 'oktober', 'november', 'december']; $formattedDate = $dutchDays[date('w')] . ' ' . date('j') . ' ' . $dutchMonths[(int)date('n')] . ' ' . date('Y'); ?>

Dagplanning & Structuur

Focus Modus

Pomodoro & diepe concentratie

25:00
Actieve focus: Kies een taak hieronder

Dagtaken & Prioriteiten ()

Nog geen taken gepland voor vandaag. Klik op 'Nieuwe Taak' om te beginnen.

Dagnotities & Kladblok

Tijdlijn & Time-blocking

08:00 – 18:00