reportService = $reportService; $this->exportService = $exportService; } public function loadReportData(): void { $reportDTO = $this->reportService->buildTrialBalanceReport($this->startDate, $this->endDate); $this->trialBalanceReport = new TrialBalanceReportTransformer($reportDTO); } public function form(Form $form): Form { return $form ->schema([ Split::make([ $this->getDateRangeFormComponent(), $this->getStartDateFormComponent(), $this->getEndDateFormComponent(), ])->live(), ]); } public function exportCSV(): StreamedResponse { return $this->exportService->exportToCsv($this->company, $this->trialBalanceReport, $this->startDate, $this->endDate); } public function exportPDF(): StreamedResponse { return $this->exportService->exportToPdf($this->company, $this->trialBalanceReport, $this->startDate, $this->endDate); } }