Employees table has a field named
current_address_id. I'm adding a new address to
$updatedEntity = $this->patchEntity($employee, [ //some other fields 'user' => $userData, 'employees_phones' => $phonesData, 'employees_addresses' => $addressesData, ], [ 'associated' => ['Users', 'EmployeesPhones', 'EmployeesAddresses'] ]); $this->save($updatedEntity);
I'm inserting the new address successfully but now I need to update
Employees.current_address_id with the new address ID. How can I do this?