When I run this I get the error “Patient UUID is invalid”. Is there some other id I could be using? I tried using the uuid instead but get a the error “Patient UUID must be a valid UUID (valid format)”.
So the patient databaseInsert returns the UUID in binary and the encounter service expects the uuid to be a string. I’d rather we send back the patient uuid as a string on the insert of the PatientService. It looks that that is what we do in the insert() method and updatePatientData() method (the downside is that those return a ProcessingResult object).
could we put this into the databaseInsert function and optionally change the signature to include $uuidAsString = false?
if ($results) {
// return the uuid as a string for friendly result set to use with encounter service
$data['uuid'] = UuidRegistry::uuidToString($data['uuid']);
return $data;
} else {
return false;
}