Skip to content

Commit 73a69ac

Browse files
authored
Merge pull request #41 from LinuxForHealth/add-coding-to-other-identifier
add coding to other identifier
2 parents 2e4725e + 5627b99 commit 73a69ac

File tree

1 file changed

+5
-1
lines changed
  • src/linuxforhealth/csvtofhir/fhirrs

1 file changed

+5
-1
lines changed

src/linuxforhealth/csvtofhir/fhirrs/basic.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
from fhir.resources.meta import Meta
77
from fhir.resources.identifier import Identifier
88
from fhir.resources.coding import Coding
9+
from fhir.resources.codeableconcept import CodeableConcept
910

1011
from linuxforhealth.csvtofhir.model.csv.basic import BasicCsv
1112
from linuxforhealth.csvtofhir.fhirutils import fhir_utils
@@ -127,10 +128,13 @@ def convert_record(
127128
# }
128129
def _build_other_identifier(id, name, value, system):
129130

130-
identifier_type_cc = Coding.construct(
131+
identifier_type_cc = CodeableConcept.construct()
132+
coding = Coding.construct(
131133
system=fhir_utils.get_uri_format(system),
132134
code=name
133135
)
136+
identifier_type_cc.coding = []
137+
identifier_type_cc.coding.append(coding)
134138

135139
identifier = Identifier.construct(
136140
id=id,

0 commit comments

Comments
 (0)