<?php
declare(strict_types=1);

namespace App\Controllers;

use App\Core\Request;
use App\Models\Opportunity;
use App\Services\IndustryReportService;

final class ReportController extends BaseController
{
    public function index(Request $request): void
    {
        $this->requireModule('reports');
        view('reports/index', [
            'title' => 'Reports',
            'byStage' => Opportunity::pipelineByStage(),
            'byRep' => Opportunity::pipelineByRep(),
            'forecast' => Opportunity::forecast(),
            'industryPanel' => IndustryReportService::panel(),
            'notifications' => $this->notifications(),
        ]);
    }
}
