fix: stop mapping isDead label on patient detail

Removing the death_indicator transform keeps GET /api/patient/{id} from exposing isDeadLabel while still returning the raw flag.
This commit is contained in:
mahdahar 2026-04-13 16:08:54 +07:00
parent 1c1808fdb9
commit dfe7a1fd0e

View File

@ -82,15 +82,14 @@ class PatientModel extends BaseModel {
unset($patient['Identifier']);
unset($patient['Comment']);
$patient = ValueSet::transformLabels([$patient], [
'Sex' => 'sex',
'Country' => 'country',
'Race' => 'race',
'Religion' => 'religion',
'Ethnic' => 'ethnic',
'isDead' => 'death_indicator',
'MaritalStatus' => 'marital_status',
])[0];
$patient = ValueSet::transformLabels([$patient], [
'Sex' => 'sex',
'Country' => 'country',
'Race' => 'race',
'Religion' => 'religion',
'Ethnic' => 'ethnic',
'MaritalStatus' => 'marital_status',
])[0];
$patient['PatIdt'] = null;
$patient['PatAtt'] = [];