<?php

use Illuminate\Support\Facades\Schedule;

Schedule::command('attendance:auto-absent')->hourly();
Schedule::command('attendance:enforce-thresholds')->dailyAt('06:00');
Schedule::command('attendance:send-alerts')->dailyAt('20:00');
Schedule::command('invoices:mark-overdue')->dailyAt('01:00');
Schedule::command('sessions:generate-upcoming')->dailyAt('02:00');
Schedule::command('audit:cleanup --days=365')->weekly();
Schedule::command('documents:expire')->dailyAt('06:00');
Schedule::command('summary:daily')->dailyAt('07:00');
Schedule::command('notifications:birthdays')->dailyAt('08:00');
Schedule::command('payments:detect-defaults')->dailyAt('08:00');
Schedule::command('inventory:notify-low-stock')->dailyAt('09:00');
Schedule::command('reminders:expiring-enrollments --days=7')->dailyAt('10:00');
Schedule::command('reminders:expiring-enrollments --days=3')->dailyAt('10:30');
Schedule::command('reminders:installments --days=3')->dailyAt('11:00');
Schedule::command('reminders:installments --days=1')->dailyAt('11:30');
Schedule::command('reminders:overdue-invoices')->weeklyOn(1, '09:00');
Schedule::command('reminders:overdue-invoices')->weeklyOn(4, '09:00');
Schedule::command('groups:reconcile-counts')->dailyAt('03:00');
Schedule::command('enrollments:deactivate-expired')->dailyAt('00:30');
Schedule::command('financials:reconcile')->weeklyOn(0, '04:00');
Schedule::command('reports:parent-weekly')->weeklyOn(6, '12:00');
Schedule::command('enrollments:generate-renewals')->dailyAt('07:00');
Schedule::command('groups:alert-capacity --threshold=90')->dailyAt('08:00');

// Push notifications
Schedule::command('push:session-reminder --minutes=30')->everyMinute();
Schedule::command('push:installment-due --days=1')->dailyAt('09:00');
Schedule::command('push:installment-due --days=3')->dailyAt('09:30');
Schedule::command('push:send-scheduled')->everyMinute();
