/**
* @param array<string, mixed> $data
* @return array<string, mixed>
*/
protected function mutateFormDataBeforeFill(array $data): array
{
dd('check'); // never gets called
$semester = Semester::where('is_active', true)->firstOrFail();
$photo = Photo::where('uin', $data['uinid']);
$primaryAdvisor = $studentAdvisors->advisors?->primaryAdvisor();
$data['student_advisor'] = $primaryAdvisor->full_name;
$data['student_photo'] = $photo->image;
....//more fields.
return $data;
}
/**
* @param array<string, mixed> $data
* @return array<string, mixed>
*/
protected function mutateFormDataBeforeFill(array $data): array
{
dd('check'); // never gets called
$semester = Semester::where('is_active', true)->firstOrFail();
$photo = Photo::where('uin', $data['uinid']);
$primaryAdvisor = $studentAdvisors->advisors?->primaryAdvisor();
$data['student_advisor'] = $primaryAdvisor->full_name;
$data['student_photo'] = $photo->image;
....//more fields.
return $data;
}