/** * Returns a new child form * @return Form */ function getChildForm() { $classname = ReportSummaryForm::translateDetailFunctionById($this->getReportParameters()->getDetailsByKey($this->getDetailId())); $child_class = new $classname(); $next_id = $this->getDetailId() + 1; $child_class->setDetailId($next_id); $child_class->setParentClass($this); return $child_class; }