<?php

class DashboardController {
    public function index() {
        $db = Database::getInstance();
        $formModel = new FormModel();
        $stats = $formModel->getStats();
        $recentResponses = $formModel->getRecentResponses(5);
        $recentForms = $db->fetchAll("SELECT * FROM forms ORDER BY created_at DESC LIMIT 5");

        require_once APP_PATH . '/views/dashboard.php';
    }
}
