@openfn/language-fhir-4 0.2.2 → 0.2.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/dist/index.cjs +1293 -0
  2. package/dist/index.js +1293 -0
  3. package/package.json +4 -4
package/dist/index.js CHANGED
@@ -580,6 +580,9 @@ function Account_default(props) {
580
580
  }
581
581
  resource.identifier = identifier(props.identifier);
582
582
  }
583
+ if (!_2.isNil(props.type)) {
584
+ resource.type = concept(props.type);
585
+ }
583
586
  if (!_2.isNil(props.subject)) {
584
587
  if (!Array.isArray(props.subject)) {
585
588
  props.subject = [props.subject];
@@ -638,6 +641,21 @@ function ActivityDefinition_default(props) {
638
641
  delete resource.subject;
639
642
  composite(resource, "subject", props.subject);
640
643
  }
644
+ if (!_3.isNil(props.jurisdiction)) {
645
+ if (!Array.isArray(props.jurisdiction)) {
646
+ props.jurisdiction = [props.jurisdiction];
647
+ }
648
+ resource.jurisdiction = concept(props.jurisdiction);
649
+ }
650
+ if (!_3.isNil(props.topic)) {
651
+ if (!Array.isArray(props.topic)) {
652
+ props.topic = [props.topic];
653
+ }
654
+ resource.topic = concept(props.topic);
655
+ }
656
+ if (!_3.isNil(props.code)) {
657
+ resource.code = concept(props.code);
658
+ }
641
659
  if (!_3.isNil(props.timing)) {
642
660
  delete resource.timing;
643
661
  composite(resource, "timing", props.timing);
@@ -662,6 +680,12 @@ function ActivityDefinition_default(props) {
662
680
  delete resource.product;
663
681
  composite(resource, "product", props.product);
664
682
  }
683
+ if (!_3.isNil(props.bodySite)) {
684
+ if (!Array.isArray(props.bodySite)) {
685
+ props.bodySite = [props.bodySite];
686
+ }
687
+ resource.bodySite = concept(props.bodySite);
688
+ }
665
689
  if (!_3.isNil(props.specimenRequirement)) {
666
690
  if (!Array.isArray(props.specimenRequirement)) {
667
691
  props.specimenRequirement = [props.specimenRequirement];
@@ -715,12 +739,24 @@ function AdministrableProductDefinition_default(props) {
715
739
  }
716
740
  resource.formOf = reference(props.formOf);
717
741
  }
742
+ if (!_4.isNil(props.administrableDoseForm)) {
743
+ resource.administrableDoseForm = concept(props.administrableDoseForm);
744
+ }
745
+ if (!_4.isNil(props.unitOfPresentation)) {
746
+ resource.unitOfPresentation = concept(props.unitOfPresentation);
747
+ }
718
748
  if (!_4.isNil(props.producedFrom)) {
719
749
  if (!Array.isArray(props.producedFrom)) {
720
750
  props.producedFrom = [props.producedFrom];
721
751
  }
722
752
  resource.producedFrom = reference(props.producedFrom);
723
753
  }
754
+ if (!_4.isNil(props.ingredient)) {
755
+ if (!Array.isArray(props.ingredient)) {
756
+ props.ingredient = [props.ingredient];
757
+ }
758
+ resource.ingredient = concept(props.ingredient);
759
+ }
724
760
  if (!_4.isNil(props.device)) {
725
761
  resource.device = reference(props.device);
726
762
  }
@@ -763,6 +799,15 @@ function AdverseEvent_default(props) {
763
799
  if (!_5.isNil(props.identifier)) {
764
800
  resource.identifier = identifier(props.identifier);
765
801
  }
802
+ if (!_5.isNil(props.category)) {
803
+ if (!Array.isArray(props.category)) {
804
+ props.category = [props.category];
805
+ }
806
+ resource.category = concept(props.category);
807
+ }
808
+ if (!_5.isNil(props.event)) {
809
+ resource.event = concept(props.event);
810
+ }
766
811
  if (!_5.isNil(props.subject)) {
767
812
  resource.subject = reference(props.subject);
768
813
  }
@@ -778,6 +823,15 @@ function AdverseEvent_default(props) {
778
823
  if (!_5.isNil(props.location)) {
779
824
  resource.location = reference(props.location);
780
825
  }
826
+ if (!_5.isNil(props.seriousness)) {
827
+ resource.seriousness = concept(props.seriousness);
828
+ }
829
+ if (!_5.isNil(props.severity)) {
830
+ resource.severity = concept(props.severity);
831
+ }
832
+ if (!_5.isNil(props.outcome)) {
833
+ resource.outcome = concept(props.outcome);
834
+ }
781
835
  if (!_5.isNil(props.recorder)) {
782
836
  resource.recorder = reference(props.recorder);
783
837
  }
@@ -834,6 +888,15 @@ function AllergyIntolerance_default(props) {
834
888
  }
835
889
  resource.identifier = identifier(props.identifier);
836
890
  }
891
+ if (!_6.isNil(props.clinicalStatus)) {
892
+ resource.clinicalStatus = concept(props.clinicalStatus);
893
+ }
894
+ if (!_6.isNil(props.verificationStatus)) {
895
+ resource.verificationStatus = concept(props.verificationStatus);
896
+ }
897
+ if (!_6.isNil(props.code)) {
898
+ resource.code = concept(props.code);
899
+ }
837
900
  if (!_6.isNil(props.patient)) {
838
901
  resource.patient = reference(props.patient);
839
902
  }
@@ -879,6 +942,36 @@ function Appointment_default(props) {
879
942
  }
880
943
  resource.identifier = identifier(props.identifier);
881
944
  }
945
+ if (!_7.isNil(props.cancelationReason)) {
946
+ resource.cancelationReason = concept(props.cancelationReason);
947
+ }
948
+ if (!_7.isNil(props.serviceCategory)) {
949
+ if (!Array.isArray(props.serviceCategory)) {
950
+ props.serviceCategory = [props.serviceCategory];
951
+ }
952
+ resource.serviceCategory = concept(props.serviceCategory);
953
+ }
954
+ if (!_7.isNil(props.serviceType)) {
955
+ if (!Array.isArray(props.serviceType)) {
956
+ props.serviceType = [props.serviceType];
957
+ }
958
+ resource.serviceType = concept(props.serviceType);
959
+ }
960
+ if (!_7.isNil(props.specialty)) {
961
+ if (!Array.isArray(props.specialty)) {
962
+ props.specialty = [props.specialty];
963
+ }
964
+ resource.specialty = concept(props.specialty);
965
+ }
966
+ if (!_7.isNil(props.appointmentType)) {
967
+ resource.appointmentType = concept(props.appointmentType);
968
+ }
969
+ if (!_7.isNil(props.reasonCode)) {
970
+ if (!Array.isArray(props.reasonCode)) {
971
+ props.reasonCode = [props.reasonCode];
972
+ }
973
+ resource.reasonCode = concept(props.reasonCode);
974
+ }
882
975
  if (!_7.isNil(props.reasonReference)) {
883
976
  if (!Array.isArray(props.reasonReference)) {
884
977
  props.reasonReference = [props.reasonReference];
@@ -935,6 +1028,12 @@ function AppointmentResponse_default(props) {
935
1028
  if (!_8.isNil(props.appointment)) {
936
1029
  resource.appointment = reference(props.appointment);
937
1030
  }
1031
+ if (!_8.isNil(props.participantType)) {
1032
+ if (!Array.isArray(props.participantType)) {
1033
+ props.participantType = [props.participantType];
1034
+ }
1035
+ resource.participantType = concept(props.participantType);
1036
+ }
938
1037
  if (!_8.isNil(props.actor)) {
939
1038
  resource.actor = reference(props.actor);
940
1039
  }
@@ -954,6 +1053,9 @@ function BiologicallyDerivedProduct_default(props) {
954
1053
  }
955
1054
  resource.identifier = identifier(props.identifier);
956
1055
  }
1056
+ if (!_9.isNil(props.productCode)) {
1057
+ resource.productCode = concept(props.productCode);
1058
+ }
957
1059
  if (!_9.isNil(props.request)) {
958
1060
  if (!Array.isArray(props.request)) {
959
1061
  props.request = [props.request];
@@ -1022,6 +1124,18 @@ function BodyStructure_default(props) {
1022
1124
  }
1023
1125
  resource.identifier = identifier(props.identifier);
1024
1126
  }
1127
+ if (!_10.isNil(props.morphology)) {
1128
+ resource.morphology = concept(props.morphology);
1129
+ }
1130
+ if (!_10.isNil(props.location)) {
1131
+ resource.location = concept(props.location);
1132
+ }
1133
+ if (!_10.isNil(props.locationQualifier)) {
1134
+ if (!Array.isArray(props.locationQualifier)) {
1135
+ props.locationQualifier = [props.locationQualifier];
1136
+ }
1137
+ resource.locationQualifier = concept(props.locationQualifier);
1138
+ }
1025
1139
  if (!_10.isNil(props.patient)) {
1026
1140
  resource.patient = reference(props.patient);
1027
1141
  }
@@ -1059,6 +1173,12 @@ function CarePlan_default(props) {
1059
1173
  }
1060
1174
  resource.partOf = reference(props.partOf);
1061
1175
  }
1176
+ if (!_11.isNil(props.category)) {
1177
+ if (!Array.isArray(props.category)) {
1178
+ props.category = [props.category];
1179
+ }
1180
+ resource.category = concept(props.category);
1181
+ }
1062
1182
  if (!_11.isNil(props.subject)) {
1063
1183
  resource.subject = reference(props.subject);
1064
1184
  }
@@ -1127,6 +1247,12 @@ function CareTeam_default(props) {
1127
1247
  }
1128
1248
  resource.identifier = identifier(props.identifier);
1129
1249
  }
1250
+ if (!_12.isNil(props.category)) {
1251
+ if (!Array.isArray(props.category)) {
1252
+ props.category = [props.category];
1253
+ }
1254
+ resource.category = concept(props.category);
1255
+ }
1130
1256
  if (!_12.isNil(props.subject)) {
1131
1257
  resource.subject = reference(props.subject);
1132
1258
  }
@@ -1146,6 +1272,12 @@ function CareTeam_default(props) {
1146
1272
  resource.participant.push(_participant);
1147
1273
  }
1148
1274
  }
1275
+ if (!_12.isNil(props.reasonCode)) {
1276
+ if (!Array.isArray(props.reasonCode)) {
1277
+ props.reasonCode = [props.reasonCode];
1278
+ }
1279
+ resource.reasonCode = concept(props.reasonCode);
1280
+ }
1149
1281
  if (!_12.isNil(props.reasonReference)) {
1150
1282
  if (!Array.isArray(props.reasonReference)) {
1151
1283
  props.reasonReference = [props.reasonReference];
@@ -1180,6 +1312,9 @@ function ChargeItem_default(props) {
1180
1312
  }
1181
1313
  resource.partOf = reference(props.partOf);
1182
1314
  }
1315
+ if (!_13.isNil(props.code)) {
1316
+ resource.code = concept(props.code);
1317
+ }
1183
1318
  if (!_13.isNil(props.subject)) {
1184
1319
  resource.subject = reference(props.subject);
1185
1320
  }
@@ -1212,9 +1347,21 @@ function ChargeItem_default(props) {
1212
1347
  if (!_13.isNil(props.costCenter)) {
1213
1348
  resource.costCenter = reference(props.costCenter);
1214
1349
  }
1350
+ if (!_13.isNil(props.bodysite)) {
1351
+ if (!Array.isArray(props.bodysite)) {
1352
+ props.bodysite = [props.bodysite];
1353
+ }
1354
+ resource.bodysite = concept(props.bodysite);
1355
+ }
1215
1356
  if (!_13.isNil(props.enterer)) {
1216
1357
  resource.enterer = reference(props.enterer);
1217
1358
  }
1359
+ if (!_13.isNil(props.reason)) {
1360
+ if (!Array.isArray(props.reason)) {
1361
+ props.reason = [props.reason];
1362
+ }
1363
+ resource.reason = concept(props.reason);
1364
+ }
1218
1365
  if (!_13.isNil(props.service)) {
1219
1366
  if (!Array.isArray(props.service)) {
1220
1367
  props.service = [props.service];
@@ -1253,6 +1400,15 @@ function ChargeItemDefinition_default(props) {
1253
1400
  }
1254
1401
  resource.identifier = identifier(props.identifier);
1255
1402
  }
1403
+ if (!_14.isNil(props.jurisdiction)) {
1404
+ if (!Array.isArray(props.jurisdiction)) {
1405
+ props.jurisdiction = [props.jurisdiction];
1406
+ }
1407
+ resource.jurisdiction = concept(props.jurisdiction);
1408
+ }
1409
+ if (!_14.isNil(props.code)) {
1410
+ resource.code = concept(props.code);
1411
+ }
1256
1412
  if (!_14.isNil(props.instance)) {
1257
1413
  if (!Array.isArray(props.instance)) {
1258
1414
  props.instance = [props.instance];
@@ -1301,6 +1457,12 @@ function Citation_default(props) {
1301
1457
  }
1302
1458
  resource.identifier = identifier(props.identifier);
1303
1459
  }
1460
+ if (!_15.isNil(props.jurisdiction)) {
1461
+ if (!Array.isArray(props.jurisdiction)) {
1462
+ props.jurisdiction = [props.jurisdiction];
1463
+ }
1464
+ resource.jurisdiction = concept(props.jurisdiction);
1465
+ }
1304
1466
  if (!_15.isNil(props.summary)) {
1305
1467
  let src = props.summary;
1306
1468
  if (!Array.isArray(src)) {
@@ -1327,6 +1489,12 @@ function Citation_default(props) {
1327
1489
  resource.classification.push(_classification);
1328
1490
  }
1329
1491
  }
1492
+ if (!_15.isNil(props.currentState)) {
1493
+ if (!Array.isArray(props.currentState)) {
1494
+ props.currentState = [props.currentState];
1495
+ }
1496
+ resource.currentState = concept(props.currentState);
1497
+ }
1330
1498
  if (!_15.isNil(props.statusDate)) {
1331
1499
  let src = props.statusDate;
1332
1500
  if (!Array.isArray(src)) {
@@ -1376,6 +1544,12 @@ function Claim_default(props) {
1376
1544
  }
1377
1545
  resource.identifier = identifier(props.identifier);
1378
1546
  }
1547
+ if (!_16.isNil(props.type)) {
1548
+ resource.type = concept(props.type);
1549
+ }
1550
+ if (!_16.isNil(props.subType)) {
1551
+ resource.subType = concept(props.subType);
1552
+ }
1379
1553
  if (!_16.isNil(props.patient)) {
1380
1554
  resource.patient = reference(props.patient);
1381
1555
  }
@@ -1388,6 +1562,12 @@ function Claim_default(props) {
1388
1562
  if (!_16.isNil(props.provider)) {
1389
1563
  resource.provider = reference(props.provider);
1390
1564
  }
1565
+ if (!_16.isNil(props.priority)) {
1566
+ resource.priority = concept(props.priority);
1567
+ }
1568
+ if (!_16.isNil(props.fundsReserve)) {
1569
+ resource.fundsReserve = concept(props.fundsReserve);
1570
+ }
1391
1571
  if (!_16.isNil(props.related)) {
1392
1572
  let src = props.related;
1393
1573
  if (!Array.isArray(src)) {
@@ -1521,6 +1701,12 @@ function ClaimResponse_default(props) {
1521
1701
  }
1522
1702
  resource.identifier = identifier(props.identifier);
1523
1703
  }
1704
+ if (!_17.isNil(props.type)) {
1705
+ resource.type = concept(props.type);
1706
+ }
1707
+ if (!_17.isNil(props.subType)) {
1708
+ resource.subType = concept(props.subType);
1709
+ }
1524
1710
  if (!_17.isNil(props.patient)) {
1525
1711
  resource.patient = reference(props.patient);
1526
1712
  }
@@ -1533,6 +1719,9 @@ function ClaimResponse_default(props) {
1533
1719
  if (!_17.isNil(props.request)) {
1534
1720
  resource.request = reference(props.request);
1535
1721
  }
1722
+ if (!_17.isNil(props.payeeType)) {
1723
+ resource.payeeType = concept(props.payeeType);
1724
+ }
1536
1725
  if (!_17.isNil(props.item)) {
1537
1726
  let src = props.item;
1538
1727
  if (!Array.isArray(src)) {
@@ -1579,6 +1768,12 @@ function ClaimResponse_default(props) {
1579
1768
  };
1580
1769
  resource.payment = _payment;
1581
1770
  }
1771
+ if (!_17.isNil(props.fundsReserve)) {
1772
+ resource.fundsReserve = concept(props.fundsReserve);
1773
+ }
1774
+ if (!_17.isNil(props.formCode)) {
1775
+ resource.formCode = concept(props.formCode);
1776
+ }
1582
1777
  if (!_17.isNil(props.processNote)) {
1583
1778
  let src = props.processNote;
1584
1779
  if (!Array.isArray(src)) {
@@ -1640,6 +1835,12 @@ function ClinicalImpression_default(props) {
1640
1835
  }
1641
1836
  resource.identifier = identifier(props.identifier);
1642
1837
  }
1838
+ if (!_18.isNil(props.statusReason)) {
1839
+ resource.statusReason = concept(props.statusReason);
1840
+ }
1841
+ if (!_18.isNil(props.code)) {
1842
+ resource.code = concept(props.code);
1843
+ }
1643
1844
  if (!_18.isNil(props.subject)) {
1644
1845
  resource.subject = reference(props.subject);
1645
1846
  }
@@ -1688,6 +1889,12 @@ function ClinicalImpression_default(props) {
1688
1889
  resource.finding.push(_finding);
1689
1890
  }
1690
1891
  }
1892
+ if (!_18.isNil(props.prognosisCodeableConcept)) {
1893
+ if (!Array.isArray(props.prognosisCodeableConcept)) {
1894
+ props.prognosisCodeableConcept = [props.prognosisCodeableConcept];
1895
+ }
1896
+ resource.prognosisCodeableConcept = concept(props.prognosisCodeableConcept);
1897
+ }
1691
1898
  if (!_18.isNil(props.prognosisReference)) {
1692
1899
  if (!Array.isArray(props.prognosisReference)) {
1693
1900
  props.prognosisReference = [props.prognosisReference];
@@ -1716,12 +1923,21 @@ function ClinicalUseDefinition_default(props) {
1716
1923
  }
1717
1924
  resource.identifier = identifier(props.identifier);
1718
1925
  }
1926
+ if (!_19.isNil(props.category)) {
1927
+ if (!Array.isArray(props.category)) {
1928
+ props.category = [props.category];
1929
+ }
1930
+ resource.category = concept(props.category);
1931
+ }
1719
1932
  if (!_19.isNil(props.subject)) {
1720
1933
  if (!Array.isArray(props.subject)) {
1721
1934
  props.subject = [props.subject];
1722
1935
  }
1723
1936
  resource.subject = reference(props.subject);
1724
1937
  }
1938
+ if (!_19.isNil(props.status)) {
1939
+ resource.status = concept(props.status);
1940
+ }
1725
1941
  if (!_19.isNil(props.contraindication)) {
1726
1942
  let src = props.contraindication;
1727
1943
  let _contraindication = {
@@ -1797,9 +2013,27 @@ function Communication_default(props) {
1797
2013
  }
1798
2014
  resource.inResponseTo = reference(props.inResponseTo);
1799
2015
  }
2016
+ if (!_20.isNil(props.statusReason)) {
2017
+ resource.statusReason = concept(props.statusReason);
2018
+ }
2019
+ if (!_20.isNil(props.category)) {
2020
+ if (!Array.isArray(props.category)) {
2021
+ props.category = [props.category];
2022
+ }
2023
+ resource.category = concept(props.category);
2024
+ }
2025
+ if (!_20.isNil(props.medium)) {
2026
+ if (!Array.isArray(props.medium)) {
2027
+ props.medium = [props.medium];
2028
+ }
2029
+ resource.medium = concept(props.medium);
2030
+ }
1800
2031
  if (!_20.isNil(props.subject)) {
1801
2032
  resource.subject = reference(props.subject);
1802
2033
  }
2034
+ if (!_20.isNil(props.topic)) {
2035
+ resource.topic = concept(props.topic);
2036
+ }
1803
2037
  if (!_20.isNil(props.about)) {
1804
2038
  if (!Array.isArray(props.about)) {
1805
2039
  props.about = [props.about];
@@ -1818,6 +2052,12 @@ function Communication_default(props) {
1818
2052
  if (!_20.isNil(props.sender)) {
1819
2053
  resource.sender = reference(props.sender);
1820
2054
  }
2055
+ if (!_20.isNil(props.reasonCode)) {
2056
+ if (!Array.isArray(props.reasonCode)) {
2057
+ props.reasonCode = [props.reasonCode];
2058
+ }
2059
+ resource.reasonCode = concept(props.reasonCode);
2060
+ }
1821
2061
  if (!_20.isNil(props.reasonReference)) {
1822
2062
  if (!Array.isArray(props.reasonReference)) {
1823
2063
  props.reasonReference = [props.reasonReference];
@@ -1868,6 +2108,21 @@ function CommunicationRequest_default(props) {
1868
2108
  if (!_21.isNil(props.groupIdentifier)) {
1869
2109
  resource.groupIdentifier = identifier(props.groupIdentifier);
1870
2110
  }
2111
+ if (!_21.isNil(props.statusReason)) {
2112
+ resource.statusReason = concept(props.statusReason);
2113
+ }
2114
+ if (!_21.isNil(props.category)) {
2115
+ if (!Array.isArray(props.category)) {
2116
+ props.category = [props.category];
2117
+ }
2118
+ resource.category = concept(props.category);
2119
+ }
2120
+ if (!_21.isNil(props.medium)) {
2121
+ if (!Array.isArray(props.medium)) {
2122
+ props.medium = [props.medium];
2123
+ }
2124
+ resource.medium = concept(props.medium);
2125
+ }
1871
2126
  if (!_21.isNil(props.subject)) {
1872
2127
  resource.subject = reference(props.subject);
1873
2128
  }
@@ -1909,6 +2164,12 @@ function CommunicationRequest_default(props) {
1909
2164
  if (!_21.isNil(props.sender)) {
1910
2165
  resource.sender = reference(props.sender);
1911
2166
  }
2167
+ if (!_21.isNil(props.reasonCode)) {
2168
+ if (!Array.isArray(props.reasonCode)) {
2169
+ props.reasonCode = [props.reasonCode];
2170
+ }
2171
+ resource.reasonCode = concept(props.reasonCode);
2172
+ }
1912
2173
  if (!_21.isNil(props.reasonReference)) {
1913
2174
  if (!Array.isArray(props.reasonReference)) {
1914
2175
  props.reasonReference = [props.reasonReference];
@@ -1931,9 +2192,18 @@ function Contract_default(props) {
1931
2192
  }
1932
2193
  resource.identifier = identifier(props.identifier);
1933
2194
  }
2195
+ if (!_22.isNil(props.legalState)) {
2196
+ resource.legalState = concept(props.legalState);
2197
+ }
1934
2198
  if (!_22.isNil(props.instantiatesCanonical)) {
1935
2199
  resource.instantiatesCanonical = reference(props.instantiatesCanonical);
1936
2200
  }
2201
+ if (!_22.isNil(props.contentDerivative)) {
2202
+ resource.contentDerivative = concept(props.contentDerivative);
2203
+ }
2204
+ if (!_22.isNil(props.expirationType)) {
2205
+ resource.expirationType = concept(props.expirationType);
2206
+ }
1937
2207
  if (!_22.isNil(props.subject)) {
1938
2208
  if (!Array.isArray(props.subject)) {
1939
2209
  props.subject = [props.subject];
@@ -1961,10 +2231,22 @@ function Contract_default(props) {
1961
2231
  if (!_22.isNil(props.author)) {
1962
2232
  resource.author = reference(props.author);
1963
2233
  }
2234
+ if (!_22.isNil(props.scope)) {
2235
+ resource.scope = concept(props.scope);
2236
+ }
1964
2237
  if (!_22.isNil(props.topic)) {
1965
2238
  delete resource.topic;
1966
2239
  composite(resource, "topic", props.topic);
1967
2240
  }
2241
+ if (!_22.isNil(props.type)) {
2242
+ resource.type = concept(props.type);
2243
+ }
2244
+ if (!_22.isNil(props.subType)) {
2245
+ if (!Array.isArray(props.subType)) {
2246
+ props.subType = [props.subType];
2247
+ }
2248
+ resource.subType = concept(props.subType);
2249
+ }
1968
2250
  if (!_22.isNil(props.contentDefinition)) {
1969
2251
  let src = props.contentDefinition;
1970
2252
  let _contentDefinition = {
@@ -2069,6 +2351,9 @@ function Coverage_default(props) {
2069
2351
  }
2070
2352
  resource.identifier = identifier(props.identifier);
2071
2353
  }
2354
+ if (!_23.isNil(props.type)) {
2355
+ resource.type = concept(props.type);
2356
+ }
2072
2357
  if (!_23.isNil(props.policyHolder)) {
2073
2358
  resource.policyHolder = reference(props.policyHolder);
2074
2359
  }
@@ -2078,6 +2363,9 @@ function Coverage_default(props) {
2078
2363
  if (!_23.isNil(props.beneficiary)) {
2079
2364
  resource.beneficiary = reference(props.beneficiary);
2080
2365
  }
2366
+ if (!_23.isNil(props.relationship)) {
2367
+ resource.relationship = concept(props.relationship);
2368
+ }
2081
2369
  if (!_23.isNil(props.payor)) {
2082
2370
  if (!Array.isArray(props.payor)) {
2083
2371
  props.payor = [props.payor];
@@ -2132,6 +2420,9 @@ function CoverageEligibilityRequest_default(props) {
2132
2420
  }
2133
2421
  resource.identifier = identifier(props.identifier);
2134
2422
  }
2423
+ if (!_24.isNil(props.priority)) {
2424
+ resource.priority = concept(props.priority);
2425
+ }
2135
2426
  if (!_24.isNil(props.patient)) {
2136
2427
  resource.patient = reference(props.patient);
2137
2428
  }
@@ -2235,6 +2526,9 @@ function CoverageEligibilityResponse_default(props) {
2235
2526
  resource.insurance.push(_insurance);
2236
2527
  }
2237
2528
  }
2529
+ if (!_25.isNil(props.form)) {
2530
+ resource.form = concept(props.form);
2531
+ }
2238
2532
  if (!_25.isNil(props.error)) {
2239
2533
  let src = props.error;
2240
2534
  if (!Array.isArray(src)) {
@@ -2264,6 +2558,9 @@ function DetectedIssue_default(props) {
2264
2558
  }
2265
2559
  resource.identifier = identifier(props.identifier);
2266
2560
  }
2561
+ if (!_26.isNil(props.code)) {
2562
+ resource.code = concept(props.code);
2563
+ }
2267
2564
  if (!_26.isNil(props.patient)) {
2268
2565
  resource.patient = reference(props.patient);
2269
2566
  }
@@ -2338,6 +2635,12 @@ function Device_default(props) {
2338
2635
  resource.udiCarrier.push(_udiCarrier);
2339
2636
  }
2340
2637
  }
2638
+ if (!_27.isNil(props.statusReason)) {
2639
+ if (!Array.isArray(props.statusReason)) {
2640
+ props.statusReason = [props.statusReason];
2641
+ }
2642
+ resource.statusReason = concept(props.statusReason);
2643
+ }
2341
2644
  if (!_27.isNil(props.deviceName)) {
2342
2645
  let src = props.deviceName;
2343
2646
  if (!Array.isArray(src)) {
@@ -2351,6 +2654,9 @@ function Device_default(props) {
2351
2654
  resource.deviceName.push(_deviceName);
2352
2655
  }
2353
2656
  }
2657
+ if (!_27.isNil(props.type)) {
2658
+ resource.type = concept(props.type);
2659
+ }
2354
2660
  if (!_27.isNil(props.specialization)) {
2355
2661
  let src = props.specialization;
2356
2662
  if (!Array.isArray(src)) {
@@ -2399,6 +2705,12 @@ function Device_default(props) {
2399
2705
  if (!_27.isNil(props.location)) {
2400
2706
  resource.location = reference(props.location);
2401
2707
  }
2708
+ if (!_27.isNil(props.safety)) {
2709
+ if (!Array.isArray(props.safety)) {
2710
+ props.safety = [props.safety];
2711
+ }
2712
+ resource.safety = concept(props.safety);
2713
+ }
2402
2714
  if (!_27.isNil(props.parent)) {
2403
2715
  resource.parent = reference(props.parent);
2404
2716
  }
@@ -2448,6 +2760,9 @@ function DeviceDefinition_default(props) {
2448
2760
  resource.deviceName.push(_deviceName);
2449
2761
  }
2450
2762
  }
2763
+ if (!_28.isNil(props.type)) {
2764
+ resource.type = concept(props.type);
2765
+ }
2451
2766
  if (!_28.isNil(props.specialization)) {
2452
2767
  let src = props.specialization;
2453
2768
  if (!Array.isArray(src)) {
@@ -2461,6 +2776,18 @@ function DeviceDefinition_default(props) {
2461
2776
  resource.specialization.push(_specialization);
2462
2777
  }
2463
2778
  }
2779
+ if (!_28.isNil(props.safety)) {
2780
+ if (!Array.isArray(props.safety)) {
2781
+ props.safety = [props.safety];
2782
+ }
2783
+ resource.safety = concept(props.safety);
2784
+ }
2785
+ if (!_28.isNil(props.languageCode)) {
2786
+ if (!Array.isArray(props.languageCode)) {
2787
+ props.languageCode = [props.languageCode];
2788
+ }
2789
+ resource.languageCode = concept(props.languageCode);
2790
+ }
2464
2791
  if (!_28.isNil(props.capability)) {
2465
2792
  let src = props.capability;
2466
2793
  if (!Array.isArray(src)) {
@@ -2522,6 +2849,12 @@ function DeviceMetric_default(props) {
2522
2849
  }
2523
2850
  resource.identifier = identifier(props.identifier);
2524
2851
  }
2852
+ if (!_29.isNil(props.type)) {
2853
+ resource.type = concept(props.type);
2854
+ }
2855
+ if (!_29.isNil(props.unit)) {
2856
+ resource.unit = concept(props.unit);
2857
+ }
2525
2858
  if (!_29.isNil(props.source)) {
2526
2859
  resource.source = reference(props.source);
2527
2860
  }
@@ -2602,9 +2935,18 @@ function DeviceRequest_default(props) {
2602
2935
  if (!_30.isNil(props.requester)) {
2603
2936
  resource.requester = reference(props.requester);
2604
2937
  }
2938
+ if (!_30.isNil(props.performerType)) {
2939
+ resource.performerType = concept(props.performerType);
2940
+ }
2605
2941
  if (!_30.isNil(props.performer)) {
2606
2942
  resource.performer = reference(props.performer);
2607
2943
  }
2944
+ if (!_30.isNil(props.reasonCode)) {
2945
+ if (!Array.isArray(props.reasonCode)) {
2946
+ props.reasonCode = [props.reasonCode];
2947
+ }
2948
+ resource.reasonCode = concept(props.reasonCode);
2949
+ }
2608
2950
  if (!_30.isNil(props.reasonReference)) {
2609
2951
  if (!Array.isArray(props.reasonReference)) {
2610
2952
  props.reasonReference = [props.reasonReference];
@@ -2670,12 +3012,21 @@ function DeviceUseStatement_default(props) {
2670
3012
  if (!_31.isNil(props.device)) {
2671
3013
  resource.device = reference(props.device);
2672
3014
  }
3015
+ if (!_31.isNil(props.reasonCode)) {
3016
+ if (!Array.isArray(props.reasonCode)) {
3017
+ props.reasonCode = [props.reasonCode];
3018
+ }
3019
+ resource.reasonCode = concept(props.reasonCode);
3020
+ }
2673
3021
  if (!_31.isNil(props.reasonReference)) {
2674
3022
  if (!Array.isArray(props.reasonReference)) {
2675
3023
  props.reasonReference = [props.reasonReference];
2676
3024
  }
2677
3025
  resource.reasonReference = reference(props.reasonReference);
2678
3026
  }
3027
+ if (!_31.isNil(props.bodySite)) {
3028
+ resource.bodySite = concept(props.bodySite);
3029
+ }
2679
3030
  return resource;
2680
3031
  }
2681
3032
 
@@ -2698,6 +3049,15 @@ function DiagnosticReport_default(props) {
2698
3049
  }
2699
3050
  resource.basedOn = reference(props.basedOn);
2700
3051
  }
3052
+ if (!_32.isNil(props.category)) {
3053
+ if (!Array.isArray(props.category)) {
3054
+ props.category = [props.category];
3055
+ }
3056
+ resource.category = concept(props.category);
3057
+ }
3058
+ if (!_32.isNil(props.code)) {
3059
+ resource.code = concept(props.code);
3060
+ }
2701
3061
  if (!_32.isNil(props.subject)) {
2702
3062
  resource.subject = reference(props.subject);
2703
3063
  }
@@ -2751,6 +3111,12 @@ function DiagnosticReport_default(props) {
2751
3111
  resource.media.push(_media);
2752
3112
  }
2753
3113
  }
3114
+ if (!_32.isNil(props.conclusionCode)) {
3115
+ if (!Array.isArray(props.conclusionCode)) {
3116
+ props.conclusionCode = [props.conclusionCode];
3117
+ }
3118
+ resource.conclusionCode = concept(props.conclusionCode);
3119
+ }
2754
3120
  return resource;
2755
3121
  }
2756
3122
 
@@ -2802,6 +3168,18 @@ function Encounter_default(props) {
2802
3168
  resource.classHistory.push(_classHistory);
2803
3169
  }
2804
3170
  }
3171
+ if (!_33.isNil(props.type)) {
3172
+ if (!Array.isArray(props.type)) {
3173
+ props.type = [props.type];
3174
+ }
3175
+ resource.type = concept(props.type);
3176
+ }
3177
+ if (!_33.isNil(props.serviceType)) {
3178
+ resource.serviceType = concept(props.serviceType);
3179
+ }
3180
+ if (!_33.isNil(props.priority)) {
3181
+ resource.priority = concept(props.priority);
3182
+ }
2805
3183
  if (!_33.isNil(props.subject)) {
2806
3184
  resource.subject = reference(props.subject);
2807
3185
  }
@@ -2836,6 +3214,12 @@ function Encounter_default(props) {
2836
3214
  }
2837
3215
  resource.appointment = reference(props.appointment);
2838
3216
  }
3217
+ if (!_33.isNil(props.reasonCode)) {
3218
+ if (!Array.isArray(props.reasonCode)) {
3219
+ props.reasonCode = [props.reasonCode];
3220
+ }
3221
+ resource.reasonCode = concept(props.reasonCode);
3222
+ }
2839
3223
  if (!_33.isNil(props.reasonReference)) {
2840
3224
  if (!Array.isArray(props.reasonReference)) {
2841
3225
  props.reasonReference = [props.reasonReference];
@@ -2969,6 +3353,12 @@ function EpisodeOfCare_default(props) {
2969
3353
  resource.statusHistory.push(_statusHistory);
2970
3354
  }
2971
3355
  }
3356
+ if (!_36.isNil(props.type)) {
3357
+ if (!Array.isArray(props.type)) {
3358
+ props.type = [props.type];
3359
+ }
3360
+ resource.type = concept(props.type);
3361
+ }
2972
3362
  if (!_36.isNil(props.diagnosis)) {
2973
3363
  let src = props.diagnosis;
2974
3364
  if (!Array.isArray(src)) {
@@ -3029,6 +3419,18 @@ function EventDefinition_default(props) {
3029
3419
  delete resource.subject;
3030
3420
  composite(resource, "subject", props.subject);
3031
3421
  }
3422
+ if (!_37.isNil(props.jurisdiction)) {
3423
+ if (!Array.isArray(props.jurisdiction)) {
3424
+ props.jurisdiction = [props.jurisdiction];
3425
+ }
3426
+ resource.jurisdiction = concept(props.jurisdiction);
3427
+ }
3428
+ if (!_37.isNil(props.topic)) {
3429
+ if (!Array.isArray(props.topic)) {
3430
+ props.topic = [props.topic];
3431
+ }
3432
+ resource.topic = concept(props.topic);
3433
+ }
3032
3434
  return resource;
3033
3435
  }
3034
3436
 
@@ -3062,6 +3464,12 @@ function Evidence_default(props) {
3062
3464
  resource.variableDefinition.push(_variableDefinition);
3063
3465
  }
3064
3466
  }
3467
+ if (!_38.isNil(props.synthesisType)) {
3468
+ resource.synthesisType = concept(props.synthesisType);
3469
+ }
3470
+ if (!_38.isNil(props.studyType)) {
3471
+ resource.studyType = concept(props.studyType);
3472
+ }
3065
3473
  if (!_38.isNil(props.statistic)) {
3066
3474
  let src = props.statistic;
3067
3475
  if (!Array.isArray(src)) {
@@ -3114,6 +3522,9 @@ function EvidenceReport_default(props) {
3114
3522
  delete resource.citeAs;
3115
3523
  composite(resource, "citeAs", props.citeAs);
3116
3524
  }
3525
+ if (!_39.isNil(props.type)) {
3526
+ resource.type = concept(props.type);
3527
+ }
3117
3528
  if (!_39.isNil(props.subject)) {
3118
3529
  let src = props.subject;
3119
3530
  let _subject = {
@@ -3205,6 +3616,12 @@ function ExplanationOfBenefit_default(props) {
3205
3616
  }
3206
3617
  resource.identifier = identifier(props.identifier);
3207
3618
  }
3619
+ if (!_41.isNil(props.type)) {
3620
+ resource.type = concept(props.type);
3621
+ }
3622
+ if (!_41.isNil(props.subType)) {
3623
+ resource.subType = concept(props.subType);
3624
+ }
3208
3625
  if (!_41.isNil(props.patient)) {
3209
3626
  resource.patient = reference(props.patient);
3210
3627
  }
@@ -3217,6 +3634,15 @@ function ExplanationOfBenefit_default(props) {
3217
3634
  if (!_41.isNil(props.provider)) {
3218
3635
  resource.provider = reference(props.provider);
3219
3636
  }
3637
+ if (!_41.isNil(props.priority)) {
3638
+ resource.priority = concept(props.priority);
3639
+ }
3640
+ if (!_41.isNil(props.fundsReserveRequested)) {
3641
+ resource.fundsReserveRequested = concept(props.fundsReserveRequested);
3642
+ }
3643
+ if (!_41.isNil(props.fundsReserve)) {
3644
+ resource.fundsReserve = concept(props.fundsReserve);
3645
+ }
3220
3646
  if (!_41.isNil(props.related)) {
3221
3647
  let src = props.related;
3222
3648
  if (!Array.isArray(src)) {
@@ -3373,6 +3799,9 @@ function ExplanationOfBenefit_default(props) {
3373
3799
  };
3374
3800
  resource.payment = _payment;
3375
3801
  }
3802
+ if (!_41.isNil(props.formCode)) {
3803
+ resource.formCode = concept(props.formCode);
3804
+ }
3376
3805
  if (!_41.isNil(props.processNote)) {
3377
3806
  let src = props.processNote;
3378
3807
  if (!Array.isArray(src)) {
@@ -3415,9 +3844,18 @@ function FamilyMemberHistory_default(props) {
3415
3844
  }
3416
3845
  resource.identifier = identifier(props.identifier);
3417
3846
  }
3847
+ if (!_42.isNil(props.dataAbsentReason)) {
3848
+ resource.dataAbsentReason = concept(props.dataAbsentReason);
3849
+ }
3418
3850
  if (!_42.isNil(props.patient)) {
3419
3851
  resource.patient = reference(props.patient);
3420
3852
  }
3853
+ if (!_42.isNil(props.relationship)) {
3854
+ resource.relationship = concept(props.relationship);
3855
+ }
3856
+ if (!_42.isNil(props.sex)) {
3857
+ resource.sex = concept(props.sex);
3858
+ }
3421
3859
  if (!_42.isNil(props.born)) {
3422
3860
  delete resource.born;
3423
3861
  composite(resource, "born", props.born);
@@ -3430,6 +3868,12 @@ function FamilyMemberHistory_default(props) {
3430
3868
  delete resource.deceased;
3431
3869
  composite(resource, "deceased", props.deceased);
3432
3870
  }
3871
+ if (!_42.isNil(props.reasonCode)) {
3872
+ if (!Array.isArray(props.reasonCode)) {
3873
+ props.reasonCode = [props.reasonCode];
3874
+ }
3875
+ resource.reasonCode = concept(props.reasonCode);
3876
+ }
3433
3877
  if (!_42.isNil(props.reasonReference)) {
3434
3878
  if (!Array.isArray(props.reasonReference)) {
3435
3879
  props.reasonReference = [props.reasonReference];
@@ -3465,6 +3909,15 @@ function Flag_default(props) {
3465
3909
  }
3466
3910
  resource.identifier = identifier(props.identifier);
3467
3911
  }
3912
+ if (!_43.isNil(props.category)) {
3913
+ if (!Array.isArray(props.category)) {
3914
+ props.category = [props.category];
3915
+ }
3916
+ resource.category = concept(props.category);
3917
+ }
3918
+ if (!_43.isNil(props.code)) {
3919
+ resource.code = concept(props.code);
3920
+ }
3468
3921
  if (!_43.isNil(props.subject)) {
3469
3922
  resource.subject = reference(props.subject);
3470
3923
  }
@@ -3490,6 +3943,21 @@ function Goal_default(props) {
3490
3943
  }
3491
3944
  resource.identifier = identifier(props.identifier);
3492
3945
  }
3946
+ if (!_44.isNil(props.achievementStatus)) {
3947
+ resource.achievementStatus = concept(props.achievementStatus);
3948
+ }
3949
+ if (!_44.isNil(props.category)) {
3950
+ if (!Array.isArray(props.category)) {
3951
+ props.category = [props.category];
3952
+ }
3953
+ resource.category = concept(props.category);
3954
+ }
3955
+ if (!_44.isNil(props.priority)) {
3956
+ resource.priority = concept(props.priority);
3957
+ }
3958
+ if (!_44.isNil(props.description)) {
3959
+ resource.description = concept(props.description);
3960
+ }
3493
3961
  if (!_44.isNil(props.subject)) {
3494
3962
  resource.subject = reference(props.subject);
3495
3963
  }
@@ -3519,6 +3987,12 @@ function Goal_default(props) {
3519
3987
  }
3520
3988
  resource.addresses = reference(props.addresses);
3521
3989
  }
3990
+ if (!_44.isNil(props.outcomeCode)) {
3991
+ if (!Array.isArray(props.outcomeCode)) {
3992
+ props.outcomeCode = [props.outcomeCode];
3993
+ }
3994
+ resource.outcomeCode = concept(props.outcomeCode);
3995
+ }
3522
3996
  if (!_44.isNil(props.outcomeReference)) {
3523
3997
  if (!Array.isArray(props.outcomeReference)) {
3524
3998
  props.outcomeReference = [props.outcomeReference];
@@ -3541,6 +4015,9 @@ function Group_default(props) {
3541
4015
  }
3542
4016
  resource.identifier = identifier(props.identifier);
3543
4017
  }
4018
+ if (!_45.isNil(props.code)) {
4019
+ resource.code = concept(props.code);
4020
+ }
3544
4021
  if (!_45.isNil(props.managingEntity)) {
3545
4022
  resource.managingEntity = reference(props.managingEntity);
3546
4023
  }
@@ -3602,6 +4079,12 @@ function GuidanceResponse_default(props) {
3602
4079
  if (!_46.isNil(props.performer)) {
3603
4080
  resource.performer = reference(props.performer);
3604
4081
  }
4082
+ if (!_46.isNil(props.reasonCode)) {
4083
+ if (!Array.isArray(props.reasonCode)) {
4084
+ props.reasonCode = [props.reasonCode];
4085
+ }
4086
+ resource.reasonCode = concept(props.reasonCode);
4087
+ }
3605
4088
  if (!_46.isNil(props.reasonReference)) {
3606
4089
  if (!Array.isArray(props.reasonReference)) {
3607
4090
  props.reasonReference = [props.reasonReference];
@@ -3639,6 +4122,24 @@ function HealthcareService_default(props) {
3639
4122
  if (!_47.isNil(props.providedBy)) {
3640
4123
  resource.providedBy = reference(props.providedBy);
3641
4124
  }
4125
+ if (!_47.isNil(props.category)) {
4126
+ if (!Array.isArray(props.category)) {
4127
+ props.category = [props.category];
4128
+ }
4129
+ resource.category = concept(props.category);
4130
+ }
4131
+ if (!_47.isNil(props.type)) {
4132
+ if (!Array.isArray(props.type)) {
4133
+ props.type = [props.type];
4134
+ }
4135
+ resource.type = concept(props.type);
4136
+ }
4137
+ if (!_47.isNil(props.specialty)) {
4138
+ if (!Array.isArray(props.specialty)) {
4139
+ props.specialty = [props.specialty];
4140
+ }
4141
+ resource.specialty = concept(props.specialty);
4142
+ }
3642
4143
  if (!_47.isNil(props.location)) {
3643
4144
  if (!Array.isArray(props.location)) {
3644
4145
  props.location = [props.location];
@@ -3651,6 +4152,12 @@ function HealthcareService_default(props) {
3651
4152
  }
3652
4153
  resource.coverageArea = reference(props.coverageArea);
3653
4154
  }
4155
+ if (!_47.isNil(props.serviceProvisionCode)) {
4156
+ if (!Array.isArray(props.serviceProvisionCode)) {
4157
+ props.serviceProvisionCode = [props.serviceProvisionCode];
4158
+ }
4159
+ resource.serviceProvisionCode = concept(props.serviceProvisionCode);
4160
+ }
3654
4161
  if (!_47.isNil(props.eligibility)) {
3655
4162
  let src = props.eligibility;
3656
4163
  if (!Array.isArray(src)) {
@@ -3664,6 +4171,30 @@ function HealthcareService_default(props) {
3664
4171
  resource.eligibility.push(_eligibility);
3665
4172
  }
3666
4173
  }
4174
+ if (!_47.isNil(props.program)) {
4175
+ if (!Array.isArray(props.program)) {
4176
+ props.program = [props.program];
4177
+ }
4178
+ resource.program = concept(props.program);
4179
+ }
4180
+ if (!_47.isNil(props.characteristic)) {
4181
+ if (!Array.isArray(props.characteristic)) {
4182
+ props.characteristic = [props.characteristic];
4183
+ }
4184
+ resource.characteristic = concept(props.characteristic);
4185
+ }
4186
+ if (!_47.isNil(props.communication)) {
4187
+ if (!Array.isArray(props.communication)) {
4188
+ props.communication = [props.communication];
4189
+ }
4190
+ resource.communication = concept(props.communication);
4191
+ }
4192
+ if (!_47.isNil(props.referralMethod)) {
4193
+ if (!Array.isArray(props.referralMethod)) {
4194
+ props.referralMethod = [props.referralMethod];
4195
+ }
4196
+ resource.referralMethod = concept(props.referralMethod);
4197
+ }
3667
4198
  if (!_47.isNil(props.availableTime)) {
3668
4199
  let src = props.availableTime;
3669
4200
  if (!Array.isArray(src)) {
@@ -3742,9 +4273,21 @@ function ImagingStudy_default(props) {
3742
4273
  if (!_48.isNil(props.procedureReference)) {
3743
4274
  resource.procedureReference = reference(props.procedureReference);
3744
4275
  }
4276
+ if (!_48.isNil(props.procedureCode)) {
4277
+ if (!Array.isArray(props.procedureCode)) {
4278
+ props.procedureCode = [props.procedureCode];
4279
+ }
4280
+ resource.procedureCode = concept(props.procedureCode);
4281
+ }
3745
4282
  if (!_48.isNil(props.location)) {
3746
4283
  resource.location = reference(props.location);
3747
4284
  }
4285
+ if (!_48.isNil(props.reasonCode)) {
4286
+ if (!Array.isArray(props.reasonCode)) {
4287
+ props.reasonCode = [props.reasonCode];
4288
+ }
4289
+ resource.reasonCode = concept(props.reasonCode);
4290
+ }
3748
4291
  if (!_48.isNil(props.reasonReference)) {
3749
4292
  if (!Array.isArray(props.reasonReference)) {
3750
4293
  props.reasonReference = [props.reasonReference];
@@ -3780,6 +4323,12 @@ function Immunization_default(props) {
3780
4323
  }
3781
4324
  resource.identifier = identifier(props.identifier);
3782
4325
  }
4326
+ if (!_49.isNil(props.statusReason)) {
4327
+ resource.statusReason = concept(props.statusReason);
4328
+ }
4329
+ if (!_49.isNil(props.vaccineCode)) {
4330
+ resource.vaccineCode = concept(props.vaccineCode);
4331
+ }
3783
4332
  if (!_49.isNil(props.patient)) {
3784
4333
  resource.patient = reference(props.patient);
3785
4334
  }
@@ -3790,12 +4339,21 @@ function Immunization_default(props) {
3790
4339
  delete resource.occurrence;
3791
4340
  composite(resource, "occurrence", props.occurrence);
3792
4341
  }
4342
+ if (!_49.isNil(props.reportOrigin)) {
4343
+ resource.reportOrigin = concept(props.reportOrigin);
4344
+ }
3793
4345
  if (!_49.isNil(props.location)) {
3794
4346
  resource.location = reference(props.location);
3795
4347
  }
3796
4348
  if (!_49.isNil(props.manufacturer)) {
3797
4349
  resource.manufacturer = reference(props.manufacturer);
3798
4350
  }
4351
+ if (!_49.isNil(props.site)) {
4352
+ resource.site = concept(props.site);
4353
+ }
4354
+ if (!_49.isNil(props.route)) {
4355
+ resource.route = concept(props.route);
4356
+ }
3799
4357
  if (!_49.isNil(props.performer)) {
3800
4358
  let src = props.performer;
3801
4359
  if (!Array.isArray(src)) {
@@ -3809,12 +4367,24 @@ function Immunization_default(props) {
3809
4367
  resource.performer.push(_performer);
3810
4368
  }
3811
4369
  }
4370
+ if (!_49.isNil(props.reasonCode)) {
4371
+ if (!Array.isArray(props.reasonCode)) {
4372
+ props.reasonCode = [props.reasonCode];
4373
+ }
4374
+ resource.reasonCode = concept(props.reasonCode);
4375
+ }
3812
4376
  if (!_49.isNil(props.reasonReference)) {
3813
4377
  if (!Array.isArray(props.reasonReference)) {
3814
4378
  props.reasonReference = [props.reasonReference];
3815
4379
  }
3816
4380
  resource.reasonReference = reference(props.reasonReference);
3817
4381
  }
4382
+ if (!_49.isNil(props.subpotentReason)) {
4383
+ if (!Array.isArray(props.subpotentReason)) {
4384
+ props.subpotentReason = [props.subpotentReason];
4385
+ }
4386
+ resource.subpotentReason = concept(props.subpotentReason);
4387
+ }
3818
4388
  if (!_49.isNil(props.education)) {
3819
4389
  let src = props.education;
3820
4390
  if (!Array.isArray(src)) {
@@ -3828,6 +4398,15 @@ function Immunization_default(props) {
3828
4398
  resource.education.push(_education);
3829
4399
  }
3830
4400
  }
4401
+ if (!_49.isNil(props.programEligibility)) {
4402
+ if (!Array.isArray(props.programEligibility)) {
4403
+ props.programEligibility = [props.programEligibility];
4404
+ }
4405
+ resource.programEligibility = concept(props.programEligibility);
4406
+ }
4407
+ if (!_49.isNil(props.fundingSource)) {
4408
+ resource.fundingSource = concept(props.fundingSource);
4409
+ }
3831
4410
  if (!_49.isNil(props.reaction)) {
3832
4411
  let src = props.reaction;
3833
4412
  if (!Array.isArray(src)) {
@@ -3876,9 +4455,21 @@ function ImmunizationEvaluation_default(props) {
3876
4455
  if (!_50.isNil(props.authority)) {
3877
4456
  resource.authority = reference(props.authority);
3878
4457
  }
4458
+ if (!_50.isNil(props.targetDisease)) {
4459
+ resource.targetDisease = concept(props.targetDisease);
4460
+ }
3879
4461
  if (!_50.isNil(props.immunizationEvent)) {
3880
4462
  resource.immunizationEvent = reference(props.immunizationEvent);
3881
4463
  }
4464
+ if (!_50.isNil(props.doseStatus)) {
4465
+ resource.doseStatus = concept(props.doseStatus);
4466
+ }
4467
+ if (!_50.isNil(props.doseStatusReason)) {
4468
+ if (!Array.isArray(props.doseStatusReason)) {
4469
+ props.doseStatusReason = [props.doseStatusReason];
4470
+ }
4471
+ resource.doseStatusReason = concept(props.doseStatusReason);
4472
+ }
3882
4473
  if (!_50.isNil(props.doseNumber)) {
3883
4474
  delete resource.doseNumber;
3884
4475
  composite(resource, "doseNumber", props.doseNumber);
@@ -3941,6 +4532,15 @@ function Ingredient_default(props) {
3941
4532
  }
3942
4533
  resource.for = reference(props.for);
3943
4534
  }
4535
+ if (!_52.isNil(props.role)) {
4536
+ resource.role = concept(props.role);
4537
+ }
4538
+ if (!_52.isNil(props.function)) {
4539
+ if (!Array.isArray(props.function)) {
4540
+ props.function = [props.function];
4541
+ }
4542
+ resource.function = concept(props.function);
4543
+ }
3944
4544
  if (!_52.isNil(props.manufacturer)) {
3945
4545
  let src = props.manufacturer;
3946
4546
  if (!Array.isArray(src)) {
@@ -3977,6 +4577,12 @@ function InsurancePlan_default(props) {
3977
4577
  }
3978
4578
  resource.identifier = identifier(props.identifier);
3979
4579
  }
4580
+ if (!_53.isNil(props.type)) {
4581
+ if (!Array.isArray(props.type)) {
4582
+ props.type = [props.type];
4583
+ }
4584
+ resource.type = concept(props.type);
4585
+ }
3980
4586
  if (!_53.isNil(props.ownedBy)) {
3981
4587
  resource.ownedBy = reference(props.ownedBy);
3982
4588
  }
@@ -4056,6 +4662,9 @@ function Invoice_default(props) {
4056
4662
  }
4057
4663
  resource.identifier = identifier(props.identifier);
4058
4664
  }
4665
+ if (!_54.isNil(props.type)) {
4666
+ resource.type = concept(props.type);
4667
+ }
4059
4668
  if (!_54.isNil(props.subject)) {
4060
4669
  resource.subject = reference(props.subject);
4061
4670
  }
@@ -4110,10 +4719,25 @@ function Library_default(props) {
4110
4719
  }
4111
4720
  resource.identifier = identifier(props.identifier);
4112
4721
  }
4722
+ if (!_55.isNil(props.type)) {
4723
+ resource.type = concept(props.type);
4724
+ }
4113
4725
  if (!_55.isNil(props.subject)) {
4114
4726
  delete resource.subject;
4115
4727
  composite(resource, "subject", props.subject);
4116
4728
  }
4729
+ if (!_55.isNil(props.jurisdiction)) {
4730
+ if (!Array.isArray(props.jurisdiction)) {
4731
+ props.jurisdiction = [props.jurisdiction];
4732
+ }
4733
+ resource.jurisdiction = concept(props.jurisdiction);
4734
+ }
4735
+ if (!_55.isNil(props.topic)) {
4736
+ if (!Array.isArray(props.topic)) {
4737
+ props.topic = [props.topic];
4738
+ }
4739
+ resource.topic = concept(props.topic);
4740
+ }
4117
4741
  return resource;
4118
4742
  }
4119
4743
 
@@ -4130,6 +4754,9 @@ function List_default(props) {
4130
4754
  }
4131
4755
  resource.identifier = identifier(props.identifier);
4132
4756
  }
4757
+ if (!_56.isNil(props.code)) {
4758
+ resource.code = concept(props.code);
4759
+ }
4133
4760
  if (!_56.isNil(props.subject)) {
4134
4761
  resource.subject = reference(props.subject);
4135
4762
  }
@@ -4139,6 +4766,9 @@ function List_default(props) {
4139
4766
  if (!_56.isNil(props.source)) {
4140
4767
  resource.source = reference(props.source);
4141
4768
  }
4769
+ if (!_56.isNil(props.orderedBy)) {
4770
+ resource.orderedBy = concept(props.orderedBy);
4771
+ }
4142
4772
  if (!_56.isNil(props.entry)) {
4143
4773
  let src = props.entry;
4144
4774
  if (!Array.isArray(src)) {
@@ -4152,6 +4782,9 @@ function List_default(props) {
4152
4782
  resource.entry.push(_entry);
4153
4783
  }
4154
4784
  }
4785
+ if (!_56.isNil(props.emptyReason)) {
4786
+ resource.emptyReason = concept(props.emptyReason);
4787
+ }
4155
4788
  return resource;
4156
4789
  }
4157
4790
 
@@ -4168,6 +4801,15 @@ function Location_default(props) {
4168
4801
  }
4169
4802
  resource.identifier = identifier(props.identifier);
4170
4803
  }
4804
+ if (!_57.isNil(props.type)) {
4805
+ if (!Array.isArray(props.type)) {
4806
+ props.type = [props.type];
4807
+ }
4808
+ resource.type = concept(props.type);
4809
+ }
4810
+ if (!_57.isNil(props.physicalType)) {
4811
+ resource.physicalType = concept(props.physicalType);
4812
+ }
4171
4813
  if (!_57.isNil(props.position)) {
4172
4814
  let src = props.position;
4173
4815
  let _position = {
@@ -4216,12 +4858,24 @@ function ManufacturedItemDefinition_default(props) {
4216
4858
  }
4217
4859
  resource.identifier = identifier(props.identifier);
4218
4860
  }
4861
+ if (!_58.isNil(props.manufacturedDoseForm)) {
4862
+ resource.manufacturedDoseForm = concept(props.manufacturedDoseForm);
4863
+ }
4864
+ if (!_58.isNil(props.unitOfPresentation)) {
4865
+ resource.unitOfPresentation = concept(props.unitOfPresentation);
4866
+ }
4219
4867
  if (!_58.isNil(props.manufacturer)) {
4220
4868
  if (!Array.isArray(props.manufacturer)) {
4221
4869
  props.manufacturer = [props.manufacturer];
4222
4870
  }
4223
4871
  resource.manufacturer = reference(props.manufacturer);
4224
4872
  }
4873
+ if (!_58.isNil(props.ingredient)) {
4874
+ if (!Array.isArray(props.ingredient)) {
4875
+ props.ingredient = [props.ingredient];
4876
+ }
4877
+ resource.ingredient = concept(props.ingredient);
4878
+ }
4225
4879
  if (!_58.isNil(props.property)) {
4226
4880
  let src = props.property;
4227
4881
  if (!Array.isArray(src)) {
@@ -4255,6 +4909,33 @@ function Measure_default(props) {
4255
4909
  delete resource.subject;
4256
4910
  composite(resource, "subject", props.subject);
4257
4911
  }
4912
+ if (!_59.isNil(props.jurisdiction)) {
4913
+ if (!Array.isArray(props.jurisdiction)) {
4914
+ props.jurisdiction = [props.jurisdiction];
4915
+ }
4916
+ resource.jurisdiction = concept(props.jurisdiction);
4917
+ }
4918
+ if (!_59.isNil(props.topic)) {
4919
+ if (!Array.isArray(props.topic)) {
4920
+ props.topic = [props.topic];
4921
+ }
4922
+ resource.topic = concept(props.topic);
4923
+ }
4924
+ if (!_59.isNil(props.scoring)) {
4925
+ resource.scoring = concept(props.scoring);
4926
+ }
4927
+ if (!_59.isNil(props.compositeScoring)) {
4928
+ resource.compositeScoring = concept(props.compositeScoring);
4929
+ }
4930
+ if (!_59.isNil(props.type)) {
4931
+ if (!Array.isArray(props.type)) {
4932
+ props.type = [props.type];
4933
+ }
4934
+ resource.type = concept(props.type);
4935
+ }
4936
+ if (!_59.isNil(props.improvementNotation)) {
4937
+ resource.improvementNotation = concept(props.improvementNotation);
4938
+ }
4258
4939
  if (!_59.isNil(props.group)) {
4259
4940
  let src = props.group;
4260
4941
  if (!Array.isArray(src)) {
@@ -4303,6 +4984,9 @@ function MeasureReport_default(props) {
4303
4984
  if (!_60.isNil(props.reporter)) {
4304
4985
  resource.reporter = reference(props.reporter);
4305
4986
  }
4987
+ if (!_60.isNil(props.improvementNotation)) {
4988
+ resource.improvementNotation = concept(props.improvementNotation);
4989
+ }
4306
4990
  if (!_60.isNil(props.group)) {
4307
4991
  let src = props.group;
4308
4992
  if (!Array.isArray(src)) {
@@ -4350,6 +5034,15 @@ function Media_default(props) {
4350
5034
  }
4351
5035
  resource.partOf = reference(props.partOf);
4352
5036
  }
5037
+ if (!_61.isNil(props.type)) {
5038
+ resource.type = concept(props.type);
5039
+ }
5040
+ if (!_61.isNil(props.modality)) {
5041
+ resource.modality = concept(props.modality);
5042
+ }
5043
+ if (!_61.isNil(props.view)) {
5044
+ resource.view = concept(props.view);
5045
+ }
4353
5046
  if (!_61.isNil(props.subject)) {
4354
5047
  resource.subject = reference(props.subject);
4355
5048
  }
@@ -4363,6 +5056,15 @@ function Media_default(props) {
4363
5056
  if (!_61.isNil(props.operator)) {
4364
5057
  resource.operator = reference(props.operator);
4365
5058
  }
5059
+ if (!_61.isNil(props.reasonCode)) {
5060
+ if (!Array.isArray(props.reasonCode)) {
5061
+ props.reasonCode = [props.reasonCode];
5062
+ }
5063
+ resource.reasonCode = concept(props.reasonCode);
5064
+ }
5065
+ if (!_61.isNil(props.bodySite)) {
5066
+ resource.bodySite = concept(props.bodySite);
5067
+ }
4366
5068
  if (!_61.isNil(props.device)) {
4367
5069
  resource.device = reference(props.device);
4368
5070
  }
@@ -4382,9 +5084,15 @@ function Medication_default(props) {
4382
5084
  }
4383
5085
  resource.identifier = identifier(props.identifier);
4384
5086
  }
5087
+ if (!_62.isNil(props.code)) {
5088
+ resource.code = concept(props.code);
5089
+ }
4385
5090
  if (!_62.isNil(props.manufacturer)) {
4386
5091
  resource.manufacturer = reference(props.manufacturer);
4387
5092
  }
5093
+ if (!_62.isNil(props.form)) {
5094
+ resource.form = concept(props.form);
5095
+ }
4388
5096
  if (!_62.isNil(props.ingredient)) {
4389
5097
  let src = props.ingredient;
4390
5098
  if (!Array.isArray(src)) {
@@ -4427,6 +5135,15 @@ function MedicationAdministration_default(props) {
4427
5135
  }
4428
5136
  resource.partOf = reference(props.partOf);
4429
5137
  }
5138
+ if (!_63.isNil(props.statusReason)) {
5139
+ if (!Array.isArray(props.statusReason)) {
5140
+ props.statusReason = [props.statusReason];
5141
+ }
5142
+ resource.statusReason = concept(props.statusReason);
5143
+ }
5144
+ if (!_63.isNil(props.category)) {
5145
+ resource.category = concept(props.category);
5146
+ }
4430
5147
  if (!_63.isNil(props.medication)) {
4431
5148
  delete resource.medication;
4432
5149
  composite(resource, "medication", props.medication);
@@ -4460,6 +5177,12 @@ function MedicationAdministration_default(props) {
4460
5177
  resource.performer.push(_performer);
4461
5178
  }
4462
5179
  }
5180
+ if (!_63.isNil(props.reasonCode)) {
5181
+ if (!Array.isArray(props.reasonCode)) {
5182
+ props.reasonCode = [props.reasonCode];
5183
+ }
5184
+ resource.reasonCode = concept(props.reasonCode);
5185
+ }
4463
5186
  if (!_63.isNil(props.reasonReference)) {
4464
5187
  if (!Array.isArray(props.reasonReference)) {
4465
5188
  props.reasonReference = [props.reasonReference];
@@ -4514,6 +5237,9 @@ function MedicationDispense_default(props) {
4514
5237
  delete resource.statusReason;
4515
5238
  composite(resource, "statusReason", props.statusReason);
4516
5239
  }
5240
+ if (!_64.isNil(props.category)) {
5241
+ resource.category = concept(props.category);
5242
+ }
4517
5243
  if (!_64.isNil(props.medication)) {
4518
5244
  delete resource.medication;
4519
5245
  composite(resource, "medication", props.medication);
@@ -4552,6 +5278,9 @@ function MedicationDispense_default(props) {
4552
5278
  }
4553
5279
  resource.authorizingPrescription = reference(props.authorizingPrescription);
4554
5280
  }
5281
+ if (!_64.isNil(props.type)) {
5282
+ resource.type = concept(props.type);
5283
+ }
4555
5284
  if (!_64.isNil(props.destination)) {
4556
5285
  resource.destination = reference(props.destination);
4557
5286
  }
@@ -4590,9 +5319,15 @@ function MedicationKnowledge_default(props) {
4590
5319
  resourceType: "MedicationKnowledge",
4591
5320
  ...props
4592
5321
  };
5322
+ if (!_65.isNil(props.code)) {
5323
+ resource.code = concept(props.code);
5324
+ }
4593
5325
  if (!_65.isNil(props.manufacturer)) {
4594
5326
  resource.manufacturer = reference(props.manufacturer);
4595
5327
  }
5328
+ if (!_65.isNil(props.doseForm)) {
5329
+ resource.doseForm = concept(props.doseForm);
5330
+ }
4596
5331
  if (!_65.isNil(props.relatedMedicationKnowledge)) {
4597
5332
  let src = props.relatedMedicationKnowledge;
4598
5333
  if (!Array.isArray(src)) {
@@ -4612,6 +5347,12 @@ function MedicationKnowledge_default(props) {
4612
5347
  }
4613
5348
  resource.associatedMedication = reference(props.associatedMedication);
4614
5349
  }
5350
+ if (!_65.isNil(props.productType)) {
5351
+ if (!Array.isArray(props.productType)) {
5352
+ props.productType = [props.productType];
5353
+ }
5354
+ resource.productType = concept(props.productType);
5355
+ }
4615
5356
  if (!_65.isNil(props.monograph)) {
4616
5357
  let src = props.monograph;
4617
5358
  if (!Array.isArray(src)) {
@@ -4638,6 +5379,12 @@ function MedicationKnowledge_default(props) {
4638
5379
  resource.ingredient.push(_ingredient);
4639
5380
  }
4640
5381
  }
5382
+ if (!_65.isNil(props.intendedRoute)) {
5383
+ if (!Array.isArray(props.intendedRoute)) {
5384
+ props.intendedRoute = [props.intendedRoute];
5385
+ }
5386
+ resource.intendedRoute = concept(props.intendedRoute);
5387
+ }
4641
5388
  if (!_65.isNil(props.cost)) {
4642
5389
  let src = props.cost;
4643
5390
  if (!Array.isArray(src)) {
@@ -4758,6 +5505,15 @@ function MedicationRequest_default(props) {
4758
5505
  }
4759
5506
  resource.identifier = identifier(props.identifier);
4760
5507
  }
5508
+ if (!_66.isNil(props.statusReason)) {
5509
+ resource.statusReason = concept(props.statusReason);
5510
+ }
5511
+ if (!_66.isNil(props.category)) {
5512
+ if (!Array.isArray(props.category)) {
5513
+ props.category = [props.category];
5514
+ }
5515
+ resource.category = concept(props.category);
5516
+ }
4761
5517
  if (!_66.isNil(props.reported)) {
4762
5518
  delete resource.reported;
4763
5519
  composite(resource, "reported", props.reported);
@@ -4784,9 +5540,18 @@ function MedicationRequest_default(props) {
4784
5540
  if (!_66.isNil(props.performer)) {
4785
5541
  resource.performer = reference(props.performer);
4786
5542
  }
5543
+ if (!_66.isNil(props.performerType)) {
5544
+ resource.performerType = concept(props.performerType);
5545
+ }
4787
5546
  if (!_66.isNil(props.recorder)) {
4788
5547
  resource.recorder = reference(props.recorder);
4789
5548
  }
5549
+ if (!_66.isNil(props.reasonCode)) {
5550
+ if (!Array.isArray(props.reasonCode)) {
5551
+ props.reasonCode = [props.reasonCode];
5552
+ }
5553
+ resource.reasonCode = concept(props.reasonCode);
5554
+ }
4790
5555
  if (!_66.isNil(props.reasonReference)) {
4791
5556
  if (!Array.isArray(props.reasonReference)) {
4792
5557
  props.reasonReference = [props.reasonReference];
@@ -4802,6 +5567,9 @@ function MedicationRequest_default(props) {
4802
5567
  if (!_66.isNil(props.groupIdentifier)) {
4803
5568
  resource.groupIdentifier = identifier(props.groupIdentifier);
4804
5569
  }
5570
+ if (!_66.isNil(props.courseOfTherapyType)) {
5571
+ resource.courseOfTherapyType = concept(props.courseOfTherapyType);
5572
+ }
4805
5573
  if (!_66.isNil(props.insurance)) {
4806
5574
  if (!Array.isArray(props.insurance)) {
4807
5575
  props.insurance = [props.insurance];
@@ -4865,6 +5633,15 @@ function MedicationStatement_default(props) {
4865
5633
  }
4866
5634
  resource.partOf = reference(props.partOf);
4867
5635
  }
5636
+ if (!_67.isNil(props.statusReason)) {
5637
+ if (!Array.isArray(props.statusReason)) {
5638
+ props.statusReason = [props.statusReason];
5639
+ }
5640
+ resource.statusReason = concept(props.statusReason);
5641
+ }
5642
+ if (!_67.isNil(props.category)) {
5643
+ resource.category = concept(props.category);
5644
+ }
4868
5645
  if (!_67.isNil(props.medication)) {
4869
5646
  delete resource.medication;
4870
5647
  composite(resource, "medication", props.medication);
@@ -4888,6 +5665,12 @@ function MedicationStatement_default(props) {
4888
5665
  }
4889
5666
  resource.derivedFrom = reference(props.derivedFrom);
4890
5667
  }
5668
+ if (!_67.isNil(props.reasonCode)) {
5669
+ if (!Array.isArray(props.reasonCode)) {
5670
+ props.reasonCode = [props.reasonCode];
5671
+ }
5672
+ resource.reasonCode = concept(props.reasonCode);
5673
+ }
4891
5674
  if (!_67.isNil(props.reasonReference)) {
4892
5675
  if (!Array.isArray(props.reasonReference)) {
4893
5676
  props.reasonReference = [props.reasonReference];
@@ -4910,6 +5693,57 @@ function MedicinalProductDefinition_default(props) {
4910
5693
  }
4911
5694
  resource.identifier = identifier(props.identifier);
4912
5695
  }
5696
+ if (!_68.isNil(props.type)) {
5697
+ resource.type = concept(props.type);
5698
+ }
5699
+ if (!_68.isNil(props.domain)) {
5700
+ resource.domain = concept(props.domain);
5701
+ }
5702
+ if (!_68.isNil(props.status)) {
5703
+ resource.status = concept(props.status);
5704
+ }
5705
+ if (!_68.isNil(props.combinedPharmaceuticalDoseForm)) {
5706
+ resource.combinedPharmaceuticalDoseForm = concept(props.combinedPharmaceuticalDoseForm);
5707
+ }
5708
+ if (!_68.isNil(props.route)) {
5709
+ if (!Array.isArray(props.route)) {
5710
+ props.route = [props.route];
5711
+ }
5712
+ resource.route = concept(props.route);
5713
+ }
5714
+ if (!_68.isNil(props.legalStatusOfSupply)) {
5715
+ resource.legalStatusOfSupply = concept(props.legalStatusOfSupply);
5716
+ }
5717
+ if (!_68.isNil(props.additionalMonitoringIndicator)) {
5718
+ resource.additionalMonitoringIndicator = concept(props.additionalMonitoringIndicator);
5719
+ }
5720
+ if (!_68.isNil(props.specialMeasures)) {
5721
+ if (!Array.isArray(props.specialMeasures)) {
5722
+ props.specialMeasures = [props.specialMeasures];
5723
+ }
5724
+ resource.specialMeasures = concept(props.specialMeasures);
5725
+ }
5726
+ if (!_68.isNil(props.pediatricUseIndicator)) {
5727
+ resource.pediatricUseIndicator = concept(props.pediatricUseIndicator);
5728
+ }
5729
+ if (!_68.isNil(props.classification)) {
5730
+ if (!Array.isArray(props.classification)) {
5731
+ props.classification = [props.classification];
5732
+ }
5733
+ resource.classification = concept(props.classification);
5734
+ }
5735
+ if (!_68.isNil(props.packagedMedicinalProduct)) {
5736
+ if (!Array.isArray(props.packagedMedicinalProduct)) {
5737
+ props.packagedMedicinalProduct = [props.packagedMedicinalProduct];
5738
+ }
5739
+ resource.packagedMedicinalProduct = concept(props.packagedMedicinalProduct);
5740
+ }
5741
+ if (!_68.isNil(props.ingredient)) {
5742
+ if (!Array.isArray(props.ingredient)) {
5743
+ props.ingredient = [props.ingredient];
5744
+ }
5745
+ resource.ingredient = concept(props.ingredient);
5746
+ }
4913
5747
  if (!_68.isNil(props.attachedDocument)) {
4914
5748
  if (!Array.isArray(props.attachedDocument)) {
4915
5749
  props.attachedDocument = [props.attachedDocument];
@@ -5117,6 +5951,18 @@ function NutritionOrder_default(props) {
5117
5951
  }
5118
5952
  resource.allergyIntolerance = reference(props.allergyIntolerance);
5119
5953
  }
5954
+ if (!_70.isNil(props.foodPreferenceModifier)) {
5955
+ if (!Array.isArray(props.foodPreferenceModifier)) {
5956
+ props.foodPreferenceModifier = [props.foodPreferenceModifier];
5957
+ }
5958
+ resource.foodPreferenceModifier = concept(props.foodPreferenceModifier);
5959
+ }
5960
+ if (!_70.isNil(props.excludeFoodModifier)) {
5961
+ if (!Array.isArray(props.excludeFoodModifier)) {
5962
+ props.excludeFoodModifier = [props.excludeFoodModifier];
5963
+ }
5964
+ resource.excludeFoodModifier = concept(props.excludeFoodModifier);
5965
+ }
5120
5966
  if (!_70.isNil(props.oralDiet)) {
5121
5967
  let src = props.oralDiet;
5122
5968
  let _oralDiet = {
@@ -5154,6 +6000,15 @@ function NutritionProduct_default(props) {
5154
6000
  resourceType: "NutritionProduct",
5155
6001
  ...props
5156
6002
  };
6003
+ if (!_71.isNil(props.category)) {
6004
+ if (!Array.isArray(props.category)) {
6005
+ props.category = [props.category];
6006
+ }
6007
+ resource.category = concept(props.category);
6008
+ }
6009
+ if (!_71.isNil(props.code)) {
6010
+ resource.code = concept(props.code);
6011
+ }
5157
6012
  if (!_71.isNil(props.manufacturer)) {
5158
6013
  if (!Array.isArray(props.manufacturer)) {
5159
6014
  props.manufacturer = [props.manufacturer];
@@ -5234,6 +6089,15 @@ function Observation_default(props) {
5234
6089
  }
5235
6090
  resource.partOf = reference(props.partOf);
5236
6091
  }
6092
+ if (!_72.isNil(props.category)) {
6093
+ if (!Array.isArray(props.category)) {
6094
+ props.category = [props.category];
6095
+ }
6096
+ resource.category = concept(props.category);
6097
+ }
6098
+ if (!_72.isNil(props.code)) {
6099
+ resource.code = concept(props.code);
6100
+ }
5237
6101
  if (!_72.isNil(props.subject)) {
5238
6102
  resource.subject = reference(props.subject);
5239
6103
  }
@@ -5260,6 +6124,21 @@ function Observation_default(props) {
5260
6124
  delete resource.value;
5261
6125
  composite(resource, "value", props.value);
5262
6126
  }
6127
+ if (!_72.isNil(props.dataAbsentReason)) {
6128
+ resource.dataAbsentReason = concept(props.dataAbsentReason);
6129
+ }
6130
+ if (!_72.isNil(props.interpretation)) {
6131
+ if (!Array.isArray(props.interpretation)) {
6132
+ props.interpretation = [props.interpretation];
6133
+ }
6134
+ resource.interpretation = concept(props.interpretation);
6135
+ }
6136
+ if (!_72.isNil(props.bodySite)) {
6137
+ resource.bodySite = concept(props.bodySite);
6138
+ }
6139
+ if (!_72.isNil(props.method)) {
6140
+ resource.method = concept(props.method);
6141
+ }
5263
6142
  if (!_72.isNil(props.specimen)) {
5264
6143
  resource.specimen = reference(props.specimen);
5265
6144
  }
@@ -5314,12 +6193,24 @@ function ObservationDefinition_default(props) {
5314
6193
  resourceType: "ObservationDefinition",
5315
6194
  ...props
5316
6195
  };
6196
+ if (!_73.isNil(props.category)) {
6197
+ if (!Array.isArray(props.category)) {
6198
+ props.category = [props.category];
6199
+ }
6200
+ resource.category = concept(props.category);
6201
+ }
6202
+ if (!_73.isNil(props.code)) {
6203
+ resource.code = concept(props.code);
6204
+ }
5317
6205
  if (!_73.isNil(props.identifier)) {
5318
6206
  if (!Array.isArray(props.identifier)) {
5319
6207
  props.identifier = [props.identifier];
5320
6208
  }
5321
6209
  resource.identifier = identifier(props.identifier);
5322
6210
  }
6211
+ if (!_73.isNil(props.method)) {
6212
+ resource.method = concept(props.method);
6213
+ }
5323
6214
  if (!_73.isNil(props.quantitativeDetails)) {
5324
6215
  let src = props.quantitativeDetails;
5325
6216
  let _quantitativeDetails = {
@@ -5368,6 +6259,12 @@ function Organization_default(props) {
5368
6259
  }
5369
6260
  resource.identifier = identifier(props.identifier);
5370
6261
  }
6262
+ if (!_74.isNil(props.type)) {
6263
+ if (!Array.isArray(props.type)) {
6264
+ props.type = [props.type];
6265
+ }
6266
+ resource.type = concept(props.type);
6267
+ }
5371
6268
  if (!_74.isNil(props.partOf)) {
5372
6269
  resource.partOf = reference(props.partOf);
5373
6270
  }
@@ -5418,6 +6315,18 @@ function OrganizationAffiliation_default(props) {
5418
6315
  }
5419
6316
  resource.network = reference(props.network);
5420
6317
  }
6318
+ if (!_75.isNil(props.code)) {
6319
+ if (!Array.isArray(props.code)) {
6320
+ props.code = [props.code];
6321
+ }
6322
+ resource.code = concept(props.code);
6323
+ }
6324
+ if (!_75.isNil(props.specialty)) {
6325
+ if (!Array.isArray(props.specialty)) {
6326
+ props.specialty = [props.specialty];
6327
+ }
6328
+ resource.specialty = concept(props.specialty);
6329
+ }
5421
6330
  if (!_75.isNil(props.location)) {
5422
6331
  if (!Array.isArray(props.location)) {
5423
6332
  props.location = [props.location];
@@ -5452,12 +6361,18 @@ function PackagedProductDefinition_default(props) {
5452
6361
  }
5453
6362
  resource.identifier = identifier(props.identifier);
5454
6363
  }
6364
+ if (!_76.isNil(props.type)) {
6365
+ resource.type = concept(props.type);
6366
+ }
5455
6367
  if (!_76.isNil(props.packageFor)) {
5456
6368
  if (!Array.isArray(props.packageFor)) {
5457
6369
  props.packageFor = [props.packageFor];
5458
6370
  }
5459
6371
  resource.packageFor = reference(props.packageFor);
5460
6372
  }
6373
+ if (!_76.isNil(props.status)) {
6374
+ resource.status = concept(props.status);
6375
+ }
5461
6376
  if (!_76.isNil(props.legalStatusOfSupply)) {
5462
6377
  let src = props.legalStatusOfSupply;
5463
6378
  if (!Array.isArray(src)) {
@@ -5471,6 +6386,12 @@ function PackagedProductDefinition_default(props) {
5471
6386
  resource.legalStatusOfSupply.push(_legalStatusOfSupply);
5472
6387
  }
5473
6388
  }
6389
+ if (!_76.isNil(props.characteristic)) {
6390
+ if (!Array.isArray(props.characteristic)) {
6391
+ props.characteristic = [props.characteristic];
6392
+ }
6393
+ resource.characteristic = concept(props.characteristic);
6394
+ }
5474
6395
  if (!_76.isNil(props.manufacturer)) {
5475
6396
  if (!Array.isArray(props.manufacturer)) {
5476
6397
  props.manufacturer = [props.manufacturer];
@@ -5504,6 +6425,9 @@ function Patient_default(props) {
5504
6425
  delete resource.deceased;
5505
6426
  composite(resource, "deceased", props.deceased);
5506
6427
  }
6428
+ if (!_77.isNil(props.maritalStatus)) {
6429
+ resource.maritalStatus = concept(props.maritalStatus);
6430
+ }
5507
6431
  if (!_77.isNil(props.multipleBirth)) {
5508
6432
  delete resource.multipleBirth;
5509
6433
  composite(resource, "multipleBirth", props.multipleBirth);
@@ -5590,6 +6514,9 @@ function PaymentNotice_default(props) {
5590
6514
  if (!_78.isNil(props.recipient)) {
5591
6515
  resource.recipient = reference(props.recipient);
5592
6516
  }
6517
+ if (!_78.isNil(props.paymentStatus)) {
6518
+ resource.paymentStatus = concept(props.paymentStatus);
6519
+ }
5593
6520
  return resource;
5594
6521
  }
5595
6522
 
@@ -5631,6 +6558,9 @@ function PaymentReconciliation_default(props) {
5631
6558
  resource.detail.push(_detail);
5632
6559
  }
5633
6560
  }
6561
+ if (!_79.isNil(props.formCode)) {
6562
+ resource.formCode = concept(props.formCode);
6563
+ }
5634
6564
  if (!_79.isNil(props.processNote)) {
5635
6565
  let src = props.processNote;
5636
6566
  if (!Array.isArray(src)) {
@@ -5692,10 +6622,25 @@ function PlanDefinition_default(props) {
5692
6622
  }
5693
6623
  resource.identifier = identifier(props.identifier);
5694
6624
  }
6625
+ if (!_81.isNil(props.type)) {
6626
+ resource.type = concept(props.type);
6627
+ }
5695
6628
  if (!_81.isNil(props.subject)) {
5696
6629
  delete resource.subject;
5697
6630
  composite(resource, "subject", props.subject);
5698
6631
  }
6632
+ if (!_81.isNil(props.jurisdiction)) {
6633
+ if (!Array.isArray(props.jurisdiction)) {
6634
+ props.jurisdiction = [props.jurisdiction];
6635
+ }
6636
+ resource.jurisdiction = concept(props.jurisdiction);
6637
+ }
6638
+ if (!_81.isNil(props.topic)) {
6639
+ if (!Array.isArray(props.topic)) {
6640
+ props.topic = [props.topic];
6641
+ }
6642
+ resource.topic = concept(props.topic);
6643
+ }
5699
6644
  if (!_81.isNil(props.goal)) {
5700
6645
  let src = props.goal;
5701
6646
  if (!Array.isArray(src)) {
@@ -5751,6 +6696,12 @@ function Practitioner_default(props) {
5751
6696
  resource.qualification.push(_qualification);
5752
6697
  }
5753
6698
  }
6699
+ if (!_82.isNil(props.communication)) {
6700
+ if (!Array.isArray(props.communication)) {
6701
+ props.communication = [props.communication];
6702
+ }
6703
+ resource.communication = concept(props.communication);
6704
+ }
5754
6705
  return resource;
5755
6706
  }
5756
6707
 
@@ -5773,6 +6724,18 @@ function PractitionerRole_default(props) {
5773
6724
  if (!_83.isNil(props.organization)) {
5774
6725
  resource.organization = reference(props.organization);
5775
6726
  }
6727
+ if (!_83.isNil(props.code)) {
6728
+ if (!Array.isArray(props.code)) {
6729
+ props.code = [props.code];
6730
+ }
6731
+ resource.code = concept(props.code);
6732
+ }
6733
+ if (!_83.isNil(props.specialty)) {
6734
+ if (!Array.isArray(props.specialty)) {
6735
+ props.specialty = [props.specialty];
6736
+ }
6737
+ resource.specialty = concept(props.specialty);
6738
+ }
5776
6739
  if (!_83.isNil(props.location)) {
5777
6740
  if (!Array.isArray(props.location)) {
5778
6741
  props.location = [props.location];
@@ -5845,6 +6808,15 @@ function Procedure_default(props) {
5845
6808
  }
5846
6809
  resource.partOf = reference(props.partOf);
5847
6810
  }
6811
+ if (!_84.isNil(props.statusReason)) {
6812
+ resource.statusReason = concept(props.statusReason);
6813
+ }
6814
+ if (!_84.isNil(props.category)) {
6815
+ resource.category = concept(props.category);
6816
+ }
6817
+ if (!_84.isNil(props.code)) {
6818
+ resource.code = concept(props.code);
6819
+ }
5848
6820
  if (!_84.isNil(props.subject)) {
5849
6821
  resource.subject = reference(props.subject);
5850
6822
  }
@@ -5877,24 +6849,51 @@ function Procedure_default(props) {
5877
6849
  if (!_84.isNil(props.location)) {
5878
6850
  resource.location = reference(props.location);
5879
6851
  }
6852
+ if (!_84.isNil(props.reasonCode)) {
6853
+ if (!Array.isArray(props.reasonCode)) {
6854
+ props.reasonCode = [props.reasonCode];
6855
+ }
6856
+ resource.reasonCode = concept(props.reasonCode);
6857
+ }
5880
6858
  if (!_84.isNil(props.reasonReference)) {
5881
6859
  if (!Array.isArray(props.reasonReference)) {
5882
6860
  props.reasonReference = [props.reasonReference];
5883
6861
  }
5884
6862
  resource.reasonReference = reference(props.reasonReference);
5885
6863
  }
6864
+ if (!_84.isNil(props.bodySite)) {
6865
+ if (!Array.isArray(props.bodySite)) {
6866
+ props.bodySite = [props.bodySite];
6867
+ }
6868
+ resource.bodySite = concept(props.bodySite);
6869
+ }
6870
+ if (!_84.isNil(props.outcome)) {
6871
+ resource.outcome = concept(props.outcome);
6872
+ }
5886
6873
  if (!_84.isNil(props.report)) {
5887
6874
  if (!Array.isArray(props.report)) {
5888
6875
  props.report = [props.report];
5889
6876
  }
5890
6877
  resource.report = reference(props.report);
5891
6878
  }
6879
+ if (!_84.isNil(props.complication)) {
6880
+ if (!Array.isArray(props.complication)) {
6881
+ props.complication = [props.complication];
6882
+ }
6883
+ resource.complication = concept(props.complication);
6884
+ }
5892
6885
  if (!_84.isNil(props.complicationDetail)) {
5893
6886
  if (!Array.isArray(props.complicationDetail)) {
5894
6887
  props.complicationDetail = [props.complicationDetail];
5895
6888
  }
5896
6889
  resource.complicationDetail = reference(props.complicationDetail);
5897
6890
  }
6891
+ if (!_84.isNil(props.followUp)) {
6892
+ if (!Array.isArray(props.followUp)) {
6893
+ props.followUp = [props.followUp];
6894
+ }
6895
+ resource.followUp = concept(props.followUp);
6896
+ }
5898
6897
  if (!_84.isNil(props.focalDevice)) {
5899
6898
  let src = props.focalDevice;
5900
6899
  if (!Array.isArray(src)) {
@@ -5914,6 +6913,12 @@ function Procedure_default(props) {
5914
6913
  }
5915
6914
  resource.usedReference = reference(props.usedReference);
5916
6915
  }
6916
+ if (!_84.isNil(props.usedCode)) {
6917
+ if (!Array.isArray(props.usedCode)) {
6918
+ props.usedCode = [props.usedCode];
6919
+ }
6920
+ resource.usedCode = concept(props.usedCode);
6921
+ }
5917
6922
  return resource;
5918
6923
  }
5919
6924
 
@@ -5930,6 +6935,12 @@ function Questionnaire_default(props) {
5930
6935
  }
5931
6936
  resource.identifier = identifier(props.identifier);
5932
6937
  }
6938
+ if (!_85.isNil(props.jurisdiction)) {
6939
+ if (!Array.isArray(props.jurisdiction)) {
6940
+ props.jurisdiction = [props.jurisdiction];
6941
+ }
6942
+ resource.jurisdiction = concept(props.jurisdiction);
6943
+ }
5933
6944
  if (!_85.isNil(props.item)) {
5934
6945
  let src = props.item;
5935
6946
  if (!Array.isArray(src)) {
@@ -6015,6 +7026,27 @@ function RegulatedAuthorization_default(props) {
6015
7026
  }
6016
7027
  resource.subject = reference(props.subject);
6017
7028
  }
7029
+ if (!_87.isNil(props.type)) {
7030
+ resource.type = concept(props.type);
7031
+ }
7032
+ if (!_87.isNil(props.region)) {
7033
+ if (!Array.isArray(props.region)) {
7034
+ props.region = [props.region];
7035
+ }
7036
+ resource.region = concept(props.region);
7037
+ }
7038
+ if (!_87.isNil(props.status)) {
7039
+ resource.status = concept(props.status);
7040
+ }
7041
+ if (!_87.isNil(props.intendedUse)) {
7042
+ resource.intendedUse = concept(props.intendedUse);
7043
+ }
7044
+ if (!_87.isNil(props.basis)) {
7045
+ if (!Array.isArray(props.basis)) {
7046
+ props.basis = [props.basis];
7047
+ }
7048
+ resource.basis = concept(props.basis);
7049
+ }
6018
7050
  if (!_87.isNil(props.holder)) {
6019
7051
  resource.holder = reference(props.holder);
6020
7052
  }
@@ -6047,6 +7079,12 @@ function RelatedPerson_default(props) {
6047
7079
  if (!_88.isNil(props.patient)) {
6048
7080
  resource.patient = reference(props.patient);
6049
7081
  }
7082
+ if (!_88.isNil(props.relationship)) {
7083
+ if (!Array.isArray(props.relationship)) {
7084
+ props.relationship = [props.relationship];
7085
+ }
7086
+ resource.relationship = concept(props.relationship);
7087
+ }
6050
7088
  if (!_88.isNil(props.communication)) {
6051
7089
  let src = props.communication;
6052
7090
  if (!Array.isArray(src)) {
@@ -6091,6 +7129,9 @@ function RequestGroup_default(props) {
6091
7129
  if (!_89.isNil(props.groupIdentifier)) {
6092
7130
  resource.groupIdentifier = identifier(props.groupIdentifier);
6093
7131
  }
7132
+ if (!_89.isNil(props.code)) {
7133
+ resource.code = concept(props.code);
7134
+ }
6094
7135
  if (!_89.isNil(props.subject)) {
6095
7136
  resource.subject = reference(props.subject);
6096
7137
  }
@@ -6100,6 +7141,12 @@ function RequestGroup_default(props) {
6100
7141
  if (!_89.isNil(props.author)) {
6101
7142
  resource.author = reference(props.author);
6102
7143
  }
7144
+ if (!_89.isNil(props.reasonCode)) {
7145
+ if (!Array.isArray(props.reasonCode)) {
7146
+ props.reasonCode = [props.reasonCode];
7147
+ }
7148
+ resource.reasonCode = concept(props.reasonCode);
7149
+ }
6103
7150
  if (!_89.isNil(props.reasonReference)) {
6104
7151
  if (!Array.isArray(props.reasonReference)) {
6105
7152
  props.reasonReference = [props.reasonReference];
@@ -6139,6 +7186,18 @@ function ResearchDefinition_default(props) {
6139
7186
  delete resource.subject;
6140
7187
  composite(resource, "subject", props.subject);
6141
7188
  }
7189
+ if (!_90.isNil(props.jurisdiction)) {
7190
+ if (!Array.isArray(props.jurisdiction)) {
7191
+ props.jurisdiction = [props.jurisdiction];
7192
+ }
7193
+ resource.jurisdiction = concept(props.jurisdiction);
7194
+ }
7195
+ if (!_90.isNil(props.topic)) {
7196
+ if (!Array.isArray(props.topic)) {
7197
+ props.topic = [props.topic];
7198
+ }
7199
+ resource.topic = concept(props.topic);
7200
+ }
6142
7201
  if (!_90.isNil(props.population)) {
6143
7202
  resource.population = reference(props.population);
6144
7203
  }
@@ -6171,6 +7230,18 @@ function ResearchElementDefinition_default(props) {
6171
7230
  delete resource.subject;
6172
7231
  composite(resource, "subject", props.subject);
6173
7232
  }
7233
+ if (!_91.isNil(props.jurisdiction)) {
7234
+ if (!Array.isArray(props.jurisdiction)) {
7235
+ props.jurisdiction = [props.jurisdiction];
7236
+ }
7237
+ resource.jurisdiction = concept(props.jurisdiction);
7238
+ }
7239
+ if (!_91.isNil(props.topic)) {
7240
+ if (!Array.isArray(props.topic)) {
7241
+ props.topic = [props.topic];
7242
+ }
7243
+ resource.topic = concept(props.topic);
7244
+ }
6174
7245
  if (!_91.isNil(props.characteristic)) {
6175
7246
  let src = props.characteristic;
6176
7247
  if (!Array.isArray(src)) {
@@ -6212,6 +7283,42 @@ function ResearchStudy_default(props) {
6212
7283
  }
6213
7284
  resource.partOf = reference(props.partOf);
6214
7285
  }
7286
+ if (!_92.isNil(props.primaryPurposeType)) {
7287
+ resource.primaryPurposeType = concept(props.primaryPurposeType);
7288
+ }
7289
+ if (!_92.isNil(props.phase)) {
7290
+ resource.phase = concept(props.phase);
7291
+ }
7292
+ if (!_92.isNil(props.category)) {
7293
+ if (!Array.isArray(props.category)) {
7294
+ props.category = [props.category];
7295
+ }
7296
+ resource.category = concept(props.category);
7297
+ }
7298
+ if (!_92.isNil(props.focus)) {
7299
+ if (!Array.isArray(props.focus)) {
7300
+ props.focus = [props.focus];
7301
+ }
7302
+ resource.focus = concept(props.focus);
7303
+ }
7304
+ if (!_92.isNil(props.condition)) {
7305
+ if (!Array.isArray(props.condition)) {
7306
+ props.condition = [props.condition];
7307
+ }
7308
+ resource.condition = concept(props.condition);
7309
+ }
7310
+ if (!_92.isNil(props.keyword)) {
7311
+ if (!Array.isArray(props.keyword)) {
7312
+ props.keyword = [props.keyword];
7313
+ }
7314
+ resource.keyword = concept(props.keyword);
7315
+ }
7316
+ if (!_92.isNil(props.location)) {
7317
+ if (!Array.isArray(props.location)) {
7318
+ props.location = [props.location];
7319
+ }
7320
+ resource.location = concept(props.location);
7321
+ }
6215
7322
  if (!_92.isNil(props.enrollment)) {
6216
7323
  if (!Array.isArray(props.enrollment)) {
6217
7324
  props.enrollment = [props.enrollment];
@@ -6230,6 +7337,9 @@ function ResearchStudy_default(props) {
6230
7337
  }
6231
7338
  resource.site = reference(props.site);
6232
7339
  }
7340
+ if (!_92.isNil(props.reasonStopped)) {
7341
+ resource.reasonStopped = concept(props.reasonStopped);
7342
+ }
6233
7343
  if (!_92.isNil(props.arm)) {
6234
7344
  let src = props.arm;
6235
7345
  if (!Array.isArray(src)) {
@@ -6303,6 +7413,12 @@ function RiskAssessment_default(props) {
6303
7413
  if (!_94.isNil(props.parent)) {
6304
7414
  resource.parent = reference(props.parent);
6305
7415
  }
7416
+ if (!_94.isNil(props.method)) {
7417
+ resource.method = concept(props.method);
7418
+ }
7419
+ if (!_94.isNil(props.code)) {
7420
+ resource.code = concept(props.code);
7421
+ }
6306
7422
  if (!_94.isNil(props.subject)) {
6307
7423
  resource.subject = reference(props.subject);
6308
7424
  }
@@ -6319,6 +7435,12 @@ function RiskAssessment_default(props) {
6319
7435
  if (!_94.isNil(props.performer)) {
6320
7436
  resource.performer = reference(props.performer);
6321
7437
  }
7438
+ if (!_94.isNil(props.reasonCode)) {
7439
+ if (!Array.isArray(props.reasonCode)) {
7440
+ props.reasonCode = [props.reasonCode];
7441
+ }
7442
+ resource.reasonCode = concept(props.reasonCode);
7443
+ }
6322
7444
  if (!_94.isNil(props.reasonReference)) {
6323
7445
  if (!Array.isArray(props.reasonReference)) {
6324
7446
  props.reasonReference = [props.reasonReference];
@@ -6360,6 +7482,24 @@ function Schedule_default(props) {
6360
7482
  }
6361
7483
  resource.identifier = identifier(props.identifier);
6362
7484
  }
7485
+ if (!_95.isNil(props.serviceCategory)) {
7486
+ if (!Array.isArray(props.serviceCategory)) {
7487
+ props.serviceCategory = [props.serviceCategory];
7488
+ }
7489
+ resource.serviceCategory = concept(props.serviceCategory);
7490
+ }
7491
+ if (!_95.isNil(props.serviceType)) {
7492
+ if (!Array.isArray(props.serviceType)) {
7493
+ props.serviceType = [props.serviceType];
7494
+ }
7495
+ resource.serviceType = concept(props.serviceType);
7496
+ }
7497
+ if (!_95.isNil(props.specialty)) {
7498
+ if (!Array.isArray(props.specialty)) {
7499
+ props.specialty = [props.specialty];
7500
+ }
7501
+ resource.specialty = concept(props.specialty);
7502
+ }
6363
7503
  if (!_95.isNil(props.actor)) {
6364
7504
  if (!Array.isArray(props.actor)) {
6365
7505
  props.actor = [props.actor];
@@ -6397,6 +7537,21 @@ function ServiceRequest_default(props) {
6397
7537
  if (!_96.isNil(props.requisition)) {
6398
7538
  resource.requisition = identifier(props.requisition);
6399
7539
  }
7540
+ if (!_96.isNil(props.category)) {
7541
+ if (!Array.isArray(props.category)) {
7542
+ props.category = [props.category];
7543
+ }
7544
+ resource.category = concept(props.category);
7545
+ }
7546
+ if (!_96.isNil(props.code)) {
7547
+ resource.code = concept(props.code);
7548
+ }
7549
+ if (!_96.isNil(props.orderDetail)) {
7550
+ if (!Array.isArray(props.orderDetail)) {
7551
+ props.orderDetail = [props.orderDetail];
7552
+ }
7553
+ resource.orderDetail = concept(props.orderDetail);
7554
+ }
6400
7555
  if (!_96.isNil(props.quantity)) {
6401
7556
  delete resource.quantity;
6402
7557
  composite(resource, "quantity", props.quantity);
@@ -6418,18 +7573,33 @@ function ServiceRequest_default(props) {
6418
7573
  if (!_96.isNil(props.requester)) {
6419
7574
  resource.requester = reference(props.requester);
6420
7575
  }
7576
+ if (!_96.isNil(props.performerType)) {
7577
+ resource.performerType = concept(props.performerType);
7578
+ }
6421
7579
  if (!_96.isNil(props.performer)) {
6422
7580
  if (!Array.isArray(props.performer)) {
6423
7581
  props.performer = [props.performer];
6424
7582
  }
6425
7583
  resource.performer = reference(props.performer);
6426
7584
  }
7585
+ if (!_96.isNil(props.locationCode)) {
7586
+ if (!Array.isArray(props.locationCode)) {
7587
+ props.locationCode = [props.locationCode];
7588
+ }
7589
+ resource.locationCode = concept(props.locationCode);
7590
+ }
6427
7591
  if (!_96.isNil(props.locationReference)) {
6428
7592
  if (!Array.isArray(props.locationReference)) {
6429
7593
  props.locationReference = [props.locationReference];
6430
7594
  }
6431
7595
  resource.locationReference = reference(props.locationReference);
6432
7596
  }
7597
+ if (!_96.isNil(props.reasonCode)) {
7598
+ if (!Array.isArray(props.reasonCode)) {
7599
+ props.reasonCode = [props.reasonCode];
7600
+ }
7601
+ resource.reasonCode = concept(props.reasonCode);
7602
+ }
6433
7603
  if (!_96.isNil(props.reasonReference)) {
6434
7604
  if (!Array.isArray(props.reasonReference)) {
6435
7605
  props.reasonReference = [props.reasonReference];
@@ -6454,6 +7624,12 @@ function ServiceRequest_default(props) {
6454
7624
  }
6455
7625
  resource.specimen = reference(props.specimen);
6456
7626
  }
7627
+ if (!_96.isNil(props.bodySite)) {
7628
+ if (!Array.isArray(props.bodySite)) {
7629
+ props.bodySite = [props.bodySite];
7630
+ }
7631
+ resource.bodySite = concept(props.bodySite);
7632
+ }
6457
7633
  if (!_96.isNil(props.relevantHistory)) {
6458
7634
  if (!Array.isArray(props.relevantHistory)) {
6459
7635
  props.relevantHistory = [props.relevantHistory];
@@ -6476,6 +7652,27 @@ function Slot_default(props) {
6476
7652
  }
6477
7653
  resource.identifier = identifier(props.identifier);
6478
7654
  }
7655
+ if (!_97.isNil(props.serviceCategory)) {
7656
+ if (!Array.isArray(props.serviceCategory)) {
7657
+ props.serviceCategory = [props.serviceCategory];
7658
+ }
7659
+ resource.serviceCategory = concept(props.serviceCategory);
7660
+ }
7661
+ if (!_97.isNil(props.serviceType)) {
7662
+ if (!Array.isArray(props.serviceType)) {
7663
+ props.serviceType = [props.serviceType];
7664
+ }
7665
+ resource.serviceType = concept(props.serviceType);
7666
+ }
7667
+ if (!_97.isNil(props.specialty)) {
7668
+ if (!Array.isArray(props.specialty)) {
7669
+ props.specialty = [props.specialty];
7670
+ }
7671
+ resource.specialty = concept(props.specialty);
7672
+ }
7673
+ if (!_97.isNil(props.appointmentType)) {
7674
+ resource.appointmentType = concept(props.appointmentType);
7675
+ }
6479
7676
  if (!_97.isNil(props.schedule)) {
6480
7677
  resource.schedule = reference(props.schedule);
6481
7678
  }
@@ -6498,6 +7695,9 @@ function Specimen_default(props) {
6498
7695
  if (!_98.isNil(props.accessionIdentifier)) {
6499
7696
  resource.accessionIdentifier = identifier(props.accessionIdentifier);
6500
7697
  }
7698
+ if (!_98.isNil(props.type)) {
7699
+ resource.type = concept(props.type);
7700
+ }
6501
7701
  if (!_98.isNil(props.subject)) {
6502
7702
  resource.subject = reference(props.subject);
6503
7703
  }
@@ -6546,6 +7746,12 @@ function Specimen_default(props) {
6546
7746
  resource.container.push(_container);
6547
7747
  }
6548
7748
  }
7749
+ if (!_98.isNil(props.condition)) {
7750
+ if (!Array.isArray(props.condition)) {
7751
+ props.condition = [props.condition];
7752
+ }
7753
+ resource.condition = concept(props.condition);
7754
+ }
6549
7755
  return resource;
6550
7756
  }
6551
7757
 
@@ -6559,6 +7765,21 @@ function SpecimenDefinition_default(props) {
6559
7765
  if (!_99.isNil(props.identifier)) {
6560
7766
  resource.identifier = identifier(props.identifier);
6561
7767
  }
7768
+ if (!_99.isNil(props.typeCollected)) {
7769
+ resource.typeCollected = concept(props.typeCollected);
7770
+ }
7771
+ if (!_99.isNil(props.patientPreparation)) {
7772
+ if (!Array.isArray(props.patientPreparation)) {
7773
+ props.patientPreparation = [props.patientPreparation];
7774
+ }
7775
+ resource.patientPreparation = concept(props.patientPreparation);
7776
+ }
7777
+ if (!_99.isNil(props.collection)) {
7778
+ if (!Array.isArray(props.collection)) {
7779
+ props.collection = [props.collection];
7780
+ }
7781
+ resource.collection = concept(props.collection);
7782
+ }
6562
7783
  if (!_99.isNil(props.typeTested)) {
6563
7784
  let src = props.typeTested;
6564
7785
  if (!Array.isArray(src)) {
@@ -6588,6 +7809,15 @@ function Substance_default(props) {
6588
7809
  }
6589
7810
  resource.identifier = identifier(props.identifier);
6590
7811
  }
7812
+ if (!_100.isNil(props.category)) {
7813
+ if (!Array.isArray(props.category)) {
7814
+ props.category = [props.category];
7815
+ }
7816
+ resource.category = concept(props.category);
7817
+ }
7818
+ if (!_100.isNil(props.code)) {
7819
+ resource.code = concept(props.code);
7820
+ }
6591
7821
  if (!_100.isNil(props.instance)) {
6592
7822
  let src = props.instance;
6593
7823
  if (!Array.isArray(src)) {
@@ -6630,6 +7860,24 @@ function SubstanceDefinition_default(props) {
6630
7860
  }
6631
7861
  resource.identifier = identifier(props.identifier);
6632
7862
  }
7863
+ if (!_101.isNil(props.status)) {
7864
+ resource.status = concept(props.status);
7865
+ }
7866
+ if (!_101.isNil(props.classification)) {
7867
+ if (!Array.isArray(props.classification)) {
7868
+ props.classification = [props.classification];
7869
+ }
7870
+ resource.classification = concept(props.classification);
7871
+ }
7872
+ if (!_101.isNil(props.domain)) {
7873
+ resource.domain = concept(props.domain);
7874
+ }
7875
+ if (!_101.isNil(props.grade)) {
7876
+ if (!Array.isArray(props.grade)) {
7877
+ props.grade = [props.grade];
7878
+ }
7879
+ resource.grade = concept(props.grade);
7880
+ }
6633
7881
  if (!_101.isNil(props.informationSource)) {
6634
7882
  if (!Array.isArray(props.informationSource)) {
6635
7883
  props.informationSource = [props.informationSource];
@@ -6771,6 +8019,9 @@ function SupplyDelivery_default(props) {
6771
8019
  if (!_102.isNil(props.patient)) {
6772
8020
  resource.patient = reference(props.patient);
6773
8021
  }
8022
+ if (!_102.isNil(props.type)) {
8023
+ resource.type = concept(props.type);
8024
+ }
6774
8025
  if (!_102.isNil(props.suppliedItem)) {
6775
8026
  let src = props.suppliedItem;
6776
8027
  let _suppliedItem = {
@@ -6810,6 +8061,9 @@ function SupplyRequest_default(props) {
6810
8061
  }
6811
8062
  resource.identifier = identifier(props.identifier);
6812
8063
  }
8064
+ if (!_103.isNil(props.category)) {
8065
+ resource.category = concept(props.category);
8066
+ }
6813
8067
  if (!_103.isNil(props.item)) {
6814
8068
  delete resource.item;
6815
8069
  composite(resource, "item", props.item);
@@ -6840,6 +8094,12 @@ function SupplyRequest_default(props) {
6840
8094
  }
6841
8095
  resource.supplier = reference(props.supplier);
6842
8096
  }
8097
+ if (!_103.isNil(props.reasonCode)) {
8098
+ if (!Array.isArray(props.reasonCode)) {
8099
+ props.reasonCode = [props.reasonCode];
8100
+ }
8101
+ resource.reasonCode = concept(props.reasonCode);
8102
+ }
6843
8103
  if (!_103.isNil(props.reasonReference)) {
6844
8104
  if (!Array.isArray(props.reasonReference)) {
6845
8105
  props.reasonReference = [props.reasonReference];
@@ -6883,6 +8143,15 @@ function Task_default(props) {
6883
8143
  }
6884
8144
  resource.partOf = reference(props.partOf);
6885
8145
  }
8146
+ if (!_104.isNil(props.statusReason)) {
8147
+ resource.statusReason = concept(props.statusReason);
8148
+ }
8149
+ if (!_104.isNil(props.businessStatus)) {
8150
+ resource.businessStatus = concept(props.businessStatus);
8151
+ }
8152
+ if (!_104.isNil(props.code)) {
8153
+ resource.code = concept(props.code);
8154
+ }
6886
8155
  if (!_104.isNil(props.focus)) {
6887
8156
  resource.focus = reference(props.focus);
6888
8157
  }
@@ -6895,12 +8164,21 @@ function Task_default(props) {
6895
8164
  if (!_104.isNil(props.requester)) {
6896
8165
  resource.requester = reference(props.requester);
6897
8166
  }
8167
+ if (!_104.isNil(props.performerType)) {
8168
+ if (!Array.isArray(props.performerType)) {
8169
+ props.performerType = [props.performerType];
8170
+ }
8171
+ resource.performerType = concept(props.performerType);
8172
+ }
6898
8173
  if (!_104.isNil(props.owner)) {
6899
8174
  resource.owner = reference(props.owner);
6900
8175
  }
6901
8176
  if (!_104.isNil(props.location)) {
6902
8177
  resource.location = reference(props.location);
6903
8178
  }
8179
+ if (!_104.isNil(props.reasonCode)) {
8180
+ resource.reasonCode = concept(props.reasonCode);
8181
+ }
6904
8182
  if (!_104.isNil(props.reasonReference)) {
6905
8183
  resource.reasonReference = reference(props.reasonReference);
6906
8184
  }
@@ -7021,6 +8299,21 @@ function VerificationResult_default(props) {
7021
8299
  }
7022
8300
  resource.target = reference(props.target);
7023
8301
  }
8302
+ if (!_106.isNil(props.need)) {
8303
+ resource.need = concept(props.need);
8304
+ }
8305
+ if (!_106.isNil(props.validationType)) {
8306
+ resource.validationType = concept(props.validationType);
8307
+ }
8308
+ if (!_106.isNil(props.validationProcess)) {
8309
+ if (!Array.isArray(props.validationProcess)) {
8310
+ props.validationProcess = [props.validationProcess];
8311
+ }
8312
+ resource.validationProcess = concept(props.validationProcess);
8313
+ }
8314
+ if (!_106.isNil(props.failureAction)) {
8315
+ resource.failureAction = concept(props.failureAction);
8316
+ }
7024
8317
  if (!_106.isNil(props.primarySource)) {
7025
8318
  let src = props.primarySource;
7026
8319
  if (!Array.isArray(src)) {