diff --git a/ui/app/clinical/consultation/mappers/specimenMapper.js b/ui/app/clinical/consultation/mappers/specimenMapper.js index 447d162f0a..0ef7d4bd8a 100644 --- a/ui/app/clinical/consultation/mappers/specimenMapper.js +++ b/ui/app/clinical/consultation/mappers/specimenMapper.js @@ -15,6 +15,9 @@ Bahmni.Clinical.SpecimenMapper = function () { } if (specimen.sample && specimen.sample.additionalAttributes) { specimen.sample.additionalAttributes = (specimen.sample.additionalAttributes) instanceof Array ? specimen.sample.additionalAttributes : [specimen.sample.additionalAttributes]; + + var obs = new Bahmni.Common.Obs.ObservationMapper().map(specimen.sample.additionalAttributes, conceptsConfig, dontSortByObsDateTime); + specimen.sampleAdditionalAttributes = obs && obs.length > 0 ? obs[0] : obs; } return specimen; };