The problem is in this line:
$record_company = $form_group->getCompany(); // it returns null
You have to var_dump the $form_group variable and check content to be sure.
But as I can see, the form group doesn’t have a company.
The problem is in this line:
$record_company = $form_group->getCompany(); // it returns null
You have to var_dump the $form_group variable and check content to be sure.
But as I can see, the form group doesn’t have a company.