diff --git a/data/SampleData/Ccda/PROBLEMS_in_Empty_C-CDA_2.1-C-CDAR2.1.ccda b/data/SampleData/Ccda/PROBLEMS_in_Empty_C-CDA_2.1-C-CDAR2.1.ccda index ca4fef596..794638f70 100644 --- a/data/SampleData/Ccda/PROBLEMS_in_Empty_C-CDA_2.1-C-CDAR2.1.ccda +++ b/data/SampleData/Ccda/PROBLEMS_in_Empty_C-CDA_2.1-C-CDAR2.1.ccda @@ -299,7 +299,7 @@ displayName="Burn by Fire"/> - + - + diff --git a/data/SampleData/Hl7v2/ADT_A01.hl7 b/data/SampleData/Hl7v2/ADT-A01-01.hl7 similarity index 100% rename from data/SampleData/Hl7v2/ADT_A01.hl7 rename to data/SampleData/Hl7v2/ADT-A01-01.hl7 diff --git a/data/SampleData/Hl7v2/ADT_A01-2.hl7 b/data/SampleData/Hl7v2/ADT-A01-02.hl7 similarity index 100% rename from data/SampleData/Hl7v2/ADT_A01-2.hl7 rename to data/SampleData/Hl7v2/ADT-A01-02.hl7 diff --git a/data/SampleData/Hl7v2/ADT_A02.hl7 b/data/SampleData/Hl7v2/ADT-A02-01.hl7 similarity index 100% rename from data/SampleData/Hl7v2/ADT_A02.hl7 rename to data/SampleData/Hl7v2/ADT-A02-01.hl7 diff --git a/data/SampleData/Hl7v2/ADT_A02-2.hl7 b/data/SampleData/Hl7v2/ADT-A02-02.hl7 similarity index 100% rename from data/SampleData/Hl7v2/ADT_A02-2.hl7 rename to data/SampleData/Hl7v2/ADT-A02-02.hl7 diff --git a/data/SampleData/Hl7v2/ADT_A03.hl7 b/data/SampleData/Hl7v2/ADT-A03-01.hl7 similarity index 97% rename from data/SampleData/Hl7v2/ADT_A03.hl7 rename to data/SampleData/Hl7v2/ADT-A03-01.hl7 index d0d9da6f0..18337fa66 100644 --- a/data/SampleData/Hl7v2/ADT_A03.hl7 +++ b/data/SampleData/Hl7v2/ADT-A03-01.hl7 @@ -4,7 +4,7 @@ EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfs PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet PD1|S^^ACR||LINDAS TEST ORGANIZATION^^SIISCLIENT818|88^Hippo^rold^H^V^Dr^MD^^TE^^^M10^DN^^||||||||||Methodist Church|||20150202^20150202 NK1|1|Evan&&&&Aniston^ADAM^A^III^Dr.^MD^D|EMC^test^ACR^CHD^^^9.0^10.0|2222&HOME&STREET^Highway^GREENSBORO^NC^27401-1020^US^BI^^jkdha&test^^^^20000110^20050111~111&Duck ST^^Fowl|78788788^WPN^Internet^5555^^^^^^^^^20010110^20020110^^^^18~121111^PRN^CP|88888888^PRN^CP^5555^^^^^^^^878777^20010110^20020110^^^^18~6666666^^BP|O|20210818|20211218|||12345567^4^M11^T1&2.16.840.1.113883.19&HCD^MR^University Hospital^19241011^19241012|TestOrg^^O12^^^^EI^^^Org12||F^^^M|19620110045504||||ara||||||||||Green^John^A^II^DR^MD^D^^^19241012^G~Josh&&&&Bing^^stanley^^^^L|898989898^^FX~88888888^^CP|Street1&Palkstreet~ST-2|I-123^^^^BA~I-222^^^^DI||2106-3^test^FDDC||Security no-23|||1515151515^WPN^CP^555544^^^^^^^^777^20010110^20020110^^^^1|444444^^CP -PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110|20150209113419+0110|||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT||||||||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C DB1|1|PT|DB123^4^M11^t&1.12&ISO^MR^UH^19241011^19241012|Y|20210830|20210930| AL1|1|EA|P^PENICILLIN^ICDO|MI|CODE16|20210824 diff --git a/data/SampleData/Hl7v2/ADT_A14-2.hl7 b/data/SampleData/Hl7v2/ADT-A03-02.hl7 similarity index 91% rename from data/SampleData/Hl7v2/ADT_A14-2.hl7 rename to data/SampleData/Hl7v2/ADT-A03-02.hl7 index 4fcc32726..07996926f 100644 --- a/data/SampleData/Hl7v2/ADT_A14-2.hl7 +++ b/data/SampleData/Hl7v2/ADT-A03-02.hl7 @@ -1,4 +1,4 @@ -MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A14^ADT_A14|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A03^ADT_A03|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet -PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital \ No newline at end of file +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110|20150209113419+0110|||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital \ No newline at end of file diff --git a/data/SampleData/Hl7v2/ADT_A04.hl7 b/data/SampleData/Hl7v2/ADT-A04-01.hl7 similarity index 96% rename from data/SampleData/Hl7v2/ADT_A04.hl7 rename to data/SampleData/Hl7v2/ADT-A04-01.hl7 index a7ffd33be..a4c79baee 100644 --- a/data/SampleData/Hl7v2/ADT_A04.hl7 +++ b/data/SampleData/Hl7v2/ADT-A04-01.hl7 @@ -5,7 +5,7 @@ PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M1 PD1|S^^ACR||LINDAS TEST ORGANIZATION^^SIISCLIENT818|88^Hippo^rold^H^V^Dr^MD^^TE^^^M10^DN^^||||||||||Methodist Church|||20150202^20150202 NK1|1|Evan&&&&Aniston^ADAM^A^III^Dr.^MD^D|EMC^test^ACR^CHD^^^9.0^10.0|2222&HOME&STREET^Highway^GREENSBORO^NC^27401-1020^US^BI^^jkdha&test^^^^20000110^20050111~111&Duck ST^^Fowl|78788788^WPN^Internet^5555^^^^^^^^^20010110^20020110^^^^18~121111^PRN^CP|88888888^PRN^CP^5555^^^^^^^^878777^20010110^20020110^^^^18~6666666^^BP|O|20210818|20211218|||12345567^4^M11^T1&2.16.840.1.113883.19&HCD^MR^University Hospital^19241011^19241012|TestOrg^^O12^^^^EI^^^Org12||F^^^M|19620110045504||||ara||||||||||Green^John^A^II^DR^MD^D^^^19241012^G~Josh&&&&Bing^^stanley^^^^L|898989898^^FX~88888888^^CP|Street1&Palkstreet~ST-2|I-123^^^^BA~I-222^^^^DI||2106-3^test^FDDC||Security no-23|||1515151515^WPN^CP^555544^^^^^^^^777^20010110^20020110^^^^1|444444^^CP PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital -PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT||||||||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C +PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT|||||20150208113419+0110|20150209113419+0110||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C DB1|1|PT|DB123^4^M11^t&1.12&ISO^MR^UH^19241011^19241012|Y|20210830|20210930| OBX|27|NM|8867-4^heartrate^LN||60~120|beats/min^^ISO|70-80|A^A^HL7nnnn~B^B|||S|||19990702|Org15^ID of producer^CAS|1134^Aly^Zafar^Mahendra^JR^Dr.^MD^^PERSt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al~2234^Pauly^Berrie^Raud|OBS^This is test method^AS4|EI12.3^NI2^UI2^GUID~^^UI1^ISO|19990702|BU^Observation site^E5|EI21^OII||FairOaks Hspital|Research Park^Fairfax^VA^22031^USA|MD-25^Atchinson^Christopher^^MD|||||||PAI-1^FAI-1 AL1|1|EA|P^PENICILLIN^ICDO|MI|CODE16|20210824 diff --git a/data/SampleData/Hl7v2/ADT-A04-02.hl7 b/data/SampleData/Hl7v2/ADT-A04-02.hl7 new file mode 100644 index 000000000..159c8a138 --- /dev/null +++ b/data/SampleData/Hl7v2/ADT-A04-02.hl7 @@ -0,0 +1,5 @@ +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A04^ADT_A04|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110|20150209113419+0110|||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital +PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT||||||||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C diff --git a/data/SampleData/Hl7v2/ADT-A05-01.hl7 b/data/SampleData/Hl7v2/ADT-A05-01.hl7 new file mode 100644 index 000000000..564da192f --- /dev/null +++ b/data/SampleData/Hl7v2/ADT-A05-01.hl7 @@ -0,0 +1,17 @@ +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A05^ADT_A05|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SFT|Orion|2.4.3.52854|Rhapsody|2.4.3|Testactivity|20070725111624 +EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet +PD1|S^^ACR||LINDAS TEST ORGANIZATION^^SIISCLIENT818|88^Hippo^rold^H^V^Dr^MD^^TE^^^M10^DN^^||||||||||Methodist Church|||20150202^20150202 +NK1|1|Evan&&&&Aniston^ADAM^A^III^Dr.^MD^D|EMC^test^ACR^CHD^^^9.0^10.0|2222&HOME&STREET^Highway^GREENSBORO^NC^27401-1020^US^BI^^jkdha&test^^^^20000110^20050111~111&Duck ST^^Fowl|78788788^WPN^Internet^5555^^^^^^^^^20010110^20020110^^^^18~121111^PRN^CP|88888888^PRN^CP^5555^^^^^^^^878777^20010110^20020110^^^^18~6666666^^BP|O|20210818|20211218|||12345567^4^M11^T1&2.16.840.1.113883.19&HCD^MR^University Hospital^19241011^19241012|TestOrg^^O12^^^^EI^^^Org12||F^^^M|19620110045504||||ara||||||||||Green^John^A^II^DR^MD^D^^^19241012^G~Josh&&&&Bing^^stanley^^^^L|898989898^^FX~88888888^^CP|Street1&Palkstreet~ST-2|I-123^^^^BA~I-222^^^^DI||2106-3^test^FDDC||Security no-23|||1515151515^WPN^CP^555544^^^^^^^^777^20010110^20020110^^^^1|444444^^CP +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital +PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT|||||20150208113419+0110|20150209113419+0110||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C +DB1|1|PT|DB123^4^M11^t&1.12&ISO^MR^UH^19241011^19241012|Y|20210830|20210930| +OBX|27|NM|8867-4^heartrate^LN||60~120|beats/min^^ISO|70-80|A^A^HL7nnnn~B^B|||S|||19990702|Org15^ID of producer^CAS|1134^Aly^Zafar^Mahendra^JR^Dr.^MD^^PERSt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al~2234^Pauly^Berrie^Raud|OBS^This is test method^AS4|EI12.3^NI2^UI2^GUID~^^UI1^ISO|19990702|BU^Observation site^E5|EI21^OII||FairOaks Hspital|Research Park^Fairfax^VA^22031^USA|MD-25^Atchinson^Christopher^^MD|||||||PAI-1^FAI-1 +AL1|1|EA|P^PENICILLIN^ICDO|MI|CODE16|20210824 +DG1|1|I9|422504002^Ischemic stroke(disorder)^SCT|Stroke|20040125114025+0420|A|||||||||1|005454^DIAG^ROBIN^B|||20200501133015+0215|DI20^Diagnosis^DTUI^CLIP|A|^^UI^CLIP +PR1|1||76164006^Biopsy of colon (procedure)^SCT|Biopsy of colon, which was part of colonoscopy|200501251140+0100|D^Diagnostic Procedure^HL70230|2|1210^ANES^MARK^B|||121188^Patrick^Harold^H^IV^Dr^MD^^&Provider Master.Community Health and Hospitals&L^L^9^M10^DN^&Good Health Hospital.Community Health and Hospitals&L^A|12345689^Everyman2^Adam2^A^III^DR^PHD^ADT01^^L^4^M11^MR|||799008^Sigmoid colon ulcer^SCT||||PR1006||||OT^201||PR1001 +GT1|1|1516^4^M11^test^MR^Unity Hospital^19241011^19241012|RADIANT^LUCY^^|Rebecca^Jonas|1619 SOUTH UNIVERSITY^^MADISON^WI^53703^US|6082517777^^Internet^8484~717171^^PH|021212^^MD|20010412|F|P/F|SEL|G-SSN-12|20010410|20010415|2|EHS GENERIC EMPLOYER|1979 MILKY WAY^^VERONA^WI^53593^US|082719000^^PH|55121^^^^FI|3|Jupiter Hospital|N|SLF|20000725111420|N||||1231^^^^BC|M|20091010|20101010||||ger||||||MothersMaiden|||Ben^Charles~Ben2|000352^^CP~00121^^FX|Urgent requirement||||GEOrg|||||Germany +IN1|1|BAV^Blue Advantage HMO|IC-1.31^24^BCV^&2.16.840.1.113883.1.1&ISO^NIIP^^19291011^19291012|Blue Cross Blue Shield of Texas|1979 MILKY WAY^^VERONA^WI^53593^US|Henry&&&&Roth^Rony^A^III^Dr.^MD^D^^^19251012|(555)555-5555^BPN^PH|PUBSUMB|SelfPay||Sam P. Hil|19891001|20501001||HMO^health maintenance organization policy|Doe^Rosallie^John^III^Mrs.^Bachelors^R|SPO^Spouse|19750228|3857 Velvet Treasure Terrace^^Midnight^NC^27878^US|||||||||||||||||PN-145|150&USD^DC||||||F^Female|2000 MILKY WAY^^VERONA^WI^53593^US|||B||HMO-12345^^^&2.16.840.1.113883.1.3&ISO^NI +IN2|1117^4^M11^&2.16.840.1.113883.1.4&ISO^EI^University Hospital~1118^^^^BC|425-57-9745|||I^Insurance company|Medicare-12345|Jack&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm|MCN-008||MI-12345||||||||||||||||||||||||eng^English|||||||||||||||Richard^Paul|254622222^^PH|||||||||||PNM1234^4^M11^PM&2.6.1&HCD^MR^University Hospital^19241011^19241012||0005245^WPN^Internet~^^CP|555777888^^FX~^^PH||||||Max Life Insurance||02^Spouse +RF1|P^Pending^HL7283|A^ASAP^HL7280|EXTERNAL|||123-1^name|||19900501120100+0515|R-1^Reason^C4|123-2^Testname|||Patient has a spinal fracture|||||AuthProvider^L^4.4^3^M10^CMS^LR^^^A|114^Beverly^Crusher^An^Mr^Dr.^AHP^^2.3^B^^^BR^^^^^^19241010^19241015^Al||||Check for metastatic disease|U \ No newline at end of file diff --git a/data/SampleData/Hl7v2/ADT-A05-02.hl7 b/data/SampleData/Hl7v2/ADT-A05-02.hl7 new file mode 100644 index 000000000..1898b4772 --- /dev/null +++ b/data/SampleData/Hl7v2/ADT-A05-02.hl7 @@ -0,0 +1,5 @@ +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A05^ADT_A05|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110|20150209113419+0110|||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital +PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT||||||||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C diff --git a/data/SampleData/Hl7v2/ADT_A08.hl7 b/data/SampleData/Hl7v2/ADT-A08-01.hl7 similarity index 97% rename from data/SampleData/Hl7v2/ADT_A08.hl7 rename to data/SampleData/Hl7v2/ADT-A08-01.hl7 index 1cdf2a84f..3c4b989f6 100644 --- a/data/SampleData/Hl7v2/ADT_A08.hl7 +++ b/data/SampleData/Hl7v2/ADT-A08-01.hl7 @@ -4,7 +4,7 @@ EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfs PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet PD1|S^^ACR||LINDAS TEST ORGANIZATION^^SIISCLIENT818|88^Hippo^rold^H^V^Dr^MD^^TE^^^M10^DN^^||||||||||Methodist Church|||20150202^20150202 NK1|1|Evan&&&&Aniston^ADAM^A^III^Dr.^MD^D|EMC^test^ACR^CHD^^^9.0^10.0|2222&HOME&STREET^Highway^GREENSBORO^NC^27401-1020^US^BI^^jkdha&test^^^^20000110^20050111~111&Duck ST^^Fowl|78788788^WPN^Internet^5555^^^^^^^^^20010110^20020110^^^^18~121111^PRN^CP|88888888^PRN^CP^5555^^^^^^^^878777^20010110^20020110^^^^18~6666666^^BP|O|20210818|20211218|||12345567^4^M11^T1&2.16.840.1.113883.19&HCD^MR^University Hospital^19241011^19241012|TestOrg^^O12^^^^EI^^^Org12||F^^^M|19620110045504||||ara||||||||||Green^John^A^II^DR^MD^D^^^19241012^G~Josh&&&&Bing^^stanley^^^^L|898989898^^FX~88888888^^CP|Street1&Palkstreet~ST-2|I-123^^^^BA~I-222^^^^DI||2106-3^test^FDDC||Security no-23|||1515151515^WPN^CP^555544^^^^^^^^777^20010110^20020110^^^^1|444444^^CP -PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110|20150209113419+0110|||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT||||||||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C DB1|1|PT|DB123^4^M11^t&1.12&ISO^MR^UH^19241011^19241012|Y|20210830|20210930| OBX|27|NM|8867-4^heartrate^LN||60~120|beats/min^^ISO|70-80|A^A^HL7nnnn~B^B|||S|||19990702|Org15^ID of producer^CAS|1134^Aly^Zafar^Mahendra^JR^Dr.^MD^^PERSt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al~2234^Pauly^Berrie^Raud|OBS^This is test method^AS4|EI12.3^NI2^UI2^GUID~^^UI1^ISO|19990702|BU^Observation site^E5|EI21^OII||FairOaks Hspital|Research Park^Fairfax^VA^22031^USA|MD-25^Atchinson^Christopher^^MD|||||||PAI-1^FAI-1 diff --git a/data/SampleData/Hl7v2/ADT_A08-2.hl7 b/data/SampleData/Hl7v2/ADT-A08-02.hl7 similarity index 100% rename from data/SampleData/Hl7v2/ADT_A08-2.hl7 rename to data/SampleData/Hl7v2/ADT-A08-02.hl7 diff --git a/data/SampleData/Hl7v2/ADT-A11-01.hl7 b/data/SampleData/Hl7v2/ADT-A11-01.hl7 new file mode 100644 index 000000000..56522398b --- /dev/null +++ b/data/SampleData/Hl7v2/ADT-A11-01.hl7 @@ -0,0 +1,9 @@ +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A11^ADT_A11|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SFT|Orion|2.4.3.52854|Rhapsody|2.4.3|Testactivity|20070725111624 +EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet +PD1|S^^ACR||LINDAS TEST ORGANIZATION^^SIISCLIENT818|88^Hippo^rold^H^V^Dr^MD^^TE^^^M10^DN^^||||||||||Methodist Church|||20150202^20150202 +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital +PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT|||||20150208113419+0110|20150209113419+0110||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C +DB1|1|PT|DB123^4^M11^t&1.12&ISO^MR^UH^19241011^19241012|Y|20210830|20210930| +OBX|27|NM|8867-4^heartrate^LN||60~120|beats/min^^ISO|70-80|A^A^HL7nnnn~B^B|||S|||19990702|Org15^ID of producer^CAS|1134^Aly^Zafar^Mahendra^JR^Dr.^MD^^PERSt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al~2234^Pauly^Berrie^Raud|OBS^This is test method^AS4|EI12.3^NI2^UI2^GUID~^^UI1^ISO|19990702|BU^Observation site^E5|EI21^OII||FairOaks Hspital|Research Park^Fairfax^VA^22031^USA|MD-25^Atchinson^Christopher^^MD|||||||PAI-1^FAI-1 \ No newline at end of file diff --git a/data/SampleData/Hl7v2/ADT-A11-02.hl7 b/data/SampleData/Hl7v2/ADT-A11-02.hl7 new file mode 100644 index 000000000..8082f8fd4 --- /dev/null +++ b/data/SampleData/Hl7v2/ADT-A11-02.hl7 @@ -0,0 +1,5 @@ +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A11^ADT_A11|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110|20150209113419+0110|||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital +PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT||||||||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C diff --git a/data/SampleData/Hl7v2/ADT_A05.hl7 b/data/SampleData/Hl7v2/ADT-A13-01.hl7 similarity index 99% rename from data/SampleData/Hl7v2/ADT_A05.hl7 rename to data/SampleData/Hl7v2/ADT-A13-01.hl7 index 3d3800f9f..f589d8b53 100644 --- a/data/SampleData/Hl7v2/ADT_A05.hl7 +++ b/data/SampleData/Hl7v2/ADT-A13-01.hl7 @@ -1,4 +1,4 @@ -MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A05^ADT_A05|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A13^ADT_A13|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO SFT|Orion|2.4.3.52854|Rhapsody|2.4.3|Testactivity|20070725111624 EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet diff --git a/data/SampleData/Hl7v2/ADT-A13-02.hl7 b/data/SampleData/Hl7v2/ADT-A13-02.hl7 new file mode 100644 index 000000000..d80b03bbf --- /dev/null +++ b/data/SampleData/Hl7v2/ADT-A13-02.hl7 @@ -0,0 +1,5 @@ +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A13^ADT_A13|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110|20150208113419+0110|20150209113419+0110||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital +PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT||||||||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C diff --git a/data/SampleData/Hl7v2/ADT_A14.hl7 b/data/SampleData/Hl7v2/ADT-A14-01.hl7 similarity index 93% rename from data/SampleData/Hl7v2/ADT_A14.hl7 rename to data/SampleData/Hl7v2/ADT-A14-01.hl7 index 07dcce042..7dbe40ce3 100644 --- a/data/SampleData/Hl7v2/ADT_A14.hl7 +++ b/data/SampleData/Hl7v2/ADT-A14-01.hl7 @@ -4,8 +4,8 @@ EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfs PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet PD1|S^^ACR||LINDAS TEST ORGANIZATION^^SIISCLIENT818|88^Hippo^rold^H^V^Dr^MD^^TE^^^M10^DN^^||||||||||Methodist Church|||20150202^20150202 NK1|1|Evan&&&&Aniston^ADAM^A^III^Dr.^MD^D|EMC^test^ACR^CHD^^^9.0^10.0|2222&HOME&STREET^Highway^GREENSBORO^NC^27401-1020^US^BI^^jkdha&test^^^^20000110^20050111~111&Duck ST^^Fowl|78788788^WPN^Internet^5555^^^^^^^^^20010110^20020110^^^^18~121111^PRN^CP|88888888^PRN^CP^5555^^^^^^^^878777^20010110^20020110^^^^18~6666666^^BP|O|20210818|20211218|||12345567^4^M11^T1&2.16.840.1.113883.19&HCD^MR^University Hospital^19241011^19241012|TestOrg^^O12^^^^EI^^^Org12||F^^^M|19620110045504||||ara||||||||||Green^John^A^II^DR^MD^D^^^19241012^G~Josh&&&&Bing^^stanley^^^^L|898989898^^FX~88888888^^CP|Street1&Palkstreet~ST-2|I-123^^^^BA~I-222^^^^DI||2106-3^test^FDDC||Security no-23|||1515151515^WPN^CP^555544^^^^^^^^777^20010110^20020110^^^^1|444444^^CP -PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital -PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT||||||||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital +PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT|||||20150208113419|20150209113419||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C DB1|1|PT|DB123^4^M11^t&1.12&ISO^MR^UH^19241011^19241012|Y|20210830|20210930| OBX|27|NM|8867-4^heartrate^LN||60~120|beats/min^^ISO|70-80|A^A^HL7nnnn~B^B|||S|||19990702|Org15^ID of producer^CAS|1134^Aly^Zafar^Mahendra^JR^Dr.^MD^^PERSt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al~2234^Pauly^Berrie^Raud|OBS^This is test method^AS4|EI12.3^NI2^UI2^GUID~^^UI1^ISO|19990702|BU^Observation site^E5|EI21^OII||FairOaks Hspital|Research Park^Fairfax^VA^22031^USA|MD-25^Atchinson^Christopher^^MD|||||||PAI-1^FAI-1 AL1|1|EA|P^PENICILLIN^ICDO|MI|CODE16|20210824 diff --git a/data/SampleData/Hl7v2/ADT-A14-02.hl7 b/data/SampleData/Hl7v2/ADT-A14-02.hl7 new file mode 100644 index 000000000..b61cd544b --- /dev/null +++ b/data/SampleData/Hl7v2/ADT-A14-02.hl7 @@ -0,0 +1,5 @@ +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A14^ADT_A14|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110|20150209113419+0110|||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital +PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT||||||||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C diff --git a/data/SampleData/Hl7v2/ADT-A15-01.hl7 b/data/SampleData/Hl7v2/ADT-A15-01.hl7 new file mode 100644 index 000000000..95be90cde --- /dev/null +++ b/data/SampleData/Hl7v2/ADT-A15-01.hl7 @@ -0,0 +1,9 @@ +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A15^ADT_A15|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SFT|Orion|2.4.3.52854|Rhapsody|2.4.3|Testactivity|20070725111624 +EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet +PD1|S^^ACR||LINDAS TEST ORGANIZATION^^SIISCLIENT818|88^Hippo^rold^H^V^Dr^MD^^TE^^^M10^DN^^||||||||||Methodist Church|||20150202^20150202 +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital +PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT||||||||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C +DB1|1|PT|DB123^4^M11^t&1.12&ISO^MR^UH^19241011^19241012|Y|20210830|20210930| +OBX|27|NM|8867-4^heartrate^LN||60~120|beats/min^^ISO|70-80|A^A^HL7nnnn~B^B|||S|||19990702|Org15^ID of producer^CAS|1134^Aly^Zafar^Mahendra^JR^Dr.^MD^^PERSt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al~2234^Pauly^Berrie^Raud|OBS^This is test method^AS4|EI12.3^NI2^UI2^GUID~^^UI1^ISO|19990702|BU^Observation site^E5|EI21^OII||FairOaks Hspital|Research Park^Fairfax^VA^22031^USA|MD-25^Atchinson^Christopher^^MD|||||||PAI-1^FAI-1 \ No newline at end of file diff --git a/data/SampleData/Hl7v2/ADT_A15-2.hl7 b/data/SampleData/Hl7v2/ADT-A15-02.hl7 similarity index 100% rename from data/SampleData/Hl7v2/ADT_A15-2.hl7 rename to data/SampleData/Hl7v2/ADT-A15-02.hl7 diff --git a/data/SampleData/Hl7v2/ADT_A16.hl7 b/data/SampleData/Hl7v2/ADT-A16-01.hl7 similarity index 96% rename from data/SampleData/Hl7v2/ADT_A16.hl7 rename to data/SampleData/Hl7v2/ADT-A16-01.hl7 index 95dd0c7cb..a3f111acd 100644 --- a/data/SampleData/Hl7v2/ADT_A16.hl7 +++ b/data/SampleData/Hl7v2/ADT-A16-01.hl7 @@ -5,7 +5,7 @@ PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M1 PD1|S^^ACR||LINDAS TEST ORGANIZATION^^SIISCLIENT818|88^Hippo^rold^H^V^Dr^MD^^TE^^^M10^DN^^||||||||||Methodist Church|||20150202^20150202 NK1|1|Evan&&&&Aniston^ADAM^A^III^Dr.^MD^D|EMC^test^ACR^CHD^^^9.0^10.0|2222&HOME&STREET^Highway^GREENSBORO^NC^27401-1020^US^BI^^jkdha&test^^^^20000110^20050111~111&Duck ST^^Fowl|78788788^WPN^Internet^5555^^^^^^^^^20010110^20020110^^^^18~121111^PRN^CP|88888888^PRN^CP^5555^^^^^^^^878777^20010110^20020110^^^^18~6666666^^BP|O|20210818|20211218|||12345567^4^M11^T1&2.16.840.1.113883.19&HCD^MR^University Hospital^19241011^19241012|TestOrg^^O12^^^^EI^^^Org12||F^^^M|19620110045504||||ara||||||||||Green^John^A^II^DR^MD^D^^^19241012^G~Josh&&&&Bing^^stanley^^^^L|898989898^^FX~88888888^^CP|Street1&Palkstreet~ST-2|I-123^^^^BA~I-222^^^^DI||2106-3^test^FDDC||Security no-23|||1515151515^WPN^CP^555544^^^^^^^^777^20010110^20020110^^^^1|444444^^CP PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital -PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT||||||||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C +PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT||||||20150210113419+0110||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C DB1|1|PT|DB123^4^M11^t&1.12&ISO^MR^UH^19241011^19241012|Y|20210830|20210930| OBX|27|NM|8867-4^heartrate^LN||60~120|beats/min^^ISO|70-80|A^A^HL7nnnn~B^B|||S|||19990702|Org15^ID of producer^CAS|1134^Aly^Zafar^Mahendra^JR^Dr.^MD^^PERSt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al~2234^Pauly^Berrie^Raud|OBS^This is test method^AS4|EI12.3^NI2^UI2^GUID~^^UI1^ISO|19990702|BU^Observation site^E5|EI21^OII||FairOaks Hspital|Research Park^Fairfax^VA^22031^USA|MD-25^Atchinson^Christopher^^MD|||||||PAI-1^FAI-1 AL1|1|EA|P^PENICILLIN^ICDO|MI|CODE16|20210824 diff --git a/data/SampleData/Hl7v2/ADT_A16-2.hl7 b/data/SampleData/Hl7v2/ADT-A16-02.hl7 similarity index 86% rename from data/SampleData/Hl7v2/ADT_A16-2.hl7 rename to data/SampleData/Hl7v2/ADT-A16-02.hl7 index ffb8f8006..55d80aad3 100644 --- a/data/SampleData/Hl7v2/ADT_A16-2.hl7 +++ b/data/SampleData/Hl7v2/ADT-A16-02.hl7 @@ -1,4 +1,5 @@ MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A16^ADT_A16|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet -PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital \ No newline at end of file +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital +PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT||||||20150210113419+0110||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C diff --git a/data/SampleData/Hl7v2/ADT_A15.hl7 b/data/SampleData/Hl7v2/ADT-A25-01.hl7 similarity index 98% rename from data/SampleData/Hl7v2/ADT_A15.hl7 rename to data/SampleData/Hl7v2/ADT-A25-01.hl7 index 30fd9f5ce..cf1094892 100644 --- a/data/SampleData/Hl7v2/ADT_A15.hl7 +++ b/data/SampleData/Hl7v2/ADT-A25-01.hl7 @@ -1,4 +1,4 @@ -MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A15^ADT_A15|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A25^ADT_A25|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO SFT|Orion|2.4.3.52854|Rhapsody|2.4.3|Testactivity|20070725111624 EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet diff --git a/data/SampleData/Hl7v2/ADT-A25-02.hl7 b/data/SampleData/Hl7v2/ADT-A25-02.hl7 new file mode 100644 index 000000000..e68d494a3 --- /dev/null +++ b/data/SampleData/Hl7v2/ADT-A25-02.hl7 @@ -0,0 +1,5 @@ +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A25^ADT_A25|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110|20150209113419+0110|||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital +PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT||||||||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C diff --git a/data/SampleData/Hl7v2/ADT-A26-01.hl7 b/data/SampleData/Hl7v2/ADT-A26-01.hl7 new file mode 100644 index 000000000..f5899be53 --- /dev/null +++ b/data/SampleData/Hl7v2/ADT-A26-01.hl7 @@ -0,0 +1,9 @@ +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A26^ADT_A26|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SFT|Orion|2.4.3.52854|Rhapsody|2.4.3|Testactivity|20070725111624 +EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet +PD1|S^^ACR||LINDAS TEST ORGANIZATION^^SIISCLIENT818|88^Hippo^rold^H^V^Dr^MD^^TE^^^M10^DN^^||||||||||Methodist Church|||20150202^20150202 +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital +PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT||||||||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C +DB1|1|PT|DB123^4^M11^t&1.12&ISO^MR^UH^19241011^19241012|Y|20210830|20210930| +OBX|27|NM|8867-4^heartrate^LN||60~120|beats/min^^ISO|70-80|A^A^HL7nnnn~B^B|||S|||19990702|Org15^ID of producer^CAS|1134^Aly^Zafar^Mahendra^JR^Dr.^MD^^PERSt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al~2234^Pauly^Berrie^Raud|OBS^This is test method^AS4|EI12.3^NI2^UI2^GUID~^^UI1^ISO|19990702|BU^Observation site^E5|EI21^OII||FairOaks Hspital|Research Park^Fairfax^VA^22031^USA|MD-25^Atchinson^Christopher^^MD|||||||PAI-1^FAI-1 \ No newline at end of file diff --git a/data/SampleData/Hl7v2/ADT_A03-2.hl7 b/data/SampleData/Hl7v2/ADT-A26-02.hl7 similarity index 97% rename from data/SampleData/Hl7v2/ADT_A03-2.hl7 rename to data/SampleData/Hl7v2/ADT-A26-02.hl7 index 9f6aefaa7..88febdcd2 100644 --- a/data/SampleData/Hl7v2/ADT_A03-2.hl7 +++ b/data/SampleData/Hl7v2/ADT-A26-02.hl7 @@ -1,4 +1,4 @@ -MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A03^ADT_A03|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A26^ADT_A26|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital \ No newline at end of file diff --git a/data/SampleData/Hl7v2/ADT-A27-01.hl7 b/data/SampleData/Hl7v2/ADT-A27-01.hl7 new file mode 100644 index 000000000..ac4a4eab9 --- /dev/null +++ b/data/SampleData/Hl7v2/ADT-A27-01.hl7 @@ -0,0 +1,9 @@ +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A27^ADT_A27|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SFT|Orion|2.4.3.52854|Rhapsody|2.4.3|Testactivity|20070725111624 +EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet +PD1|S^^ACR||LINDAS TEST ORGANIZATION^^SIISCLIENT818|88^Hippo^rold^H^V^Dr^MD^^TE^^^M10^DN^^||||||||||Methodist Church|||20150202^20150202 +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113420+0110||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital +PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT|||||20150208113419+0110|20150209113419+0110||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C +DB1|1|PT|DB123^4^M11^t&1.12&ISO^MR^UH^19241011^19241012|Y|20210830|20210930| +OBX|27|NM|8867-4^heartrate^LN||60~120|beats/min^^ISO|70-80|A^A^HL7nnnn~B^B|||S|||19990702|Org15^ID of producer^CAS|1134^Aly^Zafar^Mahendra^JR^Dr.^MD^^PERSt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al~2234^Pauly^Berrie^Raud|OBS^This is test method^AS4|EI12.3^NI2^UI2^GUID~^^UI1^ISO|19990702|BU^Observation site^E5|EI21^OII||FairOaks Hspital|Research Park^Fairfax^VA^22031^USA|MD-25^Atchinson^Christopher^^MD|||||||PAI-1^FAI-1 \ No newline at end of file diff --git a/data/SampleData/Hl7v2/ADT-A27-02.hl7 b/data/SampleData/Hl7v2/ADT-A27-02.hl7 new file mode 100644 index 000000000..6ba5fa7e2 --- /dev/null +++ b/data/SampleData/Hl7v2/ADT-A27-02.hl7 @@ -0,0 +1,5 @@ +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A27^ADT_A27|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110|20150209113419+0110|||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital +PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT||||||||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C diff --git a/data/SampleData/Hl7v2/ADT_A28.hl7 b/data/SampleData/Hl7v2/ADT-A28-01.hl7 similarity index 97% rename from data/SampleData/Hl7v2/ADT_A28.hl7 rename to data/SampleData/Hl7v2/ADT-A28-01.hl7 index 5d225a70e..69964ba26 100644 --- a/data/SampleData/Hl7v2/ADT_A28.hl7 +++ b/data/SampleData/Hl7v2/ADT-A28-01.hl7 @@ -4,7 +4,7 @@ EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfs PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet PD1|S^^ACR||LINDAS TEST ORGANIZATION^^SIISCLIENT818|88^Hippo^rold^H^V^Dr^MD^^TE^^^M10^DN^^||||||||||Methodist Church|||20150202^20150202 NK1|1|Evan&&&&Aniston^ADAM^A^III^Dr.^MD^D|EMC^test^ACR^CHD^^^9.0^10.0|2222&HOME&STREET^Highway^GREENSBORO^NC^27401-1020^US^BI^^jkdha&test^^^^20000110^20050111~111&Duck ST^^Fowl|78788788^WPN^Internet^5555^^^^^^^^^20010110^20020110^^^^18~121111^PRN^CP|88888888^PRN^CP^5555^^^^^^^^878777^20010110^20020110^^^^18~6666666^^BP|O|20210818|20211218|||12345567^4^M11^T1&2.16.840.1.113883.19&HCD^MR^University Hospital^19241011^19241012|TestOrg^^O12^^^^EI^^^Org12||F^^^M|19620110045504||||ara||||||||||Green^John^A^II^DR^MD^D^^^19241012^G~Josh&&&&Bing^^stanley^^^^L|898989898^^FX~88888888^^CP|Street1&Palkstreet~ST-2|I-123^^^^BA~I-222^^^^DI||2106-3^test^FDDC||Security no-23|||1515151515^WPN^CP^555544^^^^^^^^777^20010110^20020110^^^^1|444444^^CP -PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110|20150209113419+0110|||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT||||||||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C DB1|1|PT|DB123^4^M11^t&1.12&ISO^MR^UH^19241011^19241012|Y|20210830|20210930| OBX|27|NM|8867-4^heartrate^LN||60~120|beats/min^^ISO|70-80|A^A^HL7nnnn~B^B|||S|||19990702|Org15^ID of producer^CAS|1134^Aly^Zafar^Mahendra^JR^Dr.^MD^^PERSt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al~2234^Pauly^Berrie^Raud|OBS^This is test method^AS4|EI12.3^NI2^UI2^GUID~^^UI1^ISO|19990702|BU^Observation site^E5|EI21^OII||FairOaks Hspital|Research Park^Fairfax^VA^22031^USA|MD-25^Atchinson^Christopher^^MD|||||||PAI-1^FAI-1 diff --git a/data/SampleData/Hl7v2/ADT_A28-2.hl7 b/data/SampleData/Hl7v2/ADT-A28-02.hl7 similarity index 100% rename from data/SampleData/Hl7v2/ADT_A28-2.hl7 rename to data/SampleData/Hl7v2/ADT-A28-02.hl7 diff --git a/data/SampleData/Hl7v2/ADT-A29-01.hl7 b/data/SampleData/Hl7v2/ADT-A29-01.hl7 new file mode 100644 index 000000000..bc08c368c --- /dev/null +++ b/data/SampleData/Hl7v2/ADT-A29-01.hl7 @@ -0,0 +1,9 @@ +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A29^ADT_A29|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SFT|Orion|2.4.3.52854|Rhapsody|2.4.3|Testactivity|20070725111624 +EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet +PD1|S^^ACR||LINDAS TEST ORGANIZATION^^SIISCLIENT818|88^Hippo^rold^H^V^Dr^MD^^TE^^^M10^DN^^||||||||||Methodist Church|||20150202^20150202 +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital +PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT||||||||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C +DB1|1|PT|DB123^4^M11^t&1.12&ISO^MR^UH^19241011^19241012|Y|20210830|20210930| +OBX|27|NM|8867-4^heartrate^LN||60~120|beats/min^^ISO|70-80|A^A^HL7nnnn~B^B|||S|||19990702|Org15^ID of producer^CAS|1134^Aly^Zafar^Mahendra^JR^Dr.^MD^^PERSt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al~2234^Pauly^Berrie^Raud|OBS^This is test method^AS4|EI12.3^NI2^UI2^GUID~^^UI1^ISO|19990702|BU^Observation site^E5|EI21^OII||FairOaks Hspital|Research Park^Fairfax^VA^22031^USA|MD-25^Atchinson^Christopher^^MD|||||||PAI-1^FAI-1 \ No newline at end of file diff --git a/data/SampleData/Hl7v2/ADT_A05-2.hl7 b/data/SampleData/Hl7v2/ADT-A29-02.hl7 similarity index 97% rename from data/SampleData/Hl7v2/ADT_A05-2.hl7 rename to data/SampleData/Hl7v2/ADT-A29-02.hl7 index b995abc80..0f8e24634 100644 --- a/data/SampleData/Hl7v2/ADT_A05-2.hl7 +++ b/data/SampleData/Hl7v2/ADT-A29-02.hl7 @@ -1,4 +1,4 @@ -MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A05^ADT_A05|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A29^ADT_A29|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital \ No newline at end of file diff --git a/data/SampleData/Hl7v2/ADT_A31.hl7 b/data/SampleData/Hl7v2/ADT-A31-01.hl7 similarity index 97% rename from data/SampleData/Hl7v2/ADT_A31.hl7 rename to data/SampleData/Hl7v2/ADT-A31-01.hl7 index 914ce19ae..212f11620 100644 --- a/data/SampleData/Hl7v2/ADT_A31.hl7 +++ b/data/SampleData/Hl7v2/ADT-A31-01.hl7 @@ -4,7 +4,7 @@ EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfs PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet PD1|S^^ACR||LINDAS TEST ORGANIZATION^^SIISCLIENT818|88^Hippo^rold^H^V^Dr^MD^^TE^^^M10^DN^^||||||||||Methodist Church|||20150202^20150202 NK1|1|Evan&&&&Aniston^ADAM^A^III^Dr.^MD^D|EMC^test^ACR^CHD^^^9.0^10.0|2222&HOME&STREET^Highway^GREENSBORO^NC^27401-1020^US^BI^^jkdha&test^^^^20000110^20050111~111&Duck ST^^Fowl|78788788^WPN^Internet^5555^^^^^^^^^20010110^20020110^^^^18~121111^PRN^CP|88888888^PRN^CP^5555^^^^^^^^878777^20010110^20020110^^^^18~6666666^^BP|O|20210818|20211218|||12345567^4^M11^T1&2.16.840.1.113883.19&HCD^MR^University Hospital^19241011^19241012|TestOrg^^O12^^^^EI^^^Org12||F^^^M|19620110045504||||ara||||||||||Green^John^A^II^DR^MD^D^^^19241012^G~Josh&&&&Bing^^stanley^^^^L|898989898^^FX~88888888^^CP|Street1&Palkstreet~ST-2|I-123^^^^BA~I-222^^^^DI||2106-3^test^FDDC||Security no-23|||1515151515^WPN^CP^555544^^^^^^^^777^20010110^20020110^^^^1|444444^^CP -PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110|20150209113419+0110|||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT||||||||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C DB1|1|PT|DB123^4^M11^t&1.12&ISO^MR^UH^19241011^19241012|Y|20210830|20210930| OBX|27|NM|8867-4^heartrate^LN||60~120|beats/min^^ISO|70-80|A^A^HL7nnnn~B^B|||S|||19990702|Org15^ID of producer^CAS|1134^Aly^Zafar^Mahendra^JR^Dr.^MD^^PERSt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al~2234^Pauly^Berrie^Raud|OBS^This is test method^AS4|EI12.3^NI2^UI2^GUID~^^UI1^ISO|19990702|BU^Observation site^E5|EI21^OII||FairOaks Hspital|Research Park^Fairfax^VA^22031^USA|MD-25^Atchinson^Christopher^^MD|||||||PAI-1^FAI-1 diff --git a/data/SampleData/Hl7v2/ADT_A31-2.hl7 b/data/SampleData/Hl7v2/ADT-A31-02.hl7 similarity index 100% rename from data/SampleData/Hl7v2/ADT_A31-2.hl7 rename to data/SampleData/Hl7v2/ADT-A31-02.hl7 diff --git a/data/SampleData/Hl7v2/ADT-A45-01.hl7 b/data/SampleData/Hl7v2/ADT-A45-01.hl7 new file mode 100644 index 000000000..8c6256c92 --- /dev/null +++ b/data/SampleData/Hl7v2/ADT-A45-01.hl7 @@ -0,0 +1,6 @@ +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A45^ADT_A45|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SFT|Orion|2.4.3.52854|Rhapsody|2.4.3|Testactivity|20070725111624 +EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet +PD1|S^^ACR||LINDAS TEST ORGANIZATION^^SIISCLIENT818|88^Hippo^rold^H^V^Dr^MD^^TE^^^M10^DN^^||||||||||Methodist Church|||20150202^20150202 +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110|20150209113419+0110|||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital \ No newline at end of file diff --git a/data/SampleData/Hl7v2/ADT_A04-2.hl7 b/data/SampleData/Hl7v2/ADT-A45-02.hl7 similarity index 97% rename from data/SampleData/Hl7v2/ADT_A04-2.hl7 rename to data/SampleData/Hl7v2/ADT-A45-02.hl7 index 01242018e..a4a3651a1 100644 --- a/data/SampleData/Hl7v2/ADT_A04-2.hl7 +++ b/data/SampleData/Hl7v2/ADT-A45-02.hl7 @@ -1,4 +1,4 @@ -MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A04^ADT_A04|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A45^ADT_A45|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital \ No newline at end of file diff --git a/data/SampleData/Hl7v2/ADT_A47.hl7 b/data/SampleData/Hl7v2/ADT-A47-01.hl7 similarity index 100% rename from data/SampleData/Hl7v2/ADT_A47.hl7 rename to data/SampleData/Hl7v2/ADT-A47-01.hl7 diff --git a/data/SampleData/Hl7v2/ADT_A47-2.hl7 b/data/SampleData/Hl7v2/ADT-A47-02.hl7 similarity index 100% rename from data/SampleData/Hl7v2/ADT_A47-2.hl7 rename to data/SampleData/Hl7v2/ADT-A47-02.hl7 diff --git a/data/SampleData/Hl7v2/ADT_A60.hl7 b/data/SampleData/Hl7v2/ADT-A60-01.hl7 similarity index 96% rename from data/SampleData/Hl7v2/ADT_A60.hl7 rename to data/SampleData/Hl7v2/ADT-A60-01.hl7 index 0114015f2..88ebf7d8c 100644 --- a/data/SampleData/Hl7v2/ADT_A60.hl7 +++ b/data/SampleData/Hl7v2/ADT-A60-01.hl7 @@ -2,7 +2,7 @@ MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFac SFT|Orion|2.4.3.52854|Rhapsody|2.4.3|Testactivity|20070725111624 EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet -PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110|20150209113419+0110|||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT||||||||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C IAM|1|FA^Food allergy^HL70127|12345^Peanut Allergy^L|||A^Add/Insert^HL70206|56789^Cona_Health^1.3.6.1.4.1.44750.1.4^ISO||SE^Side Effect||201805||202010051600|Doe^Rosallie^John^III^Mrs.^Bachelors^R|SPO^Spouse||C^Confirmed or verified||||||9941339108^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|202010101600+0215||202010151600+0215|91935009^Allergy to Peanuts^SNM3 NTE|1||Allergy to peanuts observed.||9941339108^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|202010101600+0215| diff --git a/data/SampleData/Hl7v2/ADT_A60-2.hl7 b/data/SampleData/Hl7v2/ADT-A60-02.hl7 similarity index 100% rename from data/SampleData/Hl7v2/ADT_A60-2.hl7 rename to data/SampleData/Hl7v2/ADT-A60-02.hl7 diff --git a/data/SampleData/Hl7v2/ADT01-28.hl7 b/data/SampleData/Hl7v2/ADT01-28.hl7 index 6a0277165..2c4b5dd17 100644 --- a/data/SampleData/Hl7v2/ADT01-28.hl7 +++ b/data/SampleData/Hl7v2/ADT01-28.hl7 @@ -1,4 +1,4 @@ -MSH|^~\&|ADT1|GOOD HEALTH HOSPITAL|GHH LAB, INC.|GOOD HEALTH HOSPITAL|198808181126|SECURITY|ADT^A01^ADT_A01|MSG00001|P|2.5.1|| +MSH|^~\&|ADT1|GOOD HEALTH HOSPITAL|GHH LAB, INC.|GOOD HEALTH HOSPITAL|198810181126|SECURITY|ADT^A01^ADT_A01|MSG00001|P|2.5.1|| EVN|A01|200708181123|| PID|1||PATID1234^5^M11^ADT1^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS||EVERYMAN^ADAM^A^III||19610615|M||C|2222 HOME STREET^^GREENSBORO^NC^27401-1020|GL|(555) 555-2004|(555)555-2004||S||PATID12345001^2^M10^ADT1^AN^A|444333333|987654^NC| NK1|1|NUCLEAR^NELDA^W|SPO^SPOUSE||||NK^NEXT OF KIN diff --git a/data/SampleData/Hl7v2/MDM-T01-01.hl7 b/data/SampleData/Hl7v2/MDM-T01-01.hl7 new file mode 100644 index 000000000..ce1a6f9df --- /dev/null +++ b/data/SampleData/Hl7v2/MDM-T01-01.hl7 @@ -0,0 +1,10 @@ +MSH|^~\&|PROSOLV|XYZHOSPITAL|SYSTEM|XYZHOSPITAL|200801311600+0215||MDM^T02|PS1-20080131160038|P|2. +SFT|Orion|2.4.3.52854|Rhapsody|2.4.3|Testactivity|20070725111624 +EVN|T10|200801311600+0215|||C08^Woolfson^Kathleen +PID|1|987654321|987654321||PROSOLV^SAMPLE||19721201|M||||||||||10000001|111-22-3333 +PV1|1|I|CCU^2000^1|||CCU^2003^1|1234^HIPPOCRATES^KOS|9099^KEVORKIAN^JACK|8888^HOUSE^GREGORY||||||||||10000001 +ORC|SC|00012345|1-1 +TQ1|1|54^&lbs|ACM&Before Breakfast&HL7xxx^HD^^^12^min^^ACM^120^s|11:30:05~11:45:05|30^s|150^&kg|202110091600-0800|202111091600-0800|A|This is condition text|Please follow the text instructions||2^hr|5 +OBR|1|00012345|1-1|02585^TransthoracicEcho^PCV4||20060131155500|20080131155500+0215|||||||||||||||200801311600|||F||||||796.4^^I9M~786.09^^I9M~414.8^^I9M||||54321^Doctorovich^Ivan^ +NTE|1||No Antibodies Detected||MLEE^ATTEND^AARON^A^^^MD|202010101500+0215| +TXA|1|DI|TX|200801311555+0215||200801311600+0215|||IvanDoctorovich|||1.2.840.317.5947431.51.20080131160038|1.2.840.317.5947431.51.20080131155715|00012345|1-1||AU|||||54321^Doctorovich^Ivan^^^^^^^^^^^^200801311600 \ No newline at end of file diff --git a/data/SampleData/Hl7v2/MDM-T01-02.hl7 b/data/SampleData/Hl7v2/MDM-T01-02.hl7 new file mode 100644 index 000000000..563eec6a4 --- /dev/null +++ b/data/SampleData/Hl7v2/MDM-T01-02.hl7 @@ -0,0 +1,12 @@ +MSH|^~\&|PROSOLV|XYZHOSPITAL|SYSTEM|XYZHOSPITAL|200801311600+0215||MDM^T01^MDM_T01|PS1-20080131160038|P|2.8 +SFT|Orion|2.4.3.52854|Rhapsody|2.4.3|Testactivity|20070725111624 +EVN|T10|200801311600+0215|||C08^Woolfson^Kathleen +PID|1|987654321|987654321||PROSOLV^SAMPLE||19721201|M||||||||||10000001|111-22-3333 +PV1|1|I|CCU^2000^1|||CCU^2003^1|1234^HIPPOCRATES^KOS|9099^KEVORKIAN^JACK|8888^HOUSE^GREGORY||||||||||10000001 +ORC|SC|00012345|1-1 +TQ1|1|54^&lbs|ACM&Before Breakfast&HL7xxx^HD^^^12^min^^ACM^120^s|11:30:05~11:45:05|30^s|150^&kg|202110091600-0800|202111091600-0800|A|This is condition text|Please follow the text instructions||2^hr|5 +OBR|1|00012345|1-1|02585^TransthoracicEcho^PCV4|||20080131155500+0215|||||||||||||||200801311600+0215|||F||||||796.4^^I9M~786.09^^I9M~414.8^^I9M||||54321^Doctorovich^Ivan^ +NTE|1||No Antibodies Detected||MLEE^ATTEND^AARON^A^^^MD|202010101500+0215| +ORC|SC|00012367|1-1 +OBR|1|00012367|1-1|02588^3D echo cardigram^PCV4|||20080131164500+0215|||||||||||||||20080131164500+0215|||F||||||796.4^^I9M~786.09^^I9M~414.8^^I9M||||54321^Doctorovich^Ivan^ +TXA|1|DI|TX|200801311555+0215||200801311600+0215|||IvanDoctorovich|||1.2.840.317.5947431.51.20080131160038|1.2.840.317.5947431.51.20080131155715|00012345|1-1||AU|||||54321^Doctorovich^Ivan^^^^^^^^^^^^200801311600 \ No newline at end of file diff --git a/data/SampleData/Hl7v2/MDM-T02-01.hl7 b/data/SampleData/Hl7v2/MDM-T02-01.hl7 new file mode 100644 index 000000000..8c41fffac --- /dev/null +++ b/data/SampleData/Hl7v2/MDM-T02-01.hl7 @@ -0,0 +1,12 @@ +MSH|^~\&|PROSOLV|XYZHOSPITAL|SYSTEM|XYZHOSPITAL|200801311600+0215||MDM^T02^MDM_T02|PS1-20080131160038|P|2.8 +EVN|T10|200801311600+0215|||C08^Woolfson^Kathleen +PID|1|987654321|987654321||PROSOLV^SAMPLE||19721201|M||||||||||10000001|111-22-3333 +PV1|1|I|CCU^2000^1|||CCU^2003^1|1234^HIPPOCRATES^KOS|9099^KEVORKIAN^JACK|8888^HOUSE^GREGORY||||||||||10000001 +ORC|SC|00012345|1-1 +TQ1|1|54^&lbs|ACM&Before Breakfast&HL7xxx^HD^^^12^min^^ACM^120^s|11:30:05~11:45:05|30^s|150^&kg|202110091600-0800|202111091600-0800|A|This is condition text|Please follow the text instructions||2^hr|5 +OBR|1|00012345|1-1|02585^TransthoracicEcho^PCV4||20060131155500|20080131155500+0215|||||||||||||||200801311600+0215|||F||||||796.4^^I9M~786.09^^I9M~414.8^^I9M||||54321^Doctorovich^Ivan^ +NTE|1||No Antibodies Detected||MLEE^ATTEND^AARON^A^^^MD|202010101500+0215| +TXA|1|DI|TX|200801311555+0215||200801311600+0215|||IvanDoctorovich|||1.2.840.317.5947431.51.20080131160038|1.2.840.317.5947431.51.20080131155715|00012345|1-1||AU|||||54321^Doctorovich^Ivan^^^^^^^^^^^^200801311600+0215 +OBX|1|HD|113014^DICOM Study^DCM||1.2.840.317.5947431.51||||||O +NTE|1||Antibodies Detected||MLEE^ATTEND^AARON^A^^^MD|202010101500+0215| +OBX|2|ED|02585^TransthoracicEcho^PCV4||^application^pdf^Base64^||||||F diff --git a/data/SampleData/Hl7v2/MDM-T02-02.hl7 b/data/SampleData/Hl7v2/MDM-T02-02.hl7 new file mode 100644 index 000000000..96b76bfcd --- /dev/null +++ b/data/SampleData/Hl7v2/MDM-T02-02.hl7 @@ -0,0 +1,14 @@ +MSH|^~\&|PROSOLV|XYZHOSPITAL|SYSTEM|XYZHOSPITAL|200801311600+0215||MDM^T02^MDM_T02|PS1-20080131160038|P|2.8 +SFT|Orion|2.4.3.52854|Rhapsody|2.4.3|Testactivity|20070725111624 +EVN|T10|200801311600+0215|||C08^Woolfson^Kathleen +PID|1|987654321|987654321||PROSOLV^SAMPLE||19721201|M||||||||||10000001|111-22-3333 +PV1|1|I|CCU^2000^1|||CCU^2003^1|1234^HIPPOCRATES^KOS|9099^KEVORKIAN^JACK|8888^HOUSE^GREGORY||||||||||10000001 +ORC|SC|00012345|1-1 +TQ1|1|54^&lbs|ACM&Before Breakfast&HL7xxx^HD^^^12^min^^ACM^120^s|11:30:05~11:45:05|30^s|150^&kg|202110091600-0800|202111091600-0800|A|This is condition text|Please follow the text instructions||2^hr|5 +OBR|1|00012345|1-1|02585^TransthoracicEcho^PCV4|||20080131155500+0215|||||||||||||||200801311600+0215|||F||||||796.4^^I9M~786.09^^I9M~414.8^^I9M||||54321^Doctorovich^Ivan^ +NTE|1||No Antibodies Detected||MLEE^ATTEND^AARON^A^^^MD|202010101500+0215| +ORC|SC|00012367|1-1 +OBR|1|00012367|1-1|02588^3D echo cardigram^PCV4||20060131164500+0215|20080131164500+0215|||||||||||||||20080131164500+0215|||F||||||796.4^^I9M~786.09^^I9M~414.8^^I9M||||54321^Doctorovich^Ivan^ +TXA|1|DI|TX|200801311555+0215||200801311600+0215|||IvanDoctorovich|||1.2.840.317.5947431.51.20080131160038|1.2.840.317.5947431.51.20080131155715|00012345|1-1||AU|||||54321^Doctorovich^Ivan^^^^^^^^^^^^200801311600 +OBX|1|TX|obs-id^obs-text^coding-system^^|1|Toilet cylinder crackers model step-mother visor opening communication||||||F|||||| +OBX|2|TX|obs-id^obs-text^coding-system^^|1|Columnist draft inn brown income ikebana circulation prince||||||F|||||| diff --git a/data/SampleData/Hl7v2/MDM-T02-03.hl7 b/data/SampleData/Hl7v2/MDM-T02-03.hl7 new file mode 100644 index 000000000..8416a776e --- /dev/null +++ b/data/SampleData/Hl7v2/MDM-T02-03.hl7 @@ -0,0 +1,36 @@ +MSH|^~\&|SIMHOSP|SFAC|RAPP|RFAC|20210801090642+0215||MDM^T02^MDM_T02|112|T|2.3|||AL||44|ASCII +EVN|T02|20210801090642+0215|||C006^Woolfson^Kathleen^^^Dr^^^DRNBR^REL^^^ORGDR| +PID|1|3196695816^^^SIMULATOR MRN^MRN|3196695816^^^SIMULATOR MRN^MRN~6597923189^^^NHSNBR^NHSNMBR||Clark^Frederick^^^Mr^^A||19300122000000+0215|M|||19 Blocker House^Restaurant Square^Ilford^^WI3 7KU^GBR^HOME||073 0075 3040^BPN^PH|||||||||A^White - British^^^|||||||| +PV1|1|O||28b|||C006^Woolfson^Kathleen^^^Dr^^^DRNBR^REL^^^ORGDR|||MED|||||||||||||||||||||||||||||||||||| +ORC|NW||986^IA PHIMS Stage^2.16.840.1.114222.4.3.3.5.1.2^ISO|PGN-04||||ORC-8.1&ORC8.1.2^ORC8.2|202009101700+0215||||||204010101700+0215||||||MISSOURI DEPARTMENT OF HEALTH LABORATORY - MISSOURI DEPARTMENT OF HEALTH LABORATORY^L|307 W MCCARTY ST^^JEFFERSON CITY^MO^65101^USA^B|^WPN^PH^^1^^5555555|St-24, Greenwood^Building2|||||O^Outpatient Facility||orc-31 +OBR|1|845439^GHH OE|986^IA PHIMS Stage^2.16.840.1.114222.4.3.3.5.1.2^ISO|625-4^Bacteria identified in Stool by Culture^XYZ^^^^2.33^^Enteric Culture|R|202010101700+0215|200202150730+0215||150^lb&lb&ANSI+|10535^van Beethoven&van^Ludwig^A^III^Dr^PHD^^&MPI.Community Health and Hospitals&L^L^3^M10^MR^& Good Health Hospital.Community Health and Hospitals&L^A|G|||200202120730+0215|SP15&1.2&L^ACDA^Collection Method^BN&223.3&L|||Placer 1|Placer 2|Filler 1|Filler 2|200203150730+0215||BLB|F||||PAI-29||444^HIPPOCRATES^HOWARD H^^^^MD|Harry&Raud&Geny&&Mr.&Dr.^^^Poc-32^Room-4^Bed3^Facility-3&1.2&ISO^^^Building-4^FL-2||Richa&&&&Mr.&Md.^^^Poc-34^Rm-4^Bed2^Facility-4&1.22&ISO^^^Building-3^FL-3|35&Samuel^20021111^20021112^Area23||||Collector's comment|||||||PSS-46^Placer service^L|FSS-47^Filler service^L|||50^11.22^AR|||APON-53^4^M11^ORU^MR^University Hospital +TXA|1|DS||20210801090642+0215|C006^Woolfson^Kathleen^^^Dr^^^DRNBR^REL^^^ORGDR|202108030000+0215||20210801090642+0215||||2RWRVAJ627408|||||IP|||||| +OBX|1|TX|obs-id^obs-text^coding-system^^|1|Toilet cylinder crackers model step-mother visor opening communication||||||F|||||| +OBX|2|TX|obs-id^obs-text^coding-system^^|1|Columnist draft inn brown income ikebana circulation prince||||||F|||||| +OBX|3|TX|obs-id^obs-text^coding-system^^|1|Taxicab creator film therapist shelter||||||F|||||| +OBX|4|TX|obs-id^obs-text^coding-system^^|1|Naming grandmother ruth||||||F|||||| +OBX|5|TX|obs-id^obs-text^coding-system^^|1|Cesspool dress crystallography processing sphynx conspirator plate tool||||||F|||||| +OBX|6|TX|obs-id^obs-text^coding-system^^|1|Let nothing neuropathologist grass||||||F|||||| +OBX|7|TX|obs-id^obs-text^coding-system^^|1|James flavor source sweats perfume spasm||||||F|||||| +OBX|8|TX|obs-id^obs-text^coding-system^^|1|Stopsign||||||F|||||| +OBX|9|TX|obs-id^obs-text^coding-system^^|1|Neat rugby sound evening hostel curio chastity pulley wallet xylophone||||||F|||||| +OBX|10|TX|obs-id^obs-text^coding-system^^|1|Tomorrow survey raffle epee cash herb hovel frame||||||F|||||| +OBX|11|TX|obs-id^obs-text^coding-system^^|1|Wish orangutan caddy mayor knowledge guilt tight criteria||||||F|||||| +OBX|12|TX|obs-id^obs-text^coding-system^^|1|Thong||||||F|||||| +OBX|13|TX|obs-id^obs-text^coding-system^^|1|Scimitar gall-bladder economy orange trade sing town||||||F|||||| +OBX|14|TX|obs-id^obs-text^coding-system^^|1|Vinyl people junk skiing north irony sing scorn cameo||||||F|||||| +OBX|15|TX|obs-id^obs-text^coding-system^^|1|Math pimp wave leather national nurture responsibility suppression||||||F|||||| +OBX|16|TX|obs-id^obs-text^coding-system^^|1|Sash area||||||F|||||| +OBX|17|TX|obs-id^obs-text^coding-system^^|1|Search eyelids||||||F|||||| +OBX|18|TX|obs-id^obs-text^coding-system^^|1|Suffocation face convert soup cricket||||||F|||||| +OBX|19|TX|obs-id^obs-text^coding-system^^|1|Step-Grandmother||||||F|||||| +OBX|20|TX|obs-id^obs-text^coding-system^^|1|Pheasant shot disembodiment||||||F|||||| +OBX|21|TX|obs-id^obs-text^coding-system^^|1|White feature||||||F|||||| +OBX|22|TX|obs-id^obs-text^coding-system^^|1|Duster||||||F|||||| +OBX|23|TX|obs-id^obs-text^coding-system^^|1|Science cycle demand||||||F|||||| +OBX|24|TX|obs-id^obs-text^coding-system^^|1|Charm official||||||F|||||| +OBX|25|TX|obs-id^obs-text^coding-system^^|1|Airport manservant||||||F|||||| +OBX|26|TX|obs-id^obs-text^coding-system^^|1|Lanai flute unique plain feature parking pressure||||||F|||||| +OBX|27|TX|obs-id^obs-text^coding-system^^|1|Instance buggy colt route pier menorah ingrate garb||||||F|||||| +OBX|28|TX|obs-id^obs-text^coding-system^^|1|Character press mini comic||||||F|||||| +OBX|29|TX|obs-id^obs-text^coding-system^^|1|Reminder shofar congo vibration mother-in-law bondsman suspect||||||F|||||| \ No newline at end of file diff --git a/data/SampleData/Hl7v2/MDM_01.hl7 b/data/SampleData/Hl7v2/MDM_01.hl7 new file mode 100644 index 000000000..440a5203c --- /dev/null +++ b/data/SampleData/Hl7v2/MDM_01.hl7 @@ -0,0 +1,12 @@ +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A01^ADT_A01|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SFT|Orion|2.4.3.52854|Rhapsody|2.4.3|Testactivity|20070725111624 +EVN|A01|20290801070624+0115|20290801070724|01^Patient request^HL70062|C08^Woolfson^Kathleen^2ndname^Jr^Dr^MD^^DRNBR&W1.2&ISO^L^^^ANON|20210817151943.4+0200|Cona_Health^1.3.6.1.4.1.44750.1.4^ISO +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital +ORC|NW||986^IA PHIMS Stage^2.16.840.1.114222.4.3.3.5.1.2^ISO|PGN-04|CM||||202009101700+0215||||||||||||MISSOURI DEPARTMENT OF HEALTH LABORATORY - MISSOURI DEPARTMENT OF HEALTH LABORATORY^L|307 W MCCARTY ST^^JEFFERSON CITY^MO^65101^USA^B|^WPN^PH^^1^^5555555|St-24, Greenwood^Building2|||||O^Outpatient Facility +TQ1|||||||||A^ASAP|202101251600|202101251700 +OBR|1|845439^GHH OE|986^IA PHIMS Stage^2.16.840.1.114222.4.3.3.5.1.2^ISO|625-4^Bacteria identified in Stool by Culture^LN^^^^2.33^^Enteric Culture|A|202010101700+0215|200202150730+0215||150^lb&lb&ANSI+|10535^van Beethoven&van^Ludwig^A^III^Dr^PHD^^&MPI.Community Health and Hospitals&L^L^3^M10^MR^& Good Health Hospital.Community Health and Hospitals&L^A||||200202120730+0215|SP15&1.2&L^ACDA^Collection Method^BN&223.3&L|||Placer 1|Placer 2|Filler 1|Filler 2|200203150730+0215||BLB|F||12&lb^BID&12:30:05^S50^20020315^20030315^^^Annotation text^^^^21||PAI-291^FAI-292||444^HIPPOCRATES^HOWARD H^^^^MD|Harry&Raud&Geny&&Mr.&Dr.^^^Poc-32^Room-4^Bed3^Facility-3&1.2&ISO^^^Building-4^FL-2||Richa&&&&Mr.&Md.^^^Poc-34^Rm-4^Bed2^Facility-4&1.22&ISO^^^Building-3^FL-3|35&Samuel^20021111^20021112^Area23||||Collector's comment|||||||PSS-46^Placer service^L|FSS-47^Filler service^L|||50^11.22^AR|||APON-53^4^M11^ORU^MR^University Hospital +NTE|1|L|Enteric culture includes testing for Salmonella, Shigella, Campylobacter, Yersinia, E.coli O157:H7 \T\ other STECs, and Aeromonas|RE^Remark^HL70364^^^^2.5.1 +TXA|1|DIS||201011101818+0215|John Smith|201011030000+0215||201011031346+0215|Chris Rock|Emma Watson||018840|1307506^test|||54302-DEX|AU|R|AV|||||radiology report|string ofCharacters +ORC||||2222 +OBR||||5555 \ No newline at end of file diff --git a/data/SampleData/Hl7v2/OML-O21-01.hl7 b/data/SampleData/Hl7v2/OML-O21-01.hl7 new file mode 100644 index 000000000..4b25a8db6 --- /dev/null +++ b/data/SampleData/Hl7v2/OML-O21-01.hl7 @@ -0,0 +1,18 @@ +MSH|^~\&|ORDApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Aux^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|202110201126+0215|SECURITY|OML^O21^OML_O21|MSG00019|P|2.6|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|||20080825111630+0115|Y|||20050110015014+0315||||||CA^Canada^ISO3166_1|89898989^WPN^Internet +PV1|1|O|LABUnit01^Room01^^GHH|||TraumaCentre^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^^GHH1|0210^ATTEND^AARON^A|0310^REFER^LINDA^C|||||||||03410^ADMIT^LINDA^C||5001^^^AccMgr^VN|||||||||||||||||||||||||202110201126+0215| +IN1|1|BAV^Blue Advantage HMO|Org-12345^^^&2.16.840.1.113883.1.1&ISO^NIIP|Blue Cross Blue Shield of Texas|1979 MILKY WAY^^VERONA^WI^53593^US|Roger^Dann|(555)555-5555^^PH|Grp-12345|BCBS HMO|Tel-12345^^^&2.16.840.1.113883.1.2&ISO^EN|Telstra|19981101|||HMO^health maintenance organization policy|Doe^Rosallie^John^III^Mrs.^Bachelors^R|SPO^Spouse|19750228|3857 Velvet Treasure Terrace^^Midnight^NC^27878^US|||||||||||||||||548851236L|150&USD^DC||||||F^Female|2000 MILKY WAY^^VERONA^WI^53593^US|||||HMO-12345^^^&2.16.840.1.113883.1.3&ISO^NI||||||A +IN2|EI-12345^^^&2.16.840.1.113883.1.4&ISO^EI|425-57-9745|||I^Insurance company|Medicare-12345||||MI-12345||||||||||||||||||||||||en^English|||||||||||||||Richard^Paul|(555)555-1234^^PH|||||||||||MB-12345^^^&2.16.840.1.113883.1.5&ISO^MB||(555)123-1234^^PH|(555)123-5678^^PH||||||||02^Spouse +GT1|1|1516^^^^LN|RADIANT^LUCY^^||1619 SOUTH UNIVERSITY^^MADISON^WI^53703^US|(608)251-7777^^PH^^^|(608)2517777^^PH|20010412|F|P/F|MTH|2245367687|20160101|||EHS GENERIC EMPLOYER|1979 MILKYWAY^^VERONA^WI^53593^US|(608)271-9000^^PH^^^608^2719000|19290207^^^^EI|1||N|||| +AL1|1|FA^Food allergy^HL70127|12345^Peanut Allergy^L|MI^Mild^HL70128|moderate|20210121 +ORC|NW|1101^GHHPlacer|1201^GHHFiller||SC||||202110201126+0215|2304^ENTER^MARY^C|3301^VERIFY^PETER^K|3850^ORDPROVIDER^JONES^A^^^|||202110201200+0215||||||||||||||O| +TQ1|1||Once^^^^1^d&Day&ANS+^^AC^1^hr&Hour&ANS+|||1^d&Day&ANS+|||R|Pain|Fasting Sugar||15^min&minute&ANS+|1 +OBR|1|||57698-3^Lipid panel with direct LDL - Serum or Plasma^LN||202110201200+0215|202110201200+0215|||||||||005454^LAB^ROBIN^B|||||||||S|||||||005454&ROBIN^^^LABUnit01^Room01^^GHH|||| +NTE|1||Urgent|| +CTD|C^Emergency Contact^HL70131|Abbot^Adam^A^III^DR^^L^^^^^^^PHD|1000 Hospital Lane^Ste.123^Ann Arbor ^MI^99999^USA^B^^WA^||^WPN^PH^^^^^^^^^(626)555-1234| +DG1|1||E10.9^Diabetes Mellitus Type 1^I10|Diabetes|20200501123009+0215|F|||||||||1|005454^LAB^ROBIN^B|||20200501133015+0215|DG1002||| +OBX|1|CWE|625-4^Bacteria identified in Stool by Culture^XYZ^^^^2.33^^result1|1|27268008^Salmonella^SCT^^^^20090731^^Salmonella species|beats/min^^ISO|70-80|A^A^HL70078^^^^2.5|||P|||20120301|Org15^ID of producer^CAS|1134^Aly^Zafar^Mahendra^JR^Dr.^MD^^PERSt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|^^^^^^^^Bacterial Culture|EI12.3^NI2^UI2^GUID~^^UI1^ISO|201203140957|BU^Observation site^E5|EI21^OII||State Hygienic Laboratory^L^^^^IA Public Health Lab&2.16.840.1.114222.4.1.10411&ISO^FI^^^16D0648109|State Hygienic Laboratory^UI Research Park -Coralville^Iowa City^IA^52242-5002^USA^B^^19103|MD-25^Atchinson^Christopher^^MD|||||||PAI-1^FAI-1 +OBX|1|RP|1063-7^Serum or Plasma^XYZ^^^^2.33^^result1|1|https://testurl.com^^image^PICT||||||O +NTE|1||No Antibodies Detected||MLEE^ATTEND^AARON^A^^^MD|202010101500+0215| +SPM|1|2012545^2012999999&IA PHIMS Stage&2.16.840.1.114222.4.3.3.5.1.2&ISO|PAI12^FAI12|ASERU^Serum^^FUR^^^^^Blood||STUTM^Stuart transport medium^^PHENOL^Stool^L^20|BCAE|BAP^^HL70488^^^^^^Specimen source site||||40^&lbs||This is a specimen resource|AMB^Ambient Temperature^HL70376~DRY^dry^HL70376||20110103143428-0800^20111103143428-0800|20120301||Y||||AUT^Autolyzed^HL70493^CLOT~HEM|||T-container^ContainerType^ABC|||AI-30^^^IA PHIMS Stage&2.16.840.1.114222&ISO^PI^IA Public Health Lab&2.16.840.1.114222.4.1.10411&ISO|OSI-31^^^IPHIMS Stage&2.16.840.1.114222&GUID^PI^PH Lab&16.840.1.114222.4.1.10411&UUID|ShipID-32^Shipment^SID-32^CLIP +OBX|2|NM|8867-4^Bacteria identified^LN^^^^2.33^^result1|1|27~25||||||I diff --git a/data/SampleData/Hl7v2/OML-O21-02.hl7 b/data/SampleData/Hl7v2/OML-O21-02.hl7 new file mode 100644 index 000000000..bf60c3837 --- /dev/null +++ b/data/SampleData/Hl7v2/OML-O21-02.hl7 @@ -0,0 +1,17 @@ +MSH|^~\&|ORDApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Aux^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|202110201126+0215|SECURITY|ORM^O01^ORM_O01|MSG00018|P|2.6|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +PID|1||PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS||EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M||2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234||1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|||20080825111630+0115|Y|||20050110015014+0315||||||CA^Canada^ISO3166_1|89898989^WPN^Internet +PV1|1|O|LABUnit01^Room01^^GHH|||TraumaCentre^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^^GHH1|0210^ATTEND^AARON^A|0310^REFER^LINDA^C|||||||||03410^ADMIT^LINDA^C||5001^^^AccMgr^VN|||||||||||||||||||||||||202110201126+0215| +ORC|NW|1101^GHHPlacer|1201^GHHFiller||SC||||202110201126+0215|2304^ENTER^MARY^C|3301^VERIFY^PETER^K|3850^ORDPROVIDER^JONES^A^^^|||202110201200+0215||||||||||||||O| +TQ1|1||Once^^^^1^d&Day&ANS+^^AC^1^hr&Hour&ANS+|||1^d&Day&ANS+|||R|Pain|Fasting Sugar||15^min&minute&ANS+|1 +OBR|1|||57698-3^Lipid panel with direct LDL - Serum or Plasma^LN||202110201200+0215|202110201200+0215|||||||||005454^LAB^ROBIN^B|||||||||S|||||||005454&ROBIN^^^LABUnit01^Room01^^GHH|||| +NTE|1||Urgent|| +CTD|C^Emergency Contact^HL70131|Abbot^Adam^A^III^DR^^L^^^^^^^PHD|1000 Hospital Lane^Ste.123^Ann Arbor ^MI^99999^USA^B^^WA^||^WPN^PH^^^^^^^^^(626)555-1234| +DG1|1||E10.9^Diabetes Mellitus Type 1^I10|Diabetes|20200501123009+0215|F|||||||||1|005454^LAB^ROBIN^B|||20200501133015+0215|DG1002||| +OBX|1|CWE|625-4^Bacteria identified in Stool by Culture^XYZ^^^^2.33^^result1|1|27268008^Salmonella^SCT^^^^20090731^^Salmonella species|beats/min^^ISO|70-80|A^A^HL70078^^^^2.5|||P|||20120301|Org15^ID of producer^CAS|1134^Aly^Zafar^Mahendra^JR^Dr.^MD^^PERSt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|^^^^^^^^Bacterial Culture|EI12.3^NI2^UI2^GUID~^^UI1^ISO|201203140957|BU^Observation site^E5|EI21^OII||State Hygienic Laboratory^L^^^^IA Public Health Lab&2.16.840.1.114222.4.1.10411&ISO^FI^^^16D0648109|State Hygienic Laboratory^UI Research Park -Coralville^Iowa City^IA^52242-5002^USA^B^^19103|MD-25^Atchinson^Christopher^^MD|||||||PAI-1^FAI-1 +NTE|1||Submission of serum||MLEE^ATTEND^AARON^A^^^MD|202010101600+0215| +SPM|1|2545^2012999999&IA PHIMS Stage&2.16.840.1.114222.4.3.3.5.1.2&ISO|PAI12^FAI12|ASERU^Serum^^FUR^^^^^Blood||STUTM^Stuart transport medium^^PHENOL^Stool^L^20|BCAE|BAP^^HL70488^^^^^^Specimen source site||||40^&lbs||This is a specimen resource|AMB^Ambient Temperature^HL70376~DRY^dry^HL70376||20110103143428-0800^20111103143428-0800|20120301||Y||||AUT^Autolyzed^HL70493^CLOT~HEM|||T-container^ContainerType^ABC|||AI-30^^^IA PHIMS Stage&2.16.840.1.114222&ISO^PI^IA Public Health Lab&2.16.840.1.114222.4.1.10411&ISO|OSI-31^^^IPHIMS Stage&2.16.840.1.114222&GUID^PI^PH Lab&16.840.1.114222.4.1.10411&UUID|ShipID-32^Shipment^SID-32^CLIP +ORC|NW|2203^GHHPlacer|2301^GHHFiller||SC||1^^^202110201126+0215^^^||202110201126+0215|2304^ENTER^MARY^C|3301^VERIFY^PETER^K|3850^ORDPROVIDER^JONES^A^^^|||202110201300+0215||||||||||||||O| +OBR|1|||24590-2^MR Brain^LN||202110201300+0215|202110201300+0215|||||||||005454^RAD^ROBIN^B|||||||||S||1^^^202110201300+0215^^^||PAI-291^FAI-292|||005454&ROBIN^^^RADUnit02^Room02^^GHH||||||||||||||||||test50 +OBX|1|RP|1063-7^Serum or Plasma^XYZ^^^^2.33^^result1|1|https://testurl.com^^image^PICT||||||O +SPM|1|2012545^2012999999&IA PHIMS Stage&2.16.840.1.114222.4.3.3.5.1.2&ISO|PAI12^FAI12|ASERU^Serum^^FUR^^^^^Blood||STUTM^Stuart transport medium^^PHENOL^Stool^L^20|BCAE|BAP^^HL70488^^^^^^Specimen source site||||40^&lbs||This is a specimen resource|AMB^Ambient Temperature^HL70376~DRY^dry^HL70376||20110103143428-0800^20111103143428-0800|20120301||Y||||AUT^Autolyzed^HL70493^CLOT~HEM|||T-container^ContainerType^ABC|||AI-30^^^IA PHIMS Stage&2.16.840.1.114222&ISO^PI^IA Public Health Lab&2.16.840.1.114222.4.1.10411&ISO|OSI-31^^^IPHIMS Stage&2.16.840.1.114222&GUID^PI^PH Lab&16.840.1.114222.4.1.10411&UUID|ShipID-32^Shipment^SID-32^CLIP +OBX|2|NM|8867-4^Bacteria identified^LN^^^^2.33^^result1|1|27~25||||||I \ No newline at end of file diff --git a/data/SampleData/Hl7v2/ORM-O01-01.hl7 b/data/SampleData/Hl7v2/ORM-O01-01.hl7 new file mode 100644 index 000000000..5c37c00da --- /dev/null +++ b/data/SampleData/Hl7v2/ORM-O01-01.hl7 @@ -0,0 +1,8 @@ +MSH|^~\&|ORDApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Aux^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|202110201126+0215|SECURITY|ORM^O01^ORM_O01|MSG00018|P|2.6|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|||20080825111630+0115|Y|||20050110015014+0315||||||CA^Canada^ISO3166_1|89898989^WPN^Internet +PV1|1|O|RADUnit01^Room01^^GHH|||TraumaCentre^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^^GHH1|0210^ATTEND^AARON^A|0310^REFER^LINDA^C|||||||||03410^ADMIT^LINDA^C||5001^^^AccMgr^VN|||||||||||||||||||||||||202110201200+0215| +AL1|1|EA|P^PENICILLIN^ICDO|MI|CODE16|20210824 +ORC|NW|1101^GHHPlacer|1201^GHHFiller||SC||12&lb^BID&12:30:05^S50^20020315^20030315^^^Annotation text^^^^21||202110201126+0215|2304^ENTER^MARY^C|3301^VERIFY^PETER^K|3850^ORDPROVIDER^JONES^A^^^|||2010201200+0215||||||||||||||O| +OBR|1|||24725-4^CT Head^LN|||202110201200+0215|||||||||005454^RAD^ROBIN^B|||||||||S|||||||005454&ROBIN^^^RADUnit01^Room01^^GHH2|||| +CTD|C^Emergency Contact^HL70131|Doe^Rosallie|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L||^WPN^PH^^^^^^^^^(608)271-9001|O^Office Phone Number^HL70185 +DG1|1||S06.9^TBI(traumatic brain injury^I10|Traumatic brain injury|20200501123009+0215|F|||||||||1|005454^RAD^ROBIN^B|||20200501133015+0215|DG1002||| \ No newline at end of file diff --git a/data/SampleData/Hl7v2/ORM-O01-02.hl7 b/data/SampleData/Hl7v2/ORM-O01-02.hl7 new file mode 100644 index 000000000..92d416838 --- /dev/null +++ b/data/SampleData/Hl7v2/ORM-O01-02.hl7 @@ -0,0 +1,15 @@ +MSH|^~\&|ORDApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Aux^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|202110201126+0215|SECURITY|ORM^O01^ORM_O01|MSG00019|P|2.6|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|||20080825111630+0115|Y|||20050110015014+0315||||||CA^Canada^ISO3166_1|89898989^WPN^Internet +PV1|1|O|RADUnit01^Room01^^GHH|||TraumaCentre^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^^GHH1|0210^ATTEND^AARON^A|0310^REFER^LINDA^C|||||||||03410^ADMIT^LINDA^C||5001^^^AccMgr^VN|||||||||||||||||||||||||202110201200+0215| +IN1|1|BAV^Blue Advantage HMO|Org-12345^^^&2.16.840.1.113883.1.1&ISO^NIIP|Blue Cross Blue Shield of Texas|1979 MILKY WAY^^VERONA^WI^53593^US|Roger^Dann|(555)555-5555^^PH|Grp-12345|BCBS HMO|Tel-12345^^^&2.16.840.1.113883.1.2&ISO^EN|Telstra|19981101|||HMO^health maintenance organization policy|Doe^Rosallie^John^III^Mrs.^Bachelors^R|SPO^Spouse|19750228|3857 Velvet Treasure Terrace^^Midnight^NC^27878^US|||||||||||||||||548851236L|150&USD^DC||||||F^Female|2000 MILKY WAY^^VERONA^WI^53593^US|||||HMO-12345^^^&2.16.840.1.113883.1.3&ISO^NI||||||A +IN2|EI-12345^^^&2.16.840.1.113883.1.4&ISO^EI|425-57-9745|||I^Insurance company|Medicare-12345||||MI-12345||||||||||||||||||||||||en^English|||||||||||||||Richard^Paul|(555)555-1234^^PH|||||||||||MB-12345^^^&2.16.840.1.113883.1.5&ISO^MB||(555)123-1234^^PH|(555)123-5678^^PH||||||||02^Spouse +GT1|1|1516|RADIANT^LUCY^^||1619 SOUTH UNIVERSITY^^MADISON^WI^53703^US|(608)251-7777^^PH^^^|(608)2517777^^PH|20010412|F|P/F|MOT|2245367687|20160101|||EHS GENERIC EMPLOYER|1979 MILKYWAY^^VERONA^WI^53593^US|(608)271-9000^^^^^608^2719000|19290207|1||N|||| +AL1||DA^DrugAllergy^HL7127|XYZallergen|MI^Mild^Hl7128|moderate|20210121| +ORC|NW|1101^GHHPlacer|1201^GHHFiller||SC||1^^^202110201126+0215^^^||202110201126+0215|2304^ENTER^MARY^C|3301^VERIFY^PETER^K|3850^ORDPROVIDER^JONES^A^^^|||202110201200+0215||||||||||||||O| +OBR|1|||24725-4^CT Head^LN||202110201200+0215|202110201200+0215|||||||||005454^RAD^ROBIN^B|||||||||S||1^^^202110201126+0215^^^|||||005454&ROBIN^^^RADUnit01^Room01^^GHH|||| +NTE|1||CT Scan to be done urgent|| +CTD|C^Emergency Contact^HL70131|Abbot^Adam^A^III^DR^^L^^^^^^^PHD|1000 Hospital Lane^Ste.123^Ann Arbor ^MI^99999^USA^B^^WA^||^WPN^PH^^^^^^^^^(626)555-1234| +DG1|1||S06.9^TBI(traumatic brain injury^I10|Traumatic brain injury|20200501123009+0215|F|||||||||1|005454^RAD^ROBIN^B|||20200501133015+0215|DG1002||| +OBX|1|CWE|625-4^Bacteria identified in Stool by Culture^XYZ^^^^2.33^^result1|1|27268008^Salmonella^SCT^^^^20090731^^Salmonella species|beats/min^^ISO|70-80|A^A^HL70078^^^^2.5|||P|||20120301|Org15^ID of producer^CAS|1134^Aly^Zafar^Mahendra^JR^Dr.^MD^^PERSt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|^^^^^^^^Bacterial Culture|EI12.3^NI2^UI2^GUID~^^UI1^ISO|201203140957|BU^Observation site^E5|EI21^OII||State Hygienic Laboratory^L^^^^IA Public Health Lab&2.16.840.1.114222.4.1.10411&ISO^FI^^^16D0648109|State Hygienic Laboratory^UI Research Park -Coralville^Iowa City^IA^52242-5002^USA^B^^19103|MD-25^Atchinson^Christopher^^MD|||||||PAI-1^FAI-1 +OBX|1|RP|1063-7^Serum or Plasma^XYZ^^^^2.33^^result1|1|https://testurl.com^^image^PICT||||||O +NTE|1||No Antibodies Detected||MLEE^ATTEND^AARON^A^^^MD|202010101500+0215| diff --git a/data/SampleData/Hl7v2/ORM-O01-03.hl7 b/data/SampleData/Hl7v2/ORM-O01-03.hl7 new file mode 100644 index 000000000..380797273 --- /dev/null +++ b/data/SampleData/Hl7v2/ORM-O01-03.hl7 @@ -0,0 +1,8 @@ +MSH|^~\&|ORDApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Aux^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|202110201126+0215|SECURITY|ORM^O01^ORM_O01|MSG00018|P|2.6|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|||20080825111630+0115|Y|||20050110015014+0315||||||CA^Canada^ISO3166_1|89898989^WPN^Internet +PV1|1|O|RADUnit01^Room01^^GHH|||TraumaCentre^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^^GHH1|0210^ATTEND^AARON^A|0310^REFER^LINDA^C|||||||||03410^ADMIT^LINDA^C||5001^^^AccMgr^VN|||||||||||||||||||||||||202110201200+0215| +ORC|NW|1101^GHHPlacer|1201^GHHFiller||SC||1^^^202110201126+0215^^^||202110201126+0215|2304^ENTER^MARY^C|3301^VERIFY^PETER^K|3850^ORDPROVIDER^JONES^A^^^|||202110201200+0215||||||||||||||O| +OBR|1|||24725-4^CT Head^LN||202110201200+0215|202110201200+0215|||||||||005454^RAD^ROBIN^B|||||||||S||1^^^202110201126+0215^^^|||||005454&ROBIN^^^RADUnit01^Room01^^GHH|||| +DG1|1||S06.9^TBI(traumatic brain injury^I10|Traumatic brain injury|20200501123009+0215|F|||||||||1|005454^RAD^ROBIN^B|||20200501133015+0215|DG1002||| +ORC|NW|2203^GHHPlacer|2301^GHHFiller||SC||1^^^202110201126+0215^^^||202110201126+0215|2304^ENTER^MARY^C|3301^VERIFY^PETER^K|3850^ORDPROVIDER^JONES^A^^^|||202110201300+0215||||||||||||||O| +OBR|1|||24590-2^MR Brain^LN||202110201300+0215|202110201300+0215|||||||||005454^RAD^ROBIN^B|||||||||S||1^^^202110201300+0215^^^||PAI-291^FAI-292|||005454&ROBIN^^^RADUnit02^Room02^^GHH||| \ No newline at end of file diff --git a/data/SampleData/Hl7v2/ORU-R01-01.hl7 b/data/SampleData/Hl7v2/ORU-R01-01.hl7 new file mode 100644 index 000000000..543f20b43 --- /dev/null +++ b/data/SampleData/Hl7v2/ORU-R01-01.hl7 @@ -0,0 +1,18 @@ +MSH|^~\&|IA PHIMS Stage^2.16.840.1.114222.4.3.3.5.1.2^ISO|IA Public Health Lab^2.16.840.1.114222.4.1.10411^ISO|IA.DOH.IDSS^2.16.840.1.114222.4.3.3.19^ISO|IA DOH^2.16.840.1.114222.4.1.3650^ISO|201203141259-0215||ORU^R01^ORU_R01|2.16.840.1.114222.4.3.3.5.1.2-20120314235954.325|T|2.5.1|||AL|NE|USA||||PHLabReport-Ack^^2.16.840.1.113883.9.10^ISO +SFT|Orion Health^L|2.4.3.52854|Rhapsody|2.4.3.52854||20070725111624 +PID|1||14^^^IA PHIMS Stage&2.16.840.1.114222.4.3.3.5.1.2&ISO^PI^IA Public Health Lab&2.16.840.1.114222.4.1.10411&ISO||Finn^Huckleberry^^^^^L||19630815|M||2106-3^White^CDCREC^^^^04/24/2007~1002-5^American Indian or Alaska Native^CDCREC^^^^04/24/2007|721 SPRING STREET^^GRINNELL^IA^50112^USA^H|||||M^Married^HL70002^^^^2.5.1||||||H^Hispanic or Latino^HL70189^^^^2.5.1 +OBX||RP|8867-4^heartrate^LN||https://testurl.com^^SD^PICT||||||F|||19990702||1111^^Zafar^Mahen^JR^Dr.^MD^^PERLt^B^^^BR|||||EI21obx1^OII||ABC Hospital|A city^Florida^VA^22031^USA| +ORC|NW||986^IA PHIMS Stage^2.16.840.1.114222.4.3.3.5.1.2^ISO|PGN-04|CM|||PAI-8.1^FAI-8.2|202009101700+0215||||||201510101700+0215||||||MISSOURI DEPARTMENT OF HEALTH LABORATORY - MISSOURI DEPARTMENT OF HEALTH LABORATORY^L|307 W MCCARTY ST^^JEFFERSON CITY^MO^65101^USA^B|^WPN^PH^^1^^5555555|St-24, Greenwood^Building2|||||O^Outpatient Facility||PUSI^parent Identifier^AR +OBX||ED|||App5^NS^Octet-stream^Base64| +TXA|1|DIS||201011101818+0215|John Smith|201011030000+0215||201011031346+0215|Chris Rock|Emma Watson||018840|1307506^test|||54302-DEX|AU|R|AV|||||radiology report|string ofCharacters +OBR|1|845439^GHH OE|986^IA PHIMS Stage^2.16.840.1.114222.4.3.3.5.1.2^ISO|625-4^Bacteria identified in Stool by Culture^XYZ^^^^2.33^^Enteric Culture|R|202010101700+0215|200202150730+0215||150^lb&lb&ANSI+|10535^van Beethoven&van^Ludwig^A^III^Dr^PHD^^&MPI.Community Health and Hospitals&L^L^3^M10^MR^& Good Health Hospital.Community Health and Hospitals&L^A||||200202120730+0215|SP15&1.2&L^ACDA^Collection Method^BN&223.3&L|||Placer 1|Placer 2|Filler 1|Filler 2|200203150730+0215||BLB|F||||||444^Reason for study^L^^^^MD|Harry&Raud&Geny&&Mr.&Dr.^^^Poc-32^Room-4^Bed3^Facility-3&1.2&ISO^^^Building-4^FL-2||Richa&&&&Mr.&Md.^^^Poc-34^Rm-4^Bed2^Facility-4&1.22&ISO^^^Building-3^FL-3|35&Samuel^20021111^20021112^Area23||||Collector's comment|||||||PSS-46^Placer service^L|FSS-47^Filler service^L||||||APON-53^4^M11^ORU^MR^University Hospital +NTE|1|L|Enteric culture includes testing for Salmonella, Shigella, Campylobacter, Yersinia, E.coli O157:H7 \T\ other STECs, and Aeromonas|RE^Remark^HL70364^^^^2.5.1 +NTE|1||Allergy to peanuts observed.||9941339108^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|202010101600+0215| +TQ1|1|54^&lbs|ACM&Before Breakfast&HL7xxx^HD^^^12^min^^ACM^120^s|11:30:05~11:45:05|30^s|150^&kg|202110091600-0800|202111091600-0800|A|This is condition text|Please follow the text instructions||2^hr|5 +CTD|C^Emergency Contact^HL70131|Doe^Rosallie|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L||^WPN^PH^^^^^^^^^(608)271-9001|O^Office Phone Number^HL70185 +OBX|1|CWE|625-4^Bacteria identified in Stool by Culture^XYZ^^^^2.33^^result1|1|27268008^Salmonella^SCT^^^^20090731^^Salmonella species|beats/min^^ISO|70-80|A^A^HL70078^^^^2.5|||P|||20120301|Org15^ID of producer^CAS|1134^Aly^Zafar^Mahendra^JR^Dr.^MD^^PERSt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|^^^^^^^^Bacterial Culture|EI12.3^NI2^UI2^GUID~^^UI1^ISO|201203140957|BU^Observation site^E5|EI21^OII||State Hygienic Laboratory^L^^^^IA Public Health Lab&2.16.840.1.114222.4.1.10411&ISO^FI^^^16D0648109|State Hygienic Laboratory^UI Research Park -Coralville^Iowa City^IA^52242-5002^USA^B^^19103|MD-25^Atchinson^Christopher^^MD|||||||PAI-1^FAI-1 +NTE|1||Submission of serum||MLEE^ATTEND^AARON^A^^^MD|202010101600+0215| +NTE|1||No Antibodies Detected||MLEE^ATTEND^AARON^A^^^MD|202010101500+0215| +SPM|1|2012545^2012999999&IA PHIMS Stage&2.16.840.1.114222.4.3.3.5.1.2&ISO|PAI12^FAI12|ASERU^Serum^^FUR^^^^^Blood||STUTM^Stuart transport medium^^PHENOL^Stool^L^20|BCAE|BAP^^HL70488^^^^^^Specimen source site||||40^&lbs||This is a specimen resource|AMB^Ambient Temperature^HL70376~DRY^dry^HL70376||20110103143428-0800^20111103143428-0800|20120301||Y||||AUT^Autolyzed^HL70493^CLOT~HEM|||T-container^ContainerType^ABC|||AI-30^^^IA PHIMS Stage&2.16.840.1.114222&ISO^PI^IA Public Health Lab&2.16.840.1.114222.4.1.10411&ISO|OSI-31^^^IPHIMS Stage&2.16.840.1.114222&GUID^PI^PH Lab&16.840.1.114222.4.1.10411&UUID|ShipID-32^Shipment^SID-32^CLIP +OBX|1|RP|1063-7^Serum or Plasma^XYZ^^^^2.33^^result1|1|https://testurl.com^^image^PICT||||||O +OBX|2|NM|8867-4^Bacteria identified^LN^^^^2.33^^result1|1|27~25||||||I \ No newline at end of file diff --git a/data/SampleData/Hl7v2/SIU-S12-01.hl7 b/data/SampleData/Hl7v2/SIU-S12-01.hl7 new file mode 100644 index 000000000..1d5e3717c --- /dev/null +++ b/data/SampleData/Hl7v2/SIU-S12-01.hl7 @@ -0,0 +1,18 @@ +MSH|^~\&|SCHApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Aux^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|202109141120+0215|SECURITY|SIU^S12^SIU_S12|MSG00012|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SCH|12345|36996||||Add|EMERGENCY|Normal|60|s|2^^2 hours^202010011126+0215^202010091126+0215^R|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9^DENT^COREY^|(610)271-9000^^PH|^^^FACILITY3&1.23&ISO^^^BUILDING2^FLOOR1^^^|||Booked| +TQ1|||||||20210924093000+0215|20210924102000+0215|A +NTE|1||Appointment booked for emergency procedure +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|||20080825111630+0115|Y|||20050110015014+0315||||||CA^Canada^ISO3166_1|89898989^WPN^Internet +PV1|1|O|055^Room01^^GH Clinic^^^|||GENOPD^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^^FACILITY1^^^BUILDING1^^^^|0210^ATTEND^AARON^A|0310^REFER^LINDA^C|||||||||03410^ADMIT^LINDA^C||5001^^^AccMgr^VN|||||||||||||||||||||||||20210115160010+0215| +PV2|||116290004^Acute abdominal pain^SCT||||||||||||||||||||||^^^2^Urgent^HL70217|||||||||||||A +OBX|1|NM|8867-4^Heart rate^LN||72|beats/min^^ISO|60-120||||F|||20210914||1134^Aly^Zafar^Mahendra^JR^Dr.^MD^^PERSt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al~2234^Pauly^Berrie^Raud| +DG1|1||64766004^Ulcerative colitis(disorder)^SCT|Ulcerative Colitis|20210825114025+0420|A|||||||||1|005454^DIAG^ROBIN^B|||20200501133015+0215|DI20^Diagnosis^DTUI^CLIP|A|^^UI^CLIP +RGS|001| +AIS|001|A|76164006^Biopsy of colon (procedure)^SCT^1212^Biopsy|20210924093000+0215|||50|min^Minutes^ISO||Booked|5001^EVIS X12 Video Colonoscope^L|5001^EVIS X12 Video Colonoscope^L +NTE|1||Nursing staff instructions - Patient bowel preparation for the procedure| +NTE|2||Patient instructions - light meal or liquid diet a day before procedure| +AIG|001|A|5001^EVIS X12 Video Colonoscope^L^5002^Video|101^Equipment^L||||20210924093000+0215|||50|min^Minutes^ISO||Booked| +NTE|1||Check if this particular equipment is available|| +AIL|001||055^Room01^^GH Clinic^^^|C^Clinic^HL70305||20210924093000+0215|||50|min^Minutes^ISO||Booked| +NTE|1||Location ready and disinfected before procedure| +AIP|001||1210^GE^Robert^C|010^Gastroenterologist^L||20210924093000+0215|||50|min^Minutes^ISO||Booked| \ No newline at end of file diff --git a/data/SampleData/Hl7v2/SIU-S12-02.hl7 b/data/SampleData/Hl7v2/SIU-S12-02.hl7 new file mode 100644 index 000000000..d474ca680 --- /dev/null +++ b/data/SampleData/Hl7v2/SIU-S12-02.hl7 @@ -0,0 +1,28 @@ +MSH|^~\&|SCHApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Aux^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|202108101130+0215|SECURITY|SIU^S12^SIU_S12|MSG00012|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SCH|12345|36996||||Add|CHECKUP|Normal|70|Min|2^^2 hours^202010011126+0215^202010091126+0215^R|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9^DENT^COREY^|(610)271-9000^^PH|^^^FACILITY3&1.23&ISO^^^BUILDING2^FLOOR1^^^|||Booked +TQ1|||||||202108181130+0215|202108181230+0215|A +NTE|1||Appointment for annual checkup +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|||20080825111630+0115|Y|||20050110015014+0315||||||CA^Canada^ISO3166_1|89898989^WPN^Internet +RGS|1|| +AIS|1||58410-2^CBC Panel-Blood by Automated Count^LN|||||||Booked| +NTE|1||Fasting for Blood sugar before appointment +AIG|1||123^ABC Cell Counter^L|011^Lab Equipment^L|||||||| +NTE|1||Equipment booked for lab test +AIL|1||LabUnit101^Lab Room 01^^GHH Hospital||||||||| +NTE|1||Location available for lab test +AIP|1||400^PB^Tim^G^|019^Phlebotomist^L|||||| +NTE|1||Phlebotomist available for lab test +RGS|2|| +AIS|1||42272-5^XR Chest PA and Lateral^LN|||||||Booked| +NTE|1||Patient Instructions - wear loose comfortable clothes,keep metallic objects away and leave jewellery at home +AIG|1||1001^XYZ X-Ray Machine^L|015^Imaging Equipment^L|||||||| +NTE|1||Equipment booked for imaging +AIL|1||DiagnosticUnit201^Imaging Room 01^^GHH Hospital||||| +NTE|1||Location available for imaging +AIP|1||500^RT^Robert^C|021^Radiology Technician^L|||||| +NTE|1||Radiology Technician available for imaging +RGS|3|| +AIL|1||OPD12^Room 55^^GHH Hospital|||||| +NTE|1||Location available for checkup +AIP|1||600^GP^Linda^R|011^General Practitioner^L|||||| +NTE|1||GP available for checkup \ No newline at end of file diff --git a/data/SampleData/Hl7v2/SIU-S12_1.hl7 b/data/SampleData/Hl7v2/SIU-S12_1.hl7 new file mode 100644 index 000000000..e92444f95 --- /dev/null +++ b/data/SampleData/Hl7v2/SIU-S12_1.hl7 @@ -0,0 +1,32 @@ +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|SIU^S12^SIU_S12|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SCH|12345|36996||||Add|EMERGENCY|Normal|70|Min|2^^2 hours^202010011126+0215^202010091126+0215^R|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9^DENT^COREY^|(610)271-9000^^PH|^^^FACILITY3&1.23&ISO^^^BUILDING2^FLOOR1^^^|||Booked +TQ1|||||||202010041126+0215|202010081126+0215|A +NTE|1||Appointment specific instructions +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet +RGS|1|| +AIS|1||111^Hemogram^L| +NTE|1||Fasting for Blood sugar before appointment +AIG|1||123^Cell Counter^L^^^^|011^Lab Equipment^L|||||||| +NTE|1||Equipment specific Notes1 +AIL|1||4E^136^B^CommunityHospital^^N^^^||||||||| +NTE|1||Location specific notes1 +AIP|1||400^Tim^G^^^^||||||| +NTE|1||Provider specific notes +NTE|2||||| +RGS|2|| +AIS|1||220^Chest X-Ray^L|||||| +AIS|2||215^CT Scan^L|| +NTE|1||Service specific instructions +AIG|1||1001^XYZ X-Ray Machine^L|015^Imaging Equipment^L|||||||| +AIG|2||1010^ABC CT Scan Machine^L|||| +NTE|1||Equipment specific Notes2 +AIL|1||11&X-Ray Room&L||||| +AIL|2||22&CT Scan Room&L|| +NTE|1||Location specific notes2 +AIP|1||500^Robert^C^^^^||||||| +NTE|1||Provider specific notes +RGS|3|| +AIL|1||55&OPD 01&L|||||| +NTE|1||Location specific notes3 +AIP|1||600^Linda^R^^^^||||||| +NTE|1||Provider specific notes \ No newline at end of file diff --git a/data/SampleData/Hl7v2/SIU-S13-01.hl7 b/data/SampleData/Hl7v2/SIU-S13-01.hl7 new file mode 100644 index 000000000..81692e3cb --- /dev/null +++ b/data/SampleData/Hl7v2/SIU-S13-01.hl7 @@ -0,0 +1,14 @@ +MSH|^~\&|SCHApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Aux^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|202109201126+0215|SECURITY|SIU^S13^SIU_S13|MSG00013|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SCH|12345|36996||||Add|EMERGENCY|Normal|60|s|2^^2 hours^202010011126+0215^202010091126+0215^R|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9^DENT^COREY^|(610)271-9000^^PH|^^^FACILITY3&1.23&ISO^^^BUILDING2^FLOOR1^^^|||Booked| +TQ1|||||||20210924093000+0215|20210924102000+0215|A +NTE||The patient cannot make previous appointment scheduled on Sept 20.Apointment rescheduled on Sept 24. +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|||20080825111630+0115|Y|||20050110015014+0315||||||CA^Canada^ISO3166_1|89898989^WPN^Internet +RGS|001| +AIS|001|A|76164006^Biopsy of colon (procedure)^SCT^1212^Biopsy|20210924093000+0215|||50|min^Minutes^ISO||Booked|5001^EVIS X12 Video Colonoscope^L|5001^EVIS X12 Video Colonoscope^L +NTE|1||Nursing staff instructions - Patient bowel preparation for the procedure| +NTE|2||Patient instructions - light meal or liquid diet a day before procedure| +AIG|001|A|5001^EVIS X12 Video Colonoscope^L^5002^Video|101^Equipment^L||||20210924093000+0215|||50|min^Minutes^ISO||Booked| +NTE|1||Check if this particular equipment is available|| +AIL|001||055^Room01^^GH Clinic^^^|C^Clinic^HL70305||20210924093000+0215|||50|min^Minutes^ISO||Booked| +NTE|1||Location ready and disinfected before procedure| +AIP|001||1210^GE^Robert^C|010^Gastroenterologist^L||20210924093000+0215|||50|min^Minutes^ISO||Booked| diff --git a/data/SampleData/Hl7v2/SIU-S13-02.hl7 b/data/SampleData/Hl7v2/SIU-S13-02.hl7 new file mode 100644 index 000000000..98276f9d5 --- /dev/null +++ b/data/SampleData/Hl7v2/SIU-S13-02.hl7 @@ -0,0 +1,28 @@ +MSH|^~\&|SCHApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Aux^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|202108181130+0215|SECURITY|SIU^S13^SIU_S13|MSG00013|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SCH|12345|36996||||Add|CHECKUP|Normal|70|Min|2^^2 hours^202010011126+0215^202010091126+0215^R|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9^DENT^COREY^|(610)271-9000^^PH|^^^FACILITY3&1.23&ISO^^^BUILDING2^FLOOR1^^^|||Booked +TQ1|||||||202108201130+0215|202108201230+0215|A +NTE|1||Appointment rescheduled for annual checkup on Aug 20 instead of Aug 18 as per patient's request. +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|||20080825111630+0115|Y|||20050110015014+0315||||||CA^Canada^ISO3166_1|89898989^WPN^Internet +RGS|1|| +AIS|1||58410-2^CBC Panel-Blood by Automated Count^LN|||||||Booked| +NTE|1||Fasting for Blood sugar before appointment +AIG|1||123^ABC Cell Counter^L|011^Lab Equipment^L|||||||| +NTE|1||Equipment booked for lab test +AIL|1||LabUnit101^Lab Room 01^^GHH Hospital||||||||| +NTE|1||Location available for lab test +AIP|1||400^PB^Tim^G^|019^Phlebotomist^L|||||| +NTE|1||Phlebotomist available for lab test +RGS|2|| +AIS|1||42272-5^XR Chest PA and Lateral^LN|||||||Booked| +NTE|1||Patient Instructions - wear loose comfortable clothes,keep metallic objects away and leave jewellery at home +AIG|1||1001^XYZ X-Ray Machine^L|015^Imaging Equipment^L|||||||| +NTE|1||Equipment booked for imaging +AIL|1||DiagnosticUnit201^Imaging Room 01^^GHH Hospital||||| +NTE|1||Location available for imaging +AIP|1||500^RT^Robert^C|021^Radiology Technician^L|||||| +NTE|1||Radiology Technician available for imaging +RGS|3|| +AIL|1||OPD12^Room 55^^GHH Hospital|||||| +NTE|1||Location available for checkup +AIP|1||600^GP^Linda^R|011^General Practitioner^L|||||| +NTE|1||GP available for checkup \ No newline at end of file diff --git a/data/SampleData/Hl7v2/SIU-S14-01.hl7 b/data/SampleData/Hl7v2/SIU-S14-01.hl7 new file mode 100644 index 000000000..413381df1 --- /dev/null +++ b/data/SampleData/Hl7v2/SIU-S14-01.hl7 @@ -0,0 +1,14 @@ +MSH|^~\&|SCHApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Aux^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|202109201126+0215|SECURITY|SIU^S14^SIU_S14|MSG00014|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SCH|12345|36996||||Add|EMERGENCY|Normal|60|s|2^^2 hours^202010011126+0215^202010091126+0215^R|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9^DENT^COREY^|(610)271-9000^^PH|^^^FACILITY3&1.23&ISO^^^BUILDING2^FLOOR1^^^|||Booked| +TQ1|||||||20210924093000+0215|20210924102000+0215|A +NTE||Appointment modified by filler application for change of location from Room01 to Room02. +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|||20080825111630+0115|Y|||20050110015014+0315||||||CA^Canada^ISO3166_1|89898989^WPN^Internet +RGS|001| +AIS|001|A|76164006^Biopsy of colon (procedure)^SCT^1212^Biopsy|20210924093000+0215|||50|min^Minutes^ISO||Booked|5001^EVIS X12 Video Colonoscope^L|5001^EVIS X12 Video Colonoscope^L +NTE|1||Nursing staff instructions - Patient bowel preparation for the procedure| +NTE|2||Patient instructions - light meal or liquid diet a day before procedure| +AIG|001|A|5001^EVIS X12 Video Colonoscope^L^5002^Video|101^Equipment^L||||20210924093000+0215|||50|min^Minutes^ISO||Booked| +NTE|1||Check if this particular equipment is available|| +AIL|001||055^Room02^^GH Clinic^^^|C^Clinic^HL70305||20210924093000+0215|||50|min^Minutes^ISO||Booked| +NTE|1||Location ready and disinfected before procedure| +AIP|001||1210^GE^Robert^C|010^Gastroenterologist^L||20210924093000+0215|||50|min^Minutes^ISO||Booked| \ No newline at end of file diff --git a/data/SampleData/Hl7v2/SIU-S14-02.hl7 b/data/SampleData/Hl7v2/SIU-S14-02.hl7 new file mode 100644 index 000000000..7d1d909b4 --- /dev/null +++ b/data/SampleData/Hl7v2/SIU-S14-02.hl7 @@ -0,0 +1,28 @@ +MSH|^~\&|SCHApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Aux^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|202108171130+0215|SECURITY|SIU^S14^SIU_S14|MSG00014|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SCH|12345|36996||||Add|CHECKUP|Normal|70|Min|2^^2 hours^202010011126+0215^202010091126+0215^R|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9^DENT^COREY^|(610)271-9000^^PH|^^^FACILITY3&1.23&ISO^^^BUILDING2^FLOOR1^^^|||Booked +TQ1|||||||202108181130+0215|202108181230+0215|A +NTE|1||Appointment for annual checkup modified by filler application for change in location from LabUnit101 to LabUnit102 +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|||20080825111630+0115|Y|||20050110015014+0315||||||CA^Canada^ISO3166_1|89898989^WPN^Internet +RGS|1|| +AIS|1||58410-2^CBC Panel-Blood by Automated Count^LN|||||||Booked| +NTE|1||Fasting for Blood sugar before appointment +AIG|1||123^ABC Cell Counter^L|011^Lab Equipment^L|||||||| +NTE|1||Equipment booked for lab test +AIL|1||LabUnit102^Lab Room 01^^GHH Hospital||||||||| +NTE|1||Location available for lab test +AIP|1||400^PB^Tim^G^|019^Phlebotomist^L|||||| +NTE|1||Phlebotomist available for lab test +RGS|2|| +AIS|1||42272-5^XR Chest PA and Lateral^LN|||||||Booked| +NTE|1||Patient Instructions - wear loose comfortable clothes,keep metallic objects away and leave jewellery at home +AIG|1||1001^XYZ X-Ray Machine^L|015^Imaging Equipment^L|||||||| +NTE|1||Equipment booked for imaging +AIL|1||DiagnosticUnit201^Imaging Room 01^^GHH Hospital||||| +NTE|1||Location available for imaging +AIP|1||500^RT^Robert^C|021^Radiology Technician^L|||||| +NTE|1||Radiology Technician available for imaging +RGS|3|| +AIL|1||OPD12^Room 55^^GHH Hospital|||||| +NTE|1||Location available for checkup +AIP|1||600^GP^Linda^R|011^General Practitioner^L|||||| +NTE|1||GP available for checkup \ No newline at end of file diff --git a/data/SampleData/Hl7v2/SIU-S15-01.hl7 b/data/SampleData/Hl7v2/SIU-S15-01.hl7 new file mode 100644 index 000000000..933350008 --- /dev/null +++ b/data/SampleData/Hl7v2/SIU-S15-01.hl7 @@ -0,0 +1,14 @@ +MSH|^~\&|SCHApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Aux^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|202109231126+0215|SECURITY|SIU^S15^SIU_S15|MSG00015|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SCH|12345|36996||||Add|EMERGENCY|Normal|60|s|2^^2 hours^202010011126+0215^202010091126+0215^R|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9^DENT^COREY^|(610)271-9000^^PH|^^^FACILITY3&1.23&ISO^^^BUILDING2^FLOOR1^^^|||Cancelled| +TQ1|||||||20210924093000+0215|20210924102000+0215|A +NTE||Appointment cancelled. +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|||20080825111630+0115|Y|||20050110015014+0315||||||CA^Canada^ISO3166_1|89898989^WPN^Internet +RGS|001| +AIS|001|A|76164006^Biopsy of colon (procedure)^SCT^1212^Biopsy|20210924093000+0215|||50|min^Minutes^ISO||Cancelled|5001^EVIS X12 Video Colonoscope^L|5001^EVIS X12 Video Colonoscope^L +NTE|1||Nursing staff instructions - Appointment cancelled| +NTE|2||Patient instructions - Appointment cancelled| +AIG|001|A|5001^EVIS X12 Video Colonoscope^L^5002^Video|101^Equipment^L||||20210924093000+0215|||50|min^Minutes^ISO||Cancelled| +NTE|1||Equipment is available for other Practitioner as the appointment is cancelled|| +AIL|001||055^Room01^^GH Clinic^^^|C^Clinic^HL70305||20210924093000+0215|||50|min^Minutes^ISO||Cancelled| +NTE|1||Location available as appointment is cancelled| +AIP|001||1210^GE^Robert^C|010^Gastroenterologist^L||20210924093000+0215|||50|min^Minutes^ISO||Cancelled| \ No newline at end of file diff --git a/data/SampleData/Hl7v2/SIU-S15-02.hl7 b/data/SampleData/Hl7v2/SIU-S15-02.hl7 new file mode 100644 index 000000000..0b6b3adca --- /dev/null +++ b/data/SampleData/Hl7v2/SIU-S15-02.hl7 @@ -0,0 +1,28 @@ +MSH|^~\&|SCHApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Aux^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|202108181030+0215|SECURITY|SIU^S15^SIU_S15|MSG00015|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SCH|12345|36996||||Add|CHECKUP|Normal|70|Min|2^^2 hours^202010011126+0215^202010091126+0215^R|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9^DENT^COREY^|(610)271-9000^^PH|^^^FACILITY3&1.23&ISO^^^BUILDING2^FLOOR1^^^|||Cancelled +TQ1|||||||202108181130+0215|202108181230+0215|A +NTE|1||Appointment for annual checkup cancelled as GP is not available on Aug 18. +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|||20080825111630+0115|Y|||20050110015014+0315||||||CA^Canada^ISO3166_1|89898989^WPN^Internet +RGS|1|| +AIS|1||58410-2^CBC Panel-Blood by Automated Count^LN|||||||| +NTE|1||Fasting for Blood sugar before appointment +AIG|1||123^ABC Cell Counter^L|011^Lab Equipment^L|||||||| +NTE|1||Equipment booked for lab test +AIL|1||LabUnit101^Lab Room 01^^GHH Hospital||||||||| +NTE|1||Location available for lab test +AIP|1||400^PB^Tim^G^|019^Phlebotomist^L|||||| +NTE|1||Phlebotomist available for lab test +RGS|2|| +AIS|1||42272-5^XR Chest PA and Lateral^LN|||||||| +NTE|1||Patient Instructions - wear loose comfortable clothes,keep metallic objects away and leave jewellery at home +AIG|1||1001^XYZ X-Ray Machine^L|015^Imaging Equipment^L|||||||| +NTE|1||Equipment booked for imaging +AIL|1||DiagnosticUnit201^Imaging Room 01^^GHH Hospital||||| +NTE|1||Location available for imaging +AIP|1||500^RT^Robert^C|021^Radiology Technician^L|||||| +NTE|1||Radiology Technician available for imaging +RGS|3|| +AIL|1||OPD12^Room 55^^GHH Hospital|||||| +NTE|1||Location available for checkup +AIP|1||600^GP^Linda^R|011^General Practitioner^L|||||| +NTE|1||GP available for checkup \ No newline at end of file diff --git a/data/SampleData/Hl7v2/SIU-S16-01.hl7 b/data/SampleData/Hl7v2/SIU-S16-01.hl7 new file mode 100644 index 000000000..71b944a9d --- /dev/null +++ b/data/SampleData/Hl7v2/SIU-S16-01.hl7 @@ -0,0 +1,14 @@ +MSH|^~\&|SCHApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Aux^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|SIU^S16^SIU_S16|MSG00016|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SCH|12345|36996||||Add|EMERGENCY|Normal|60|s|2^^2 hours^202010011126+0215^202010091126+0215^R|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9^DENT^COREY^|(610)271-9000^^PH|^^^FACILITY3&1.23&ISO^^^BUILDING2^FLOOR1^^^|||Dc| +TQ1|||||||20210924093000+0215|20210924102000+0215|A +NTE||Appointment discontinued due to equipment malfunction. +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|||20080825111630+0115|Y|||20050110015014+0315||||||CA^Canada^ISO3166_1|89898989^WPN^Internet +RGS|001| +AIS|001|A|76164006^Biopsy of colon (procedure)^SCT^1212^Biopsy|20210924093000+0215|||50|min^Minutes^ISO||Dc|5001^EVIS X12 Video Colonoscope^L|5001^EVIS X12 Video Colonoscope^L +NTE|1||Nursing staff instructions - Appointment discontinued due to equipment malfunction| +NTE|2||Patient instructions - Appointment discontinued due to equipment malfunction| +AIG|001|A|5001^EVIS X12 Video Colonoscope^L^5002^Video|101^Equipment^L||||20210924093000+0215|||50|min^Minutes^ISO||Dc| +NTE|1||Equipment malfunction|| +AIL|001||055^Room01^^GH Clinic^^^|C^Clinic^HL70305||20210924093000+0215|||50|min^Minutes^ISO||Dc| +NTE|1||Location available for next slot as appointment is discontinued| +AIP|001||1210^GE^Robert^C|010^Gastroenterologist^L||20210924093000+0215|||50|min^Minutes^ISO||Dc| \ No newline at end of file diff --git a/data/SampleData/Hl7v2/SIU-S16-02.hl7 b/data/SampleData/Hl7v2/SIU-S16-02.hl7 new file mode 100644 index 000000000..57e82884b --- /dev/null +++ b/data/SampleData/Hl7v2/SIU-S16-02.hl7 @@ -0,0 +1,28 @@ +MSH|^~\&|SCHApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Aux^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|202108101200+0215|SECURITY|SIU^S16^SIU_S16|MSG00016|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SCH|12345|36996||||Add|CHECKUP|Normal|70|Min|2^^2 hours^202010011126+0215^202010091126+0215^R|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9^DENT^COREY^|(610)271-9000^^PH|^^^FACILITY3&1.23&ISO^^^BUILDING2^FLOOR1^^^|||Dc +TQ1|||||||202108181130+0215|202108181230+0215|A +NTE|1||Appointment for annual checkup discontinued due to power failure at the facility. +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|||20080825111630+0115|Y|||20050110015014+0315||||||CA^Canada^ISO3166_1|89898989^WPN^Internet +RGS|1|| +AIS|1||58410-2^CBC Panel-Blood by Automated Count^LN|||||||Dc| +NTE|1||Fasting for Blood sugar before appointment +AIG|1||123^ABC Cell Counter^L|011^Lab Equipment^L|||||||| +NTE|1||Equipment booked for lab test +AIL|1||LabUnit101^Lab Room 01^^GHH Hospital||||||||| +NTE|1||Location available for lab test +AIP|1||400^PB^Tim^G^|019^Phlebotomist^L|||||| +NTE|1||Phlebotomist available for lab test +RGS|2|| +AIS|1||42272-5^XR Chest PA and Lateral^LN|||||||Dc| +NTE|1||Patient Instructions - wear loose comfortable clothes,keep metallic objects away and leave jewellery at home +AIG|1||1001^XYZ X-Ray Machine^L|015^Imaging Equipment^L|||||||| +NTE|1||Equipment booked for imaging +AIL|1||DiagnosticUnit201^Imaging Room 01^^GHH Hospital||||| +NTE|1||Location available for imaging +AIP|1||500^RT^Robert^C|021^Radiology Technician^L|||||| +NTE|1||Radiology Technician available for imaging +RGS|3|| +AIL|1||OPD12^Room 55^^GHH Hospital|||||| +NTE|1||Location available for checkup +AIP|1||600^GP^Linda^R|011^General Practitioner^L|||||| +NTE|1||GP available for checkup \ No newline at end of file diff --git a/data/SampleData/Hl7v2/SIU-S17-01.hl7 b/data/SampleData/Hl7v2/SIU-S17-01.hl7 new file mode 100644 index 000000000..4c842a3be --- /dev/null +++ b/data/SampleData/Hl7v2/SIU-S17-01.hl7 @@ -0,0 +1,14 @@ +MSH|^~\&|SCHApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Aux^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|202109231126+0215|SECURITY|SIU^S17^SIU_S17|MSG00017|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SCH|12345|36996||||Add|EMERGENCY|Normal|60|s|2^^2 hours^202010011126+0215^202010091126+0215^R|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9^DENT^COREY^|(610)271-9000^^PH|^^^FACILITY3&1.23&ISO^^^BUILDING2^FLOOR1^^^|||Deleted| +TQ1|||||||20210924093000+0215|20210924102000+0215|A +NTE||Appointment deleted as it was booked for the wrong patient. +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|||20080825111630+0115|Y|||20050110015014+0315||||||CA^Canada^ISO3166_1|89898989^WPN^Internet +RGS|001| +AIS|001|A|76164006^Biopsy of colon (procedure)^SCT^1212^Biopsy|20210924093000+0215|||50|min^Minutes^ISO||Deleted|5001^EVIS X12 Video Colonoscope^L|5001^EVIS X12 Video Colonoscope^L +NTE|1||Nursing staff instructions - Appointment deleted| +NTE|2||Patient instructions - Appointment deleted| +AIG|001|A|5001^EVIS X12 Video Colonoscope^L^5002^Video|101^Equipment^L||||20210924093000+0215|||50|min^Minutes^ISO||Deleted| +NTE|1||Equipment available|| +AIL|001||055^Room01^^GH Clinic^^^|C^Clinic^HL70305||20210924093000+0215|||50|min^Minutes^ISO||Deleted| +NTE|1||Location available for next slot as appointment is deleted| +AIP|001||1210^GE^Robert^C|010^Gastroenterologist^L||20210924093000+0215|||50|min^Minutes^ISO||Deleted| \ No newline at end of file diff --git a/data/SampleData/Hl7v2/SIU-S17-02.hl7 b/data/SampleData/Hl7v2/SIU-S17-02.hl7 new file mode 100644 index 000000000..fe2d45360 --- /dev/null +++ b/data/SampleData/Hl7v2/SIU-S17-02.hl7 @@ -0,0 +1,28 @@ +MSH|^~\&|SCHApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Aux^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|202108101030+0215|SECURITY|SIU^S17^SIU_S17|MSG00017|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SCH|12345|36996||||Add|CHECKUP|Normal|70|Min|2^^2 hours^202010011126+0215^202010091126+0215^R|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9^DENT^COREY^|(610)271-9000^^PH|^^^FACILITY3&1.23&ISO^^^BUILDING2^FLOOR1^^^|||Deleted +TQ1|||||||202108181130+0215|202108181230+0215|A +NTE|1||Appointment for annual checkup deleted as it was assigned to wrong patient. +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID566^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|||20080825111630+0115|Y|||20050110015014+0315||||||CA^Canada^ISO3166_1|89898989^WPN^Internet +RGS|1|| +AIS|1||58410-2^CBC Panel-Blood by Automated Count^LN|||||||Deleted| +NTE|1||Fasting for Blood sugar before appointment +AIG|1||123^ABC Cell Counter^L|011^Lab Equipment^L|||||||| +NTE|1||Equipment booked for lab test +AIL|1||LabUnit101^Lab Room 01^^GHH Hospital||||||||| +NTE|1||Location available for lab test +AIP|1||400^PB^Tim^G^|019^Phlebotomist^L|||||| +NTE|1||Phlebotomist available for lab test +RGS|2|| +AIS|1||42272-5^XR Chest PA and Lateral^LN|||||||Deleted| +NTE|1||Patient Instructions - wear loose comfortable clothes,keep metallic objects away and leave jewellery at home +AIG|1||1001^XYZ X-Ray Machine^L|015^Imaging Equipment^L|||||||| +NTE|1||Equipment booked for imaging +AIL|1||DiagnosticUnit201^Imaging Room 01^^GHH Hospital||||| +NTE|1||Location available for imaging +AIP|1||500^RT^Robert^C|021^Radiology Technician^L|||||| +NTE|1||Radiology Technician available for imaging +RGS|3|| +AIL|1||OPD12^Room 55^^GHH Hospital|||||| +NTE|1||Location available for checkup +AIP|1||600^GP^Linda^R|011^General Practitioner^L|||||| +NTE|1||GP available for checkup \ No newline at end of file diff --git a/data/SampleData/Hl7v2/SIU-S26-01.hl7 b/data/SampleData/Hl7v2/SIU-S26-01.hl7 new file mode 100644 index 000000000..11dea2840 --- /dev/null +++ b/data/SampleData/Hl7v2/SIU-S26-01.hl7 @@ -0,0 +1,13 @@ +MSH|^~\&|SCHApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Aux^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|202109241000+0215|SECURITY|SIU^S26^SIU_S26|MSG00026|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SCH|12345|36996||||Add|EMERGENCY|Normal|60|s|2^^2 hours^202010011126+0215^202010091126+0215^R|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9^DENT^COREY^|(610)271-9000^^PH|^^^FACILITY3&1.23&ISO^^^BUILDING2^FLOOR1^^^|||Noshow| +TQ1|||||||20210924093000+0215|20210924102000+0215|A +NTE||Patient did not show up for the appointment. +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|||20080825111630+0115|Y|||20050110015014+0315||||||CA^Canada^ISO3166_1|89898989^WPN^Internet +RGS|001| +AIS|001|A|76164006^Biopsy of colon (procedure)^SCT^1212^Biopsy|20210924093000+0215|||50|min^Minutes^ISO||Noshow|5001^EVIS X12 Video Colonoscope^L|5001^EVIS X12 Video Colonoscope^L +NTE|1||Nursing staff instructions - Patient did not show up for the appointment| +AIG|001|A|5001^EVIS X12 Video Colonoscope^L^5002^Video|101^Equipment^L||||20210924093000+0215|||50|min^Minutes^ISO||Noshow| +NTE|1||Equipment available|| +AIL|001||055^Room01^^GH Clinic^^^|C^Clinic^HL70305||20210924093000+0215|||50|min^Minutes^ISO||Noshow| +NTE|1||Location available as patient did not show up| +AIP|001||1210^GE^Robert^C|010^Gastroenterologist^L||20210924093000+0215|||50|min^Minutes^ISO||Noshow| \ No newline at end of file diff --git a/data/SampleData/Hl7v2/SIU-S26-02.hl7 b/data/SampleData/Hl7v2/SIU-S26-02.hl7 new file mode 100644 index 000000000..b007a6a00 --- /dev/null +++ b/data/SampleData/Hl7v2/SIU-S26-02.hl7 @@ -0,0 +1,28 @@ +MSH|^~\&|SCHApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Aux^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|202108181130+0215|SECURITY|SIU^S26^SIU_S26|MSG00026|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SCH|12345|36996||||Add|CHECKUP|Normal|70|Min|2^^2 hours^202010011126+0215^202010091126+0215^R|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9941339109^Smith&Mr.&Smith^Adam^Mellie^Jr^Dr^MD^^NPIID&2.16.840.1.113883.4.6&ISO^L^^^NPI^^^^^^20100115^20200115^GP|(608)271-9000^^PH|115 MAINSTREET^^GOODTOWN^KY^42010^USA^L|^^^FACILITY2^^^BUILDING2^FLOOR2^^^|9^DENT^COREY^|(610)271-9000^^PH|^^^FACILITY3&1.23&ISO^^^BUILDING2^FLOOR1^^^|||Noshow +TQ1|||||||202108181130+0215|202108181230+0215|A +NTE|1||Patient did not show up for the annual checkup +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor ^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|||20080825111630+0115|Y|||20050110015014+0315||||||CA^Canada^ISO3166_1|89898989^WPN^Internet +RGS|1|| +AIS|1||58410-2^CBC Panel-Blood by Automated Count^LN|||||||Noshow| +NTE|1||Lab Staff Instructions - Patient did not show up +AIG|1||123^ABC Cell Counter^L|011^Lab Equipment^L|||||||| +NTE|1||Equipment available for lab test +AIL|1||LabUnit101^Lab Room 01^^GHH Hospital||||||||| +NTE|1||Location available for lab test +AIP|1||400^PB^Tim^G^|019^Phlebotomist^L|||||| +NTE|1||Phlebotomist available for lab test +RGS|2|| +AIS|1||42272-5^XR Chest PA and Lateral^LN|||||||Noshow| +NTE|1||Radiology Staff Instructions - Patient did not show up +AIG|1||1001^XYZ X-Ray Machine^L|015^Imaging Equipment^L|||||||| +NTE|1||Equipment available for imaging +AIL|1||DiagnosticUnit201^Imaging Room 01^^GHH Hospital||||| +NTE|1||Location available for imaging +AIP|1||500^RT^Robert^C|021^Radiology Technician^L|||||| +NTE|1||Radiology Technician available for imaging +RGS|3|| +AIL|1||OPD12^Room 55^^GHH Hospital|||||| +NTE|1||Location available for checkup +AIP|1||600^GP^Linda^R|011^General Practitioner^L|||||| +NTE|1||GP available for next checkup - as previously booked patient did not show up \ No newline at end of file diff --git a/data/SampleData/Hl7v2/SIU_12.hl7 b/data/SampleData/Hl7v2/SIU_12.hl7 new file mode 100644 index 000000000..980da4c9c --- /dev/null +++ b/data/SampleData/Hl7v2/SIU_12.hl7 @@ -0,0 +1,21 @@ +MSH|^~\&|ADTApp|GHHSFacility^2.16.840.1.122848.1.30^ISO|EHRApp^1.Edu^ISO|GHHRFacility^2.16.840.1.1122848.1.32^ISO|198908181126+0215|SECURITY|ADT^A60^ADT_A60|MSG00001|P|2.8|||||USA||en-US|||22 GHH Inc.|23 GHH Inc.|24GHH^2.16.840.1.114884.10.20^ISO|25GHH^2.16.840.1.114884.10.23^ISO +SCH||||||||||||||||||||||||||123-1^name|123-1^name +PID|1|1234567^4^M11^test^MR^University Hospital^19241011^19241012|PATID1234^5^M11^test1&2.16.1&HCD^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS|PATID567^^^test2|EVERYMAN&&&&Aniston^ADAM^A^III^Dr.^MD^D^^^19241012^^^^PF^Addsm~Josh&&&&Bing^^stanley^^^^L^^^^^19241010^19241015|SMITH^Angela^L|198808181126+0215|M|elbert^Son|2106-3^White^HL70005~2028-9^Asian^HL70005|1000&Hospital Lane^Ste. 123^Ann Arbor^MI^99999^USA^M^^&W^^^20000110&20000120^^^^^^^Near Highway|GL|78788788^^CP^5555^^^1111^^^^^2222^20010110^20020110^^^^18~12121212^^CP|7777^^CP~1111^^TDD|ara^^HL70296^eng^English-us^HL70296^v2^v2.1^TextInEnglish|M^Married|AME|4000776^^^AccMgr&2.4&ISO^VN^1^19241011^19241012|PSSN123121234|DLN-123^US^20010123|1212121^^^NTH&rt23&HCD^AND^^19241011^19241012|N^NOT HISPANIC OR LATINO^HL70189|St. Francis Community Hospital of Lower South Side|N|2|US^United States of America^ISO3166_1|Vet123^retired^ART|BT^Bhutan^ISO3166_1|20080825111630+0115|Y|||20050110015014+0315||125097000^Goat^SCT|4880003^Beagle^SCT|||CA^Canada^ISO3166_1|89898989^WPN^Internet +PD1|S^^ACR||LINDAS TEST ORGANIZATION^^SIISCLIENT818|88^Hippo^rold^H^V^Dr^MD^^TE^^^M10^DN^^||||||||||Methodist Church|||20150202^20150202 +PV1|1|P|HUH AE OMU&9.8&ISO^OMU B^Bed 03^HOMERTON UNIVER^^C^Homerton UH^Floor5|E|1234567^4^M11^t&2.16.840.1.113883.19&HCD^ANON^University Hospital^19241011^19241012|4 East, room 136, bed B 4E^136^B^CommunityHospital^^N^^^|1122334^Alaz^Mohammed^Mahi^JR^Dr.^MD^^PERSONNELt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al|C006^Woolfson^Kathleen^^^Dr^^^TEST&23.2&HCD^MSK^^^BA|C008^Condoc^leen^^^Dr^^^&2.8&ISO^NAV^^^BR|SUR|||R|NHS Provider-General (inc.A\T\E-this Hosp)||VIP^Very Important Person^L^IMP^^DCM^v1.1^v1.2^Inportant Person|37^DISNEY^WALT^^^^^^AccMgr^^^^ANC|Inpatient|40007716^^^AccMng&1.2&HCD^AM|||||||||||||||||Admitted as Inpatient^Sample^ACR|22&Homes&FDK|Vegan^Vegetarian|HOMERTON UNIVER||Active|POC^Room-2^Bed-103^^^C^Greenland|Nursing home^^^^^^Rosewood|20150208113419+0110||||||50^^^T123&r2.3&ISO^MR||Othhel^^^^^^^^testing&&HCD||EOC124^5^M11^Etest&2.16.1&HCD^MR^CommunityHospital +PV2|^ROOM1&2.16.840.1.113883.4.642.1.1108&ISO^BED1^FACILITY1^^^BUILDING1^FLOOR1^^^||140004^Chronic pharyngitis^SCT||||||||2|Health Checkup|12188^Hippocrates^Harold^H^IV^Dr^MD^^TE&Provider Master.Community Health and Hospitals&DNS^^^M10^DN^^|||||||||N|||2^^^3^^^V1.2^V1.3|||||||||||||C +OBX|27|NM|8867-4^heartrate^LN||60~120|beats/min^^ISO|70-80|A^A^HL7nnnn~B^B|||S|||19990702|Org15^ID of producer^CAS|1134^Aly^Zafar^Mahendra^JR^Dr.^MD^^PERSt&1.23&HCD^B^^^BR^^^^^^19241010^19241015^Al~2234^Pauly^Berrie^Raud|OBS^This is test method^AS4|EI12.3^NI2^UI2^GUID~^^UI1^ISO|19990702|BU^Observation site^E5|EI21^OII||FairOaks Hspital|Research Park^Fairfax^VA^22031^USA|MD-25^Atchinson^Christopher^^MD|||||||PAI-1^FAI-1 +DG1|1|I9|422504002^Ischemic stroke(disorder)^SCT|Stroke|20040125114025+0420|A|||||||||1|005454^DIAG^ROBIN^B|||20200501133015+0215|DI20^Diagnosis^DTUI^CLIP|A|^^UI^CLIP +RGS|1|| +AIS|1|E|76164006^Biopsy of colon (procedure)^SCT|20210924093000|||50|min^Minutes^ISO||Booked|5001^EVIS X12 Video Colonoscope^L~5001^EVIS X12 Video Colonoscope^L|5001^EVIS X12 Video Colonoscope^L| +NTE|||ABXXYZ||1210^GE^Robert^C^^^^^TEST&23.2&HCD|198908181128+0215| +AIG|1|A|5001^EVIS X12 Video Colonoscope^L|101^Equipment^L||||20210924093000|||50|min^Minutes^ISO||Booked| +NTE|||ABC|||198908181126+0215| +AIL|1||055^Room01^^GH Clinic^^^|C^Clinic^HL70305||20210924093000|||50|min^Minutes^ISO||Booked +NTE|||ABC|| +AIP|1||1210^GE^Robert^C^^^^^TEST&23.2&HCD|010^Gastroenterologist^L||20210924093000|||50|min^Minutes^ISO||Booked| +RGS|2|| +AIS|2|E|76164007^Biopsy of colon (procedure)^SCT|20210924093011|||50|min^Minutes^ISO||Booked|5001^EVIS X12 Video Colonoscope^L~5001^EVIS X12 Video Colonoscope^L|5001^EVIS X12 Video Colonoscope^L| +AIG|2|A|5002^EVIS X12 Video Colonoscope^L|102^Equipment^L||||20210924093000|||50|min^Minutes^ISO||Booked| +AIL|2||056^Room01^^GH Clinic^^^|C^Clinic^HL70305||20210924093000|||50|min^Minutes^ISO||Booked +AIP|2||1211^GE^Robert^C^^^^^TEST&23.2&HCD|010^Gastroenterologist^L||20210924093000|||50|min^Minutes^ISO||Booked| \ No newline at end of file diff --git a/data/Templates/Hl7v2/ADT_A01.liquid b/data/Templates/Hl7v2/ADT_A01.liquid index ab7bedb2d..d93d25b87 100644 --- a/data/Templates/Hl7v2/ADT_A01.liquid +++ b/data/Templates/Hl7v2/ADT_A01.liquid @@ -18,8 +18,9 @@ {% assign accSegmentLists = hl7v2Data | get_segment_lists: 'ACC' -%} {% assign ub1SegmentLists = hl7v2Data | get_segment_lists: 'UB1' -%} {% assign ub2SegmentLists = hl7v2Data | get_segment_lists: 'UB2' -%} -{% assign pdaSegmentLists = hl7v2Data | get_segment_lists: 'PDA' -%} -{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} +{% assign pdaSegmentLists = hl7v2Data | get_segment_lists: 'PDA' -%} +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} + { "resourceType": "Bundle", "type": "batch", @@ -301,7 +302,7 @@ {% include 'Resource/Organization', PV1: firstSegments.PV1.54.4, ID: Organization_ID_PV1_54_4 -%} {% endif -%} {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: firstSegments.PV1.54 -%} - {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId -%} + {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId, Root_Template: 'ADT_A01' -%} {% endif -%} {% evaluate encounterId using 'ID/Encounter' PV1: firstSegments.PV1, baseId: patientId -%} @@ -355,14 +356,8 @@ {% include 'Resource/Practitioner' PR1: pr1Segment.12, ID: practitionerId_PR1_12 -%} {% endif -%} - {% if pr1Segment.23.1 -%} - {% evaluate Location_ID_PR1_23_1 using 'ID/Location' PL: pr1Segment.23.1 -%} - {% include 'Resource/PLLocation' PL_1: pr1Segment.23.1, ID: Location_ID_PR1_23_1-%} - {% else %} - {% if pr1Segment.23.2 %} - {% evaluate Location_ID_PR1_23_2 using 'ID/Location' PL: pr1Segment.23.2 -%} - {% include 'Resource/PLLocation' PL_2: pr1Segment.23.2, ID: Location_ID_PR1_23_2-%} - {% endif %} + {% if pr1Segment.23 -%} + {% include 'Resource/PLLocation' PL: pr1Segment.23-%} {% endif %} {% if pr1Segment.25 -%} @@ -495,7 +490,7 @@ {% include 'Resource/Condition' DG1_22: dg1Segment.22, Condition_Subject_ID_DG1_22: fullPatientId, ID: conditionId_DG1_22 -%} {% endif -%} {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} - + {% endfor -%} {% for rf1Segment in rf1SegmentLists.RF1 -%} diff --git a/data/Templates/Hl7v2/ADT_A02.liquid b/data/Templates/Hl7v2/ADT_A02.liquid index afed1d6d4..d09ffaf9e 100644 --- a/data/Templates/Hl7v2/ADT_A02.liquid +++ b/data/Templates/Hl7v2/ADT_A02.liquid @@ -239,7 +239,7 @@ {% include 'Resource/Organization', PV1: firstSegments.PV1.54.4, ID: Organization_ID_PV1_54_4 -%} {% endif -%} {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: firstSegments.PV1.54 -%} - {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId -%} + {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId, Root_Template: 'ADT_A02' -%} {% endif -%} {% evaluate encounterId using 'ID/Encounter' PV1: firstSegments.PV1, baseId: patientId -%} diff --git a/data/Templates/Hl7v2/ADT_A03.liquid b/data/Templates/Hl7v2/ADT_A03.liquid index a1733a63c..4a0f7ea5a 100644 --- a/data/Templates/Hl7v2/ADT_A03.liquid +++ b/data/Templates/Hl7v2/ADT_A03.liquid @@ -16,8 +16,9 @@ {% assign autSegmentLists = hl7v2Data | get_segment_lists: 'AUT' -%} {% assign rf1SegmentLists = hl7v2Data | get_segment_lists: 'RF1' -%} {% assign accSegmentLists = hl7v2Data | get_segment_lists: 'ACC' -%} -{% assign pdaSegmentLists = hl7v2Data | get_segment_lists: 'PDA' -%} -{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} +{% assign pdaSegmentLists = hl7v2Data | get_segment_lists: 'PDA' -%} +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} + { "resourceType": "Bundle", "type": "batch", @@ -293,7 +294,7 @@ {% include 'Resource/Organization', PV1: firstSegments.PV1.54.4, ID: Organization_ID_PV1_54_4 -%} {% endif -%} {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: firstSegments.PV1.54 -%} - {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId -%} + {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId, Root_Template: 'ADT_A03' -%} {% endif -%} {% evaluate encounterId using 'ID/Encounter' PV1: firstSegments.PV1, baseId: patientId -%} @@ -347,14 +348,8 @@ {% include 'Resource/Practitioner' PR1: pr1Segment.12, ID: practitionerId_PR1_12 -%} {% endif -%} - {% if pr1Segment.23.1 -%} - {% evaluate Location_ID_PR1_23_1 using 'ID/Location' PL: pr1Segment.23.1 -%} - {% include 'Resource/PLLocation' PL_1: pr1Segment.23.1, ID: Location_ID_PR1_23_1-%} - {% else %} - {% if pr1Segment.23.2 %} - {% evaluate Location_ID_PR1_23_2 using 'ID/Location' PL: pr1Segment.23.2 -%} - {% include 'Resource/PLLocation' PL_2: pr1Segment.23.2, ID: Location_ID_PR1_23_2-%} - {% endif %} + {% if pr1Segment.23 -%} + {% include 'Resource/PLLocation' PL: pr1Segment.23-%} {% endif %} {% if pr1Segment.25 -%} @@ -480,8 +475,8 @@ {% evaluate conditionId_DG1_22 using 'ID/Condition' DG1: dg1Segment.22, baseId: patientId -%} {% include 'Resource/Condition' DG1_22: dg1Segment.22, Condition_Subject_ID_DG1_22: fullPatientId, ID: conditionId_DG1_22 -%} {% endif -%} - {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} - + {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} + {% endfor -%} {% for rf1Segment in rf1SegmentLists.RF1 -%} diff --git a/data/Templates/Hl7v2/ADT_A04.liquid b/data/Templates/Hl7v2/ADT_A04.liquid index 1048026cf..f4f623a49 100644 --- a/data/Templates/Hl7v2/ADT_A04.liquid +++ b/data/Templates/Hl7v2/ADT_A04.liquid @@ -18,8 +18,9 @@ {% assign accSegmentLists = hl7v2Data | get_segment_lists: 'ACC' -%} {% assign ub1SegmentLists = hl7v2Data | get_segment_lists: 'UB1' -%} {% assign ub2SegmentLists = hl7v2Data | get_segment_lists: 'UB2' -%} -{% assign pdaSegmentLists = hl7v2Data | get_segment_lists: 'PDA' -%} -{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} +{% assign pdaSegmentLists = hl7v2Data | get_segment_lists: 'PDA' -%} +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} + { "resourceType": "Bundle", "type": "batch", @@ -295,7 +296,7 @@ {% include 'Resource/Organization', PV1: firstSegments.PV1.54.4, ID: Organization_ID_PV1_54_4 -%} {% endif -%} {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: firstSegments.PV1.54 -%} - {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId -%} + {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId, Root_Template: 'ADT_A04' -%} {% endif -%} {% evaluate encounterId using 'ID/Encounter' PV1: firstSegments.PV1, baseId: patientId -%} @@ -349,14 +350,8 @@ {% include 'Resource/Practitioner' PR1: pr1Segment.12, ID: practitionerId_PR1_12 -%} {% endif -%} - {% if pr1Segment.23.1 -%} - {% evaluate Location_ID_PR1_23_1 using 'ID/Location' PL: pr1Segment.23.1 -%} - {% include 'Resource/PLLocation' PL_1: pr1Segment.23.1, ID: Location_ID_PR1_23_1-%} - {% else %} - {% if pr1Segment.23.2 %} - {% evaluate Location_ID_PR1_23_2 using 'ID/Location' PL: pr1Segment.23.2 -%} - {% include 'Resource/PLLocation' PL_2: pr1Segment.23.2, ID: Location_ID_PR1_23_2-%} - {% endif %} + {% if pr1Segment.23 -%} + {% include 'Resource/PLLocation' PL: pr1Segment.23-%} {% endif %} {% if pr1Segment.25 -%} @@ -481,8 +476,8 @@ {% evaluate conditionId_DG1_22 using 'ID/Condition' DG1: dg1Segment.22, baseId: patientId -%} {% include 'Resource/Condition' DG1_22: dg1Segment.22, Condition_Subject_ID_DG1_22: fullPatientId, ID: conditionId_DG1_22 -%} {% endif -%} - {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} - + {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} + {% endfor -%} {% for rf1Segment in rf1SegmentLists.RF1 -%} diff --git a/data/Templates/Hl7v2/ADT_A05.liquid b/data/Templates/Hl7v2/ADT_A05.liquid index 5a6291fca..01c1542a5 100644 --- a/data/Templates/Hl7v2/ADT_A05.liquid +++ b/data/Templates/Hl7v2/ADT_A05.liquid @@ -18,7 +18,7 @@ {% assign accSegmentLists = hl7v2Data | get_segment_lists: 'ACC' -%} {% assign ub1SegmentLists = hl7v2Data | get_segment_lists: 'UB1' -%} {% assign ub2SegmentLists = hl7v2Data | get_segment_lists: 'UB2' -%} -{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} { "resourceType": "Bundle", "type": "batch", @@ -294,7 +294,7 @@ {% include 'Resource/Organization', PV1: firstSegments.PV1.54.4, ID: Organization_ID_PV1_54_4 -%} {% endif -%} {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: firstSegments.PV1.54 -%} - {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId -%} + {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId, Root_Template: 'ADT_A05' -%} {% endif -%} {% evaluate encounterId using 'ID/Encounter' PV1: firstSegments.PV1, baseId: patientId -%} @@ -348,14 +348,8 @@ {% include 'Resource/Practitioner' PR1: pr1Segment.12, ID: practitionerId_PR1_12 -%} {% endif -%} - {% if pr1Segment.23.1 -%} - {% evaluate Location_ID_PR1_23_1 using 'ID/Location' PL: pr1Segment.23.1 -%} - {% include 'Resource/PLLocation' PL_1: pr1Segment.23.1, ID: Location_ID_PR1_23_1-%} - {% else %} - {% if pr1Segment.23.2 %} - {% evaluate Location_ID_PR1_23_2 using 'ID/Location' PL: pr1Segment.23.2 -%} - {% include 'Resource/PLLocation' PL_2: pr1Segment.23.2, ID: Location_ID_PR1_23_2-%} - {% endif %} + {% if pr1Segment.23 -%} + {% include 'Resource/PLLocation' PL: pr1Segment.23-%} {% endif %} {% if pr1Segment.25 -%} @@ -481,8 +475,8 @@ {% evaluate conditionId_DG1_22 using 'ID/Condition' DG1: dg1Segment.22, baseId: patientId -%} {% include 'Resource/Condition' DG1_22: dg1Segment.22, Condition_Subject_ID_DG1_22: fullPatientId, ID: conditionId_DG1_22 -%} {% endif -%} - {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} - + {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} + {% endfor -%} {% for rf1Segment in rf1SegmentLists.RF1 -%} diff --git a/data/Templates/Hl7v2/ADT_A08.liquid b/data/Templates/Hl7v2/ADT_A08.liquid index 17f31f42c..ec606d1be 100644 --- a/data/Templates/Hl7v2/ADT_A08.liquid +++ b/data/Templates/Hl7v2/ADT_A08.liquid @@ -18,9 +18,8 @@ {% assign accSegmentLists = hl7v2Data | get_segment_lists: 'ACC' -%} {% assign ub1SegmentLists = hl7v2Data | get_segment_lists: 'UB1' -%} {% assign ub2SegmentLists = hl7v2Data | get_segment_lists: 'UB2' -%} -{% assign pdaSegmentLists = hl7v2Data | get_segment_lists: 'PDA' -%} -{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} - +{% assign pdaSegmentLists = hl7v2Data | get_segment_lists: 'PDA' -%} +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} { "resourceType": "Bundle", "type": "batch", @@ -349,14 +348,8 @@ {% include 'Resource/Practitioner' PR1: pr1Segment.12, ID: practitionerId_PR1_12 -%} {% endif -%} - {% if pr1Segment.23.1 -%} - {% evaluate Location_ID_PR1_23_1 using 'ID/Location' PL: pr1Segment.23.1 -%} - {% include 'Resource/PLLocation' PL_1: pr1Segment.23.1, ID: Location_ID_PR1_23_1-%} - {% else %} - {% if pr1Segment.23.2 %} - {% evaluate Location_ID_PR1_23_2 using 'ID/Location' PL: pr1Segment.23.2 -%} - {% include 'Resource/PLLocation' PL_2: pr1Segment.23.2, ID: Location_ID_PR1_23_2-%} - {% endif %} + {% if pr1Segment.23 -%} + {% include 'Resource/PLLocation' PL: pr1Segment.23-%} {% endif %} {% if pr1Segment.25 -%} @@ -483,8 +476,8 @@ {% evaluate conditionId_DG1_22 using 'ID/Condition' DG1: dg1Segment.22, baseId: patientId -%} {% include 'Resource/Condition' DG1_22: dg1Segment.22, Condition_Subject_ID_DG1_22: fullPatientId, ID: conditionId_DG1_22 -%} {% endif -%} - {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} - + {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} + {% endfor -%} {% for rf1Segment in rf1SegmentLists.RF1 -%} diff --git a/data/Templates/Hl7v2/ADT_A11.liquid b/data/Templates/Hl7v2/ADT_A11.liquid new file mode 100644 index 000000000..efaf3ee68 --- /dev/null +++ b/data/Templates/Hl7v2/ADT_A11.liquid @@ -0,0 +1,315 @@ +{% assign firstSegments = hl7v2Data | get_first_segments: 'MSH|UAC|EVN|PID|PD1|PV1|PV2' -%} +{% assign sftSegmentLists = hl7v2Data | get_segment_lists: 'SFT' -%} +{% assign db1SegmentLists = hl7v2Data | get_segment_lists: 'DB1' -%} +{% assign obxSegmentLists = hl7v2Data | get_segment_lists: 'OBX' -%} +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} +{ + "resourceType": "Bundle", + "type": "batch", + {% if firstSegments.MSH.7 -%} + "timestamp":"{{ firstSegments.MSH.7.Value | format_as_date_time }}", + {% endif -%} + "identifier": + { + "value":"{{ firstSegments.MSH.10.Value }}", + }, + "id":"{{ bundleID }}", + "entry": [ + {% evaluate patientId using 'ID/Patient' PID: firstSegments.PID, type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% evaluate messageHeaderId using 'ID/MessageHeader' MSH: firstSegments.MSH -%} + + {% if firstSegments.MSH -%} + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, ID: messageHeaderId -%} + {% evaluate provenanceId using 'ID/Provenance' MSH: firstSegments.MSH, baseId: patientId -%} + {% include 'Resource/Provenance' Root_Template: 'ADT_A11', MSH: firstSegments.MSH, REF_BUNDLE: bundleID, ID: provenanceId -%} + + {%- comment -%} + {% assign transformation_val = 'provenance_transformation' %} + {% evaluate provenanceOrganizationId using 'ID/Organization', prov_id: firstSegments.MSH -%} + {% evaluate provenanceTransformationId using 'ID/Provenance_transformation' prov_id: transformation_val -%} + {% include 'Resource/Organization' org_name: 'Microsoft Corporation', ID: provenanceOrganizationId -%} + {% include 'Resource/Provenance_transformation' Root_Template: 'ADT_A11', Provenance_Organization_ID: provenanceOrganizationId, REF_MSH: messageHeaderId, provenanceOrganizationId, ID: provenanceTransformationId -%} + {%- endcomment -%} + {% if firstSegments.MSH.4 -%} + {% if firstSegments.MSH.4.1 != "" and firstSegments.MSH.4.1 != null or firstSegments.MSH.4.2 != "" and firstSegments.MSH.4.2 != null or firstSegments.MSH.4.3 != "" and firstSegments.MSH.4.3 != null -%} + {% evaluate organization_ID_MSH_4 using 'ID/Organization' HD: firstSegments.MSH.4 -%} + {% include 'Resource/Organization' MSHHD1: firstSegments.MSH.4, MSH: firstSegments.MSH, ID: organization_ID_MSH_4 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.6 %} + {% if firstSegments.MSH.6.1 != "" and firstSegments.MSH.6.1 != null or firstSegments.MSH.6.2 != "" and firstSegments.MSH.6.2 != null or firstSegments.MSH.6.3 != "" and firstSegments.MSH.6.3 != null -%} + {% evaluate organization_Id_MSH_6 using 'ID/Organization' HD: firstSegments.MSH.6 -%} + {% include 'Resource/Organization' MSHHD2: firstSegments.MSH.6, MSH: firstSegments.MSH, ID: organization_Id_MSH_6 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.22 %} + {% if firstSegments.MSH.22.1 != "" and firstSegments.MSH.22.1 != null -%} + {% evaluate organization_Id_MSH_22 using 'ID/Organization' XON: firstSegments.MSH.22 -%} + {% include 'Resource/Organization' MSHXON1: firstSegments.MSH.22, ID: organization_Id_MSH_22 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.23 %} + {% if firstSegments.MSH.23.1 != "" and firstSegments.MSH.23.1 != null -%} + {% evaluate organization_Id_MSH_23 using 'ID/Organization' XON: firstSegments.MSH.23 -%} + {% include 'Resource/Organization' MSHXON2: firstSegments.MSH.23, ID: organization_Id_MSH_23 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.3 and firstSegments.MSH.24 %} + {% evaluate device_Id_MSH_3 using 'ID/Device' HD: firstSegments.MSH.3 -%} + {% include 'Resource/Device' MSH: firstSegments.MSH, ID: device_Id_MSH_3 -%} + {% endif -%} + {% endif -%} + + {% for sftSegment in sftSegmentLists.SFT -%} + {% evaluate deviceId_SFT using 'ID/Device' SFT: sftSegment -%} + {% include 'Resource/Device' SFT:sftSegment, ID: deviceId_SFT -%} + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, SFT:sftSegment, ID: messageHeaderID -%} + {% endfor -%} + + {% include 'Resource/Patient' PID: firstSegments.PID, PD1: firstSegments.PD1, ID: patientId -%} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, PID: firstSegments.PID, PD1: firstSegments.PD1, PV1: firstSegments.PV1 -%} + + {% if firstSegments.PID.18 -%} + {% evaluate accountId using 'ID/Account' CX: firstSegments.PID.3 -%} + {% include 'Resource/Account' PID: firstSegments.PID, ID: accountId -%} + {% include 'Reference/Account/Subject' ID: accountId, REF: fullPatientId -%} + {% if firstSegments.PID.18.4.1 != "" and firstSegments.PID.18.4.1 != null and firstSegments.PID.18.4.2 != "" and firstSegments.PID.18.4.2 != null and firstSegments.PID.18.4.3 != "" and firstSegments.PID.18.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_18 using 'ID/Organization' HDORG: firstSegments.PID.18.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.18, ID: Organization_ID_pid_CX_18 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PID.2 -%} + {% if firstSegments.PID.2.4.1 != "" and firstSegments.PID.2.4.1 != null and firstSegments.PID.2.4.2 != "" and firstSegments.PID.2.4.2 != null and firstSegments.PID.2.4.3 != "" and firstSegments.PID.2.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_2 using 'ID/Organization' HDORG: firstSegments.PID.2.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.2, ID: Organization_ID_pid_CX_2 -%} + {% endif -%} + {% endif -%} + {% for pid3 in firstSegments.PID.3.Repeats -%} + {% if pid3.4.1 != "" and pid3.4.1 != null and pid3.4.2 != "" and pid3.4.2 != null and pid3.4.3 != "" and pid3.4.3 != null -%} + {% evaluate Organization_ID_pid_CX using 'ID/Organization' HDORG: pid3.4 -%} + {% include 'Resource/Organization', PID: pid3, ID: Organization_ID_pid_CX -%} + {% endif -%} + {% endfor -%} + {% if firstSegments.PID.4 -%} + {% if firstSegments.PID.4.4.1 != "" and firstSegments.PID.4.4.1 != null and firstSegments.PID.4.4.2 != "" and firstSegments.PID.4.4.2 != null and firstSegments.PID.4.4.3 != "" and firstSegments.PID.4.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_4 using 'ID/Organization' HDORG: firstSegments.PID.4.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.4, ID: Organization_ID_pid_CX_4 -%} + {% endif -%} + {% endif -%} + + {% unless nk1SegmentLists.NK1 -%} + {% if firstSegments.PID.21 -%} + {% if firstSegments.PID.21.4.1 != "" and firstSegments.PID.21.4.1 != null and firstSegments.PID.21.4.2 != "" and firstSegments.PID.21.4.2 != null and firstSegments.PID.21.4.3 != "" and firstSegments.PID.21.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_21 using 'ID/Organization' HDORG: firstSegments.PID.21.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.21, ID: Organization_ID_pid_CX_21 -%} + {% endif -%} + {% evaluate pidrelatedPersonId using 'ID/RelatedPerson' PID: firstSegments.PID, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: pidrelatedPersonId, PID: firstSegments.PID -%} + {% endif -%} + {% endunless -%} + {% if firstSegments.PD1.3 -%} + {% evaluate Organization_ID_PD1_3 using 'ID/Organization' XON: firstSegments.PD1.3 -%} + {% include 'Resource/Organization' PD1: firstSegments.PD1, ID: Organization_ID_PD1_3 -%} + {% endif -%} + + {% if firstSegments.PD1.4 -%} + {% if firstSegments.PD1.4.9.1 != "" and firstSegments.PD1.4.9.1 != null and firstSegments.PD1.4.9.2 != "" and firstSegments.PD1.4.9.2 != null and firstSegments.PD1.4.9.3 != "" and firstSegments.PD1.4.9.3 != null -%} + {% evaluate Organization_ID_PD1_4_9 using 'ID/Organization' HDORG: firstSegments.PD1.4.9 -%} + {% include 'Resource/Organization', PD1_4: firstSegments.PD1.4.9, ID: Organization_ID_PD1_4_9 -%} + {% endif -%} + {% evaluate Practitioner_ID_PD1_4 using 'ID/Practitioner' XCN: firstSegments.PD1.4 -%} + {% include 'Resource/Practitioner' PD1: firstSegments.PD1.4, ID: Practitioner_ID_PD1_4 -%} + {% endif -%} + + {% if firstSegments.PV1 -%} + {% if firstSegments.PV1.5 -%} + {% if firstSegments.PV1.5.4.1 != "" and firstSegments.PV1.5.4.1 != null and firstSegments.PV1.5.4.2 != "" and firstSegments.PV1.5.4.2 != null and firstSegments.PV1.5.4.3 != "" and firstSegments.PV1.5.4.3 != null -%} + {% evaluate Organization_ID_PV1_5_4 using 'ID/Organization' HDORG: firstSegments.PV1.5.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.5.4, ID: Organization_ID_PV1_5_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PV1.19 -%} + {% if firstSegments.PV1.19.4.1 != "" and firstSegments.PV1.19.4.1 != null and firstSegments.PV1.19.4.2 != "" and firstSegments.PV1.19.4.2 != null and firstSegments.PV1.19.4.3 != "" and firstSegments.PV1.19.4.3 != null -%} + {% evaluate Organization_ID_PV1_19_4 using 'ID/Organization' HDORG: firstSegments.PV1.19.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.19.4, ID: Organization_ID_PV1_19_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PV1.7 -%} + {% if firstSegments.PV1.7.9.1 != "" and firstSegments.PV1.7.9.1 != null and firstSegments.PV1.7.9.2 != "" and firstSegments.PV1.7.9.2 != null and firstSegments.PV1.7.9.3 != "" and firstSegments.PV1.7.9.3 != null -%} + {% evaluate Organization_ID_PV1_7_9 using 'ID/Organization' HDORG: firstSegments.PV1.7.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.7.9, ID: Organization_ID_PV1_7_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_7 using 'ID/Practitioner' XCN: firstSegments.PV1.7 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.7, ID: practitionerId_PV1_7 -%} + {% endif -%} + + {% if firstSegments.PV1.8 -%} + {% if firstSegments.PV1.8.9.1 != "" and firstSegments.PV1.8.9.1 != null and firstSegments.PV1.8.9.2 != "" and firstSegments.PV1.8.9.2 != null and firstSegments.PV1.8.9.3 != "" and firstSegments.PV1.8.9.3 != null -%} + {% evaluate Organization_ID_PV1_8_9 using 'ID/Organization' HDORG: firstSegments.PV1.8.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.8.9, ID: Organization_ID_PV1_8_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_8 using 'ID/Practitioner' XCN: firstSegments.PV1.8 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.8, ID: practitionerId_PV1_8 -%} + {% endif -%} + + {% if firstSegments.PV1.9 -%} + {% if firstSegments.PV1.9.9.1 != "" and firstSegments.PV1.9.9.1 != null and firstSegments.PV1.9.9.2 != "" and firstSegments.PV1.9.9.2 != null and firstSegments.PV1.9.9.3 != "" and firstSegments.PV1.9.9.3 != null -%} + {% evaluate Organization_ID_PV1_9_9 using 'ID/Organization' HDORG: firstSegments.PV1.9.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.9.9, ID: Organization_ID_PV1_9_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_9 using 'ID/Practitioner' XCN: firstSegments.PV1.9 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.9, ID: practitionerId_PV1_9 -%} + {% endif -%} + + {% if firstSegments.PV1.17 -%} + {% if firstSegments.PV1.17.9.1 != "" and firstSegments.PV1.17.9.1 != null and firstSegments.PV1.17.9.2 != "" and firstSegments.PV1.17.9.2 != null and firstSegments.PV1.17.9.3 != "" and firstSegments.PV1.17.9.3 != null -%} + {% evaluate Organization_ID_PV1_17_9 using 'ID/Organization' HDORG: firstSegments.PV1.17.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.17.9, ID: Organization_ID_PV1_17_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_17 using 'ID/Practitioner' XCN: firstSegments.PV1.17 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.17, ID: practitionerId_PV1_17 -%} + {% endif -%} + + {% if firstSegments.PV1.50 -%} + {% for p in firstSegments.PV1.50.Repeats -%} + {% if p.4.1 != "" and p.4.1 != null and p.4.2 != "" and p.4.2 != null and p.4.3 != "" and p.4.3 != null -%} + {% evaluate Organization_ID_PV1_50_4 using 'ID/Organization' HDORG: p.4 -%} + {% include 'Resource/Organization', PV1: p.4, ID: Organization_ID_PV1_50_4 -%} + {% endif -%} + {% endfor -%} + {% endif -%} + + {% if firstSegments.PV1.52 -%} + {% if firstSegments.PV1.52.9.1 != "" and firstSegments.PV1.52.9.1 != null and firstSegments.PV1.52.9.2 != "" and firstSegments.PV1.52.9.2 != null and firstSegments.PV1.52.9.3 != "" and firstSegments.PV1.52.9.3 != null -%} + {% evaluate Organization_ID_PV1_52_9 using 'ID/Organization' HDORG: firstSegments.PV1.52.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.52.9, ID: Organization_ID_PV1_52_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_52 using 'ID/Practitioner' XCN: firstSegments.PV1.52 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.52, ID: practitionerId_PV1_52 -%} + {% endif -%} + + {% if firstSegments.PV2.13 -%} + {% if firstSegments.PV2.13.9.1 != "" and firstSegments.PV2.13.9.1 != null and firstSegments.PV2.13.9.2 != "" and firstSegments.PV2.13.9.2 != null and firstSegments.PV2.13.9.3 != "" and firstSegments.PV2.13.9.3 != null -%} + {% evaluate Organization_ID_PV2_13_9 using 'ID/Organization' HDORG: firstSegments.PV2.13.9 -%} + {% include 'Resource/Organization', PV2: firstSegments.PV2.13.9, ID: Organization_ID_PV2_13_9 -%} + {% endif -%} + {% evaluate practitionerId_PV2_13 using 'ID/Practitioner' XCN: firstSegments.PV2.13 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV2.13, ID: practitionerId_PV2_13 -%} + {% endif -%} + + {% if firstSegments.PV1.3 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.3-%} + {% endif -%} + + {% if firstSegments.PV1.6 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.6 -%} + {% endif -%} + + {% if firstSegments.PV1.37 -%} + {% evaluate location_ID_PV1_37 using 'ID/Location' DLD: firstSegments.PV1.37 -%} + {% include 'Resource/Location' PV1: firstSegments.PV1.37, ID: location_ID_PV1_37-%} + {% endif -%} + + {% if firstSegments.PV1.42 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.42-%} + {% endif -%} + + {% if firstSegments.PV1.43 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.43-%} + {% endif -%} + + {% if firstSegments.PV2.1 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV2.1-%} + {% endif -%} + + {% if firstSegments.PV1.54 -%} + {% if firstSegments.PV1.54.4.1 != "" and firstSegments.PV1.54.4.1 != null and firstSegments.PV1.54.4.2 != "" and firstSegments.PV1.54.4.2 != null and firstSegments.PV1.54.4.3 != "" and firstSegments.PV1.54.4.3 != null -%} + {% evaluate Organization_ID_PV1_54_4 using 'ID/Organization' HDORG: firstSegments.PV1.54.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.54.4, ID: Organization_ID_PV1_54_4 -%} + {% endif -%} + {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: firstSegments.PV1.54 -%} + {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId, Root_Template: 'ADT_A11' -%} + {% endif -%} + + {% evaluate encounterId using 'ID/Encounter' PV1: firstSegments.PV1, baseId: patientId -%} + {% include 'Resource/Encounter' Root_Template: 'ADT_A11', PV1: firstSegments.PV1, PV2: firstSegments.PV2, ID: encounterId -%} + {% include 'Reference/Encounter/Subject' ID: encounterId, REF: fullPatientId -%} + {% include 'Extensions/Encounter/EncounterExtension' ID: encounterId, PV1: firstSegments.PV1, PV2: firstSegments.PV2, -%} + {% endif -%} + + {% if firstSegments.EVN -%} + {% evaluate provenanceId using 'ID/Provenance' EVN: firstSegments.EVN, baseId: patientId -%} + {% include 'Resource/Provenance' EVN: firstSegments.EVN, EVNTEXT: firstSegments.MSH.9, REF_BUNDLE: bundleID, ID: provenanceId -%} + {% if firstSegments.EVN.5 -%} + {% if firstSegments.EVN.5.9.1 != "" and firstSegments.EVN.5.9.1 != null and firstSegments.EVN.5.9.2 != "" and firstSegments.EVN.5.9.2 != null and firstSegments.EVN.5.9.3 != "" and firstSegments.EVN.5.9.3 != null -%} + {% evaluate Organization_ID_EVN_5_9 using 'ID/Organization' HDORG: firstSegments.EVN.5.9 -%} + {% include 'Resource/Organization', EVN: firstSegments.EVN.5.9, ID: Organization_ID_EVN_5_9 -%} + {% endif -%} + {% evaluate practitionerId_EVN_5 using 'ID/Practitioner' XCN: firstSegments.EVN.5 -%} + {% include 'Resource/Practitioner' EVN: firstSegments.EVN.5, ID: practitionerId_EVN_5 -%} + {% if firstSegments.EVN.7 -%} + {% evaluate locationId_EVN_7 using 'ID/Location' HD: firstSegments.EVN.7 -%} + {% include 'Resource/Location' EVN: firstSegments.EVN.7, ID: locationId_EVN_7 -%} + {% endif -%} + {% endif -%} + {% endif -%} + + {% for obxSegment in obxSegmentLists.OBX -%} + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16 -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16 -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + {% if obxSegment.18 -%} + {% evaluate deviceId_OBX_18 using 'ID/Device' EI: obxSegment.18.Repeats[0] -%} + {% include 'Resource/Device' EI_OBX18: obxSegment.18, ID: deviceId_OBX_18 -%} + {% endif -%} + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23 -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + {% evaluate observationId using 'ID/Observation' OBX: obxSegment, baseId: patientId -%} + {% include 'Resource/Observation' OBX: obxSegment, Observation_Subject_ID: fullPatientId, ID: observationId -%} + {% include 'Extensions/Observation/ObservationExtension' OBX: obxSegment, ID: observationId %} + {% endfor -%} + + {% for db1Segment in db1SegmentLists.DB1 -%} + {% if db1Segment.2.1.Value == "PT" %} + {% for db in db1Segment.3.Repeats -%} + {% if db.4.1 != "" and db.4.1 != null and db.4.2 != "" and db.4.2 != null and db.4.3 != "" and db.4.3 != null -%} + {% evaluate Organization_ID_DB1_3 using 'ID/Organization' HDORG: db.4 -%} + {% include 'Resource/Organization', DB1: db.4, ID: Organization_ID_DB1_3 -%} + {% endif -%} + {% endfor %} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, DB1: db1Segment -%} + {% endif -%} + {% include 'Resource/Patient' DB1: db1Segment, ID: patientId -%} + {% endfor %} + + ] +} \ No newline at end of file diff --git a/data/Templates/Hl7v2/ADT_A13.liquid b/data/Templates/Hl7v2/ADT_A13.liquid new file mode 100644 index 000000000..3200fc91f --- /dev/null +++ b/data/Templates/Hl7v2/ADT_A13.liquid @@ -0,0 +1,609 @@ +{% assign firstSegments = hl7v2Data | get_first_segments: 'MSH|UAC|EVN|PID|PD1|PV1|PV2|DRG|ACC|UB1|UB2|PDA' -%} +{% assign sftSegmentLists = hl7v2Data | get_segment_lists: 'SFT' -%} +{% assign arvSegmentLists = hl7v2Data | get_segment_lists: 'ARV' -%} +{% assign rolSegmentLists = hl7v2Data | get_segment_lists: 'ROL' -%} +{% assign nk1SegmentLists = hl7v2Data | get_segment_lists: 'NK1' -%} +{% assign db1SegmentLists = hl7v2Data | get_segment_lists: 'DB1' -%} +{% assign obxSegmentLists = hl7v2Data | get_segment_lists: 'OBX' -%} +{% assign al1SegmentLists = hl7v2Data | get_segment_lists: 'AL1' -%} +{% assign dg1SegmentLists = hl7v2Data | get_segment_lists: 'DG1' -%} +{% assign pr1SegmentLists = hl7v2Data | get_segment_lists: 'PR1' -%} +{% assign gt1SegmentLists = hl7v2Data | get_segment_lists: 'GT1' -%} +{% assign in1SegmentLists = hl7v2Data | get_segment_lists: 'IN1' -%} +{% assign in2SegmentLists = hl7v2Data | get_segment_lists: 'IN2' -%} +{% assign in3SegmentLists = hl7v2Data | get_segment_lists: 'IN3' -%} +{% assign autSegmentLists = hl7v2Data | get_segment_lists: 'AUT' -%} +{% assign rf1SegmentLists = hl7v2Data | get_segment_lists: 'RF1' -%} +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} +{ + "resourceType": "Bundle", + "type": "batch", + {% if firstSegments.MSH.7 -%} + "timestamp":"{{ firstSegments.MSH.7.Value | format_as_date_time }}", + {% endif -%} + "identifier": + { + "value":"{{ firstSegments.MSH.10.Value }}", + }, + "id":"{{ bundleID }}", + "entry": [ + {% evaluate patientId using 'ID/Patient' PID: firstSegments.PID, type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% evaluate messageHeaderId using 'ID/MessageHeader' MSH: firstSegments.MSH -%} + + {% if firstSegments.MSH -%} + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, ID: messageHeaderId -%} + {% evaluate provenanceId using 'ID/Provenance' MSH: firstSegments.MSH, baseId: patientId -%} + {% include 'Resource/Provenance' Root_Template: 'ADT_A13', MSH: firstSegments.MSH, REF_BUNDLE: bundleID, ID: provenanceId -%} + + {%- comment -%} + {% assign transformation_val = 'provenance_transformation' %} + {% evaluate provenanceOrganizationId using 'ID/Organization', prov_id: firstSegments.MSH -%} + {% evaluate provenanceTransformationId using 'ID/Provenance_transformation' prov_id: transformation_val -%} + {% include 'Resource/Organization' org_name: 'Microsoft Corporation', ID: provenanceOrganizationId -%} + {% include 'Resource/Provenance_transformation' Root_Template: 'ADT_A13', Provenance_Organization_ID: provenanceOrganizationId, REF_MSH: messageHeaderId, provenanceOrganizationId, ID: provenanceTransformationId -%} + {%- endcomment -%} + {% if firstSegments.MSH.4 -%} + {% if firstSegments.MSH.4.1 != "" and firstSegments.MSH.4.1 != null or firstSegments.MSH.4.2 != "" and firstSegments.MSH.4.2 != null or firstSegments.MSH.4.3 != "" and firstSegments.MSH.4.3 != null -%} + {% evaluate organization_ID_MSH_4 using 'ID/Organization' HD: firstSegments.MSH.4 -%} + {% include 'Resource/Organization' MSHHD1: firstSegments.MSH.4, MSH: firstSegments.MSH, ID: organization_ID_MSH_4 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.6 %} + {% if firstSegments.MSH.6.1 != "" and firstSegments.MSH.6.1 != null or firstSegments.MSH.6.2 != "" and firstSegments.MSH.6.2 != null or firstSegments.MSH.6.3 != "" and firstSegments.MSH.6.3 != null -%} + {% evaluate organization_Id_MSH_6 using 'ID/Organization' HD: firstSegments.MSH.6 -%} + {% include 'Resource/Organization' MSHHD2: firstSegments.MSH.6, MSH: firstSegments.MSH, ID: organization_Id_MSH_6 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.22 %} + {% if firstSegments.MSH.22.1 != "" and firstSegments.MSH.22.1 != null -%} + {% evaluate organization_Id_MSH_22 using 'ID/Organization' XON: firstSegments.MSH.22 -%} + {% include 'Resource/Organization' MSHXON1: firstSegments.MSH.22, ID: organization_Id_MSH_22 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.23 %} + {% if firstSegments.MSH.23.1 != "" and firstSegments.MSH.23.1 != null -%} + {% evaluate organization_Id_MSH_23 using 'ID/Organization' XON: firstSegments.MSH.23 -%} + {% include 'Resource/Organization' MSHXON2: firstSegments.MSH.23, ID: organization_Id_MSH_23 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.3 and firstSegments.MSH.24 %} + {% evaluate device_Id_MSH_3 using 'ID/Device' HD: firstSegments.MSH.3 -%} + {% include 'Resource/Device' MSH: firstSegments.MSH, ID: device_Id_MSH_3 -%} + {% endif -%} + {% endif -%} + + {% for sftSegment in sftSegmentLists.SFT -%} + {% evaluate deviceId_SFT using 'ID/Device' SFT: sftSegment -%} + {% include 'Resource/Device' SFT:sftSegment, ID: deviceId_SFT -%} + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, SFT:sftSegment, ID: messageHeaderID -%} + {% endfor -%} + + {% include 'Resource/Patient' PID: firstSegments.PID, PD1: firstSegments.PD1, ID: patientId -%} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, PID: firstSegments.PID, PD1: firstSegments.PD1, PV1: firstSegments.PV1 -%} + + {% if firstSegments.PID.18 -%} + {% evaluate accountId using 'ID/Account' CX: firstSegments.PID.3 -%} + {% include 'Resource/Account' PID: firstSegments.PID, ID: accountId -%} + {% include 'Reference/Account/Subject' ID: accountId, REF: fullPatientId -%} + {% if firstSegments.PID.18.4.1 != "" and firstSegments.PID.18.4.1 != null and firstSegments.PID.18.4.2 != "" and firstSegments.PID.18.4.2 != null and firstSegments.PID.18.4.3 != "" and firstSegments.PID.18.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_18 using 'ID/Organization' HDORG: firstSegments.PID.18.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.18, ID: Organization_ID_pid_CX_18 -%} + {% endif -%} + + {% for gt1SegmentLists in gt1SegmentLists.GT1 -%} + {% if gt1SegmentLists.11.1.Value == "SEL" -%} + {% include 'Resource/Patient' PID: firstSegments.PID, GT1: gt1SegmentLists, ID: patientId, NK1_PER: nk1SegmentLists.NK1[0] -%} + {% if gt1SegmentLists.2.4.1 != "" and gt1SegmentLists.2.4.1 != null and gt1SegmentLists.2.4.2 != "" and gt1SegmentLists.2.4.2 != null and gt1SegmentLists.2.4.3 != "" and gt1SegmentLists.2.4.3 != null -%} + {% evaluate Organization_ID_gt1_CX_2 using 'ID/Organization' HDORG: gt1SegmentLists.2.4 -%} + {% include 'Resource/Organization', PID: gt1SegmentLists.2, ID: Organization_ID_gt1_CX_2 -%} + {% endif -%} + {% if gt1SegmentLists.19.4.1 != "" and gt1SegmentLists.19.4.1 != null and gt1SegmentLists.19.4.2 != "" and gt1SegmentLists.19.4.2 != null and gt1SegmentLists.19.4.3 != "" and gt1SegmentLists.19.4.3 != null -%} + {% evaluate Organization_ID_gt1_CX_19 using 'ID/Organization' HDORG: gt1SegmentLists.19.4 -%} + {% include 'Resource/Organization', PID: gt1SegmentLists.19, ID: Organization_ID_gt1_CX_19 -%} + {% endif -%} + {% if gt1SegmentLists.29.4.1 != "" and gt1SegmentLists.29.4.1 != null and gt1SegmentLists.29.4.2 != "" and gt1SegmentLists.29.4.2 != null and gt1SegmentLists.29.4.3 != "" and gt1SegmentLists.29.4.3 != null -%} + {% evaluate Organization_ID_gt1_CX_29 using 'ID/Organization' HDORG: gt1SegmentLists.29.4 -%} + {% include 'Resource/Organization', PID: gt1SegmentLists.29, ID: Organization_ID_gt1_CX_29 -%} + {% endif -%} + {% if gt1SegmentLists.51 and nk1SegmentLists.NK1[0].7.1.Value == "E" -%} + {% evaluate Organization_ID_gt1_XON_51 using 'ID/Organization' XON: gt1SegmentLists.51 -%} + {% include 'Resource/Organization', GT1_51: gt1SegmentLists, ID: Organization_ID_gt1_XON_51 -%} + {% assign Organization_GT1_51 = Organization_ID_gt1_XON_51 | prepend: 'Organization/' -%} + {% include 'Reference/Patient/Contact_Organization' REF:Organization_GT1_51 , ID: patientId -%} + {% endif -%} + {% else -%} + {% evaluate gt1relatedPersonId using 'ID/RelatedPerson' GT1: gt1SegmentLists, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: gt1relatedPersonId, GT1: gt1SegmentLists -%} + {% if gt1SegmentLists.2.4.1 != "" and gt1SegmentLists.2.4.1 != null and gt1SegmentLists.2.4.2 != "" and gt1SegmentLists.2.4.2 != null and gt1SegmentLists.2.4.3 != "" and gt1SegmentLists.2.4.3 != null -%} + {% evaluate Organization_ID_gt1_CX_2 using 'ID/Organization' HDORG: gt1SegmentLists.2.4 -%} + {% include 'Resource/Organization', PID: gt1SegmentLists.2, ID: Organization_ID_gt1_CX_2 -%} + {% endif -%} + {% if gt1SegmentLists.19.4.1 != "" and gt1SegmentLists.19.4.1 != null and gt1SegmentLists.19.4.2 != "" and gt1SegmentLists.19.4.2 != null and gt1SegmentLists.19.4.3 != "" and gt1SegmentLists.19.4.3 != null -%} + {% evaluate Organization_ID_gt1_CX_19 using 'ID/Organization' HDORG: gt1SegmentLists.19.4 -%} + {% include 'Resource/Organization', PID: gt1SegmentLists.19, ID: Organization_ID_gt1_CX_19 -%} + {% endif -%} + {% endif -%} + {% if gt1SegmentLists.21 -%} + {% evaluate Organization_ID_gt1_XON_21 using 'ID/Organization' XON: gt1SegmentLists.21 -%} + {% include 'Resource/Organization', GT1: gt1SegmentLists, ID: Organization_ID_gt1_XON_21 -%} + {% if gt1SegmentLists.2.4.1 != "" and gt1SegmentLists.2.4.1 != null and gt1SegmentLists.2.4.2 != "" and gt1SegmentLists.2.4.2 != null and gt1SegmentLists.2.4.3 != "" and gt1SegmentLists.2.4.3 != null -%} + {% evaluate Organization_ID_gt1_CX_2 using 'ID/Organization' HDORG: gt1SegmentLists.2.4 -%} + {% include 'Resource/Organization', PID: gt1SegmentLists.2, ID: Organization_ID_gt1_CX_2 -%} + {% endif -%} + {% endif -%} + {% include 'Resource/Account' GT1: gt1SegmentLists, ID: accountId, REF_PATIENT: fullPatientId, REF_RELATED_PERSON: gt1relatedPersonId, REF_ORG: Organization_ID_gt1_XON_21 -%} + {% endfor -%} + + {% endif -%} + + {% if firstSegments.PID.2 -%} + {% if firstSegments.PID.2.4.1 != "" and firstSegments.PID.2.4.1 != null and firstSegments.PID.2.4.2 != "" and firstSegments.PID.2.4.2 != null and firstSegments.PID.2.4.3 != "" and firstSegments.PID.2.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_2 using 'ID/Organization' HDORG: firstSegments.PID.2.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.2, ID: Organization_ID_pid_CX_2 -%} + {% endif -%} + {% endif -%} + {% for pid3 in firstSegments.PID.3.Repeats -%} + {% if pid3.4.1 != "" and pid3.4.1 != null and pid3.4.2 != "" and pid3.4.2 != null and pid3.4.3 != "" and pid3.4.3 != null -%} + {% evaluate Organization_ID_pid_CX using 'ID/Organization' HDORG: pid3.4 -%} + {% include 'Resource/Organization', PID: pid3, ID: Organization_ID_pid_CX -%} + {% endif -%} + {% endfor -%} + {% if firstSegments.PID.4 -%} + {% if firstSegments.PID.4.4.1 != "" and firstSegments.PID.4.4.1 != null and firstSegments.PID.4.4.2 != "" and firstSegments.PID.4.4.2 != null and firstSegments.PID.4.4.3 != "" and firstSegments.PID.4.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_4 using 'ID/Organization' HDORG: firstSegments.PID.4.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.4, ID: Organization_ID_pid_CX_4 -%} + {% endif -%} + {% endif -%} + + {% unless nk1SegmentLists.NK1 -%} + {% if firstSegments.PID.21 -%} + {% if firstSegments.PID.21.4.1 != "" and firstSegments.PID.21.4.1 != null and firstSegments.PID.21.4.2 != "" and firstSegments.PID.21.4.2 != null and firstSegments.PID.21.4.3 != "" and firstSegments.PID.21.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_21 using 'ID/Organization' HDORG: firstSegments.PID.21.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.21, ID: Organization_ID_pid_CX_21 -%} + {% endif -%} + {% evaluate pidrelatedPersonId using 'ID/RelatedPerson' PID: firstSegments.PID, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: pidrelatedPersonId, PID: firstSegments.PID -%} + {% endif -%} + {% endunless -%} + {% if firstSegments.PD1.3 -%} + {% evaluate Organization_ID_PD1_3 using 'ID/Organization' XON: firstSegments.PD1.3 -%} + {% include 'Resource/Organization' PD1: firstSegments.PD1, ID: Organization_ID_PD1_3 -%} + {% endif -%} + + {% if firstSegments.PD1.4 -%} + {% if firstSegments.PD1.4.9.1 != "" and firstSegments.PD1.4.9.1 != null and firstSegments.PD1.4.9.2 != "" and firstSegments.PD1.4.9.2 != null and firstSegments.PD1.4.9.3 != "" and firstSegments.PD1.4.9.3 != null -%} + {% evaluate Organization_ID_PD1_4_9 using 'ID/Organization' HDORG: firstSegments.PD1.4.9 -%} + {% include 'Resource/Organization', PD1_4: firstSegments.PD1.4.9, ID: Organization_ID_PD1_4_9 -%} + {% endif -%} + {% evaluate Practitioner_ID_PD1_4 using 'ID/Practitioner' XCN: firstSegments.PD1.4 -%} + {% include 'Resource/Practitioner' PD1: firstSegments.PD1.4, ID: Practitioner_ID_PD1_4 -%} + {% endif -%} + + {% if firstSegments.PV1 -%} + {% if firstSegments.PV1.5 -%} + {% if firstSegments.PV1.5.4.1 != "" and firstSegments.PV1.5.4.1 != null and firstSegments.PV1.5.4.2 != "" and firstSegments.PV1.5.4.2 != null and firstSegments.PV1.5.4.3 != "" and firstSegments.PV1.5.4.3 != null -%} + {% evaluate Organization_ID_PV1_5_4 using 'ID/Organization' HDORG: firstSegments.PV1.5.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.5.4, ID: Organization_ID_PV1_5_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PV1.19 -%} + {% if firstSegments.PV1.19.4.1 != "" and firstSegments.PV1.19.4.1 != null and firstSegments.PV1.19.4.2 != "" and firstSegments.PV1.19.4.2 != null and firstSegments.PV1.19.4.3 != "" and firstSegments.PV1.19.4.3 != null -%} + {% evaluate Organization_ID_PV1_19_4 using 'ID/Organization' HDORG: firstSegments.PV1.19.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.19.4, ID: Organization_ID_PV1_19_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PV1.7 -%} + {% if firstSegments.PV1.7.9.1 != "" and firstSegments.PV1.7.9.1 != null and firstSegments.PV1.7.9.2 != "" and firstSegments.PV1.7.9.2 != null and firstSegments.PV1.7.9.3 != "" and firstSegments.PV1.7.9.3 != null -%} + {% evaluate Organization_ID_PV1_7_9 using 'ID/Organization' HDORG: firstSegments.PV1.7.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.7.9, ID: Organization_ID_PV1_7_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_7 using 'ID/Practitioner' XCN: firstSegments.PV1.7 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.7, ID: practitionerId_PV1_7 -%} + {% endif -%} + + {% if firstSegments.PV1.8 -%} + {% if firstSegments.PV1.8.9.1 != "" and firstSegments.PV1.8.9.1 != null and firstSegments.PV1.8.9.2 != "" and firstSegments.PV1.8.9.2 != null and firstSegments.PV1.8.9.3 != "" and firstSegments.PV1.8.9.3 != null -%} + {% evaluate Organization_ID_PV1_8_9 using 'ID/Organization' HDORG: firstSegments.PV1.8.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.8.9, ID: Organization_ID_PV1_8_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_8 using 'ID/Practitioner' XCN: firstSegments.PV1.8 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.8, ID: practitionerId_PV1_8 -%} + {% endif -%} + + {% if firstSegments.PV1.9 -%} + {% if firstSegments.PV1.9.9.1 != "" and firstSegments.PV1.9.9.1 != null and firstSegments.PV1.9.9.2 != "" and firstSegments.PV1.9.9.2 != null and firstSegments.PV1.9.9.3 != "" and firstSegments.PV1.9.9.3 != null -%} + {% evaluate Organization_ID_PV1_9_9 using 'ID/Organization' HDORG: firstSegments.PV1.9.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.9.9, ID: Organization_ID_PV1_9_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_9 using 'ID/Practitioner' XCN: firstSegments.PV1.9 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.9, ID: practitionerId_PV1_9 -%} + {% endif -%} + + {% if firstSegments.PV1.17 -%} + {% if firstSegments.PV1.17.9.1 != "" and firstSegments.PV1.17.9.1 != null and firstSegments.PV1.17.9.2 != "" and firstSegments.PV1.17.9.2 != null and firstSegments.PV1.17.9.3 != "" and firstSegments.PV1.17.9.3 != null -%} + {% evaluate Organization_ID_PV1_17_9 using 'ID/Organization' HDORG: firstSegments.PV1.17.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.17.9, ID: Organization_ID_PV1_17_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_17 using 'ID/Practitioner' XCN: firstSegments.PV1.17 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.17, ID: practitionerId_PV1_17 -%} + {% endif -%} + + {% if firstSegments.PV1.50 -%} + {% for p in firstSegments.PV1.50.Repeats -%} + {% if p.4.1 != "" and p.4.1 != null and p.4.2 != "" and p.4.2 != null and p.4.3 != "" and p.4.3 != null -%} + {% evaluate Organization_ID_PV1_50_4 using 'ID/Organization' HDORG: p.4 -%} + {% include 'Resource/Organization', PV1: p.4, ID: Organization_ID_PV1_50_4 -%} + {% endif -%} + {% endfor -%} + {% endif -%} + + {% if firstSegments.PV1.52 -%} + {% if firstSegments.PV1.52.9.1 != "" and firstSegments.PV1.52.9.1 != null and firstSegments.PV1.52.9.2 != "" and firstSegments.PV1.52.9.2 != null and firstSegments.PV1.52.9.3 != "" and firstSegments.PV1.52.9.3 != null -%} + {% evaluate Organization_ID_PV1_52_9 using 'ID/Organization' HDORG: firstSegments.PV1.52.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.52.9, ID: Organization_ID_PV1_52_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_52 using 'ID/Practitioner' XCN: firstSegments.PV1.52 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.52, ID: practitionerId_PV1_52 -%} + {% endif -%} + + {% if firstSegments.PV2.13 -%} + {% if firstSegments.PV2.13.9.1 != "" and firstSegments.PV2.13.9.1 != null and firstSegments.PV2.13.9.2 != "" and firstSegments.PV2.13.9.2 != null and firstSegments.PV2.13.9.3 != "" and firstSegments.PV2.13.9.3 != null -%} + {% evaluate Organization_ID_PV2_13_9 using 'ID/Organization' HDORG: firstSegments.PV2.13.9 -%} + {% include 'Resource/Organization', PV2: firstSegments.PV2.13.9, ID: Organization_ID_PV2_13_9 -%} + {% endif -%} + {% evaluate practitionerId_PV2_13 using 'ID/Practitioner' XCN: firstSegments.PV2.13 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV2.13, ID: practitionerId_PV2_13 -%} + {% endif -%} + + {% if firstSegments.PV1.3 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.3-%} + {% endif -%} + + {% if firstSegments.PV1.6 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.6 -%} + {% endif -%} + + {% if firstSegments.PV1.37 -%} + {% evaluate location_ID_PV1_37 using 'ID/Location' DLD: firstSegments.PV1.37 -%} + {% include 'Resource/Location' PV1: firstSegments.PV1.37, ID: location_ID_PV1_37-%} + {% endif -%} + + {% if firstSegments.PV1.42 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.42-%} + {% endif -%} + + {% if firstSegments.PV1.43 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.43-%} + {% endif -%} + + {% if firstSegments.PV2.1 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV2.1-%} + {% endif -%} + + {% if firstSegments.PV1.54 -%} + {% if firstSegments.PV1.54.4.1 != "" and firstSegments.PV1.54.4.1 != null and firstSegments.PV1.54.4.2 != "" and firstSegments.PV1.54.4.2 != null and firstSegments.PV1.54.4.3 != "" and firstSegments.PV1.54.4.3 != null -%} + {% evaluate Organization_ID_PV1_54_4 using 'ID/Organization' HDORG: firstSegments.PV1.54.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.54.4, ID: Organization_ID_PV1_54_4 -%} + {% endif -%} + {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: firstSegments.PV1.54 -%} + {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId, Root_Template: 'ADT_A13' -%} + {% endif -%} + + {% evaluate encounterId using 'ID/Encounter' PV1: firstSegments.PV1, baseId: patientId -%} + {% include 'Resource/Encounter' Root_Template: 'ADT_A13', PV1: firstSegments.PV1, PV2: firstSegments.PV2, ID: encounterId -%} + {% include 'Reference/Encounter/Subject' ID: encounterId, REF: fullPatientId -%} + {% include 'Extensions/Encounter/EncounterExtension' ID: encounterId, PV1: firstSegments.PV1, PV2: firstSegments.PV2, -%} + {% endif -%} + + {% if firstSegments.EVN -%} + {% evaluate provenanceId using 'ID/Provenance' EVN: firstSegments.EVN, baseId: patientId -%} + {% include 'Resource/Provenance' EVN: firstSegments.EVN, EVNTEXT: firstSegments.MSH.9, REF_BUNDLE: bundleID, ID: provenanceId -%} + {% if firstSegments.EVN.5 -%} + {% if firstSegments.EVN.5.9.1 != "" and firstSegments.EVN.5.9.1 != null and firstSegments.EVN.5.9.2 != "" and firstSegments.EVN.5.9.2 != null and firstSegments.EVN.5.9.3 != "" and firstSegments.EVN.5.9.3 != null -%} + {% evaluate Organization_ID_EVN_5_9 using 'ID/Organization' HDORG: firstSegments.EVN.5.9 -%} + {% include 'Resource/Organization', EVN: firstSegments.EVN.5.9, ID: Organization_ID_EVN_5_9 -%} + {% endif -%} + {% evaluate practitionerId_EVN_5 using 'ID/Practitioner' XCN: firstSegments.EVN.5 -%} + {% include 'Resource/Practitioner' EVN: firstSegments.EVN.5, ID: practitionerId_EVN_5 -%} + {% if firstSegments.EVN.7 -%} + {% evaluate locationId_EVN_7 using 'ID/Location' HD: firstSegments.EVN.7 -%} + {% include 'Resource/Location' EVN: firstSegments.EVN.7, ID: locationId_EVN_7 -%} + {% endif -%} + {% endif -%} + {% endif -%} + + {% for pr1Segment in pr1SegmentLists.PR1 -%} + {% if pr1Segment.8 -%} + {% if pr1Segment.8.9.1 != "" and pr1Segment.8.9.1 != null and pr1Segment.8.9.2 != "" and pr1Segment.8.9.2 != null and pr1Segment.8.9.3 != "" and pr1Segment.8.9.3 != null -%} + {% evaluate Organization_ID_PR1_8 using 'ID/Organization' HDORG: pr1Segment.8.9 -%} + {% include 'Resource/Organization', PR1: pr1Segment.8.9, ID: Organization_ID_PR1_8 -%} + {% endif -%} + {% evaluate practitionerId_PR1_8 using 'ID/Practitioner' XCN: pr1Segment.8 -%} + {% include 'Resource/Practitioner' PR1: pr1Segment.8, ID: practitionerId_PR1_8 -%} + {% endif -%} + + {% if pr1Segment.11 -%} + {% if pr1Segment.11.9.1 != "" and pr1Segment.11.9.1 != null and pr1Segment.11.9.2 != "" and pr1Segment.11.9.2 != null and pr1Segment.11.9.3 != "" and pr1Segment.11.9.3 != null -%} + {% evaluate Organization_ID_PR1_11 using 'ID/Organization' HDORG: pr1Segment.11.9 -%} + {% include 'Resource/Organization', PR1: pr1Segment.11.9, ID: Organization_ID_PR1_11 -%} + {% endif -%} + {% evaluate practitionerId_PR1_11 using 'ID/Practitioner' XCN: pr1Segment.11 -%} + {% include 'Resource/Practitioner' PR1: pr1Segment.11, ID: practitionerId_PR1_11 -%} + {% endif -%} + + {% if pr1Segment.12 -%} + {% if pr1Segment.12.9.1 != "" and pr1Segment.12.9.1 != null and pr1Segment.12.9.2 != "" and pr1Segment.12.9.2 != null and pr1Segment.12.9.3 != "" and pr1Segment.12.9.3 != null -%} + {% evaluate Organization_ID_PR1_12 using 'ID/Organization' HDORG: pr1Segment.12.9 -%} + {% include 'Resource/Organization', PR1: pr1Segment.12.9, ID: Organization_ID_PR1_12 -%} + {% endif -%} + {% evaluate practitionerId_PR1_12 using 'ID/Practitioner' XCN: pr1Segment.12 -%} + {% include 'Resource/Practitioner' PR1: pr1Segment.12, ID: practitionerId_PR1_12 -%} + {% endif -%} + + {% if pr1Segment.23 -%} + {% include 'Resource/PLLocation' PL: pr1Segment.23-%} + {% endif %} + + {% if pr1Segment.25 -%} + {% evaluate Procedure_ID_PR1_25 using 'ID/Procedure' PR1: pr1Segment.25, baseId: fullPatientId -%} + {% include 'Resource/Procedure' PR1_25: pr1Segment.25, PV1: firstSegments.PV1, Procedure_Subject_ID: fullPatientId, ID: Procedure_ID_PR1_25 -%} + {% endif -%} + + {% evaluate procedureId using 'ID/Procedure' PR1: pr1Segment, baseId: patientId -%} + {% include 'Resource/Procedure' PR1: pr1Segment, PV1: firstSegments.PV1, Procedure_Subject_ID: fullPatientId, ID: procedureId -%} + {% endfor -%} + + {% for nk1Segment in nk1SegmentLists.NK1 -%} + {% evaluate relatedPersonId using 'ID/RelatedPerson' NK1: nk1Segment, baseId: patientId -%} + {% if nk1Segment.13 -%} + {% evaluate organizationId_NK1_13 using 'ID/Organization' XON: nk1Segment.13 -%} + {% include 'Resource/Organization' NK1: nk1Segment, ID: organizationId_NK1_13 -%} + {% assign Organization_NK1_13 = organizationId_NK1_13 | prepend: 'Organization/' -%} + {% include 'Reference/Patient/Contact_Organization' REF:Organization_NK1_13 , ID: patientId -%} + {% endif -%} + {% unless nk1Segment.3.1.Value == "EMR" or nk1Segment.3.1.Value == "CGV" or nk1Segment.7.1.Value == "E" or nk1Segment.7.1.Value =="F" or nk1Segment.7.1.Value == "I" or nk1Segment.7.1.Value =="S" -%} + {% include 'Resource/Patient' NK1: nk1Segment, ID: patientId -%} + {% include 'Resource/RelatedPerson' NK1: nk1Segment, RelatedPerson_Patient_ID: fullPatientId, ID: relatedPersonId, PID: firstSegments.PID -%} + {% include 'Extensions/RelatedPerson/RelatedPerson' ID: relatedPersonId, NK1: nk1Segment -%} + {% if nk1Segment.12.4.1 != "" and nk1Segment.12.4.1 != null and nk1Segment.12.4.2 != "" and nk1Segment.12.4.2 != null and nk1Segment.12.4.3 != "" and nk1Segment.12.4.3 != null -%} + {% evaluate Organization_ID_nk_CX_12 using 'ID/Organization' HDORG: nk1Segment.12.4 -%} + {% include 'Resource/Organization', NK1_12: nk1Segment.12, ID: Organization_ID_nk_CX_12 -%} + {% endif -%} + {% endunless -%} + {% if firstSegments.PID.21 -%} + {% include 'Resource/RelatedPerson' ID: relatedPersonId, PID: firstSegments.PID, RelatedPerson_Patient_ID: fullPatientId -%} + {% if firstSegments.PID.21.4.1 != "" and firstSegments.PID.21.4.1 != null and firstSegments.PID.21.4.2 != "" and firstSegments.PID.21.4.2 != null and firstSegments.PID.21.4.3 != "" and firstSegments.PID.21.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_21 using 'ID/Organization' HDORG: firstSegments.PID.21.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.21, ID: Organization_ID_pid_CX_21 -%} + {% endif -%} + {% endif -%} + + {% for nk33 in nk1Segment.33.Repeats -%} + {% if nk33.4.1 != "" and nk33.4.1 != null and nk33.4.2 != "" and nk33.4.2 != null and nk33.4.3 != "" and nk33.4.3 != null -%} + {% evaluate Organization_ID_nk_CX_33 using 'ID/Organization' HDORG: nk33.4 -%} + {% include 'Resource/Organization', NK1_33: nk33, ID: Organization_ID_nk_CX_33 -%} + {% endif -%} + {% endfor -%} + {% endfor -%} + + {% for db1Segment in db1SegmentLists.DB1 -%} + {% if db1Segment.2.1.Value == "PT" %} + {% for db in db1Segment.3.Repeats -%} + {% if db.4.1 != "" and db.4.1 != null and db.4.2 != "" and db.4.2 != null and db.4.3 != "" and db.4.3 != null -%} + {% evaluate Organization_ID_DB1_3 using 'ID/Organization' HDORG: db.4 -%} + {% include 'Resource/Organization', DB1: db.4, ID: Organization_ID_DB1_3 -%} + {% endif -%} + {% endfor %} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, DB1: db1Segment -%} + {% endif -%} + {% include 'Resource/Patient' DB1: db1Segment, ID: patientId -%} + {% endfor %} + + {% for obxSegment in obxSegmentLists.OBX -%} + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16 -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16 -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + {% if obxSegment.18 -%} + {% evaluate deviceId_OBX_18 using 'ID/Device' EI: obxSegment.18.Repeats[0] -%} + {% include 'Resource/Device' EI_OBX18: obxSegment.18, ID: deviceId_OBX_18 -%} + {% endif -%} + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23 -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + {% evaluate observationId using 'ID/Observation' OBX: obxSegment, baseId: patientId -%} + {% include 'Resource/Observation' OBX: obxSegment, Observation_Subject_ID: fullPatientId, ID: observationId -%} + {% include 'Extensions/Observation/ObservationExtension' OBX: obxSegment, ID: observationId %} + {% endfor -%} + + {% for al1Segment in al1SegmentLists.AL1 -%} + {% evaluate allergyIntoleranceId using 'ID/AllergyIntolerance' AL1: al1Segment, baseId: patientId -%} + {% include 'Resource/AllergyIntolerance' AL1: al1Segment, ID: allergyIntoleranceId, AllergyIntolerance_Patient_ID: fullPatientId -%} + {% endfor -%} + + {% for dg1Segment in dg1SegmentLists.DG1 -%} + {% if dg1Segment.16.Repeats[0] %} + {% if dg1Segment.16.Repeats[0].9.1 != "" and dg1Segment.16.Repeats[0].9.1 != null and dg1Segment.16.Repeats[0].9.2 != "" and dg1Segment.16.Repeats[0].9.2 != null and dg1Segment.16.Repeats[0].9.3 != "" and dg1Segment.16.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_DG1_16 using 'ID/Organization' HDORG: dg1Segment.16.Repeats[0].9 -%} + {% include 'Resource/Organization', DG1: dg1Segment.16.Repeats[0].9, ID: Organization_ID_DG1_16 -%} + {% endif -%} + {% evaluate practitionerId_DG1_16 using 'ID/Practitioner' XCN: dg1Segment.16.Repeats[0] -%} + {% include 'Resource/Practitioner' DG1: dg1Segment, ID: practitionerId_DG1_16 -%} + {% endif -%} + + {% evaluate conditionId using 'ID/Condition' DG1: dg1Segment, baseId: patientId -%} + {% include 'Resource/Condition' DG1: dg1Segment, Condition_Subject_ID: fullPatientId, baseId: patientId, ID: conditionId -%} + + {% if encounterId -%} + {% include 'Resource/Encounter' DG1: dg1Segment, conditionId: conditionId, ID: encounterId -%} + {% endif -%} + + {% if EpisodeOfCare_ID %} + {% include 'Resource/EpisodeOfCare' DG1: dg1Segment, conditionId: conditionId, ID: EpisodeOfCare_ID -%} + {% endif %} + {% if dg1Segment.22 -%} + {% evaluate conditionId_DG1_22 using 'ID/Condition' DG1: dg1Segment.22, baseId: patientId -%} + {% include 'Resource/Condition' DG1_22: dg1Segment.22, Condition_Subject_ID_DG1_22: fullPatientId, ID: conditionId_DG1_22 -%} + {% endif -%} + {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} + + {% endfor -%} + + {% for rf1Segment in rf1SegmentLists.RF1 -%} + {% if rf1Segment.19 -%} + {% evaluate Organization_ID_RF1_19 using 'ID/Organization' XON: rf1Segment.19 -%} + {% include 'Resource/Organization' RF1: rf1Segment.19, ID: Organization_ID_RF1_19 -%} + {% endif -%} + + {% if rf1Segment.20 -%} + {% if rf1Segment.20.9.1 != "" and rf1Segment.20.9.1 != null and rf1Segment.20.9.2 != "" and rf1Segment.20.9.2 != null and rf1Segment.20.9.3 != "" and rf1Segment.20.9.3 != null -%} + {% evaluate Organization_ID_RF1_20_9 using 'ID/Organization' HDORG: rf1Segment.20.9 -%} + {% include 'Resource/Organization', RF1_20: rf1Segment.20.9, ID: Organization_ID_RF1_20_9 -%} + {% endif -%} + {% evaluate Practitioner_ID_RF1_20 using 'ID/Practitioner' XCN: rf1Segment.20 -%} + {% include 'Resource/Practitioner' RF1: rf1Segment.20, ID: Practitioner_ID_RF1_20 -%} + {% endif -%} + + {% evaluate serviceRequestId using 'ID/ServiceRequest' RF1: rf1Segment, baseId: patientId -%} + {% include 'Resource/ServiceRequest' RF1: rf1Segment, ID: serviceRequestId, ServiceRequest_Subject_ID: fullPatientId -%} + {% endfor -%} + + {% for in1Segment in in1SegmentLists.IN1 -%} + + {% evaluate coverageId using 'ID/Coverage' CX: in1Segment -%} + {% include 'Resource/Coverage' IN1: in1Segment, ID: coverageId -%} + {% include 'Reference/Coverage/Beneficiary' ID: coverageId, REF: fullPatientId -%} + + {% for in1_49 in in1Segment.49.Repeats -%} + {% if in1_49.4.1 != "" and in1_49.4.1 != null and in1_49.4.2 != "" and in1_49.4.2 != null and in1_49.4.3 != "" and in1_49.4.3 != null -%} + {% evaluate Organization_ID_in1_CX_49 using 'ID/Organization' HDORG: in1_49.4 -%} + {% include 'Resource/Organization', IN1_49: in1_49, ID: Organization_ID_in1_CX_49 -%} + {% endif -%} + {% endfor -%} + + {% for in1_3 in in1Segment.3.Repeats -%} + {% if in1_3.4.1 != "" and in1_3.4.1 != null and in1_3.4.2 != "" and in1_3.4.2 != null and in1_3.4.3 != "" and in1_3.4.3 != null -%} + {% evaluate Organization_ID_in1_CX_3 using 'ID/Organization' HDORG: in1_3.4 -%} + {% include 'Resource/Organization', IN1_3: in1_3, ID: Organization_ID_in1_CX_3 -%} + {% endif -%} + {% endfor -%} + + {% for in1_10 in in1Segment.10.Repeats -%} + {% if in1_10.4.1 != "" and in1_10.4.1 != null and in1_10.4.2 != "" and in1_10.4.2 != null and in1_10.4.3 != "" and in1_10.4.3 != null -%} + {% evaluate Organization_ID_in1_CX_10 using 'ID/Organization' HDORG: in1_10.4 -%} + {% include 'Resource/Organization', IN1_10: in1_10, ID: Organization_ID_in1_CX_10 -%} + {% endif -%} + {% endfor -%} + + {% if in1Segment.4 -%} + {% evaluate Organization_ID_in1_4 using 'ID/Organization' XON: in1Segment.4 -%} + {% else -%} + {% evaluate Organization_ID_in1_4 using 'ID/Organization' CX: in1Segment -%} + {% endif -%} + {% if Organization_ID_in1_4 -%} + {% include 'Resource/Organization', IN1: in1Segment, ID: Organization_ID_in1_4 -%} + {% assign org_in1_4 = Organization_ID_in1_4 | prepend: 'Organization/' -%} + {% include 'Reference/Coverage/Payor' ID: coverageId, REF: org_in1_4 -%} + {% endif -%} + + {% if in1Segment.11 -%} + {% evaluate Organization_ID_in1_11 using 'ID/Organization' XON: in1Segment.11 -%} + {% else -%} + {% evaluate Organization_ID_in1_11 using 'ID/Organization' CX_IN1: in1Segment -%} + {% endif -%} + {% if Organization_ID_in1_11 -%} + {% include 'Resource/Organization', IN1_11: in1Segment, ID: Organization_ID_in1_11 -%} + {% assign org_in1_11 = Organization_ID_in1_11 | prepend: 'Organization/' -%} + {% include 'Reference/Coverage/PolicyHolder' ID: coverageId, REF: org_in1_11 -%} + {% endif -%} + + {% if in1Segment.17.1.Value == "SEL" -%} + {% include 'Resource/Patient' PID_IN1: firstSegments.PID, IN1: in1Segment, ID: patientId -%} + {% include 'Reference/Coverage/Subscriber' ID: coverageId, REF: fullPatientId -%} + {% endif -%} + {% unless in1Segment.17.1.Value == "SEL" or in1Segment.17.Value == "" -%} + {% evaluate in1relatedPersonId using 'ID/RelatedPerson' IN1: in1Segment, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: in1relatedPersonId, IN1: in1Segment -%} + {% assign rel_in1_17 = in1relatedPersonId | prepend: 'RelatedPerson/' -%} + {% include 'Reference/Coverage/Subscriber' ID: coverageId, REF: rel_in1_17 -%} + {% endunless -%} + + {% for in2Segment in in2SegmentLists.IN2 -%} + {% if in1Segment.17.1.Value == "SEL" -%} + {% include 'Resource/Patient' IN2: in2Segment, ID: patientId -%} + {% endif -%} + {% unless in1Segment.17.1.Value == "SEL" or in1Segment.17.Value == "" -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: in1relatedPersonId, IN2: in2Segment -%} + {% endunless -%} + + {% unless in1Segment.10 and in1Segment.11 -%} + {% if in2Segment.3 -%} + {% evaluate in2relatedPersonId using 'ID/RelatedPerson' IN2: in2Segment, baseId: patientId -%} + {% if in2Segment.3.9.1 != "" and in2Segment.3.9.1 != null and in2Segment.3.9.2 != "" and in2Segment.3.9.2 != null and in2Segment.3.9.3 != "" and in2Segment.3.9.3 != null -%} + {% evaluate Organization_ID_IN2_3_9 using 'ID/Organization' HDORG: in2Segment.3.9 -%} + {% include 'Resource/Organization', IN2_3: in2Segment.3.9, ID: Organization_ID_IN2_3_9 -%} + {% endif -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: in2relatedPersonId, IN2_3: in2Segment -%} + {% assign relatedperson_3 = in2relatedPersonId | prepend: 'RelatedPerson/' -%} + {% include 'Reference/Coverage/PolicyHolder' ID: coverageId, REF: relatedperson_3 -%} + {% endif -%} + {% endunless -%} + + {% if in1Segment.10 == null and in1Segment.11 == null and in2Segment.3 == null -%} + {% if in2Segment.70 -%} + {% evaluate organization_Id_IN2_70 using 'ID/Organization' XON: in2Segment.70 -%} + {% include 'Resource/Organization' IN2_70: in2Segment, ID: organization_Id_IN2_70 -%} + {% assign org_in2_70 = organization_Id_IN2_70 | prepend: 'Organization/' -%} + {% include 'Reference/Coverage/PolicyHolder' ID: coverageId, REF: org_in2_70 -%} + {% endif -%} + {% endif -%} + + {% if Organization_ID_in1_11 -%} + {% include 'Resource/Organization', IN2_49: in2Segment, ID: Organization_ID_in1_11 -%} + {% endif -%} + {% include 'Resource/Coverage' IN2: in2Segment, ID: coverageId -%} + {% include 'Resource/Patient' IN2_6: in2Segment, ID: patientId -%} + + {% for in2_1 in in2Segment.1.Repeats -%} + {% if in2_1.4.1 != "" and in2_1.4.1 != null and in2_1.4.2 != "" and in2_1.4.2 != null and in2_1.4.3 != "" and in2_1.4.3 != null -%} + {% evaluate Organization_ID_in2_CX_1 using 'ID/Organization' HDORG: in2_1.4 -%} + {% include 'Resource/Organization', IN2_1: in2_1, ID: Organization_ID_in2_CX_1 -%} + {% endif -%} + {% endfor -%} + {% if in2Segment.61 -%} + {% if in2Segment.61.4.1 != "" and in2Segment.61.4.1 != null and in2Segment.61.4.2 != "" and in2Segment.61.4.2 != null and in2Segment.61.4.3 != "" and in2Segment.61.4.3 != null -%} + {% evaluate Organization_ID_in2_CX_61 using 'ID/Organization' HDORG: in2Segment.61.4 -%} + {% include 'Resource/Organization', IN2_61: in2Segment.61, ID: Organization_ID_in2_CX_61 -%} + {% endif -%} + {% endif -%} + {% endfor -%} + + {% endfor -%} + ] +} \ No newline at end of file diff --git a/data/Templates/Hl7v2/ADT_A14.liquid b/data/Templates/Hl7v2/ADT_A14.liquid index 6515c302f..abb4f00ff 100644 --- a/data/Templates/Hl7v2/ADT_A14.liquid +++ b/data/Templates/Hl7v2/ADT_A14.liquid @@ -289,7 +289,7 @@ {% include 'Resource/Organization', PV1: firstSegments.PV1.54.4, ID: Organization_ID_PV1_54_4 -%} {% endif -%} {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: firstSegments.PV1.54 -%} - {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId -%} + {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId, Root_Template: 'ADT_A14' -%} {% endif -%} {% evaluate encounterId using 'ID/Encounter' PV1: firstSegments.PV1, baseId: patientId -%} @@ -343,14 +343,8 @@ {% include 'Resource/Practitioner' PR1: pr1Segment.12, ID: practitionerId_PR1_12 -%} {% endif -%} - {% if pr1Segment.23.1 -%} - {% evaluate Location_ID_PR1_23_1 using 'ID/Location' PL: pr1Segment.23.1 -%} - {% include 'Resource/PLLocation' PL_1: pr1Segment.23.1, ID: Location_ID_PR1_23_1-%} - {% else %} - {% if pr1Segment.23.2 %} - {% evaluate Location_ID_PR1_23_2 using 'ID/Location' PL: pr1Segment.23.2 -%} - {% include 'Resource/PLLocation' PL_2: pr1Segment.23.2, ID: Location_ID_PR1_23_2-%} - {% endif %} + {% if pr1Segment.23 -%} + {% include 'Resource/PLLocation' PL: pr1Segment.23-%} {% endif %} {% if pr1Segment.25 -%} @@ -476,8 +470,8 @@ {% evaluate conditionId_DG1_22 using 'ID/Condition' DG1: dg1Segment.22, baseId: patientId -%} {% include 'Resource/Condition' DG1_22: dg1Segment.22, Condition_Subject_ID_DG1_22: fullPatientId, ID: conditionId_DG1_22 -%} {% endif -%} - {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} - + {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} + {% endfor -%} {% for rf1Segment in rf1SegmentLists.RF1 -%} diff --git a/data/Templates/Hl7v2/ADT_A15.liquid b/data/Templates/Hl7v2/ADT_A15.liquid index cf3469775..3cd61fbf8 100644 --- a/data/Templates/Hl7v2/ADT_A15.liquid +++ b/data/Templates/Hl7v2/ADT_A15.liquid @@ -235,7 +235,7 @@ {% include 'Resource/Organization', PV1: firstSegments.PV1.54.4, ID: Organization_ID_PV1_54_4 -%} {% endif -%} {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: firstSegments.PV1.54 -%} - {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId -%} + {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId, Root_Template: 'ADT_A15' -%} {% endif -%} {% evaluate encounterId using 'ID/Encounter' PV1: firstSegments.PV1, baseId: patientId -%} diff --git a/data/Templates/Hl7v2/ADT_A16.liquid b/data/Templates/Hl7v2/ADT_A16.liquid index 275bf6b08..cf34823b3 100644 --- a/data/Templates/Hl7v2/ADT_A16.liquid +++ b/data/Templates/Hl7v2/ADT_A16.liquid @@ -288,7 +288,7 @@ {% include 'Resource/Organization', PV1: firstSegments.PV1.54.4, ID: Organization_ID_PV1_54_4 -%} {% endif -%} {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: firstSegments.PV1.54 -%} - {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId -%} + {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId, Root_Template: 'ADT_A16' -%} {% endif -%} {% evaluate encounterId using 'ID/Encounter' PV1: firstSegments.PV1, baseId: patientId -%} @@ -342,14 +342,8 @@ {% include 'Resource/Practitioner' PR1: pr1Segment.12, ID: practitionerId_PR1_12 -%} {% endif -%} - {% if pr1Segment.23.1 -%} - {% evaluate Location_ID_PR1_23_1 using 'ID/Location' PL: pr1Segment.23.1 -%} - {% include 'Resource/PLLocation' PL_1: pr1Segment.23.1, ID: Location_ID_PR1_23_1-%} - {% else %} - {% if pr1Segment.23.2 %} - {% evaluate Location_ID_PR1_23_2 using 'ID/Location' PL: pr1Segment.23.2 -%} - {% include 'Resource/PLLocation' PL_2: pr1Segment.23.2, ID: Location_ID_PR1_23_2-%} - {% endif %} + {% if pr1Segment.23 -%} + {% include 'Resource/PLLocation' PL: pr1Segment.23-%} {% endif %} {% if pr1Segment.25 -%} @@ -475,8 +469,8 @@ {% evaluate conditionId_DG1_22 using 'ID/Condition' DG1: dg1Segment.22, baseId: patientId -%} {% include 'Resource/Condition' DG1_22: dg1Segment.22, Condition_Subject_ID_DG1_22: fullPatientId, ID: conditionId_DG1_22 -%} {% endif -%} - {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} - + {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} + {% endfor -%} {% for rf1Segment in rf1SegmentLists.RF1 -%} diff --git a/data/Templates/Hl7v2/ADT_A25.liquid b/data/Templates/Hl7v2/ADT_A25.liquid new file mode 100644 index 000000000..5cbebb62d --- /dev/null +++ b/data/Templates/Hl7v2/ADT_A25.liquid @@ -0,0 +1,315 @@ +{% assign firstSegments = hl7v2Data | get_first_segments: 'MSH|UAC|EVN|PID|PD1|PV1|PV2' -%} +{% assign sftSegmentLists = hl7v2Data | get_segment_lists: 'SFT' -%} +{% assign db1SegmentLists = hl7v2Data | get_segment_lists: 'DB1' -%} +{% assign obxSegmentLists = hl7v2Data | get_segment_lists: 'OBX' -%} +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} +{ + "resourceType": "Bundle", + "type": "batch", + {% if firstSegments.MSH.7 -%} + "timestamp":"{{ firstSegments.MSH.7.Value | format_as_date_time }}", + {% endif -%} + "identifier": + { + "value":"{{ firstSegments.MSH.10.Value }}", + }, + "id":"{{ bundleID }}", + "entry": [ + {% evaluate patientId using 'ID/Patient' PID: firstSegments.PID, type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% evaluate messageHeaderId using 'ID/MessageHeader' MSH: firstSegments.MSH -%} + + {% if firstSegments.MSH -%} + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, ID: messageHeaderId -%} + {% evaluate provenanceId using 'ID/Provenance' MSH: firstSegments.MSH, baseId: patientId -%} + {% include 'Resource/Provenance' Root_Template: 'ADT_A25', MSH: firstSegments.MSH, REF_BUNDLE: bundleID, ID: provenanceId -%} + + {%- comment -%} + {% assign transformation_val = 'provenance_transformation' %} + {% evaluate provenanceOrganizationId using 'ID/Organization', prov_id: firstSegments.MSH -%} + {% evaluate provenanceTransformationId using 'ID/Provenance_transformation' prov_id: transformation_val -%} + {% include 'Resource/Organization' org_name: 'Microsoft Corporation', ID: provenanceOrganizationId -%} + {% include 'Resource/Provenance_transformation' Root_Template: 'ADT_A25', Provenance_Organization_ID: provenanceOrganizationId, REF_MSH: messageHeaderId, provenanceOrganizationId, ID: provenanceTransformationId -%} + {%- endcomment -%} + {% if firstSegments.MSH.4 -%} + {% if firstSegments.MSH.4.1 != "" and firstSegments.MSH.4.1 != null or firstSegments.MSH.4.2 != "" and firstSegments.MSH.4.2 != null or firstSegments.MSH.4.3 != "" and firstSegments.MSH.4.3 != null -%} + {% evaluate organization_ID_MSH_4 using 'ID/Organization' HD: firstSegments.MSH.4 -%} + {% include 'Resource/Organization' MSHHD1: firstSegments.MSH.4, MSH: firstSegments.MSH, ID: organization_ID_MSH_4 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.6 %} + {% if firstSegments.MSH.6.1 != "" and firstSegments.MSH.6.1 != null or firstSegments.MSH.6.2 != "" and firstSegments.MSH.6.2 != null or firstSegments.MSH.6.3 != "" and firstSegments.MSH.6.3 != null -%} + {% evaluate organization_Id_MSH_6 using 'ID/Organization' HD: firstSegments.MSH.6 -%} + {% include 'Resource/Organization' MSHHD2: firstSegments.MSH.6, MSH: firstSegments.MSH, ID: organization_Id_MSH_6 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.22 %} + {% if firstSegments.MSH.22.1 != "" and firstSegments.MSH.22.1 != null -%} + {% evaluate organization_Id_MSH_22 using 'ID/Organization' XON: firstSegments.MSH.22 -%} + {% include 'Resource/Organization' MSHXON1: firstSegments.MSH.22, ID: organization_Id_MSH_22 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.23 %} + {% if firstSegments.MSH.23.1 != "" and firstSegments.MSH.23.1 != null -%} + {% evaluate organization_Id_MSH_23 using 'ID/Organization' XON: firstSegments.MSH.23 -%} + {% include 'Resource/Organization' MSHXON2: firstSegments.MSH.23, ID: organization_Id_MSH_23 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.3 and firstSegments.MSH.24 %} + {% evaluate device_Id_MSH_3 using 'ID/Device' HD: firstSegments.MSH.3 -%} + {% include 'Resource/Device' MSH: firstSegments.MSH, ID: device_Id_MSH_3 -%} + {% endif -%} + {% endif -%} + + {% for sftSegment in sftSegmentLists.SFT -%} + {% evaluate deviceId_SFT using 'ID/Device' SFT: sftSegment -%} + {% include 'Resource/Device' SFT:sftSegment, ID: deviceId_SFT -%} + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, SFT:sftSegment, ID: messageHeaderID -%} + {% endfor -%} + + {% include 'Resource/Patient' PID: firstSegments.PID, PD1: firstSegments.PD1, ID: patientId -%} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, PID: firstSegments.PID, PD1: firstSegments.PD1, PV1: firstSegments.PV1 -%} + + {% if firstSegments.PID.18 -%} + {% evaluate accountId using 'ID/Account' CX: firstSegments.PID.3 -%} + {% include 'Resource/Account' PID: firstSegments.PID, ID: accountId -%} + {% include 'Reference/Account/Subject' ID: accountId, REF: fullPatientId -%} + {% if firstSegments.PID.18.4.1 != "" and firstSegments.PID.18.4.1 != null and firstSegments.PID.18.4.2 != "" and firstSegments.PID.18.4.2 != null and firstSegments.PID.18.4.3 != "" and firstSegments.PID.18.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_18 using 'ID/Organization' HDORG: firstSegments.PID.18.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.18, ID: Organization_ID_pid_CX_18 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PID.2 -%} + {% if firstSegments.PID.2.4.1 != "" and firstSegments.PID.2.4.1 != null and firstSegments.PID.2.4.2 != "" and firstSegments.PID.2.4.2 != null and firstSegments.PID.2.4.3 != "" and firstSegments.PID.2.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_2 using 'ID/Organization' HDORG: firstSegments.PID.2.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.2, ID: Organization_ID_pid_CX_2 -%} + {% endif -%} + {% endif -%} + {% for pid3 in firstSegments.PID.3.Repeats -%} + {% if pid3.4.1 != "" and pid3.4.1 != null and pid3.4.2 != "" and pid3.4.2 != null and pid3.4.3 != "" and pid3.4.3 != null -%} + {% evaluate Organization_ID_pid_CX using 'ID/Organization' HDORG: pid3.4 -%} + {% include 'Resource/Organization', PID: pid3, ID: Organization_ID_pid_CX -%} + {% endif -%} + {% endfor -%} + {% if firstSegments.PID.4 -%} + {% if firstSegments.PID.4.4.1 != "" and firstSegments.PID.4.4.1 != null and firstSegments.PID.4.4.2 != "" and firstSegments.PID.4.4.2 != null and firstSegments.PID.4.4.3 != "" and firstSegments.PID.4.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_4 using 'ID/Organization' HDORG: firstSegments.PID.4.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.4, ID: Organization_ID_pid_CX_4 -%} + {% endif -%} + {% endif -%} + + {% unless nk1SegmentLists.NK1 -%} + {% if firstSegments.PID.21 -%} + {% if firstSegments.PID.21.4.1 != "" and firstSegments.PID.21.4.1 != null and firstSegments.PID.21.4.2 != "" and firstSegments.PID.21.4.2 != null and firstSegments.PID.21.4.3 != "" and firstSegments.PID.21.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_21 using 'ID/Organization' HDORG: firstSegments.PID.21.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.21, ID: Organization_ID_pid_CX_21 -%} + {% endif -%} + {% evaluate pidrelatedPersonId using 'ID/RelatedPerson' PID: firstSegments.PID, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: pidrelatedPersonId, PID: firstSegments.PID -%} + {% endif -%} + {% endunless -%} + {% if firstSegments.PD1.3 -%} + {% evaluate Organization_ID_PD1_3 using 'ID/Organization' XON: firstSegments.PD1.3 -%} + {% include 'Resource/Organization' PD1: firstSegments.PD1, ID: Organization_ID_PD1_3 -%} + {% endif -%} + + {% if firstSegments.PD1.4 -%} + {% if firstSegments.PD1.4.9.1 != "" and firstSegments.PD1.4.9.1 != null and firstSegments.PD1.4.9.2 != "" and firstSegments.PD1.4.9.2 != null and firstSegments.PD1.4.9.3 != "" and firstSegments.PD1.4.9.3 != null -%} + {% evaluate Organization_ID_PD1_4_9 using 'ID/Organization' HDORG: firstSegments.PD1.4.9 -%} + {% include 'Resource/Organization', PD1_4: firstSegments.PD1.4.9, ID: Organization_ID_PD1_4_9 -%} + {% endif -%} + {% evaluate Practitioner_ID_PD1_4 using 'ID/Practitioner' XCN: firstSegments.PD1.4 -%} + {% include 'Resource/Practitioner' PD1: firstSegments.PD1.4, ID: Practitioner_ID_PD1_4 -%} + {% endif -%} + + {% if firstSegments.PV1 -%} + {% if firstSegments.PV1.5 -%} + {% if firstSegments.PV1.5.4.1 != "" and firstSegments.PV1.5.4.1 != null and firstSegments.PV1.5.4.2 != "" and firstSegments.PV1.5.4.2 != null and firstSegments.PV1.5.4.3 != "" and firstSegments.PV1.5.4.3 != null -%} + {% evaluate Organization_ID_PV1_5_4 using 'ID/Organization' HDORG: firstSegments.PV1.5.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.5.4, ID: Organization_ID_PV1_5_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PV1.19 -%} + {% if firstSegments.PV1.19.4.1 != "" and firstSegments.PV1.19.4.1 != null and firstSegments.PV1.19.4.2 != "" and firstSegments.PV1.19.4.2 != null and firstSegments.PV1.19.4.3 != "" and firstSegments.PV1.19.4.3 != null -%} + {% evaluate Organization_ID_PV1_19_4 using 'ID/Organization' HDORG: firstSegments.PV1.19.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.19.4, ID: Organization_ID_PV1_19_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PV1.7 -%} + {% if firstSegments.PV1.7.9.1 != "" and firstSegments.PV1.7.9.1 != null and firstSegments.PV1.7.9.2 != "" and firstSegments.PV1.7.9.2 != null and firstSegments.PV1.7.9.3 != "" and firstSegments.PV1.7.9.3 != null -%} + {% evaluate Organization_ID_PV1_7_9 using 'ID/Organization' HDORG: firstSegments.PV1.7.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.7.9, ID: Organization_ID_PV1_7_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_7 using 'ID/Practitioner' XCN: firstSegments.PV1.7 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.7, ID: practitionerId_PV1_7 -%} + {% endif -%} + + {% if firstSegments.PV1.8 -%} + {% if firstSegments.PV1.8.9.1 != "" and firstSegments.PV1.8.9.1 != null and firstSegments.PV1.8.9.2 != "" and firstSegments.PV1.8.9.2 != null and firstSegments.PV1.8.9.3 != "" and firstSegments.PV1.8.9.3 != null -%} + {% evaluate Organization_ID_PV1_8_9 using 'ID/Organization' HDORG: firstSegments.PV1.8.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.8.9, ID: Organization_ID_PV1_8_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_8 using 'ID/Practitioner' XCN: firstSegments.PV1.8 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.8, ID: practitionerId_PV1_8 -%} + {% endif -%} + + {% if firstSegments.PV1.9 -%} + {% if firstSegments.PV1.9.9.1 != "" and firstSegments.PV1.9.9.1 != null and firstSegments.PV1.9.9.2 != "" and firstSegments.PV1.9.9.2 != null and firstSegments.PV1.9.9.3 != "" and firstSegments.PV1.9.9.3 != null -%} + {% evaluate Organization_ID_PV1_9_9 using 'ID/Organization' HDORG: firstSegments.PV1.9.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.9.9, ID: Organization_ID_PV1_9_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_9 using 'ID/Practitioner' XCN: firstSegments.PV1.9 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.9, ID: practitionerId_PV1_9 -%} + {% endif -%} + + {% if firstSegments.PV1.17 -%} + {% if firstSegments.PV1.17.9.1 != "" and firstSegments.PV1.17.9.1 != null and firstSegments.PV1.17.9.2 != "" and firstSegments.PV1.17.9.2 != null and firstSegments.PV1.17.9.3 != "" and firstSegments.PV1.17.9.3 != null -%} + {% evaluate Organization_ID_PV1_17_9 using 'ID/Organization' HDORG: firstSegments.PV1.17.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.17.9, ID: Organization_ID_PV1_17_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_17 using 'ID/Practitioner' XCN: firstSegments.PV1.17 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.17, ID: practitionerId_PV1_17 -%} + {% endif -%} + + {% if firstSegments.PV1.50 -%} + {% for p in firstSegments.PV1.50.Repeats -%} + {% if p.4.1 != "" and p.4.1 != null and p.4.2 != "" and p.4.2 != null and p.4.3 != "" and p.4.3 != null -%} + {% evaluate Organization_ID_PV1_50_4 using 'ID/Organization' HDORG: p.4 -%} + {% include 'Resource/Organization', PV1: p.4, ID: Organization_ID_PV1_50_4 -%} + {% endif -%} + {% endfor -%} + {% endif -%} + + {% if firstSegments.PV1.52 -%} + {% if firstSegments.PV1.52.9.1 != "" and firstSegments.PV1.52.9.1 != null and firstSegments.PV1.52.9.2 != "" and firstSegments.PV1.52.9.2 != null and firstSegments.PV1.52.9.3 != "" and firstSegments.PV1.52.9.3 != null -%} + {% evaluate Organization_ID_PV1_52_9 using 'ID/Organization' HDORG: firstSegments.PV1.52.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.52.9, ID: Organization_ID_PV1_52_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_52 using 'ID/Practitioner' XCN: firstSegments.PV1.52 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.52, ID: practitionerId_PV1_52 -%} + {% endif -%} + + {% if firstSegments.PV2.13 -%} + {% if firstSegments.PV2.13.9.1 != "" and firstSegments.PV2.13.9.1 != null and firstSegments.PV2.13.9.2 != "" and firstSegments.PV2.13.9.2 != null and firstSegments.PV2.13.9.3 != "" and firstSegments.PV2.13.9.3 != null -%} + {% evaluate Organization_ID_PV2_13_9 using 'ID/Organization' HDORG: firstSegments.PV2.13.9 -%} + {% include 'Resource/Organization', PV2: firstSegments.PV2.13.9, ID: Organization_ID_PV2_13_9 -%} + {% endif -%} + {% evaluate practitionerId_PV2_13 using 'ID/Practitioner' XCN: firstSegments.PV2.13 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV2.13, ID: practitionerId_PV2_13 -%} + {% endif -%} + + {% if firstSegments.PV1.3 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.3-%} + {% endif -%} + + {% if firstSegments.PV1.6 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.6 -%} + {% endif -%} + + {% if firstSegments.PV1.37 -%} + {% evaluate location_ID_PV1_37 using 'ID/Location' DLD: firstSegments.PV1.37 -%} + {% include 'Resource/Location' PV1: firstSegments.PV1.37, ID: location_ID_PV1_37-%} + {% endif -%} + + {% if firstSegments.PV1.42 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.42-%} + {% endif -%} + + {% if firstSegments.PV1.43 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.43-%} + {% endif -%} + + {% if firstSegments.PV2.1 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV2.1-%} + {% endif -%} + + {% if firstSegments.PV1.54 -%} + {% if firstSegments.PV1.54.4.1 != "" and firstSegments.PV1.54.4.1 != null and firstSegments.PV1.54.4.2 != "" and firstSegments.PV1.54.4.2 != null and firstSegments.PV1.54.4.3 != "" and firstSegments.PV1.54.4.3 != null -%} + {% evaluate Organization_ID_PV1_54_4 using 'ID/Organization' HDORG: firstSegments.PV1.54.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.54.4, ID: Organization_ID_PV1_54_4 -%} + {% endif -%} + {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: firstSegments.PV1.54 -%} + {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId, Root_Template: 'ADT_A25' -%} + {% endif -%} + + {% evaluate encounterId using 'ID/Encounter' PV1: firstSegments.PV1, baseId: patientId -%} + {% include 'Resource/Encounter' Root_Template: 'ADT_A25', PV1: firstSegments.PV1, PV2: firstSegments.PV2, ID: encounterId -%} + {% include 'Reference/Encounter/Subject' ID: encounterId, REF: fullPatientId -%} + {% include 'Extensions/Encounter/EncounterExtension' ID: encounterId, PV1: firstSegments.PV1, PV2: firstSegments.PV2, -%} + {% endif -%} + + {% if firstSegments.EVN -%} + {% evaluate provenanceId using 'ID/Provenance' EVN: firstSegments.EVN, baseId: patientId -%} + {% include 'Resource/Provenance' EVN: firstSegments.EVN, EVNTEXT: firstSegments.MSH.9, REF_BUNDLE: bundleID, ID: provenanceId -%} + {% if firstSegments.EVN.5 -%} + {% if firstSegments.EVN.5.9.1 != "" and firstSegments.EVN.5.9.1 != null and firstSegments.EVN.5.9.2 != "" and firstSegments.EVN.5.9.2 != null and firstSegments.EVN.5.9.3 != "" and firstSegments.EVN.5.9.3 != null -%} + {% evaluate Organization_ID_EVN_5_9 using 'ID/Organization' HDORG: firstSegments.EVN.5.9 -%} + {% include 'Resource/Organization', EVN: firstSegments.EVN.5.9, ID: Organization_ID_EVN_5_9 -%} + {% endif -%} + {% evaluate practitionerId_EVN_5 using 'ID/Practitioner' XCN: firstSegments.EVN.5 -%} + {% include 'Resource/Practitioner' EVN: firstSegments.EVN.5, ID: practitionerId_EVN_5 -%} + {% if firstSegments.EVN.7 -%} + {% evaluate locationId_EVN_7 using 'ID/Location' HD: firstSegments.EVN.7 -%} + {% include 'Resource/Location' EVN: firstSegments.EVN.7, ID: locationId_EVN_7 -%} + {% endif -%} + {% endif -%} + {% endif -%} + + {% for db1Segment in db1SegmentLists.DB1 -%} + {% if db1Segment.2.1.Value == "PT" %} + {% for db in db1Segment.3.Repeats -%} + {% if db.4.1 != "" and db.4.1 != null and db.4.2 != "" and db.4.2 != null and db.4.3 != "" and db.4.3 != null -%} + {% evaluate Organization_ID_DB1_3 using 'ID/Organization' HDORG: db.4 -%} + {% include 'Resource/Organization', DB1: db.4, ID: Organization_ID_DB1_3 -%} + {% endif -%} + {% endfor %} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, DB1: db1Segment -%} + {% endif -%} + {% include 'Resource/Patient' DB1: db1Segment, ID: patientId -%} + {% endfor %} + + {% for obxSegment in obxSegmentLists.OBX -%} + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16 -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16 -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + {% if obxSegment.18 -%} + {% evaluate deviceId_OBX_18 using 'ID/Device' EI: obxSegment.18.Repeats[0] -%} + {% include 'Resource/Device' EI_OBX18: obxSegment.18, ID: deviceId_OBX_18 -%} + {% endif -%} + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23 -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + {% evaluate observationId using 'ID/Observation' OBX: obxSegment, baseId: patientId -%} + {% include 'Resource/Observation' OBX: obxSegment, Observation_Subject_ID: fullPatientId, ID: observationId -%} + {% include 'Extensions/Observation/ObservationExtension' OBX: obxSegment, ID: observationId %} + {% endfor -%} + + ] +} \ No newline at end of file diff --git a/data/Templates/Hl7v2/ADT_A26.liquid b/data/Templates/Hl7v2/ADT_A26.liquid new file mode 100644 index 000000000..e862d9216 --- /dev/null +++ b/data/Templates/Hl7v2/ADT_A26.liquid @@ -0,0 +1,318 @@ +{% assign firstSegments = hl7v2Data | get_first_segments: 'MSH|UAC|EVN|PID|PD1|PV1|PV2' -%} +{% assign sftSegmentLists = hl7v2Data | get_segment_lists: 'SFT' -%} +{% assign db1SegmentLists = hl7v2Data | get_segment_lists: 'DB1' -%} +{% assign obxSegmentLists = hl7v2Data | get_segment_lists: 'OBX' -%} +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} +{ + "resourceType": "Bundle", + "type": "batch", + {% if firstSegments.MSH.7 -%} + "timestamp":"{{ firstSegments.MSH.7.Value | format_as_date_time }}", + {% endif -%} + "identifier": + { + "value":"{{ firstSegments.MSH.10.Value }}", + }, + "id":"{{ bundleID }}", + "entry": [ + {% evaluate patientId using 'ID/Patient' PID: firstSegments.PID, type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% evaluate messageHeaderId using 'ID/MessageHeader' MSH: firstSegments.MSH -%} + + {% if firstSegments.MSH -%} + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, ID: messageHeaderId -%} + {% evaluate provenanceId using 'ID/Provenance' MSH: firstSegments.MSH, baseId: patientId -%} + {% include 'Resource/Provenance' Root_Template: 'ADT_A26', MSH: firstSegments.MSH, REF_BUNDLE: bundleID, ID: provenanceId -%} + + {%- comment -%} + {% assign transformation_val = 'provenance_transformation' %} + {% evaluate provenanceOrganizationId using 'ID/Organization', prov_id: firstSegments.MSH -%} + {% evaluate provenanceTransformationId using 'ID/Provenance_transformation' prov_id: transformation_val -%} + {% include 'Resource/Organization' org_name: 'Microsoft Corporation', ID: provenanceOrganizationId -%} + {% include 'Resource/Provenance_transformation' Root_Template: 'ADT_A26', Provenance_Organization_ID: provenanceOrganizationId, REF_MSH: messageHeaderId, provenanceOrganizationId, ID: provenanceTransformationId -%} + {%- endcomment -%} + {% if firstSegments.MSH.4 -%} + {% if firstSegments.MSH.4.1 != "" and firstSegments.MSH.4.1 != null or firstSegments.MSH.4.2 != "" and firstSegments.MSH.4.2 != null or firstSegments.MSH.4.3 != "" and firstSegments.MSH.4.3 != null -%} + {% evaluate organization_ID_MSH_4 using 'ID/Organization' HD: firstSegments.MSH.4 -%} + {% include 'Resource/Organization' MSHHD1: firstSegments.MSH.4, MSH: firstSegments.MSH, ID: organization_ID_MSH_4 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.6 %} + {% if firstSegments.MSH.6.1 != "" and firstSegments.MSH.6.1 != null or firstSegments.MSH.6.2 != "" and firstSegments.MSH.6.2 != null or firstSegments.MSH.6.3 != "" and firstSegments.MSH.6.3 != null -%} + {% evaluate organization_Id_MSH_6 using 'ID/Organization' HD: firstSegments.MSH.6 -%} + {% include 'Resource/Organization' MSHHD2: firstSegments.MSH.6, MSH: firstSegments.MSH, ID: organization_Id_MSH_6 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.22 %} + {% if firstSegments.MSH.22.1 != "" and firstSegments.MSH.22.1 != null -%} + {% evaluate organization_Id_MSH_22 using 'ID/Organization' XON: firstSegments.MSH.22 -%} + {% include 'Resource/Organization' MSHXON1: firstSegments.MSH.22, ID: organization_Id_MSH_22 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.23 %} + {% if firstSegments.MSH.23.1 != "" and firstSegments.MSH.23.1 != null -%} + {% evaluate organization_Id_MSH_23 using 'ID/Organization' XON: firstSegments.MSH.23 -%} + {% include 'Resource/Organization' MSHXON2: firstSegments.MSH.23, ID: organization_Id_MSH_23 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.3 and firstSegments.MSH.24 %} + {% evaluate device_Id_MSH_3 using 'ID/Device' HD: firstSegments.MSH.3 -%} + {% include 'Resource/Device' MSH: firstSegments.MSH, ID: device_Id_MSH_3 -%} + {% endif -%} + {% endif -%} + + {% for sftSegment in sftSegmentLists.SFT -%} + {% evaluate deviceId_SFT using 'ID/Device' SFT: sftSegment -%} + {% include 'Resource/Device' SFT:sftSegment, ID: deviceId_SFT -%} + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, SFT:sftSegment, ID: messageHeaderID -%} + {% endfor -%} + + {% include 'Resource/Patient' PID: firstSegments.PID, PD1: firstSegments.PD1, ID: patientId -%} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, PID: firstSegments.PID, PD1: firstSegments.PD1, PV1: firstSegments.PV1 -%} + + {% if firstSegments.PID.18 -%} + {% evaluate accountId using 'ID/Account' CX: firstSegments.PID.3 -%} + {% include 'Resource/Account' PID: firstSegments.PID, ID: accountId -%} + {% include 'Reference/Account/Subject' ID: accountId, REF: fullPatientId -%} + {% if firstSegments.PID.18.4.1 != "" and firstSegments.PID.18.4.1 != null and firstSegments.PID.18.4.2 != "" and firstSegments.PID.18.4.2 != null and firstSegments.PID.18.4.3 != "" and firstSegments.PID.18.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_18 using 'ID/Organization' HDORG: firstSegments.PID.18.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.18, ID: Organization_ID_pid_CX_18 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PID.2 -%} + {% if firstSegments.PID.2.4.1 != "" and firstSegments.PID.2.4.1 != null and firstSegments.PID.2.4.2 != "" and firstSegments.PID.2.4.2 != null and firstSegments.PID.2.4.3 != "" and firstSegments.PID.2.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_2 using 'ID/Organization' HDORG: firstSegments.PID.2.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.2, ID: Organization_ID_pid_CX_2 -%} + {% endif -%} + {% endif -%} + {% for pid3 in firstSegments.PID.3.Repeats -%} + {% if pid3.4.1 != "" and pid3.4.1 != null and pid3.4.2 != "" and pid3.4.2 != null and pid3.4.3 != "" and pid3.4.3 != null -%} + {% evaluate Organization_ID_pid_CX using 'ID/Organization' HDORG: pid3.4 -%} + {% include 'Resource/Organization', PID: pid3, ID: Organization_ID_pid_CX -%} + {% endif -%} + {% endfor -%} + {% if firstSegments.PID.4 -%} + {% if firstSegments.PID.4.4.1 != "" and firstSegments.PID.4.4.1 != null and firstSegments.PID.4.4.2 != "" and firstSegments.PID.4.4.2 != null and firstSegments.PID.4.4.3 != "" and firstSegments.PID.4.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_4 using 'ID/Organization' HDORG: firstSegments.PID.4.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.4, ID: Organization_ID_pid_CX_4 -%} + {% endif -%} + {% endif -%} + + {% unless nk1SegmentLists.NK1 -%} + {% if firstSegments.PID.21 -%} + {% if firstSegments.PID.21.4.1 != "" and firstSegments.PID.21.4.1 != null and firstSegments.PID.21.4.2 != "" and firstSegments.PID.21.4.2 != null and firstSegments.PID.21.4.3 != "" and firstSegments.PID.21.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_21 using 'ID/Organization' HDORG: firstSegments.PID.21.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.21, ID: Organization_ID_pid_CX_21 -%} + {% endif -%} + {% evaluate pidrelatedPersonId using 'ID/RelatedPerson' PID: firstSegments.PID, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: pidrelatedPersonId, PID: firstSegments.PID -%} + {% endif -%} + {% endunless -%} + {% if firstSegments.PD1.3 -%} + {% evaluate Organization_ID_PD1_3 using 'ID/Organization' XON: firstSegments.PD1.3 -%} + {% include 'Resource/Organization' PD1: firstSegments.PD1, ID: Organization_ID_PD1_3 -%} + {% endif -%} + + {% if firstSegments.PD1.4 -%} + {% if firstSegments.PD1.4.9.1 != "" and firstSegments.PD1.4.9.1 != null and firstSegments.PD1.4.9.2 != "" and firstSegments.PD1.4.9.2 != null and firstSegments.PD1.4.9.3 != "" and firstSegments.PD1.4.9.3 != null -%} + {% evaluate Organization_ID_PD1_4_9 using 'ID/Organization' HDORG: firstSegments.PD1.4.9 -%} + {% include 'Resource/Organization', PD1_4: firstSegments.PD1.4.9, ID: Organization_ID_PD1_4_9 -%} + {% endif -%} + {% evaluate Practitioner_ID_PD1_4 using 'ID/Practitioner' XCN: firstSegments.PD1.4 -%} + {% include 'Resource/Practitioner' PD1: firstSegments.PD1.4, ID: Practitioner_ID_PD1_4 -%} + {% endif -%} + + {% if firstSegments.PV1 -%} + {% if firstSegments.PV1.5 -%} + {% if firstSegments.PV1.5.4.1 != "" and firstSegments.PV1.5.4.1 != null and firstSegments.PV1.5.4.2 != "" and firstSegments.PV1.5.4.2 != null and firstSegments.PV1.5.4.3 != "" and firstSegments.PV1.5.4.3 != null -%} + {% evaluate Organization_ID_PV1_5_4 using 'ID/Organization' HDORG: firstSegments.PV1.5.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.5.4, ID: Organization_ID_PV1_5_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PV1.19 -%} + {% if firstSegments.PV1.19.4.1 != "" and firstSegments.PV1.19.4.1 != null and firstSegments.PV1.19.4.2 != "" and firstSegments.PV1.19.4.2 != null and firstSegments.PV1.19.4.3 != "" and firstSegments.PV1.19.4.3 != null -%} + {% evaluate Organization_ID_PV1_19_4 using 'ID/Organization' HDORG: firstSegments.PV1.19.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.19.4, ID: Organization_ID_PV1_19_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PV1.7 -%} + {% if firstSegments.PV1.7.9.1 != "" and firstSegments.PV1.7.9.1 != null and firstSegments.PV1.7.9.2 != "" and firstSegments.PV1.7.9.2 != null and firstSegments.PV1.7.9.3 != "" and firstSegments.PV1.7.9.3 != null -%} + {% evaluate Organization_ID_PV1_7_9 using 'ID/Organization' HDORG: firstSegments.PV1.7.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.7.9, ID: Organization_ID_PV1_7_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_7 using 'ID/Practitioner' XCN: firstSegments.PV1.7 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.7, ID: practitionerId_PV1_7 -%} + {% endif -%} + + {% if firstSegments.PV1.8 -%} + {% if firstSegments.PV1.8.9.1 != "" and firstSegments.PV1.8.9.1 != null and firstSegments.PV1.8.9.2 != "" and firstSegments.PV1.8.9.2 != null and firstSegments.PV1.8.9.3 != "" and firstSegments.PV1.8.9.3 != null -%} + {% evaluate Organization_ID_PV1_8_9 using 'ID/Organization' HDORG: firstSegments.PV1.8.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.8.9, ID: Organization_ID_PV1_8_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_8 using 'ID/Practitioner' XCN: firstSegments.PV1.8 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.8, ID: practitionerId_PV1_8 -%} + {% endif -%} + + {% if firstSegments.PV1.9 -%} + {% if firstSegments.PV1.9.9.1 != "" and firstSegments.PV1.9.9.1 != null and firstSegments.PV1.9.9.2 != "" and firstSegments.PV1.9.9.2 != null and firstSegments.PV1.9.9.3 != "" and firstSegments.PV1.9.9.3 != null -%} + {% evaluate Organization_ID_PV1_9_9 using 'ID/Organization' HDORG: firstSegments.PV1.9.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.9.9, ID: Organization_ID_PV1_9_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_9 using 'ID/Practitioner' XCN: firstSegments.PV1.9 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.9, ID: practitionerId_PV1_9 -%} + {% endif -%} + + {% if firstSegments.PV1.17 -%} + {% if firstSegments.PV1.17.9.1 != "" and firstSegments.PV1.17.9.1 != null and firstSegments.PV1.17.9.2 != "" and firstSegments.PV1.17.9.2 != null and firstSegments.PV1.17.9.3 != "" and firstSegments.PV1.17.9.3 != null -%} + {% evaluate Organization_ID_PV1_17_9 using 'ID/Organization' HDORG: firstSegments.PV1.17.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.17.9, ID: Organization_ID_PV1_17_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_17 using 'ID/Practitioner' XCN: firstSegments.PV1.17 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.17, ID: practitionerId_PV1_17 -%} + {% endif -%} + + {% if firstSegments.PV1.50 -%} + {% for p in firstSegments.PV1.50.Repeats -%} + {% if p.4.1 != "" and p.4.1 != null and p.4.2 != "" and p.4.2 != null and p.4.3 != "" and p.4.3 != null -%} + {% evaluate Organization_ID_PV1_50_4 using 'ID/Organization' HDORG: p.4 -%} + {% include 'Resource/Organization', PV1: p.4, ID: Organization_ID_PV1_50_4 -%} + {% endif -%} + {% endfor -%} + {% endif -%} + + {% if firstSegments.PV1.52 -%} + {% if firstSegments.PV1.52.9.1 != "" and firstSegments.PV1.52.9.1 != null and firstSegments.PV1.52.9.2 != "" and firstSegments.PV1.52.9.2 != null and firstSegments.PV1.52.9.3 != "" and firstSegments.PV1.52.9.3 != null -%} + {% evaluate Organization_ID_PV1_52_9 using 'ID/Organization' HDORG: firstSegments.PV1.52.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.52.9, ID: Organization_ID_PV1_52_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_52 using 'ID/Practitioner' XCN: firstSegments.PV1.52 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.52, ID: practitionerId_PV1_52 -%} + {% endif -%} + + {% if firstSegments.PV2.13 -%} + {% if firstSegments.PV2.13.9.1 != "" and firstSegments.PV2.13.9.1 != null and firstSegments.PV2.13.9.2 != "" and firstSegments.PV2.13.9.2 != null and firstSegments.PV2.13.9.3 != "" and firstSegments.PV2.13.9.3 != null -%} + {% evaluate Organization_ID_PV2_13_9 using 'ID/Organization' HDORG: firstSegments.PV2.13.9 -%} + {% include 'Resource/Organization', PV2: firstSegments.PV2.13.9, ID: Organization_ID_PV2_13_9 -%} + {% endif -%} + {% evaluate practitionerId_PV2_13 using 'ID/Practitioner' XCN: firstSegments.PV2.13 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV2.13, ID: practitionerId_PV2_13 -%} + {% endif -%} + + {% if firstSegments.PV1.3 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.3-%} + {% endif -%} + + {% if firstSegments.PV1.6 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.6 -%} + {% endif -%} + + {% if firstSegments.PV1.37 -%} + {% evaluate location_ID_PV1_37 using 'ID/Location' DLD: firstSegments.PV1.37 -%} + {% include 'Resource/Location' PV1: firstSegments.PV1.37, ID: location_ID_PV1_37-%} + {% endif -%} + + {% if firstSegments.PV1.43 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.43-%} + {% endif -%} + + {% comment -%} + + {% if firstSegments.PV1.42 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.42-%} + {% endif -%} + + {% if firstSegments.PV2.1 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV2.1-%} + {% endif -%} + {% endcomment -%} + + {% if firstSegments.PV1.54 -%} + {% if firstSegments.PV1.54.4.1 != "" and firstSegments.PV1.54.4.1 != null and firstSegments.PV1.54.4.2 != "" and firstSegments.PV1.54.4.2 != null and firstSegments.PV1.54.4.3 != "" and firstSegments.PV1.54.4.3 != null -%} + {% evaluate Organization_ID_PV1_54_4 using 'ID/Organization' HDORG: firstSegments.PV1.54.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.54.4, ID: Organization_ID_PV1_54_4 -%} + {% endif -%} + {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: firstSegments.PV1.54 -%} + {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId, Root_Template: 'ADT_A26' -%} + {% endif -%} + + {% evaluate encounterId using 'ID/Encounter' PV1: firstSegments.PV1, baseId: patientId -%} + {% include 'Resource/Encounter' Root_Template: 'ADT_A26', PV1: firstSegments.PV1, PV2: firstSegments.PV2, ID: encounterId -%} + {% include 'Reference/Encounter/Subject' ID: encounterId, REF: fullPatientId -%} + {% include 'Extensions/Encounter/EncounterExtension' ID: encounterId, PV1: firstSegments.PV1, PV2: firstSegments.PV2, -%} + {% endif -%} + + {% if firstSegments.EVN -%} + {% evaluate provenanceId using 'ID/Provenance' EVN: firstSegments.EVN, baseId: patientId -%} + {% include 'Resource/Provenance' EVN: firstSegments.EVN, EVNTEXT: firstSegments.MSH.9, REF_BUNDLE: bundleID, ID: provenanceId -%} + {% if firstSegments.EVN.5 -%} + {% if firstSegments.EVN.5.9.1 != "" and firstSegments.EVN.5.9.1 != null and firstSegments.EVN.5.9.2 != "" and firstSegments.EVN.5.9.2 != null and firstSegments.EVN.5.9.3 != "" and firstSegments.EVN.5.9.3 != null -%} + {% evaluate Organization_ID_EVN_5_9 using 'ID/Organization' HDORG: firstSegments.EVN.5.9 -%} + {% include 'Resource/Organization', EVN: firstSegments.EVN.5.9, ID: Organization_ID_EVN_5_9 -%} + {% endif -%} + {% evaluate practitionerId_EVN_5 using 'ID/Practitioner' XCN: firstSegments.EVN.5 -%} + {% include 'Resource/Practitioner' EVN: firstSegments.EVN.5, ID: practitionerId_EVN_5 -%} + {% if firstSegments.EVN.7 -%} + {% evaluate locationId_EVN_7 using 'ID/Location' HD: firstSegments.EVN.7 -%} + {% include 'Resource/Location' EVN: firstSegments.EVN.7, ID: locationId_EVN_7 -%} + {% endif -%} + {% endif -%} + {% endif -%} + + {% for db1Segment in db1SegmentLists.DB1 -%} + {% if db1Segment.2.1.Value == "PT" %} + {% for db in db1Segment.3.Repeats -%} + {% if db.4.1 != "" and db.4.1 != null and db.4.2 != "" and db.4.2 != null and db.4.3 != "" and db.4.3 != null -%} + {% evaluate Organization_ID_DB1_3 using 'ID/Organization' HDORG: db.4 -%} + {% include 'Resource/Organization', DB1: db.4, ID: Organization_ID_DB1_3 -%} + {% endif -%} + {% endfor %} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, DB1: db1Segment -%} + {% endif -%} + {% include 'Resource/Patient' DB1: db1Segment, ID: patientId -%} + {% endfor %} + + {% for obxSegment in obxSegmentLists.OBX -%} + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16 -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16 -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + {% if obxSegment.18 -%} + {% evaluate deviceId_OBX_18 using 'ID/Device' EI: obxSegment.18.Repeats[0] -%} + {% include 'Resource/Device' EI_OBX18: obxSegment.18, ID: deviceId_OBX_18 -%} + {% endif -%} + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23 -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + {% evaluate observationId using 'ID/Observation' OBX: obxSegment, baseId: patientId -%} + {% include 'Resource/Observation' OBX: obxSegment, Observation_Subject_ID: fullPatientId, ID: observationId -%} + {% include 'Extensions/Observation/ObservationExtension' OBX: obxSegment, ID: observationId %} + {% endfor -%} + + ] +} \ No newline at end of file diff --git a/data/Templates/Hl7v2/ADT_A27.liquid b/data/Templates/Hl7v2/ADT_A27.liquid new file mode 100644 index 000000000..284f537d2 --- /dev/null +++ b/data/Templates/Hl7v2/ADT_A27.liquid @@ -0,0 +1,316 @@ +{% assign firstSegments = hl7v2Data | get_first_segments: 'PID|PD1|PV1|PV2|UAC|EVN|MSH' -%} +{% assign obxSegmentLists = hl7v2Data | get_segment_lists: 'OBX' -%} +{% assign sftSegmentLists = hl7v2Data | get_segment_lists: 'SFT' -%} +{% assign db1SegmentLists = hl7v2Data | get_segment_lists: 'DB1' -%} +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} +{ + "resourceType": "Bundle", + "type": "batch", + {% if firstSegments.MSH.7 -%} + "timestamp":"{{ firstSegments.MSH.7.Value | format_as_date_time }}", + {% endif -%} + "identifier": + { + "value":"{{ firstSegments.MSH.10.Value }}", + }, + "id":"{{ bundleID }}", + "entry": [ + {% evaluate patientId using 'ID/Patient' PID: firstSegments.PID, type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% evaluate messageHeaderId using 'ID/MessageHeader' MSH: firstSegments.MSH -%} + + {% if firstSegments.MSH -%} + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, ID: messageHeaderId -%} + {% evaluate provenanceId using 'ID/Provenance' MSH: firstSegments.MSH, baseId: patientId -%} + {% include 'Resource/Provenance' Root_Template: 'ADT_A27', MSH: firstSegments.MSH, REF_BUNDLE: bundleID, ID: provenanceId -%} + + {%- comment -%} + {% assign transformation_val = 'provenance_transformation' %} + {% evaluate provenanceOrganizationId using 'ID/Organization', prov_id: firstSegments.MSH -%} + {% evaluate provenanceTransformationId using 'ID/Provenance_transformation' prov_id: transformation_val -%} + {% include 'Resource/Organization' org_name: 'Microsoft Corporation', ID: provenanceOrganizationId -%} + {% include 'Resource/Provenance_transformation' Root_Template: 'ADT_A27', Provenance_Organization_ID: provenanceOrganizationId, REF_MSH: messageHeaderId, provenanceOrganizationId, ID: provenanceTransformationId -%} + {%- endcomment -%} + {% if firstSegments.MSH.4 -%} + {% if firstSegments.MSH.4.1 != "" and firstSegments.MSH.4.1 != null or firstSegments.MSH.4.2 != "" and firstSegments.MSH.4.2 != null or firstSegments.MSH.4.3 != "" and firstSegments.MSH.4.3 != null -%} + {% evaluate organization_ID_MSH_4 using 'ID/Organization' HD: firstSegments.MSH.4 -%} + {% include 'Resource/Organization' MSHHD1: firstSegments.MSH.4, MSH: firstSegments.MSH, ID: organization_ID_MSH_4 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.6 %} + {% if firstSegments.MSH.6.1 != "" and firstSegments.MSH.6.1 != null or firstSegments.MSH.6.2 != "" and firstSegments.MSH.6.2 != null or firstSegments.MSH.6.3 != "" and firstSegments.MSH.6.3 != null -%} + {% evaluate organization_Id_MSH_6 using 'ID/Organization' HD: firstSegments.MSH.6 -%} + {% include 'Resource/Organization' MSHHD2: firstSegments.MSH.6, MSH: firstSegments.MSH, ID: organization_Id_MSH_6 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.22 %} + {% if firstSegments.MSH.22.1 != "" and firstSegments.MSH.22.1 != null -%} + {% evaluate organization_Id_MSH_22 using 'ID/Organization' XON: firstSegments.MSH.22 -%} + {% include 'Resource/Organization' MSHXON1: firstSegments.MSH.22, ID: organization_Id_MSH_22 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.23 %} + {% if firstSegments.MSH.23.1 != "" and firstSegments.MSH.23.1 != null -%} + {% evaluate organization_Id_MSH_23 using 'ID/Organization' XON: firstSegments.MSH.23 -%} + {% include 'Resource/Organization' MSHXON2: firstSegments.MSH.23, ID: organization_Id_MSH_23 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.3 and firstSegments.MSH.24 %} + {% evaluate device_Id_MSH_3 using 'ID/Device' HD: firstSegments.MSH.3 -%} + {% include 'Resource/Device' MSH: firstSegments.MSH, ID: device_Id_MSH_3 -%} + {% endif -%} + {% endif -%} + + {% for sftSegment in sftSegmentLists.SFT -%} + {% evaluate deviceId_SFT using 'ID/Device' SFT: sftSegment -%} + {% include 'Resource/Device' SFT:sftSegment, ID: deviceId_SFT -%} + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, SFT:sftSegment, ID: messageHeaderID -%} + {% endfor -%} + + {% include 'Resource/Patient' PID: firstSegments.PID, PD1: firstSegments.PD1, ID: patientId -%} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, PID: firstSegments.PID, PD1: firstSegments.PD1, PV1: firstSegments.PV1 -%} + + + {% if firstSegments.PID.18 -%} + {% evaluate accountId using 'ID/Account' CX: firstSegments.PID.3 -%} + {% include 'Resource/Account' PID: firstSegments.PID, ID: accountId -%} + {% include 'Reference/Account/Subject' ID: accountId, REF: fullPatientId -%} + {% if firstSegments.PID.18.4.1 != "" and firstSegments.PID.18.4.1 != null and firstSegments.PID.18.4.2 != "" and firstSegments.PID.18.4.2 != null and firstSegments.PID.18.4.3 != "" and firstSegments.PID.18.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_18 using 'ID/Organization' HDORG: firstSegments.PID.18.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.18, ID: Organization_ID_pid_CX_18 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PID.2 -%} + {% if firstSegments.PID.2.4.1 != "" and firstSegments.PID.2.4.1 != null and firstSegments.PID.2.4.2 != "" and firstSegments.PID.2.4.2 != null and firstSegments.PID.2.4.3 != "" and firstSegments.PID.2.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_2 using 'ID/Organization' HDORG: firstSegments.PID.2.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.2, ID: Organization_ID_pid_CX_2 -%} + {% endif -%} + {% endif -%} + {% for pid3 in firstSegments.PID.3.Repeats -%} + {% if pid3.4.1 != "" and pid3.4.1 != null and pid3.4.2 != "" and pid3.4.2 != null and pid3.4.3 != "" and pid3.4.3 != null -%} + {% evaluate Organization_ID_pid_CX using 'ID/Organization' HDORG: pid3.4 -%} + {% include 'Resource/Organization', PID: pid3, ID: Organization_ID_pid_CX -%} + {% endif -%} + {% endfor -%} + {% if firstSegments.PID.4 -%} + {% if firstSegments.PID.4.4.1 != "" and firstSegments.PID.4.4.1 != null and firstSegments.PID.4.4.2 != "" and firstSegments.PID.4.4.2 != null and firstSegments.PID.4.4.3 != "" and firstSegments.PID.4.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_4 using 'ID/Organization' HDORG: firstSegments.PID.4.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.4, ID: Organization_ID_pid_CX_4 -%} + {% endif -%} + {% endif -%} + + {% unless nk1SegmentLists.NK1 -%} + {% if firstSegments.PID.21 -%} + {% if firstSegments.PID.21.4.1 != "" and firstSegments.PID.21.4.1 != null and firstSegments.PID.21.4.2 != "" and firstSegments.PID.21.4.2 != null and firstSegments.PID.21.4.3 != "" and firstSegments.PID.21.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_21 using 'ID/Organization' HDORG: firstSegments.PID.21.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.21, ID: Organization_ID_pid_CX_21 -%} + {% endif -%} + {% evaluate pidrelatedPersonId using 'ID/RelatedPerson' PID: firstSegments.PID, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: pidrelatedPersonId, PID: firstSegments.PID -%} + {% endif -%} + {% endunless -%} + {% if firstSegments.PD1.3 -%} + {% evaluate Organization_ID_PD1_3 using 'ID/Organization' XON: firstSegments.PD1.3 -%} + {% include 'Resource/Organization' PD1: firstSegments.PD1, ID: Organization_ID_PD1_3 -%} + {% endif -%} + + {% if firstSegments.PD1.4 -%} + {% if firstSegments.PD1.4.9.1 != "" and firstSegments.PD1.4.9.1 != null and firstSegments.PD1.4.9.2 != "" and firstSegments.PD1.4.9.2 != null and firstSegments.PD1.4.9.3 != "" and firstSegments.PD1.4.9.3 != null -%} + {% evaluate Organization_ID_PD1_4_9 using 'ID/Organization' HDORG: firstSegments.PD1.4.9 -%} + {% include 'Resource/Organization', PD1_4: firstSegments.PD1.4.9, ID: Organization_ID_PD1_4_9 -%} + {% endif -%} + {% evaluate Practitioner_ID_PD1_4 using 'ID/Practitioner' XCN: firstSegments.PD1.4 -%} + {% include 'Resource/Practitioner' PD1: firstSegments.PD1.4, ID: Practitioner_ID_PD1_4 -%} + {% endif -%} + + {% if firstSegments.PV1 -%} + {% if firstSegments.PV1.5 -%} + {% if firstSegments.PV1.5.4.1 != "" and firstSegments.PV1.5.4.1 != null and firstSegments.PV1.5.4.2 != "" and firstSegments.PV1.5.4.2 != null and firstSegments.PV1.5.4.3 != "" and firstSegments.PV1.5.4.3 != null -%} + {% evaluate Organization_ID_PV1_5_4 using 'ID/Organization' HDORG: firstSegments.PV1.5.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.5.4, ID: Organization_ID_PV1_5_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PV1.19 -%} + {% if firstSegments.PV1.19.4.1 != "" and firstSegments.PV1.19.4.1 != null and firstSegments.PV1.19.4.2 != "" and firstSegments.PV1.19.4.2 != null and firstSegments.PV1.19.4.3 != "" and firstSegments.PV1.19.4.3 != null -%} + {% evaluate Organization_ID_PV1_19_4 using 'ID/Organization' HDORG: firstSegments.PV1.19.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.19.4, ID: Organization_ID_PV1_19_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PV1.7 -%} + {% if firstSegments.PV1.7.9.1 != "" and firstSegments.PV1.7.9.1 != null and firstSegments.PV1.7.9.2 != "" and firstSegments.PV1.7.9.2 != null and firstSegments.PV1.7.9.3 != "" and firstSegments.PV1.7.9.3 != null -%} + {% evaluate Organization_ID_PV1_7_9 using 'ID/Organization' HDORG: firstSegments.PV1.7.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.7.9, ID: Organization_ID_PV1_7_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_7 using 'ID/Practitioner' XCN: firstSegments.PV1.7 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.7, ID: practitionerId_PV1_7 -%} + {% endif -%} + + {% if firstSegments.PV1.8 -%} + {% if firstSegments.PV1.8.9.1 != "" and firstSegments.PV1.8.9.1 != null and firstSegments.PV1.8.9.2 != "" and firstSegments.PV1.8.9.2 != null and firstSegments.PV1.8.9.3 != "" and firstSegments.PV1.8.9.3 != null -%} + {% evaluate Organization_ID_PV1_8_9 using 'ID/Organization' HDORG: firstSegments.PV1.8.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.8.9, ID: Organization_ID_PV1_8_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_8 using 'ID/Practitioner' XCN: firstSegments.PV1.8 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.8, ID: practitionerId_PV1_8 -%} + {% endif -%} + + {% if firstSegments.PV1.9 -%} + {% if firstSegments.PV1.9.9.1 != "" and firstSegments.PV1.9.9.1 != null and firstSegments.PV1.9.9.2 != "" and firstSegments.PV1.9.9.2 != null and firstSegments.PV1.9.9.3 != "" and firstSegments.PV1.9.9.3 != null -%} + {% evaluate Organization_ID_PV1_9_9 using 'ID/Organization' HDORG: firstSegments.PV1.9.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.9.9, ID: Organization_ID_PV1_9_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_9 using 'ID/Practitioner' XCN: firstSegments.PV1.9 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.9, ID: practitionerId_PV1_9 -%} + {% endif -%} + + {% if firstSegments.PV1.17 -%} + {% if firstSegments.PV1.17.9.1 != "" and firstSegments.PV1.17.9.1 != null and firstSegments.PV1.17.9.2 != "" and firstSegments.PV1.17.9.2 != null and firstSegments.PV1.17.9.3 != "" and firstSegments.PV1.17.9.3 != null -%} + {% evaluate Organization_ID_PV1_17_9 using 'ID/Organization' HDORG: firstSegments.PV1.17.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.17.9, ID: Organization_ID_PV1_17_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_17 using 'ID/Practitioner' XCN: firstSegments.PV1.17 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.17, ID: practitionerId_PV1_17 -%} + {% endif -%} + + {% if firstSegments.PV1.50 -%} + {% for p in firstSegments.PV1.50.Repeats -%} + {% if p.4.1 != "" and p.4.1 != null and p.4.2 != "" and p.4.2 != null and p.4.3 != "" and p.4.3 != null -%} + {% evaluate Organization_ID_PV1_50_4 using 'ID/Organization' HDORG: p.4 -%} + {% include 'Resource/Organization', PV1: p.4, ID: Organization_ID_PV1_50_4 -%} + {% endif -%} + {% endfor -%} + {% endif -%} + + {% if firstSegments.PV1.52 -%} + {% if firstSegments.PV1.52.9.1 != "" and firstSegments.PV1.52.9.1 != null and firstSegments.PV1.52.9.2 != "" and firstSegments.PV1.52.9.2 != null and firstSegments.PV1.52.9.3 != "" and firstSegments.PV1.52.9.3 != null -%} + {% evaluate Organization_ID_PV1_52_9 using 'ID/Organization' HDORG: firstSegments.PV1.52.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.52.9, ID: Organization_ID_PV1_52_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_52 using 'ID/Practitioner' XCN: firstSegments.PV1.52 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.52, ID: practitionerId_PV1_52 -%} + {% endif -%} + + {% if firstSegments.PV2.13 -%} + {% if firstSegments.PV2.13.9.1 != "" and firstSegments.PV2.13.9.1 != null and firstSegments.PV2.13.9.2 != "" and firstSegments.PV2.13.9.2 != null and firstSegments.PV2.13.9.3 != "" and firstSegments.PV2.13.9.3 != null -%} + {% evaluate Organization_ID_PV2_13_9 using 'ID/Organization' HDORG: firstSegments.PV2.13.9 -%} + {% include 'Resource/Organization', PV2: firstSegments.PV2.13.9, ID: Organization_ID_PV2_13_9 -%} + {% endif -%} + {% evaluate practitionerId_PV2_13 using 'ID/Practitioner' XCN: firstSegments.PV2.13 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV2.13, ID: practitionerId_PV2_13 -%} + {% endif -%} + + {% if firstSegments.PV1.3 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.3-%} + {% endif -%} + + {% if firstSegments.PV1.6 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.6 -%} + {% endif -%} + + {% if firstSegments.PV1.37 -%} + {% evaluate location_ID_PV1_37 using 'ID/Location' DLD: firstSegments.PV1.37 -%} + {% include 'Resource/Location' PV1: firstSegments.PV1.37, ID: location_ID_PV1_37-%} + {% endif -%} + + {% if firstSegments.PV1.42 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.42-%} + {% endif -%} + + {% if firstSegments.PV1.43 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.43-%} + {% endif -%} + + {% if firstSegments.PV2.1 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV2.1-%} + {% endif -%} + + {% if firstSegments.PV1.54 -%} + {% if firstSegments.PV1.54.4.1 != "" and firstSegments.PV1.54.4.1 != null and firstSegments.PV1.54.4.2 != "" and firstSegments.PV1.54.4.2 != null and firstSegments.PV1.54.4.3 != "" and firstSegments.PV1.54.4.3 != null -%} + {% evaluate Organization_ID_PV1_54_4 using 'ID/Organization' HDORG: firstSegments.PV1.54.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.54.4, ID: Organization_ID_PV1_54_4 -%} + {% endif -%} + {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: firstSegments.PV1.54 -%} + {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId, Root_Template: 'ADT_A27' -%} + {% endif -%} + + {% evaluate encounterId using 'ID/Encounter' PV1: firstSegments.PV1, baseId: patientId -%} + {% include 'Resource/Encounter' Root_Template: 'ADT_A27', PV1: firstSegments.PV1, PV2: firstSegments.PV2, ID: encounterId -%} + {% include 'Reference/Encounter/Subject' ID: encounterId, REF: fullPatientId -%} + {% include 'Extensions/Encounter/EncounterExtension' ID: encounterId, PV1: firstSegments.PV1, PV2: firstSegments.PV2, -%} + {% endif -%} + + {% if firstSegments.EVN -%} + {% evaluate provenanceId using 'ID/Provenance' EVN: firstSegments.EVN, baseId: patientId -%} + {% include 'Resource/Provenance' EVN: firstSegments.EVN, EVNTEXT: firstSegments.MSH.9, REF_BUNDLE: bundleID, ID: provenanceId -%} + {% if firstSegments.EVN.5 -%} + {% if firstSegments.EVN.5.9.1 != "" and firstSegments.EVN.5.9.1 != null and firstSegments.EVN.5.9.2 != "" and firstSegments.EVN.5.9.2 != null and firstSegments.EVN.5.9.3 != "" and firstSegments.EVN.5.9.3 != null -%} + {% evaluate Organization_ID_EVN_5_9 using 'ID/Organization' HDORG: firstSegments.EVN.5.9 -%} + {% include 'Resource/Organization', EVN: firstSegments.EVN.5.9, ID: Organization_ID_EVN_5_9 -%} + {% endif -%} + {% evaluate practitionerId_EVN_5 using 'ID/Practitioner' XCN: firstSegments.EVN.5 -%} + {% include 'Resource/Practitioner' EVN: firstSegments.EVN.5, ID: practitionerId_EVN_5 -%} + {% if firstSegments.EVN.7 -%} + {% evaluate locationId_EVN_7 using 'ID/Location' HD: firstSegments.EVN.7 -%} + {% include 'Resource/Location' EVN: firstSegments.EVN.7, ID: locationId_EVN_7 -%} + {% endif -%} + {% endif -%} + {% endif -%} + + {% for db1Segment in db1SegmentLists.DB1 -%} + {% if db1Segment.2.1.Value == "PT" %} + {% for db in db1Segment.3.Repeats -%} + {% if db.4.1 != "" and db.4.1 != null and db.4.2 != "" and db.4.2 != null and db.4.3 != "" and db.4.3 != null -%} + {% evaluate Organization_ID_DB1_3 using 'ID/Organization' HDORG: db.4 -%} + {% include 'Resource/Organization', DB1: db.4, ID: Organization_ID_DB1_3 -%} + {% endif -%} + {% endfor %} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, DB1: db1Segment -%} + {% endif -%} + {% include 'Resource/Patient' DB1: db1Segment, ID: patientId -%} + {% endfor %} + + {% for obxSegment in obxSegmentLists.OBX -%} + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16 -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16 -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + {% if obxSegment.18 -%} + {% evaluate deviceId_OBX_18 using 'ID/Device' EI: obxSegment.18.Repeats[0] -%} + {% include 'Resource/Device' EI_OBX18: obxSegment.18, ID: deviceId_OBX_18 -%} + {% endif -%} + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23 -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + {% evaluate observationId using 'ID/Observation' OBX: obxSegment, baseId: patientId -%} + {% include 'Resource/Observation' OBX: obxSegment, Observation_Subject_ID: fullPatientId, ID: observationId -%} + {% include 'Extensions/Observation/ObservationExtension' OBX: obxSegment, ID: observationId %} + {% endfor -%} + + ] +} \ No newline at end of file diff --git a/data/Templates/Hl7v2/ADT_A28.liquid b/data/Templates/Hl7v2/ADT_A28.liquid index 023c6f9dd..cf13199a4 100644 --- a/data/Templates/Hl7v2/ADT_A28.liquid +++ b/data/Templates/Hl7v2/ADT_A28.liquid @@ -15,7 +15,6 @@ {% assign sftSegmentLists = hl7v2Data | get_segment_lists: 'SFT' -%} {% assign pr1SegmentLists = hl7v2Data | get_segment_lists: 'PR1' -%} {% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} - { "resourceType": "Bundle", "type": "batch", @@ -344,14 +343,8 @@ {% include 'Resource/Practitioner' PR1: pr1Segment.12, ID: practitionerId_PR1_12 -%} {% endif -%} - {% if pr1Segment.23.1 -%} - {% evaluate Location_ID_PR1_23_1 using 'ID/Location' PL: pr1Segment.23.1 -%} - {% include 'Resource/PLLocation' PL_1: pr1Segment.23.1, ID: Location_ID_PR1_23_1-%} - {% else %} - {% if pr1Segment.23.2 %} - {% evaluate Location_ID_PR1_23_2 using 'ID/Location' PL: pr1Segment.23.2 -%} - {% include 'Resource/PLLocation' PL_2: pr1Segment.23.2, ID: Location_ID_PR1_23_2-%} - {% endif %} + {% if pr1Segment.23 -%} + {% include 'Resource/PLLocation' PL: pr1Segment.23-%} {% endif %} {% if pr1Segment.25 -%} @@ -477,8 +470,8 @@ {% evaluate conditionId_DG1_22 using 'ID/Condition' DG1: dg1Segment.22, baseId: patientId -%} {% include 'Resource/Condition' DG1_22: dg1Segment.22, Condition_Subject_ID_DG1_22: fullPatientId, ID: conditionId_DG1_22 -%} {% endif -%} - {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} - + {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} + {% endfor -%} {% for rf1Segment in rf1SegmentLists.RF1 -%} diff --git a/data/Templates/Hl7v2/ADT_A29.liquid b/data/Templates/Hl7v2/ADT_A29.liquid new file mode 100644 index 000000000..3dfc73bcd --- /dev/null +++ b/data/Templates/Hl7v2/ADT_A29.liquid @@ -0,0 +1,315 @@ +{% assign firstSegments = hl7v2Data | get_first_segments: 'PID|PD1|PV1|PV2|UAC|EVN|MSH' -%} +{% assign obxSegmentLists = hl7v2Data | get_segment_lists: 'OBX' -%} +{% assign sftSegmentLists = hl7v2Data | get_segment_lists: 'SFT' -%} +{% assign db1SegmentLists = hl7v2Data | get_segment_lists: 'DB1' -%} +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} +{ + "resourceType": "Bundle", + "type": "batch", + {% if firstSegments.MSH.7 -%} + "timestamp":"{{ firstSegments.MSH.7.Value | format_as_date_time }}", + {% endif -%} + "identifier": + { + "value":"{{ firstSegments.MSH.10.Value }}", + }, + "id":"{{ bundleID }}", + "entry": [ + {% evaluate patientId using 'ID/Patient' PID: firstSegments.PID, type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% evaluate messageHeaderId using 'ID/MessageHeader' MSH: firstSegments.MSH -%} + + {% if firstSegments.MSH -%} + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, ID: messageHeaderId, Root_Template: 'ADT_A29' -%} + {% evaluate provenanceId using 'ID/Provenance' MSH: firstSegments.MSH, baseId: patientId -%} + {% include 'Resource/Provenance' Root_Template: 'ADT_A29', MSH: firstSegments.MSH, REF_BUNDLE: bundleID, ID: provenanceId, Root_Template_1: 'ADT_A29' -%} + + {%- comment -%} + {% assign transformation_val = 'provenance_transformation' %} + {% evaluate provenanceOrganizationId using 'ID/Organization', prov_id: firstSegments.MSH -%} + {% evaluate provenanceTransformationId using 'ID/Provenance_transformation' prov_id: transformation_val -%} + {% include 'Resource/Organization' org_name: 'Microsoft Corporation', ID: provenanceOrganizationId -%} + {% include 'Resource/Provenance_transformation' Root_Template: 'ADT_A29', Provenance_Organization_ID: provenanceOrganizationId, REF_MSH: messageHeaderId, provenanceOrganizationId, ID: provenanceTransformationId -%} + {%- endcomment -%} + {% if firstSegments.MSH.4 -%} + {% if firstSegments.MSH.4.1 != "" and firstSegments.MSH.4.1 != null or firstSegments.MSH.4.2 != "" and firstSegments.MSH.4.2 != null or firstSegments.MSH.4.3 != "" and firstSegments.MSH.4.3 != null -%} + {% evaluate organization_ID_MSH_4 using 'ID/Organization' HD: firstSegments.MSH.4 -%} + {% include 'Resource/Organization' MSHHD1: firstSegments.MSH.4, MSH: firstSegments.MSH, ID: organization_ID_MSH_4, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.6 %} + {% if firstSegments.MSH.6.1 != "" and firstSegments.MSH.6.1 != null or firstSegments.MSH.6.2 != "" and firstSegments.MSH.6.2 != null or firstSegments.MSH.6.3 != "" and firstSegments.MSH.6.3 != null -%} + {% evaluate organization_Id_MSH_6 using 'ID/Organization' HD: firstSegments.MSH.6 -%} + {% include 'Resource/Organization' MSHHD2: firstSegments.MSH.6, MSH: firstSegments.MSH, ID: organization_Id_MSH_6, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.22 %} + {% if firstSegments.MSH.22.1 != "" and firstSegments.MSH.22.1 != null -%} + {% evaluate organization_Id_MSH_22 using 'ID/Organization' XON: firstSegments.MSH.22 -%} + {% include 'Resource/Organization' MSHXON1: firstSegments.MSH.22, ID: organization_Id_MSH_22, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.23 %} + {% if firstSegments.MSH.23.1 != "" and firstSegments.MSH.23.1 != null -%} + {% evaluate organization_Id_MSH_23 using 'ID/Organization' XON: firstSegments.MSH.23 -%} + {% include 'Resource/Organization' MSHXON2: firstSegments.MSH.23, ID: organization_Id_MSH_23, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.3 and firstSegments.MSH.24 %} + {% evaluate device_Id_MSH_3 using 'ID/Device' HD: firstSegments.MSH.3 -%} + {% include 'Resource/Device' MSH: firstSegments.MSH, ID: device_Id_MSH_3, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% endif -%} + + {% for sftSegment in sftSegmentLists.SFT -%} + {% evaluate deviceId_SFT using 'ID/Device' SFT: sftSegment -%} + {% include 'Resource/Device' SFT:sftSegment, ID: deviceId_SFT, Root_Template: 'ADT_A29' -%} + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, SFT:sftSegment, ID: messageHeaderID, Root_Template: 'ADT_A29' -%} + {% endfor -%} + + {% include 'Resource/Patient' PID: firstSegments.PID, PD1: firstSegments.PD1, ID: patientId, Root_Template: 'ADT_A29' -%} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, PID: firstSegments.PID, PD1: firstSegments.PD1, PV1: firstSegments.PV1 -%} + + {% if firstSegments.PID.18 -%} + {% evaluate accountId using 'ID/Account' CX: firstSegments.PID.3 -%} + {% include 'Resource/Account' PID: firstSegments.PID, ID: accountId, Root_Template: 'ADT_A29' -%} + {% include 'Reference/Account/Subject' ID: accountId, REF: fullPatientId -%} + {% if firstSegments.PID.18.4.1 != "" and firstSegments.PID.18.4.1 != null and firstSegments.PID.18.4.2 != "" and firstSegments.PID.18.4.2 != null and firstSegments.PID.18.4.3 != "" and firstSegments.PID.18.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_18 using 'ID/Organization' HDORG: firstSegments.PID.18.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.18, ID: Organization_ID_pid_CX_18, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PID.2 -%} + {% if firstSegments.PID.2.4.1 != "" and firstSegments.PID.2.4.1 != null and firstSegments.PID.2.4.2 != "" and firstSegments.PID.2.4.2 != null and firstSegments.PID.2.4.3 != "" and firstSegments.PID.2.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_2 using 'ID/Organization' HDORG: firstSegments.PID.2.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.2, ID: Organization_ID_pid_CX_2, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% endif -%} + {% for pid3 in firstSegments.PID.3.Repeats -%} + {% if pid3.4.1 != "" and pid3.4.1 != null and pid3.4.2 != "" and pid3.4.2 != null and pid3.4.3 != "" and pid3.4.3 != null -%} + {% evaluate Organization_ID_pid_CX using 'ID/Organization' HDORG: pid3.4 -%} + {% include 'Resource/Organization', PID: pid3, ID: Organization_ID_pid_CX, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% endfor -%} + {% if firstSegments.PID.4 -%} + {% if firstSegments.PID.4.4.1 != "" and firstSegments.PID.4.4.1 != null and firstSegments.PID.4.4.2 != "" and firstSegments.PID.4.4.2 != null and firstSegments.PID.4.4.3 != "" and firstSegments.PID.4.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_4 using 'ID/Organization' HDORG: firstSegments.PID.4.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.4, ID: Organization_ID_pid_CX_4, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% endif -%} + + {% unless nk1SegmentLists.NK1 -%} + {% if firstSegments.PID.21 -%} + {% if firstSegments.PID.21.4.1 != "" and firstSegments.PID.21.4.1 != null and firstSegments.PID.21.4.2 != "" and firstSegments.PID.21.4.2 != null and firstSegments.PID.21.4.3 != "" and firstSegments.PID.21.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_21 using 'ID/Organization' HDORG: firstSegments.PID.21.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.21, ID: Organization_ID_pid_CX_21, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% evaluate pidrelatedPersonId using 'ID/RelatedPerson' PID: firstSegments.PID, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: pidrelatedPersonId, PID: firstSegments.PID, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% endunless -%} + {% if firstSegments.PD1.3 -%} + {% evaluate Organization_ID_PD1_3 using 'ID/Organization' XON: firstSegments.PD1.3 -%} + {% include 'Resource/Organization' PD1: firstSegments.PD1, ID: Organization_ID_PD1_3, Root_Template: 'ADT_A29' -%} + {% endif -%} + + {% if firstSegments.PD1.4 -%} + {% if firstSegments.PD1.4.9.1 != "" and firstSegments.PD1.4.9.1 != null and firstSegments.PD1.4.9.2 != "" and firstSegments.PD1.4.9.2 != null and firstSegments.PD1.4.9.3 != "" and firstSegments.PD1.4.9.3 != null -%} + {% evaluate Organization_ID_PD1_4_9 using 'ID/Organization' HDORG: firstSegments.PD1.4.9 -%} + {% include 'Resource/Organization', PD1_4: firstSegments.PD1.4.9, ID: Organization_ID_PD1_4_9, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% evaluate Practitioner_ID_PD1_4 using 'ID/Practitioner' XCN: firstSegments.PD1.4 -%} + {% include 'Resource/Practitioner' PD1: firstSegments.PD1.4, ID: Practitioner_ID_PD1_4, Root_Template: 'ADT_A29' -%} + {% endif -%} + + {% if firstSegments.PV1 -%} + {% if firstSegments.PV1.5 -%} + {% if firstSegments.PV1.5.4.1 != "" and firstSegments.PV1.5.4.1 != null and firstSegments.PV1.5.4.2 != "" and firstSegments.PV1.5.4.2 != null and firstSegments.PV1.5.4.3 != "" and firstSegments.PV1.5.4.3 != null -%} + {% evaluate Organization_ID_PV1_5_4 using 'ID/Organization' HDORG: firstSegments.PV1.5.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.5.4, ID: Organization_ID_PV1_5_4, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PV1.19 -%} + {% if firstSegments.PV1.19.4.1 != "" and firstSegments.PV1.19.4.1 != null and firstSegments.PV1.19.4.2 != "" and firstSegments.PV1.19.4.2 != null and firstSegments.PV1.19.4.3 != "" and firstSegments.PV1.19.4.3 != null -%} + {% evaluate Organization_ID_PV1_19_4 using 'ID/Organization' HDORG: firstSegments.PV1.19.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.19.4, ID: Organization_ID_PV1_19_4, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PV1.7 -%} + {% if firstSegments.PV1.7.9.1 != "" and firstSegments.PV1.7.9.1 != null and firstSegments.PV1.7.9.2 != "" and firstSegments.PV1.7.9.2 != null and firstSegments.PV1.7.9.3 != "" and firstSegments.PV1.7.9.3 != null -%} + {% evaluate Organization_ID_PV1_7_9 using 'ID/Organization' HDORG: firstSegments.PV1.7.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.7.9, ID: Organization_ID_PV1_7_9, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% evaluate practitionerId_PV1_7 using 'ID/Practitioner' XCN: firstSegments.PV1.7 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.7, ID: practitionerId_PV1_7, Root_Template: 'ADT_A29' -%} + {% endif -%} + + {% if firstSegments.PV1.8 -%} + {% if firstSegments.PV1.8.9.1 != "" and firstSegments.PV1.8.9.1 != null and firstSegments.PV1.8.9.2 != "" and firstSegments.PV1.8.9.2 != null and firstSegments.PV1.8.9.3 != "" and firstSegments.PV1.8.9.3 != null -%} + {% evaluate Organization_ID_PV1_8_9 using 'ID/Organization' HDORG: firstSegments.PV1.8.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.8.9, ID: Organization_ID_PV1_8_9, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% evaluate practitionerId_PV1_8 using 'ID/Practitioner' XCN: firstSegments.PV1.8 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.8, ID: practitionerId_PV1_8, Root_Template: 'ADT_A29' -%} + {% endif -%} + + {% if firstSegments.PV1.9 -%} + {% if firstSegments.PV1.9.9.1 != "" and firstSegments.PV1.9.9.1 != null and firstSegments.PV1.9.9.2 != "" and firstSegments.PV1.9.9.2 != null and firstSegments.PV1.9.9.3 != "" and firstSegments.PV1.9.9.3 != null -%} + {% evaluate Organization_ID_PV1_9_9 using 'ID/Organization' HDORG: firstSegments.PV1.9.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.9.9, ID: Organization_ID_PV1_9_9, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% evaluate practitionerId_PV1_9 using 'ID/Practitioner' XCN: firstSegments.PV1.9 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.9, ID: practitionerId_PV1_9, Root_Template: 'ADT_A29' -%} + {% endif -%} + + {% if firstSegments.PV1.17 -%} + {% if firstSegments.PV1.17.9.1 != "" and firstSegments.PV1.17.9.1 != null and firstSegments.PV1.17.9.2 != "" and firstSegments.PV1.17.9.2 != null and firstSegments.PV1.17.9.3 != "" and firstSegments.PV1.17.9.3 != null -%} + {% evaluate Organization_ID_PV1_17_9 using 'ID/Organization' HDORG: firstSegments.PV1.17.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.17.9, ID: Organization_ID_PV1_17_9, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% evaluate practitionerId_PV1_17 using 'ID/Practitioner' XCN: firstSegments.PV1.17 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.17, ID: practitionerId_PV1_17, Root_Template: 'ADT_A29' -%} + {% endif -%} + + {% if firstSegments.PV1.50 -%} + {% for p in firstSegments.PV1.50.Repeats -%} + {% if p.4.1 != "" and p.4.1 != null and p.4.2 != "" and p.4.2 != null and p.4.3 != "" and p.4.3 != null -%} + {% evaluate Organization_ID_PV1_50_4 using 'ID/Organization' HDORG: p.4 -%} + {% include 'Resource/Organization', PV1: p.4, ID: Organization_ID_PV1_50_4, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% endfor -%} + {% endif -%} + + {% if firstSegments.PV1.52 -%} + {% if firstSegments.PV1.52.9.1 != "" and firstSegments.PV1.52.9.1 != null and firstSegments.PV1.52.9.2 != "" and firstSegments.PV1.52.9.2 != null and firstSegments.PV1.52.9.3 != "" and firstSegments.PV1.52.9.3 != null -%} + {% evaluate Organization_ID_PV1_52_9 using 'ID/Organization' HDORG: firstSegments.PV1.52.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.52.9, ID: Organization_ID_PV1_52_9, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% evaluate practitionerId_PV1_52 using 'ID/Practitioner' XCN: firstSegments.PV1.52 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.52, ID: practitionerId_PV1_52, Root_Template: 'ADT_A29' -%} + {% endif -%} + + {% if firstSegments.PV2.13 -%} + {% if firstSegments.PV2.13.9.1 != "" and firstSegments.PV2.13.9.1 != null and firstSegments.PV2.13.9.2 != "" and firstSegments.PV2.13.9.2 != null and firstSegments.PV2.13.9.3 != "" and firstSegments.PV2.13.9.3 != null -%} + {% evaluate Organization_ID_PV2_13_9 using 'ID/Organization' HDORG: firstSegments.PV2.13.9 -%} + {% include 'Resource/Organization', PV2: firstSegments.PV2.13.9, ID: Organization_ID_PV2_13_9, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% evaluate practitionerId_PV2_13 using 'ID/Practitioner' XCN: firstSegments.PV2.13 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV2.13, ID: practitionerId_PV2_13, Root_Template: 'ADT_A29' -%} + {% endif -%} + + {% if firstSegments.PV1.3 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.3, Root_Template: 'ADT_A29' -%} + {% endif -%} + + {% if firstSegments.PV1.6 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.6, Root_Template: 'ADT_A29' -%} + {% endif -%} + + {% if firstSegments.PV1.37 -%} + {% evaluate location_ID_PV1_37 using 'ID/Location' DLD: firstSegments.PV1.37 -%} + {% include 'Resource/Location' PV1: firstSegments.PV1.37, ID: location_ID_PV1_37, Root_Template: 'ADT_A29' -%} + {% endif -%} + + {% if firstSegments.PV1.42 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.42, Root_Template: 'ADT_A29' -%} + {% endif -%} + + {% if firstSegments.PV1.43 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.43, Root_Template: 'ADT_A29' -%} + {% endif -%} + + {% if firstSegments.PV2.1 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV2.1, Root_Template: 'ADT_A29' -%} + {% endif -%} + + {% if firstSegments.PV1.54 -%} + {% if firstSegments.PV1.54.4.1 != "" and firstSegments.PV1.54.4.1 != null and firstSegments.PV1.54.4.2 != "" and firstSegments.PV1.54.4.2 != null and firstSegments.PV1.54.4.3 != "" and firstSegments.PV1.54.4.3 != null -%} + {% evaluate Organization_ID_PV1_54_4 using 'ID/Organization' HDORG: firstSegments.PV1.54.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.54.4, ID: Organization_ID_PV1_54_4, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: firstSegments.PV1.54 -%} + {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId, Root_Template: 'ADT_A29' -%} + {% endif -%} + + {% evaluate encounterId using 'ID/Encounter' PV1: firstSegments.PV1, baseId: patientId -%} + {% include 'Resource/Encounter' Root_Template: 'ADT_A29', PV1: firstSegments.PV1, PV2: firstSegments.PV2, ID: encounterId -%} + {% include 'Reference/Encounter/Subject' ID: encounterId, REF: fullPatientId -%} + {% include 'Extensions/Encounter/EncounterExtension' ID: encounterId, PV1: firstSegments.PV1, PV2: firstSegments.PV2, -%} + {% endif -%} + + {% if firstSegments.EVN -%} + {% evaluate provenanceId using 'ID/Provenance' EVN: firstSegments.EVN, baseId: patientId -%} + {% include 'Resource/Provenance' EVN: firstSegments.EVN, EVNTEXT: firstSegments.MSH.9, REF_BUNDLE: bundleID, ID: provenanceId, Root_Template_1: 'ADT_A29' -%} + {% if firstSegments.EVN.5 -%} + {% if firstSegments.EVN.5.9.1 != "" and firstSegments.EVN.5.9.1 != null and firstSegments.EVN.5.9.2 != "" and firstSegments.EVN.5.9.2 != null and firstSegments.EVN.5.9.3 != "" and firstSegments.EVN.5.9.3 != null -%} + {% evaluate Organization_ID_EVN_5_9 using 'ID/Organization' HDORG: firstSegments.EVN.5.9 -%} + {% include 'Resource/Organization', EVN: firstSegments.EVN.5.9, ID: Organization_ID_EVN_5_9, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% evaluate practitionerId_EVN_5 using 'ID/Practitioner' XCN: firstSegments.EVN.5 -%} + {% include 'Resource/Practitioner' EVN: firstSegments.EVN.5, ID: practitionerId_EVN_5, Root_Template: 'ADT_A29' -%} + {% if firstSegments.EVN.7 -%} + {% evaluate locationId_EVN_7 using 'ID/Location' HD: firstSegments.EVN.7 -%} + {% include 'Resource/Location' EVN: firstSegments.EVN.7, ID: locationId_EVN_7, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% endif -%} + {% endif -%} + + {% for db1Segment in db1SegmentLists.DB1 -%} + {% if db1Segment.2.1.Value == "PT" %} + {% for db in db1Segment.3.Repeats -%} + {% if db.4.1 != "" and db.4.1 != null and db.4.2 != "" and db.4.2 != null and db.4.3 != "" and db.4.3 != null -%} + {% evaluate Organization_ID_DB1_3 using 'ID/Organization' HDORG: db.4 -%} + {% include 'Resource/Organization', DB1: db.4, ID: Organization_ID_DB1_3, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% endfor %} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, DB1: db1Segment -%} + {% endif -%} + {% include 'Resource/Patient' DB1: db1Segment, ID: patientId, Root_Template: 'ADT_A29' -%} + {% endfor %} + + {% for obxSegment in obxSegmentLists.OBX -%} + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16, Root_Template: 'ADT_A29' -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16, Root_Template: 'ADT_A29' -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + {% if obxSegment.18 -%} + {% evaluate deviceId_OBX_18 using 'ID/Device' EI: obxSegment.18.Repeats[0] -%} + {% include 'Resource/Device' EI_OBX18: obxSegment.18, ID: deviceId_OBX_18, Root_Template: 'ADT_A29' -%} + {% endif -%} + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25, Root_Template: 'ADT_A29' -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25, Root_Template: 'ADT_A29' -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23, Root_Template: 'ADT_A29' -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + {% evaluate observationId using 'ID/Observation' OBX: obxSegment, baseId: patientId -%} + {% include 'Resource/Observation' OBX: obxSegment, Observation_Subject_ID: fullPatientId, ID: observationId, Root_Template: 'ADT_A29' -%} + {% include 'Extensions/Observation/ObservationExtension' OBX: obxSegment, ID: observationId %} + {% endfor -%} + + ] +} \ No newline at end of file diff --git a/data/Templates/Hl7v2/ADT_A31.liquid b/data/Templates/Hl7v2/ADT_A31.liquid index ac83c2823..731d86135 100644 --- a/data/Templates/Hl7v2/ADT_A31.liquid +++ b/data/Templates/Hl7v2/ADT_A31.liquid @@ -345,14 +345,8 @@ {% include 'Resource/Practitioner' PR1: pr1Segment.12, ID: practitionerId_PR1_12 -%} {% endif -%} - {% if pr1Segment.23.1 -%} - {% evaluate Location_ID_PR1_23_1 using 'ID/Location' PL: pr1Segment.23.1 -%} - {% include 'Resource/PLLocation' PL_1: pr1Segment.23.1, ID: Location_ID_PR1_23_1-%} - {% else %} - {% if pr1Segment.23.2 %} - {% evaluate Location_ID_PR1_23_2 using 'ID/Location' PL: pr1Segment.23.2 -%} - {% include 'Resource/PLLocation' PL_2: pr1Segment.23.2, ID: Location_ID_PR1_23_2-%} - {% endif %} + {% if pr1Segment.23 -%} + {% include 'Resource/PLLocation' PL: pr1Segment.23-%} {% endif %} {% if pr1Segment.25 -%} @@ -478,8 +472,8 @@ {% evaluate conditionId_DG1_22 using 'ID/Condition' DG1: dg1Segment.22, baseId: patientId -%} {% include 'Resource/Condition' DG1_22: dg1Segment.22, Condition_Subject_ID_DG1_22: fullPatientId, ID: conditionId_DG1_22 -%} {% endif -%} - {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} - + {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} + {% endfor -%} {% for rf1Segment in rf1SegmentLists.RF1 -%} diff --git a/data/Templates/Hl7v2/CodeSystem/CodeSystem.json b/data/Templates/Hl7v2/CodeSystem/CodeSystem.json index 1a060f3e2..0ea369d43 100644 --- a/data/Templates/Hl7v2/CodeSystem/CodeSystem.json +++ b/data/Templates/Hl7v2/CodeSystem/CodeSystem.json @@ -1573,6 +1573,48 @@ "system": "http://hl7.org/fhir/specimen-status" } }, + "CodeSystem/SpecimenCondition": { + "AUT": { + "code": "AUT", + "system": "http://terminology.hl7.org/CodeSystem/v2-0493" + }, + "CFU": { + "code": "CFU", + "system": "http://terminology.hl7.org/CodeSystem/v2-0493" + }, + "LIVE": { + "code": "LIVE", + "system": "http://terminology.hl7.org/CodeSystem/v2-0493" + }, + "CLOT": { + "code": "CLOT", + "system": "http://terminology.hl7.org/CodeSystem/v2-0493" + }, + "CON": { + "code": "CON", + "system": "http://terminology.hl7.org/CodeSystem/v2-0493" + }, + "COOL": { + "code": "COOL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0493" + }, + "FROZ": { + "code": "FROZ", + "system": "http://terminology.hl7.org/CodeSystem/v2-0493" + }, + "HEM": { + "code": "HEM", + "system": "http://terminology.hl7.org/CodeSystem/v2-0493" + }, + "ROOM": { + "code": "ROOM", + "system": "http://terminology.hl7.org/CodeSystem/v2-0493" + }, + "SNR": { + "code": "SNR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0493" + } + }, "CodeSystem/SecurityLabelHandlingInstructions": {}, "CodeSystem/Yes_No": { "Y": { @@ -2250,7 +2292,63 @@ "system": "http://terminology.hl7.org/CodeSystem/v2-0131" } }, - "CodeSystem/DurationUnit": {}, + "CodeSystem/DurationUnit": { + "s": { + "code": "s", + "display": "second", + "system": "http://unitsofmeasure.org" + }, + "Min": { + "code": "min", + "display": "minute", + "system": "http://unitsofmeasure.org" + }, + "Hr": { + "code": "h", + "display": "hour", + "system": "http://unitsofmeasure.org" + }, + "d": { + "code": "d", + "display": "day", + "system": "http://unitsofmeasure.org" + }, + "wk": { + "code": "wk", + "display": "week", + "system": "http://unitsofmeasure.org" + }, + "mo": { + "code": "mo", + "display": "month", + "system": "http://unitsofmeasure.org" + }, + "yr": { + "code": "a", + "display": "year", + "system": "http://unitsofmeasure.org" + }, + "ann": { + "code": "a", + "display": "year", + "system": "http://unitsofmeasure.org" + }, + "sec": { + "code": "s", + "display": "second", + "system": "http://unitsofmeasure.org" + }, + "min": { + "code": "min", + "display": "minute", + "system": "http://unitsofmeasure.org" + }, + "hr": { + "code": "h", + "display": "hour", + "system": "http://unitsofmeasure.org" + } + }, "CodeSystem/AllergyType": { "AA": { "code": "allergy", @@ -3209,63 +3307,262 @@ "system": "http://terminology.hl7.org/CodeSystem/v2-0315" } }, + "CodeSystem/DiagnosticReportStatus": { + "C": { + "code": "corrected", + "system": "http://hl7.org/fhir/diagnostic-report-status" + }, + "D": { + "code": "cancelled", + "system": "http://hl7.org/fhir/diagnostic-report-status" + }, + "F": { + "code": "final", + "system": "http://hl7.org/fhir/diagnostic-report-status" + }, + "I": { + "code": "preliminary", + "system": "http://hl7.org/fhir/diagnostic-report-status" + }, + "N": { + "code": "unknown" + }, + "O": { + "code": "unknown" + }, + "P": { + "code": "preliminary", + "system": "http://hl7.org/fhir/diagnostic-report-status" + }, + "S": { + "code": "partial", + "system": "http://hl7.org/fhir/diagnostic-report-status" + }, + "R": { + "code": "unknown" + }, + "X": { + "code": "cancelled", + "system": "http://hl7.org/fhir/diagnostic-report-status" + }, + "U": { + "code": "unknown" + }, + "W": { + "code": "entered-in-error", + "system": "http://hl7.org/fhir/diagnostic-report-status" + } + }, "CodeSystem/ResultStatus": { "A": { "code": "partial", - "display": "Partial", "system": "http://hl7.org/fhir/diagnostic-report-status" }, "C": { - "code": "corrected", - "display": "Corrected", + "code": "corrected", "system": "http://hl7.org/fhir/diagnostic-report-status" }, "F": { "code": "final", - "display": "Final", "system": "http://hl7.org/fhir/diagnostic-report-status" }, "I": { "code": "registered", - "display": "Registered", "system": "http://hl7.org/fhir/diagnostic-report-status" }, "O": { "code": "registered", - "display": "Registered", "system": "http://hl7.org/fhir/diagnostic-report-status" }, "P": { "code": "preliminary", - "display": "Preliminary", "system": "http://hl7.org/fhir/diagnostic-report-status" }, "S": { "code": "registered", - "display": "Registered", "system": "http://hl7.org/fhir/diagnostic-report-status" }, "R": { "code": "partial", - "display": "Partial", "system": "http://hl7.org/fhir/diagnostic-report-status" }, "Y": { - "code": "", - "display": "", - "system": "" + "code": "unknown", + "system": "http://hl7.org/fhir/diagnostic-report-status" }, "X": { "code": "cancelled", - "display": "Cancelled", "system": "http://hl7.org/fhir/diagnostic-report-status" }, "Z": { - "code": "", - "display": "", - "system": "" + "code": "unknown", + "system": "http://hl7.org/fhir/diagnostic-report-status" } }, + + "CodeSystem/DiagnosticServiceSection": { + "AU": { + "code": "AU", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "BG": { + "code": "BG", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "BLB": { + "code": "BLB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "CG": { + "code": "CG", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "CUS": { + "code": "CUS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "CTH": { + "code": "CTH", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "CT": { + "code": "CH", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "CP": { + "code": "CP", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "EC": { + "code": "EC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "EN": { + "code": "EN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "GE": { + "code": "GE", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "HM": { + "code": "HM", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "ICU": { + "code": "ICU", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "IMM": { + "code": "IMM", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "LAB": { + "code": "LAB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "MB": { + "code": "MB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "MCB": { + "code": "MCB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "MYC": { + "code": "MYC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "NMS": { + "code": "NMS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "NMR": { + "code": "NMR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "NRS": { + "code": "NRS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "OUS": { + "code": "OUS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "OT": { + "code": "OT", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "OTH": { + "code": "OTH", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "OSL": { + "code": "OSL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "PHR": { + "code": "PHR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "PT": { + "code": "PT", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "PHY": { + "code": "PHY", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "PF": { + "code": "PF", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "RAD": { + "code": "RAD", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "RX": { + "code": "RX", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "RUS": { + "code": "RUS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "RC": { + "code": "RC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "RT": { + "code": "RT", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "SR": { + "code": "SR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "SP": { + "code": "SP", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "TX": { + "code": "TX", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "VUS": { + "code": "VUS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "VR": { + "code": "VR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + }, + "VXC": { + "code": "VXC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + } + }, + "CodeSystem/ConsentRelationship": { "3": { "code": "N", @@ -4038,6 +4335,53 @@ "system": "http://hl7.org/fhir/encounter-status" } }, + "CodeSystem/EpisodeOfCareStatus": { + "E": { + "code": "active", + "display": "Active", + "system": "http://hl7.org/fhir/encounter-status" + }, + "I": { + "code": "active", + "display": "Active", + "system": "http://hl7.org/fhir/encounter-status" + }, + "O": { + "code": "active", + "display": "Active", + "system": "http://hl7.org/fhir/encounter-status" + }, + "P": { + "code": "planned", + "display": "Planned", + "system": "http://hl7.org/fhir/encounter-status" + }, + "R": { + "code": "active", + "display": "Active", + "system": "http://hl7.org/fhir/encounter-status" + }, + "B": { + "code": "active", + "display": "Active", + "system": "http://hl7.org/fhir/encounter-status" + }, + "C": { + "code": "active", + "display": "Active", + "system": "http://hl7.org/fhir/encounter-status" + }, + "N": { + "code": "cancelled", + "display": "Cancelled", + "system": "http://hl7.org/fhir/encounter-status" + }, + "U": { + "code": "", + "display": "", + "system": "http://hl7.org/fhir/encounter-status" + } + }, "CodeSystem/AllergyIntoleranceCriticality": { "SV": { "code" : "high", @@ -4796,6 +5140,533 @@ "display" : "Grandparent", "system" : "http://terminology.hl7.org/CodeSystem/v2-0344" } + }, + "CodeSystem/FillerStatusServiceRequestStatus": { + "Pending" : { + "code" : "draft", + "display" : "Draft", + "system" : "http://hl7.org/fhir/request-status" + }, + "Waitlist" : { + "code" : "draft", + "display" : "Draft", + "system" : "http://hl7.org/fhir/request-status" + }, + "Booked" : { + "code" : "active", + "display" : "Active", + "system" : "http://hl7.org/fhir/request-status" + }, + "Started" : { + "code" : "active", + "display" : "Active", + "system" : "http://hl7.org/fhir/request-status" + }, + "Complete" : { + "code" : "completed", + "display" : "Completed", + "system" : "http://hl7.org/fhir/request-status" + }, + "Cancelled" : { + "code" : "revoked", + "display" : "Revoked", + "system" : "http://hl7.org/fhir/request-status" + }, + "Dc" : { + "code" : "revoked", + "display" : "Revoked", + "system" : "http://hl7.org/fhir/request-status" + }, + "Deleted" : { + "code" : "entered-in-error", + "display" : "Entered In Error", + "system" : "http://hl7.org/fhir/request-status" + }, + "Blocked" : { + "code" : "draft", + "display" : "Draft", + "system" : "http://hl7.org/fhir/request-status" + }, + "Overbook" : { + "code" : "draft", + "display" : "Draft", + "system" : "http://hl7.org/fhir/request-status" + }, + "Noshow" : { + "code" : "revoked", + "display" : "Revoked", + "system" : "http://hl7.org/fhir/request-status" + } + }, + "CodeSystem/FillerStatusAppointmentParticipantStatus": { + "Pending" : { + "code" : "tentative", + "display" : "Tentative", + "system" : "http://hl7.org/fhir/participationstatus" + }, + "Waitlist" : { + "code" : "tentative", + "display" : "Tentative", + "system" : "http://hl7.org/fhir/participationstatus" + }, + "Booked" : { + "code" : "accepted", + "display" : "Accepted", + "system" : "http://hl7.org/fhir/participationstatus" + }, + "Started" : { + "code" : "accepted", + "display" : "Accepted", + "system" : "http://hl7.org/fhir/participationstatus" + }, + "Complete" : { + "code" : "accepted", + "display" : "Accepted", + "system" : "http://hl7.org/fhir/participationstatus" + }, + "Cancelled" : { + "code" : "declined", + "display" : "Declined", + "system" : "http://hl7.org/fhir/participationstatus" + }, + "Dc" : { + "code" : "declined", + "display" : "Declined", + "system" : "http://hl7.org/fhir/participationstatus" + }, + "Deleted" : { + "code" : "declined", + "display" : "Declined", + "system" : "http://hl7.org/fhir/participationstatus" + }, + "Blocked" : { + "code" : "needs-action", + "display" : "Needs Action", + "system" : "http://hl7.org/fhir/participationstatus" + }, + "Overbook" : { + "code" : "needs-action", + "display" : "Needs Action", + "system" : "http://hl7.org/fhir/participationstatus" + }, + "Noshow" : { + "code" : "declined", + "display" : "Declined", + "system" : "http://hl7.org/fhir/participationstatus" + } + }, + "CodeSystem/LocationRoleType": { + "C" : { + "code" : "C", + "display" : "Clinic", + "system" : "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + }, + "D" : { + "code" : "D", + "display" : "Department", + "system" : "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + }, + "H" : { + "code" : "H", + "display" : "Home", + "system" : "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + }, + "N" : { + "code" : "N", + "display" : "Nursing Unit", + "system" : "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + }, + "O" : { + "code" : "PROFF", + "display" : "Provider's Office", + "system" : "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + }, + "P" : { + "code" : "P", + "display" : "Phone", + "system" : "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + }, + "S" : { + "code" : "SNF", + "display" : "Skilled nursing facility", + "system" : "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + }, + "CodeSystem/AppointmentType": { + "ROUTINE" : { + "code" : "ROUTINE", + "display" : "Routine appointment - default if not valued", + "system" : "http://terminology.hl7.org/CodeSystem/v2-0276" + }, + "WALKIN" : { + "code" : "WALKIN", + "display" : "A previously unscheduled walk-in visit", + "system" : "http://terminology.hl7.org/CodeSystem/v2-0276" + }, + "CHECKUP" : { + "code" : "CHECKUP", + "display" : "A routine check-up, such as an annual physical", + "system" : "http://terminology.hl7.org/CodeSystem/v2-0276" + }, + "FOLLOWUP" : { + "code" : "FOLLOWUP", + "display" : "A follow up visit from a previous appointment", + "system" : "http://terminology.hl7.org/CodeSystem/v2-0276" + }, + "EMERGENCY" : { + "code" : "EMERGENCY", + "display" : "Emergency appointment", + "system" : "http://terminology.hl7.org/CodeSystem/v2-0276" + } + }, + "CodeSystem/FillerStatus" : { + "Pending" : { + "code" : "pending", + "display" : "Proposed", + "system" : "http://hl7.org/fhir/R4/codesystem-appointmentstatus.html" + }, + "Waitlist" : { + "code" : "waitlist", + "display" : "Waitlisted", + "system" : "http://hl7.org/fhir/R4/codesystem-appointmentstatus.html" + }, + "Booked" : { + "code" : "booked", + "display" : "Booked", + "system" : "http://hl7.org/fhir/R4/codesystem-appointmentstatus.html" + }, + "Started" : { + "code" : "checked-in", + "display" : "Checked In", + "system" : "http://hl7.org/fhir/R4/codesystem-appointmentstatus.html" + }, + "Complete" : { + "code" : "fulfilled", + "display" : "Fulfilled", + "system" : "http://hl7.org/fhir/R4/codesystem-appointmentstatus.html" + }, + "Cancelled" : { + "code" : "cancelled", + "display" : "Cancelled", + "system" : "http://hl7.org/fhir/R4/codesystem-appointmentstatus.html" + }, + "Dc" : { + "code" : "cancelled", + "display" : "Cancelled", + "system" : "http://hl7.org/fhir/R4/codesystem-appointmentstatus.html" + }, + "Deleted" : { + "code" : "entered-in-error", + "display" : "Entered In Error", + "system" : "http://hl7.org/fhir/R4/codesystem-appointmentstatus.html" + }, + "Blocked" : { + "code" : "waitlist", + "display" : "Waitlisted", + "system" : "http://hl7.org/fhir/R4/codesystem-appointmentstatus.html" + }, + "Overbook" : { + "code" : "waitlist", + "display" : "Waitlisted", + "system" : "http://hl7.org/fhir/R4/codesystem-appointmentstatus.html" + }, + "Noshow" : { + "code" : "noshow", + "display" : "No Show", + "system" : "http://hl7.org/fhir/R4/codesystem-appointmentstatus.html" + } + }, + "CodeSystem/DocumentAvailabilityStatus" : { + "AV" : { + "code" : "current", + "display" : "Current", + "system" : "http://hl7.org/fhir/document-reference-status" + }, + "CA" : { + "code" : "entered-in-error", + "display" : "Entered in Error", + "system" : "http://hl7.org/fhir/document-reference-status" + }, + "OB" : { + "code" : "entered-in-error", + "display" : "Entered in Error", + "system" : "http://hl7.org/fhir/document-reference-status" + }, + "UN" : { + "code" : "current", + "display" : "Current", + "system" : "http://hl7.org/fhir/document-reference-status" + } + }, + "CodeSystem/SecurityLableHandingInstructions": { + "R" : { + "code" : "R", + "display" : "restricted", + "system" : "http://terminology.hl7.org/CodeSystem/v3-Confidentiality" + }, + "U" : { + "code" : "U", + "display" : "unrestricted", + "system" : "http://terminology.hl7.org/CodeSystem/v3-Confidentiality" + }, + "V" : { + "code" : "V", + "display" : "very restricted", + "system" : "http://terminology.hl7.org/CodeSystem/v3-Confidentiality" + } + }, + "CodeSystem/DocumentCompletionStatus" : { + "AU" : { + "code" : "preliminary", + "display" : "Preliminary", + "system" : "http://hl7.org/fhir/composition-status" + }, + "DI" : { + "code" : "preliminary", + "display" : "Preliminary", + "system" : "http://hl7.org/fhir/composition-status" + }, + "DO" : { + "code" : "preliminary", + "display" : "Preliminary", + "system" : "http://hl7.org/fhir/composition-status" + }, + "IN" : { + "code" : "preliminary", + "display" : "Preliminary", + "system" : "http://hl7.org/fhir/composition-status" + }, + "IP" : { + "code" : "preliminary", + "display" : "Preliminary", + "system" : "http://hl7.org/fhir/composition-status" + }, + "LA" : { + "code" : "final", + "display" : "Final", + "system" : "http://hl7.org/fhir/composition-status" + }, + "PA" : { + "code" : "preliminary", + "display" : "Preliminary", + "system" : "http://hl7.org/fhir/composition-status" + } + }, + "CodeSystem/MimeType": { + "AP" : { + "code" : "application", + "display" : "pdf", + "system" : "urn:ietf:bcp:13" + }, + "AU" : { + "code" : "audio", + "display" : "basic", + "system" : "urn:ietf:bcp:13" + }, + "FT" : { + "code" : "text", + "display" : "x-hl7-ft", + "system" : "urn:ietf:bcp:13" + }, + "IM" : { + "code" : "image", + "display" : "jpeg", + "system" : "urn:ietf:bcp:13" + }, + "NS" : { + "code" : "image", + "display" : "jpeg", + "system" : "urn:ietf:bcp:13" + }, + "SD" : { + "code" : "image", + "display" : "jpeg", + "system" : "urn:ietf:bcp:13" + }, + "SI" : { + "code" : "image", + "display" : "jpeg", + "system" : "urn:ietf:bcp:13" + }, + "TX" : { + "code" : "text", + "display" : "plain", + "system" : "urn:ietf:bcp:13" + }, + "application" : { + "code" : "application", + "display" : "pdf", + "system" : "urn:ietf:bcp:13" + }, + "audio" : { + "code" : "audio", + "display" : "basic", + "system" : "urn:ietf:bcp:13" + }, + "image" : { + "code" : "image", + "display" : "jpeg", + "system" : "urn:ietf:bcp:13" + }, + "model" : { + "code" : "model", + "display" : "vrml", + "system" : "urn:ietf:bcp:13" + }, + "multipart" : { + "code" : "multipart", + "display" : "x-hl7-cda-level-one", + "system" : "urn:ietf:bcp:13" + }, + "text" : { + "code" : "text", + "display" : "plain", + "system" : "urn:ietf:bcp:13" + }, + "video" : { + "code" : "video", + "display" : "mpeg", + "system" : "urn:ietf:bcp:13" + } + }, + "CodeSystem/MimeSubType": { + "BASIC" : { + "code" : "basic", + "display" : "Basic", + "system" : "urn:ietf:bcp:13" + }, + "DICOM" : { + "code" : "dicom", + "display" : "DICOM", + "system" : "urn:ietf:bcp:13" + }, + "FAX" : { + "code" : "g3fax", + "display" : "", + "system" : "urn:ietf:bcp:13" + }, + "GIF" : { + "code" : "gif", + "display" : "GIF", + "system" : "urn:ietf:bcp:13" + }, + "HTML" : { + "code" : "html", + "display" : "HTML", + "system" : "urn:ietf:bcp:13" + }, + "JOT" : { + "code" : "jpeg", + "display" : "", + "system" : "urn:ietf:bcp:13" + }, + "JPEG" : { + "code" : "jpeg", + "display" : "JPEG", + "system" : "urn:ietf:bcp:13" + }, + "Octet-stream" : { + "code" : "", + "display" : "", + "system" : "urn:ietf:bcp:13" + }, + "PICT" : { + "code" : "pict", + "display" : "", + "system" : "urn:ietf:bcp:13" + }, + "PostScript" : { + "code" : "", + "display" : "", + "system" : "urn:ietf:bcp:13" + }, + "RTF" : { + "code" : "rtf", + "display" : "RTF", + "system" : "urn:ietf:bcp:13" + }, + "TIFF" : { + "code" : "tiff", + "display" : "TIFF", + "system" : "urn:ietf:bcp:13" + }, + "x-hl7-cda-level-one" : { + "code" : "x-hl7-cda-level-one", + "display" : "", + "system" : "urn:ietf:bcp:13" + } + }, + "CodeSystem/EventTiming": { + "AC" : { + "code" : "AC", + "display" : "AC", + "system" : "http://terminology.hl7.org/CodeSystem/v3-TimingEvent" + }, + "ACD" : { + "code" : "ACD", + "display" : "ACD", + "system" : "http://terminology.hl7.org/CodeSystem/v3-TimingEvent" + }, + "ACM" : { + "code" : "ACM", + "display" : "ACM", + "system" : "http://terminology.hl7.org/CodeSystem/v3-TimingEvent" + }, + "ACV" : { + "code" : "ACV", + "display" : "ACV", + "system" : "http://terminology.hl7.org/CodeSystem/v3-TimingEvent" + }, + "HS" : { + "code" : "HS", + "display" : "HS", + "system" : "http://terminology.hl7.org/CodeSystem/v3-TimingEvent" + }, + "IC" : { + "code" : "C", + "display" : "C", + "system" : "http://terminology.hl7.org/CodeSystem/v3-TimingEvent" + }, + "ICD" : { + "code" : "CD", + "display" : "CD", + "system" : "http://terminology.hl7.org/CodeSystem/v3-TimingEvent" + }, + "ICM" : { + "code" : "CM", + "display" : "CM", + "system" : "http://terminology.hl7.org/CodeSystem/v3-TimingEvent" + }, + "ICV" : { + "code" : "CV", + "display" : "CV", + "system" : "http://terminology.hl7.org/CodeSystem/v3-TimingEvent" + }, + "PC" : { + "code" : "PC", + "display" : "PC", + "system" : "http://terminology.hl7.org/CodeSystem/v3-TimingEvent" + }, + "PCD" : { + "code" : "PCD", + "display" : "PCD", + "system" : "http://terminology.hl7.org/CodeSystem/v3-TimingEvent" + }, + "PCM" : { + "code" : "PCM", + "display" : "PCM", + "system" : "http://terminology.hl7.org/CodeSystem/v3-TimingEvent" + }, + "PCV" : { + "code" : "PCV", + "display" : "PCV", + "system" : "http://terminology.hl7.org/CodeSystem/v3-TimingEvent" + }, + "WAKE" : { + "code" : "WAKE", + "display" : "WAKE", + "system" : "http://terminology.hl7.org/CodeSystem/v3-TimingEvent" + } } } } \ No newline at end of file diff --git a/data/Templates/Hl7v2/DataType/_CECodeableConcept.liquid b/data/Templates/Hl7v2/DataType/_CECodeableConcept.liquid index 82616a385..53a5014eb 100644 --- a/data/Templates/Hl7v2/DataType/_CECodeableConcept.liquid +++ b/data/Templates/Hl7v2/DataType/_CECodeableConcept.liquid @@ -4,7 +4,14 @@ { {% if mapping -%} "code":"{{ CE.1.Value | get_property: mapping, 'code' }}", - "display":"{{ CE.1.Value | get_property: mapping, 'display' }}", + {% capture displayURL %}{{ CE.1.Value | get_property: mapping, 'display' }}{% endcapture %} + "display":"{{ displayURL }}", + {% if displayURL == CE.1.Value %} + "display":"{{ CE.2.Value }}", + {% endif %} + {% if CE.3 %} + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CE.3.Value | replace: ' ', '-'}}", + {% endif %} "system":"{{ CE.1.Value | get_property: mapping, 'system' }}", "version":"{{ CE.1.Value | get_property: mapping, 'version' }}", "version":"{{ CE.7.Value }}", @@ -13,7 +20,7 @@ "display":"{{ CE.2.Value }}", {% if CE.3 %} - "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CE.3.Value}}", + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CE.3.Value | replace: ' ', '-'}}", {% endif %} {% capture temp %}{{ CE.3.Value | get_property: 'CodeSystem/CodeSystemUrl', 'system' }}{% endcapture %} {% if temp%} diff --git a/data/Templates/Hl7v2/DataType/_CFCodeableConcept.liquid b/data/Templates/Hl7v2/DataType/_CFCodeableConcept.liquid index 484e5e700..af0a7e9bc 100644 --- a/data/Templates/Hl7v2/DataType/_CFCodeableConcept.liquid +++ b/data/Templates/Hl7v2/DataType/_CFCodeableConcept.liquid @@ -4,15 +4,22 @@ { {% if mapping -%} "code":"{{CF.1.Value | get_property: mapping, 'code' }}", - "display":"{{CF.1.Value | get_property: mapping, 'display' }}", - "system":"{{CF.1.Value | get_property: mapping, 'system' }}", + {% capture displayURL %}{{ CF.1.Value | get_property: mapping, 'display' }}{% endcapture %} + "display":"{{ displayURL }}", + {% if displayURL == CF.1.Value %} + "display":"{{ CF.2.Value }}", + {% endif %} + {% if CF.3 %} + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CF.3.Value | replace: ' ', '-'}}", + {% endif %} + "system":"{{ CF.1.Value | get_property: mapping, 'system' }}", "version":"{{CF.1.Value | get_property: mapping, 'version' }}", "version":"{{CF.7.Value }}", {% else -%} "code":"{{CF.1.Value }}", "display":"{{CF.2.Value }}", {% if CF.3 %} - "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CF.3.Value}}", + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CF.3.Value | replace: ' ', '-'}}", {% endif %} {% capture SYSTEM_PROPERTY_VALUE %}{{ CF.3.Value | get_property: 'CodeSystem/CodeSystemUrl', 'system' }}{% endcapture %} {% if SYSTEM_PROPERTY_VALUE -%} @@ -24,15 +31,22 @@ { {% if mapping -%} "code":"{{CF.4.Value | get_property: mapping, 'code' }}", - "display":"{{CF.4.Value | get_property: mapping, 'display' }}", - "system":"{{CF.4.Value | get_property: mapping, 'system' }}", + {% capture displayURL %}{{ CF.4.Value | get_property: mapping, 'display' }}{% endcapture %} + "display":"{{ displayURL }}", + {% if displayURL == CF.4.Value %} + "display":"{{ CF.5.Value }}", + {% endif %} + {% if CF.6 %} + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CF.6.Value | replace: ' ', '-'}}", + {% endif %} + "system":"{{ CF.4.Value | get_property: mapping, 'system' }}", "version":"{{CF.4.Value | get_property: mapping, 'version' }}", "version":"{{CF.8.Value }}", {% else -%} "code":"{{CF.4.Value }}", "display":"{{CF.5.Value }}", {% if CF.6 %} - "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CF.6.Value}}", + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CF.6.Value | replace: ' ', '-'}}", {% endif %} {% capture SYSTEM_PROPERTY_VALUE %}{{ CF.6.Value | get_property: 'CodeSystem/CodeSystemUrl', 'system' }}{% endcapture %} {% if SYSTEM_PROPERTY_VALUE -%} @@ -44,15 +58,23 @@ { {% if mapping -%} "code":"{{CF.10.Value | get_property: mapping, 'code' }}", - "display":"{{CF.10.Value | get_property: mapping, 'display' }}", - "system":"{{CF.10.Value | get_property: mapping, 'system' }}", + "code":"{{ CF.10.Value | get_property: mapping, 'code' }}", + {% capture displayURL %}{{ CF.10.Value | get_property: mapping, 'display' }}{% endcapture %} + "display":"{{ displayURL }}", + {% if displayURL == CF.10.Value %} + "display":"{{ CF.11.Value }}", + {% endif %} + {% if CF.12 %} + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CF.12.Value | replace: ' ', '-'}}", + {% endif %} + "system":"{{ CF.10.Value | get_property: mapping, 'system' }}", "version":"{{CF.10.Value | get_property: mapping, 'version' }}", "version":"{{CF.13.Value }}", {% else -%} "code":"{{CF.10.Value }}", "display":"{{CF.11.Value }}", {% if CF.12 %} - "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CF.12.Value}}", + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CF.12.Value | replace: ' ', '-'}}", {% endif %} {% capture SYSTEM_PROPERTY_VALUE %}{{ CF.12.Value | get_property: 'CodeSystem/CodeSystemUrl', 'system' }}{% endcapture %} {% if SYSTEM_PROPERTY_VALUE -%} diff --git a/data/Templates/Hl7v2/DataType/_CMSpecimenSource.liquid b/data/Templates/Hl7v2/DataType/_CMSpecimenSource.liquid new file mode 100644 index 000000000..19cfa186c --- /dev/null +++ b/data/Templates/Hl7v2/DataType/_CMSpecimenSource.liquid @@ -0,0 +1,33 @@ +{% if CM %} +{% if CM.1 %} + "type": { + {% include 'DataType/CWECodeableConcept' CWE: CM.1 %} + }, +{% endif %} +{% if CM.2 %} + "container": { + "additiveCodeableConcept": "{{CM.2.Value}} "; + }, +{% endif %} +{% if CM.3 %} + "note": [ + { + "text": "{{CM.3.Value}}", + } + ], +{% endif %} +{% if CM.4 %} +"collection": [ + { + "site": { + {% include 'DataType/CWECodeableConcept' CWE: CM.4 %} + } + } +], +{% endif %} +{% if CM.5 %} + "condition": { + {% include 'DataType/CWECodeableConcept' CWE: CM.5 %} + }, +{% endif %} +{% endif %} \ No newline at end of file diff --git a/data/Templates/Hl7v2/DataType/_CNECodeableConcept.liquid b/data/Templates/Hl7v2/DataType/_CNECodeableConcept.liquid index d0c4f3715..cac1521ed 100644 --- a/data/Templates/Hl7v2/DataType/_CNECodeableConcept.liquid +++ b/data/Templates/Hl7v2/DataType/_CNECodeableConcept.liquid @@ -5,7 +5,7 @@ "code":"{{ CNE.1.Value }}", "display":"{{ CNE.2.Value }}", {% if CNE.3 %} - "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CNE.3.Value}}", + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CNE.3.Value | replace: ' ', '-'}}", {% endif %} {% capture temp %}{{ CNE.3.Value | get_property: 'CodeSystem/CodeSystemUrl', 'system' }}{% endcapture %} {% if temp%} @@ -17,7 +17,7 @@ "code":"{{ CNE.4.Value }}", "display":"{{ CNE.5.Value }}", {% if CNE.6 %} - "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CNE.6.Value}}", + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CNE.6.Value | replace: ' ', '-'}}", {% endif %} {% capture temp %}{{ CNE.6.Value | get_property: 'CodeSystem/CodeSystemUrl', 'system' }}{% endcapture %} {% if temp%} @@ -29,7 +29,7 @@ "code":"{{ CNE.10.Value }}", "display":"{{ CNE.11.Value }}", {% if CNE.12 %} - "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CNE.12.Value}}", + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CNE.12.Value | replace: ' ', '-'}}", {% endif %} {% capture temp %}{{ CNE.12.Value | get_property: 'CodeSystem/CodeSystemUrl', 'system' }}{% endcapture %} {% if temp%} diff --git a/data/Templates/Hl7v2/DataType/_CNN.liquid b/data/Templates/Hl7v2/DataType/_CNN.liquid index 490430f61..1c021a66a 100644 --- a/data/Templates/Hl7v2/DataType/_CNN.liquid +++ b/data/Templates/Hl7v2/DataType/_CNN.liquid @@ -26,3 +26,31 @@ }, ], {% endif -%} +{% if CNN_val -%} + "identifier": + [ + { + "value":"{{ CNN_val.1 }}", + }, + ], + "name": + [ + { + "family":"{{ CNN_val.2 }}", + "given": + [ + "{{ CNN_val.3 }}", + "{{ CNN_val.4 }}", + ], + "suffix": + [ + "{{ CNN_val.5 }}", + "{{ CNN_val.7 }}", + ], + "prefix": + [ + "{{ CNN_val.6 }}", + ], + }, + ], +{% endif -%} diff --git a/data/Templates/Hl7v2/DataType/_CQ.liquid b/data/Templates/Hl7v2/DataType/_CQ.liquid index d5b2511d8..87ced64c5 100644 --- a/data/Templates/Hl7v2/DataType/_CQ.liquid +++ b/data/Templates/Hl7v2/DataType/_CQ.liquid @@ -1,7 +1,30 @@ {% if CQ -%} - "value":"{{ CQ.1.Value }}", + {% if CQ.1 %} + "value":{{ CQ.1.Value }}, + {% endif %} {% if CQ.2.9 == null -%} "unit":"{{ CQ.2.2 }}", {% endif -%} "unit":"{{ CQ.2.9 }}", {% endif -%} +{% if CQ_val -%} + {% assign temp = CQ_val.1 %} + {% if temp != "" and temp != null -%} + "value": {{temp}}, + {% endif %} + {% if CQ.2.9 == null -%} + "unit":"{{ CQ_val.2 }}", + {% endif -%} + "unit":"{{ CQ_val.2.9 }}", +{% endif -%} +{% if CQ_duration -%} + {% if CQ_duration.1 %} + "value":{{ CQ_duration.1.Value }}, + {% endif %} + {% if CQ_duration.2.9 == null -%} + "unit":"{{ CQ_duration.2.2 }}", + {% endif -%} + "unit":"{{ CQ_duration.2.9 }}", + "code" : "{{ CQ_duration.2.1 | get_property: 'CodeSystem/DurationUnit', 'code' }}", + "system" : "http://unitsofmeasure.org", +{% endif -%} \ No newline at end of file diff --git a/data/Templates/Hl7v2/DataType/_CQServiceRequestduration.liquid b/data/Templates/Hl7v2/DataType/_CQServiceRequestduration.liquid index 52e2e9235..4fda763a2 100644 --- a/data/Templates/Hl7v2/DataType/_CQServiceRequestduration.liquid +++ b/data/Templates/Hl7v2/DataType/_CQServiceRequestduration.liquid @@ -1,7 +1,6 @@ {% if CQ -%} - "repeat": - { - "duration":"{{ CQ.1.Value }}", - "durationUnit":"{{ CQ.2.Value }}", - }, + {% if CQ.1 -%} + "duration":{{ CQ.1.Value }}, + {% endif -%} + "durationUnit":"{{ CQ.2.1 | get_property: 'CodeSystem/DurationUnit', 'code' }}", {% endif -%} diff --git a/data/Templates/Hl7v2/DataType/_CWECode.liquid b/data/Templates/Hl7v2/DataType/_CWECode.liquid index 9294567da..54c297351 100644 --- a/data/Templates/Hl7v2/DataType/_CWECode.liquid +++ b/data/Templates/Hl7v2/DataType/_CWECode.liquid @@ -11,4 +11,14 @@ "{{ CWE.4.Value | get_property: mapping, 'code' }}" {% endunless %} {% endif -%} +{% endif -%} +{% if CWE_internal -%} + {% if mapping -%} + {% if CWE_internal.1 -%} + "{{ CWE_internal.1 | get_property: mapping, 'code' }}" + {% endif -%} + {% unless CWE_internal.1 -%} + "{{ CWE_internal.4 | get_property: mapping, 'code' }}" + {% endunless %} + {% endif -%} {% endif -%} \ No newline at end of file diff --git a/data/Templates/Hl7v2/DataType/_CWECodeableConcept.liquid b/data/Templates/Hl7v2/DataType/_CWECodeableConcept.liquid index b560ea75b..f48d1cea2 100644 --- a/data/Templates/Hl7v2/DataType/_CWECodeableConcept.liquid +++ b/data/Templates/Hl7v2/DataType/_CWECodeableConcept.liquid @@ -4,7 +4,14 @@ { {% if mapping -%} "code":"{{ CWE.1.Value | get_property: mapping, 'code' }}", - "display":"{{ CWE.1.Value | get_property: mapping, 'display' }}", + {% capture displayURL %}{{ CWE.1.Value | get_property: mapping, 'display' }}{% endcapture %} + "display":"{{ displayURL }}", + {% if displayURL == CWE.1.Value %} + "display":"{{ CWE.2.Value }}", + {% endif %} + {% if CWE.3 %} + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.3.Value | replace: ' ', '-'}}", + {% endif %} "system":"{{ CWE.1.Value | get_property: mapping, 'system' }}", "version":"{{ CWE.1.Value | get_property: mapping, 'version' }}", "version":"{{ CWE.7.Value }}", @@ -13,7 +20,7 @@ "display":"{{ CWE.2.Value }}", {% if CWE.3 %} - "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.3.Value}}", + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.3.Value | replace: ' ', '-'}}", {% endif %} {% capture temp %}{{ CWE.3.Value | get_property: 'CodeSystem/CodeSystemUrl', 'system' }}{% endcapture %} {% if temp%} @@ -25,7 +32,14 @@ { {% if mapping -%} "code":"{{ CWE.4.Value | get_property: mapping, 'code' }}", - "display":"{{ CWE.4.Value | get_property: mapping, 'display' }}", + {% capture displayURL %}{{ CWE.4.Value | get_property: mapping, 'display' }}{% endcapture %} + "display":"{{ displayURL }}", + {% if displayURL == CWE.4.Value %} + "display":"{{ CWE.5.Value }}", + {% endif %} + {% if CWE.6 %} + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.6.Value | replace: ' ', '-'}}", + {% endif %} "system":"{{ CWE.4.Value | get_property: mapping, 'system' }}", "version":"{{ CWE.4.Value | get_property: mapping, 'version' }}", "version":"{{ CWE.8.Value }}", @@ -33,7 +47,7 @@ "code":"{{ CWE.4.Value }}", "display":"{{ CWE.5.Value }}", {% if CWE.6 %} - "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.6.Value}}", + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.6.Value | replace: ' ', '-'}}", {% endif %} {% capture temp %}{{ CWE.6.Value | get_property: 'CodeSystem/CodeSystemUrl', 'system' }}{% endcapture %} {% if temp%} @@ -45,7 +59,14 @@ { {% if mapping -%} "code":"{{ CWE.10.Value | get_property: mapping, 'code' }}", - "display":"{{ CWE.10.Value | get_property: mapping, 'display' }}", + {% capture displayURL %}{{ CWE.10.Value | get_property: mapping, 'display' }}{% endcapture %} + "display":"{{ displayURL }}", + {% if displayURL == CWE.10.Value %} + "display":"{{ CWE.11.Value }}", + {% endif %} + {% if CWE.12 %} + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.12.Value | replace: ' ', '-'}}", + {% endif %} "system":"{{ CWE.10.Value | get_property: mapping, 'system' }}", "version":"{{ CWE.10.Value | get_property: mapping, 'version' }}", "version":"{{ CWE.13.Value }}", @@ -53,7 +74,7 @@ "code":"{{ CWE.10.Value }}", "display":"{{ CWE.11.Value }}", {% if CWE.12 %} - "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.12.Value}}", + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.12.Value | replace: ' ', '-'}}", {% endif %} {% capture temp %}{{ CWE.12.Value | get_property: 'CodeSystem/CodeSystemUrl', 'system' }}{% endcapture %} {% if temp%} diff --git a/data/Templates/Hl7v2/DataType/_CWECodeableConceptInternalValues.liquid b/data/Templates/Hl7v2/DataType/_CWECodeableConceptInternalValues.liquid new file mode 100644 index 000000000..77d4fc35c --- /dev/null +++ b/data/Templates/Hl7v2/DataType/_CWECodeableConceptInternalValues.liquid @@ -0,0 +1,43 @@ +{% if CWE -%} + "coding": + [ + { + "code":"{{ CWE.1 }}", + "display":"{{ CWE.2 }}", + + {% if CWE.3 %} + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.3 | replace: ' ', '-'}}", + {% endif %} + {% capture temp %}{{ CWE.3 | get_property: 'CodeSystem/CodeSystemUrl', 'system' }}{% endcapture %} + {% if temp%} + "system":"{{temp}}", + {% endif %} + "version":"{{ CWE.7 }}", + }, + { + "code":"{{ CWE.4 }}", + "display":"{{ CWE.5 }}", + {% if CWE.6 %} + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.6 | replace: ' ', '-'}}", + {% endif %} + {% capture temp %}{{ CWE.6 | get_property: 'CodeSystem/CodeSystemUrl', 'system' }}{% endcapture %} + {% if temp%} + "system":"{{temp}}", + {% endif %} + "version":"{{ CWE.8 }}", + }, + { + "code":"{{ CWE.10 }}", + "display":"{{ CWE.11 }}", + {% if CWE.12 %} + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.12 | replace: ' ', '-'}}", + {% endif %} + {% capture temp %}{{ CWE.12 | get_property: 'CodeSystem/CodeSystemUrl', 'system' }}{% endcapture %} + {% if temp%} + "system":"{{temp}}", + {% endif %} + "version":"{{ CWE.13 }}", + }, + ], + "text":"{{ CWE.9 }}", +{% endif -%} \ No newline at end of file diff --git a/data/Templates/Hl7v2/DataType/_CWECodeableConceptRepeatable.liquid b/data/Templates/Hl7v2/DataType/_CWECodeableConceptRepeatable.liquid index 7feedf921..1b688acbb 100644 --- a/data/Templates/Hl7v2/DataType/_CWECodeableConceptRepeatable.liquid +++ b/data/Templates/Hl7v2/DataType/_CWECodeableConceptRepeatable.liquid @@ -2,7 +2,14 @@ { {% if mapping -%} "code":"{{ CWE.1.Value | get_property: mapping, 'code' }}", - "display":"{{ CWE.1.Value | get_property: mapping, 'display' }}", + {% capture displayURL %}{{ CWE.1.Value | get_property: mapping, 'display' }}{% endcapture %} + "display":"{{ displayURL }}", + {% if displayURL == CWE.1.Value %} + "display":"{{ CWE.2.Value }}", + {% endif %} + {% if CWE.3 %} + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.3.Value | replace: ' ', '-'}}", + {% endif %} "system":"{{ CWE.1.Value | get_property: mapping, 'system' }}", "version":"{{ CWE.1.Value | get_property: mapping, 'version' }}", "version":"{{ CWE.7.Value }}", @@ -11,22 +18,29 @@ "display":"{{ CWE.2.Value }}", {% if CWE.3 %} - "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.3.Value}}", + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.3.Value | replace: ' ', '-'}}", {% endif %} {% capture SYSTEM_PROPERTY_VALUE %}{{ CWE.3.Value | get_property: 'CodeSystem/CodeSystemUrl', 'system' }}{% endcapture %} {% if SYSTEM_PROPERTY_VALUE -%} "system":"{{SYSTEM_PROPERTY_VALUE}}", {% endif %} - {%- comment -%} - "system": "{{ CWE.3.Value | get_property: 'CodeSystem/CodeSystemURL', 'system' }}", - {%- endcomment -%} + {% if systemHardcodedUrl and CWE.3-%} + "system":"{{systemHardcodedUrl}}", + {% endif %} "version":"{{ CWE.7.Value }}", {% endif -%} }, { {% if mapping -%} "code":"{{ CWE.4.Value | get_property: mapping, 'code' }}", - "display":"{{ CWE.4.Value | get_property: mapping, 'display' }}", + {% capture displayURL %}{{ CWE.4.Value | get_property: mapping, 'display' }}{% endcapture %} + "display":"{{ displayURL }}", + {% if displayURL == CWE.4.Value %} + "display":"{{ CWE.5.Value }}", + {% endif %} + {% if CWE.6 %} + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.6.Value | replace: ' ', '-'}}", + {% endif %} "system":"{{ CWE.4.Value | get_property: mapping, 'system' }}", "version":"{{ CWE.4.Value | get_property: mapping, 'version' }}", "version":"{{ CWE.8.Value }}", @@ -34,19 +48,29 @@ "code":"{{ CWE.4.Value }}", "display":"{{ CWE.5.Value }}", {% if CWE.6 %} - "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.6.Value}}", + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.6.Value | replace: ' ', '-'}}", {% endif %} {% capture SYSTEM_PROPERTY_VALUE %}{{ CWE.6.Value | get_property: 'CodeSystem/CodeSystemUrl', 'system' }}{% endcapture %} {% if SYSTEM_PROPERTY_VALUE -%} "system":"{{SYSTEM_PROPERTY_VALUE}}", {% endif %} + {% if systemHardcodedUrl and CWE.6-%} + "system":"{{systemHardcodedUrl}}", + {% endif %} "version":"{{ CWE.8.Value }}", {% endif -%} }, { {% if mapping -%} "code":"{{ CWE.10.Value | get_property: mapping, 'code' }}", - "display":"{{ CWE.10.Value | get_property: mapping, 'display' }}", + {% capture displayURL %}{{ CWE.10.Value | get_property: mapping, 'display' }}{% endcapture %} + "display":"{{ displayURL }}", + {% if displayURL == CWE.10.Value %} + "display":"{{ CWE.11.Value }}", + {% endif %} + {% if CWE.12 %} + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.12.Value | replace: ' ', '-'}}", + {% endif %} "system":"{{ CWE.10.Value | get_property: mapping, 'system' }}", "version":"{{ CWE.10.Value | get_property: mapping, 'version' }}", "version":"{{ CWE.13.Value }}", @@ -54,12 +78,15 @@ "code":"{{ CWE.10.Value }}", "display":"{{ CWE.11.Value }}", {% if CWE.12 %} - "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.12.Value}}", + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.12.Value | replace: ' ', '-'}}", {% endif %} {% capture SYSTEM_PROPERTY_VALUE %}{{ CWE.12.Value | get_property: 'CodeSystem/CodeSystemUrl', 'system' }}{% endcapture %} {% if SYSTEM_PROPERTY_VALUE -%} "system":"{{SYSTEM_PROPERTY_VALUE}}", {% endif %} + {% if systemHardcodedUrl and CWE.12-%} + "system":"{{systemHardcodedUrl}}", + {% endif %} "version":"{{ CWE.13.Value }}", {% endif -%} }, diff --git a/data/Templates/Hl7v2/DataType/_CWECodeableConcept_hardcodedURL.liquid b/data/Templates/Hl7v2/DataType/_CWECodeableConcept_hardcodedURL.liquid new file mode 100644 index 000000000..442649014 --- /dev/null +++ b/data/Templates/Hl7v2/DataType/_CWECodeableConcept_hardcodedURL.liquid @@ -0,0 +1,92 @@ +{% if CWE -%} + { + {% if mapping -%} + "code":"{{ CWE.1.Value | get_property: mapping, 'code' }}", + {% capture displayURL %}{{ CWE.1.Value | get_property: mapping, 'display' }}{% endcapture %} + "display":"{{ displayURL }}", + {% if displayURL == CWE.1.Value %} + "display":"{{ CWE.2.Value }}", + {% endif %} + {% if CWE.3 %} + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.3.Value | replace: ' ', '-'}}", + {% endif %} + "system":"{{ CWE.1.Value | get_property: mapping, 'system' }}", + "version":"{{ CWE.1.Value | get_property: mapping, 'version' }}", + "version":"{{ CWE.7.Value }}", + {% else -%} + "code":"{{ CWE.1.Value }}", + "display":"{{ CWE.2.Value }}", + {% if CWE.3 %} + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.3.Value | replace: ' ', '-'}}", + {% endif %} + {% capture SYSTEM_PROPERTY_VALUE %}{{ CWE.3.Value | get_property: 'CodeSystem/CodeSystemUrl', 'system' }}{% endcapture %} + {% if SYSTEM_PROPERTY_VALUE -%} + "system":"{{SYSTEM_PROPERTY_VALUE}}", + {% endif %} + {% if systemHardcodedUrl and CWE.1 or CWE.2 or CWE.3 or CWE.7-%} + "system":"{{systemHardcodedUrl}}", + {% endif %} + "version":"{{ CWE.7.Value }}", + {% endif -%} + }, + { + {% if mapping -%} + "code":"{{ CWE.4.Value | get_property: mapping, 'code' }}", + {% capture displayURL %}{{ CWE.4.Value | get_property: mapping, 'display' }}{% endcapture %} + "display":"{{ displayURL }}", + {% if displayURL == CWE.4.Value %} + "display":"{{ CWE.5.Value }}", + {% endif %} + {% if CWE.6 %} + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.6.Value | replace: ' ', '-'}}", + {% endif %} + "system":"{{ CWE.4.Value | get_property: mapping, 'system' }}", + "version":"{{ CWE.4.Value | get_property: mapping, 'version' }}", + "version":"{{ CWE.8.Value }}", + {% else -%} + "code":"{{ CWE.4.Value }}", + "display":"{{ CWE.5.Value }}", + {% if CWE.6 %} + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.6.Value | replace: ' ', '-'}}", + {% endif %} + {% capture SYSTEM_PROPERTY_VALUE %}{{ CWE.6.Value | get_property: 'CodeSystem/CodeSystemUrl', 'system' }}{% endcapture %} + {% if SYSTEM_PROPERTY_VALUE -%} + "system":"{{SYSTEM_PROPERTY_VALUE}}", + {% endif %} + {% if systemHardcodedUrl and CWE.4 or CWE.5 or CWE.6 or CWE.8 -%} + "system":"{{systemHardcodedUrl}}", + {% endif %} + "version":"{{ CWE.8.Value }}", + {% endif -%} + }, + { + {% if mapping -%} + "code":"{{ CWE.10.Value | get_property: mapping, 'code' }}", + {% capture displayURL %}{{ CWE.10.Value | get_property: mapping, 'display' }}{% endcapture %} + "display":"{{ displayURL }}", + {% if displayURL == CWE.10.Value %} + "display":"{{ CWE.11.Value }}", + {% endif %} + {% if CWE.12 %} + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.12.Value | replace: ' ', '-'}}", + {% endif %} + "system":"{{ CWE.10.Value | get_property: mapping, 'system' }}", + "version":"{{ CWE.10.Value | get_property: mapping, 'version' }}", + "version":"{{ CWE.13.Value }}", + {% else -%} + "code":"{{ CWE.10.Value }}", + "display":"{{ CWE.11.Value }}", + {% if CWE.12 %} + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.12.Value | replace: ' ', '-'}}", + {% endif %} + {% capture SYSTEM_PROPERTY_VALUE %}{{ CWE.12.Value | get_property: 'CodeSystem/CodeSystemUrl', 'system' }}{% endcapture %} + {% if SYSTEM_PROPERTY_VALUE -%} + "system":"{{SYSTEM_PROPERTY_VALUE}}", + {% endif %} + {% if systemHardcodedUrl and CWE.10 or CWE.11 or CWE.12 or CWE.13 -%} + "system":"{{systemHardcodedUrl}}", + {% endif %} + "version":"{{ CWE.13.Value }}", + {% endif -%} + }, +{% endif -%} \ No newline at end of file diff --git a/data/Templates/Hl7v2/DataType/_CWECoding.liquid b/data/Templates/Hl7v2/DataType/_CWECoding.liquid index f9b1af4db..620ab9616 100644 --- a/data/Templates/Hl7v2/DataType/_CWECoding.liquid +++ b/data/Templates/Hl7v2/DataType/_CWECoding.liquid @@ -1,7 +1,14 @@ {% if CWE -%} {% if mapping -%} "code":"{{ CWE.1.Value | get_property: mapping, 'code' }}", - "display":"{{ CWE.1.Value | get_property: mapping, 'display' }}", + {% capture displayURL %}{{ CWE.1.Value | get_property: mapping, 'display' }}{% endcapture %} + "display":"{{ displayURL }}", + {% if displayURL == CWE.1.Value %} + "display":"{{ CWE.2.Value }}", + {% endif %} + {% if CWE.3 %} + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.3.Value | replace: ' ', '-'}}", + {% endif %} "system":"{{ CWE.1.Value | get_property: mapping, 'system' }}", "version":"{{ CWE.1.Value | get_property: mapping, 'version' }}", "version":"{{ CWE.7.Value }}", diff --git a/data/Templates/Hl7v2/DataType/_CWEIdentifier.liquid b/data/Templates/Hl7v2/DataType/_CWEIdentifier.liquid index 0eba8f0ce..c019f392f 100644 --- a/data/Templates/Hl7v2/DataType/_CWEIdentifier.liquid +++ b/data/Templates/Hl7v2/DataType/_CWEIdentifier.liquid @@ -1,3 +1,4 @@ +{% if CWE -%} "identifier" : [ { "value": "{{CWE.1}}", @@ -17,4 +18,27 @@ "system": "http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE.12}}", {% endif %} }, -], \ No newline at end of file +], +{% endif -%} +{% if CWE_InternalValue -%} +"identifier" : [ + { + "value": "{{CWE_InternalValue.1.Value}}", + {% if CWE_InternalValue.3.Value %} + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE_InternalValue.3.Value}}", + {% endif %} + }, + { + "value": "{{CWE_InternalValue.4.Value}}", + {% if CWE_InternalValue.6.Value %} + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE_InternalValue.6.Value}}", + {% endif %} + }, + { + "value": "{{CWE_InternalValue.10.Value}}", + {% if CWE_InternalValue.12.Value %} + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/{{CWE_InternalValue.12.VAlue}}", + {% endif %} + }, +], +{% endif -%} \ No newline at end of file diff --git a/data/Templates/Hl7v2/DataType/_EDAttachment1.liquid b/data/Templates/Hl7v2/DataType/_EDAttachment1.liquid index 0c585892b..2b59e216a 100644 --- a/data/Templates/Hl7v2/DataType/_EDAttachment1.liquid +++ b/data/Templates/Hl7v2/DataType/_EDAttachment1.liquid @@ -1,4 +1,14 @@ {% if ED -%} - "contentType":"{{ ED.2.Value }}", + {% assign mimetype = ED.2.Value | get_property: 'CodeSystem/MimeType', 'code' -%} + {% if ED.3 -%} + {% if ED.3.Value == "Octet-stream" or ED.3.Value == "PostScript" -%} + {% assign mimesubtype = ED.2.Value | get_property: 'CodeSystem/MimeType', 'display' -%} + {% else -%} + {% assign mimesubtype = ED.3.Value | get_property: 'CodeSystem/MimeSubType', 'code' -%} + {% endif -%} + {% else -%} + {% assign mimesubtype = ED.2.Value | get_property: 'CodeSystem/MimeType', 'display' -%} + {% endif -%} + "contentType": "{{mimetype | append: "/" | append: mimesubtype}}", "data":"{{ ED.5.Value }}", {% endif -%} diff --git a/data/Templates/Hl7v2/DataType/_EIIdentifier.liquid b/data/Templates/Hl7v2/DataType/_EIIdentifier.liquid index 8c13dcd7c..e0c3e7ed0 100644 --- a/data/Templates/Hl7v2/DataType/_EIIdentifier.liquid +++ b/data/Templates/Hl7v2/DataType/_EIIdentifier.liquid @@ -7,7 +7,7 @@ "value":"{{ EI.1.Value }}", {% unless EI.3.Value and EI.4.Value -%} {% if EI.2 %} - "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-{{EI.2.Value}}", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-{{EI.2.Value | replace: ' ', '-'}}", {% endif %} {% endunless -%} {% if EI.4.Value -%} @@ -18,7 +18,7 @@ {% elsif EI.4.Value == "UUID" or EI.4.Value == "GUID" -%} "system": "urn:uuid:{{ EI.3.Value }}", {% else -%} - "system": "http://example.com/v2-to-fhir-converter/universal-entity-identifier-{{EI.4.Value}}", + "system": "http://example.com/v2-to-fhir-converter/universal-entity-identifier-{{EI.4.Value | replace: ' ', '-' }}", {% endif -%} "type":{ "coding": [ diff --git a/data/Templates/Hl7v2/DataType/_EIPIdentifier.liquid b/data/Templates/Hl7v2/DataType/_EIPIdentifier.liquid index 0eaa44b13..f8e631ced 100644 --- a/data/Templates/Hl7v2/DataType/_EIPIdentifier.liquid +++ b/data/Templates/Hl7v2/DataType/_EIPIdentifier.liquid @@ -22,3 +22,56 @@ ], }, {% endif -%} +{% if EIP_Specimen_child1 -%} + "value":"{{ EIP_Specimen_child1.1 }}", + "type": + { + "coding": + [ + { + {% if EIP_Specimen_child1 -%} + "code":"PGN", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + {% endif -%} + }, + ], + }, +{% endif -%} +{% if EIP_Specimen_child2 -%} + "value":"{{ EIP_Specimen_child2.1 }}", + "type": + { + "coding": + [ + { + {% if EIP_Specimen_child2 -%} + "code":"FGN", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + {% endif -%} + }, + ], + }, +{% endif -%} +{% if EIP_Specimen_parent1 or EIP_Specimen_parent2 -%} + {% if EIP_Specimen_parent1 -%} + "value":"{{ EIP_Specimen_parent1.1 }}", + {% elsif EIP_Specimen_parent2 -%} + "value":"{{ EIP_Specimen_parent2.1 }}", + {% endif -%} + "type": + { + "coding": + [ + { + {% if EIP_Specimen_parent1 -%} + "code":"PGN", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + {% endif -%} + {% if EIP_Specimen_parent2 -%} + "code":"FGN", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + {% endif -%} + }, + ], + }, +{% endif -%} \ No newline at end of file diff --git a/data/Templates/Hl7v2/DataType/_IDCodeableConcept.liquid b/data/Templates/Hl7v2/DataType/_IDCodeableConcept.liquid index b7f299d30..746e4c28f 100644 --- a/data/Templates/Hl7v2/DataType/_IDCodeableConcept.liquid +++ b/data/Templates/Hl7v2/DataType/_IDCodeableConcept.liquid @@ -1,24 +1,21 @@ {% if ID -%} - {% if mapping -%} - "code":"{{ ID.1.Value | get_property: mapping, 'code' }}", - "display":"{{ ID.1.Value | get_property: mapping, 'display' }}", - "system":"{{ ID.1.Value | get_property: mapping, 'system' }}", - "version":"{{ ID.1.Value | get_property: mapping, 'version' }}", - "version":"{{ ID.7.Value }}", - {% else -%} - "code":"{{ ID.1.Value }}", - "display":"{{ ID.2.Value }}", - - {% if ID.3 %} - "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{ID.3.Value}}", - {% endif %} - {% capture SYSTEM_PROPERTY_VALUE %}{{ ID.3.Value | get_property: 'CodeSystem/CodeSystemUrl', 'system' }}{% endcapture %} - {% if SYSTEM_PROPERTY_VALUE -%} - "system":"{{SYSTEM_PROPERTY_VALUE}}", - {% endif %} - {%- comment -%} - "system": "{{ ID.3.Value | get_property: 'CodeSystem/CodeSystemURL', 'system' }}", - {%- endcomment -%} - "version":"{{ ID.7.Value }}", - {% endif -%} -{% endif -%} \ No newline at end of file +"coding": +[ + { + {% if mapping -%} + "code":"{{ ID.1.Value | get_property: mapping, 'code' }}", + "system":"{{ ID.1.Value | get_property: mapping, 'system' }}", + {% else -%} + "code":"{{ ID.1.Value }}", + {% if ID.3 %} + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{ID.3.Value}}", + {% endif %} + {% capture SYSTEM_PROPERTY_VALUE %}{{ ID.3.Value | get_property: 'CodeSystem/CodeSystemUrl', 'system' }}{% endcapture %} + {% if SYSTEM_PROPERTY_VALUE -%} + "system":"{{SYSTEM_PROPERTY_VALUE}}", + {% endif %} + {% endif -%} + } +], +{% endif -%} + \ No newline at end of file diff --git a/data/Templates/Hl7v2/DataType/_IDCoding.liquid b/data/Templates/Hl7v2/DataType/_IDCoding.liquid index 540b92bab..61aff8f09 100644 --- a/data/Templates/Hl7v2/DataType/_IDCoding.liquid +++ b/data/Templates/Hl7v2/DataType/_IDCoding.liquid @@ -1,7 +1,14 @@ {% if ID -%} {% if mapping -%} "code":"{{ ID.1.Value | get_property: mapping, 'code' }}", - "display":"{{ ID.1.Value | get_property: mapping, 'display' }}", + {% capture displayURL %}{{ ID.1.Value | get_property: mapping, 'display' }}{% endcapture %} + "display":"{{ displayURL }}", + {% if displayURL == ID.1.Value %} + "display":"{{ ID.2.Value }}", + {% endif %} + {% if ID.3 %} + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/{{ID.3.Value | replace: ' ', '-'}}", + {% endif %} "system":"{{ ID.1.Value | get_property: mapping, 'system' }}", {% endif -%} {% endif -%} diff --git a/data/Templates/Hl7v2/DataType/_NDLLocation.liquid b/data/Templates/Hl7v2/DataType/_NDLLocation.liquid new file mode 100644 index 000000000..61a8ca8ff --- /dev/null +++ b/data/Templates/Hl7v2/DataType/_NDLLocation.liquid @@ -0,0 +1,207 @@ +{% evaluate Location_ID_NDL_4 using 'ID/Location' PL: NDL.4 -%} +{% evaluate Location_ID_NDL_5 using 'ID/Location' PL: NDL.5 -%} +{% evaluate Location_ID_NDL_6 using 'ID/Location' PL: NDL.6 -%} +{% evaluate Location_ID_NDL_7 using 'ID/Location' PL: NDL.7 -%} +{% evaluate Location_ID_NDL_10 using 'ID/Location' PL: NDL.10 -%} +{% evaluate Location_ID_NDL_11 using 'ID/Location' PL: NDL.11 -%} + +{% if NDL.4 -%} +{ + "fullUrl":"urn:uuid:{{ Location_ID_NDL_4 }}", + "resource":{ + "resourceType": "Location", + "id":"{{ Location_ID_NDL_4 }}", + {% if Location_ID_NDL_11 -%} + "partOf":{ + "reference":"Location/{{Location_ID_NDL_11}}" + }, + {% endif %} + "name" : "{{NDL.4.Value}}", + "mode":"instance", + {% assign NDLValue= NDL.Value%} + {% capture textstring %}{{ NDLValue | split: "^" | join: "--" }}{% endcapture -%} + {% capture specomp %}{{ textstring | split: "~" | join: "+" }}{% endcapture -%} + {% capture description %}{{ specomp | split: "&" | join: "--" }}{% endcapture -%} + "description" : "{{ description }}", + + "physicalType":{ + "coding":[ + { + "system":"http://terminology.hl7.org/CodeSystem/location-physical-type", + "code":"lvl" + } + ] + }, + }, + "request":{ + "method":"PUT", + "url":"Location/{{ Location_ID_NDL_4 }}", + }, +}, +{% endif -%} +{% if NDL.5 -%} +{ + "fullUrl":"urn:uuid:{{ Location_ID_NDL_5 }}", + "resource":{ + "resourceType": "Location", + "id":"{{ Location_ID_NDL_5 }}", + {% if Location_ID_NDL_4 -%} + "partOf":{ + "reference":"Location/{{Location_ID_NDL_4}}" + }, + {% endif %} + "name" : "{{NDL.5.Value}}", + "mode":"instance", + {% assign NDLValue= NDL.Value%} + {% capture textstring %}{{ NDLValue | split: "^" | join: "--" }}{% endcapture -%} + {% capture specomp %}{{ textstring | split: "~" | join: "+" }}{% endcapture -%} + {% capture description %}{{ specomp | split: "&" | join: "--" }}{% endcapture -%} + "description" : "{{ description }}", + + "physicalType":{ + "coding":[ + { + "system":"http://terminology.hl7.org/CodeSystem/location-physical-type", + "code":"ro", + } + ] + }, + }, + "request":{ + "method":"PUT", + "url":"Location/{{ Location_ID_NDL_5 }}", + }, +}, +{% endif -%} +{% if NDL.6 -%} +{ + "fullUrl":"urn:uuid:{{ Location_ID_NDL_6 }}", + "resource":{ + "resourceType": "Location", + "id":"{{ Location_ID_NDL_6 }}", + {% if Location_ID_NDL_5 -%} + "partOf":{ + "reference":"Location/{{Location_ID_NDL_5}}" + }, + {% endif %} + "name" : "{{NDL.6.Value}}", + "mode":"instance", + {% assign NDLValue= NDL.Value%} + {% capture textstring %}{{ NDLValue | split: "^" | join: "--" }}{% endcapture -%} + {% capture specomp %}{{ textstring | split: "~" | join: "+" }}{% endcapture -%} + {% capture description %}{{ specomp | split: "&" | join: "--" }}{% endcapture -%} + "description" : "{{ description }}", + + "physicalType":{ + "coding":[ + { + "system":"http://terminology.hl7.org/CodeSystem/location-physical-type", + "code":"bd", + } + ] + }, + }, + "request":{ + "method":"PUT", + "url":"Location/{{ Location_ID_NDL_6 }}", + }, +}, +{% endif -%} +{% if NDL.7-%} +{ + "fullUrl":"urn:uuid:{{ Location_ID_NDL_7 }}", + "resource":{ + "resourceType": "Location", + "id":"{{ Location_ID_NDL_7 }}", + {% include 'DataType/PL_HDLocation' HD: NDL.7 -%}, + "mode":"instance", + {% assign NDLValue= NDL.Value%} + {% capture textstring %}{{ NDLValue | split: "^" | join: "--" }}{% endcapture -%} + {% capture specomp %}{{ textstring | split: "~" | join: "+" }}{% endcapture -%} + {% capture description %}{{ specomp | split: "&" | join: "--" }}{% endcapture -%} + "description" : "{{ description }}", + + "physicalType":{ + "coding":[ + { + "system":"http://terminology.hl7.org/CodeSystem/location-physical-type", + "code":"si", + } + ] + }, + }, + "request":{ + "method":"PUT", + "url":"Location/{{ Location_ID_NDL_7 }}", + }, +}, +{% endif -%} +{% if NDL.10 -%} +{ + "fullUrl":"urn:uuid:{{ Location_ID_NDL_10 }}", + "resource":{ + "resourceType": "Location", + "id":"{{ Location_ID_NDL_10 }}", + + {% if Location_ID_NDL_7 -%} + "partOf":{ + "reference":"Location/{{Location_ID_NDL_7}}" + }, + {% endif %} + "name": "{{NDL.10.Value}}", + "mode":"instance", + {% assign NDLValue= NDL.Value%} + {% capture textstring %}{{ NDLValue | split: "^" | join: "--" }}{% endcapture -%} + {% capture specomp %}{{ textstring | split: "~" | join: "+" }}{% endcapture -%} + {% capture description %}{{ specomp | split: "&" | join: "--" }}{% endcapture -%} + "description" : "{{ description }}", + + "physicalType":{ + "coding":[ + { + "system":"http://terminology.hl7.org/CodeSystem/location-physical-type", + "code":"bu", + } + ] + }, + }, + "request":{ + "method":"PUT", + "url":"Location/{{ Location_ID_NDL_10 }}", + }, +}, +{% endif -%} +{% if NDL.11 -%} +{ + "fullUrl":"urn:uuid:{{ Location_ID_NDL_11 }}", + "resource":{ + "resourceType": "Location", + "id":"{{ Location_ID_NDL_11 }}", + {% if Location_ID_NDL_10 -%} + "partOf":{ + "reference":"Location/{{Location_ID_NDL_10}}" + }, + {% endif %} + "name": "{{NDL.11.Value}}", + "mode":"instance", + {% assign NDLValue= NDL.Value%} + {% capture textstring %}{{ NDLValue | split: "^" | join: "--" }}{% endcapture -%} + {% capture specomp %}{{ textstring | split: "~" | join: "+" }}{% endcapture -%} + {% capture description %}{{ specomp | split: "&" | join: "--" }}{% endcapture -%} + "description" : "{{ description }}", + + "physicalType":{ + "coding":[ + { + "system":"http://terminology.hl7.org/CodeSystem/location-physical-type", + "code":"lvl", + } + ] + }, + }, + "request":{ + "method":"PUT", + "url":"Location/{{ Location_ID_NDL_11 }}", + }, +}, +{% endif -%} diff --git a/data/Templates/Hl7v2/DataType/_NDLPractitionerRole.liquid b/data/Templates/Hl7v2/DataType/_NDLPractitionerRole.liquid index 3f4de9f80..6f83ff129 100644 --- a/data/Templates/Hl7v2/DataType/_NDLPractitionerRole.liquid +++ b/data/Templates/Hl7v2/DataType/_NDLPractitionerRole.liquid @@ -1,7 +1,29 @@ {% if NDL -%} + "period": { "start":"{{ NDL.2.Value | format_as_date_time }}", "end":"{{ NDL.3.Value | format_as_date_time }}", }, + {% if NDL.4 or NDL.5 or NDL.6 or NDL.7 or NDL.10 or NDL.11 %} + {% if NDL.4 -%} + {% evaluate Location_ID_NDL using 'ID/Location' PL: NDL.4 -%} + {% elseif NDL.5 -%} + {% evaluate Location_ID_NDL using 'ID/Location' PL: NDL.5 -%} + {% elseif NDL.6 -%} + {% evaluate Location_ID_NDL using 'ID/Location' PL: NDL.6 -%} + {% elseif NDL.7 -%} + {% evaluate Location_ID_NDL using 'ID/Location' PL: NDL.7 -%} + {% elseif NDL.10 -%} + {% evaluate Location_ID_NDL using 'ID/Location' PL: NDL.10 -%} + {% elseif NDL.11 -%} + {% evaluate Location_ID_NDL using 'ID/Location' PL: NDL.11 -%} + {% endif %} + "location" : [ + { + "reference":"Location/{{ Location_ID_NDL }}", + } + ], + {% endif %} + {% endif -%} diff --git a/data/Templates/Hl7v2/DataType/_RITiming.liquid b/data/Templates/Hl7v2/DataType/_RITiming.liquid index e89180b91..e712c04c8 100644 --- a/data/Templates/Hl7v2/DataType/_RITiming.liquid +++ b/data/Templates/Hl7v2/DataType/_RITiming.liquid @@ -1,7 +1,13 @@ {% if RI -%} {% comment -%} Placeholder provided for customization by users. If left empty, it will be removed in post-processing. {% endcomment -%} - "code": + "code": { + "coding": + [ + { + "code": "{{RI.1}}", + } + ] }, "repeat": { @@ -11,3 +17,22 @@ ], }, {% endif -%} +{% if RI_val -%} + {% comment -%} Placeholder provided for customization by users. If left empty, it will be removed in post-processing. {% endcomment -%} + "code": + { + "coding": + [ + { + "code": "{{RI_val.1}}", + } + ] + }, + "repeat": + { + "timeOfDay": + [ + "{{ RI_val.2 }}", + ], + }, +{% endif -%} \ No newline at end of file diff --git a/data/Templates/Hl7v2/DataType/_RPAttachment.liquid b/data/Templates/Hl7v2/DataType/_RPAttachment.liquid index 0d636a813..3570e43d9 100644 --- a/data/Templates/Hl7v2/DataType/_RPAttachment.liquid +++ b/data/Templates/Hl7v2/DataType/_RPAttachment.liquid @@ -1,4 +1,14 @@ {% if RP -%} - "url":"http://example.com/v2-to-fhir-converter/CodeSystem/{{ RP.1.Value }}", - "contentType":"{{ RP.3.Value }}", + {% assign mimetype = RP.3.Value | get_property: 'CodeSystem/MimeType', 'code' -%} + {% if RP.4 -%} + {% if RP.4.Value == "Octet-stream" or RP.4.Value == "PostScript" -%} + {% assign mimesubtype = RP.3.Value | get_property: 'CodeSystem/MimeType', 'display' -%} + {% else -%} + {% assign mimesubtype = RP.4.Value | get_property: 'CodeSystem/MimeSubType', 'code' -%} + {% endif -%} + {% else -%} + {% assign mimesubtype = RP.3.Value | get_property: 'CodeSystem/MimeType', 'display' -%} + {% endif -%} + "contentType": "{{mimetype | append: "/" | append: mimesubtype}}", + "url":"{{ RP.1.Value }}", {% endif -%} \ No newline at end of file diff --git a/data/Templates/Hl7v2/DataType/_RPTTiming.liquid b/data/Templates/Hl7v2/DataType/_RPTTiming.liquid new file mode 100644 index 000000000..237e531f6 --- /dev/null +++ b/data/Templates/Hl7v2/DataType/_RPTTiming.liquid @@ -0,0 +1,59 @@ +{% if RPT -%} + {% if RPT.5 -%} + "period" : {{ RPT.5.Value }}, + {% endif -%} + "periodUnit" : {% include 'DataType/CWECode' mapping: 'CodeSystem/DurationUnit', CWE_internal: RPT.6 -%}, + "when" : [ + "{{ RPT.8.Value | get_property: 'CodeSystem/EventTiming', 'code' }}", + ], + {% if RPT.10.1 -%} + {% assign durationunit = RPT.10.1 | get_property: 'CodeSystem/DurationUnit', 'code' -%} + {% else -%} + {% assign durationunit = RPT.10.4 | get_property: 'CodeSystem/DurationUnit', 'code' -%} + {% endif -%} + {% if durationunit == 'min' -%} + {% if RPT.9 -%} + "offset" : {{ RPT.9.Value }}, + {% endif -%} + {% endif -%} + {% if durationunit == 's' -%} + {% if RPT.9 -%} + "offset" : {{ RPT.9.Value | divide: 60 | truncate_number }}, + {% endif -%} + {% endif -%} + {% if durationunit == 'h' -%} + {% if RPT.9 -%} + {% assign hour = RPT.9.Value | times: 1.0 %} + {% assign minutesDuration = hour | times: 60 %} + "offset" : {{ minutesDuration }}, + {% endif -%} + {% endif -%} + {% if durationunit == 'd' -%} + {% if RPT.9 -%} + {% assign day = RPT.9.Value | times: 1.0 %} + {% assign minutesDuration = day | times: 1440 %} + "offset" : {{ minutesDuration }}, + {% endif -%} + {% endif -%} + {% if durationunit == 'wk' -%} + {% if RPT.9 -%} + {% assign wk = RPT.9.Value | times: 1.0 %} + {% assign minutesDuration = wk | times: 10080 %} + "offset" : {{ minutesDuration }}, + {% endif -%} + {% endif -%} + {% if durationunit == 'mo' -%} + {% if RPT.9 -%} + {% assign mo = RPT.9.Value | times: 1.0 %} + {% assign minutesDuration = mo | times: 302400 %} + "offset" : {{ minutesDuration }}, + {% endif -%} + {% endif -%} + {% if durationunit == 'a' -%} + {% if RPT.9 -%} + {% assign year = RPT.9.Value | times: 1.0 %} + {% assign minutesDuration = year | times: 3628800 %} + "offset" : {{ minutesDuration }}, + {% endif -%} + {% endif -%} +{% endif -%} \ No newline at end of file diff --git a/data/Templates/Hl7v2/DataType/_TQServiceRequest.liquid b/data/Templates/Hl7v2/DataType/_TQServiceRequest.liquid index d9423d59e..d86b320b2 100644 --- a/data/Templates/Hl7v2/DataType/_TQServiceRequest.liquid +++ b/data/Templates/Hl7v2/DataType/_TQServiceRequest.liquid @@ -23,4 +23,4 @@ "count":"{{ TQ.12.Value }}", }, }, -{% endif -%} +{% endif -%} \ No newline at end of file diff --git a/data/Templates/Hl7v2/Extensions/Specimen/_SpecimenExtension.liquid b/data/Templates/Hl7v2/Extensions/Specimen/_SpecimenExtension.liquid new file mode 100644 index 000000000..935b5a316 --- /dev/null +++ b/data/Templates/Hl7v2/Extensions/Specimen/_SpecimenExtension.liquid @@ -0,0 +1,14 @@ +{ + "resource":{ + "resourceType": "Specimen", + "id":"{{ ID }}", + "collection": { + "extension": + [ + {% if SPM.15 -%} + {% include 'Extensions/Specimen-SpecialHandling' SPL_HANDLING: SPM.15 -%}, + {% endif -%} + ], + }, + }, +}, \ No newline at end of file diff --git a/data/Templates/Hl7v2/Extensions/_ObservationStatus.liquid b/data/Templates/Hl7v2/Extensions/_ObservationStatus.liquid index 23c1636d3..4129f8c1c 100644 --- a/data/Templates/Hl7v2/Extensions/_ObservationStatus.liquid +++ b/data/Templates/Hl7v2/Extensions/_ObservationStatus.liquid @@ -1,13 +1,7 @@ { "url": "http://example.com/v2-to-fhir-converter/Observation_Status", "valueCodeableConcept": { - "coding": - [ - { - {% include 'DataType/IDCodeableConcept' mapping: 'CodeSystem/ObservationStatus-ext', ID: ID -%} - }, - ], - "text": "{{ ID.1.Value | get_property: 'CodeSystem/ObservationStatus-ext', 'display' }}", -}, - + {% include 'DataType/CWECodeableConcept' mapping: 'CodeSystem/ObservationStatus-ext', CWE: ID -%} + "text": "{{ ID.1.Value | get_property: 'CodeSystem/ObservationStatus-ext', 'display' }}", + }, } \ No newline at end of file diff --git a/data/Templates/Hl7v2/Extensions/_Specimen-SpecialHandling.liquid b/data/Templates/Hl7v2/Extensions/_Specimen-SpecialHandling.liquid new file mode 100644 index 000000000..9c3be698a --- /dev/null +++ b/data/Templates/Hl7v2/Extensions/_Specimen-SpecialHandling.liquid @@ -0,0 +1,17 @@ +{ + {% if SPL_HANDLING -%} + "url": "http://hl7.org/fhir/StructureDefinition/specimen-specialHandling", + "valueCodeableConcept": + { + "coding": + [ + {% for specimen in SPL_HANDLING.Repeats -%} + {% if specimen -%} + {% assign hardcodedUrl = "http://terminology.hl7.org/CodeSystem/v2-0376" %} + {% include 'DataType/CWECodeableConceptRepeatable' CWE:specimen, systemHardcodedUrl: hardcodedUrl %} + {% endif -%} + {% endfor -%} + ], + } + {% endif -%} +} \ No newline at end of file diff --git a/data/Templates/Hl7v2/ID/_Appointment.liquid b/data/Templates/Hl7v2/ID/_Appointment.liquid index 80c5174cf..a5989c91a 100644 --- a/data/Templates/Hl7v2/ID/_Appointment.liquid +++ b/data/Templates/Hl7v2/ID/_Appointment.liquid @@ -1,6 +1,12 @@ {% capture identifiers -%} {% if NTE -%} {{NTE.3.Value}} + {% elsif SCH.1 -%} + {{SCH.1.Value}} + {% elsif SCH.2 -%} + {{SCH.2.Value}} + {% elsif SCH -%} + {{SCH.Value}} {% endif -%} {% endcapture -%} {{ identifiers | generate_id_input: 'Appointment', true, baseId | generate_uuid }} diff --git a/data/Templates/Hl7v2/ID/_Device.liquid b/data/Templates/Hl7v2/ID/_Device.liquid index 3ca8779fc..1d2a0996e 100644 --- a/data/Templates/Hl7v2/ID/_Device.liquid +++ b/data/Templates/Hl7v2/ID/_Device.liquid @@ -9,6 +9,10 @@ {{SFT.Value}} {% elsif EI -%} {{EI.Value}} + {% elsif AIG.3 -%} + {{AIG.3.Value}} + {% elsif AIG.4 -%} + {{AIG.4.Value}} {% endif -%} {% endcapture -%} {{ identifiers | generate_id_input: 'Device', false | generate_uuid }} diff --git a/data/Templates/Hl7v2/ID/_DiagnosticReport.liquid b/data/Templates/Hl7v2/ID/_DiagnosticReport.liquid index a7315b9c7..c715105c5 100644 --- a/data/Templates/Hl7v2/ID/_DiagnosticReport.liquid +++ b/data/Templates/Hl7v2/ID/_DiagnosticReport.liquid @@ -11,6 +11,8 @@ {{ORC.2.3.Value}},{{ORC.2.4.Value}} {% elsif ORC -%} {{ORC.Value}} + {% elsif OBX -%} + {{OBX.Value}} {% endif -%} {% endcapture -%} {{ identifiers | generate_id_input: 'DiagnosticReport', false, baseId | generate_uuid }} diff --git a/data/Templates/Hl7v2/ID/_DocumentReference.liquid b/data/Templates/Hl7v2/ID/_DocumentReference.liquid new file mode 100644 index 000000000..6b9cd0228 --- /dev/null +++ b/data/Templates/Hl7v2/ID/_DocumentReference.liquid @@ -0,0 +1,8 @@ +{% capture identifiers -%} + {% if EI.1 and EI.3 -%} + {{EI.1.Value}},{{EI.3.Value}} + {% elsif EI -%} + {{EI.Value}} + {% endif -%} +{% endcapture -%} +{{ identifiers | generate_id_input: 'DocumentReference', false | generate_uuid }} diff --git a/data/Templates/Hl7v2/ID/_Provenance.liquid b/data/Templates/Hl7v2/ID/_Provenance.liquid index e31110fcd..1495b1e20 100644 --- a/data/Templates/Hl7v2/ID/_Provenance.liquid +++ b/data/Templates/Hl7v2/ID/_Provenance.liquid @@ -1,6 +1,6 @@ {% capture identifiers -%} {% if MSH.3 -%} - {{MSH.4.Value}} + {{MSH.3.Value}} {% elsif MSH.3 and MSH.24-%} {{MSH.3.Value}},{{MSH.24.Value}} {% elsif MSH.5 and MSH.25-%} diff --git a/data/Templates/Hl7v2/ID/_ServiceRequest.liquid b/data/Templates/Hl7v2/ID/_ServiceRequest.liquid index 1bdf8e98a..35be94af6 100644 --- a/data/Templates/Hl7v2/ID/_ServiceRequest.liquid +++ b/data/Templates/Hl7v2/ID/_ServiceRequest.liquid @@ -13,10 +13,24 @@ {{OBR.2.3.Value}},{{OBR.2.4.Value}} {% elsif OBR -%} {{OBR.Value}} + {% elsif OBR_29_1 -%} + {{OBR_29_1.Value}} + {% elsif OBR_29_2 -%} + {{OBR_29_2.Value}} + {% elsif OBR_29 -%} + {{OBR_29.Value}} + {% elsif OBR_29.1 and OBR_29.2 -%} + {{OBR_29.1.Value}}, {{OBR_29.2.Value}} + {% elsif OBR_50 -%} + {{OBR_50.Value}} {% elsif NTE -%} {{NTE.Value}} {% elsif RF1 -%} {{RF1.Value}} + {% elsif AIS.3 -%} + {{AIS.3.Value}} + {% elsif AIS -%} + {{AIS.Value}} {% endif -%} {% endcapture -%} {{ identifiers | generate_id_input: 'ServiceRequest', true, baseId | generate_uuid }} diff --git a/data/Templates/Hl7v2/ID/_Specimen.liquid b/data/Templates/Hl7v2/ID/_Specimen.liquid index 9986eeeb2..b5de5ce3f 100644 --- a/data/Templates/Hl7v2/ID/_Specimen.liquid +++ b/data/Templates/Hl7v2/ID/_Specimen.liquid @@ -5,6 +5,8 @@ {{SPM.2.1.3}},{{SPM.2.1.4}} {% elsif SPM -%} {{SPM.Value}} + {% elsif OBR -%} + {{OBR.Value}} {% endif -%} {% endcapture -%} {{ identifiers | generate_id_input: 'Specimen', false, baseId | generate_uuid }} diff --git a/data/Templates/Hl7v2/MDM_T01.liquid b/data/Templates/Hl7v2/MDM_T01.liquid new file mode 100644 index 000000000..ba4b0551e --- /dev/null +++ b/data/Templates/Hl7v2/MDM_T01.liquid @@ -0,0 +1,407 @@ +{% assign firstSegments = hl7v2Data | get_first_segments: 'MSH|UAC|EVN|PID|PV1|TXA' -%} +{% assign sftSegmentLists = hl7v2Data | get_segment_lists: 'SFT' -%} +{% assign orcSegmentLists = hl7v2Data | get_segment_lists: 'ORC' -%} +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} + +{ + "resourceType": "Bundle", + "type": "batch", + {% if firstSegments.MSH.7 -%} + "timestamp":"{{ firstSegments.MSH.7.Value | format_as_date_time }}", + {% endif -%} + "identifier": + { + "value":"{{ firstSegments.MSH.10.Value }}", + }, + "id":"{{ bundleID }}", + "entry": [ + + {% evaluate patientId using 'ID/Patient' PID: firstSegments.PID, type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% evaluate messageHeaderId using 'ID/MessageHeader' MSH: firstSegments.MSH -%} + + {% if firstSegments.MSH -%} + + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, ID: messageHeaderId -%} + {% evaluate provenanceId using 'ID/Provenance' MSH: firstSegments.MSH, baseId: patientId -%} + {% include 'Resource/Provenance' Root_Template: 'MDM_T01', MSH: firstSegments.MSH, REF_BUNDLE: bundleID, ID: provenanceId -%} + + {%- comment -%} + {% assign transformation_val = 'provenance_transformation' %} + {% evaluate provenanceOrganizationId using 'ID/Organization', prov_id: firstSegments.MSH -%} + {% evaluate provenanceTransformationId using 'ID/Provenance_transformation' prov_id: transformation_val -%} + {% include 'Resource/Organization' org_name: 'Microsoft Corporation', ID: provenanceOrganizationId -%} + {% include 'Resource/Provenance_transformation' Root_Template: 'ADT_A01', Provenance_Organization_ID: provenanceOrganizationId, REF_MSH: messageHeaderId, provenanceOrganizationId, ID: provenanceTransformationId -%} + {%- endcomment -%} + + {% if firstSegments.MSH.4 -%} + {% if firstSegments.MSH.4.1 != "" and firstSegments.MSH.4.1 != null or firstSegments.MSH.4.2 != "" and firstSegments.MSH.4.2 != null or firstSegments.MSH.4.3 != "" and firstSegments.MSH.4.3 != null -%} + {% evaluate organization_ID_MSH_4 using 'ID/Organization' HD: firstSegments.MSH.4 -%} + {% include 'Resource/Organization' MSHHD1: firstSegments.MSH.4, MSH: firstSegments.MSH, ID: organization_ID_MSH_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.6 %} + {% if firstSegments.MSH.6.1 != "" and firstSegments.MSH.6.1 != null or firstSegments.MSH.6.2 != "" and firstSegments.MSH.6.2 != null or firstSegments.MSH.6.3 != "" and firstSegments.MSH.6.3 != null -%} + {% evaluate organization_Id_MSH_6 using 'ID/Organization' HD: firstSegments.MSH.6 -%} + {% include 'Resource/Organization' MSHHD2: firstSegments.MSH.6, MSH: firstSegments.MSH, ID: organization_Id_MSH_6 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.22 %} + {% if firstSegments.MSH.22.1 != "" and firstSegments.MSH.22.1 != null -%} + {% evaluate organization_Id_MSH_22 using 'ID/Organization' XON: firstSegments.MSH.22 -%} + {% include 'Resource/Organization' MSHXON1: firstSegments.MSH.22, ID: organization_Id_MSH_22 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.23 %} + {% if firstSegments.MSH.23.1 != "" and firstSegments.MSH.23.1 != null -%} + {% evaluate organization_Id_MSH_23 using 'ID/Organization' XON: firstSegments.MSH.23 -%} + {% include 'Resource/Organization' MSHXON2: firstSegments.MSH.23, ID: organization_Id_MSH_23 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.3 and firstSegments.MSH.24 %} + {% evaluate device_Id_MSH_3 using 'ID/Device' HD: firstSegments.MSH.3 -%} + {% include 'Resource/Device' MSH: firstSegments.MSH, ID: device_Id_MSH_3 -%} + {% endif -%} + + {% endif -%} + + {% for sftSegment in sftSegmentLists.SFT -%} + {% evaluate deviceId_SFT using 'ID/Device' SFT: sftSegment -%} + {% include 'Resource/Device' SFT:sftSegment, ID: deviceId_SFT -%} + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, SFT:sftSegment, ID: messageHeaderID -%} + {% endfor -%} + + {% if firstSegments.EVN -%} + {% evaluate provenanceId using 'ID/Provenance' EVN: firstSegments.EVN, baseId: patientId -%} + {% include 'Resource/Provenance' EVN: firstSegments.EVN, EVNTEXT: firstSegments.MSH.9, REF_BUNDLE: bundleID, ID: provenanceId -%} + {% if firstSegments.EVN.5 -%} + {% if firstSegments.EVN.5.9.1 != "" and firstSegments.EVN.5.9.1 != null and firstSegments.EVN.5.9.2 != "" and firstSegments.EVN.5.9.2 != null and firstSegments.EVN.5.9.3 != "" and firstSegments.EVN.5.9.3 != null -%} + {% evaluate Organization_ID_EVN_5_9 using 'ID/Organization' HDORG: firstSegments.EVN.5.9 -%} + {% include 'Resource/Organization', EVN: firstSegments.EVN.5.9, ID: Organization_ID_EVN_5_9 -%} + {% endif -%} + {% evaluate practitionerId_EVN_5 using 'ID/Practitioner' XCN: firstSegments.EVN.5 -%} + {% include 'Resource/Practitioner' EVN: firstSegments.EVN.5, ID: practitionerId_EVN_5 -%} + {% if firstSegments.EVN.7 -%} + {% evaluate locationId_EVN_7 using 'ID/Location' HD: firstSegments.EVN.7 -%} + {% include 'Resource/Location' EVN: firstSegments.EVN.7, ID: locationId_EVN_7 -%} + {% endif -%} + {% endif -%} + {% endif -%} + + {% include 'Resource/Patient' PID: firstSegments.PID, PD1: firstSegments.PD1, ID: patientId -%} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, PID: firstSegments.PID, PD1: firstSegments.PD1, PV1: firstSegments.PV1 -%} + + {% if firstSegments.PID.18 -%} + {% evaluate accountId using 'ID/Account' CX: firstSegments.PID.3 -%} + {% include 'Resource/Account' PID: firstSegments.PID, ID: accountId -%} + {% include 'Reference/Account/Subject' ID: accountId, REF: fullPatientId -%} + {% if firstSegments.PID.18.4.1 != "" and firstSegments.PID.18.4.1 != null and firstSegments.PID.18.4.2 != "" and firstSegments.PID.18.4.2 != null and firstSegments.PID.18.4.3 != "" and firstSegments.PID.18.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_18 using 'ID/Organization' HDORG: firstSegments.PID.18.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.18, ID: Organization_ID_pid_CX_18 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PID.2 -%} + {% if firstSegments.PID.2.4.1 != "" and firstSegments.PID.2.4.1 != null and firstSegments.PID.2.4.2 != "" and firstSegments.PID.2.4.2 != null and firstSegments.PID.2.4.3 != "" and firstSegments.PID.2.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_2 using 'ID/Organization' HDORG: firstSegments.PID.2.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.2, ID: Organization_ID_pid_CX_2 -%} + {% endif -%} + {% endif -%} + + {% for pid3 in firstSegments.PID.3.Repeats -%} + {% if pid3.4.1 != "" and pid3.4.1 != null and pid3.4.2 != "" and pid3.4.2 != null and pid3.4.3 != "" and pid3.4.3 != null -%} + {% evaluate Organization_ID_pid_CX using 'ID/Organization' HDORG: pid3.4 -%} + {% include 'Resource/Organization', PID: pid3, ID: Organization_ID_pid_CX -%} + {% endif -%} + {% endfor -%} + + {% if firstSegments.PID.4 -%} + {% if firstSegments.PID.4.4.1 != "" and firstSegments.PID.4.4.1 != null and firstSegments.PID.4.4.2 != "" and firstSegments.PID.4.4.2 != null and firstSegments.PID.4.4.3 != "" and firstSegments.PID.4.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_4 using 'ID/Organization' HDORG: firstSegments.PID.4.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.4, ID: Organization_ID_pid_CX_4 -%} + {% endif -%} + {% endif -%} + + {% unless nk1SegmentLists.NK1 -%} + {% if firstSegments.PID.21 -%} + {% if firstSegments.PID.21.4.1 != "" and firstSegments.PID.21.4.1 != null and firstSegments.PID.21.4.2 != "" and firstSegments.PID.21.4.2 != null and firstSegments.PID.21.4.3 != "" and firstSegments.PID.21.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_21 using 'ID/Organization' HDORG: firstSegments.PID.21.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.21, ID: Organization_ID_pid_CX_21 -%} + {% endif -%} + {% evaluate pidrelatedPersonId using 'ID/RelatedPerson' PID: firstSegments.PID, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: pidrelatedPersonId, PID: firstSegments.PID -%} + {% endif -%} + {% endunless -%} + + {% if firstSegments.PV1 -%} + {% if firstSegments.PV1.5 -%} + {% if firstSegments.PV1.5.4.1 != "" and firstSegments.PV1.5.4.1 != null and firstSegments.PV1.5.4.2 != "" and firstSegments.PV1.5.4.2 != null and firstSegments.PV1.5.4.3 != "" and firstSegments.PV1.5.4.3 != null -%} + {% evaluate Organization_ID_PV1_5_4 using 'ID/Organization' HDORG: firstSegments.PV1.5.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.5.4, ID: Organization_ID_PV1_5_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PV1.19 -%} + {% if firstSegments.PV1.19.4.1 != "" and firstSegments.PV1.19.4.1 != null and firstSegments.PV1.19.4.2 != "" and firstSegments.PV1.19.4.2 != null and firstSegments.PV1.19.4.3 != "" and firstSegments.PV1.19.4.3 != null -%} + {% evaluate Organization_ID_PV1_19_4 using 'ID/Organization' HDORG: firstSegments.PV1.19.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.19.4, ID: Organization_ID_PV1_19_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PV1.7 -%} + {% if firstSegments.PV1.7.9.1 != "" and firstSegments.PV1.7.9.1 != null and firstSegments.PV1.7.9.2 != "" and firstSegments.PV1.7.9.2 != null and firstSegments.PV1.7.9.3 != "" and firstSegments.PV1.7.9.3 != null -%} + {% evaluate Organization_ID_PV1_7_9 using 'ID/Organization' HDORG: firstSegments.PV1.7.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.7.9, ID: Organization_ID_PV1_7_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_7 using 'ID/Practitioner' XCN: firstSegments.PV1.7 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.7, ID: practitionerId_PV1_7 -%} + {% endif -%} + + {% if firstSegments.PV1.8 -%} + {% if firstSegments.PV1.8.9.1 != "" and firstSegments.PV1.8.9.1 != null and firstSegments.PV1.8.9.2 != "" and firstSegments.PV1.8.9.2 != null and firstSegments.PV1.8.9.3 != "" and firstSegments.PV1.8.9.3 != null -%} + {% evaluate Organization_ID_PV1_8_9 using 'ID/Organization' HDORG: firstSegments.PV1.8.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.8.9, ID: Organization_ID_PV1_8_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_8 using 'ID/Practitioner' XCN: firstSegments.PV1.8 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.8, ID: practitionerId_PV1_8 -%} + {% endif -%} + + {% if firstSegments.PV1.9 -%} + {% if firstSegments.PV1.9.9.1 != "" and firstSegments.PV1.9.9.1 != null and firstSegments.PV1.9.9.2 != "" and firstSegments.PV1.9.9.2 != null and firstSegments.PV1.9.9.3 != "" and firstSegments.PV1.9.9.3 != null -%} + {% evaluate Organization_ID_PV1_9_9 using 'ID/Organization' HDORG: firstSegments.PV1.9.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.9.9, ID: Organization_ID_PV1_9_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_9 using 'ID/Practitioner' XCN: firstSegments.PV1.9 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.9, ID: practitionerId_PV1_9 -%} + {% endif -%} + + {% if firstSegments.PV1.17 -%} + {% if firstSegments.PV1.17.9.1 != "" and firstSegments.PV1.17.9.1 != null and firstSegments.PV1.17.9.2 != "" and firstSegments.PV1.17.9.2 != null and firstSegments.PV1.17.9.3 != "" and firstSegments.PV1.17.9.3 != null -%} + {% evaluate Organization_ID_PV1_17_9 using 'ID/Organization' HDORG: firstSegments.PV1.17.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.17.9, ID: Organization_ID_PV1_17_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_17 using 'ID/Practitioner' XCN: firstSegments.PV1.17 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.17, ID: practitionerId_PV1_17 -%} + {% endif -%} + + {% if firstSegments.PV1.50 -%} + {% for p in firstSegments.PV1.50.Repeats -%} + {% if p.4.1 != "" and p.4.1 != null and p.4.2 != "" and p.4.2 != null and p.4.3 != "" and p.4.3 != null -%} + {% evaluate Organization_ID_PV1_50_4 using 'ID/Organization' HDORG: p.4 -%} + {% include 'Resource/Organization', PV1: p.4, ID: Organization_ID_PV1_50_4 -%} + {% endif -%} + {% endfor -%} + {% endif -%} + + {% if firstSegments.PV1.52 -%} + {% if firstSegments.PV1.52.9.1 != "" and firstSegments.PV1.52.9.1 != null and firstSegments.PV1.52.9.2 != "" and firstSegments.PV1.52.9.2 != null and firstSegments.PV1.52.9.3 != "" and firstSegments.PV1.52.9.3 != null -%} + {% evaluate Organization_ID_PV1_52_9 using 'ID/Organization' HDORG: firstSegments.PV1.52.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.52.9, ID: Organization_ID_PV1_52_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_52 using 'ID/Practitioner' XCN: firstSegments.PV1.52 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.52, ID: practitionerId_PV1_52 -%} + {% endif -%} + + {% if firstSegments.PV1.3 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.3-%} + {% endif -%} + + {% if firstSegments.PV1.6 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.6 -%} + {% endif -%} + + {% if firstSegments.PV1.37 -%} + {% evaluate location_ID_PV1_37 using 'ID/Location' DLD: firstSegments.PV1.37 -%} + {% include 'Resource/Location' PV1: firstSegments.PV1.37, ID: location_ID_PV1_37-%} + {% endif -%} + + {% if firstSegments.PV1.42 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.42-%} + {% endif -%} + + {% if firstSegments.PV1.43 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.43-%} + {% endif -%} + + {% if firstSegments.PV1.54 -%} + {% if firstSegments.PV1.54.4.1 != "" and firstSegments.PV1.54.4.1 != null and firstSegments.PV1.54.4.2 != "" and firstSegments.PV1.54.4.2 != null and firstSegments.PV1.54.4.3 != "" and firstSegments.PV1.54.4.3 != null -%} + {% evaluate Organization_ID_PV1_54_4 using 'ID/Organization' HDORG: firstSegments.PV1.54.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.54.4, ID: Organization_ID_PV1_54_4 -%} + {% endif -%} + {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: firstSegments.PV1.54 -%} + {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId -%} + {% endif -%} + + {% evaluate encounterId using 'ID/Encounter' PV1: firstSegments.PV1, baseId: patientId -%} + {% include 'Resource/Encounter' Root_Template: 'MDM_T01', PV1: firstSegments.PV1, ID: encounterId -%} + {% include 'Reference/Encounter/Subject' ID: encounterId, REF: fullPatientId -%} + {% include 'Extensions/Encounter/EncounterExtension' ID: encounterId, PV1: firstSegments.PV1 -%} + {% endif -%} + + {% if firstSegments.TXA -%} + + {% evaluate documentreferenceID using 'ID/DocumentReference' EI: firstSegments.TXA.12 -%} + {% include 'Resource/DocumentReference' TXA: firstSegments.TXA, ID: documentreferenceID -%} + + {% if firstSegments.TXA.5 -%} + {% for txa_5 in firstSegments.TXA.5.Repeats -%} + {% if txa_5.9.1 != "" and txa_5.9.1 != null and txa_5.9.2 != "" and txa_5.9.2 != null and txa_5.9.3 != "" and txa_5.9.3 != null -%} + {% evaluate Organization_ID_TXA_5_9 using 'ID/Organization' HDORG: txa_5.9.9 -%} + {% include 'Resource/Organization', TXA: txa_5.5.9, ID: Organization_ID_TXA_5_9 -%} + {% endif -%} + {% evaluate practitionerId_TXA_5 using 'ID/Practitioner' XCN: txa_5 -%} + {% include 'Resource/Practitioner' TXA: txa_5, ID: practitionerId_TXA_5 -%} + {% endfor -%} + {% endif -%} + {% if firstSegments.TXA.9 -%} + {% for txa_9 in firstSegments.TXA.9.Repeats -%} + {% if txa_9.Value != null and txa_9.Value != "" -%} + {% if txa_9.9.1 != "" and txa_9.9.1 != null and txa_9.9.2 != "" and txa_9.9.2 != null and txa_9.9.3 != "" and txa_9.9.3 != null -%} + {% evaluate Organization_ID_TXA_9_9 using 'ID/Organization' HDORG: txa_9.9.9 -%} + {% include 'Resource/Organization', TXA: txa_9.9.9, ID: Organization_ID_TXA_9_9 -%} + {% endif -%} + {% evaluate practitionerId_TXA_9 using 'ID/Practitioner' XCN: txa_9 -%} + {% include 'Resource/Practitioner' TXA: txa_9, ID: practitionerId_TXA_9 -%} + + {% evaluate practitionerRoleId_TXA9 using 'ID/PractitionerRole' XCN: txa_9 -%} + {% include 'Resource/PractitionerRole' practitionerId_TXA: practitionerId_TXA_9, ID: practitionerRoleId_TXA9 -%} + {% endif -%} + {% endfor -%} + {% endif -%} + + {% if firstSegments.TXA.10.Repeats[0] -%} + {% assign txa_10 = firstSegments.TXA.10.Repeats[0] -%} + {% if txa_10.9.1 != "" and txa_10.9.1 != null and txa_10.9.2 != "" and txa_10.9.2 != null and txa_10.9.3 != "" and txa_10.9.3 != null -%} + {% evaluate Organization_ID_TXA_10_9 using 'ID/Organization' HDORG: txa_10.9.9 -%} + {% include 'Resource/Organization', TXA: txa_10.9.9, ID: Organization_ID_TXA_10_9 -%} + {% endif -%} + {% evaluate practitionerId_TXA_10 using 'ID/Practitioner' XCN: txa_10 -%} + {% include 'Resource/Practitioner' TXA: txa_10, ID: practitionerId_TXA_10 -%} + + {% evaluate practitionerRoleId_TXA10 using 'ID/PractitionerRole' XCN: txa_10 -%} + {% include 'Resource/PractitionerRole' practitionerId_TXA: practitionerId_TXA_10, ID: practitionerRoleId_TXA10 -%} + + {% endif -%} + {% endif -%} + + {% assign obrSegmentPositionIndex_orc = 0 -%} + {% for orcSegment in orcSegmentLists.ORC -%} + + {% assign obrSegmentLists = hl7v2Data | get_related_segment_list: orcSegment, 'OBR' -%} + {% assign tq1SegmentLists = hl7v2Data | get_related_segment_list: orcSegment, 'TQ1' -%} + + {% for obrSegment in obrSegmentLists.OBR -%} + {% assign checkParent = hl7v2Data | get_parent_segment: 'OBR', {{obrSegmentPositionIndex_orc}}, 'ORC' -%} + {% assign obrSegmentPositionIndex_orc = obrSegmentPositionIndex_orc | plus: 1 -%} + + {% evaluate parentServiceRequestId_orc using 'ID/ServiceRequest' ORC: checkParent.ORC.31, baseId: patientId -%} + {% if obrSegment.29.Value == null %} + {% if checkParent.ORC.8 and checkParent.ORC.31 %} + {% include 'Resource/ServiceRequest' OBR: obrSegment, ORC: checkParent.ORC, ID: parentServiceRequestId_orc, ServiceRequest_Subject_ID: fullPatientId, type_msg: "MDM_T01" -%} + {% endif %} + {% endif %} + + {% evaluate serviceRequestId using 'ID/ServiceRequest' OBR: obrSegment, baseId: patientId -%} + + {% evaluate specimenId_obr using 'ID/Specimen' OBR: obrSegment -%} + {% assign fullSpecimenId_obr = specimenId_obr | prepend: 'Specimen/' -%} + {% evaluate parentServiceRequestId using 'ID/ServiceRequest' OBR_29: obrSegment.29, baseId: patientId -%} + {% include 'Resource/ServiceRequest' OBR_child: obrSegment, parentSegment: checkParent.ORC, ServiceRequest_Subject_ID: fullPatientId, ServiceRequest_ID_OBR_29: parentServiceRequestId, ServiceRequest_ID_ORC_8: parentServiceRequestId_orc, ID: serviceRequestId, type_msg: "MDM_T01" -%} + + {% assign fullDocumentreferenceID = documentreferenceID | prepend: 'DocumentReference/' -%} + {% include 'Reference/ServiceRequest/ReasonReference' ID: serviceRequestId, REF: fullDocumentreferenceID -%} + + {% evaluate practitionerId_ORC_12 using 'ID/Practitioner' XCN: checkParent.ORC.12.Repeats[0] -%} + {% if obrSegment.16 -%} + {% if obrSegment.16.Repeats[0] %} + {% if obrSegment.16.Repeats[0].9.1 != "" and obrSegment.16.Repeats[0].9.1 != null and obrSegment.16.Repeats[0].9.2 != "" and obrSegment.16.Repeats[0].9.2 != null and obrSegment.16.Repeats[0].9.3 != "" and obrSegment.16.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_OBR16 using 'ID/Organization' HDORG: obrSegment.16.Repeats[0].9 -%} + {% include 'Resource/Organization' OBR_SEG_16: obrSegment.16.Repeats[0].9, ID: Organization_ID_OBR16 -%} + {% endif -%} + {% endif -%} + {% evaluate practitionerId_OBR_16 using 'ID/Practitioner' XCN: obrSegment.16.Repeats[0] -%} + {% include 'Resource/Practitioner' OBR_SEG: obrSegment, OBRXCN_16: obrSegment.16.Repeats[0], ORC_SEG_24: checkParent.ORC.24, ID: practitionerId_OBR_16 -%} + {% evaluate practitionerRoleId_OBR_16 using 'ID/PractitionerRole' XCN: obrSegment.16.Repeats[0]-%} + {% include 'Resource/PractitionerRole' OBR: obrSegment, requestor_practitioner1: practitionerId_OBR_16, ID: practitionerRoleId_OBR_16 -%} + {% assign fullpractitionerRoleId_OBR_16 = practitionerRoleId_OBR_16 | prepend: 'PractitionerRole/' -%} + {% include 'Reference/ServiceRequest/Requester' REF: fullpractitionerRoleId_OBR_16, ID: serviceRequestId -%} + {% else %} + {% if checkParent.ORC.12 %} + {% if checkParent.ORC.12.Repeats[0].9.1 != "" and checkParent.ORC.12.Repeats[0].9.1 != null and checkParent.ORC.12.Repeats[0].9.2 != "" and checkParent.ORC.12.Repeats[0].9.2 != null and checkParent.ORC.12.Repeats[0].9.3 != "" and checkParent.ORC.12.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_ORC_12 using 'ID/Organization' HDORG: checkParent.ORC.12.Repeats[0].9 -%} + {% include 'Resource/Organization' ORC_SEG_12: checkParent.ORC.12.Repeats[0].9, ID: Organization_ID_ORC_12 -%} + {% endif -%} + {% include 'Resource/Practitioner' ORC_SEG: checkParent.ORC, ORCXCN_12: checkParent.ORC.12.Repeats[0], ORC_SEG_24: checkParent.ORC.24, ID: practitionerId_ORC_12 -%} + {% evaluate practitionerRoleId_ORC_12 using 'ID/PractitionerRole' XCN: checkParent.ORC.12.Repeats[0]-%} + {% include 'Resource/PractitionerRole' ORC: checkParent.ORC, requestor_practitioner2: practitionerId_ORC_12, ID: practitionerRoleId_ORC_12 -%} + {% assign fullPractitionerRoleId_ORC_12 = practitionerRoleId_ORC_12 | prepend: 'PractitionerRole/' -%} + {% include 'Reference/ServiceRequest/Requester' REF: fullPractitionerRoleId_ORC_12, ID: serviceRequestId -%} + {% else %} + {% if checkParent.ORC.21 %} + {% evaluate organizationId_ORC_21 using 'ID/Organization' XON: checkParent.ORC.21.Repeats[0] -%} + {% if checkParent.ORC.12.Repeats[0] == null or checkParent.ORC.12.Repeats[0] == "" and obrSegment.16 == null or obrSegment.16 == "" %} + {% include 'Resource/Organization' ORC_SEG: checkParent.ORC, ORC_SEG_22: checkParent.ORC.22, ORC_SEG_23: checkParent.ORC.23, ID: organizationId_ORC_21 -%} + {% endif %} + {% evaluate practitionerRoleId_ORC_21 using 'ID/PractitionerRole' XCN: checkParent.ORC.21.Repeats[0]-%} + {% include 'Resource/PractitionerRole' ORC: checkParent.ORC, requestor_organization: organizationId_ORC_21, ID: practitionerRoleId_ORC_21 -%} + {% assign fullPractitionerRoleId_ORC_21 = practitionerRoleId_ORC_21 | prepend: 'PractitionerRole/' -%} + {% include 'Reference/ServiceRequest/Requester' REF: fullPractitionerRoleId_ORC_21, ID: serviceRequestId -%} + {% endif %} + {% endif -%} + {% endif %} + + {% include 'Reference/ServiceRequest/Specimen' REF: fullSpecimenId_obr, ID: serviceRequestId -%} + + {% if obrSegment.29 %} + {% if obrSegment.50 -%} + {% evaluate parentServiceRequestId using 'ID/ServiceRequest' OBR_29: obrSegment.29, baseId: patientId -%} + {% include 'Resource/ServiceRequest' OBR_parent: obrSegment, parentSegment: checkParent.ORC, ServiceRequest_Subject_ID: fullPatientId, ID: parentServiceRequestId, type_msg: "MDM_T01" -%} + {% endif %} + {% endif %} + + {% assign fullParentServiceRequestId = parentServiceRequestId | prepend: 'ServiceRequest/' -%} + + {% assign nteSegmentLists1 = hl7v2Data | get_related_segment_list: obrSegment, 'NTE' -%} + {% for nteSegment1 in nteSegmentLists1.NTE -%} + {% if nteSegment1.5 -%} + {% if nteSegment1.5.9.1 != "" and nteSegment1.5.9.1 != null and nteSegment1.5.9.2 != "" and nteSegment1.5.9.2 != null and nteSegment1.5.9.3 != "" and nteSegment1.5.9.3 != null -%} + {% evaluate Organization_ID_NTE1_5_9 using 'ID/Organization' HDORG: nteSegment1.5.9 -%} + {% include 'Resource/Organization' OBR_NTE: nteSegment1.5.9, ID: Organization_ID_NTE1_5_9 -%} + {% endif -%} + {% evaluate practitioner_ID_NTE_5 using 'ID/Practitioner' XCN: nteSegment1.5 -%} + {% include 'Resource/Practitioner' NTE: nteSegment1.5, ID: practitioner_ID_NTE_5 -%} + {% endif -%} + {% include 'Resource/ServiceRequest' NTE: nteSegment1, ID: serviceRequestId -%} + {% endfor -%} + + {% assign fullServiceRequestId = serviceRequestId | prepend: 'ServiceRequest/' -%} + {% include 'Resource/Specimen' OBR: obrSegment, ID: specimenId_obr -%} + + {% if obrSegment.10 %} + {% if obrSegment.10.Repeats[0].9.1 != "" and obrSegment.10.Repeats[0].9.1 != null and obrSegment.10.Repeats[0].9.2 != "" and obrSegment.10.Repeats[0].9.2 != null and obrSegment.10.Repeats[0].9.3 != "" and obrSegment.10.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_OBR10 using 'ID/Organization' HDORG: obrSegment.10.Repeats[0].9 -%} + {% include 'Resource/Organization' OBR_SEG_10: obrSegment.10.Repeats[0].9, ID: Organization_ID_OBR10 -%} + {% endif -%} + {% evaluate practitionerId_OBR_10 using 'ID/Practitioner' XCN: obrSegment.10.Repeats[0] -%} + {% include 'Resource/Practitioner' OBR_SEG: obrSegment, OBRXCN_10: obrSegment.10.Repeats[0], ID: practitionerId_OBR_10 -%} + {% evaluate practitionerRoleId_OBR_10 using 'ID/PractitionerRole' XCN: obrSegment.10.Repeats[0] -%} + {% assign full_practitionerId_obr_10 = practitionerRoleId_OBR_10 | prepend: 'PractitionerRole/' %} + {% include 'Resource/PractitionerRole' OBR: obrSegment, collection_collector_practitioner: practitionerId_obr_10, ID: practitionerRoleId_OBR_10 -%} + {% include 'Reference/Specimen/Collection_Collector' REF: full_practitionerId_obr_10, ID: specimenId_obr -%} + {% endif -%} + {% endfor -%} + + {% unless tq1SegmentLists.TQ1 -%} + {% include 'Resource/ServiceRequest' ID: serviceRequestId, OBR_tq1: obrSegmentLists.OBR[0], ORC_tq1: orcSegment -%} + {% endunless -%} + + {% for tq1Segment in tq1SegmentLists.TQ1 -%} + {% include 'Resource/ServiceRequest' TQ1: tq1Segment, ID: serviceRequestId, OBR_timeday: obrSegmentLists.OBR[0] -%} + {% endfor -%} + + {% endfor -%} + ] +} \ No newline at end of file diff --git a/data/Templates/Hl7v2/MDM_T02.liquid b/data/Templates/Hl7v2/MDM_T02.liquid new file mode 100644 index 000000000..ca7377017 --- /dev/null +++ b/data/Templates/Hl7v2/MDM_T02.liquid @@ -0,0 +1,498 @@ +{% assign firstSegments = hl7v2Data | get_first_segments: 'MSH|UAC|EVN|PID|PV1|TXA' -%} +{% assign sftSegmentLists = hl7v2Data | get_segment_lists: 'SFT' -%} +{% assign orcSegmentLists = hl7v2Data | get_segment_lists: 'ORC' -%} +{% assign obxSegmentLists = hl7v2Data | get_segment_lists: 'OBX' -%} +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} + +{ + "resourceType": "Bundle", + "type": "batch", + {% if firstSegments.MSH.7 -%} + "timestamp":"{{ firstSegments.MSH.7.Value | format_as_date_time }}", + {% endif -%} + "identifier": + { + "value":"{{ firstSegments.MSH.10.Value }}", + }, + "id":"{{ bundleID }}", + "entry": [ + + {% evaluate patientId using 'ID/Patient' PID: firstSegments.PID, type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% evaluate messageHeaderId using 'ID/MessageHeader' MSH: firstSegments.MSH -%} + + {% if firstSegments.MSH -%} + + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, ID: messageHeaderId -%} + {% evaluate provenanceId using 'ID/Provenance' MSH: firstSegments.MSH, baseId: patientId -%} + {% include 'Resource/Provenance' Root_Template: 'MDM_T02', MSH: firstSegments.MSH, REF_BUNDLE: bundleID, ID: provenanceId -%} + + {%- comment -%} + {% assign transformation_val = 'provenance_transformation' %} + {% evaluate provenanceOrganizationId using 'ID/Organization', prov_id: firstSegments.MSH -%} + {% evaluate provenanceTransformationId using 'ID/Provenance_transformation' prov_id: transformation_val -%} + {% include 'Resource/Organization' org_name: 'Microsoft Corporation', ID: provenanceOrganizationId -%} + {% include 'Resource/Provenance_transformation' Root_Template: 'ADT_A01', Provenance_Organization_ID: provenanceOrganizationId, REF_MSH: messageHeaderId, provenanceOrganizationId, ID: provenanceTransformationId -%} + {%- endcomment -%} + + {% if firstSegments.MSH.4 -%} + {% if firstSegments.MSH.4.1 != "" and firstSegments.MSH.4.1 != null or firstSegments.MSH.4.2 != "" and firstSegments.MSH.4.2 != null or firstSegments.MSH.4.3 != "" and firstSegments.MSH.4.3 != null -%} + {% evaluate organization_ID_MSH_4 using 'ID/Organization' HD: firstSegments.MSH.4 -%} + {% include 'Resource/Organization' MSHHD1: firstSegments.MSH.4, MSH: firstSegments.MSH, ID: organization_ID_MSH_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.6 %} + {% if firstSegments.MSH.6.1 != "" and firstSegments.MSH.6.1 != null or firstSegments.MSH.6.2 != "" and firstSegments.MSH.6.2 != null or firstSegments.MSH.6.3 != "" and firstSegments.MSH.6.3 != null -%} + {% evaluate organization_Id_MSH_6 using 'ID/Organization' HD: firstSegments.MSH.6 -%} + {% include 'Resource/Organization' MSHHD2: firstSegments.MSH.6, MSH: firstSegments.MSH, ID: organization_Id_MSH_6 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.22 %} + {% if firstSegments.MSH.22.1 != "" and firstSegments.MSH.22.1 != null -%} + {% evaluate organization_Id_MSH_22 using 'ID/Organization' XON: firstSegments.MSH.22 -%} + {% include 'Resource/Organization' MSHXON1: firstSegments.MSH.22, ID: organization_Id_MSH_22 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.23 %} + {% if firstSegments.MSH.23.1 != "" and firstSegments.MSH.23.1 != null -%} + {% evaluate organization_Id_MSH_23 using 'ID/Organization' XON: firstSegments.MSH.23 -%} + {% include 'Resource/Organization' MSHXON2: firstSegments.MSH.23, ID: organization_Id_MSH_23 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.3 and firstSegments.MSH.24 %} + {% evaluate device_Id_MSH_3 using 'ID/Device' HD: firstSegments.MSH.3 -%} + {% include 'Resource/Device' MSH: firstSegments.MSH, ID: device_Id_MSH_3 -%} + {% endif -%} + + {% endif -%} + + {% for sftSegment in sftSegmentLists.SFT -%} + {% evaluate deviceId_SFT using 'ID/Device' SFT: sftSegment -%} + {% include 'Resource/Device' SFT:sftSegment, ID: deviceId_SFT -%} + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, SFT:sftSegment, ID: messageHeaderID -%} + {% endfor -%} + + {% if firstSegments.EVN -%} + {% evaluate provenanceId using 'ID/Provenance' EVN: firstSegments.EVN, baseId: patientId -%} + {% include 'Resource/Provenance' EVN: firstSegments.EVN, EVNTEXT: firstSegments.MSH.9, REF_BUNDLE: bundleID, ID: provenanceId -%} + {% if firstSegments.EVN.5 -%} + {% if firstSegments.EVN.5.9.1 != "" and firstSegments.EVN.5.9.1 != null and firstSegments.EVN.5.9.2 != "" and firstSegments.EVN.5.9.2 != null and firstSegments.EVN.5.9.3 != "" and firstSegments.EVN.5.9.3 != null -%} + {% evaluate Organization_ID_EVN_5_9 using 'ID/Organization' HDORG: firstSegments.EVN.5.9 -%} + {% include 'Resource/Organization', EVN: firstSegments.EVN.5.9, ID: Organization_ID_EVN_5_9 -%} + {% endif -%} + {% evaluate practitionerId_EVN_5 using 'ID/Practitioner' XCN: firstSegments.EVN.5 -%} + {% include 'Resource/Practitioner' EVN: firstSegments.EVN.5, ID: practitionerId_EVN_5 -%} + {% if firstSegments.EVN.7 -%} + {% evaluate locationId_EVN_7 using 'ID/Location' HD: firstSegments.EVN.7 -%} + {% include 'Resource/Location' EVN: firstSegments.EVN.7, ID: locationId_EVN_7 -%} + {% endif -%} + {% endif -%} + {% endif -%} + + {% include 'Resource/Patient' PID: firstSegments.PID, PD1: firstSegments.PD1, ID: patientId -%} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, PID: firstSegments.PID, PD1: firstSegments.PD1, PV1: firstSegments.PV1 -%} + + {% if firstSegments.PID.18 -%} + {% evaluate accountId using 'ID/Account' CX: firstSegments.PID.3 -%} + {% include 'Resource/Account' PID: firstSegments.PID, ID: accountId -%} + {% include 'Reference/Account/Subject' ID: accountId, REF: fullPatientId -%} + {% if firstSegments.PID.18.4.1 != "" and firstSegments.PID.18.4.1 != null and firstSegments.PID.18.4.2 != "" and firstSegments.PID.18.4.2 != null and firstSegments.PID.18.4.3 != "" and firstSegments.PID.18.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_18 using 'ID/Organization' HDORG: firstSegments.PID.18.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.18, ID: Organization_ID_pid_CX_18 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PID.2 -%} + {% if firstSegments.PID.2.4.1 != "" and firstSegments.PID.2.4.1 != null and firstSegments.PID.2.4.2 != "" and firstSegments.PID.2.4.2 != null and firstSegments.PID.2.4.3 != "" and firstSegments.PID.2.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_2 using 'ID/Organization' HDORG: firstSegments.PID.2.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.2, ID: Organization_ID_pid_CX_2 -%} + {% endif -%} + {% endif -%} + + {% for pid3 in firstSegments.PID.3.Repeats -%} + {% if pid3.4.1 != "" and pid3.4.1 != null and pid3.4.2 != "" and pid3.4.2 != null and pid3.4.3 != "" and pid3.4.3 != null -%} + {% evaluate Organization_ID_pid_CX using 'ID/Organization' HDORG: pid3.4 -%} + {% include 'Resource/Organization', PID: pid3, ID: Organization_ID_pid_CX -%} + {% endif -%} + {% endfor -%} + + {% if firstSegments.PID.4 -%} + {% if firstSegments.PID.4.4.1 != "" and firstSegments.PID.4.4.1 != null and firstSegments.PID.4.4.2 != "" and firstSegments.PID.4.4.2 != null and firstSegments.PID.4.4.3 != "" and firstSegments.PID.4.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_4 using 'ID/Organization' HDORG: firstSegments.PID.4.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.4, ID: Organization_ID_pid_CX_4 -%} + {% endif -%} + {% endif -%} + + {% unless nk1SegmentLists.NK1 -%} + {% if firstSegments.PID.21 -%} + {% if firstSegments.PID.21.4.1 != "" and firstSegments.PID.21.4.1 != null and firstSegments.PID.21.4.2 != "" and firstSegments.PID.21.4.2 != null and firstSegments.PID.21.4.3 != "" and firstSegments.PID.21.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_21 using 'ID/Organization' HDORG: firstSegments.PID.21.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.21, ID: Organization_ID_pid_CX_21 -%} + {% endif -%} + {% evaluate pidrelatedPersonId using 'ID/RelatedPerson' PID: firstSegments.PID, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: pidrelatedPersonId, PID: firstSegments.PID -%} + {% endif -%} + {% endunless -%} + + {% if firstSegments.PV1 -%} + {% if firstSegments.PV1.5 -%} + {% if firstSegments.PV1.5.4.1 != "" and firstSegments.PV1.5.4.1 != null and firstSegments.PV1.5.4.2 != "" and firstSegments.PV1.5.4.2 != null and firstSegments.PV1.5.4.3 != "" and firstSegments.PV1.5.4.3 != null -%} + {% evaluate Organization_ID_PV1_5_4 using 'ID/Organization' HDORG: firstSegments.PV1.5.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.5.4, ID: Organization_ID_PV1_5_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PV1.19 -%} + {% if firstSegments.PV1.19.4.1 != "" and firstSegments.PV1.19.4.1 != null and firstSegments.PV1.19.4.2 != "" and firstSegments.PV1.19.4.2 != null and firstSegments.PV1.19.4.3 != "" and firstSegments.PV1.19.4.3 != null -%} + {% evaluate Organization_ID_PV1_19_4 using 'ID/Organization' HDORG: firstSegments.PV1.19.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.19.4, ID: Organization_ID_PV1_19_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PV1.7 -%} + {% if firstSegments.PV1.7.9.1 != "" and firstSegments.PV1.7.9.1 != null and firstSegments.PV1.7.9.2 != "" and firstSegments.PV1.7.9.2 != null and firstSegments.PV1.7.9.3 != "" and firstSegments.PV1.7.9.3 != null -%} + {% evaluate Organization_ID_PV1_7_9 using 'ID/Organization' HDORG: firstSegments.PV1.7.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.7.9, ID: Organization_ID_PV1_7_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_7 using 'ID/Practitioner' XCN: firstSegments.PV1.7 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.7, ID: practitionerId_PV1_7 -%} + {% endif -%} + + {% if firstSegments.PV1.8 -%} + {% if firstSegments.PV1.8.9.1 != "" and firstSegments.PV1.8.9.1 != null and firstSegments.PV1.8.9.2 != "" and firstSegments.PV1.8.9.2 != null and firstSegments.PV1.8.9.3 != "" and firstSegments.PV1.8.9.3 != null -%} + {% evaluate Organization_ID_PV1_8_9 using 'ID/Organization' HDORG: firstSegments.PV1.8.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.8.9, ID: Organization_ID_PV1_8_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_8 using 'ID/Practitioner' XCN: firstSegments.PV1.8 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.8, ID: practitionerId_PV1_8 -%} + {% endif -%} + + {% if firstSegments.PV1.9 -%} + {% if firstSegments.PV1.9.9.1 != "" and firstSegments.PV1.9.9.1 != null and firstSegments.PV1.9.9.2 != "" and firstSegments.PV1.9.9.2 != null and firstSegments.PV1.9.9.3 != "" and firstSegments.PV1.9.9.3 != null -%} + {% evaluate Organization_ID_PV1_9_9 using 'ID/Organization' HDORG: firstSegments.PV1.9.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.9.9, ID: Organization_ID_PV1_9_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_9 using 'ID/Practitioner' XCN: firstSegments.PV1.9 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.9, ID: practitionerId_PV1_9 -%} + {% endif -%} + + {% if firstSegments.PV1.17 -%} + {% if firstSegments.PV1.17.9.1 != "" and firstSegments.PV1.17.9.1 != null and firstSegments.PV1.17.9.2 != "" and firstSegments.PV1.17.9.2 != null and firstSegments.PV1.17.9.3 != "" and firstSegments.PV1.17.9.3 != null -%} + {% evaluate Organization_ID_PV1_17_9 using 'ID/Organization' HDORG: firstSegments.PV1.17.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.17.9, ID: Organization_ID_PV1_17_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_17 using 'ID/Practitioner' XCN: firstSegments.PV1.17 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.17, ID: practitionerId_PV1_17 -%} + {% endif -%} + + {% if firstSegments.PV1.50 -%} + {% for p in firstSegments.PV1.50.Repeats -%} + {% if p.4.1 != "" and p.4.1 != null and p.4.2 != "" and p.4.2 != null and p.4.3 != "" and p.4.3 != null -%} + {% evaluate Organization_ID_PV1_50_4 using 'ID/Organization' HDORG: p.4 -%} + {% include 'Resource/Organization', PV1: p.4, ID: Organization_ID_PV1_50_4 -%} + {% endif -%} + {% endfor -%} + {% endif -%} + + {% if firstSegments.PV1.52 -%} + {% if firstSegments.PV1.52.9.1 != "" and firstSegments.PV1.52.9.1 != null and firstSegments.PV1.52.9.2 != "" and firstSegments.PV1.52.9.2 != null and firstSegments.PV1.52.9.3 != "" and firstSegments.PV1.52.9.3 != null -%} + {% evaluate Organization_ID_PV1_52_9 using 'ID/Organization' HDORG: firstSegments.PV1.52.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.52.9, ID: Organization_ID_PV1_52_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_52 using 'ID/Practitioner' XCN: firstSegments.PV1.52 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.52, ID: practitionerId_PV1_52 -%} + {% endif -%} + + {% if firstSegments.PV1.3 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.3-%} + {% endif -%} + + {% if firstSegments.PV1.6 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.6 -%} + {% endif -%} + + {% if firstSegments.PV1.37 -%} + {% evaluate location_ID_PV1_37 using 'ID/Location' DLD: firstSegments.PV1.37 -%} + {% include 'Resource/Location' PV1: firstSegments.PV1.37, ID: location_ID_PV1_37-%} + {% endif -%} + + {% if firstSegments.PV1.42 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.42-%} + {% endif -%} + + {% if firstSegments.PV1.43 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.43-%} + {% endif -%} + + {% if firstSegments.PV1.54 -%} + {% if firstSegments.PV1.54.4.1 != "" and firstSegments.PV1.54.4.1 != null and firstSegments.PV1.54.4.2 != "" and firstSegments.PV1.54.4.2 != null and firstSegments.PV1.54.4.3 != "" and firstSegments.PV1.54.4.3 != null -%} + {% evaluate Organization_ID_PV1_54_4 using 'ID/Organization' HDORG: firstSegments.PV1.54.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.54.4, ID: Organization_ID_PV1_54_4 -%} + {% endif -%} + {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: firstSegments.PV1.54 -%} + {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId -%} + {% endif -%} + + {% evaluate encounterId using 'ID/Encounter' PV1: firstSegments.PV1, baseId: patientId -%} + {% include 'Resource/Encounter' Root_Template: 'MDM_T02', PV1: firstSegments.PV1, ID: encounterId -%} + {% include 'Reference/Encounter/Subject' ID: encounterId, REF: fullPatientId -%} + {% include 'Extensions/Encounter/EncounterExtension' ID: encounterId, PV1: firstSegments.PV1 -%} + {% endif -%} + + {% if firstSegments.TXA -%} + + {% evaluate documentreferenceID using 'ID/DocumentReference' EI: firstSegments.TXA.12 -%} + {% include 'Resource/DocumentReference' TXA: firstSegments.TXA, ID: documentreferenceID -%} + + {% if firstSegments.TXA.5 -%} + {% for txa_5 in firstSegments.TXA.5.Repeats -%} + {% if txa_5.9.1 != "" and txa_5.9.1 != null and txa_5.9.2 != "" and txa_5.9.2 != null and txa_5.9.3 != "" and txa_5.9.3 != null -%} + {% evaluate Organization_ID_TXA_5_9 using 'ID/Organization' HDORG: txa_5.9.9 -%} + {% include 'Resource/Organization', TXA: txa_5.5.9, ID: Organization_ID_TXA_5_9 -%} + {% endif -%} + {% evaluate practitionerId_TXA_5 using 'ID/Practitioner' XCN: txa_5 -%} + {% include 'Resource/Practitioner' TXA: txa_5, ID: practitionerId_TXA_5 -%} + {% endfor -%} + {% endif -%} + {% if firstSegments.TXA.9 -%} + {% for txa_9 in firstSegments.TXA.9.Repeats -%} + {% if txa_9.Value != null and txa_9.Value != "" -%} + {% if txa_9.9.1 != "" and txa_9.9.1 != null and txa_9.9.2 != "" and txa_9.9.2 != null and txa_9.9.3 != "" and txa_9.9.3 != null -%} + {% evaluate Organization_ID_TXA_9_9 using 'ID/Organization' HDORG: txa_9.9.9 -%} + {% include 'Resource/Organization', TXA: txa_9.9.9, ID: Organization_ID_TXA_9_9 -%} + {% endif -%} + {% evaluate practitionerId_TXA_9 using 'ID/Practitioner' XCN: txa_9 -%} + {% include 'Resource/Practitioner' TXA: txa_9, ID: practitionerId_TXA_9 -%} + + {% evaluate practitionerRoleId_TXA9 using 'ID/PractitionerRole' XCN: txa_9 -%} + {% include 'Resource/PractitionerRole' practitionerId_TXA: practitionerId_TXA_9, ID: practitionerRoleId_TXA9 -%} + {% endif -%} + {% endfor -%} + {% endif -%} + + {% if firstSegments.TXA.10.Repeats[0] -%} + {% assign txa_10 = firstSegments.TXA.10.Repeats[0] -%} + {% if txa_10.9.1 != "" and txa_10.9.1 != null and txa_10.9.2 != "" and txa_10.9.2 != null and txa_10.9.3 != "" and txa_10.9.3 != null -%} + {% evaluate Organization_ID_TXA_10_9 using 'ID/Organization' HDORG: txa_10.9.9 -%} + {% include 'Resource/Organization', TXA: txa_10.9.9, ID: Organization_ID_TXA_10_9 -%} + {% endif -%} + {% evaluate practitionerId_TXA_10 using 'ID/Practitioner' XCN: txa_10 -%} + {% include 'Resource/Practitioner' TXA: txa_10, ID: practitionerId_TXA_10 -%} + + {% evaluate practitionerRoleId_TXA10 using 'ID/PractitionerRole' XCN: txa_10 -%} + {% include 'Resource/PractitionerRole' practitionerId_TXA: practitionerId_TXA_10, ID: practitionerRoleId_TXA10 -%} + + {% endif -%} + {% endif -%} + + {% assign obrSegmentPositionIndex_orc = 0 -%} + {% for orcSegment in orcSegmentLists.ORC -%} + + {% assign obrSegmentLists = hl7v2Data | get_related_segment_list: orcSegment, 'OBR' -%} + {% assign tq1SegmentLists = hl7v2Data | get_related_segment_list: orcSegment, 'TQ1' -%} + + {% for obrSegment in obrSegmentLists.OBR -%} + {% assign checkParent = hl7v2Data | get_parent_segment: 'OBR', {{obrSegmentPositionIndex_orc}}, 'ORC' -%} + {% assign obrSegmentPositionIndex_orc = obrSegmentPositionIndex_orc | plus: 1 -%} + + {% evaluate parentServiceRequestId_orc using 'ID/ServiceRequest' ORC: checkParent.ORC.31, baseId: patientId -%} + {% if obrSegment.29.Value == null %} + {% if checkParent.ORC.8 and checkParent.ORC.31 %} + {% include 'Resource/ServiceRequest' OBR: obrSegment, ORC: checkParent.ORC, ID: parentServiceRequestId_orc, ServiceRequest_Subject_ID: fullPatientId, type_msg: "MDM_T02" -%} + {% endif %} + {% endif %} + + {% evaluate serviceRequestId using 'ID/ServiceRequest' OBR: obrSegment, baseId: patientId -%} + + {% evaluate specimenId_obr using 'ID/Specimen' OBR: obrSegment -%} + {% assign fullSpecimenId_obr = specimenId_obr | prepend: 'Specimen/' -%} + {% evaluate parentServiceRequestId using 'ID/ServiceRequest' OBR_29: obrSegment.29, baseId: patientId -%} + + {% include 'Resource/ServiceRequest' OBR_child: obrSegment, parentSegment: checkParent.ORC, ServiceRequest_Subject_ID: fullPatientId, ServiceRequest_ID_OBR_29: parentServiceRequestId, ServiceRequest_ID_ORC_8: parentServiceRequestId_orc, ID: serviceRequestId, type_msg: "MDM_T02" -%} + + {% assign fullDocumentreferenceID = documentreferenceID | prepend: 'DocumentReference/' -%} + {% include 'Reference/ServiceRequest/ReasonReference' ID: serviceRequestId, REF: fullDocumentreferenceID -%} + + {% evaluate practitionerId_ORC_12 using 'ID/Practitioner' XCN: checkParent.ORC.12.Repeats[0] -%} + {% if obrSegment.16 -%} + {% if obrSegment.16.Repeats[0] %} + {% if obrSegment.16.Repeats[0].9.1 != "" and obrSegment.16.Repeats[0].9.1 != null and obrSegment.16.Repeats[0].9.2 != "" and obrSegment.16.Repeats[0].9.2 != null and obrSegment.16.Repeats[0].9.3 != "" and obrSegment.16.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_OBR16 using 'ID/Organization' HDORG: obrSegment.16.Repeats[0].9 -%} + {% include 'Resource/Organization' OBR_SEG_16: obrSegment.16.Repeats[0].9, ID: Organization_ID_OBR16 -%} + {% endif -%} + {% endif -%} + {% evaluate practitionerId_OBR_16 using 'ID/Practitioner' XCN: obrSegment.16.Repeats[0] -%} + {% include 'Resource/Practitioner' OBR_SEG: obrSegment, OBRXCN_16: obrSegment.16.Repeats[0], ORC_SEG_24: checkParent.ORC.24, ID: practitionerId_OBR_16 -%} + {% evaluate practitionerRoleId_OBR_16 using 'ID/PractitionerRole' XCN: obrSegment.16.Repeats[0]-%} + {% include 'Resource/PractitionerRole' OBR: obrSegment, requestor_practitioner1: practitionerId_OBR_16, ID: practitionerRoleId_OBR_16 -%} + {% assign fullpractitionerRoleId_OBR_16 = practitionerRoleId_OBR_16 | prepend: 'PractitionerRole/' -%} + {% include 'Reference/ServiceRequest/Requester' REF: fullpractitionerRoleId_OBR_16, ID: serviceRequestId -%} + {% else %} + {% if checkParent.ORC.12 %} + {% if checkParent.ORC.12.Repeats[0].9.1 != "" and checkParent.ORC.12.Repeats[0].9.1 != null and checkParent.ORC.12.Repeats[0].9.2 != "" and checkParent.ORC.12.Repeats[0].9.2 != null and checkParent.ORC.12.Repeats[0].9.3 != "" and checkParent.ORC.12.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_ORC_12 using 'ID/Organization' HDORG: checkParent.ORC.12.Repeats[0].9 -%} + {% include 'Resource/Organization' ORC_SEG_12: checkParent.ORC.12.Repeats[0].9, ID: Organization_ID_ORC_12 -%} + {% endif -%} + {% include 'Resource/Practitioner' ORC_SEG: checkParent.ORC, ORCXCN_12: checkParent.ORC.12.Repeats[0], ORC_SEG_24: checkParent.ORC.24, ID: practitionerId_ORC_12 -%} + {% evaluate practitionerRoleId_ORC_12 using 'ID/PractitionerRole' XCN: checkParent.ORC.12.Repeats[0]-%} + {% include 'Resource/PractitionerRole' ORC: checkParent.ORC, requestor_practitioner2: practitionerId_ORC_12, ID: practitionerRoleId_ORC_12 -%} + {% assign fullPractitionerRoleId_ORC_12 = practitionerRoleId_ORC_12 | prepend: 'PractitionerRole/' -%} + {% include 'Reference/ServiceRequest/Requester' REF: fullPractitionerRoleId_ORC_12, ID: serviceRequestId -%} + {% else %} + {% if checkParent.ORC.21 %} + {% evaluate organizationId_ORC_21 using 'ID/Organization' XON: checkParent.ORC.21.Repeats[0] -%} + {% if checkParent.ORC.12.Repeats[0] == null or checkParent.ORC.12.Repeats[0] == "" and obrSegment.16 == null or obrSegment.16 == "" %} + {% include 'Resource/Organization' ORC_SEG: checkParent.ORC, ORC_SEG_22: checkParent.ORC.22, ORC_SEG_23: checkParent.ORC.23, ID: organizationId_ORC_21 -%} + {% endif %} + {% evaluate practitionerRoleId_ORC_21 using 'ID/PractitionerRole' XCN: checkParent.ORC.21.Repeats[0]-%} + {% include 'Resource/PractitionerRole' ORC: checkParent.ORC, requestor_organization: organizationId_ORC_21, ID: practitionerRoleId_ORC_21 -%} + {% assign fullPractitionerRoleId_ORC_21 = practitionerRoleId_ORC_21 | prepend: 'PractitionerRole/' -%} + {% include 'Reference/ServiceRequest/Requester' REF: fullPractitionerRoleId_ORC_21, ID: serviceRequestId -%} + {% endif %} + {% endif -%} + {% endif %} + + {% include 'Reference/ServiceRequest/Specimen' REF: fullSpecimenId_obr, ID: serviceRequestId -%} + + {% if obrSegment.29 %} + {% if obrSegment.50 -%} + {% evaluate parentServiceRequestId using 'ID/ServiceRequest' OBR_29: obrSegment.29, baseId: patientId -%} + {% include 'Resource/ServiceRequest' OBR_parent: obrSegment, parentSegment: checkParent.ORC, ServiceRequest_Subject_ID: fullPatientId, ID: parentServiceRequestId, type_msg: "MDM_T02" -%} + {% endif %} + {% endif %} + + {% assign fullParentServiceRequestId = parentServiceRequestId | prepend: 'ServiceRequest/' -%} + + {% assign nteSegmentLists1 = hl7v2Data | get_related_segment_list: obrSegment, 'NTE' -%} + {% for nteSegment1 in nteSegmentLists1.NTE -%} + {% if nteSegment1.5 -%} + {% if nteSegment1.5.9.1 != "" and nteSegment1.5.9.1 != null and nteSegment1.5.9.2 != "" and nteSegment1.5.9.2 != null and nteSegment1.5.9.3 != "" and nteSegment1.5.9.3 != null -%} + {% evaluate Organization_ID_NTE1_5_9 using 'ID/Organization' HDORG: nteSegment1.5.9 -%} + {% include 'Resource/Organization' OBR_NTE: nteSegment1.5.9, ID: Organization_ID_NTE1_5_9 -%} + {% endif -%} + {% evaluate practitioner_ID_NTE_5 using 'ID/Practitioner' XCN: nteSegment1.5 -%} + {% include 'Resource/Practitioner' NTE: nteSegment1.5, ID: practitioner_ID_NTE_5 -%} + {% endif -%} + {% include 'Resource/ServiceRequest' NTE: nteSegment1, ID: serviceRequestId -%} + {% endfor -%} + + {% assign fullServiceRequestId = serviceRequestId | prepend: 'ServiceRequest/' -%} + {% include 'Resource/Specimen' OBR: obrSegment, ID: specimenId_obr -%} + + {% if obrSegment.10 %} + {% if obrSegment.10.Repeats[0].9.1 != "" and obrSegment.10.Repeats[0].9.1 != null and obrSegment.10.Repeats[0].9.2 != "" and obrSegment.10.Repeats[0].9.2 != null and obrSegment.10.Repeats[0].9.3 != "" and obrSegment.10.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_OBR10 using 'ID/Organization' HDORG: obrSegment.10.Repeats[0].9 -%} + {% include 'Resource/Organization' OBR_SEG_10: obrSegment.10.Repeats[0].9, ID: Organization_ID_OBR10 -%} + {% endif -%} + {% evaluate practitionerId_OBR_10 using 'ID/Practitioner' XCN: obrSegment.10.Repeats[0] -%} + {% include 'Resource/Practitioner' OBR_SEG: obrSegment, OBRXCN_10: obrSegment.10.Repeats[0], ID: practitionerId_OBR_10 -%} + {% evaluate practitionerRoleId_OBR_10 using 'ID/PractitionerRole' XCN: obrSegment.10.Repeats[0] -%} + {% assign full_practitionerId_obr_10 = practitionerRoleId_OBR_10 | prepend: 'PractitionerRole/' %} + {% include 'Resource/PractitionerRole' OBR: obrSegment, collection_collector_practitioner: practitionerId_obr_10, ID: practitionerRoleId_OBR_10 -%} + {% include 'Reference/Specimen/Collection_Collector' REF: full_practitionerId_obr_10, ID: specimenId_obr -%} + {% endif -%} + {% endfor -%} + + {% unless tq1SegmentLists.TQ1 -%} + {% include 'Resource/ServiceRequest' ID: serviceRequestId, OBR_tq1: obrSegmentLists.OBR[0], ORC_tq1: orcSegment -%} + {% endunless -%} + + {% for tq1Segment in tq1SegmentLists.TQ1 -%} + {% include 'Resource/ServiceRequest' TQ1: tq1Segment, ID: serviceRequestId, OBR_timeday: obrSegmentLists.OBR[0] -%} + {% endfor -%} + + {% endfor -%} + + {% for obxSegment in obxSegmentLists.OBX -%} + {% if obxSegment.2.Value == 'ED' or obxSegment.2.Value == 'RP' %} + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16 -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16 -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23 -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + + {% evaluate obx_diagnosticReportID using 'ID/DiagnosticReport' OBX: obxSegment -%} + {% include 'Resource/DiagnosticReport' OBX: obxSegment, ID: obx_diagnosticReportID, DiagnosticReport_Subject_ID: fullPatientId -%} + {% else %} + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16 -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16 -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + {% if obxSegment.18 -%} + {% evaluate deviceId_OBX_18 using 'ID/Device' EI: obxSegment.18.Repeats[0] -%} + {% include 'Resource/Device' EI_OBX18: obxSegment.18, ID: deviceId_OBX_18 -%} + {% endif -%} + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23 -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + {% evaluate observationId using 'ID/Observation' OBX: obxSegment, baseId: patientId -%} + {% include 'Resource/Observation' OBX: obxSegment, Observation_Subject_ID: fullPatientId, ID: observationId -%} + + {% include 'Extensions/Observation/ObservationExtension' OBX: obxSegment, ID: observationId %} + {% assign nteSegmentLists2 = hl7v2Data | get_related_segment_list: obxSegment, 'NTE' -%} + {% for nteSegment2 in nteSegmentLists2.NTE -%} + {% if nteSegment2.5 -%} + {% if nteSegment2.5.9.1 != "" and nteSegment2.5.9.1 != null and nteSegment2.5.9.2 != "" and nteSegment2.5.9.2 != null and nteSegment2.5.9.3 != "" and nteSegment2.5.9.3 != null -%} + {% evaluate Organization_ID_NTE2_5_9 using 'ID/Organization' HDORG: nteSegment2.5.9 -%} + {% include 'Resource/Organization' OBX_NTE: nteSegment2.5.9, ID: Organization_ID_NTE2_5_9 -%} + {% endif -%} + {% evaluate practitioner_ID_NTE_5 using 'ID/Practitioner' XCN: nteSegment2.5 -%} + {% include 'Resource/Practitioner' NTE: nteSegment2.5, ID: practitioner_ID_NTE_5 -%} + {% endif -%} + {% include 'Resource/Observation' NTE: nteSegment2, ID: observationId -%} + {% endfor -%} + {% endif -%} + {% endfor -%} + ] +} \ No newline at end of file diff --git a/data/Templates/Hl7v2/OML_O21.liquid b/data/Templates/Hl7v2/OML_O21.liquid index 54beccb0b..5ac71fff9 100644 --- a/data/Templates/Hl7v2/OML_O21.liquid +++ b/data/Templates/Hl7v2/OML_O21.liquid @@ -1,8 +1,13 @@ -{% assign firstSegments = hl7v2Data | get_first_segments: 'PID|PD1|PV1|PV2|ORC|MSH' -%} -{% assign al1SegmentLists = hl7v2Data | get_segment_lists: 'AL1' -%} +{% assign firstSegments = hl7v2Data | get_first_segments: 'MSH|UAC|PID|PD1|PV1|PV2|ORC' -%} +{% assign sftSegmentLists = hl7v2Data | get_segment_lists: 'SFT' -%} +{% assign nteSegmentLists = hl7v2Data | get_segment_lists: 'NTE' -%} {% assign nk1SegmentLists = hl7v2Data | get_segment_lists: 'NK1' -%} +{% assign in1SegmentLists = hl7v2Data | get_segment_lists: 'IN1' -%} +{% assign gt1SegmentLists = hl7v2Data | get_segment_lists: 'GT1' -%} +{% assign al1SegmentLists = hl7v2Data | get_segment_lists: 'AL1' -%} {% assign orcSegmentLists = hl7v2Data | get_segment_lists: 'ORC' -%} -{% assign spmSegmentLists = hl7v2Data | get_segment_lists: 'SPM' -%} + +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} { "resourceType": "Bundle", @@ -14,107 +19,157 @@ { "value":"{{ firstSegments.MSH.10.Value }}", }, + "id":"{{ bundleID }}", "entry": [ - {% evaluate messageHeaderId using 'ID/MessageHeader' MSH: firstSegments.MSH -%} - {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, ID: messageHeaderID -%} - + {% evaluate patientId using 'ID/Patient' PID: firstSegments.PID, type: 'First' -%} {% assign fullPatientId = patientId | prepend: 'Patient/' -%} - {% include 'Resource/Patient' PID: firstSegments.PID, PD1: firstSegments.PD1, ID: patientId -%} - {% include 'Extensions/Patient/PatientExtension' ID: PatientId, PID: firstSegments.PID, PV1: firstSegments.PV1 -%} - - {% evaluate practitionerId10_ORC_10 using 'ID/Practitioner' XCN: firstSegments.ORC.10 -%} - {% evaluate practitionerId10_ORC_11 using 'ID/Practitioner' XCN: firstSegments.ORC.11 -%} - {% evaluate practitionerId10_ORC_12 using 'ID/Practitioner' XCN: firstSegments.ORC.12 -%} - - {% include 'Resource/Practitioner' ORC: firstSegments.ORC, ID: practitionerId10_ORC_10 -%} - {% include 'Resource/Practitioner' ORC: firstSegments.ORC, ID: practitionerId10_ORC_11 -%} - {% include 'Resource/Practitioner' ORC: firstSegments.ORC, ID: practitionerId10_ORC_12 -%} + {% evaluate messageHeaderId using 'ID/MessageHeader' MSH: firstSegments.MSH -%} - {% if firstSegments.PV1.5 -%} - {% if firstSegments.PV1.5.4.1 != "" and firstSegments.PV1.5.4.1 != null and firstSegments.PV1.5.4.2 != "" and firstSegments.PV1.5.4.2 != null and firstSegments.PV1.5.4.3 != "" and firstSegments.PV1.5.4.3 != null -%} - {% evaluate Organization_ID_PV1_5_4 using 'ID/Organization' HDORG: firstSegments.PV1.5.4 -%} - {% include 'Resource/Organization', PV1: firstSegments.PV1.5.4, ID: Organization_ID_PV1_5_4 -%} + {% if firstSegments.MSH -%} + + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, ID: messageHeaderId -%} + {% evaluate provenanceId using 'ID/Provenance' MSH: firstSegments.MSH, baseId: patientId -%} + {% include 'Resource/Provenance' Root_Template: 'OML_O21', MSH: firstSegments.MSH, REF_BUNDLE: bundleID, ID: provenanceId -%} + + {%- comment -%} + {% assign transformation_val = 'provenance_transformation' %} + {% evaluate provenanceOrganizationId using 'ID/Organization', prov_id: firstSegments.MSH -%} + {% evaluate provenanceTransformationId using 'ID/Provenance_transformation' prov_id: transformation_val -%} + {% include 'Resource/Organization' org_name: 'Microsoft Corporation', ID: provenanceOrganizationId -%} + {% include 'Resource/Provenance_transformation' Root_Template: 'ADT_A01', Provenance_Organization_ID: provenanceOrganizationId, REF_MSH: messageHeaderId, provenanceOrganizationId, ID: provenanceTransformationId -%} + {%- endcomment -%} + + {% if firstSegments.MSH.4 -%} + {% if firstSegments.MSH.4.1 != "" and firstSegments.MSH.4.1 != null or firstSegments.MSH.4.2 != "" and firstSegments.MSH.4.2 != null or firstSegments.MSH.4.3 != "" and firstSegments.MSH.4.3 != null -%} + {% evaluate organization_ID_MSH_4 using 'ID/Organization' HD: firstSegments.MSH.4 -%} + {% include 'Resource/Organization' MSHHD1: firstSegments.MSH.4, MSH: firstSegments.MSH, ID: organization_ID_MSH_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.6 %} + {% if firstSegments.MSH.6.1 != "" and firstSegments.MSH.6.1 != null or firstSegments.MSH.6.2 != "" and firstSegments.MSH.6.2 != null or firstSegments.MSH.6.3 != "" and firstSegments.MSH.6.3 != null -%} + {% evaluate organization_Id_MSH_6 using 'ID/Organization' HD: firstSegments.MSH.6 -%} + {% include 'Resource/Organization' MSHHD2: firstSegments.MSH.6, MSH: firstSegments.MSH, ID: organization_Id_MSH_6 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.22 %} + {% if firstSegments.MSH.22.1 != "" and firstSegments.MSH.22.1 != null -%} + {% evaluate organization_Id_MSH_22 using 'ID/Organization' XON: firstSegments.MSH.22 -%} + {% include 'Resource/Organization' MSHXON1: firstSegments.MSH.22, ID: organization_Id_MSH_22 -%} + {% endif -%} {% endif -%} - {% endif -%} - {% if firstSegments.PV1.19 -%} - {% if firstSegments.PV1.19.4.1 != "" and firstSegments.PV1.19.4.1 != null and firstSegments.PV1.19.4.2 != "" and firstSegments.PV1.19.4.2 != null and firstSegments.PV1.19.4.3 != "" and firstSegments.PV1.19.4.3 != null -%} - {% evaluate Organization_ID_PV1_19_4 using 'ID/Organization' HDORG: firstSegments.PV1.19.4 -%} - {% include 'Resource/Organization', PV1: firstSegments.PV1.19.4, ID: Organization_ID_PV1_19_4 -%} + {% if firstSegments.MSH.23 %} + {% if firstSegments.MSH.23.1 != "" and firstSegments.MSH.23.1 != null -%} + {% evaluate organization_Id_MSH_23 using 'ID/Organization' XON: firstSegments.MSH.23 -%} + {% include 'Resource/Organization' MSHXON2: firstSegments.MSH.23, ID: organization_Id_MSH_23 -%} + {% endif -%} {% endif -%} - {% endif -%} - - {% if firstSegments.PV1.7 -%} - {% if firstSegments.PV1.7.9.1 != "" and firstSegments.PV1.7.9.1 != null and firstSegments.PV1.7.9.2 != "" and firstSegments.PV1.7.9.2 != null and firstSegments.PV1.7.9.3 != "" and firstSegments.PV1.7.9.3 != null -%} - {% evaluate Organization_ID_PV1_7_9 using 'ID/Organization' HDORG: firstSegments.PV1.7.9 -%} - {% include 'Resource/Organization', PV1: firstSegments.PV1.7.9, ID: Organization_ID_PV1_7_9 -%} + {% if firstSegments.MSH.3 and firstSegments.MSH.24 %} + {% evaluate device_Id_MSH_3 using 'ID/Device' HD: firstSegments.MSH.3 -%} + {% include 'Resource/Device' MSH: firstSegments.MSH, ID: device_Id_MSH_3 -%} {% endif -%} - {% evaluate practitionerId_PV1_7 using 'ID/Practitioner' XCN: firstSegments.PV1.7 -%} - {% include 'Resource/Practitioner' PV1: firstSegments.PV1.7, ID: practitionerId_PV1_7 -%} - {% endif -%} - {% if firstSegments.PV1.8 -%} - {% if firstSegments.PV1.8.9.1 != "" and firstSegments.PV1.8.9.1 != null and firstSegments.PV1.8.9.2 != "" and firstSegments.PV1.8.9.2 != null and firstSegments.PV1.8.9.3 != "" and firstSegments.PV1.8.9.3 != null -%} - {% evaluate Organization_ID_PV1_8_9 using 'ID/Organization' HDORG: firstSegments.PV1.8.9 -%} - {% include 'Resource/Organization', PV1: firstSegments.PV1.8.9, ID: Organization_ID_PV1_8_9 -%} - {% endif -%} - {% evaluate practitionerId_PV1_8 using 'ID/Practitioner' XCN: firstSegments.PV1.8 -%} - {% include 'Resource/Practitioner' PV1: firstSegments.PV1.8, ID: practitionerId_PV1_8 -%} {% endif -%} - {% if firstSegments.PV1.9 -%} - {% if firstSegments.PV1.9.9.1 != "" and firstSegments.PV1.9.9.1 != null and firstSegments.PV1.9.9.2 != "" and firstSegments.PV1.9.9.2 != null and firstSegments.PV1.9.9.3 != "" and firstSegments.PV1.9.9.3 != null -%} - {% evaluate Organization_ID_PV1_9_9 using 'ID/Organization' HDORG: firstSegments.PV1.9.9 -%} - {% include 'Resource/Organization', PV1: firstSegments.PV1.9.9, ID: Organization_ID_PV1_9_9 -%} - {% endif -%} - {% evaluate practitionerId_PV1_9 using 'ID/Practitioner' XCN: firstSegments.PV1.9 -%} - {% include 'Resource/Practitioner' PV1: firstSegments.PV1.9, ID: practitionerId_PV1_9 -%} - {% endif -%} + {% for sftSegment in sftSegmentLists.SFT -%} + {% evaluate deviceId_SFT using 'ID/Device' SFT: sftSegment -%} + {% include 'Resource/Device' SFT:sftSegment, ID: deviceId_SFT -%} + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, SFT:sftSegment, ID: messageHeaderID -%} + {% endfor -%} - {% if firstSegments.PV1.17 -%} - {% if firstSegments.PV1.17.9.1 != "" and firstSegments.PV1.17.9.1 != null and firstSegments.PV1.17.9.2 != "" and firstSegments.PV1.17.9.2 != null and firstSegments.PV1.17.9.3 != "" and firstSegments.PV1.17.9.3 != null -%} - {% evaluate Organization_ID_PV1_17_9 using 'ID/Organization' HDORG: firstSegments.PV1.17.9 -%} - {% include 'Resource/Organization', PV1: firstSegments.PV1.17.9, ID: Organization_ID_PV1_17_9 -%} - {% endif -%} - {% evaluate practitionerId_PV1_17 using 'ID/Practitioner' XCN: firstSegments.PV1.17 -%} - {% include 'Resource/Practitioner' PV1: firstSegments.PV1.17, ID: practitionerId_PV1_17 -%} - {% endif -%} + {% include 'Resource/Patient' PID: firstSegments.PID, PD1: firstSegments.PD1, ID: patientId -%} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, PID: firstSegments.PID, PD1: firstSegments.PD1, PV1: firstSegments.PV1 -%} + + {% if firstSegments.PID.18 -%} + {% evaluate accountId using 'ID/Account' CX: firstSegments.PID.3 -%} + {% include 'Resource/Account' PID: firstSegments.PID, ID: accountId -%} + {% include 'Reference/Account/Subject' ID: accountId, REF: fullPatientId -%} + {% if firstSegments.PID.18.4.1 != "" and firstSegments.PID.18.4.1 != null and firstSegments.PID.18.4.2 != "" and firstSegments.PID.18.4.2 != null and firstSegments.PID.18.4.3 != "" and firstSegments.PID.18.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_18 using 'ID/Organization' HDORG: firstSegments.PID.18.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.18, ID: Organization_ID_pid_CX_18 -%} + {% endif -%} - {% if firstSegments.PV1.50 -%} - {% for p in firstSegments.PV1.50.Repeats -%} - {% if p.4.1 != "" and p.4.1 != null and p.4.2 != "" and p.4.2 != null and p.4.3 != "" and p.4.3 != null -%} - {% evaluate Organization_ID_PV1_50_4 using 'ID/Organization' HDORG: p.4 -%} - {% include 'Resource/Organization', PV1: p.4, ID: Organization_ID_PV1_50_4 -%} + {% for gt1SegmentLists in gt1SegmentLists.GT1 -%} + {% if gt1SegmentLists.11.1.Value == "SEL" -%} + {% include 'Resource/Patient' PID: firstSegments.PID, GT1: gt1SegmentLists, ID: patientId, NK1_PER: nk1SegmentLists.NK1[0] -%} + {% if gt1SegmentLists.2.4.1 != "" and gt1SegmentLists.2.4.1 != null and gt1SegmentLists.2.4.2 != "" and gt1SegmentLists.2.4.2 != null and gt1SegmentLists.2.4.3 != "" and gt1SegmentLists.2.4.3 != null -%} + {% evaluate Organization_ID_gt1_CX_2 using 'ID/Organization' HDORG: gt1SegmentLists.2.4 -%} + {% include 'Resource/Organization', PID: gt1SegmentLists.2, ID: Organization_ID_gt1_CX_2 -%} + {% endif -%} + {% if gt1SegmentLists.19.4.1 != "" and gt1SegmentLists.19.4.1 != null and gt1SegmentLists.19.4.2 != "" and gt1SegmentLists.19.4.2 != null and gt1SegmentLists.19.4.3 != "" and gt1SegmentLists.19.4.3 != null -%} + {% evaluate Organization_ID_gt1_CX_19 using 'ID/Organization' HDORG: gt1SegmentLists.19.4 -%} + {% include 'Resource/Organization', PID: gt1SegmentLists.19, ID: Organization_ID_gt1_CX_19 -%} + {% endif -%} + {% if gt1SegmentLists.29.4.1 != "" and gt1SegmentLists.29.4.1 != null and gt1SegmentLists.29.4.2 != "" and gt1SegmentLists.29.4.2 != null and gt1SegmentLists.29.4.3 != "" and gt1SegmentLists.29.4.3 != null -%} + {% evaluate Organization_ID_gt1_CX_29 using 'ID/Organization' HDORG: gt1SegmentLists.29.4 -%} + {% include 'Resource/Organization', PID: gt1SegmentLists.29, ID: Organization_ID_gt1_CX_29 -%} + {% endif -%} + {% if gt1SegmentLists.51 and nk1SegmentLists.NK1[0].7.1.Value == "E" -%} + {% evaluate Organization_ID_gt1_XON_51 using 'ID/Organization' XON: gt1SegmentLists.51 -%} + {% include 'Resource/Organization', GT1_51: gt1SegmentLists, ID: Organization_ID_gt1_XON_51 -%} + {% assign Organization_GT1_51 = Organization_ID_gt1_XON_51 | prepend: 'Organization/' -%} + {% include 'Reference/Patient/Contact_Organization' REF:Organization_GT1_51 , ID: patientId -%} + {% endif -%} + {% else -%} + {% evaluate gt1relatedPersonId using 'ID/RelatedPerson' GT1: gt1SegmentLists, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: gt1relatedPersonId, GT1: gt1SegmentLists -%} + {% if gt1SegmentLists.2.4.1 != "" and gt1SegmentLists.2.4.1 != null and gt1SegmentLists.2.4.2 != "" and gt1SegmentLists.2.4.2 != null and gt1SegmentLists.2.4.3 != "" and gt1SegmentLists.2.4.3 != null -%} + {% evaluate Organization_ID_gt1_CX_2 using 'ID/Organization' HDORG: gt1SegmentLists.2.4 -%} + {% include 'Resource/Organization', PID: gt1SegmentLists.2, ID: Organization_ID_gt1_CX_2 -%} + {% endif -%} + {% if gt1SegmentLists.19.4.1 != "" and gt1SegmentLists.19.4.1 != null and gt1SegmentLists.19.4.2 != "" and gt1SegmentLists.19.4.2 != null and gt1SegmentLists.19.4.3 != "" and gt1SegmentLists.19.4.3 != null -%} + {% evaluate Organization_ID_gt1_CX_19 using 'ID/Organization' HDORG: gt1SegmentLists.19.4 -%} + {% include 'Resource/Organization', PID: gt1SegmentLists.19, ID: Organization_ID_gt1_CX_19 -%} + {% endif -%} + {% endif -%} + {% if gt1SegmentLists.21 -%} + {% evaluate Organization_ID_gt1_XON_21 using 'ID/Organization' XON: gt1SegmentLists.21 -%} + {% include 'Resource/Organization', GT1: gt1SegmentLists, ID: Organization_ID_gt1_XON_21 -%} + {% if gt1SegmentLists.2.4.1 != "" and gt1SegmentLists.2.4.1 != null and gt1SegmentLists.2.4.2 != "" and gt1SegmentLists.2.4.2 != null and gt1SegmentLists.2.4.3 != "" and gt1SegmentLists.2.4.3 != null -%} + {% evaluate Organization_ID_gt1_CX_2 using 'ID/Organization' HDORG: gt1SegmentLists.2.4 -%} + {% include 'Resource/Organization', PID: gt1SegmentLists.2, ID: Organization_ID_gt1_CX_2 -%} + {% endif -%} {% endif -%} + {% include 'Resource/Account' GT1: gt1SegmentLists, ID: accountId, REF_PATIENT: fullPatientId, REF_RELATED_PERSON: gt1relatedPersonId, REF_ORG: Organization_ID_gt1_XON_21 -%} {% endfor -%} - {% endif -%} - {% if firstSegments.PV1.52 -%} - {% if firstSegments.PV1.52.9.1 != "" and firstSegments.PV1.52.9.1 != null and firstSegments.PV1.52.9.2 != "" and firstSegments.PV1.52.9.2 != null and firstSegments.PV1.52.9.3 != "" and firstSegments.PV1.52.9.3 != null -%} - {% evaluate Organization_ID_PV1_52_9 using 'ID/Organization' HDORG: firstSegments.PV1.52.9 -%} - {% include 'Resource/Organization', PV1: firstSegments.PV1.52.9, ID: Organization_ID_PV1_52_9 -%} - {% endif -%} - {% evaluate practitionerId_PV1_52 using 'ID/Practitioner' XCN: firstSegments.PV1.52 -%} - {% include 'Resource/Practitioner' PV1: firstSegments.PV1.52, ID: practitionerId_PV1_52 -%} {% endif -%} - {% if firstSegments.PV2.13 -%} - {% if firstSegments.PV2.13.9.1 != "" and firstSegments.PV2.13.9.1 != null and firstSegments.PV2.13.9.2 != "" and firstSegments.PV2.13.9.2 != null and firstSegments.PV2.13.9.3 != "" and firstSegments.PV2.13.9.3 != null -%} - {% evaluate Organization_ID_PV2_13_9 using 'ID/Organization' HDORG: firstSegments.PV2.13.9 -%} - {% include 'Resource/Organization', PV2: firstSegments.PV2.13.9, ID: Organization_ID_PV2_13_9 -%} - {% endif -%} - {% evaluate practitionerId_PV2_13 using 'ID/Practitioner' XCN: firstSegments.PV2.13 -%} - {% include 'Resource/Practitioner' PV1: firstSegments.PV2.13, ID: practitionerId_PV2_13 -%} + {% if firstSegments.PID.2 -%} + {% if firstSegments.PID.2.4.1 != "" and firstSegments.PID.2.4.1 != null and firstSegments.PID.2.4.2 != "" and firstSegments.PID.2.4.2 != null and firstSegments.PID.2.4.3 != "" and firstSegments.PID.2.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_2 using 'ID/Organization' HDORG: firstSegments.PID.2.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.2, ID: Organization_ID_pid_CX_2 -%} + {% endif -%} + {% endif -%} + {% for pid3 in firstSegments.PID.3.Repeats -%} + {% if pid3.4.1 != "" and pid3.4.1 != null and pid3.4.2 != "" and pid3.4.2 != null and pid3.4.3 != "" and pid3.4.3 != null -%} + {% evaluate Organization_ID_pid_CX using 'ID/Organization' HDORG: pid3.4 -%} + {% include 'Resource/Organization', PID: pid3, ID: Organization_ID_pid_CX -%} + {% endif -%} + {% endfor -%} + {% if firstSegments.PID.4 -%} + {% if firstSegments.PID.4.4.1 != "" and firstSegments.PID.4.4.1 != null and firstSegments.PID.4.4.2 != "" and firstSegments.PID.4.4.2 != null and firstSegments.PID.4.4.3 != "" and firstSegments.PID.4.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_4 using 'ID/Organization' HDORG: firstSegments.PID.4.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.4, ID: Organization_ID_pid_CX_4 -%} + {% endif -%} {% endif -%} - {% if firstSegments.EVN.5 -%} - {% if firstSegments.EVN.5.9.1 != "" and firstSegments.EVN.5.9.1 != null and firstSegments.EVN.5.9.2 != "" and firstSegments.EVN.5.9.2 != null and firstSegments.EVN.5.9.3 != "" and firstSegments.EVN.5.9.3 != null -%} - {% evaluate Organization_ID_EVN_5_9 using 'ID/Organization' HDORG: firstSegments.EVN.5.9 -%} - {% include 'Resource/Organization', EVN: firstSegments.EVN.5.9, ID: Organization_ID_EVN_5_9 -%} - {% endif -%} - {% evaluate practitionerId_EVN_5 using 'ID/Practitioner' XCN: firstSegments.EVN.5 -%} - {% include 'Resource/Practitioner' EVN: firstSegments.EVN.5, ID: practitionerId_EVN_5 -%} + {% unless nk1SegmentLists.NK1 -%} + {% if firstSegments.PID.21 -%} + {% if firstSegments.PID.21.4.1 != "" and firstSegments.PID.21.4.1 != null and firstSegments.PID.21.4.2 != "" and firstSegments.PID.21.4.2 != null and firstSegments.PID.21.4.3 != "" and firstSegments.PID.21.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_21 using 'ID/Organization' HDORG: firstSegments.PID.21.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.21, ID: Organization_ID_pid_CX_21 -%} + {% endif -%} + {% evaluate pidrelatedPersonId using 'ID/RelatedPerson' PID: firstSegments.PID, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: pidrelatedPersonId, PID: firstSegments.PID -%} + {% endif -%} + {% endunless -%} + {% if firstSegments.PD1.3 -%} + {% evaluate Organization_ID_PD1_3 using 'ID/Organization' XON: firstSegments.PD1.3 -%} + {% include 'Resource/Organization' PD1: firstSegments.PD1, ID: Organization_ID_PD1_3 -%} {% endif -%} {% if firstSegments.PD1.4 -%} @@ -125,148 +180,626 @@ {% evaluate Practitioner_ID_PD1_4 using 'ID/Practitioner' XCN: firstSegments.PD1.4 -%} {% include 'Resource/Practitioner' PD1: firstSegments.PD1.4, ID: Practitioner_ID_PD1_4 -%} {% endif -%} - - {% evaluate locationId_ORC_21 using 'ID/Location' XON: firstSegments.ORC.21 -%} - {% include 'Resource/Location' ORC: firstSegments.ORC, ID: locationId_ORC_21 -%} - {% if firstSegments.PV1.3 -%} - {% include 'Resource/PLLocation' PL: firstSegments.PV1.3-%} - {% endif -%} + {% if firstSegments.PV1 -%} + {% if firstSegments.PV1.5 -%} + {% if firstSegments.PV1.5.4.1 != "" and firstSegments.PV1.5.4.1 != null and firstSegments.PV1.5.4.2 != "" and firstSegments.PV1.5.4.2 != null and firstSegments.PV1.5.4.3 != "" and firstSegments.PV1.5.4.3 != null -%} + {% evaluate Organization_ID_PV1_5_4 using 'ID/Organization' HDORG: firstSegments.PV1.5.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.5.4, ID: Organization_ID_PV1_5_4 -%} + {% endif -%} + {% endif -%} - {% if firstSegments.PV1.6 -%} - {% include 'Resource/PLLocation' PL: firstSegments.PV1.6 -%} - {% endif -%} + {% if firstSegments.PV1.19 -%} + {% if firstSegments.PV1.19.4.1 != "" and firstSegments.PV1.19.4.1 != null and firstSegments.PV1.19.4.2 != "" and firstSegments.PV1.19.4.2 != null and firstSegments.PV1.19.4.3 != "" and firstSegments.PV1.19.4.3 != null -%} + {% evaluate Organization_ID_PV1_19_4 using 'ID/Organization' HDORG: firstSegments.PV1.19.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.19.4, ID: Organization_ID_PV1_19_4 -%} + {% endif -%} + {% endif -%} - {% if firstSegments.PV1.37 -%} - {% evaluate location_ID_PV1_37 using 'ID/Location' DLD: firstSegments.PV1.37 -%} - {% include 'Resource/Location' PV1: firstSegments.PV1.37, ID: location_ID_PV1_37-%} - {% endif -%} - - {% if firstSegments.PV1.42 -%} - {% include 'Resource/PLLocation' PL: firstSegments.PV1.42-%} - {% endif -%} - - {% if firstSegments.PV1.43 -%} - {% include 'Resource/PLLocation' PL: firstSegments.PV1.43-%} - {% endif -%} + {% if firstSegments.PV1.7 -%} + {% if firstSegments.PV1.7.9.1 != "" and firstSegments.PV1.7.9.1 != null and firstSegments.PV1.7.9.2 != "" and firstSegments.PV1.7.9.2 != null and firstSegments.PV1.7.9.3 != "" and firstSegments.PV1.7.9.3 != null -%} + {% evaluate Organization_ID_PV1_7_9 using 'ID/Organization' HDORG: firstSegments.PV1.7.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.7.9, ID: Organization_ID_PV1_7_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_7 using 'ID/Practitioner' XCN: firstSegments.PV1.7 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.7, ID: practitionerId_PV1_7 -%} + {% endif -%} - {% if firstSegments.PV2.1 -%} - {% include 'Resource/PLLocation' PL: firstSegments.PV2.1-%} - {% endif -%} - - {% evaluate provenanceId using 'ID/Provenance' MSH: firstSegments.MSH, baseId: patientId -%} - {% include 'Resource/Provenance' Root_Template: 'OML_O21', MSH: firstSegments.MSH, ORC: firstSegments.ORC, ID: provenanceId -%} + {% if firstSegments.PV1.8 -%} + {% if firstSegments.PV1.8.9.1 != "" and firstSegments.PV1.8.9.1 != null and firstSegments.PV1.8.9.2 != "" and firstSegments.PV1.8.9.2 != null and firstSegments.PV1.8.9.3 != "" and firstSegments.PV1.8.9.3 != null -%} + {% evaluate Organization_ID_PV1_8_9 using 'ID/Organization' HDORG: firstSegments.PV1.8.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.8.9, ID: Organization_ID_PV1_8_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_8 using 'ID/Practitioner' XCN: firstSegments.PV1.8 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.8, ID: practitionerId_PV1_8 -%} + {% endif -%} - {% evaluate accountId using 'ID/Account' CX: firstSegments.PID.3 -%} - {% include 'Resource/Account' PID: firstSegments.PID, ID: accountId -%} - {% include 'Reference/Account/Subject' ID: accountId, REF: fullPatientId -%} + {% if firstSegments.PV1.9 -%} + {% if firstSegments.PV1.9.9.1 != "" and firstSegments.PV1.9.9.1 != null and firstSegments.PV1.9.9.2 != "" and firstSegments.PV1.9.9.2 != null and firstSegments.PV1.9.9.3 != "" and firstSegments.PV1.9.9.3 != null -%} + {% evaluate Organization_ID_PV1_9_9 using 'ID/Organization' HDORG: firstSegments.PV1.9.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.9.9, ID: Organization_ID_PV1_9_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_9 using 'ID/Practitioner' XCN: firstSegments.PV1.9 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.9, ID: practitionerId_PV1_9 -%} + {% endif -%} - {% if firstSegments.PV1.54 -%} - {% if firstSegments.PV1.54.4.1 != "" and firstSegments.PV1.54.4.1 != null and firstSegments.PV1.54.4.2 != "" and firstSegments.PV1.54.4.2 != null and firstSegments.PV1.54.4.3 != "" and firstSegments.PV1.54.4.3 != null -%} - {% evaluate Organization_ID_PV1_54_4 using 'ID/Organization' HDORG: firstSegments.PV1.54.4 -%} - {% include 'Resource/Organization', PV1: firstSegments.PV1.54.4, ID: Organization_ID_PV1_54_4 -%} - {% endif -%} - {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: firstSegments.PV1.54 -%} - {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId -%} - {% endif -%} + {% if firstSegments.PV1.17 -%} + {% if firstSegments.PV1.17.9.1 != "" and firstSegments.PV1.17.9.1 != null and firstSegments.PV1.17.9.2 != "" and firstSegments.PV1.17.9.2 != null and firstSegments.PV1.17.9.3 != "" and firstSegments.PV1.17.9.3 != null -%} + {% evaluate Organization_ID_PV1_17_9 using 'ID/Organization' HDORG: firstSegments.PV1.17.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.17.9, ID: Organization_ID_PV1_17_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_17 using 'ID/Practitioner' XCN: firstSegments.PV1.17 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.17, ID: practitionerId_PV1_17 -%} + {% endif -%} - {% evaluate encounterId using 'ID/Encounter' PV1: firstSegments.PV1, baseId: patientId -%} - {% include 'Resource/Encounter' Root_Template: 'OML_021', PV1: firstSegments.PV1, PV2: firstSegments.PV2, ID: encounterId -%} - {% include 'Reference/Encounter/Subject' ID: encounterId, REF: fullPatientId -%} - {% include 'Extensions/Encounter/EncounterExtension' ID: encounterId, PV1: firstSegments.PV1, PV2: firstSegments.PV2, -%} - - {% for al1Segment in al1SegmentLists.AL1 -%} - {% evaluate allergyIntoleranceId using 'ID/AllergyIntolerance' AL1: al1Segment, baseId: patientId -%} - {% include 'Resource/AllergyIntolerance' AL1: al1Segment, ID: allergyIntoleranceId, AllergyIntolerance_Patient_ID: fullPatientId -%} - {% endfor -%} + {% if firstSegments.PV1.50 -%} + {% for p in firstSegments.PV1.50.Repeats -%} + {% if p.4.1 != "" and p.4.1 != null and p.4.2 != "" and p.4.2 != null and p.4.3 != "" and p.4.3 != null -%} + {% evaluate Organization_ID_PV1_50_4 using 'ID/Organization' HDORG: p.4 -%} + {% include 'Resource/Organization', PV1: p.4, ID: Organization_ID_PV1_50_4 -%} + {% endif -%} + {% endfor -%} + {% endif -%} - {% for nk1Segment in nk1SegmentLists.NK1 -%} - {% evaluate organizationId_NK1_13 using 'ID/Organization' XON: nk1Segment.13 -%} - {% include 'Resource/Organization' NK1: nk1Segment, ID: organizationId_NK1_13 -%} + {% if firstSegments.PV1.52 -%} + {% if firstSegments.PV1.52.9.1 != "" and firstSegments.PV1.52.9.1 != null and firstSegments.PV1.52.9.2 != "" and firstSegments.PV1.52.9.2 != null and firstSegments.PV1.52.9.3 != "" and firstSegments.PV1.52.9.3 != null -%} + {% evaluate Organization_ID_PV1_52_9 using 'ID/Organization' HDORG: firstSegments.PV1.52.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.52.9, ID: Organization_ID_PV1_52_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_52 using 'ID/Practitioner' XCN: firstSegments.PV1.52 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.52, ID: practitionerId_PV1_52 -%} + {% endif -%} - {% include 'Resource/Patient' NK1: nk1Segment, ID: patientId -%} + {% if firstSegments.PV2.13 -%} + {% if firstSegments.PV2.13.9.1 != "" and firstSegments.PV2.13.9.1 != null and firstSegments.PV2.13.9.2 != "" and firstSegments.PV2.13.9.2 != null and firstSegments.PV2.13.9.3 != "" and firstSegments.PV2.13.9.3 != null -%} + {% evaluate Organization_ID_PV2_13_9 using 'ID/Organization' HDORG: firstSegments.PV2.13.9 -%} + {% include 'Resource/Organization', PV2: firstSegments.PV2.13.9, ID: Organization_ID_PV2_13_9 -%} + {% endif -%} + {% evaluate practitionerId_PV2_13 using 'ID/Practitioner' XCN: firstSegments.PV2.13 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV2.13, ID: practitionerId_PV2_13 -%} + {% endif -%} - {% evaluate relatedPersonId using 'ID/RelatedPerson' NK1: nk1Segment, baseId: patientId -%} - {% include 'Resource/RelatedPerson' NK1: nk1Segment, RelatedPerson_Patient_ID: fullPatientId, ID: relatedPersonId -%} - {% endfor -%} + {% if firstSegments.PV1.3 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.3-%} + {% endif -%} - {% for orcSegment in orcSegmentLists.ORC -%} - {% assign tq1SegmentLists = hl7v2Data | get_related_segment_list: orcSegment, 'TQ1' -%} - {% assign obrSegmentLists = hl7v2Data | get_related_segment_list: orcSegment, 'OBR' -%} - {% assign obxSegmentLists = hl7v2Data | get_related_segment_list: orcSegment, 'OBX' -%} - {% assign dg1SegmentLists = hl7v2Data | get_related_segment_list: orcSegment, 'DG1' -%} + {% if firstSegments.PV1.6 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.6 -%} + {% endif -%} - {% evaluate organizationId_ORC_21 using 'ID/Organization' CWE: orcSegment.21 -%} - {% evaluate organizationId_ORC_17 using 'ID/Organization' CWE: orcSegment.17 -%} + {% if firstSegments.PV1.37 -%} + {% evaluate location_ID_PV1_37 using 'ID/Location' DLD: firstSegments.PV1.37 -%} + {% include 'Resource/Location' PV1: firstSegments.PV1.37, ID: location_ID_PV1_37-%} + {% endif -%} - {% include 'Resource/Organization' ORC: orcSegment, ID: organizationId_ORC_21 -%} - {% include 'Resource/Organization' ORC: orcSegment, ID: organizationId_ORC_17 -%} + {% if firstSegments.PV1.42 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.42-%} + {% endif -%} + + {% if firstSegments.PV1.43 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.43-%} + {% endif -%} - {% evaluate serviceRequestId using 'ID/ServiceRequest' ORC: orcSegment, baseId: patientId -%} - {% assign fullServiceRequestId = serviceRequestId | prepend: 'ServiceRequest/' -%} - {% include 'Resource/ServiceRequest' ORC: orcSegment, ServiceRequest_Subject_ID: fullPatientId, ID: serviceRequestId -%} + {% if firstSegments.PV2.1 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV2.1-%} + {% endif -%} - {% evaluate provenanceId using 'ID/Provenance' ORC: orcSegment, baseId: patientId -%} - {% include 'Resource/Provenance' ORC: orcSegment, ID: provenanceId -%} - {% include 'Reference/Provenance/Target' ID: provenanceId, REF: fullServiceRequestId -%} + {% if firstSegments.PV1.54 -%} + {% if firstSegments.PV1.54.4.1 != "" and firstSegments.PV1.54.4.1 != null and firstSegments.PV1.54.4.2 != "" and firstSegments.PV1.54.4.2 != null and firstSegments.PV1.54.4.3 != "" and firstSegments.PV1.54.4.3 != null -%} + {% evaluate Organization_ID_PV1_54_4 using 'ID/Organization' HDORG: firstSegments.PV1.54.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.54.4, ID: Organization_ID_PV1_54_4 -%} + {% endif -%} + {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: firstSegments.PV1.54 -%} + {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId -%} + {% endif -%} - {% for tq1Segment in tq1SegmentLists.TQ1 -%} - {% include 'Resource/ServiceRequest' TQ1: tq1Segment, ID: serviceRequestId -%} - {% endfor -%} + {% evaluate encounterId using 'ID/Encounter' PV1: firstSegments.PV1, baseId: patientId -%} + {% include 'Resource/Encounter' Root_Template: 'OML_O21', PV1: firstSegments.PV1, PV2: firstSegments.PV2, ID: encounterId -%} + {% include 'Reference/Encounter/Subject' ID: encounterId, REF: fullPatientId -%} + {% include 'Extensions/Encounter/EncounterExtension' ID: encounterId, PV1: firstSegments.PV1, PV2: firstSegments.PV2, -%} + {% endif -%} - {% for obrSegment in obrSegmentLists.OBR -%} - {% evaluate practitionerId_OBR_10 using 'ID/Practitioner' XCN: obrSegment.10 -%} - {% include 'Resource/Practitioner' OBR: obrSegment, ID: practitionerId_OBR_10 -%} + {% for nk1Segment in nk1SegmentLists.NK1 -%} + {% evaluate relatedPersonId using 'ID/RelatedPerson' NK1: nk1Segment, baseId: patientId -%} + {% if nk1Segment.13 -%} + {% evaluate organizationId_NK1_13 using 'ID/Organization' XON: nk1Segment.13 -%} + {% include 'Resource/Organization' NK1: nk1Segment, ID: organizationId_NK1_13 -%} + {% assign Organization_NK1_13 = organizationId_NK1_13 | prepend: 'Organization/' -%} + {% include 'Reference/Patient/Contact_Organization' REF:Organization_NK1_13 , ID: patientId -%} + {% endif -%} + {% unless nk1Segment.3.1.Value == "EMR" or nk1Segment.3.1.Value == "CGV" or nk1Segment.7.1.Value == "E" or nk1Segment.7.1.Value =="F" or nk1Segment.7.1.Value == "I" or nk1Segment.7.1.Value =="S" -%} + {% include 'Resource/Patient' NK1: nk1Segment, ID: patientId -%} + {% include 'Resource/RelatedPerson' NK1: nk1Segment, RelatedPerson_Patient_ID: fullPatientId, ID: relatedPersonId, PID: firstSegments.PID -%} + {% include 'Extensions/RelatedPerson/RelatedPerson' ID: relatedPersonId, NK1: nk1Segment -%} + {% if nk1Segment.12.4.1 != "" and nk1Segment.12.4.1 != null and nk1Segment.12.4.2 != "" and nk1Segment.12.4.2 != null and nk1Segment.12.4.3 != "" and nk1Segment.12.4.3 != null -%} + {% evaluate Organization_ID_nk_CX_12 using 'ID/Organization' HDORG: nk1Segment.12.4 -%} + {% include 'Resource/Organization', NK1_12: nk1Segment.12, ID: Organization_ID_nk_CX_12 -%} + {% endif -%} + {% endunless -%} + {% if firstSegments.PID.21 -%} + {% include 'Resource/RelatedPerson' ID: relatedPersonId, PID: firstSegments.PID, RelatedPerson_Patient_ID: fullPatientId -%} + {% if firstSegments.PID.21.4.1 != "" and firstSegments.PID.21.4.1 != null and firstSegments.PID.21.4.2 != "" and firstSegments.PID.21.4.2 != null and firstSegments.PID.21.4.3 != "" and firstSegments.PID.21.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_21 using 'ID/Organization' HDORG: firstSegments.PID.21.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.21, ID: Organization_ID_pid_CX_21 -%} + {% endif -%} + {% endif -%} - {% include 'Resource/ServiceRequest' OBR: obrSegment, ID: serviceRequestId -%} + {% for nk33 in nk1Segment.33.Repeats -%} + {% if nk33.4.1 != "" and nk33.4.1 != null and nk33.4.2 != "" and nk33.4.2 != null and nk33.4.3 != "" and nk33.4.3 != null -%} + {% evaluate Organization_ID_nk_CX_33 using 'ID/Organization' HDORG: nk33.4 -%} + {% include 'Resource/Organization', NK1_33: nk33, ID: Organization_ID_nk_CX_33 -%} + {% endif -%} {% endfor -%} + {% endfor -%} - {% for obxSegment in obxSegmentLists.OBX -%} - {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} - {% if obxSegment.24 or obxSegment.25 -%} - {% include 'Resource/Organization' OBX: obxSegment, ID: organizationId_OBX_23 -%} + {% for al1Segment in al1SegmentLists.AL1 -%} + {% evaluate allergyIntoleranceId using 'ID/AllergyIntolerance' AL1: al1Segment, baseId: patientId -%} + {% include 'Resource/AllergyIntolerance' AL1: al1Segment, ID: allergyIntoleranceId, AllergyIntolerance_Patient_ID: fullPatientId -%} + {% endfor -%} + + {% for in1Segment in in1SegmentLists.IN1 -%} + {% assign in2SegmentLists = hl7v2Data | get_related_segment_list: in1Segment, 'IN2' -%} + {% evaluate coverageId using 'ID/Coverage' CX: in1Segment -%} + {% include 'Resource/Coverage' IN1: in1Segment, ID: coverageId -%} + {% include 'Reference/Coverage/Beneficiary' ID: coverageId, REF: fullPatientId -%} + + {% for in1_49 in in1Segment.49.Repeats -%} + {% if in1_49.4.1 != "" and in1_49.4.1 != null and in1_49.4.2 != "" and in1_49.4.2 != null and in1_49.4.3 != "" and in1_49.4.3 != null -%} + {% evaluate Organization_ID_in1_CX_49 using 'ID/Organization' HDORG: in1_49.4 -%} + {% include 'Resource/Organization', IN1_49: in1_49, ID: Organization_ID_in1_CX_49 -%} {% endif -%} + {% endfor -%} - {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obxSegment.16 -%} - {% if obxSegment.16 -%} - {% include 'Resource/Practitioner' OBX: obxSegment, ID: practitionerId_OBX_16 -%} + {% for in1_3 in in1Segment.3.Repeats -%} + {% if in1_3.4.1 != "" and in1_3.4.1 != null and in1_3.4.2 != "" and in1_3.4.2 != null and in1_3.4.3 != "" and in1_3.4.3 != null -%} + {% evaluate Organization_ID_in1_CX_3 using 'ID/Organization' HDORG: in1_3.4 -%} + {% include 'Resource/Organization', IN1_3: in1_3, ID: Organization_ID_in1_CX_3 -%} {% endif -%} + {% endfor -%} - {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} - {% if obxSegment.16 or obxSegment.23 or obxSegment.25 -%} - {% include 'Resource/PractitionerRole' OBX: obxSegment, ID: practitionerRoleId_OBX_25 -%} + {% for in1_10 in in1Segment.10.Repeats -%} + {% if in1_10.4.1 != "" and in1_10.4.1 != null and in1_10.4.2 != "" and in1_10.4.2 != null and in1_10.4.3 != "" and in1_10.4.3 != null -%} + {% evaluate Organization_ID_in1_CX_10 using 'ID/Organization' HDORG: in1_10.4 -%} + {% include 'Resource/Organization', IN1_10: in1_10, ID: Organization_ID_in1_CX_10 -%} {% endif -%} + {% endfor -%} + + {% if in1Segment.4 -%} + {% evaluate Organization_ID_in1_4 using 'ID/Organization' XON: in1Segment.4 -%} + {% else -%} + {% evaluate Organization_ID_in1_4 using 'ID/Organization' CX: in1Segment -%} + {% endif -%} + {% if Organization_ID_in1_4 -%} + {% include 'Resource/Organization', IN1: in1Segment, ID: Organization_ID_in1_4 -%} + {% assign org_in1_4 = Organization_ID_in1_4 | prepend: 'Organization/' -%} + {% include 'Reference/Coverage/Payor' ID: coverageId, REF: org_in1_4 -%} + {% endif -%} + + {% if in1Segment.11 -%} + {% evaluate Organization_ID_in1_11 using 'ID/Organization' XON: in1Segment.11 -%} + {% else -%} + {% evaluate Organization_ID_in1_11 using 'ID/Organization' CX_IN1: in1Segment -%} + {% endif -%} + {% if Organization_ID_in1_11 -%} + {% include 'Resource/Organization', IN1_11: in1Segment, ID: Organization_ID_in1_11 -%} + {% assign org_in1_11 = Organization_ID_in1_11 | prepend: 'Organization/' -%} + {% include 'Reference/Coverage/PolicyHolder' ID: coverageId, REF: org_in1_11 -%} + {% endif -%} - {% evaluate deviceId_OBX_18 using 'ID/Device' HD: obxSegment.18 -%} - {% if obxSegment.18 -%} - {% include 'Resource/Device' OBX: obxSegment, ID: deviceId_OBX_18 -%} + {% if in1Segment.17.1.Value == "SEL" -%} + {% include 'Resource/Patient' PID_IN1: firstSegments.PID, IN1: in1Segment, ID: patientId -%} + {% include 'Reference/Coverage/Subscriber' ID: coverageId, REF: fullPatientId -%} + {% endif -%} + {% unless in1Segment.17.1.Value == "SEL" or in1Segment.17.Value == "" -%} + {% evaluate in1relatedPersonId using 'ID/RelatedPerson' IN1: in1Segment, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: in1relatedPersonId, IN1: in1Segment -%} + {% assign rel_in1_17 = in1relatedPersonId | prepend: 'RelatedPerson/' -%} + {% include 'Reference/Coverage/Subscriber' ID: coverageId, REF: rel_in1_17 -%} + {% endunless -%} + + {% for in2Segment in in2SegmentLists.IN2 -%} + {% if in1Segment.17.1.Value == "SEL" -%} + {% include 'Resource/Patient' IN2: in2Segment, ID: patientId -%} + {% endif -%} + {% unless in1Segment.17.1.Value == "SEL" or in1Segment.17.Value == "" -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: in1relatedPersonId, IN2: in2Segment -%} + {% endunless -%} + + {% unless in1Segment.10 and in1Segment.11 -%} + {% if in2Segment.3 -%} + {% evaluate in2relatedPersonId using 'ID/RelatedPerson' IN2: in2Segment, baseId: patientId -%} + {% if in2Segment.3.9.1 != "" and in2Segment.3.9.1 != null and in2Segment.3.9.2 != "" and in2Segment.3.9.2 != null and in2Segment.3.9.3 != "" and in2Segment.3.9.3 != null -%} + {% evaluate Organization_ID_IN2_3_9 using 'ID/Organization' HDORG: in2Segment.3.9 -%} + {% include 'Resource/Organization', IN2_3: in2Segment.3.9, ID: Organization_ID_IN2_3_9 -%} + {% endif -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: in2relatedPersonId, IN2_3: in2Segment -%} + {% assign relatedperson_3 = in2relatedPersonId | prepend: 'RelatedPerson/' -%} + {% include 'Reference/Coverage/PolicyHolder' ID: coverageId, REF: relatedperson_3 -%} + {% endif -%} + {% endunless -%} + + {% if in1Segment.10 == null and in1Segment.11 == null and in2Segment.3 == null -%} + {% if in2Segment.70 -%} + {% evaluate organization_Id_IN2_70 using 'ID/Organization' XON: in2Segment.70 -%} + {% include 'Resource/Organization' IN2_70: in2Segment, ID: organization_Id_IN2_70 -%} + {% assign org_in2_70 = organization_Id_IN2_70 | prepend: 'Organization/' -%} + {% include 'Reference/Coverage/PolicyHolder' ID: coverageId, REF: org_in2_70 -%} + {% endif -%} + {% endif -%} + + {% if Organization_ID_in1_11 -%} + {% include 'Resource/Organization', IN2_49: in2Segment, ID: Organization_ID_in1_11 -%} {% endif -%} + {% include 'Resource/Coverage' IN2: in2Segment, ID: coverageId -%} + {% include 'Resource/Patient' IN2_6: in2Segment, ID: patientId -%} + + {% for in2_1 in in2Segment.1.Repeats -%} + {% if in2_1.4.1 != "" and in2_1.4.1 != null and in2_1.4.2 != "" and in2_1.4.2 != null and in2_1.4.3 != "" and in2_1.4.3 != null -%} + {% evaluate Organization_ID_in2_CX_1 using 'ID/Organization' HDORG: in2_1.4 -%} + {% include 'Resource/Organization', IN2_1: in2_1, ID: Organization_ID_in2_CX_1 -%} + {% endif -%} + {% endfor -%} + {% if in2Segment.61 -%} + {% if in2Segment.61.4.1 != "" and in2Segment.61.4.1 != null and in2Segment.61.4.2 != "" and in2Segment.61.4.2 != null and in2Segment.61.4.3 != "" and in2Segment.61.4.3 != null -%} + {% evaluate Organization_ID_in2_CX_61 using 'ID/Organization' HDORG: in2Segment.61.4 -%} + {% include 'Resource/Organization', IN2_61: in2Segment.61, ID: Organization_ID_in2_CX_61 -%} + {% endif -%} + {% endif -%} + {% endfor -%} + + {% endfor -%} - {% evaluate observationId using 'ID/Observation' OBX: obxSegment, baseId: patientId -%} - {% include 'Resource/Observation' OBX: obxSegment, Observation_Subject_ID: fullPatientId, ID: observationId -%} + {% for orcSegment in orcSegmentLists.ORC -%} + {% assign tq1SegmentLists = hl7v2Data | get_related_segment_list: orcSegment, 'TQ1' -%} + {% assign obrSegmentLists = hl7v2Data | get_related_segment_list: orcSegment, 'OBR' -%} + {% assign pidSegmentLists = hl7v2Data | get_related_segment_list: orcSegment, 'PID' -%} + + {% assign obrSegment = obrSegmentLists.OBR[0] %} + {% assign checkParent = orcSegment %} + + {% assign ctdSegmentLists = hl7v2Data | get_related_segment_list: obrSegment, 'CTD' -%} + {% assign dg1SegmentLists = hl7v2Data | get_related_segment_list: obrSegment, 'DG1' -%} + {% assign obxSegmentLists = hl7v2Data | get_related_segment_list: obrSegment, 'OBX' -%} + {% assign spmSegmentLists = hl7v2Data | get_related_segment_list: obrSegment, 'SPM' -%} + + {% evaluate parentServiceRequestId_orc using 'ID/ServiceRequest' ORC: checkParent.31, baseId: patientId -%} + {% if obrSegment.29.Value == null %} + {% if checkParent.8 and checkParent.31 %} + {% include 'Resource/ServiceRequest' OBR: obrSegment, ORC: checkParent, ID: parentServiceRequestId_orc, ServiceRequest_Subject_ID: fullPatientId, type_msg: "OML" -%} + {% endif %} + {% endif %} + + {% evaluate serviceRequestId using 'ID/ServiceRequest' ORC: checkParent, baseId: patientId -%} + {% evaluate specimenId_obr using 'ID/Specimen' OBR: obrSegment -%} + {% assign fullSpecimenId_obr = specimenId_obr | prepend: 'Specimen/' -%} + {% evaluate parentServiceRequestId using 'ID/ServiceRequest' OBR_29: obrSegment.29, baseId: patientId -%} + {% include 'Resource/ServiceRequest' OBR_child: obrSegment, parentSegment: checkParent, ServiceRequest_Subject_ID: fullPatientId, ServiceRequest_ID_OBR_29: parentServiceRequestId, ServiceRequest_ID_ORC_8: parentServiceRequestId_orc, ID: serviceRequestId, type_msg: "OML" -%} + + {% evaluate practitionerId_ORC_12 using 'ID/Practitioner' XCN: checkParent.12.Repeats[0] -%} + {% if obrSegment.16 -%} + {% if obrSegment.16.Repeats[0] %} + {% if obrSegment.16.Repeats[0].9.1 != "" and obrSegment.16.Repeats[0].9.1 != null and obrSegment.16.Repeats[0].9.2 != "" and obrSegment.16.Repeats[0].9.2 != null and obrSegment.16.Repeats[0].9.3 != "" and obrSegment.16.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_OBR16 using 'ID/Organization' HDORG: obrSegment.16.Repeats[0].9 -%} + {% include 'Resource/Organization' OBR_SEG_16: obrSegment.16.Repeats[0].9, ID: Organization_ID_OBR16 -%} + {% endif -%} + {% endif -%} + {% evaluate practitionerId_OBR_16 using 'ID/Practitioner' XCN: obrSegment.16.Repeats[0] -%} + {% include 'Resource/Practitioner' OBR_SEG: obrSegment, OBRXCN_16: obrSegment.16.Repeats[0], ORC_SEG_24: checkParent.24, ID: practitionerId_OBR_16 -%} + {% evaluate practitionerRoleId_OBR_16 using 'ID/PractitionerRole' XCN: obrSegment.16.Repeats[0]-%} + {% include 'Resource/PractitionerRole' OBR: obrSegment, requestor_practitioner1: practitionerId_OBR_16, ID: practitionerRoleId_OBR_16 -%} + {% assign fullpractitionerRoleId_OBR_16 = practitionerRoleId_OBR_16 | prepend: 'PractitionerRole/' -%} + {% include 'Reference/ServiceRequest/Requester' REF: fullpractitionerRoleId_OBR_16, ID: serviceRequestId -%} + {% else %} + {% if checkParent.12 %} + {% if checkParent.12.Repeats[0].9.1 != "" and checkParent.12.Repeats[0].9.1 != null and checkParent.12.Repeats[0].9.2 != "" and checkParent.12.Repeats[0].9.2 != null and checkParent.12.Repeats[0].9.3 != "" and checkParent.12.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_ORC_12 using 'ID/Organization' HDORG: checkParent.12.Repeats[0].9 -%} + {% include 'Resource/Organization' ORC_SEG_12: checkParent.12.Repeats[0].9, ID: Organization_ID_ORC_12 -%} + {% endif -%} + {% include 'Resource/Practitioner' ORC_SEG: checkParent, ORCXCN_12: checkParent.12.Repeats[0], ORC_SEG_24: checkParent.24, ID: practitionerId_ORC_12 -%} + {% evaluate practitionerRoleId_ORC_12 using 'ID/PractitionerRole' XCN: checkParent.12.Repeats[0]-%} + {% include 'Resource/PractitionerRole' ORC: checkParent, requestor_practitioner2: practitionerId_ORC_12, ID: practitionerRoleId_ORC_12 -%} + {% assign fullPractitionerRoleId_ORC_12 = practitionerRoleId_ORC_12 | prepend: 'PractitionerRole/' -%} + {% include 'Reference/ServiceRequest/Requester' REF: fullPractitionerRoleId_ORC_12, ID: serviceRequestId -%} + {% else %} + {% if checkParent.21 %} + {% evaluate organizationId_ORC_21 using 'ID/Organization' XON: checkParent.21.Repeats[0] -%} + {% if checkParent.12.Repeats[0] == null or checkParent.12.Repeats[0] == "" and obrSegment.16 == null or obrSegment.16 == "" %} + {% include 'Resource/Organization' ORC_SEG: checkParent, ORC_SEG_22: checkParent.22, ORC_SEG_23: checkParent.23, ID: organizationId_ORC_21 -%} + {% endif %} + {% evaluate practitionerRoleId_ORC_21 using 'ID/PractitionerRole' XCN: checkParent.21.Repeats[0]-%} + {% include 'Resource/PractitionerRole' ORC: checkParent, requestor_organization: organizationId_ORC_21, ID: practitionerRoleId_ORC_21 -%} + {% assign fullPractitionerRoleId_ORC_21 = practitionerRoleId_ORC_21 | prepend: 'PractitionerRole/' -%} + {% include 'Reference/ServiceRequest/Requester' REF: fullPractitionerRoleId_ORC_21, ID: serviceRequestId -%} + {% endif %} + {% endif -%} + {% endif %} - {% assign fullObservationId = observationId | prepend: 'Observation/' -%} - {% include 'Reference/ServiceRequest/SupportingInfo' ID: serviceRequestId, REF: fullObservationId -%} + {% include 'Reference/ServiceRequest/Specimen' REF: fullSpecimenId_obr, ID: serviceRequestId -%} + + {% if obrSegment.29 %} + {% if obrSegment.50 -%} + {% evaluate parentServiceRequestId using 'ID/ServiceRequest' OBR_29: obrSegment.29, baseId: patientId -%} + {% include 'Resource/ServiceRequest' OBR_parent: obrSegment, parentSegment: checkParent, ServiceRequest_Subject_ID: fullPatientId, ID: parentServiceRequestId, type_msg: "OML" -%} + {% endif %} + {% endif %} + + {% assign fullParentServiceRequestId = parentServiceRequestId | prepend: 'ServiceRequest/' -%} + + {% assign nteSegmentLists1 = hl7v2Data | get_related_segment_list: obrSegment, 'NTE' -%} + {% for nteSegment1 in nteSegmentLists1.NTE -%} + {% if nteSegment1.5 -%} + {% if nteSegment1.5.9.1 != "" and nteSegment1.5.9.1 != null and nteSegment1.5.9.2 != "" and nteSegment1.5.9.2 != null and nteSegment1.5.9.3 != "" and nteSegment1.5.9.3 != null -%} + {% evaluate Organization_ID_NTE1_5_9 using 'ID/Organization' HDORG: nteSegment1.5.9 -%} + {% include 'Resource/Organization' OBR_NTE: nteSegment1.5.9, ID: Organization_ID_NTE1_5_9 -%} + {% endif -%} + {% evaluate practitioner_ID_NTE_5 using 'ID/Practitioner' XCN: nteSegment1.5 -%} + {% include 'Resource/Practitioner' NTE: nteSegment1.5, ID: practitioner_ID_NTE_5 -%} + {% endif -%} + {% include 'Resource/ServiceRequest' NTE: nteSegment1, ID: serviceRequestId -%} + {% endfor -%} + + {% if obrSegment %} + {% include 'Resource/Specimen' OBR: obrSegment, ID: specimenId_obr -%} + {% endif %} + + {% if obrSegment.10 %} + {% if obrSegment.10.Repeats[0].9.1 != "" and obrSegment.10.Repeats[0].9.1 != null and obrSegment.10.Repeats[0].9.2 != "" and obrSegment.10.Repeats[0].9.2 != null and obrSegment.10.Repeats[0].9.3 != "" and obrSegment.10.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_OBR10 using 'ID/Organization' HDORG: obrSegment.10.Repeats[0].9 -%} + {% include 'Resource/Organization' OBR_SEG_10: obrSegment.10.Repeats[0].9, ID: Organization_ID_OBR10 -%} + {% endif -%} + {% evaluate practitionerId_OBR_10 using 'ID/Practitioner' XCN: obrSegment.10.Repeats[0] -%} + {% include 'Resource/Practitioner' OBR_SEG: obrSegment, OBRXCN_10: obrSegment.10.Repeats[0], ID: practitionerId_OBR_10 -%} + {% evaluate practitionerRoleId_OBR_10 using 'ID/PractitionerRole' XCN: obrSegment.10.Repeats[0] -%} + {% assign full_practitionerId_obr_10 = practitionerRoleId_OBR_10 | prepend: 'PractitionerRole/' %} + {% include 'Resource/PractitionerRole' OBR: obrSegment, collection_collector_practitioner: practitionerId_obr_10, ID: practitionerRoleId_OBR_10 -%} + {% include 'Reference/Specimen/Collection_Collector' REF: full_practitionerId_obr_10, ID: specimenId_obr -%} + {% endif -%} + + {% for ctdSegment in ctdSegmentLists.CTD -%} + {% include 'Resource/Patient' CTD: ctdSegment, ID: patientId -%} {% endfor -%} {% for dg1Segment in dg1SegmentLists.DG1 -%} - {% evaluate practitionerId_DG1_16 using 'ID/Practitioner' XCN: dg1Segment.16 -%} - {% include 'Resource/Practitioner' DG1: dg1Segment, ID: practitionerId_DG1_16 -%} - + {% if dg1Segment.16.Repeats[0] %} + {% if dg1Segment.16.Repeats[0].9.1 != "" and dg1Segment.16.Repeats[0].9.1 != null and dg1Segment.16.Repeats[0].9.2 != "" and dg1Segment.16.Repeats[0].9.2 != null and dg1Segment.16.Repeats[0].9.3 != "" and dg1Segment.16.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_DG1_16 using 'ID/Organization' HDORG: dg1Segment.16.Repeats[0].9 -%} + {% include 'Resource/Organization', DG1: dg1Segment.16.Repeats[0].9, ID: Organization_ID_DG1_16 -%} + {% endif -%} + {% evaluate practitionerId_DG1_16 using 'ID/Practitioner' XCN: dg1Segment.16.Repeats[0] -%} + {% include 'Resource/Practitioner' DG1: dg1Segment, ID: practitionerId_DG1_16 -%} + {% endif -%} + {% evaluate conditionId using 'ID/Condition' DG1: dg1Segment, baseId: patientId -%} - {% include 'Resource/Condition' DG1: obxSegment, Condition_Subject_ID: fullPatientId, ID: conditionId -%} + {% include 'Resource/Condition' DG1: dg1Segment, Condition_Subject_ID: fullPatientId, baseId: patientId, ID: conditionId -%} + {% assign fullConditionId = conditionId | prepend: 'Condition/' -%} + {% include 'Reference/ServiceRequest/ReasonReference' REF: fullConditionId, ID: serviceRequestId -%} + + {% if encounterId -%} + {% include 'Resource/Encounter' DG1: dg1Segment, conditionId: conditionId, ID: encounterId -%} + {% endif %} + {% if EpisodeOfCare_ID %} + {% include 'Resource/EpisodeOfCare' DG1: dg1Segment, conditionId: conditionId, ID: EpisodeOfCare_ID -%} + {% endif %} + {% if dg1Segment.22 -%} + {% evaluate conditionId_DG1_22 using 'ID/Condition' DG1: dg1Segment.22, baseId: patientId -%} + {% include 'Resource/Condition' DG1_22: dg1Segment.22, Condition_Subject_ID_DG1_22: fullPatientId, ID: conditionId_DG1_22 -%} + {% endif -%} + {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} - {% assign fullConditionId = conditionId | prepend: 'Condition/' -%} - {% include 'Reference/ServiceRequest/ReasonReference' ID: serviceRequestId, REF: fullConditionId -%} {% endfor -%} - {% for spmSegment in spmSegmentLists.SPM -%} - {% evaluate specimenId using 'ID/Specimen' SPM: spmSegment, baseId: patientId -%} - {% include 'Resource/Specimen' SPM: spmSegment, ID: specimenId -%} + {% for obxSegment in obxSegmentLists.OBX -%} + {% if obxSegment.2.Value == 'ED' or obxSegment.2.Value == 'RP' %} + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16 -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16 -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23 -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + {% evaluate obx_diagnosticReportID using 'ID/DiagnosticReport' OBX: obxSegment -%} + {% include 'Resource/DiagnosticReport' OBX: obxSegment, DiagnosticReport_ServiceRequest_ID: serviceRequestId, ID: obx_diagnosticReportID, DiagnosticReport_Subject_ID: fullPatientId -%} + {% else %} + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16 -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16 -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + {% if obxSegment.18 -%} + {% evaluate deviceId_OBX_18 using 'ID/Device' EI: obxSegment.18.Repeats[0] -%} + {% include 'Resource/Device' EI_OBX18: obxSegment.18, ID: deviceId_OBX_18 -%} + {% endif -%} + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23 -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + {% evaluate observationId using 'ID/Observation' OBX: obxSegment, baseId: patientId -%} + {% include 'Resource/Observation' OBX: obxSegment, Observation_Subject_ID: fullPatientId, Observation_ServiceRequest_ID : serviceRequestId, ID: observationId -%} + {% include 'Extensions/Observation/ObservationExtension' OBX: obxSegment, ID: observationId %} + {% assign nteSegmentLists2 = hl7v2Data | get_related_segment_list: obxSegment, 'NTE' -%} + {% for nteSegment2 in nteSegmentLists2.NTE -%} + {% if nteSegment2.5 -%} + {% if nteSegment2.5.9.1 != "" and nteSegment2.5.9.1 != null and nteSegment2.5.9.2 != "" and nteSegment2.5.9.2 != null and nteSegment2.5.9.3 != "" and nteSegment2.5.9.3 != null -%} + {% evaluate Organization_ID_NTE2_5_9 using 'ID/Organization' HDORG: nteSegment2.5.9 -%} + {% include 'Resource/Organization' OBX_NTE: nteSegment2.5.9, ID: Organization_ID_NTE2_5_9 -%} + {% endif -%} + {% evaluate practitioner_ID_NTE_5 using 'ID/Practitioner' XCN: nteSegment2.5 -%} + {% include 'Resource/Practitioner' NTE: nteSegment2.5, ID: practitioner_ID_NTE_5 -%} + {% endif -%} + {% include 'Resource/Observation' NTE: nteSegment2, ID: observationId -%} + {% endfor -%} + {% endif -%} + {% endfor -%} + + {% unless tq1SegmentLists.TQ1 -%} + {% include 'Resource/ServiceRequest' ID: serviceRequestId, OBR_tq1: obrSegmentLists.OBR[0], ORC_tq1: orcSegment -%} + {% endunless -%} + {% for tq1Segment in tq1SegmentLists.TQ1 -%} + {% include 'Resource/ServiceRequest' TQ1: tq1Segment, ID: serviceRequestId, OBR_timeday: obrSegmentLists.OBR[0] -%} + {% endfor -%} - {% assign fullSpecimenId = specimenId | prepend: 'Specimen/' -%} - {% include 'Reference/ServiceRequest/Specimen' ID: serviceRequestId, REF: fullSpecimenId -%} + {% for spmSegment in spmSegmentLists.SPM -%} + {% evaluate specimenId_spm using 'ID/Specimen' SPM: spmSegment, baseId: patientId -%} + {% include 'Resource/Specimen' SPM: spmSegment, ID: specimenId_spm -%} + {% assign fullServiceRequestId = serviceRequestId | prepend: 'ServiceRequest/' -%} + {% include 'Reference/Specimen/Request' ID: specimenId_spm, REF: fullServiceRequestId -%} + + {% if spmSegment.3 %} + {% for spmSegment_3 in spmSegment.3.Repeats %} + {% evaluate spm_specimenId_3 using 'ID/Specimen' SPM: spmSegment_3 -%} + {% include 'Resource/Specimen' SPM_parent: spmSegment_3, ID: spm_specimenId_3 -%} + {% assign fullSpecimenId_spm3 = spm_specimenId_3 | prepend: 'Specimen/' -%} + {% include 'Reference/Specimen/Parent' ID: specimenId_spm, REF: fullSpecimenId_spm3 -%} + {% endfor %} + {% endif %} + {% if spmSegment.30 -%} + {% if spmSegment.30.4.1 != "" and spmSegment.30.4.1 != null and spmSegment.30.4.2 != "" and spmSegment.30.4.2 != null and spmSegment.30.4.3 != "" and spmSegment.30.4.3 != null -%} + {% evaluate Organization_ID_SPM_30_4 using 'ID/Organization' HDORG: spmSegment.30.4 -%} + {% include 'Resource/Organization' SPM: spmSegment.30.4, ID: Organization_ID_SPM_30_4 -%} + {% endif -%} + {% endif -%} + {% if spmSegment.31 -%} + {% for spm_31 in spmSegment.31.Repeats %} + {% if spm_31.4.1 != "" and spm_31.4.1 != null and spm_31.4.2 != "" and spm_31.4.2 != null and spm_31.4.3 != "" and spm_31.4.3 != null -%} + {% evaluate Organization_ID_SPM_31_4 using 'ID/Organization' HDORG: spm_31.4 -%} + {% include 'Resource/Organization' SPM: spm_31.4, ID: Organization_ID_SPM_31_4 -%} + {% endif -%} + {% endfor %} + {% endif -%} + + {% include 'Extensions/Specimen/SpecimenExtension' ID: specimenId_spm, SPM: spmSegment -%} + {% assign fullSpecimenId_spm = specimenId_spm | prepend: 'Specimen/' -%} + + {% assign checkParentSPM = hl7v2Data | get_parent_segment: 'OBX', {{obxSegmentPositionIndex_spm}}, 'SPM' -%} + {% assign obxSegmentPositionIndex_spm = obxSegmentPositionIndex_spm | plus: 1 -%} + {% assign spm_obxSegmentLists = hl7v2Data | get_related_segment_list: spmSegment, 'OBX' -%} + {% for spm_obxSegment in spm_obxSegmentLists.OBX -%} + {% if spm_obxSegment.2.Value == 'ED' or spm_obxSegment.2.Value == 'RP' %} + {% for spm_obx_16 in spm_obxSegment.16.Repeats -%} + {% if spm_obx_16.9.1 != "" and spm_obx_16.9.1 != null and spm_obx_16.9.2 != "" and spm_obx_16.9.2 != null and spm_obx_16.9.3 != "" and spm_obx_16.9.3 != null -%} + {% evaluate Organization_ID_spm_obx_16 using 'ID/Organization' HDORG: spm_obx_16.9 -%} + {% include 'Resource/Organization' OBX: spm_obx_16.9, ID: Organization_ID_spm_obx_16 -%} + {% endif -%} + {% evaluate practitionerId_spm_obx_16 using 'ID/Practitioner' XCN: spm_obx_16 -%} + {% include 'Resource/Practitioner' OBX: spm_obxSegment, OBXXCN1: spm_obx_16, ID: practitionerId_spm_obx_16 -%} + {% evaluate practitionerRoleId_spm_obx_16 using 'ID/PractitionerRole' XCN: spm_obx_16 -%} + {% assign full_practitionerId_spm_obx_16 = practitionerId_spm_obx_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: spm_obx_16, ID: practitionerRoleId_spm_obx_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_spm_obx_16, ID: practitionerRoleId_spm_obx_16 -%} + {% endfor %} + {% if spm_obxSegment.23 or spm_obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: spm_obxSegment.25 -%} + {% endif %} + {% if spm_obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: spm_obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: spm_obxSegment, OBXXCN2: spm_obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: spm_obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if spm_obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: spm_obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: spm_obxSegment.23, OBX_24: spm_obxSegment.24, ID: organizationId_OBX_23 -%} + {% if spm_obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + {% evaluate spm_obx_diagnosticReportID using 'ID/DiagnosticReport' OBX: spm_obxSegment -%} + {% include 'Resource/DiagnosticReport' OBX: spm_obxSegment, DiagnosticReport_Subject_ID: fullPatientId, ID: spm_obx_diagnosticReportID -%} + {% if checkParentSPM %} + {% include 'Resource/DiagnosticReport' DiagnosticReport_Specimen_ID: fullSpecimenId_spm, ID: spm_obx_diagnosticReportID %} + {% endif %} + {% else %} + {% for spm_obx_16 in spm_obxSegment.16.Repeats -%} + {% if spm_obx_16.9.1 != "" and spm_obx_16.9.1 != null and spm_obx_16.9.2 != "" and spm_obx_16.9.2 != null and spm_obx_16.9.3 != "" and spm_obx_16.9.3 != null -%} + {% evaluate Organization_ID_spm_obx_16 using 'ID/Organization' HDORG: spm_obx_16.9 -%} + {% include 'Resource/Organization' OBX: spm_obx_16.9, ID: Organization_ID_spm_obx_16 -%} + {% endif -%} + {% evaluate practitionerId_spm_obx_16 using 'ID/Practitioner' XCN: spm_obx_16 -%} + {% include 'Resource/Practitioner' OBX: spm_obxSegment, OBXXCN1: spm_obx_16, ID: practitionerId_spm_obx_16 -%} + {% evaluate practitionerRoleId_spm_obx_16 using 'ID/PractitionerRole' XCN: spm_obx_16 -%} + {% assign full_practitionerId_spm_obx_16 = practitionerId_spm_obx_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: spm_obx_16, ID: practitionerRoleId_spm_obx_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_spm_obx_16, ID: practitionerRoleId_spm_obx_16 -%} + {% endfor %} + {% if spm_obxSegment.18 -%} + {% evaluate deviceId_OBX_18 using 'ID/Device' EI: spm_obxSegment.18.Repeats[0] -%} + {% include 'Resource/Device' EI_OBX18: spm_obxSegment.18, ID: deviceId_OBX_18 -%} + {% endif -%} + {% if spm_obxSegment.23 or spm_obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: spm_obxSegment.25 -%} + {% endif %} + {% if spm_obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: spm_obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: spm_obxSegment, OBXXCN2: spm_obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: spm_obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if spm_obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: spm_obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: spm_obxSegment.23, OBX_24: spm_obxSegment.24, ID: organizationId_OBX_23 -%} + {% if spm_obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + {% evaluate observationId using 'ID/Observation' OBX: spm_obxSegment, baseId: patientId -%} + {% include 'Resource/Observation' OBX: spm_obxSegment, Observation_Subject_ID: fullPatientId, SPM_Observation_Specimen_ID: fullSpecimenId_spm, ID: observationId -%} + {% if checkParentSPM %} + {% include 'Resource/Observation' Observation_Specimen_ID: fullSpecimenId_spm, ID: observationId %} + {% endif %} + {% include 'Extensions/Observation/ObservationExtension' OBX: spm_obxSegment, ID: observationId %} + {% endif %} {% endfor -%} + {% endfor -%} + + {% endfor -%} ] } \ No newline at end of file diff --git a/data/Templates/Hl7v2/ORM_O01.liquid b/data/Templates/Hl7v2/ORM_O01.liquid new file mode 100644 index 000000000..e07e4cd94 --- /dev/null +++ b/data/Templates/Hl7v2/ORM_O01.liquid @@ -0,0 +1,637 @@ +{% assign firstSegments = hl7v2Data | get_first_segments: 'MSH|PID|PD1|PV1|PV2' -%} + +{% assign gt1SegmentLists = hl7v2Data | get_segment_lists: 'GT1' -%} +{% assign in1SegmentLists = hl7v2Data | get_segment_lists: 'IN1' -%} +{% assign al1SegmentLists = hl7v2Data | get_segment_lists: 'AL1' -%} +{% assign orcSegmentLists = hl7v2Data | get_segment_lists: 'ORC' -%} +{% assign obxSegmentLists = hl7v2Data | get_segment_lists: 'OBX' -%} +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} + +{ + "resourceType": "Bundle", + "type": "batch", + {% if firstSegments.MSH.7 -%} + "timestamp":"{{ firstSegments.MSH.7.Value | format_as_date_time }}", + {% endif -%} + "identifier": + { + "value":"{{ firstSegments.MSH.10.Value }}", + }, + "id":"{{ bundleID }}", + "entry": [ + + {% evaluate patientId using 'ID/Patient' PID: firstSegments.PID, type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% evaluate messageHeaderId using 'ID/MessageHeader' MSH: firstSegments.MSH -%} + + {% if firstSegments.MSH -%} + + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, ID: messageHeaderId -%} + {% evaluate provenanceId using 'ID/Provenance' MSH: firstSegments.MSH, baseId: patientId -%} + {% include 'Resource/Provenance' Root_Template: 'ORM_O01', MSH: firstSegments.MSH, REF_BUNDLE: bundleID, ID: provenanceId -%} + + {%- comment -%} + {% assign transformation_val = 'provenance_transformation' %} + {% evaluate provenanceOrganizationId using 'ID/Organization', prov_id: firstSegments.MSH -%} + {% evaluate provenanceTransformationId using 'ID/Provenance_transformation' prov_id: transformation_val -%} + {% include 'Resource/Organization' org_name: 'Microsoft Corporation', ID: provenanceOrganizationId -%} + {% include 'Resource/Provenance_transformation' Root_Template: 'ADT_A01', Provenance_Organization_ID: provenanceOrganizationId, REF_MSH: messageHeaderId, provenanceOrganizationId, ID: provenanceTransformationId -%} + {%- endcomment -%} + + {% if firstSegments.MSH.4 -%} + {% if firstSegments.MSH.4.1 != "" and firstSegments.MSH.4.1 != null or firstSegments.MSH.4.2 != "" and firstSegments.MSH.4.2 != null or firstSegments.MSH.4.3 != "" and firstSegments.MSH.4.3 != null -%} + {% evaluate organization_ID_MSH_4 using 'ID/Organization' HD: firstSegments.MSH.4 -%} + {% include 'Resource/Organization' MSHHD1: firstSegments.MSH.4, MSH: firstSegments.MSH, ID: organization_ID_MSH_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.6 %} + {% if firstSegments.MSH.6.1 != "" and firstSegments.MSH.6.1 != null or firstSegments.MSH.6.2 != "" and firstSegments.MSH.6.2 != null or firstSegments.MSH.6.3 != "" and firstSegments.MSH.6.3 != null -%} + {% evaluate organization_Id_MSH_6 using 'ID/Organization' HD: firstSegments.MSH.6 -%} + {% include 'Resource/Organization' MSHHD2: firstSegments.MSH.6, MSH: firstSegments.MSH, ID: organization_Id_MSH_6 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.22 %} + {% if firstSegments.MSH.22.1 != "" and firstSegments.MSH.22.1 != null -%} + {% evaluate organization_Id_MSH_22 using 'ID/Organization' XON: firstSegments.MSH.22 -%} + {% include 'Resource/Organization' MSHXON1: firstSegments.MSH.22, ID: organization_Id_MSH_22 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.23 %} + {% if firstSegments.MSH.23.1 != "" and firstSegments.MSH.23.1 != null -%} + {% evaluate organization_Id_MSH_23 using 'ID/Organization' XON: firstSegments.MSH.23 -%} + {% include 'Resource/Organization' MSHXON2: firstSegments.MSH.23, ID: organization_Id_MSH_23 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.3 and firstSegments.MSH.24 %} + {% evaluate device_Id_MSH_3 using 'ID/Device' HD: firstSegments.MSH.3 -%} + {% include 'Resource/Device' MSH: firstSegments.MSH, ID: device_Id_MSH_3 -%} + {% endif -%} + + {% endif -%} + + {% include 'Resource/Patient' PID: firstSegments.PID, PD1: firstSegments.PD1, ID: patientId -%} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, PID: firstSegments.PID, PD1: firstSegments.PD1, PV1: firstSegments.PV1 -%} + + {% if firstSegments.PID.18 -%} + {% evaluate accountId using 'ID/Account' CX: firstSegments.PID.3 -%} + {% include 'Resource/Account' PID: firstSegments.PID, ID: accountId -%} + {% include 'Reference/Account/Subject' ID: accountId, REF: fullPatientId -%} + {% if firstSegments.PID.18.4.1 != "" and firstSegments.PID.18.4.1 != null and firstSegments.PID.18.4.2 != "" and firstSegments.PID.18.4.2 != null and firstSegments.PID.18.4.3 != "" and firstSegments.PID.18.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_18 using 'ID/Organization' HDORG: firstSegments.PID.18.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.18, ID: Organization_ID_pid_CX_18 -%} + {% endif -%} + + {% for gt1SegmentLists in gt1SegmentLists.GT1 -%} + {% if gt1SegmentLists.11.1.Value == "SEL" -%} + {% include 'Resource/Patient' PID: firstSegments.PID, GT1: gt1SegmentLists, ID: patientId, NK1_PER: nk1SegmentLists.NK1[0] -%} + {% if gt1SegmentLists.2.4.1 != "" and gt1SegmentLists.2.4.1 != null and gt1SegmentLists.2.4.2 != "" and gt1SegmentLists.2.4.2 != null and gt1SegmentLists.2.4.3 != "" and gt1SegmentLists.2.4.3 != null -%} + {% evaluate Organization_ID_gt1_CX_2 using 'ID/Organization' HDORG: gt1SegmentLists.2.4 -%} + {% include 'Resource/Organization', PID: gt1SegmentLists.2, ID: Organization_ID_gt1_CX_2 -%} + {% endif -%} + {% if gt1SegmentLists.19.4.1 != "" and gt1SegmentLists.19.4.1 != null and gt1SegmentLists.19.4.2 != "" and gt1SegmentLists.19.4.2 != null and gt1SegmentLists.19.4.3 != "" and gt1SegmentLists.19.4.3 != null -%} + {% evaluate Organization_ID_gt1_CX_19 using 'ID/Organization' HDORG: gt1SegmentLists.19.4 -%} + {% include 'Resource/Organization', PID: gt1SegmentLists.19, ID: Organization_ID_gt1_CX_19 -%} + {% endif -%} + {% if gt1SegmentLists.29.4.1 != "" and gt1SegmentLists.29.4.1 != null and gt1SegmentLists.29.4.2 != "" and gt1SegmentLists.29.4.2 != null and gt1SegmentLists.29.4.3 != "" and gt1SegmentLists.29.4.3 != null -%} + {% evaluate Organization_ID_gt1_CX_29 using 'ID/Organization' HDORG: gt1SegmentLists.29.4 -%} + {% include 'Resource/Organization', PID: gt1SegmentLists.29, ID: Organization_ID_gt1_CX_29 -%} + {% endif -%} + {% if gt1SegmentLists.51 and nk1SegmentLists.NK1[0].7.1.Value == "E" -%} + {% evaluate Organization_ID_gt1_XON_51 using 'ID/Organization' XON: gt1SegmentLists.51 -%} + {% include 'Resource/Organization', GT1_51: gt1SegmentLists, ID: Organization_ID_gt1_XON_51 -%} + {% assign Organization_GT1_51 = Organization_ID_gt1_XON_51 | prepend: 'Organization/' -%} + {% include 'Reference/Patient/Contact_Organization' REF:Organization_GT1_51 , ID: patientId -%} + {% endif -%} + {% else -%} + {% evaluate gt1relatedPersonId using 'ID/RelatedPerson' GT1: gt1SegmentLists, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: gt1relatedPersonId, GT1: gt1SegmentLists -%} + {% if gt1SegmentLists.2.4.1 != "" and gt1SegmentLists.2.4.1 != null and gt1SegmentLists.2.4.2 != "" and gt1SegmentLists.2.4.2 != null and gt1SegmentLists.2.4.3 != "" and gt1SegmentLists.2.4.3 != null -%} + {% evaluate Organization_ID_gt1_CX_2 using 'ID/Organization' HDORG: gt1SegmentLists.2.4 -%} + {% include 'Resource/Organization', PID: gt1SegmentLists.2, ID: Organization_ID_gt1_CX_2 -%} + {% endif -%} + {% if gt1SegmentLists.19.4.1 != "" and gt1SegmentLists.19.4.1 != null and gt1SegmentLists.19.4.2 != "" and gt1SegmentLists.19.4.2 != null and gt1SegmentLists.19.4.3 != "" and gt1SegmentLists.19.4.3 != null -%} + {% evaluate Organization_ID_gt1_CX_19 using 'ID/Organization' HDORG: gt1SegmentLists.19.4 -%} + {% include 'Resource/Organization', PID: gt1SegmentLists.19, ID: Organization_ID_gt1_CX_19 -%} + {% endif -%} + {% endif -%} + {% if gt1SegmentLists.21 -%} + {% evaluate Organization_ID_gt1_XON_21 using 'ID/Organization' XON: gt1SegmentLists.21 -%} + {% include 'Resource/Organization', GT1: gt1SegmentLists, ID: Organization_ID_gt1_XON_21 -%} + {% if gt1SegmentLists.2.4.1 != "" and gt1SegmentLists.2.4.1 != null and gt1SegmentLists.2.4.2 != "" and gt1SegmentLists.2.4.2 != null and gt1SegmentLists.2.4.3 != "" and gt1SegmentLists.2.4.3 != null -%} + {% evaluate Organization_ID_gt1_CX_2 using 'ID/Organization' HDORG: gt1SegmentLists.2.4 -%} + {% include 'Resource/Organization', PID: gt1SegmentLists.2, ID: Organization_ID_gt1_CX_2 -%} + {% endif -%} + {% endif -%} + {% include 'Resource/Account' GT1: gt1SegmentLists, ID: accountId, REF_PATIENT: fullPatientId, REF_RELATED_PERSON: gt1relatedPersonId, REF_ORG: Organization_ID_gt1_XON_21 -%} + {% endfor -%} + + {% endif -%} + + {% if firstSegments.PID.2 -%} + {% if firstSegments.PID.2.4.1 != "" and firstSegments.PID.2.4.1 != null and firstSegments.PID.2.4.2 != "" and firstSegments.PID.2.4.2 != null and firstSegments.PID.2.4.3 != "" and firstSegments.PID.2.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_2 using 'ID/Organization' HDORG: firstSegments.PID.2.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.2, ID: Organization_ID_pid_CX_2 -%} + {% endif -%} + {% endif -%} + {% for pid3 in firstSegments.PID.3.Repeats -%} + {% if pid3.4.1 != "" and pid3.4.1 != null and pid3.4.2 != "" and pid3.4.2 != null and pid3.4.3 != "" and pid3.4.3 != null -%} + {% evaluate Organization_ID_pid_CX using 'ID/Organization' HDORG: pid3.4 -%} + {% include 'Resource/Organization', PID: pid3, ID: Organization_ID_pid_CX -%} + {% endif -%} + {% endfor -%} + {% if firstSegments.PID.4 -%} + {% if firstSegments.PID.4.4.1 != "" and firstSegments.PID.4.4.1 != null and firstSegments.PID.4.4.2 != "" and firstSegments.PID.4.4.2 != null and firstSegments.PID.4.4.3 != "" and firstSegments.PID.4.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_4 using 'ID/Organization' HDORG: firstSegments.PID.4.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.4, ID: Organization_ID_pid_CX_4 -%} + {% endif -%} + {% endif -%} + + {% unless nk1SegmentLists.NK1 -%} + {% if firstSegments.PID.21 -%} + {% if firstSegments.PID.21.4.1 != "" and firstSegments.PID.21.4.1 != null and firstSegments.PID.21.4.2 != "" and firstSegments.PID.21.4.2 != null and firstSegments.PID.21.4.3 != "" and firstSegments.PID.21.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_21 using 'ID/Organization' HDORG: firstSegments.PID.21.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.21, ID: Organization_ID_pid_CX_21 -%} + {% endif -%} + {% evaluate pidrelatedPersonId using 'ID/RelatedPerson' PID: firstSegments.PID, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: pidrelatedPersonId, PID: firstSegments.PID -%} + {% endif -%} + {% endunless -%} + + {% if firstSegments.PD1.3 -%} + {% evaluate Organization_ID_PD1_3 using 'ID/Organization' XON: firstSegments.PD1.3 -%} + {% include 'Resource/Organization' PD1: firstSegments.PD1, ID: Organization_ID_PD1_3 -%} + {% endif -%} + + {% if firstSegments.PD1.4 -%} + {% if firstSegments.PD1.4.9.1 != "" and firstSegments.PD1.4.9.1 != null and firstSegments.PD1.4.9.2 != "" and firstSegments.PD1.4.9.2 != null and firstSegments.PD1.4.9.3 != "" and firstSegments.PD1.4.9.3 != null -%} + {% evaluate Organization_ID_PD1_4_9 using 'ID/Organization' HDORG: firstSegments.PD1.4.9 -%} + {% include 'Resource/Organization', PD1_4: firstSegments.PD1.4.9, ID: Organization_ID_PD1_4_9 -%} + {% endif -%} + {% evaluate Practitioner_ID_PD1_4 using 'ID/Practitioner' XCN: firstSegments.PD1.4 -%} + {% include 'Resource/Practitioner' PD1: firstSegments.PD1.4, ID: Practitioner_ID_PD1_4 -%} + {% endif -%} + + {% if firstSegments.PV1 -%} + {% if firstSegments.PV1.5 -%} + {% if firstSegments.PV1.5.4.1 != "" and firstSegments.PV1.5.4.1 != null and firstSegments.PV1.5.4.2 != "" and firstSegments.PV1.5.4.2 != null and firstSegments.PV1.5.4.3 != "" and firstSegments.PV1.5.4.3 != null -%} + {% evaluate Organization_ID_PV1_5_4 using 'ID/Organization' HDORG: firstSegments.PV1.5.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.5.4, ID: Organization_ID_PV1_5_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PV1.19 -%} + {% if firstSegments.PV1.19.4.1 != "" and firstSegments.PV1.19.4.1 != null and firstSegments.PV1.19.4.2 != "" and firstSegments.PV1.19.4.2 != null and firstSegments.PV1.19.4.3 != "" and firstSegments.PV1.19.4.3 != null -%} + {% evaluate Organization_ID_PV1_19_4 using 'ID/Organization' HDORG: firstSegments.PV1.19.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.19.4, ID: Organization_ID_PV1_19_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.PV1.7 -%} + {% if firstSegments.PV1.7.9.1 != "" and firstSegments.PV1.7.9.1 != null and firstSegments.PV1.7.9.2 != "" and firstSegments.PV1.7.9.2 != null and firstSegments.PV1.7.9.3 != "" and firstSegments.PV1.7.9.3 != null -%} + {% evaluate Organization_ID_PV1_7_9 using 'ID/Organization' HDORG: firstSegments.PV1.7.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.7.9, ID: Organization_ID_PV1_7_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_7 using 'ID/Practitioner' XCN: firstSegments.PV1.7 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.7, ID: practitionerId_PV1_7 -%} + {% endif -%} + + {% if firstSegments.PV1.8 -%} + {% if firstSegments.PV1.8.9.1 != "" and firstSegments.PV1.8.9.1 != null and firstSegments.PV1.8.9.2 != "" and firstSegments.PV1.8.9.2 != null and firstSegments.PV1.8.9.3 != "" and firstSegments.PV1.8.9.3 != null -%} + {% evaluate Organization_ID_PV1_8_9 using 'ID/Organization' HDORG: firstSegments.PV1.8.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.8.9, ID: Organization_ID_PV1_8_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_8 using 'ID/Practitioner' XCN: firstSegments.PV1.8 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.8, ID: practitionerId_PV1_8 -%} + {% endif -%} + + {% if firstSegments.PV1.9 -%} + {% if firstSegments.PV1.9.9.1 != "" and firstSegments.PV1.9.9.1 != null and firstSegments.PV1.9.9.2 != "" and firstSegments.PV1.9.9.2 != null and firstSegments.PV1.9.9.3 != "" and firstSegments.PV1.9.9.3 != null -%} + {% evaluate Organization_ID_PV1_9_9 using 'ID/Organization' HDORG: firstSegments.PV1.9.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.9.9, ID: Organization_ID_PV1_9_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_9 using 'ID/Practitioner' XCN: firstSegments.PV1.9 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.9, ID: practitionerId_PV1_9 -%} + {% endif -%} + + {% if firstSegments.PV1.17 -%} + {% if firstSegments.PV1.17.9.1 != "" and firstSegments.PV1.17.9.1 != null and firstSegments.PV1.17.9.2 != "" and firstSegments.PV1.17.9.2 != null and firstSegments.PV1.17.9.3 != "" and firstSegments.PV1.17.9.3 != null -%} + {% evaluate Organization_ID_PV1_17_9 using 'ID/Organization' HDORG: firstSegments.PV1.17.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.17.9, ID: Organization_ID_PV1_17_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_17 using 'ID/Practitioner' XCN: firstSegments.PV1.17 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.17, ID: practitionerId_PV1_17 -%} + {% endif -%} + + {% if firstSegments.PV1.50 -%} + {% for p in firstSegments.PV1.50.Repeats -%} + {% if p.4.1 != "" and p.4.1 != null and p.4.2 != "" and p.4.2 != null and p.4.3 != "" and p.4.3 != null -%} + {% evaluate Organization_ID_PV1_50_4 using 'ID/Organization' HDORG: p.4 -%} + {% include 'Resource/Organization', PV1: p.4, ID: Organization_ID_PV1_50_4 -%} + {% endif -%} + {% endfor -%} + {% endif -%} + + {% if firstSegments.PV1.52 -%} + {% if firstSegments.PV1.52.9.1 != "" and firstSegments.PV1.52.9.1 != null and firstSegments.PV1.52.9.2 != "" and firstSegments.PV1.52.9.2 != null and firstSegments.PV1.52.9.3 != "" and firstSegments.PV1.52.9.3 != null -%} + {% evaluate Organization_ID_PV1_52_9 using 'ID/Organization' HDORG: firstSegments.PV1.52.9 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.52.9, ID: Organization_ID_PV1_52_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_52 using 'ID/Practitioner' XCN: firstSegments.PV1.52 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV1.52, ID: practitionerId_PV1_52 -%} + {% endif -%} + + {% if firstSegments.PV2.13 -%} + {% if firstSegments.PV2.13.9.1 != "" and firstSegments.PV2.13.9.1 != null and firstSegments.PV2.13.9.2 != "" and firstSegments.PV2.13.9.2 != null and firstSegments.PV2.13.9.3 != "" and firstSegments.PV2.13.9.3 != null -%} + {% evaluate Organization_ID_PV2_13_9 using 'ID/Organization' HDORG: firstSegments.PV2.13.9 -%} + {% include 'Resource/Organization', PV2: firstSegments.PV2.13.9, ID: Organization_ID_PV2_13_9 -%} + {% endif -%} + {% evaluate practitionerId_PV2_13 using 'ID/Practitioner' XCN: firstSegments.PV2.13 -%} + {% include 'Resource/Practitioner' PV1: firstSegments.PV2.13, ID: practitionerId_PV2_13 -%} + {% endif -%} + + {% if firstSegments.PV1.3 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.3-%} + {% endif -%} + + {% if firstSegments.PV1.6 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.6 -%} + {% endif -%} + + {% if firstSegments.PV1.37 -%} + {% evaluate location_ID_PV1_37 using 'ID/Location' DLD: firstSegments.PV1.37 -%} + {% include 'Resource/Location' PV1: firstSegments.PV1.37, ID: location_ID_PV1_37-%} + {% endif -%} + + {% if firstSegments.PV1.42 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.42-%} + {% endif -%} + + {% if firstSegments.PV1.43 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV1.43-%} + {% endif -%} + + {% if firstSegments.PV2.1 -%} + {% include 'Resource/PLLocation' PL: firstSegments.PV2.1-%} + {% endif -%} + + {% if firstSegments.PV1.54 -%} + {% if firstSegments.PV1.54.4.1 != "" and firstSegments.PV1.54.4.1 != null and firstSegments.PV1.54.4.2 != "" and firstSegments.PV1.54.4.2 != null and firstSegments.PV1.54.4.3 != "" and firstSegments.PV1.54.4.3 != null -%} + {% evaluate Organization_ID_PV1_54_4 using 'ID/Organization' HDORG: firstSegments.PV1.54.4 -%} + {% include 'Resource/Organization', PV1: firstSegments.PV1.54.4, ID: Organization_ID_PV1_54_4 -%} + {% endif -%} + {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: firstSegments.PV1.54 -%} + {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId -%} + {% endif -%} + + {% evaluate encounterId using 'ID/Encounter' PV1: firstSegments.PV1, baseId: patientId -%} + {% include 'Resource/Encounter' Root_Template: 'ORM_O01', PV1: firstSegments.PV1, PV2: firstSegments.PV2, ID: encounterId -%} + {% include 'Reference/Encounter/Subject' ID: encounterId, REF: fullPatientId -%} + {% include 'Extensions/Encounter/EncounterExtension' ID: encounterId, PV1: firstSegments.PV1, PV2: firstSegments.PV2, -%} + {% endif -%} + + {% for in1Segment in in1SegmentLists.IN1 -%} + {% assign in2SegmentLists = hl7v2Data | get_related_segment_list: in1Segment, 'IN2' -%} + {% evaluate coverageId using 'ID/Coverage' CX: in1Segment -%} + {% include 'Resource/Coverage' IN1: in1Segment, ID: coverageId -%} + {% include 'Reference/Coverage/Beneficiary' ID: coverageId, REF: fullPatientId -%} + + {% for in1_49 in in1Segment.49.Repeats -%} + {% if in1_49.4.1 != "" and in1_49.4.1 != null and in1_49.4.2 != "" and in1_49.4.2 != null and in1_49.4.3 != "" and in1_49.4.3 != null -%} + {% evaluate Organization_ID_in1_CX_49 using 'ID/Organization' HDORG: in1_49.4 -%} + {% include 'Resource/Organization', IN1_49: in1_49, ID: Organization_ID_in1_CX_49 -%} + {% endif -%} + {% endfor -%} + + {% for in1_3 in in1Segment.3.Repeats -%} + {% if in1_3.4.1 != "" and in1_3.4.1 != null and in1_3.4.2 != "" and in1_3.4.2 != null and in1_3.4.3 != "" and in1_3.4.3 != null -%} + {% evaluate Organization_ID_in1_CX_3 using 'ID/Organization' HDORG: in1_3.4 -%} + {% include 'Resource/Organization', IN1_3: in1_3, ID: Organization_ID_in1_CX_3 -%} + {% endif -%} + {% endfor -%} + + {% for in1_10 in in1Segment.10.Repeats -%} + {% if in1_10.4.1 != "" and in1_10.4.1 != null and in1_10.4.2 != "" and in1_10.4.2 != null and in1_10.4.3 != "" and in1_10.4.3 != null -%} + {% evaluate Organization_ID_in1_CX_10 using 'ID/Organization' HDORG: in1_10.4 -%} + {% include 'Resource/Organization', IN1_10: in1_10, ID: Organization_ID_in1_CX_10 -%} + {% endif -%} + {% endfor -%} + + {% if in1Segment.4 -%} + {% evaluate Organization_ID_in1_4 using 'ID/Organization' XON: in1Segment.4 -%} + {% else -%} + {% evaluate Organization_ID_in1_4 using 'ID/Organization' CX: in1Segment -%} + {% endif -%} + {% if Organization_ID_in1_4 -%} + {% include 'Resource/Organization', IN1: in1Segment, ID: Organization_ID_in1_4 -%} + {% assign org_in1_4 = Organization_ID_in1_4 | prepend: 'Organization/' -%} + {% include 'Reference/Coverage/Payor' ID: coverageId, REF: org_in1_4 -%} + {% endif -%} + + {% if in1Segment.11 -%} + {% evaluate Organization_ID_in1_11 using 'ID/Organization' XON: in1Segment.11 -%} + {% else -%} + {% evaluate Organization_ID_in1_11 using 'ID/Organization' CX_IN1: in1Segment -%} + {% endif -%} + {% if Organization_ID_in1_11 -%} + {% include 'Resource/Organization', IN1_11: in1Segment, ID: Organization_ID_in1_11 -%} + {% assign org_in1_11 = Organization_ID_in1_11 | prepend: 'Organization/' -%} + {% include 'Reference/Coverage/PolicyHolder' ID: coverageId, REF: org_in1_11 -%} + {% endif -%} + + {% if in1Segment.17.1.Value == "SEL" -%} + {% include 'Resource/Patient' PID_IN1: firstSegments.PID, IN1: in1Segment, ID: patientId -%} + {% include 'Reference/Coverage/Subscriber' ID: coverageId, REF: fullPatientId -%} + {% endif -%} + {% unless in1Segment.17.1.Value == "SEL" or in1Segment.17.Value == "" -%} + {% evaluate in1relatedPersonId using 'ID/RelatedPerson' IN1: in1Segment, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: in1relatedPersonId, IN1: in1Segment -%} + {% assign rel_in1_17 = in1relatedPersonId | prepend: 'RelatedPerson/' -%} + {% include 'Reference/Coverage/Subscriber' ID: coverageId, REF: rel_in1_17 -%} + {% endunless -%} + + {% for in2Segment in in2SegmentLists.IN2 -%} + {% if in1Segment.17.1.Value == "SEL" -%} + {% include 'Resource/Patient' IN2: in2Segment, ID: patientId -%} + {% endif -%} + {% unless in1Segment.17.1.Value == "SEL" or in1Segment.17.Value == "" -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: in1relatedPersonId, IN2: in2Segment -%} + {% endunless -%} + + {% unless in1Segment.10 and in1Segment.11 -%} + {% if in2Segment.3 -%} + {% evaluate in2relatedPersonId using 'ID/RelatedPerson' IN2: in2Segment, baseId: patientId -%} + {% if in2Segment.3.9.1 != "" and in2Segment.3.9.1 != null and in2Segment.3.9.2 != "" and in2Segment.3.9.2 != null and in2Segment.3.9.3 != "" and in2Segment.3.9.3 != null -%} + {% evaluate Organization_ID_IN2_3_9 using 'ID/Organization' HDORG: in2Segment.3.9 -%} + {% include 'Resource/Organization', IN2_3: in2Segment.3.9, ID: Organization_ID_IN2_3_9 -%} + {% endif -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: in2relatedPersonId, IN2_3: in2Segment -%} + {% assign relatedperson_3 = in2relatedPersonId | prepend: 'RelatedPerson/' -%} + {% include 'Reference/Coverage/PolicyHolder' ID: coverageId, REF: relatedperson_3 -%} + {% endif -%} + {% endunless -%} + + {% if in1Segment.10 == null and in1Segment.11 == null and in2Segment.3 == null -%} + {% if in2Segment.70 -%} + {% evaluate organization_Id_IN2_70 using 'ID/Organization' XON: in2Segment.70 -%} + {% include 'Resource/Organization' IN2_70: in2Segment, ID: organization_Id_IN2_70 -%} + {% assign org_in2_70 = organization_Id_IN2_70 | prepend: 'Organization/' -%} + {% include 'Reference/Coverage/PolicyHolder' ID: coverageId, REF: org_in2_70 -%} + {% endif -%} + {% endif -%} + + {% if Organization_ID_in1_11 -%} + {% include 'Resource/Organization', IN2_49: in2Segment, ID: Organization_ID_in1_11 -%} + {% endif -%} + {% include 'Resource/Coverage' IN2: in2Segment, ID: coverageId -%} + {% include 'Resource/Patient' IN2_6: in2Segment, ID: patientId -%} + + {% for in2_1 in in2Segment.1.Repeats -%} + {% if in2_1.4.1 != "" and in2_1.4.1 != null and in2_1.4.2 != "" and in2_1.4.2 != null and in2_1.4.3 != "" and in2_1.4.3 != null -%} + {% evaluate Organization_ID_in2_CX_1 using 'ID/Organization' HDORG: in2_1.4 -%} + {% include 'Resource/Organization', IN2_1: in2_1, ID: Organization_ID_in2_CX_1 -%} + {% endif -%} + {% endfor -%} + {% if in2Segment.61 -%} + {% if in2Segment.61.4.1 != "" and in2Segment.61.4.1 != null and in2Segment.61.4.2 != "" and in2Segment.61.4.2 != null and in2Segment.61.4.3 != "" and in2Segment.61.4.3 != null -%} + {% evaluate Organization_ID_in2_CX_61 using 'ID/Organization' HDORG: in2Segment.61.4 -%} + {% include 'Resource/Organization', IN2_61: in2Segment.61, ID: Organization_ID_in2_CX_61 -%} + {% endif -%} + {% endif -%} + {% endfor -%} + + {% endfor -%} + + {% for al1Segment in al1SegmentLists.AL1 -%} + {% evaluate allergyIntoleranceId using 'ID/AllergyIntolerance' AL1: al1Segment, baseId: patientId -%} + {% include 'Resource/AllergyIntolerance' AL1: al1Segment, ID: allergyIntoleranceId, AllergyIntolerance_Patient_ID: fullPatientId -%} + {% endfor -%} + + {% for orcSegment in orcSegmentLists.ORC -%} + + {% assign obrSegmentLists = hl7v2Data | get_related_segment_list: orcSegment, 'OBR' -%} + {% assign ctdSegmentLists = hl7v2Data | get_related_segment_list: orcSegment, 'CTD' -%} + {% assign dg1SegmentLists = hl7v2Data | get_related_segment_list: orcSegment, 'DG1' -%} + {% assign obxSegmentLists = hl7v2Data | get_related_segment_list: orcSegment, 'OBX' -%} + {% assign nteSegmentLists1 = hl7v2Data | get_related_segment_list: orcSegment, 'NTE' -%} + + {% assign obrSegment = obrSegmentLists.OBR[0] %} + {% assign checkParent = orcSegment %} + + {% evaluate parentServiceRequestId_orc using 'ID/ServiceRequest' ORC: checkParent.31, baseId: patientId -%} + {% if obrSegment.29.Value == null %} + {% if checkParent.8 and checkParent.31 %} + {% include 'Resource/ServiceRequest' OBR: obrSegment, ORC: checkParent, ID: parentServiceRequestId_orc, ServiceRequest_Subject_ID: fullPatientId, type_msg: "ORM" -%} + {% endif %} + {% endif %} + + {% evaluate serviceRequestId using 'ID/ServiceRequest' ORC: checkParent, baseId: patientId -%} + {% assign reasonRefrenceServiceRequestId = serviceRequestId -%} + {% evaluate specimenId_obr using 'ID/Specimen' OBR: obrSegment -%} + {% assign fullSpecimenId_obr = specimenId_obr | prepend: 'Specimen/' -%} + {% evaluate parentServiceRequestId using 'ID/ServiceRequest' OBR_29: obrSegment.29, baseId: patientId -%} + {% include 'Resource/ServiceRequest' OBR_child: obrSegment, parentSegment: checkParent, ServiceRequest_Subject_ID: fullPatientId, ServiceRequest_ID_OBR_29: parentServiceRequestId, ServiceRequest_ID_ORC_8: parentServiceRequestId_orc, ID: serviceRequestId, type_msg: "ORM" -%} + + {% evaluate practitionerId_ORC_12 using 'ID/Practitioner' XCN: checkParent.12.Repeats[0] -%} + {% if obrSegment.16 -%} + {% if obrSegment.16.Repeats[0] %} + {% if obrSegment.16.Repeats[0].9.1 != "" and obrSegment.16.Repeats[0].9.1 != null and obrSegment.16.Repeats[0].9.2 != "" and obrSegment.16.Repeats[0].9.2 != null and obrSegment.16.Repeats[0].9.3 != "" and obrSegment.16.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_OBR16 using 'ID/Organization' HDORG: obrSegment.16.Repeats[0].9 -%} + {% include 'Resource/Organization' OBR_SEG_16: obrSegment.16.Repeats[0].9, ID: Organization_ID_OBR16 -%} + {% endif -%} + {% endif -%} + {% evaluate practitionerId_OBR_16 using 'ID/Practitioner' XCN: obrSegment.16.Repeats[0] -%} + {% include 'Resource/Practitioner' OBR_SEG: obrSegment, OBRXCN_16: obrSegment.16.Repeats[0], ORC_SEG_24: checkParent.24, ID: practitionerId_OBR_16 -%} + {% evaluate practitionerRoleId_OBR_16 using 'ID/PractitionerRole' XCN: obrSegment.16.Repeats[0]-%} + {% include 'Resource/PractitionerRole' OBR: obrSegment, requestor_practitioner1: practitionerId_OBR_16, ID: practitionerRoleId_OBR_16 -%} + {% assign fullpractitionerRoleId_OBR_16 = practitionerRoleId_OBR_16 | prepend: 'PractitionerRole/' -%} + {% include 'Reference/ServiceRequest/Requester' REF: fullpractitionerRoleId_OBR_16, ID: serviceRequestId -%} + {% else %} + {% if checkParent.12 %} + {% if checkParent.12.Repeats[0].9.1 != "" and checkParent.12.Repeats[0].9.1 != null and checkParent.12.Repeats[0].9.2 != "" and checkParent.12.Repeats[0].9.2 != null and checkParent.12.Repeats[0].9.3 != "" and checkParent.12.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_ORC_12 using 'ID/Organization' HDORG: checkParent.12.Repeats[0].9 -%} + {% include 'Resource/Organization' ORC_SEG_12: checkParent.12.Repeats[0].9, ID: Organization_ID_ORC_12 -%} + {% endif -%} + {% include 'Resource/Practitioner' ORC_SEG: checkParent, ORCXCN_12: checkParent.12.Repeats[0], ORC_SEG_24: checkParent.24, ID: practitionerId_ORC_12 -%} + {% evaluate practitionerRoleId_ORC_12 using 'ID/PractitionerRole' XCN: checkParent.12.Repeats[0]-%} + {% include 'Resource/PractitionerRole' ORC: checkParent, requestor_practitioner2: practitionerId_ORC_12, ID: practitionerRoleId_ORC_12 -%} + {% assign fullPractitionerRoleId_ORC_12 = practitionerRoleId_ORC_12 | prepend: 'PractitionerRole/' -%} + {% include 'Reference/ServiceRequest/Requester' REF: fullPractitionerRoleId_ORC_12, ID: serviceRequestId -%} + {% else %} + {% if checkParent.21 %} + {% evaluate organizationId_ORC_21 using 'ID/Organization' XON: checkParent.21.Repeats[0] -%} + {% if checkParent.12.Repeats[0] == null or checkParent.12.Repeats[0] == "" and obrSegment.16 == null or obrSegment.16 == "" %} + {% include 'Resource/Organization' ORC_SEG: checkParent, ORC_SEG_22: checkParent.22, ORC_SEG_23: checkParent.23, ID: organizationId_ORC_21 -%} + {% endif %} + {% evaluate practitionerRoleId_ORC_21 using 'ID/PractitionerRole' XCN: checkParent.21.Repeats[0]-%} + {% include 'Resource/PractitionerRole' ORC: checkParent, requestor_organization: organizationId_ORC_21, ID: practitionerRoleId_ORC_21 -%} + {% assign fullPractitionerRoleId_ORC_21 = practitionerRoleId_ORC_21 | prepend: 'PractitionerRole/' -%} + {% include 'Reference/ServiceRequest/Requester' REF: fullPractitionerRoleId_ORC_21, ID: serviceRequestId -%} + {% endif %} + {% endif -%} + {% endif %} + + {% include 'Reference/ServiceRequest/Specimen' REF: fullSpecimenId_obr, ID: serviceRequestId -%} + + {% if obrSegment.29 %} + {% if obrSegment.50 -%} + {% evaluate parentServiceRequestId using 'ID/ServiceRequest' OBR_29: obrSegment.29, baseId: patientId -%} + {% include 'Resource/ServiceRequest' OBR_parent: obrSegment, parentSegment: checkParent, ServiceRequest_Subject_ID: fullPatientId, ID: parentServiceRequestId, type_msg: "ORM" -%} + {% endif %} + {% endif %} + + {% assign fullParentServiceRequestId = parentServiceRequestId | prepend: 'ServiceRequest/' -%} + + {% for nteSegment1 in nteSegmentLists1.NTE -%} + {% if nteSegment1.5 -%} + {% if nteSegment1.5.9.1 != "" and nteSegment1.5.9.1 != null and nteSegment1.5.9.2 != "" and nteSegment1.5.9.2 != null and nteSegment1.5.9.3 != "" and nteSegment1.5.9.3 != null -%} + {% evaluate Organization_ID_NTE1_5_9 using 'ID/Organization' HDORG: nteSegment1.5.9 -%} + {% include 'Resource/Organization' OBR_NTE: nteSegment1.5.9, ID: Organization_ID_NTE1_5_9 -%} + {% endif -%} + {% evaluate practitioner_ID_NTE_5 using 'ID/Practitioner' XCN: nteSegment1.5 -%} + {% include 'Resource/Practitioner' NTE: nteSegment1.5, ID: practitioner_ID_NTE_5 -%} + {% endif -%} + {% include 'Resource/ServiceRequest' NTE: nteSegment1, ID: serviceRequestId -%} + {% endfor -%} + + {% if obrSegment %} + {% include 'Resource/Specimen' OBR: obrSegment, ID: specimenId_obr -%} + {% endif %} + + {% if obrSegment.10 %} + {% if obrSegment.10.Repeats[0].9.1 != "" and obrSegment.10.Repeats[0].9.1 != null and obrSegment.10.Repeats[0].9.2 != "" and obrSegment.10.Repeats[0].9.2 != null and obrSegment.10.Repeats[0].9.3 != "" and obrSegment.10.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_OBR10 using 'ID/Organization' HDORG: obrSegment.10.Repeats[0].9 -%} + {% include 'Resource/Organization' OBR_SEG_10: obrSegment.10.Repeats[0].9, ID: Organization_ID_OBR10 -%} + {% endif -%} + {% evaluate practitionerId_OBR_10 using 'ID/Practitioner' XCN: obrSegment.10.Repeats[0] -%} + {% include 'Resource/Practitioner' OBR_SEG: obrSegment, OBRXCN_10: obrSegment.10.Repeats[0], ID: practitionerId_OBR_10 -%} + {% evaluate practitionerRoleId_OBR_10 using 'ID/PractitionerRole' XCN: obrSegment.10.Repeats[0] -%} + {% assign full_practitionerId_obr_10 = practitionerRoleId_OBR_10 | prepend: 'PractitionerRole/' %} + {% include 'Resource/PractitionerRole' OBR: obrSegment, collection_collector_practitioner: practitionerId_obr_10, ID: practitionerRoleId_OBR_10 -%} + {% include 'Reference/Specimen/Collection_Collector' REF: full_practitionerId_obr_10, ID: specimenId_obr -%} + {% endif -%} + + {% for ctdSegment in ctdSegmentLists.CTD -%} + {% include 'Resource/Patient' CTD: ctdSegment, ID: patientId -%} + {% endfor -%} + + {% for dg1Segment in dg1SegmentLists.DG1 -%} + {% if dg1Segment.16.Repeats[0] %} + {% if dg1Segment.16.Repeats[0].9.1 != "" and dg1Segment.16.Repeats[0].9.1 != null and dg1Segment.16.Repeats[0].9.2 != "" and dg1Segment.16.Repeats[0].9.2 != null and dg1Segment.16.Repeats[0].9.3 != "" and dg1Segment.16.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_DG1_16 using 'ID/Organization' HDORG: dg1Segment.16.Repeats[0].9 -%} + {% include 'Resource/Organization', DG1: dg1Segment.16.Repeats[0].9, ID: Organization_ID_DG1_16 -%} + {% endif -%} + {% evaluate practitionerId_DG1_16 using 'ID/Practitioner' XCN: dg1Segment.16.Repeats[0] -%} + {% include 'Resource/Practitioner' DG1: dg1Segment, ID: practitionerId_DG1_16 -%} + {% endif -%} + + {% evaluate conditionId using 'ID/Condition' DG1: dg1Segment, baseId: patientId -%} + {% include 'Resource/Condition' DG1: dg1Segment, Condition_Subject_ID: fullPatientId, baseId: patientId, ID: conditionId -%} + {% assign fullConditionId = conditionId | prepend: 'Condition/' -%} + {% include 'Reference/ServiceRequest/ReasonReference' REF: fullConditionId, ID: serviceRequestId -%} + + {% if encounterId -%} + {% include 'Resource/Encounter' DG1: dg1Segment, conditionId: conditionId, ID: encounterId -%} + {% endif %} + {% if EpisodeOfCare_ID %} + {% include 'Resource/EpisodeOfCare' DG1: dg1Segment, conditionId: conditionId, ID: EpisodeOfCare_ID -%} + {% endif %} + {% if dg1Segment.22 -%} + {% evaluate conditionId_DG1_22 using 'ID/Condition' DG1: dg1Segment.22, baseId: patientId -%} + {% include 'Resource/Condition' DG1_22: dg1Segment.22, Condition_Subject_ID_DG1_22: fullPatientId, ID: conditionId_DG1_22 -%} + {% endif -%} + {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} + + {% endfor -%} + + {% for obxSegment in obxSegmentLists.OBX -%} + {% if obxSegment.2.Value == 'ED' or obxSegment.2.Value == 'RP' %} + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16 -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16 -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23 -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + {% evaluate obx_diagnosticReportID using 'ID/DiagnosticReport' OBX: obxSegment -%} + {% include 'Resource/DiagnosticReport' OBX: obxSegment, DiagnosticReport_ServiceRequest_ID: serviceRequestId, ID: obx_diagnosticReportID, DiagnosticReport_Subject_ID: fullPatientId-%} + {% else %} + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16 -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16 -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + {% if obxSegment.18 -%} + {% evaluate deviceId_OBX_18 using 'ID/Device' EI: obxSegment.18.Repeats[0] -%} + {% include 'Resource/Device' EI_OBX18: obxSegment.18, ID: deviceId_OBX_18 -%} + {% endif -%} + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23 -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + {% evaluate observationId using 'ID/Observation' OBX: obxSegment, baseId: patientId -%} + {% include 'Resource/Observation' OBX: obxSegment, Observation_Subject_ID: fullPatientId, Observation_ServiceRequest_ID : serviceRequestId, ID: observationId -%} + {% include 'Extensions/Observation/ObservationExtension' OBX: obxSegment, ID: observationId %} + {% assign nteSegmentLists2 = hl7v2Data | get_related_segment_list: obxSegment, 'NTE' -%} + {% for nteSegment2 in nteSegmentLists2.NTE -%} + {% if nteSegment2.5 -%} + {% if nteSegment2.5.9.1 != "" and nteSegment2.5.9.1 != null and nteSegment2.5.9.2 != "" and nteSegment2.5.9.2 != null and nteSegment2.5.9.3 != "" and nteSegment2.5.9.3 != null -%} + {% evaluate Organization_ID_NTE2_5_9 using 'ID/Organization' HDORG: nteSegment2.5.9 -%} + {% include 'Resource/Organization' OBX_NTE: nteSegment2.5.9, ID: Organization_ID_NTE2_5_9 -%} + {% endif -%} + {% evaluate practitioner_ID_NTE_5 using 'ID/Practitioner' XCN: nteSegment2.5 -%} + {% include 'Resource/Practitioner' NTE: nteSegment2.5, ID: practitioner_ID_NTE_5 -%} + {% endif -%} + {% include 'Resource/Observation' NTE: nteSegment2, ID: observationId -%} + {% endfor -%} + {% endif -%} + {% endfor -%} + {% endfor -%} + ] +} \ No newline at end of file diff --git a/data/Templates/Hl7v2/ORU_R01.liquid b/data/Templates/Hl7v2/ORU_R01.liquid index 9ce2dbed1..ff5084f8f 100644 --- a/data/Templates/Hl7v2/ORU_R01.liquid +++ b/data/Templates/Hl7v2/ORU_R01.liquid @@ -1,25 +1,77 @@ -{% assign firstSegments = hl7v2Data | get_first_segments: 'PID|PD1|NK1|PV1|PV2|MSH' -%} -{% assign nk1SegmentLists = hl7v2Data | get_segment_lists: 'NK1' -%} +{% assign firstSegments = hl7v2Data | get_first_segments: 'MSH|UAC|ORC' -%} +{% assign sftSegmentLists = hl7v2Data | get_segment_lists: 'SFT' -%} +{% assign pidSegmentLists = hl7v2Data | get_segment_lists: 'PID' -%} {% assign obrSegmentLists = hl7v2Data | get_segment_lists: 'OBR' -%} - +{% assign ctdSegmentLists = hl7v2Data | get_segment_lists: 'CTD' -%} +{% assign txaSegmentLists = hl7v2Data | get_segment_lists: 'TXA' -%} +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} { "resourceType": "Bundle", "type": "batch", {% if firstSegments.MSH.7 -%} - "timestamp":"{{ firstSegments.MSH.7.Value | format_as_date_time }}", + "timestamp":"{{ firstSegments.MSH.7.Value | format_as_date_time }}", {% endif -%} "identifier": { "value":"{{ firstSegments.MSH.10.Value }}", }, + "id":"{{ bundleID }}", "entry": [ - {% evaluate messageHeaderId using 'ID/MessageHeader' MSH: firstSegments.MSH -%} - {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, ID: messageHeaderID -%} - {% evaluate patientId using 'ID/Patient' PID: firstSegments.PID, type: 'First' -%} + {% evaluate patientId using 'ID/Patient' PID: pidSegmentLists.PID[0], type: 'First' -%} {% assign fullPatientId = patientId | prepend: 'Patient/' -%} - {% include 'Resource/Patient' PID: firstSegments.PID, PD1: firstSegments.PD1, ID: patientId -%} - {% include 'Extensions/Patient/PatientExtension' ID: PatientId, PID: firstSegments.PID, PV1: firstSegments.PV1 -%} + {% evaluate messageHeaderId using 'ID/MessageHeader' MSH: firstSegments.MSH -%} + + {% if firstSegments.MSH -%} + + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, ID: messageHeaderId -%} + {% evaluate provenanceId using 'ID/Provenance' MSH: firstSegments.MSH, baseId: patientId -%} + {% include 'Resource/Provenance' Root_Template: 'ORU_R01', MSH: firstSegments.MSH, REF_BUNDLE: bundleID, ID: provenanceId -%} + + {%- comment -%} + {% assign transformation_val = 'provenance_transformation' %} + {% evaluate provenanceOrganizationId using 'ID/Organization', prov_id: firstSegments.MSH -%} + {% evaluate provenanceTransformationId using 'ID/Provenance_transformation' prov_id: transformation_val -%} + {% include 'Resource/Organization' org_name: 'Microsoft Corporation', ID: provenanceOrganizationId -%} + {% include 'Resource/Provenance_transformation' Root_Template: 'ADT_A01', Provenance_Organization_ID: provenanceOrganizationId, REF_MSH: messageHeaderId, provenanceOrganizationId, ID: provenanceTransformationId -%} + {%- endcomment -%} + + {% if firstSegments.MSH.4 -%} + {% if firstSegments.MSH.4.1 != "" and firstSegments.MSH.4.1 != null or firstSegments.MSH.4.2 != "" and firstSegments.MSH.4.2 != null or firstSegments.MSH.4.3 != "" and firstSegments.MSH.4.3 != null -%} + {% evaluate organization_ID_MSH_4 using 'ID/Organization' HD: firstSegments.MSH.4 -%} + {% include 'Resource/Organization' MSHHD1: firstSegments.MSH.4, MSH: firstSegments.MSH, ID: organization_ID_MSH_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.6 %} + {% if firstSegments.MSH.6.1 != "" and firstSegments.MSH.6.1 != null or firstSegments.MSH.6.2 != "" and firstSegments.MSH.6.2 != null or firstSegments.MSH.6.3 != "" and firstSegments.MSH.6.3 != null -%} + {% evaluate organization_Id_MSH_6 using 'ID/Organization' HD: firstSegments.MSH.6 -%} + {% include 'Resource/Organization' MSHHD2: firstSegments.MSH.6, MSH: firstSegments.MSH, ID: organization_Id_MSH_6 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.22 %} + {% if firstSegments.MSH.22.1 != "" and firstSegments.MSH.22.1 != null -%} + {% evaluate organization_Id_MSH_22 using 'ID/Organization' XON: firstSegments.MSH.22 -%} + {% include 'Resource/Organization' MSHXON1: firstSegments.MSH.22, ID: organization_Id_MSH_22 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.23 %} + {% if firstSegments.MSH.23.1 != "" and firstSegments.MSH.23.1 != null -%} + {% evaluate organization_Id_MSH_23 using 'ID/Organization' XON: firstSegments.MSH.23 -%} + {% include 'Resource/Organization' MSHXON2: firstSegments.MSH.23, ID: organization_Id_MSH_23 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.3 and firstSegments.MSH.24 %} + {% evaluate device_Id_MSH_3 using 'ID/Device' HD: firstSegments.MSH.3 -%} + {% include 'Resource/Device' MSH: firstSegments.MSH, ID: device_Id_MSH_3 -%} + {% endif -%} + + {% endif -%} + {%- comment -%} + {% evaluate provenanceId using 'ID/Provenance' MSH: firstSegments.MSH, baseId: patientId -%} + {% include 'Resource/Provenance' Root_Template: 'ORU_R01', MSH: firstSegments.MSH, ORC: firstSegments.ORC, ID: provenanceId -%} {% evaluate practitionerId10_ORC_10 using 'ID/Practitioner' XCN: firstSegments.ORC.10 -%} {% evaluate practitionerId10_ORC_11 using 'ID/Practitioner' XCN: firstSegments.ORC.11 -%} @@ -29,207 +81,732 @@ {% include 'Resource/Practitioner' ORC: firstSegments.ORC, ID: practitionerId10_ORC_11 -%} {% include 'Resource/Practitioner' ORC: firstSegments.ORC, ID: practitionerId10_ORC_12 -%} - {% if firstSegments.PV1.5 -%} - {% if firstSegments.PV1.5.4.1 != "" and firstSegments.PV1.5.4.1 != null and firstSegments.PV1.5.4.2 != "" and firstSegments.PV1.5.4.2 != null and firstSegments.PV1.5.4.3 != "" and firstSegments.PV1.5.4.3 != null -%} - {% evaluate Organization_ID_PV1_5_4 using 'ID/Organization' HDORG: firstSegments.PV1.5.4 -%} - {% include 'Resource/Organization', PV1: firstSegments.PV1.5.4, ID: Organization_ID_PV1_5_4 -%} + {% evaluate locationId_ORC_21 using 'ID/Location' XON: firstSegments.ORC.21 -%} + {% include 'Resource/Location' ORC: firstSegments.ORC, ID: locationId_ORC_21 -%} +{%- endcomment -%} + {% for sftSegment in sftSegmentLists.SFT -%} + {% evaluate deviceId_SFT using 'ID/Device' SFT: sftSegment -%} + {% include 'Resource/Device' SFT:sftSegment, ID: deviceId_SFT -%} + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, SFT:sftSegment, ID: messageHeaderID -%} + {% endfor -%} + + {% for pidSegment in pidSegmentLists.PID -%} + + {% evaluate patientId using 'ID/Patient' PID: pidSegment, type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + + {% assign pd1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PD1' -%} + {% assign pd1Segment = pd1SegmentLists.PD1[0] %} + {% assign nk1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'NK1' -%} + {% assign pv1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PV1' -%} + {% assign pv1Segment = pv1SegmentLists.PV1[0] %} + {% assign pv2SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PV2' -%} + {% assign pv2Segment = pv2SegmentLists.PV2[0] %} + {% assign obxSegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'OBX' -%} + {% assign ctdSegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'CTD' -%} + + {% include 'Resource/Patient' PID: pidSegment, PD1: pd1Segment, ID: patientId -%} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, PID: pidSegment, PD1: pd1Segment, PV1: pv1Segment -%} + + {% for ctdSegment in ctdSegmentLists.CTD -%} + {% include 'Resource/Patient' CTD: ctdSegment, ID: patientId -%} + {% endfor -%} + + {% if pidSegment.18 -%} + {% evaluate accountId using 'ID/Account' CX: pidSegment.3 -%} + {% include 'Resource/Account' PID: pidSegment, ID: accountId -%} + {% include 'Reference/Account/Subject' ID: accountId, REF: fullPatientId -%} + {% if pidSegment.18.4.1 != "" and pidSegment.18.4.1 != null and pidSegment.18.4.2 != "" and pidSegment.18.4.2 != null and pidSegment.18.4.3 != "" and pidSegment.18.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_18 using 'ID/Organization' HDORG: pidSegment.18.4 -%} + {% include 'Resource/Organization', PID: pidSegment.18, ID: Organization_ID_pid_CX_18 -%} + {% endif -%} {% endif -%} - {% endif -%} - {% if firstSegments.PV1.19 -%} - {% if firstSegments.PV1.19.4.1 != "" and firstSegments.PV1.19.4.1 != null and firstSegments.PV1.19.4.2 != "" and firstSegments.PV1.19.4.2 != null and firstSegments.PV1.19.4.3 != "" and firstSegments.PV1.19.4.3 != null -%} - {% evaluate Organization_ID_PV1_19_4 using 'ID/Organization' HDORG: firstSegments.PV1.19.4 -%} - {% include 'Resource/Organization', PV1: firstSegments.PV1.19.4, ID: Organization_ID_PV1_19_4 -%} + {% if pidSegment.2 -%} + {% if pidSegment.2.4.1 != "" and pidSegment.2.4.1 != null and pidSegment.2.4.2 != "" and pidSegment.2.4.2 != null and pidSegment.2.4.3 != "" and pidSegment.2.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_2 using 'ID/Organization' HDORG: pidSegment.2.4 -%} + {% include 'Resource/Organization', PID: pidSegment.2, ID: Organization_ID_pid_CX_2 -%} + {% endif -%} {% endif -%} - {% endif -%} + {% for pid3 in pidSegment.3.Repeats -%} + {% if pid3.4.1 != "" and pid3.4.1 != null and pid3.4.2 != "" and pid3.4.2 != null and pid3.4.3 != "" and pid3.4.3 != null -%} + {% evaluate Organization_ID_pid_CX using 'ID/Organization' HDORG: pid3.4 -%} + {% include 'Resource/Organization', PID: pid3, ID: Organization_ID_pid_CX -%} + {% endif -%} + {% endfor -%} + {% if pidSegment.4 -%} + {% if pidSegment.4.4.1 != "" and pidSegment.4.4.1 != null and pidSegment.4.4.2 != "" and pidSegment.4.4.2 != null and pidSegment.4.4.3 != "" and pidSegment.4.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_4 using 'ID/Organization' HDORG: pidSegment.4.4 -%} + {% include 'Resource/Organization', PID: pidSegment.4, ID: Organization_ID_pid_CX_4 -%} + {% endif -%} + {% endif -%} + + {% unless nk1SegmentLists.NK1 -%} + {% if pidSegment.21 -%} + {% if pidSegment.21.4.1 != "" and pidSegment.21.4.1 != null and pidSegment.21.4.2 != "" and pidSegment.21.4.2 != null and pidSegment.21.4.3 != "" and pidSegment.21.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_21 using 'ID/Organization' HDORG: pidSegment.21.4 -%} + {% include 'Resource/Organization', PID: pidSegment.21, ID: Organization_ID_pid_CX_21 -%} + {% endif -%} + {% evaluate pidrelatedPersonId using 'ID/RelatedPerson' PID: pidSegment, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: pidrelatedPersonId, PID: pidSegment -%} + {% endif -%} + {% endunless -%} - {% if firstSegments.PV1.7 -%} - {% if firstSegments.PV1.7.9.1 != "" and firstSegments.PV1.7.9.1 != null and firstSegments.PV1.7.9.2 != "" and firstSegments.PV1.7.9.2 != null and firstSegments.PV1.7.9.3 != "" and firstSegments.PV1.7.9.3 != null -%} - {% evaluate Organization_ID_PV1_7_9 using 'ID/Organization' HDORG: firstSegments.PV1.7.9 -%} - {% include 'Resource/Organization', PV1: firstSegments.PV1.7.9, ID: Organization_ID_PV1_7_9 -%} + {% if pd1Segment.3 -%} + {% evaluate Organization_ID_PD1_3 using 'ID/Organization' XON: pd1Segment.3 -%} + {% include 'Resource/Organization' PD1: pd1Segment, ID: Organization_ID_PD1_3 -%} {% endif -%} - {% evaluate practitionerId_PV1_7 using 'ID/Practitioner' XCN: firstSegments.PV1.7 -%} - {% include 'Resource/Practitioner' PV1: firstSegments.PV1.7, ID: practitionerId_PV1_7 -%} - {% endif -%} - {% if firstSegments.PV1.8 -%} - {% if firstSegments.PV1.8.9.1 != "" and firstSegments.PV1.8.9.1 != null and firstSegments.PV1.8.9.2 != "" and firstSegments.PV1.8.9.2 != null and firstSegments.PV1.8.9.3 != "" and firstSegments.PV1.8.9.3 != null -%} - {% evaluate Organization_ID_PV1_8_9 using 'ID/Organization' HDORG: firstSegments.PV1.8.9 -%} - {% include 'Resource/Organization', PV1: firstSegments.PV1.8.9, ID: Organization_ID_PV1_8_9 -%} + {% if pd1Segment.4 -%} + {% if pd1Segment.4.9.1 != "" and pd1Segment.4.9.1 != null and pd1Segment.4.9.2 != "" and pd1Segment.4.9.2 != null and pd1Segment.4.9.3 != "" and pd1Segment.4.9.3 != null -%} + {% evaluate Organization_ID_PD1_4_9 using 'ID/Organization' HDORG: pd1Segment.4.9 -%} + {% include 'Resource/Organization', PD1_4: pd1Segment.4.9, ID: Organization_ID_PD1_4_9 -%} + {% endif -%} + {% evaluate Practitioner_ID_PD1_4 using 'ID/Practitioner' XCN: pd1Segment.4 -%} + {% include 'Resource/Practitioner' PD1: pd1Segment.4, ID: Practitioner_ID_PD1_4 -%} {% endif -%} - {% evaluate practitionerId_PV1_8 using 'ID/Practitioner' XCN: firstSegments.PV1.8 -%} - {% include 'Resource/Practitioner' PV1: firstSegments.PV1.8, ID: practitionerId_PV1_8 -%} - {% endif -%} - {% if firstSegments.PV1.9 -%} - {% if firstSegments.PV1.9.9.1 != "" and firstSegments.PV1.9.9.1 != null and firstSegments.PV1.9.9.2 != "" and firstSegments.PV1.9.9.2 != null and firstSegments.PV1.9.9.3 != "" and firstSegments.PV1.9.9.3 != null -%} - {% evaluate Organization_ID_PV1_9_9 using 'ID/Organization' HDORG: firstSegments.PV1.9.9 -%} - {% include 'Resource/Organization', PV1: firstSegments.PV1.9.9, ID: Organization_ID_PV1_9_9 -%} - {% endif -%} - {% evaluate practitionerId_PV1_9 using 'ID/Practitioner' XCN: firstSegments.PV1.9 -%} - {% include 'Resource/Practitioner' PV1: firstSegments.PV1.9, ID: practitionerId_PV1_9 -%} - {% endif -%} + {% for nk1Segment in nk1SegmentLists.NK1 -%} + {% evaluate relatedPersonId using 'ID/RelatedPerson' NK1: nk1Segment, baseId: patientId -%} + {% if nk1Segment.13 -%} + {% evaluate organizationId_NK1_13 using 'ID/Organization' XON: nk1Segment.13 -%} + {% include 'Resource/Organization' NK1: nk1Segment, ID: organizationId_NK1_13 -%} + {% assign Organization_NK1_13 = organizationId_NK1_13 | prepend: 'Organization/' -%} + {% include 'Reference/Patient/Contact_Organization' REF:Organization_NK1_13 , ID: patientId -%} + {% endif -%} + {% unless nk1Segment.3.1.Value == "EMR" or nk1Segment.3.1.Value == "CGV" or nk1Segment.7.1.Value == "E" or nk1Segment.7.1.Value =="F" or nk1Segment.7.1.Value == "I" or nk1Segment.7.1.Value =="S" -%} + {% include 'Resource/Patient' NK1: nk1Segment, ID: patientId -%} + {% include 'Resource/RelatedPerson' NK1: nk1Segment, RelatedPerson_Patient_ID: fullPatientId, ID: relatedPersonId, PID: firstSegments.PID -%} + {% include 'Extensions/RelatedPerson/RelatedPerson' ID: relatedPersonId, NK1: nk1Segment -%} + {% if nk1Segment.12.4.1 != "" and nk1Segment.12.4.1 != null and nk1Segment.12.4.2 != "" and nk1Segment.12.4.2 != null and nk1Segment.12.4.3 != "" and nk1Segment.12.4.3 != null -%} + {% evaluate Organization_ID_nk_CX_12 using 'ID/Organization' HDORG: nk1Segment.12.4 -%} + {% include 'Resource/Organization', NK1_12: nk1Segment.12, ID: Organization_ID_nk_CX_12 -%} + {% endif -%} + {% endunless -%} + {% if firstSegments.PID.21 -%} + {% include 'Resource/RelatedPerson' ID: relatedPersonId, PID: firstSegments.PID, RelatedPerson_Patient_ID: fullPatientId -%} + {% if firstSegments.PID.21.4.1 != "" and firstSegments.PID.21.4.1 != null and firstSegments.PID.21.4.2 != "" and firstSegments.PID.21.4.2 != null and firstSegments.PID.21.4.3 != "" and firstSegments.PID.21.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_21 using 'ID/Organization' HDORG: firstSegments.PID.21.4 -%} + {% include 'Resource/Organization', PID: firstSegments.PID.21, ID: Organization_ID_pid_CX_21 -%} + {% endif -%} + {% endif -%} - {% if firstSegments.PV1.17 -%} - {% if firstSegments.PV1.17.9.1 != "" and firstSegments.PV1.17.9.1 != null and firstSegments.PV1.17.9.2 != "" and firstSegments.PV1.17.9.2 != null and firstSegments.PV1.17.9.3 != "" and firstSegments.PV1.17.9.3 != null -%} - {% evaluate Organization_ID_PV1_17_9 using 'ID/Organization' HDORG: firstSegments.PV1.17.9 -%} - {% include 'Resource/Organization', PV1: firstSegments.PV1.17.9, ID: Organization_ID_PV1_17_9 -%} - {% endif -%} - {% evaluate practitionerId_PV1_17 using 'ID/Practitioner' XCN: firstSegments.PV1.17 -%} - {% include 'Resource/Practitioner' PV1: firstSegments.PV1.17, ID: practitionerId_PV1_17 -%} - {% endif -%} + {% for nk33 in nk1Segment.33.Repeats -%} + {% if nk33.4.1 != "" and nk33.4.1 != null and nk33.4.2 != "" and nk33.4.2 != null and nk33.4.3 != "" and nk33.4.3 != null -%} + {% evaluate Organization_ID_nk_CX_33 using 'ID/Organization' HDORG: nk33.4 -%} + {% include 'Resource/Organization', NK1_33: nk33, ID: Organization_ID_nk_CX_33 -%} + {% endif -%} + {% endfor -%} + {% endfor -%} - {% if firstSegments.PV1.50 -%} - {% for p in firstSegments.PV1.50.Repeats -%} - {% if p.4.1 != "" and p.4.1 != null and p.4.2 != "" and p.4.2 != null and p.4.3 != "" and p.4.3 != null -%} - {% evaluate Organization_ID_PV1_50_4 using 'ID/Organization' HDORG: p.4 -%} - {% include 'Resource/Organization', PV1: p.4, ID: Organization_ID_PV1_50_4 -%} - {% endif -%} + {% for obxSegment in obxSegmentLists.OBX -%} + {% if obxSegment.2.Value == 'ED' or obxSegment.2.Value == 'RP' %} + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16 -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16 -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23 -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + {% evaluate obx_diagnosticReportID1 using 'ID/DiagnosticReport' OBX: obxSegment -%} + {% include 'Resource/DiagnosticReport' OBX: obxSegment, ID: obx_diagnosticReportID1, DiagnosticReport_Subject_ID: fullPatientId -%} + {% else %} + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16 -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16 -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + {% if obxSegment.18 -%} + {% evaluate deviceId_OBX_18 using 'ID/Device' EI: obxSegment.18.Repeats[0] -%} + {% include 'Resource/Device' EI_OBX18: obxSegment.18, ID: deviceId_OBX_18 -%} + {% endif -%} + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23 -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + {% evaluate observationId using 'ID/Observation' OBX: obxSegment, baseId: patientId -%} + {% include 'Resource/Observation' OBX: obxSegment, Observation_Subject_ID: fullPatientId, ID: observationId -%} + {% include 'Extensions/Observation/ObservationExtension' OBX: obxSegment, ID: observationId %} + {% endif %} {% endfor -%} - {% endif -%} - {% if firstSegments.PV1.52 -%} - {% if firstSegments.PV1.52.9.1 != "" and firstSegments.PV1.52.9.1 != null and firstSegments.PV1.52.9.2 != "" and firstSegments.PV1.52.9.2 != null and firstSegments.PV1.52.9.3 != "" and firstSegments.PV1.52.9.3 != null -%} - {% evaluate Organization_ID_PV1_52_9 using 'ID/Organization' HDORG: firstSegments.PV1.52.9 -%} - {% include 'Resource/Organization', PV1: firstSegments.PV1.52.9, ID: Organization_ID_PV1_52_9 -%} - {% endif -%} - {% evaluate practitionerId_PV1_52 using 'ID/Practitioner' XCN: firstSegments.PV1.52 -%} - {% include 'Resource/Practitioner' PV1: firstSegments.PV1.52, ID: practitionerId_PV1_52 -%} - {% endif -%} + {% if pv1Segment -%} + {% if pv1Segment.5 -%} + {% if pv1Segment.5.4.1 != "" and pv1Segment.5.4.1 != null and pv1Segment.5.4.2 != "" and pv1Segment.5.4.2 != null and pv1Segment.5.4.3 != "" and pv1Segment.5.4.3 != null -%} + {% evaluate Organization_ID_PV1_5_4 using 'ID/Organization' HDORG: pv1Segment.5.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.5.4, ID: Organization_ID_PV1_5_4 -%} + {% endif -%} + {% endif -%} - {% if firstSegments.PV2.13 -%} - {% if firstSegments.PV2.13.9.1 != "" and firstSegments.PV2.13.9.1 != null and firstSegments.PV2.13.9.2 != "" and firstSegments.PV2.13.9.2 != null and firstSegments.PV2.13.9.3 != "" and firstSegments.PV2.13.9.3 != null -%} - {% evaluate Organization_ID_PV2_13_9 using 'ID/Organization' HDORG: firstSegments.PV2.13.9 -%} - {% include 'Resource/Organization', PV2: firstSegments.PV2.13.9, ID: Organization_ID_PV2_13_9 -%} - {% endif -%} - {% evaluate practitionerId_PV2_13 using 'ID/Practitioner' XCN: firstSegments.PV2.13 -%} - {% include 'Resource/Practitioner' PV1: firstSegments.PV2.13, ID: practitionerId_PV2_13 -%} - {% endif -%} + {% if pv1Segment.19 -%} + {% if pv1Segment.19.4.1 != "" and pv1Segment.19.4.1 != null and pv1Segment.19.4.2 != "" and pv1Segment.19.4.2 != null and pv1Segment.19.4.3 != "" and pv1Segment.19.4.3 != null -%} + {% evaluate Organization_ID_PV1_19_4 using 'ID/Organization' HDORG: pv1Segment.19.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.19.4, ID: Organization_ID_PV1_19_4 -%} + {% endif -%} + {% endif -%} - {% if firstSegments.EVN.5 -%} - {% if firstSegments.EVN.5.9.1 != "" and firstSegments.EVN.5.9.1 != null and firstSegments.EVN.5.9.2 != "" and firstSegments.EVN.5.9.2 != null and firstSegments.EVN.5.9.3 != "" and firstSegments.EVN.5.9.3 != null -%} - {% evaluate Organization_ID_EVN_5_9 using 'ID/Organization' HDORG: firstSegments.EVN.5.9 -%} - {% include 'Resource/Organization', EVN: firstSegments.EVN.5.9, ID: Organization_ID_EVN_5_9 -%} - {% endif -%} - {% evaluate practitionerId_EVN_5 using 'ID/Practitioner' XCN: firstSegments.EVN.5 -%} - {% include 'Resource/Practitioner' EVN: firstSegments.EVN.5, ID: practitionerId_EVN_5 -%} - {% endif -%} + {% if pv1Segment.7 -%} + {% if pv1Segment.7.9.1 != "" and pv1Segment.7.9.1 != null and pv1Segment.7.9.2 != "" and pv1Segment.7.9.2 != null and pv1Segment.7.9.3 != "" and pv1Segment.7.9.3 != null -%} + {% evaluate Organization_ID_PV1_7_9 using 'ID/Organization' HDORG: pv1Segment.7.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.7.9, ID: Organization_ID_PV1_7_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_7 using 'ID/Practitioner' XCN: pv1Segment.7 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.7, ID: practitionerId_PV1_7 -%} + {% endif -%} - {% if firstSegments.PD1.4 -%} - {% if firstSegments.PD1.4.9.1 != "" and firstSegments.PD1.4.9.1 != null and firstSegments.PD1.4.9.2 != "" and firstSegments.PD1.4.9.2 != null and firstSegments.PD1.4.9.3 != "" and firstSegments.PD1.4.9.3 != null -%} - {% evaluate Organization_ID_PD1_4_9 using 'ID/Organization' HDORG: firstSegments.PD1.4.9 -%} - {% include 'Resource/Organization', PD1_4: firstSegments.PD1.4.9, ID: Organization_ID_PD1_4_9 -%} - {% endif -%} - {% evaluate Practitioner_ID_PD1_4 using 'ID/Practitioner' XCN: firstSegments.PD1.4 -%} - {% include 'Resource/Practitioner' PD1: firstSegments.PD1.4, ID: Practitioner_ID_PD1_4 -%} - {% endif -%} + {% if pv1Segment.8 -%} + {% if pv1Segment.8.9.1 != "" and pv1Segment.8.9.1 != null and pv1Segment.8.9.2 != "" and pv1Segment.8.9.2 != null and pv1Segment.8.9.3 != "" and pv1Segment.8.9.3 != null -%} + {% evaluate Organization_ID_PV1_8_9 using 'ID/Organization' HDORG: pv1Segment.8.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.8.9, ID: Organization_ID_PV1_8_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_8 using 'ID/Practitioner' XCN: pv1Segment.8 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.8, ID: practitionerId_PV1_8 -%} + {% endif -%} - {% evaluate locationId_ORC_21 using 'ID/Location' XON: firstSegments.ORC.21 -%} - {% include 'Resource/Location' ORC: firstSegments.ORC, ID: locationId_ORC_21 -%} + {% if pv1Segment.9 -%} + {% if pv1Segment.9.9.1 != "" and pv1Segment.9.9.1 != null and pv1Segment.9.9.2 != "" and pv1Segment.9.9.2 != null and pv1Segment.9.9.3 != "" and pv1Segment.9.9.3 != null -%} + {% evaluate Organization_ID_PV1_9_9 using 'ID/Organization' HDORG: pv1Segment.9.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.9.9, ID: Organization_ID_PV1_9_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_9 using 'ID/Practitioner' XCN: pv1Segment.9 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.9, ID: practitionerId_PV1_9 -%} + {% endif -%} - {% if firstSegments.PV1.3 -%} - {% include 'Resource/PLLocation' PL: firstSegments.PV1.3-%} - {% endif -%} + {% if pv1Segment.17 -%} + {% if pv1Segment.17.9.1 != "" and pv1Segment.17.9.1 != null and pv1Segment.17.9.2 != "" and pv1Segment.17.9.2 != null and pv1Segment.17.9.3 != "" and pv1Segment.17.9.3 != null -%} + {% evaluate Organization_ID_PV1_17_9 using 'ID/Organization' HDORG: pv1Segment.17.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.17.9, ID: Organization_ID_PV1_17_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_17 using 'ID/Practitioner' XCN: pv1Segment.17 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.17, ID: practitionerId_PV1_17 -%} + {% endif -%} - {% if firstSegments.PV1.6 -%} - {% include 'Resource/PLLocation' PL: firstSegments.PV1.6 -%} - {% endif -%} + {% if pv1Segment.50 -%} + {% for p in pv1Segment.50.Repeats -%} + {% if p.4.1 != "" and p.4.1 != null and p.4.2 != "" and p.4.2 != null and p.4.3 != "" and p.4.3 != null -%} + {% evaluate Organization_ID_PV1_50_4 using 'ID/Organization' HDORG: p.4 -%} + {% include 'Resource/Organization', PV1: p.4, ID: Organization_ID_PV1_50_4 -%} + {% endif -%} + {% endfor -%} + {% endif -%} - {% if firstSegments.PV1.37 -%} - {% evaluate location_ID_PV1_37 using 'ID/Location' DLD: firstSegments.PV1.37 -%} - {% include 'Resource/Location' PV1: firstSegments.PV1.37, ID: location_ID_PV1_37-%} - {% endif -%} + {% if pv1Segment.52 -%} + {% if pv1Segment.52.9.1 != "" and pv1Segment.52.9.1 != null and pv1Segment.52.9.2 != "" and pv1Segment.52.9.2 != null and pv1Segment.52.9.3 != "" and pv1Segment.52.9.3 != null -%} + {% evaluate Organization_ID_PV1_52_9 using 'ID/Organization' HDORG: pv1Segment.52.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.52.9, ID: Organization_ID_PV1_52_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_52 using 'ID/Practitioner' XCN: pv1Segment.52 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.52, ID: practitionerId_PV1_52 -%} + {% endif -%} - {% if firstSegments.PV1.42 -%} - {% include 'Resource/PLLocation' PL: firstSegments.PV1.42-%} - {% endif -%} - - {% if firstSegments.PV1.43 -%} - {% include 'Resource/PLLocation' PL: firstSegments.PV1.43-%} - {% endif -%} + {% if pv2Segment.13 -%} + {% if pv2Segment.13.9.1 != "" and pv2Segment.13.9.1 != null and pv2Segment.13.9.2 != "" and pv2Segment.13.9.2 != null and pv2Segment.13.9.3 != "" and pv2Segment.13.9.3 != null -%} + {% evaluate Organization_ID_PV2_13_9 using 'ID/Organization' HDORG: pv2Segment.13.9 -%} + {% include 'Resource/Organization', PV2: pv2Segment.13.9, ID: Organization_ID_PV2_13_9 -%} + {% endif -%} + {% evaluate practitionerId_PV2_13 using 'ID/Practitioner' XCN: pv2Segment.13 -%} + {% include 'Resource/Practitioner' PV1: pv2Segment.13, ID: practitionerId_PV2_13 -%} + {% endif -%} - {% if firstSegments.PV2.1 -%} - {% include 'Resource/PLLocation' PL: firstSegments.PV2.1-%} - {% endif -%} - - {% evaluate provenanceId using 'ID/Provenance' MSH: firstSegments.MSH, baseId: patientId -%} - {% include 'Resource/Provenance' Root_Template: 'ORU_R01', MSH: firstSegments.MSH, ORC: firstSegments.ORC, ID: provenanceId -%} + {% if pv1Segment.3 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.3-%} + {% endif -%} - {% evaluate accountId using 'ID/Account' CX: firstSegments.PID.3 -%} - {% include 'Resource/Account' PID: firstSegments.PID, ID: accountId -%} - {% include 'Reference/Account/Subject' ID: accountId, REF: fullPatientId -%} + {% if pv1Segment.6 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.6 -%} + {% endif -%} - {% if firstSegments.PV1.54 -%} - {% if firstSegments.PV1.54.4.1 != "" and firstSegments.PV1.54.4.1 != null and firstSegments.PV1.54.4.2 != "" and firstSegments.PV1.54.4.2 != null and firstSegments.PV1.54.4.3 != "" and firstSegments.PV1.54.4.3 != null -%} - {% evaluate Organization_ID_PV1_54_4 using 'ID/Organization' HDORG: firstSegments.PV1.54.4 -%} - {% include 'Resource/Organization', PV1: firstSegments.PV1.54.4, ID: Organization_ID_PV1_54_4 -%} - {% endif -%} - {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: firstSegments.PV1.54 -%} - {% include 'Resource/EpisodeOfCare' PV1: firstSegments.PV1, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId -%} - {% endif -%} + {% if pv1Segment.37 -%} + {% evaluate location_ID_PV1_37 using 'ID/Location' DLD: pv1Segment.37 -%} + {% include 'Resource/Location' PV1: pv1Segment.37, ID: location_ID_PV1_37-%} + {% endif -%} - {% evaluate encounterId using 'ID/Encounter' PV1: firstSegments.PV1, baseId: patientId -%} - {% assign fullEncounterId = encounterId | prepend: 'Encounter/' -%} - {% include 'Resource/Encounter' Root_Template: 'ORU_R01', PV1: firstSegments.PV1, PV2: firstSegments.PV2, ID: encounterId -%} - {% include 'Reference/Encounter/Subject' ID: encounterId, REF: fullPatientId -%} - {% include 'Extensions/Encounter/EncounterExtension' ID: encounterId, PV1: firstSegments.PV1, PV2: firstSegments.PV2, -%} + {% if pv1Segment.42 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.42-%} + {% endif -%} - {% for nk1Segment in nk1SegmentLists.NK1 -%} - {% evaluate organizationId_NK1_13 using 'ID/Organization' XON: nk1Segment.13 -%} - {% include 'Resource/Organization' NK1: nk1Segment, ID: organizationId_NK1_13 -%} + {% if pv1Segment.43 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.43-%} + {% endif -%} + + {% if pv2Segment.1 -%} + {% include 'Resource/PLLocation' PL: pv2Segment.1-%} + {% endif -%} - {% include 'Resource/Patient' NK1: nk1Segment, ID: patientId -%} + {% if pv1Segment.54 -%} + {% if pv1Segment.54.4.1 != "" and pv1Segment.54.4.1 != null and pv1Segment.54.4.2 != "" and pv1Segment.54.4.2 != null and pv1Segment.54.4.3 != "" and pv1Segment.54.4.3 != null -%} + {% evaluate Organization_ID_PV1_54_4 using 'ID/Organization' HDORG: pv1Segment.54.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.54.4, ID: Organization_ID_PV1_54_4 -%} + {% endif -%} + {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: pv1Segment.54 -%} + {% include 'Resource/EpisodeOfCare' PV1: pv1Segment, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId -%} + {% endif -%} + {% evaluate encounterId using 'ID/Encounter' PV1: pv1Segment, baseId: patientId -%} + {% assign fullEncounterId = encounterId | prepend: 'Encounter/' -%} + {% include 'Resource/Encounter' Root_Template: 'ORU_R01', PV1: pv1Segment, PV2: pv2Segment, ID: encounterId -%} + {% include 'Reference/Encounter/Subject' ID: encounterId, REF: fullPatientId -%} + {% include 'Extensions/Encounter/EncounterExtension' ID: encounterId, PV1: pv1Segment, PV2: pv2Segment -%} + {% endif -%} - {% evaluate relatedPersonId using 'ID/RelatedPerson' NK1: nk1Segment, baseId: patientId -%} - {% include 'Resource/RelatedPerson' NK1: nk1Segment, RelatedPerson_Patient_ID: fullPatientId, ID: relatedPersonId -%} {% endfor -%} + {% assign txaSegmentPositionIndex = 0 -%} + {% for txaSegment in txaSegmentLists.TXA -%} + {% assign checkParentOBX = hl7v2Data | get_parent_segment: 'TXA', {{txaSegmentPositionIndex}}, 'OBX' -%} + {% assign txaSegmentPositionIndex = txaSegmentPositionIndex | plus: 1 -%} + + {% evaluate documentreferenceID using 'ID/DocumentReference' EI: txaSegment.12 -%} + {% include 'Resource/DocumentReference' TXA: txaSegment, OBX: checkParentOBX.OBX, ID: documentreferenceID -%} + {% if txaSegment.5 -%} + {% for txa_5 in txaSegment.5.Repeats -%} + {% if txa_5.9.1 != "" and txa_5.9.1 != null and txa_5.9.2 != "" and txa_5.9.2 != null and txa_5.9.3 != "" and txa_5.9.3 != null -%} + {% evaluate Organization_ID_TXA_5_9 using 'ID/Organization' HDORG: txa_5.9.9 -%} + {% include 'Resource/Organization', TXA: txa_5.5.9, ID: Organization_ID_TXA_5_9 -%} + {% endif -%} + {% evaluate practitionerId_TXA_5 using 'ID/Practitioner' XCN: txa_5 -%} + {% include 'Resource/Practitioner' TXA: txa_5, ID: practitionerId_TXA_5 -%} + {% endfor -%} + {% endif -%} + {% if txaSegment.9 -%} + {% for txa_9 in txaSegment.9.Repeats -%} + {% if txa_9.Value != null and txa_9.Value != "" -%} + {% if txa_9.9.1 != "" and txa_9.9.1 != null and txa_9.9.2 != "" and txa_9.9.2 != null and txa_9.9.3 != "" and txa_9.9.3 != null -%} + {% evaluate Organization_ID_TXA_9_9 using 'ID/Organization' HDORG: txa_9.9.9 -%} + {% include 'Resource/Organization', TXA: txa_9.9.9, ID: Organization_ID_TXA_9_9 -%} + {% endif -%} + {% evaluate practitionerId_TXA_9 using 'ID/Practitioner' XCN: txa_9 -%} + {% include 'Resource/Practitioner' TXA: txa_9, ID: practitionerId_TXA_9 -%} + + {% evaluate practitionerRoleId_TXA9 using 'ID/PractitionerRole' XCN: txa_9 -%} + {% include 'Resource/PractitionerRole' practitionerId_TXA: practitionerId_TXA_9, ID: practitionerRoleId_TXA9 -%} + {% endif -%} + {% endfor -%} + {% endif -%} + + {% if txaSegment.10.Repeats[0] -%} + {% assign txa_10 = txaSegment.10.Repeats[0] -%} + {% if txa_10.9.1 != "" and txa_10.9.1 != null and txa_10.9.2 != "" and txa_10.9.2 != null and txa_10.9.3 != "" and txa_10.9.3 != null -%} + {% evaluate Organization_ID_TXA_10_9 using 'ID/Organization' HDORG: txa_10.9.9 -%} + {% include 'Resource/Organization', TXA: txa_10.9.9, ID: Organization_ID_TXA_10_9 -%} + {% endif -%} + {% evaluate practitionerId_TXA_10 using 'ID/Practitioner' XCN: txa_10 -%} + {% include 'Resource/Practitioner' TXA: txa_10, ID: practitionerId_TXA_10 -%} + + {% evaluate practitionerRoleId_TXA10 using 'ID/PractitionerRole' XCN: txa_10 -%} + {% include 'Resource/PractitionerRole' practitionerId_TXA: practitionerId_TXA_10, ID: practitionerRoleId_TXA10 -%} + + {% endif -%} + {% endfor -%} + + {% assign obrSegmentPositionIndex_orc = 0 -%} + {% assign obxSegmentPositionIndex_obr = 0 -%} + {% assign obxSegmentPositionIndex_spm = 0 -%} {% for obrSegment in obrSegmentLists.OBR -%} + {% assign checkParent = hl7v2Data | get_parent_segment: 'OBR', {{obrSegmentPositionIndex_orc}}, 'ORC' -%} + {% assign obrSegmentPositionIndex_orc = obrSegmentPositionIndex_orc | plus: 1 -%} {% assign obxSegmentLists = hl7v2Data | get_related_segment_list: obrSegment, 'OBX' -%} {% assign spmSegmentLists = hl7v2Data | get_related_segment_list: obrSegment, 'SPM' -%} - - {% evaluate practitionerId_OBR_10 using 'ID/Practitioner' XCN: obrSegment.10 -%} - {% include 'Resource/Practitioner' OBR: obrSegment, ID: practitionerId_OBR_10 -%} + + {% evaluate patientId using 'ID/Patient' PID: pidSegmentLists.PID[0], type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} - - {% evaluate diagnosticId using 'ID/DiagnosticReport' OBR: obrSegment, baseId: patientId -%} - {% include 'Resource/DiagnosticReport' OBR: obrSegment, DiagnosticReport_Encounter_ID: fullEncounterId, ID: diagnosticId -%} - - {% for obxSegment in obxSegmentLists.OBX -%} - {% comment -%}{% endcomment -%} - {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} - {% if obxSegment.24 or obxSegment.25 -%} - {% include 'Resource/Organization' OBX_ORU: obxSegment, ID: organizationId_OBX_23 -%} - {% endif -%} - {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obxSegment.16 -%} - {% if obxSegment.16 -%} - {% include 'Resource/Practitioner' OBX: obxSegment, ID: practitionerId_OBX_16 -%} + {% evaluate parentServiceRequestId_orc using 'ID/ServiceRequest' ORC: checkParent.ORC.8, baseId: patientId -%} + {% if obrSegment.29 == null %} + {% if checkParent.ORC.8 and checkParent.ORC.31 %} + {% include 'Resource/ServiceRequest' OBR: obrSegment, ORC: checkParent.ORC, ID: parentServiceRequestId_orc, ServiceRequest_Subject_ID: fullPatientId, type_msg: "ORU" -%} + {% endif %} + {% endif %} + + {% evaluate serviceRequestId using 'ID/ServiceRequest' OBR: obrSegment, baseId: patientId -%} + {% evaluate specimenId_obr using 'ID/Specimen' OBR: obrSegment -%} + {% assign fullSpecimenId_obr = specimenId_obr | prepend: 'Specimen/' -%} + {% evaluate parentServiceRequestId using 'ID/ServiceRequest' OBR_29: obrSegment.29, baseId: patientId -%} + {% include 'Resource/ServiceRequest' OBR_child: obrSegment, parentSegment: checkParent.ORC, ServiceRequest_Subject_ID: fullPatientId, ServiceRequest_ID_OBR_29: parentServiceRequestId, ServiceRequest_ID_ORC_8: parentServiceRequestId_orc, ID: serviceRequestId, type_msg: "ORU" -%} + {% if serviceRequestId and documentreferenceID %} + {% assign fullDocumentreferenceID = documentreferenceID | prepend: 'DocumentReference/' -%} + {% include 'Reference/ServiceRequest/ReasonReference' ID: serviceRequestId, REF: fullDocumentreferenceID -%} + {% endif %} + + {% evaluate practitionerId_ORC_12 using 'ID/Practitioner' XCN: checkParent.ORC.12.Repeats[0] -%} + {% if obrSegment.16 -%} + {% if obrSegment.16.Repeats[0] %} + {% if obrSegment.16.Repeats[0].9.1 != "" and obrSegment.16.Repeats[0].9.1 != null and obrSegment.16.Repeats[0].9.2 != "" and obrSegment.16.Repeats[0].9.2 != null and obrSegment.16.Repeats[0].9.3 != "" and obrSegment.16.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_OBR16 using 'ID/Organization' HDORG: obrSegment.16.Repeats[0].9 -%} + {% include 'Resource/Organization' OBR_SEG_16: obrSegment.16.Repeats[0].9, ID: Organization_ID_OBR16 -%} + {% endif -%} + {% endif -%} + {% evaluate practitionerId_OBR_16 using 'ID/Practitioner' XCN: obrSegment.16.Repeats[0] -%} + {% include 'Resource/Practitioner' OBR_SEG: obrSegment, OBRXCN_16: obrSegment.16.Repeats[0], ORC_SEG_24: checkParent.ORC.24, ID: practitionerId_OBR_16 -%} + {% evaluate practitionerRoleId_OBR_16 using 'ID/PractitionerRole' XCN: obrSegment.16.Repeats[0]-%} + {% include 'Resource/PractitionerRole' OBR: obrSegment, requestor_practitioner1: practitionerId_OBR_16, ID: practitionerRoleId_OBR_16 -%} + {% assign fullpractitionerRoleId_OBR_16 = practitionerRoleId_OBR_16 | prepend: 'PractitionerRole/' -%} + {% include 'Reference/ServiceRequest/Requester' REF: fullpractitionerRoleId_OBR_16, ID: serviceRequestId -%} + {% else %} + {% if checkParent.ORC.12 %} + {% if checkParent.ORC.12.Repeats[0].9.1 != "" and checkParent.ORC.12.Repeats[0].9.1 != null and checkParent.ORC.12.Repeats[0].9.2 != "" and checkParent.ORC.12.Repeats[0].9.2 != null and checkParent.ORC.12.Repeats[0].9.3 != "" and checkParent.ORC.12.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_ORC_12 using 'ID/Organization' HDORG: checkParent.ORC.12.Repeats[0].9 -%} + {% include 'Resource/Organization' ORC_SEG_12: checkParent.ORC.12.Repeats[0].9, ID: Organization_ID_ORC_12 -%} + {% endif -%} + {% include 'Resource/Practitioner' ORC_SEG: checkParent.ORC, ORCXCN_12: checkParent.ORC.12.Repeats[0], ORC_SEG_24: checkParent.ORC.24, ID: practitionerId_ORC_12 -%} + {% evaluate practitionerRoleId_ORC_12 using 'ID/PractitionerRole' XCN: checkParent.ORC.12.Repeats[0]-%} + {% include 'Resource/PractitionerRole' ORC: checkParent.ORC, requestor_practitioner2: practitionerId_ORC_12, ID: practitionerRoleId_ORC_12 -%} + {% assign fullPractitionerRoleId_ORC_12 = practitionerRoleId_ORC_12 | prepend: 'PractitionerRole/' -%} + {% include 'Reference/ServiceRequest/Requester' REF: fullPractitionerRoleId_ORC_12, ID: serviceRequestId -%} + {% else %} + {% if checkParent.ORC.21 %} + {% evaluate organizationId_ORC_21 using 'ID/Organization' XON: checkParent.ORC.21.Repeats[0] -%} + {% if checkParent.ORC.12.Repeats[0] == null or checkParent.ORC.12.Repeats[0] == "" and obrSegment.16 == null or obrSegment.16 == "" %} + {% include 'Resource/Organization' ORC_SEG: checkParent.ORC, ORC_SEG_22: checkParent.ORC.22, ORC_SEG_23: checkParent.ORC.23, ID: organizationId_ORC_21 -%} + {% endif %} + {% evaluate practitionerRoleId_ORC_21 using 'ID/PractitionerRole' XCN: checkParent.ORC.21.Repeats[0]-%} + {% include 'Resource/PractitionerRole' ORC: checkParent.ORC, requestor_organization: organizationId_ORC_21, ID: practitionerRoleId_ORC_21 -%} + {% assign fullPractitionerRoleId_ORC_21 = practitionerRoleId_ORC_21 | prepend: 'PractitionerRole/' -%} + {% include 'Reference/ServiceRequest/Requester' REF: fullPractitionerRoleId_ORC_21, ID: serviceRequestId -%} + {% endif %} {% endif -%} + {% endif %} + + {% include 'Reference/ServiceRequest/Specimen' REF: fullSpecimenId_obr, ID: serviceRequestId -%} + + {% if obrSegment.29 %} + {% if obrSegment.50 -%} + {% evaluate parentServiceRequestId using 'ID/ServiceRequest' OBR_29: obrSegment.29, baseId: patientId -%} + {% include 'Resource/ServiceRequest' OBR_parent: obrSegment, parentSegment: checkParent.ORC, ServiceRequest_Subject_ID: fullPatientId, ID: parentServiceRequestId, type_msg: "ORU" -%} + {% endif %} + {% endif %} + + {% assign fullParentServiceRequestId = parentServiceRequestId | prepend: 'ServiceRequest/' -%} + + {% evaluate diagnosticId using 'ID/DiagnosticReport' OBR: obrSegment -%} + + {% assign nteSegmentLists1 = hl7v2Data | get_related_segment_list: obrSegment, 'NTE' -%} + {% for nteSegment1 in nteSegmentLists1.NTE -%} + {% if nteSegment1.5 -%} + {% if nteSegment1.5.9.1 != "" and nteSegment1.5.9.1 != null and nteSegment1.5.9.2 != "" and nteSegment1.5.9.2 != null and nteSegment1.5.9.3 != "" and nteSegment1.5.9.3 != null -%} + {% evaluate Organization_ID_NTE1_5_9 using 'ID/Organization' HDORG: nteSegment1.5.9 -%} + {% include 'Resource/Organization' OBR_NTE: nteSegment1.5.9, ID: Organization_ID_NTE1_5_9 -%} + {% endif -%} + {% evaluate practitioner_ID_NTE_5 using 'ID/Practitioner' XCN: nteSegment1.5 -%} + {% include 'Resource/Practitioner' NTE: nteSegment1.5, ID: practitioner_ID_NTE_5 -%} + {% endif -%} + {% include 'Resource/ServiceRequest' NTE: nteSegment1, ID: serviceRequestId -%} + {% endfor -%} - {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} - {% if obxSegment.16 or obxSegment.23 or obxSegment.25 -%} - {% include 'Resource/PractitionerRole' OBX: obxSegment, ID: practitionerRoleId_OBX_25 -%} - {% endif -%} + {% if obrSegment.32 -%} + {% evaluate practitionerId_obrSegment_32 using 'ID/Practitioner' CNN: obrSegment.32.1 -%} + {% evaluate practitionerRoleId_obrSegment_32 using 'ID/PractitionerRole' NDL: obrSegment.32 -%} + {% assign full_practitionerId_obrSegment_32 = practitionerId_obrSegment_32 | prepend: 'Practitioner/' %} + {% assign full_practitionerRoleId_obrSegment_32 = practitionerRoleId_obrSegment_32 | prepend: 'PractitionerRole/' %} + {% include 'Resource/Practitioner' OBR: obrSegment, CNN_OBR_32: obrSegment.32, ID: practitionerId_obrSegment_32 -%} + {% include 'Resource/PractitionerRole' OBR_32: obrSegment.32, ID: practitionerRoleId_obrSegment_32 -%} + {% include 'DataType/NDLLocation' NDL: obrSegment.32 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_obrSegment_32, ID: practitionerRoleId_obrSegment_32 -%} + {% include 'Reference/DiagnosticReport/ResultsInterpreter' REF: full_practitionerRoleId_obrSegment_32, ID: diagnosticId %} + {% endif -%} + {% for obr_34 in obrSegment.34.Repeats -%} + {% evaluate practitionerId_obr_34 using 'ID/Practitioner' CNN: obr_34.1 -%} + {% include 'Resource/Practitioner' OBR: obrSegment, CNN_OBR_34_1: obr_34.1, ID: practitionerId_obr_34 -%} + {% evaluate practitionerRoleId_obr_34 using 'ID/PractitionerRole' NDL: obr_34 -%} + {% assign full_practitionerId_obr_34 = practitionerId_obr_34 | prepend: 'Practitioner/' %} + {% assign full_practitionerRoleId_obr_34 = practitionerRoleId_obrSegment_34 | prepend: 'PractitionerRole/' %} + {% include 'Resource/PractitionerRole' OBR_34: OBR_34, ID: practitionerRoleId_obr_34 -%} + {% include 'DataType/NDLLocation' NDL: obr_34 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_obr_34, ID: practitionerRoleId_obr_34 -%} + {% include 'Reference/DiagnosticReport/Performer' REF: full_practitionerRoleId_obr_34, ID: diagnosticId %} + {% endfor %} + {% for obr_35 in obrSegment.35.Repeats -%} + {% evaluate practitionerId_obr_35 using 'ID/Practitioner' CNN: obr_35.1 -%} + {% include 'Resource/Practitioner' OBR: obrSegment, CNN_OBR_35_1: obr_35.1, ID: practitionerId_obr_35 -%} + {% evaluate practitionerRoleId_obr_35 using 'ID/PractitionerRole' NDL: obr_35 -%} + {% assign full_practitionerId_obr_35 = practitionerId_obr_35 | prepend: 'Practitioner/' %} + {% assign full_practitionerRoleId_obr_35 = practitionerRoleId_obrSegment_35 | prepend: 'PractitionerRole/' %} + {% include 'Resource/PractitionerRole' OBR_35: OBR_35, ID: practitionerRoleId_obr_35 -%} + {% include 'DataType/NDLLocation' NDL: obr_35 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_obr_35, ID: practitionerRoleId_obr_35 -%} + {% include 'Reference/DiagnosticReport/Performer' REF: full_practitionerRoleId_obr_35, ID: diagnosticId %} + {% endfor %} + + {% include 'Resource/DiagnosticReport' OBR: obrSegment, parentSegment: checkParent.ORC, DiagnosticReport_Encounter_ID: fullEncounterId, ID: diagnosticId, DiagnosticReport_Subject_ID: fullPatientId -%} + {% assign fullServiceRequestId = serviceRequestId | prepend: 'ServiceRequest/' -%} + {% include 'Reference/DiagnosticReport/BasedOn' ID: diagnosticId, REF: fullServiceRequestId -%} + {% include 'Reference/DiagnosticReport/Specimen' ID: diagnosticId, REF: fullSpecimenId_obr -%} + {% include 'Resource/Specimen' OBR: obrSegment, ID: specimenId_obr -%} + + {% if obrSegment.10 %} + {% if obrSegment.10.Repeats[0].9.1 != "" and obrSegment.10.Repeats[0].9.1 != null and obrSegment.10.Repeats[0].9.2 != "" and obrSegment.10.Repeats[0].9.2 != null and obrSegment.10.Repeats[0].9.3 != "" and obrSegment.10.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_OBR10 using 'ID/Organization' HDORG: obrSegment.10.Repeats[0].9 -%} + {% include 'Resource/Organization' OBR_SEG_10: obrSegment.10.Repeats[0].9, ID: Organization_ID_OBR10 -%} + {% endif -%} + {% evaluate practitionerId_OBR_10 using 'ID/Practitioner' XCN: obrSegment.10.Repeats[0] -%} + {% include 'Resource/Practitioner' OBR_SEG: obrSegment, OBRXCN_10: obrSegment.10.Repeats[0], ID: practitionerId_OBR_10 -%} + {% evaluate practitionerRoleId_OBR_10 using 'ID/PractitionerRole' XCN: obrSegment.10.Repeats[0] -%} + {% assign full_practitionerId_obr_10 = practitionerRoleId_OBR_10 | prepend: 'PractitionerRole/' %} + {% include 'Resource/PractitionerRole' OBR: obrSegment, collection_collector_practitioner: practitionerId_obr_10, ID: practitionerRoleId_OBR_10 -%} + {% include 'Reference/Specimen/Collection_Collector' REF: full_practitionerId_obr_10, ID: specimenId_obr -%} + {% endif -%} - {% evaluate deviceId_OBX_18 using 'ID/Device' HD: obxSegment.18 -%} - {% if obxSegment.18 -%} - {% include 'Resource/Device' OBX: obxSegment, ID: deviceId_OBX_18 -%} + {% assign checkParentOBR = hl7v2Data | get_parent_segment: 'OBX', {{obxSegmentPositionIndex_obr}}, 'OBR' -%} + {% assign obxSegmentPositionIndex_obr = obxSegmentPositionIndex_obr | plus: 1 -%} + {% for obxSegment in obxSegmentLists.OBX -%} + {% if obxSegment.2.Value == 'ED' or obxSegment.2.Value == 'RP' %} + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16 -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16 -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23 -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + {% evaluate obx_diagnosticReportID2 using 'ID/DiagnosticReport' OBX: obxSegment -%} + {% include 'Resource/DiagnosticReport' OBX: obxSegment, DiagnosticReport_Subject_ID: fullPatientId, ID: obx_diagnosticReportID2 -%} + {% if serviceRequestId %} + {% include 'Resource/DiagnosticReport' DiagnosticReport_ServiceRequest_ID: serviceRequestId, ID: obx_diagnosticReportID2 %} + {% endif %} + {% else %} + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16 -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16 -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + {% if obxSegment.18 -%} + {% evaluate deviceId_OBX_18 using 'ID/Device' EI: obxSegment.18.Repeats[0] -%} + {% include 'Resource/Device' EI_OBX18: obxSegment.18, ID: deviceId_OBX_18 -%} + {% endif -%} + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23 -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + {% evaluate observationId using 'ID/Observation' OBX: obxSegment, baseId: patientId -%} + {% include 'Resource/Observation' OBX: obxSegment, Observation_Subject_ID: fullPatientId, ID: observationId -%} + {% if serviceRequestId %} + {% include 'Resource/Observation' Observation_ServiceRequest_ID: serviceRequestId, ID: observationId %} + {% endif %} + {% include 'Extensions/Observation/ObservationExtension' OBX: obxSegment, ID: observationId %} + {% assign nteSegmentLists2 = hl7v2Data | get_related_segment_list: obxSegment, 'NTE' -%} + {% for nteSegment2 in nteSegmentLists2.NTE -%} + {% if nteSegment2.5 -%} + {% if nteSegment2.5.9.1 != "" and nteSegment2.5.9.1 != null and nteSegment2.5.9.2 != "" and nteSegment2.5.9.2 != null and nteSegment2.5.9.3 != "" and nteSegment2.5.9.3 != null -%} + {% evaluate Organization_ID_NTE2_5_9 using 'ID/Organization' HDORG: nteSegment2.5.9 -%} + {% include 'Resource/Organization' OBX_NTE: nteSegment2.5.9, ID: Organization_ID_NTE2_5_9 -%} + {% endif -%} + {% evaluate practitioner_ID_NTE_5 using 'ID/Practitioner' XCN: nteSegment2.5 -%} + {% include 'Resource/Practitioner' NTE: nteSegment2.5, ID: practitioner_ID_NTE_5 -%} + {% endif -%} + {% include 'Resource/Observation' NTE: nteSegment2, ID: observationId -%} + {% endfor -%} + {% assign fullObservationId = observationId | prepend: 'Observation/' -%} + {% include 'Reference/DiagnosticReport/Result' ID: diagnosticId, REF: fullObservationId -%} {% endif -%} - - {% evaluate observationId using 'ID/Observation' OBX: obxSegment, baseId: patientId -%} - {% include 'Resource/Observation' OBX: obxSegment, Observation_Subject_ID: fullPatientId, ID: observationId -%} - - {% assign fullObservationId = observationId | prepend: 'Observation/' -%} - {% include 'Reference/DiagnosticReport/Result' ID: diagnosticId, REF: fullObservationId -%} {% endfor -%} + {% assign tq1SegmentLists = hl7v2Data | get_related_segment_list: obrSegment, 'TQ1' -%} + {% unless tq1SegmentLists.TQ1 -%} + {% include 'Resource/ServiceRequest' ID: serviceRequestId, OBR_tq1: obrSegment, ORC_tq1: checkParent.ORC -%} + {% endunless -%} + {% for tq1Segment in tq1SegmentLists.TQ1 -%} + {% include 'Resource/ServiceRequest' TQ1: tq1Segment, ID: serviceRequestId, OBR_timeday: obrSegment -%} + {% endfor -%} + {% for spmSegment in spmSegmentLists.SPM -%} - {% evaluate specimenId using 'ID/Specimen' SPM: spmSegment, baseId: patientId -%} - {% include 'Resource/Specimen' SPM: spmSegment, ID: specimenId -%} - - {% assign fullSpecimenId = specimenId | prepend: 'Specimen/' -%} - {% include 'Reference/DiagnosticReport/Specimen' ID: diagnosticId, REF: fullSpecimenId -%} + {% evaluate specimenId_spm using 'ID/Specimen' SPM: spmSegment, baseId: patientId -%} + {% include 'Resource/Specimen' SPM: spmSegment, ID: specimenId_spm -%} + {% if spmSegment.3 %} + {% for spmSegment_3 in spmSegment.3.Repeats %} + {% evaluate spm_specimenId_3 using 'ID/Specimen' SPM: spmSegment_3 -%} + {% include 'Resource/Specimen' SPM_parent: spmSegment_3, ID: spm_specimenId_3 -%} + {% assign fullSpecimenId_spm3 = spm_specimenId_3 | prepend: 'Specimen/' -%} + {% include 'Reference/Specimen/Parent' ID: specimenId_spm, REF: fullSpecimenId_spm3 -%} + {% endfor %} + {% endif %} + {% if spmSegment.30 -%} + {% if spmSegment.30.4.1 != "" and spmSegment.30.4.1 != null and spmSegment.30.4.2 != "" and spmSegment.30.4.2 != null and spmSegment.30.4.3 != "" and spmSegment.30.4.3 != null -%} + {% evaluate Organization_ID_SPM_30_4 using 'ID/Organization' HDORG: spmSegment.30.4 -%} + {% include 'Resource/Organization' SPM: spmSegment.30.4, ID: Organization_ID_SPM_30_4 -%} + {% endif -%} + {% endif -%} + {% if spmSegment.31 -%} + {% for spm_31 in spmSegment.31.Repeats %} + {% if spm_31.4.1 != "" and spm_31.4.1 != null and spm_31.4.2 != "" and spm_31.4.2 != null and spm_31.4.3 != "" and spm_31.4.3 != null -%} + {% evaluate Organization_ID_SPM_31_4 using 'ID/Organization' HDORG: spm_31.4 -%} + {% include 'Resource/Organization' SPM: spm_31.4, ID: Organization_ID_SPM_31_4 -%} + {% endif -%} + {% endfor %} + {% endif -%} + + {% include 'Extensions/Specimen/SpecimenExtension' ID: specimenId_spm, SPM: spmSegment -%} + {% assign fullSpecimenId_spm = specimenId_spm | prepend: 'Specimen/' -%} + + {% assign checkParentSPM = hl7v2Data | get_parent_segment: 'OBX', {{obxSegmentPositionIndex_spm}}, 'SPM' -%} + {% assign obxSegmentPositionIndex_spm = obxSegmentPositionIndex_spm | plus: 1 -%} + {% assign spm_obxSegmentLists = hl7v2Data | get_related_segment_list: spmSegment, 'OBX' -%} + {% for spm_obxSegment in spm_obxSegmentLists.OBX -%} + {% if spm_obxSegment.2.Value == 'ED' or spm_obxSegment.2.Value == 'RP' %} + {% for spm_obx_16 in spm_obxSegment.16.Repeats -%} + {% if spm_obx_16.9.1 != "" and spm_obx_16.9.1 != null and spm_obx_16.9.2 != "" and spm_obx_16.9.2 != null and spm_obx_16.9.3 != "" and spm_obx_16.9.3 != null -%} + {% evaluate Organization_ID_spm_obx_16 using 'ID/Organization' HDORG: spm_obx_16.9 -%} + {% include 'Resource/Organization' OBX: spm_obx_16.9, ID: Organization_ID_spm_obx_16 -%} + {% endif -%} + {% evaluate practitionerId_spm_obx_16 using 'ID/Practitioner' XCN: spm_obx_16 -%} + {% include 'Resource/Practitioner' OBX: spm_obxSegment, OBXXCN1: spm_obx_16, ID: practitionerId_spm_obx_16 -%} + {% evaluate practitionerRoleId_spm_obx_16 using 'ID/PractitionerRole' XCN: spm_obx_16 -%} + {% assign full_practitionerId_spm_obx_16 = practitionerId_spm_obx_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: spm_obx_16, ID: practitionerRoleId_spm_obx_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_spm_obx_16, ID: practitionerRoleId_spm_obx_16 -%} + {% endfor %} + {% if spm_obxSegment.23 or spm_obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: spm_obxSegment.25 -%} + {% endif %} + {% if spm_obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: spm_obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: spm_obxSegment, OBXXCN2: spm_obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: spm_obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if spm_obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: spm_obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: spm_obxSegment.23, OBX_24: spm_obxSegment.24, ID: organizationId_OBX_23 -%} + {% if spm_obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + {% evaluate spm_obx_diagnosticReportID using 'ID/DiagnosticReport' OBX: spm_obxSegment -%} + {% include 'Resource/DiagnosticReport' OBX: spm_obxSegment, DiagnosticReport_Subject_ID: fullPatientId, ID: spm_obx_diagnosticReportID -%} + {% if checkParentSPM %} + {% include 'Resource/DiagnosticReport' DiagnosticReport_Specimen_ID: fullSpecimenId_spm, ID: spm_obx_diagnosticReportID %} + {% endif %} + {% else %} + {% for spm_obx_16 in spm_obxSegment.16.Repeats -%} + {% if spm_obx_16.9.1 != "" and spm_obx_16.9.1 != null and spm_obx_16.9.2 != "" and spm_obx_16.9.2 != null and spm_obx_16.9.3 != "" and spm_obx_16.9.3 != null -%} + {% evaluate Organization_ID_spm_obx_16 using 'ID/Organization' HDORG: spm_obx_16.9 -%} + {% include 'Resource/Organization' OBX: spm_obx_16.9, ID: Organization_ID_spm_obx_16 -%} + {% endif -%} + {% evaluate practitionerId_spm_obx_16 using 'ID/Practitioner' XCN: spm_obx_16 -%} + {% include 'Resource/Practitioner' OBX: spm_obxSegment, OBXXCN1: spm_obx_16, ID: practitionerId_spm_obx_16 -%} + {% evaluate practitionerRoleId_spm_obx_16 using 'ID/PractitionerRole' XCN: spm_obx_16 -%} + {% assign full_practitionerId_spm_obx_16 = practitionerId_spm_obx_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: spm_obx_16, ID: practitionerRoleId_spm_obx_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_spm_obx_16, ID: practitionerRoleId_spm_obx_16 -%} + {% endfor %} + {% if spm_obxSegment.18 -%} + {% evaluate deviceId_OBX_18 using 'ID/Device' EI: spm_obxSegment.18.Repeats[0] -%} + {% include 'Resource/Device' EI_OBX18: spm_obxSegment.18, ID: deviceId_OBX_18 -%} + {% endif -%} + {% if spm_obxSegment.23 or spm_obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: spm_obxSegment.25 -%} + {% endif %} + {% if spm_obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: spm_obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: spm_obxSegment, OBXXCN2: spm_obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: spm_obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if spm_obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: spm_obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: spm_obxSegment.23, OBX_24: spm_obxSegment.24, ID: organizationId_OBX_23 -%} + {% if spm_obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + {% evaluate observationId using 'ID/Observation' OBX: spm_obxSegment, baseId: patientId -%} + {% include 'Resource/Observation' OBX: spm_obxSegment, Observation_Subject_ID: fullPatientId, SPM_Observation_Specimen_ID: fullSpecimenId_spm, ID: observationId -%} + {% if checkParentSPM %} + {% include 'Resource/Observation' Observation_Specimen_ID: fullSpecimenId_spm, ID: observationId %} + {% endif %} + {% include 'Extensions/Observation/ObservationExtension' OBX: spm_obxSegment, ID: observationId %} + {% endif %} {% endfor -%} {% endfor -%} + {% endfor -%} ] } \ No newline at end of file diff --git a/data/Templates/Hl7v2/Reference/ServiceRequest/_BasedOn.liquid b/data/Templates/Hl7v2/Reference/ServiceRequest/_BasedOn.liquid index f3f73a35c..59c7f284c 100644 --- a/data/Templates/Hl7v2/Reference/ServiceRequest/_BasedOn.liquid +++ b/data/Templates/Hl7v2/Reference/ServiceRequest/_BasedOn.liquid @@ -2,6 +2,31 @@ "resource":{ "resourceType": "ServiceRequest", "id":"{{ ID }}", + "identifier": + [ + {% if OBR %} + { + "type": + { + "coding": + [ + { + {% if OBR.29.1 and OBR.50 == null -%} + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + {% elsif OBR.29.2 and OBR.50 == null %} + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + {% elsif OBR.50 %} + {% include 'DataType/CWECodeableConcept' CWE: OBR.50 %} + {% endif %} + } + ], + }, + }, + {% endif -%} + ], + "basedOn": [ { diff --git a/data/Templates/Hl7v2/Resource/_Account.liquid b/data/Templates/Hl7v2/Resource/_Account.liquid index 00a66350c..0d0a35a81 100644 --- a/data/Templates/Hl7v2/Resource/_Account.liquid +++ b/data/Templates/Hl7v2/Resource/_Account.liquid @@ -70,6 +70,9 @@ }, "request":{ "method":"PUT", + {% if Root_Template == "ADT_A29" -%} + "method":"DELETE", + {% endif -%} "url":"Account/{{ ID }}", }, }, diff --git a/data/Templates/Hl7v2/Resource/_Appointment.liquid b/data/Templates/Hl7v2/Resource/_Appointment.liquid index c4789b613..45f3d3c16 100644 --- a/data/Templates/Hl7v2/Resource/_Appointment.liquid +++ b/data/Templates/Hl7v2/Resource/_Appointment.liquid @@ -1,12 +1,284 @@ + +{% evaluate practitioner_ID_AIP_3 using 'ID/Practitioner' XCN: AIP.3 -%} +{% evaluate device_Id_AIG_3 using 'ID/Device' CWE: AIG.3 -%} +{% evaluate practitionerRoleId_SCH_12 using 'ID/PractitionerRole' XCN: SCH.12 -%} +{% evaluate practitionerRoleId_SCH_16 using 'ID/PractitionerRole' XCN: SCH.16 -%} +{% evaluate practitionerRoleId_SCH_20 using 'ID/PractitionerRole' XCN: SCH.20 -%} + { "fullUrl":"urn:uuid:{{ ID }}", "resource":{ "resourceType" : "Appointment", "id": "{{ ID }}", + "identifier": + [ + {% if SCH.1 -%} + { + {% include 'DataType/EIIdentifier' EI: SCH.1 -%} + "type":{ + "coding": [ + { + "code": "PLAC", + "display": "Placer Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + } + ] + }, + }, + {% endif -%} + {% if SCH.2 -%} + { + {% include 'DataType/EIIdentifier' EI: SCH.2 -%} + "type":{ + "coding": [ + { + "code": "FILL", + "display": "Filler Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + } + ] + }, + }, + {% endif -%} + ], + "appointmentType" : { + {% include 'DataType/CWECodeableConcept' mapping: 'CodeSystem/AppointmentType', CWE: SCH.7 -%} + }, + {% if TQ1.9.1 -%} + {% if TQ1.9.1.Value == "S" or TQ1.9.1.Value == "Stat" or TQ1.9.1.Value == "stat" -%} + "priority" : 1, + {% elsif TQ1.9.1.Value == "A" or TQ1.9.1.Value == "ASAP" or TQ1.9.1.Value == "asap" -%} + "priority" : 2, + {% elsif TQ1.9.1.Value == "R" or TQ1.9.1.Value == "Routine" or TQ1.9.1.Value == "routine" -%} + "priority" : 3, + {% elsif TQ1.9.1.Value == "P" or TQ1.9.1.Value == "Preop" or TQ1.9.1.Value == "preop" -%} + "priority" : 4, + {% elsif TQ1.9.1.Value == "C" or TQ1.9.1.Value == "Callback" or TQ1.9.1.Value == "callback" -%} + "priority" : 5, + {% elsif TQ1.9.1.Value == "T" or TQ1.9.1.Value == "Timing critical" or TQ1.9.1.Value == "timing critical" -%} + "priority" : 6, + {% elsif TQ1.9.1.Value == "PRN" or TQ1.9.1.Value == "As needed" or TQ1.9.1.Value == "as needed" -%} + "priority" : 7, + {% else -%} + {% assign textvalue = TQ1.9.1.Value | slice: 0 -%} + {% if textvalue == "T" or textvalue == "t" -%} + "priority" : 6, + {% endif %} + {% endif %} + {% else -%} + {% if SCH.11.6.Value == "S" or SCH.11.6.Value == "Stat" or SCH.11.6.Value == "stat" -%} + "priority" : 1, + {% elsif SCH.11.6.Value == "A" or SCH.11.6.Value == "ASAP" or SCH.11.6.Value == "asap" -%} + "priority" : 2, + {% elsif SCH.11.6.Value == "R" or SCH.11.6.Value == "Routine" or SCH.11.6.Value == "routine" -%} + "priority" : 3, + {% elsif SCH.11.6.Value == "P" or SCH.11.6.Value == "Preop" or SCH.11.6.Value == "preop" -%} + "priority" : 4, + {% elsif SCH.11.6.Value == "C" or SCH.11.6.Value == "Callback" or SCH.11.6.Value == "callback" -%} + "priority" : 5, + {% elsif SCH.11.6.Value == "T" or SCH.11.6.Value == "Timing critical" or SCH.11.6.Value == "timing critical" -%} + "priority" : 6, + {% elsif SCH.11.6.Value == "PRN" or SCH.11.6.Value == "As needed" or SCH.11.6.Value == "as needed" -%} + "priority" : 7, + {% else -%} + {% assign textvalue = SCH.11.6.Value | slice: 0 -%} + {% if textvalue == "T" or textvalue == "t" -%} + "priority" : 6, + {% endif %} + {% endif %} + {% endif -%} + {% if TQ1.7 -%} + "start" : "{{ TQ1.7.Value | format_as_date_time }}", + {% else -%} + "start" : "{{ SCH.11.4.Value | format_as_date_time }}", + {% endif -%} + {% if TQ1.8 -%} + "end" : "{{ TQ1.8.Value | format_as_date_time }}", + {% else -%} + "end" : "{{ SCH.11.5.Value | format_as_date_time }}", + {% endif -%} + + {% if SCH.10.Value == 'Min' or SCH.10 == 'min' -%} + {% if SCH.9 -%} + "minutesDuration": {{ SCH.9.Value }}, + {% endif -%} + {% endif -%} + + {% if SCH.10.Value == 's' or SCH.10.Value == 'sec' or SCH.10 == null -%} + {% if SCH.9 -%} + "minutesDuration": {{ SCH.9.Value | divide: 60 | truncate_number }}, + {% endif -%} + {% endif -%} + + {% if SCH.10.Value == 'Hr' or SCH.10.Value == 'hr' -%} + {% if SCH.9 -%} + {% assign hour = SCH.9.Value | times: 1.0 %} + {% assign minutesDuration = hour | times: 60 %} + "minutesDuration": {{ minutesDuration }}, + {% endif -%} + {% endif -%} + {% if SCH.10.Value == 'ann' or SCH.10.Value == 'yr' -%} + {% if SCH.9 -%} + {% assign year = SCH.9.Value | times: 1.0 %} + {% assign minutesDuration = year | times: 3628800 %} + "minutesDuration": {{ minutesDuration }}, + {% endif -%} + {% endif -%} + {% if SCH.10.Value == 'd' -%} + {% if SCH.9 -%} + {% assign day = SCH.9.Value | times: 1.0 %} + {% assign minutesDuration = day | times: 1440 %} + "minutesDuration": {{ minutesDuration }}, + {% endif -%} + {% endif -%} + {% if SCH.10.Value == 'wk' -%} + {% if SCH.9 -%} + {% assign wk = SCH.9.Value | times: 1.0 %} + {% assign minutesDuration = wk | times: 10080 %} + "minutesDuration": {{ minutesDuration }}, + {% endif -%} + {% endif -%} + {% if SCH.10.Value == 'mo' -%} + {% if SCH.9 -%} + {% assign mo = SCH.9.Value | times: 1.0 %} + {% assign minutesDuration = mo | times: 302400 %} + "minutesDuration": {{ minutesDuration }}, + {% endif -%} + {% endif -%} + + {% if SCH -%} + {% unless type_sch -%} + {% if SCH.25 -%} + "status": {% include 'DataType/CWECode' mapping: 'CodeSystem/FillerStatus', CWE: SCH.25 -%}, + {% else -%} + "status": "booked", + {% endif -%} + {% endunless -%} + {% if type_sch -%} + {% if type_sch == "15" or type_sch == "16" -%} + "status": "cancelled", + {% elsif type_sch == "17" -%} + "status": "entered-in-error", + {% elsif type_sch == "26" -%} + "status": "noshow", + {% endif -%} + {% endif -%} + {% endif -%} + + "supportingInformation" : [ + {% if SCH.12 -%} + { + "reference":"PractitionerRole/{{ practitionerRoleId_SCH_12 }}" + }, + {% endif -%} + {% if SCH.16 -%} + { + "reference":"PractitionerRole/{{ practitionerRoleId_SCH_16 }}" + }, + {% endif -%} + {% if SCH.20 -%} + { + "reference":"PractitionerRole/{{ practitionerRoleId_SCH_20 }}" + }, + {% endif -%} + ], "comment": "{{NTE.3.Value}}", + "participant" : [ + {% if AIG -%} + { + {% if AIG.3 -%} + "actor" : { + "reference":"Device/{{ device_ID_AIG_3 }}" + }, + {% endif -%} + "type" : [ + { + {% include 'DataType/CWECodeableConcept', CWE: AIG.4-%} + }, + ], + "period" : { + "start" : "{{ AIG.8.Value | format_as_date_time }}", + }, + {% if AIG.14 -%} + "status": {% include 'DataType/CWECode' mapping: 'CodeSystem/FillerStatusAppointmentParticipantStatus', CWE: AIG.14 -%}, + {% else -%} + "status": "tentative", + {% endif -%} + }, + {% endif -%} + {% if AIL -%} + { + {% if AIL.3 -%} + "actor" : { + {% if AIL.3.1 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: AIL.3.1 -%} + "reference":"Location/{{ Location_ID_AIL_3 }}", + {% elseif AIL.3.2 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: AIL.3.2 -%} + "reference":"Location/{{ Location_ID_AIL_3 }}", + {% elseif AIL.3.3 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: AIL.3.3 -%} + "reference":"Location/{{ Location_ID_AIL_3 }}", + {% elseif AIL.3.4 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: AIL.3.4 -%} + "reference":"Location/{{ Location_ID_AIL_3 }}", + {% elseif AIL.3.7 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: AIL.3.7 -%} + "reference":"Location/{{ Location_ID_AIL_3 }}", + {% elseif AIL.3.8 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: AIL.3.8 -%} + "reference":"Location/{{ Location_ID_AIL_3 }}", + {% endif %} + }, + {% endif -%} + "period" : { + "start" : "{{ AIL.6.Value | format_as_date_time }}", + }, + {% if AIL.12 -%} + "status": {% include 'DataType/CWECode' mapping: 'CodeSystem/FillerStatusAppointmentParticipantStatus', CWE: AIL.12 -%}, + {% else -%} + "status": "tentative", + {% endif -%} + }, + {% endif -%} + {% if AIP -%} + { + {% if AIP.3 -%} + "actor" : { + "reference":"Practitioner/{{ practitioner_ID_AIP_3 }}" + }, + {% endif -%} + "type" : [ + { + {% include 'DataType/CWECodeableConcept', CWE: AIP.4 -%} + }, + ], + "period" : { + "start" : "{{ AIP.6.Value | format_as_date_time }}", + }, + {% if AIP.12 -%} + "status": {% include 'DataType/CWECode' mapping: 'CodeSystem/FillerStatusAppointmentParticipantStatus', CWE: AIP.12 -%}, + {% else -%} + "status": "tentative", + {% endif -%} + }, + {% endif -%} + {% if pidseg -%} + {% for pidSegment in pidseg.PID -%} + { + {% evaluate patientId using 'ID/Patient' PID: pidSegment, type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + "actor" : { + "reference":"{{ fullPatientId }}" + }, + "status" : "accepted", + }, + {% endfor -%} + {% endif -%} + ], }, "request":{ "method":"PUT", "url":"Appointment/{{ ID }}", }, -} \ No newline at end of file +}, \ No newline at end of file diff --git a/data/Templates/Hl7v2/Resource/_Coverage.liquid b/data/Templates/Hl7v2/Resource/_Coverage.liquid index e209b704c..eaad20c04 100644 --- a/data/Templates/Hl7v2/Resource/_Coverage.liquid +++ b/data/Templates/Hl7v2/Resource/_Coverage.liquid @@ -149,11 +149,6 @@ {% include 'DataType/CX' CX: in2_61 -%} }, {% endfor -%} - {% for in1_49 in IN1.49.Repeats -%} - { - {% include 'DataType/CX' CX: in1_49 -%} - }, - {% endfor -%} ], "costToBeneficiary" : [ { diff --git a/data/Templates/Hl7v2/Resource/_Device.liquid b/data/Templates/Hl7v2/Resource/_Device.liquid index 610c17857..343fd53e9 100644 --- a/data/Templates/Hl7v2/Resource/_Device.liquid +++ b/data/Templates/Hl7v2/Resource/_Device.liquid @@ -18,6 +18,8 @@ Device_Parent_ID: A resource Id used to fill "parent.reference" property. {% include 'DataType/HDDevice' HD: MSH.3 -%} {% endif -%} + {% include 'DataType/CWEIdentifier' CWE_InternalValue: AIG.3 -%} + "identifier": [ {% for ei_obx18 in EI_OBX18.Repeats -%} @@ -53,7 +55,18 @@ Device_Parent_ID: A resource Id used to fill "parent.reference" property. "type": "manufacturer-name", } {% endif -%} + {% if AIG.3.2 -%} + { + "name":"{{AIG.3.2.Value}}", + "type": "model-name", + } + {% endif -%} ], + {% if AIG.2.Value == "D" -%} + "status": "entered-in error", + {% elsif AIG.2.Value == "A" or AIG.2.Value == "U" or AIG.2.Value == "X"%} + "status": "active", + {% endif -%} "version": [ { @@ -62,9 +75,11 @@ Device_Parent_ID: A resource Id used to fill "parent.reference" property. ], "modelNumber": "{{SFT.4.Value}}", "note": [ - { - "text": "{{SFT.5.Value}}", - } + { + "text": "{{SFT.5.Value}}", + "text": "{{NTE.3.Value}}", + "time": "{{NTE.6.Value | format_as_date_time}}", + }, ], "manufactureDate":"{{ PRT.17.Value | format_as_date_time }}", "expirationDate":"{{ PRT.18.Value | format_as_date_time }}", @@ -99,6 +114,9 @@ Device_Parent_ID: A resource Id used to fill "parent.reference" property. }, "request":{ "method":"PUT", + {% if Root_Template == "ADT_A29" -%} + "method":"DELETE", + {% endif -%} "url":"Device/{{ ID }}", }, }, diff --git a/data/Templates/Hl7v2/Resource/_DiagnosticReport.liquid b/data/Templates/Hl7v2/Resource/_DiagnosticReport.liquid index f6ffac648..52115f252 100644 --- a/data/Templates/Hl7v2/Resource/_DiagnosticReport.liquid +++ b/data/Templates/Hl7v2/Resource/_DiagnosticReport.liquid @@ -9,7 +9,12 @@ DiagnosticReport_Subject_ID: A resource Id, used to fill "subject.reference" pro DiagnosticReport_Encounter_ID: A resource Id, used to fill "encounter.reference" property. {% endcomment -%} -{% evaluate Practitioner_ID_OBR_10 using 'ID/Practitioner' XCN: OBR.10 -%} +{%- comment -%} +{% evaluate Practitioner_ID_OBR_10 using 'ID/Practitioner' XCN: OBR_child.10 -%} +{%- endcomment -%} +{% evaluate PractitionerRole_ID_OBR_32 using 'ID/PractitionerRole' NDL: OBR.32 -%} +{% evaluate Organization_ID_OBX_23 using 'ID/Organization' XON: OBX.23 -%} +{% evaluate PractitionerRole_ID_OBX_25 using 'ID/PractitionerRole' XCN: OBX.25 -%} { "fullUrl":"urn:uuid:{{ ID }}", @@ -19,45 +24,78 @@ DiagnosticReport_Encounter_ID: A resource Id, used to fill "encounter.reference" "identifier": [ { - {% include 'DataType/EIIdentifier' EI: ORC.2 -%} - "type": - { - "coding": - [ + {% if OBR.2 == null %} + {% if parentSegment.2 -%} + {% include 'DataType/EIIdentifier' EI: parentSegment.2 -%} + "type": { - {% if ORC.2 -%} - "code":"PLAC", - {% endif -%} - {% if OBR.2 -%} - "code":"PLAC", - {% endif -%} - {% if OBR.3 -%} - "code":"FILL", - {% endif -%} - {% if ORC.2 -%} - "system":"http://terminology.hl7.org/CodeSystem/v2-0203", - {% endif -%} - {% if OBR.2 -%} - "system":"http://terminology.hl7.org/CodeSystem/v2-0203", - {% endif -%} - {% if OBR.3 -%} - "system":"http://terminology.hl7.org/CodeSystem/v2-0203", - {% endif -%} + "coding": + [ + { + "code":"PLAC", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + }, + ], }, - ], - }, + {% endif %} + {% else %} + {% include 'DataType/EIIdentifier' EI: OBR.2 -%} + "type": + { + "coding": + [ + { + {% if OBR.2 -%} + "code":"PLAC", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + {% endif -%} + }, + ], + }, + {% endif %} }, { - {% include 'DataType/EIIdentifier' EI: ORC.3 -%} + {% if OBR.3 == null %} + {% if parentSegment.3 -%} + {% include 'DataType/EIIdentifier' EI: parentSegment.3 -%} + "type": + { + "coding": + [ + { + "code":"FILL", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + }, + ], + }, + {% endif %} + {% else %} + {% include 'DataType/EIIdentifier' EI: OBR.3 -%} + "type": + { + "coding": + [ + { + {% if OBR.3 -%} + "code":"FILL", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + {% endif -%} + }, + ], + }, + {% endif %} + }, + { + {% include 'DataType/EIIdentifier' EI: parentSegment.4 -%} "type": { "coding": [ { - {% if ORC.3 -%} - "code":"FILL", + {% if parentSegment.4 -%} + "code":"PGN", {% endif -%} - {% if ORC.3 -%} + {% if parentSegment.4 -%} "system":"http://terminology.hl7.org/CodeSystem/v2-0203", {% endif -%} }, @@ -65,33 +103,32 @@ DiagnosticReport_Encounter_ID: A resource Id, used to fill "encounter.reference" }, }, { - {% include 'DataType/EIIdentifier' EI: ORC.4 -%} + {% include 'DataType/EIIdentifier' EI: OBX.21 -%} + }, + { "type": { "coding": [ { - {% if ORC.4 -%} - "code":"PGN", - {% endif -%} - {% if ORC.4 -%} - "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + {% if OBX.21 -%} + "code":"FILL", {% endif -%} }, ], }, }, - { - {% include 'DataType/EIIdentifier' EI: OBR.2 -%} - }, - { - {% include 'DataType/EIIdentifier' EI: OBR.3 -%} - }, ], "effectiveDateTime":"{{ ORC.9.Value | format_as_date_time }}", {% if OBR.8 == null -%} "effectiveDateTime":"{{ OBR.7.Value | format_as_date_time }}", {% endif -%} + "code": + { + {% include 'DataType/CWECodeableConcept' CWE: OBX.3 -%} + }, + "status": "{{ OBX.11.Value | get_property: 'CodeSystem/DiagnosticReportStatus', 'code' }}", + "effectiveDateTime":"{{ OBX.14.Value | format_as_date_time }}", "basedOn": [ { @@ -99,6 +136,11 @@ DiagnosticReport_Encounter_ID: A resource Id, used to fill "encounter.reference" "reference":"ServiceRequest/{{ ServiceRequest_ID_ORC_2 }}", {% endif -%} }, + { + {% if DiagnosticReport_ServiceRequest_ID %} + "reference":"ServiceRequest/{{ DiagnosticReport_ServiceRequest_ID }}", + {% endif %} + }, ], "code": { @@ -111,32 +153,88 @@ DiagnosticReport_Encounter_ID: A resource Id, used to fill "encounter.reference" {% endif -%} "end":"{{ OBR.8.Value | format_as_date_time }}", }, + "issued":"{{ OBR.22.Value | format_as_date_time }}", - "category": - [ - { - {% include 'DataType/CWECodeableConcept' CWE: OBR.24 -%} - }, + + "category": [ + { + {% include 'DataType/IDCodeableConcept' mapping: 'CodeSystem/DiagnosticServiceSection', ID: OBR.24 -%} + }, ], - "status":"{{ OBR.25.Value | get_property: 'CodeSystem/ResultStatus', 'code' }}", - "specimen": + {% if OBR.25 %} + "status": "{{ OBR.25.Value | get_property: 'CodeSystem/ResultStatus', 'code' }}", + {% endif %} + + {% unless OBR.25 -%} + "status": "unknown", + {% endunless -%} + "resultsInterpreter" : [{ + {% if OBR.32 and PractitionerRole_ID_OBR_32 -%} + "reference":"PractitionerRole/{{ PractitionerRole_ID_OBR_32 }}", + {% endif -%} + }], + + "performer": [ + {% for obx_Segment_16 in OBX.16.Repeats %} + { + {% evaluate PractitionerRole_ID_OBX_16 using 'ID/PractitionerRole' XCN: obx_Segment_16 -%} + {% if obx_Segment_16 and PractitionerRole_ID_OBX_16 -%} + "reference":"PractitionerRole/{{ PractitionerRole_ID_OBX_16 }}", + {% endif -%} + }, + {% endfor %} { - {% if OBR.10 and Practitioner_ID_OBR_10 -%} - "reference":"Practitioner/{{ Practitioner_ID_OBR_10 }}", + {% if OBX.25 == null and OBX.23 and Organization_ID_OBX_23 -%} + "reference":"Organization/{{ Organization_ID_OBX_23 }}", {% endif -%} + {% if OBX.23 and OBX.25 and PractitionerRole_ID_OBX_25 -%} + "reference":"PractitionerRole/{{ PractitionerRole_ID_OBX_25 }}", + {% endif -%} + }, + {% for obx_Segment_34 in OBR.34.Repeats %} + { + {% evaluate PractitionerRole_ID_OBX_34 using 'ID/PractitionerRole' NDL: obx_Segment_34 -%} + {% if obx_Segment_34 and PractitionerRole_ID_OBX_34 -%} + "reference":"PractitionerRole/{{ PractitionerRole_ID_OBX_34 }}", + {% endif -%} }, + {% endfor %} + {% for obx_Segment_35 in OBR.35.Repeats %} + { + {% evaluate PractitionerRole_ID_OBX_35 using 'ID/PractitionerRole' NDL: obx_Segment_35 -%} + {% if obx_Segment_35 and PractitionerRole_ID_OBX_35 -%} + "reference":"PractitionerRole/{{ PractitionerRole_ID_OBX_35 }}", + {% endif -%} + }, + {% endfor %} ], - "performer": - [ - { - {% if OBR.34 and PractitionerRole_ID_OBR_34 -%} - "reference":"PractitionerRole/{{ PractitionerRole_ID_OBR_34 }}", - {% endif -%} - {% if OBR.35 and PractitionerRole_ID_OBR_35 -%} - "reference":"PractitionerRole/{{ PractitionerRole_ID_OBR_35 }}", - {% endif -%} + "presentedForm" : [ + {% if OBX.2.Value == "ED" and OBX.5.4.Value == "Base64" %} + { + {% include 'DataType/EDAttachment1' ED: OBX.5 %} }, + {% elsif OBX.2.Value == "RP" %} + { + {% include 'DataType/RPAttachment' RP: OBX.5 %} + }, + {% endif %} + ], + {%- comment -%} + {% for nte_3 in NTE.3.Repeats %} + {% if nte_3 %} + {% capture conclusionstring %}{{ conclusionstring | append: nte_3.Value | append: ";" }}{% endcapture -%} + {% endif -%} + {% endfor %} + "conclusion": "{{ conclusionstring | split: ";" | join: "+"}}", + {%- endcomment -%} + "specimen": + [ + { + {% if DiagnosticReport_Specimen_ID %} + "reference":"{{ DiagnosticReport_Specimen_ID }}", + {% endif %} + }, ], "subject": { @@ -146,6 +244,7 @@ DiagnosticReport_Encounter_ID: A resource Id, used to fill "encounter.reference" { "reference":"{{ DiagnosticReport_Encounter_ID }}", }, + }, "request":{ "method":"PUT", diff --git a/data/Templates/Hl7v2/Resource/_DocumentReference.liquid b/data/Templates/Hl7v2/Resource/_DocumentReference.liquid new file mode 100644 index 000000000..78b151853 --- /dev/null +++ b/data/Templates/Hl7v2/Resource/_DocumentReference.liquid @@ -0,0 +1,123 @@ +{ + "fullUrl":"urn:uuid:{{ ID }}", + "resource":{ + "resourceType": "DocumentReference", + "id":"{{ ID }}", + "type" :{ + {% include 'DataType/CWECodeableConcept' CWE: TXA.2 -%} + }, + "context" : { + "period" : { + "start" : "{{ TXA.4.Value | format_as_date_time }}", + }, + {% if TXA.5 -%} + "related" : [ + {% for txa_5 in TXA.5.Repeats -%} + {% evaluate practitionerId_TXA_5 using 'ID/Practitioner' XCN: txa_5 -%} + { + "reference" : "Practitioner/{{practitionerId_TXA_5}}", + }, + {% endfor -%} + ] + {% endif -%} + }, + "content" : [ + { + "attachment" : { + {% if OBX.2.Value == "ED" and OBX.14 == null -%} + "creation" : "{{ TXA.6.Value | format_as_date_time }}", + {% endif -%} + {% unless OBX.Value %} + "creation" : "{{ TXA.6.Value | format_as_date_time }}", + {% endunless %} + + "title": "{{OBX.3.2.Value}}", + {% if OBX.2.Value == "RP" -%} + {% include 'DataType/RPAttachment' RP: OBX.5 %} + {% endif -%} + {% if OBX.2.Value == "ED" and OBX.5.4.Value == "Base64" -%} + {% include 'DataType/EDAttachment1' ED: OBX.5 %} + {% endif -%} + }, + } + ], + + "meta": { + "lastUpdated" : "{{ TXA.8.Value | format_as_date_time }}", + }, + "author" : [ + {% if TXA.9 -%} + {% for txa_9 in TXA.9.Repeats -%} + {% if txa_9.Value != null and txa_9.Value != "" -%} + { + {% evaluate practitionerRoleId_TXA9 using 'ID/PractitionerRole' XCN: txa_9 -%} + "reference" : "PractitionerRole/{{practitionerRoleId_TXA9}}", + }, + {% endif -%} + {% endfor -%} + {% endif -%} + ], + "authenticator" : { + {% if TXA.10.Repeats[0] -%} + {% evaluate practitionerRoleId_TXA10 using 'ID/PractitionerRole' XCN: TXA.10.Repeats[0]-%} + "reference" : "PractitionerRole/{{practitionerRoleId_TXA10}}", + {% endif -%} + }, + "masterIdentifier" : { + {% include 'DataType/EIIdentifier' EI: TXA.12 -%} + }, + "identifier" : [ + {% if TXA.16 -%} + { + "value" : "{{ TXA.16.Value }}", + "type" : { + "coding": [ + { + "system" : "http://example.com/v2-to-fhir-converter/CodeSystem/additional-identifertype", + "code" : "DOCI", + "display" : "Document unique identifier" + } + ], + "text" : "Document unique file name", + } + } + {% endif -%} + ], + "relatesTo" : [ + {% if TXA.13 -%} + { + "code" : "appends", + "target" : { + "identifier": + { + {% include 'DataType/EIIdentifier' EI: TXA.13 -%} + } + } + } + {% endif -%} + ], + "docStatus" : "{{ TXA.17.Value | get_property: 'CodeSystem/DocumentCompletionStatus', 'code' }}", + "securityLabel" : [ + { + {% include 'DataType/IDCodeableConcept' mapping: 'CodeSystem/SecurityLableHandingInstructions' , ID: TXA.18 -%} + } + ], + "status" : "{{ TXA.19.Value | get_property: 'CodeSystem/DocumentAvailabilityStatus', 'code' }}", + {% unless TXA.19 -%} + "status": "current", + {% endunless -%} + "category" : [ + {% for txa_24 in TXA.24.Repeats -%} + { + {% include 'DataType/CWECodeableConcept' CWE: txa_24 -%} + }, + {% endfor -%} + ], + {% capture textstring %}{{TXA.25.Value | split: "~" | join: "+" }}{% endcapture -%} + "description" : "{{ textstring }}" + }, + "request":{ + "method":"PUT", + "url":"DocumentReference/{{ ID }}", + }, +}, diff --git a/data/Templates/Hl7v2/Resource/_Encounter.liquid b/data/Templates/Hl7v2/Resource/_Encounter.liquid index 9b837d92d..0228e1085 100644 --- a/data/Templates/Hl7v2/Resource/_Encounter.liquid +++ b/data/Templates/Hl7v2/Resource/_Encounter.liquid @@ -12,41 +12,6 @@ Practitioner_ID_PV1_17: A resource Id, used to fill "participant.individual.refe Practitioner_ID_PV1_52: A resource Id, used to fill "participant.individual.reference" property. The resource is of "Practitioner" type and generated based on "PV1.52" HL7 V2 identifier. {% endcomment -%} -{% evaluate Location_ID_PV1_3_1 using 'ID/Location' PL: PV1.3.1 -%} -{% evaluate Location_ID_PV1_3_2 using 'ID/Location' PL: PV1.3.2 -%} -{% evaluate Location_ID_PV1_3_3 using 'ID/Location' PL: PV1.3.3 -%} -{% evaluate Location_ID_PV1_3_4 using 'ID/Location' PL: PV1.3.4 -%} -{% evaluate Location_ID_PV1_3_7 using 'ID/Location' PL: PV1.3.7 -%} -{% evaluate Location_ID_PV1_3_8 using 'ID/Location' PL: PV1.3.8 -%} - -{% evaluate Location_ID_PV1_6_1 using 'ID/Location' PL: PV1.6.1 -%} -{% evaluate Location_ID_PV1_6_2 using 'ID/Location' PL: PV1.6.2 -%} -{% evaluate Location_ID_PV1_6_3 using 'ID/Location' PL: PV1.6.3 -%} -{% evaluate Location_ID_PV1_6_4 using 'ID/Location' PL: PV1.6.4 -%} -{% evaluate Location_ID_PV1_6_7 using 'ID/Location' PL: PV1.6.7 -%} -{% evaluate Location_ID_PV1_6_8 using 'ID/Location' PL: PV1.6.8 -%} - -{% evaluate Location_ID_PV1_42_1 using 'ID/Location' PL: PV1.42.1 -%} -{% evaluate Location_ID_PV1_42_2 using 'ID/Location' PL: PV1.42.2 -%} -{% evaluate Location_ID_PV1_42_3 using 'ID/Location' PL: PV1.42.3 -%} -{% evaluate Location_ID_PV1_42_4 using 'ID/Location' PL: PV1.42.4 -%} -{% evaluate Location_ID_PV1_42_7 using 'ID/Location' PL: PV1.42.7 -%} -{% evaluate Location_ID_PV1_42_8 using 'ID/Location' PL: PV1.42.8 -%} - -{% evaluate Location_ID_PV1_43_1 using 'ID/Location' PL: PV1.43.1 -%} -{% evaluate Location_ID_PV1_43_2 using 'ID/Location' PL: PV1.43.2 -%} -{% evaluate Location_ID_PV1_43_3 using 'ID/Location' PL: PV1.43.3 -%} -{% evaluate Location_ID_PV1_43_4 using 'ID/Location' PL: PV1.43.4 -%} -{% evaluate Location_ID_PV1_43_7 using 'ID/Location' PL: PV1.43.7 -%} -{% evaluate Location_ID_PV1_43_8 using 'ID/Location' PL: PV1.43.8 -%} - -{% evaluate Location_ID_PV2_1_1 using 'ID/Location' PL: PV2.1.1 -%} -{% evaluate Location_ID_PV2_1_2 using 'ID/Location' PL: PV2.1.2 -%} -{% evaluate Location_ID_PV2_1_3 using 'ID/Location' PL: PV2.1.3 -%} -{% evaluate Location_ID_PV2_1_4 using 'ID/Location' PL: PV2.1.4 -%} -{% evaluate Location_ID_PV2_1_7 using 'ID/Location' PL: PV2.1.7 -%} -{% evaluate Location_ID_PV2_1_8 using 'ID/Location' PL: PV2.1.8 -%} - {% evaluate Location_ID_PV1_37 using 'ID/Location' DLD: PV1.37 -%} {% evaluate Practitioner_ID_PV1_7 using 'ID/Practitioner' XCN: PV1.7 -%} @@ -73,337 +38,188 @@ Practitioner_ID_PV1_52: A resource Id, used to fill "participant.individual.refe {% if PV1.45 -%} "status":"finished", {% endif -%} + + {% if Root_Template == "ADT_A11" or Root_Template =="ADT_A27" -%} + "status":"cancelled", + {% endif -%} + {% if Root_Template == "ADT_A13" or Root_Template =="ADT_A15" or Root_Template =="ADT_A16" or Root_Template =="ADT_A25" or Root_Template =="ADT_A26" or Root_Template == "ADT_A01" or Root_Template == "ADT_A02" or Root_Template == "ADT_A04" -%} + "status":"in-progress", + {% endif -%} + {% if Root_Template == "ADT_A03" -%} + "status":"finished", + {% endif -%} + {% if Root_Template == "ADT_A05" or Root_Template =="ADT_A14" -%} + "status":"planned", + {% endif -%} + "location": - [ - { - {% if PV1.2.1.Value != "P" and Location_ID_PV1_3_1 -%} - "status":"active", - {% endif -%} - {% if PV1.2.1.Value == "P" and Location_ID_PV1_3_1 -%} - "status":"planned", - {% endif -%} - "location": - { - {% if PV1.3.1 and Location_ID_PV1_3_1 -%} - "reference":"Location/{{ Location_ID_PV1_3_1 }}", - {% endif -%} - }, - }, - { - {% if PV1.2.1.Value != "P" and Location_ID_PV1_3_2 -%} - "status":"active", - {% endif -%} - {% if PV1.2.1.Value == "P" and Location_ID_PV1_3_2 -%} - "status":"planned", - {% endif -%} - "location": - { - {% if PV1.3.3 and Location_ID_PV1_3_2 -%} - "reference":"Location/{{ Location_ID_PV1_3_2 }}", - {% endif -%} - }, - }, - { - {% if PV1.2.1.Value != "P" and Location_ID_PV1_3_3 -%} - "status":"active", - {% endif -%} - {% if PV1.2.1.Value == "P" and Location_ID_PV1_3_3 -%} - "status":"planned", - {% endif -%} - "location": - { - {% if PV1.3.3 and Location_ID_PV1_3_3 -%} - "reference":"Location/{{ Location_ID_PV1_3_3 }}", + [ + {% if PV1.3 -%} + { + {% if PV1.3.1 -%} + {% evaluate Location_ID_PV1_3 using 'ID/Location' PL: PV1.3.1 -%} + {% elseif PV1.3.2 -%} + {% evaluate Location_ID_PV1_3 using 'ID/Location' PL: PV1.3.2 -%} + {% elseif PV1.3.3 -%} + {% evaluate Location_ID_PV1_3 using 'ID/Location' PL: PV1.3.3 -%} + {% elseif PV1.3.4 -%} + {% evaluate Location_ID_PV1_3 using 'ID/Location' PL: PV1.3.4 -%} + {% elseif PV1.3.7 -%} + {% evaluate Location_ID_PV1_3 using 'ID/Location' PL: PV1.3.7 -%} + {% elseif PV1.3.8 -%} + {% evaluate Location_ID_PV1_3 using 'ID/Location' PL: PV1.3.8 -%} + {% endif %} + + {% unless Root_Template == "ADT_A11" or Root_Template == "ADT_A27" -%} + {% if PV1.2.1.Value != "P" and Location_ID_PV1_3 -%} + "status":"active", {% endif -%} - }, - }, - { - {% if PV1.2.1.Value != "P" and Location_ID_PV1_3_4 -%} - "status":"active", - {% endif -%} - {% if PV1.2.1.Value == "P" and Location_ID_PV1_3_4 -%} - "status":"planned", - {% endif -%} - "location": - { - {% if PV1.3.3 and Location_ID_PV1_3_4 -%} - "reference":"Location/{{ Location_ID_PV1_3_4 }}", + {% if PV1.2.1.Value == "P" and Location_ID_PV1_3 -%} + "status":"planned", {% endif -%} - }, - }, - { - {% if PV1.2.1.Value != "P" and Location_ID_PV1_3_7 -%} + {% endunless -%} + + {% if Root_Template == "ADT_A01" or Root_Template == "ADT_A02" or Root_Template == "ADT_A04" or Root_Template == "ADT_A13" or Root_Template == "ADT_A15" or Root_Template == "ADT_A16" or Root_Template == "ADT_A25" or Root_Template == "ADT_A26" -%} "status":"active", {% endif -%} - {% if PV1.2.1.Value == "P" and Location_ID_PV1_3_7 -%} - "status":"planned", - {% endif -%} - "location": - { - {% if PV1.3.3 and Location_ID_PV1_3_7 -%} - "reference":"Location/{{ Location_ID_PV1_3_7 }}", - {% endif -%} - }, - }, - { - {% if PV1.2.1.Value != "P" and Location_ID_PV1_3_8 -%} - "status":"active", + {% if Root_Template == "ADT_A03" -%} + "status":"completed", {% endif -%} - {% if PV1.2.1.Value == "P" and Location_ID_PV1_3_8 -%} + {% if Root_Template == "ADT_A14" -%} "status":"planned", {% endif -%} + "location": { - {% if PV1.3.3 and Location_ID_PV1_3_8 -%} - "reference":"Location/{{ Location_ID_PV1_3_8 }}", + {% if PV1.3 and Location_ID_PV1_3 -%} + "reference":"Location/{{ Location_ID_PV1_3 }}", {% endif -%} }, }, + {% endif %} - { - {% if PV1.6.1 and Location_ID_PV1_6_1 -%} - "status":"completed", - "location": - { - - "reference":"Location/{{ Location_ID_PV1_6_1 }}", - }, - {% include 'Extensions/TemporaryLocation' , status: 'false' -%} - {% endif -%} - }, - { - {% if PV1.6.2 and Location_ID_PV1_6_2 -%} - "status":"completed", - "location": - { - "reference":"Location/{{ Location_ID_PV1_6_2 }}", - }, - {% include 'Extensions/TemporaryLocation' , status: 'false' -%} - {% endif -%} - }, - { - {% if PV1.6.3 and Location_ID_PV1_6_3 -%} - "status":"completed", - "location": - { - "reference":"Location/{{ Location_ID_PV1_6_3 }}", - }, - {% include 'Extensions/TemporaryLocation' , status: 'false' -%} - {% endif -%} - }, - { - {% if PV1.6.4 and Location_ID_PV1_6_4 -%} - "status":"completed", - "location": - { - "reference":"Location/{{ Location_ID_PV1_6_4 }}", - }, - {% include 'Extensions/TemporaryLocation' , status: 'false' -%} - {% endif -%} - }, - { - {% if PV1.6.7 and Location_ID_PV1_6_7 -%} - "status":"completed", - "location": - { - "reference":"Location/{{ Location_ID_PV1_6_7 }}", - }, - {% include 'Extensions/TemporaryLocation' , status: 'false' -%} - {% endif -%} - }, - { - {% if PV1.6.8 and Location_ID_PV1_6_8 -%} - "status":"completed", - "location": - { - "reference":"Location/{{ Location_ID_PV1_6_8 }}", - }, - {% include 'Extensions/TemporaryLocation' , status: 'false' -%} - {% endif -%} - }, + {% if PV1.6 -%} + { + {% if PV1.6.1 -%} + {% evaluate Location_ID_PV1_6 using 'ID/Location' PL: PV1.6.1 -%} + {% elseif PV1.6.2 -%} + {% evaluate Location_ID_PV1_6 using 'ID/Location' PL: PV1.6.2 -%} + {% elseif PV1.6.3 -%} + {% evaluate Location_ID_PV1_6 using 'ID/Location' PL: PV1.6.3 -%} + {% elseif PV1.6.4 -%} + {% evaluate Location_ID_PV1_6 using 'ID/Location' PL: PV1.6.4 -%} + {% elseif PV1.6.7 -%} + {% evaluate Location_ID_PV1_6 using 'ID/Location' PL: PV1.6.7 -%} + {% elseif PV1.6.8 -%} + {% evaluate Location_ID_PV1_6 using 'ID/Location' PL: PV1.6.8 -%} + {% endif %} - { - {% if PV1.42.1 and Location_ID_PV1_42_1 -%} - "status":"planned", - "location": - { - "reference":"Location/{{ Location_ID_PV1_42_1 }}", - }, - {% include 'Extensions/TemporaryLocation' , status: 'false' -%} - {% endif -%} - }, - { - {% if PV1.42.2 and Location_ID_PV1_42_2 -%} - "status":"planned", + {% if PV1.6 and Location_ID_PV1_6 -%} + {% unless Root_Template == "ADT_A11" or Root_Template == "ADT_A27" -%} + "status":"completed", + {% endunless -%} "location": { - "reference":"Location/{{ Location_ID_PV1_42_2 }}", + "reference":"Location/{{ Location_ID_PV1_6 }}", }, {% include 'Extensions/TemporaryLocation' , status: 'false' -%} {% endif -%} - }, - { - {% if PV1.42.3 and Location_ID_PV1_42_3 -%} - "status":"planned", - "location": - { - "reference":"Location/{{ Location_ID_PV1_42_3 }}", - }, - {% include 'Extensions/TemporaryLocation' , status: 'false' -%} - {% endif -%} - }, - { - {% if PV1.42.4 and Location_ID_PV1_42_4 -%} - "status":"planned", - "location": - { - "reference":"Location/{{ Location_ID_PV1_42_4 }}", - }, - {% include 'Extensions/TemporaryLocation' , status: 'false' -%} - {% endif -%} - }, - { - {% if PV1.42.7 and Location_ID_PV1_42_7 -%} - "status":"planned", - "location": - { - "reference":"Location/{{ Location_ID_PV1_42_7 }}", - }, - {% include 'Extensions/TemporaryLocation' , status: 'false' -%} - {% endif -%} - }, - { - {% if PV1.42.8 and Location_ID_PV1_42_8 -%} - "status":"planned", - "location": - { - "reference":"Location/{{ Location_ID_PV1_42_8 }}", - }, - {% include 'Extensions/TemporaryLocation' , status: 'false' -%} - {% endif -%} - }, - { - {% if PV1.43.1 and Location_ID_PV1_43_1 -%} - "status":"completed", - "location": - { - "reference":"Location/{{ Location_ID_PV1_43_1 }}", - }, - {% include 'Extensions/TemporaryLocation' , status: 'true' -%} - {% endif -%} - }, - { - {% if PV1.43.2 and Location_ID_PV1_43_2 -%} - "status":"completed", - "location": - { - "reference":"Location/{{ Location_ID_PV1_43_2 }}", - }, - {% include 'Extensions/TemporaryLocation' , status: 'true' -%} - {% endif -%} - }, - { - {% if PV1.43.3 and Location_ID_PV1_43_3 -%} - "status":"completed", - "location": - { - "reference":"Location/{{ Location_ID_PV1_43_3 }}", - }, - {% include 'Extensions/TemporaryLocation' , status: 'true' -%} - {% endif -%} - }, - { - {% if PV1.43.4 and Location_ID_PV1_43_4 -%} - "status":"completed", - "location": - { - "reference":"Location/{{ Location_ID_PV1_43_4 }}", - }, - {% include 'Extensions/TemporaryLocation' , status: 'true' -%} - {% endif -%} - }, - { - {% if PV1.43.7 and Location_ID_PV1_43_7 -%} - "status":"completed", - "location": - { - "reference":"Location/{{ Location_ID_PV1_43_7 }}", - }, - {% include 'Extensions/TemporaryLocation' , status: 'true' -%} - {% endif -%} - }, - { - {% if PV1.43.8 and Location_ID_PV1_43_8 -%} - "status":"completed", - "location": - { - "reference":"Location/{{ Location_ID_PV1_43_8 }}", - }, - {% include 'Extensions/TemporaryLocation' , status: 'true' -%} - {% endif -%} }, + {% endif %} + + {% unless Root_Template == "ADT_A26" -%} + {% if PV1.42 -%} + { + {% if PV1.42.1 -%} + {% evaluate Location_ID_PV1_42 using 'ID/Location' PL: PV1.42.1 -%} + {% elseif PV1.42.2 -%} + {% evaluate Location_ID_PV1_42 using 'ID/Location' PL: PV1.42.2 -%} + {% elseif PV1.42.3 -%} + {% evaluate Location_ID_PV1_42 using 'ID/Location' PL: PV1.42.3 -%} + {% elseif PV1.42.4 -%} + {% evaluate Location_ID_PV1_42 using 'ID/Location' PL: PV1.42.4 -%} + {% elseif PV1.42.7 -%} + {% evaluate Location_ID_PV1_42 using 'ID/Location' PL: PV1.42.7 -%} + {% elseif PV1.42.8 -%} + {% evaluate Location_ID_PV1_42 using 'ID/Location' PL: PV1.42.8 -%} + {% endif %} + + {% if PV1.42 and Location_ID_PV1_42 -%} + {% unless Root_Template == "ADT_A11" or Root_Template == "ADT_A27" -%} + "status":"planned", + {% endunless -%} + "location": + { + "reference":"Location/{{ Location_ID_PV1_42 }}", + }, + {% include 'Extensions/TemporaryLocation' , status: 'false' -%} + {% endif -%} + + }, + {% endif %} + {% endunless -%} - { - {% if PV2.1.1 and Location_ID_PV2_1_1 -%} - "status":"planned", - "location": - { - "reference":"Location/{{ Location_ID_PV2_1_1 }}", - }, - {% include 'Extensions/TemporaryLocation' , status: 'false' -%} - {% endif -%} - }, - { - {% if PV2.1.2 and Location_ID_PV2_1_2 -%} - "status":"planned", - "location": - { - "reference":"Location/{{ Location_ID_PV2_1_2 }}", - }, - {% include 'Extensions/TemporaryLocation' , status: 'false' -%} - {% endif -%} - }, - { - {% if PV2.1.3 and Location_ID_PV2_1_3 -%} - "status":"planned", - "location": - { - "reference":"Location/{{ Location_ID_PV2_1_3 }}", - }, - {% include 'Extensions/TemporaryLocation' , status: 'false' -%} - {% endif -%} - }, - { - {% if PV2.1.4 and Location_ID_PV2_1_4 -%} - "status":"planned", - "location": - { - "reference":"Location/{{ Location_ID_PV2_1_4 }}", - }, - {% include 'Extensions/TemporaryLocation' , status: 'false' -%} - {% endif -%} - }, - { - {% if PV2.1.7 and Location_ID_PV2_1_7 -%} - "status":"planned", + {% if PV1.43 -%} + { + {% if PV1.43.1 -%} + {% evaluate Location_ID_PV1_43 using 'ID/Location' PL: PV1.43.1 -%} + {% elseif PV1.43.2 -%} + {% evaluate Location_ID_PV1_43 using 'ID/Location' PL: PV1.43.2 -%} + {% elseif PV1.43.3 -%} + {% evaluate Location_ID_PV1_43 using 'ID/Location' PL: PV1.43.3 -%} + {% elseif PV1.43.4 -%} + {% evaluate Location_ID_PV1_43 using 'ID/Location' PL: PV1.43.4 -%} + {% elseif PV1.43.7 -%} + {% evaluate Location_ID_PV1_43 using 'ID/Location' PL: PV1.43.7 -%} + {% elseif PV1.43.8 -%} + {% evaluate Location_ID_PV1_43 using 'ID/Location' PL: PV1.43.8 -%} + {% endif %} + + {% if PV1.43 and Location_ID_PV1_43 -%} + {% unless Root_Template == "ADT_A11" or Root_Template == "ADT_A27" -%} + "status":"completed", + {% endunless -%} "location": { - "reference":"Location/{{ Location_ID_PV2_1_7 }}", + "reference":"Location/{{ Location_ID_PV1_43 }}", }, - {% include 'Extensions/TemporaryLocation' , status: 'false' -%} + {% include 'Extensions/TemporaryLocation' , status: 'true' -%} {% endif -%} + }, - { - {% if PV2.1.8 and Location_ID_PV2_1_8 -%} - "status":"planned", - "location": - { - "reference":"Location/{{ Location_ID_PV2_1_8 }}", - }, - {% include 'Extensions/TemporaryLocation' , status: 'false' -%} - {% endif -%} - } + {% endif %} + + {% unless Root_Template == "ADT_A26" -%} + {% if PV2.1 -%} + { + {% if PV2.1.1 -%} + {% evaluate Location_ID_PV2_1 using 'ID/Location' PL: PV2.1.1 -%} + {% elseif PV2.1.2 -%} + {% evaluate Location_ID_PV2_1 using 'ID/Location' PL: PV2.1.2 -%} + {% elseif PV2.1.3 -%} + {% evaluate Location_ID_PV2_1 using 'ID/Location' PL: PV2.1.3 -%} + {% elseif PV2.1.4 -%} + {% evaluate Location_ID_PV2_1 using 'ID/Location' PL: PV2.1.4 -%} + {% elseif PV2.1.7 -%} + {% evaluate Location_ID_PV2_1 using 'ID/Location' PL: PV2.1.7 -%} + {% elseif PV2.1.8 -%} + {% evaluate Location_ID_PV2_1 using 'ID/Location' PL: PV2.1.8 -%} + {% endif %} + + {% if PV2.1 and Location_ID_PV2_1 -%} + {% unless Root_Template == "ADT_A11" or Root_Template == "ADT_A27" -%} + "status":"planned", + {% endunless -%} + "location": + { + "reference":"Location/{{ Location_ID_PV2_1 }}", + }, + {% include 'Extensions/TemporaryLocation' , status: 'false' -%} + {% endif -%} + }, + {% endif %} + {% endunless -%} ], "type": [ @@ -636,8 +452,19 @@ Practitioner_ID_PV1_52: A resource Id, used to fill "participant.individual.refe ], "period": { + "start":"{{ PV1.44.Value | format_as_date_time }}", - "end":"{{ PV1.45.Value | format_as_date_time }}", + + {% unless Root_Template == "ADT_A25" or Root_Template == "ADT_A13" -%} + "end":"{{ PV1.45.Value | format_as_date_time }}", + {% endunless -%} + {% if Root_Template == "ADT_A05" or Root_Template == "ADT_A14" or Root_Template == "ADT_A04" or Root_Template == "ADT_A11" or Root_Template == "ADT_A27" -%} + "start":"{{ PV2.8.Value | format_as_date_time }}", + "end":"{{ PV2.9.Value | format_as_date_time }}", + {% endif -%} + {% if Root_Template == "ADT_A16" -%} + "end":"{{ PV2.9.Value | format_as_date_time }}", + {% endif -%} }, "reasonCode": [ @@ -702,6 +529,9 @@ Practitioner_ID_PV1_52: A resource Id, used to fill "participant.individual.refe }, "request":{ "method":"PUT", + {% if Root_Template == "ADT_A29" -%} + "method":"DELETE", + {% endif -%} "url":"Encounter/{{ ID }}", }, }, diff --git a/data/Templates/Hl7v2/Resource/_EpisodeOfCare.liquid b/data/Templates/Hl7v2/Resource/_EpisodeOfCare.liquid index 585a4cd38..39827da14 100644 --- a/data/Templates/Hl7v2/Resource/_EpisodeOfCare.liquid +++ b/data/Templates/Hl7v2/Resource/_EpisodeOfCare.liquid @@ -4,11 +4,25 @@ "resourceType": "EpisodeOfCare", "id":"{{ ID }}", {% if PV1.45 == null -%} - "status": "{{ PV1.2.Value | get_property: 'CodeSystem/EncounterStatus', 'code' }}", + "status": "{{ PV1.2.Value | get_property: 'CodeSystem/EpisodeOfCareStatus', 'code' }}", {% endif -%} {% if PV1.45 -%} "status":"finished", {% endif -%} + + {% if Root_Template == "ADT_A11" or Root_Template =="ADT_A27" -%} + "status":"cancelled", + {% endif -%} + {% if Root_Template == "ADT_A13" or Root_Template =="ADT_A15" or Root_Template =="ADT_A16" or Root_Template =="ADT_A25" or Root_Template =="ADT_A26" or Root_Template == "ADT_A01" or Root_Template == "ADT_A02" or Root_Template == "ADT_A04" -%} + "status":"active", + {% endif -%} + {% if Root_Template == "ADT_A03" -%} + "status":"finished", + {% endif -%} + {% if Root_Template == "ADT_A05" or Root_Template =="ADT_A14" -%} + "status":"planned", + {% endif -%} + "identifier": [ { @@ -46,6 +60,9 @@ }, "request":{ "method":"PUT", + {% if Root_Template == "ADT_A29" -%} + "method":"DELETE", + {% endif -%} "url":"EpisodeOfCare/{{ ID }}", }, }, diff --git a/data/Templates/Hl7v2/Resource/_Location.liquid b/data/Templates/Hl7v2/Resource/_Location.liquid index bb0a00b56..b38d99ffb 100644 --- a/data/Templates/Hl7v2/Resource/_Location.liquid +++ b/data/Templates/Hl7v2/Resource/_Location.liquid @@ -25,6 +25,9 @@ }, "request":{ "method":"PUT", + {% if Root_Template == "ADT_A29" -%} + "method":"DELETE", + {% endif -%} "url":"Location/{{ ID }}", }, }, diff --git a/data/Templates/Hl7v2/Resource/_MessageHeader.liquid b/data/Templates/Hl7v2/Resource/_MessageHeader.liquid index 8f31e6c8a..90e0ef9a5 100644 --- a/data/Templates/Hl7v2/Resource/_MessageHeader.liquid +++ b/data/Templates/Hl7v2/Resource/_MessageHeader.liquid @@ -109,6 +109,9 @@ MessageHeader_Response_Details_ID: A resource Id, used to fill "response.details }, "request":{ "method":"PUT", + {% if Root_Template == "ADT_A29" -%} + "method":"DELETE", + {% endif -%} "url":"MessageHeader/{{ ID }}", }, }, diff --git a/data/Templates/Hl7v2/Resource/_Observation.liquid b/data/Templates/Hl7v2/Resource/_Observation.liquid index 08dca6a2c..ca8c46626 100644 --- a/data/Templates/Hl7v2/Resource/_Observation.liquid +++ b/data/Templates/Hl7v2/Resource/_Observation.liquid @@ -48,7 +48,14 @@ Observation_Specimen_ID: A resource Id, used to fill "specimen.reference" proper { {% include 'DataType/CWECodeableConcept' CWE: OBX.3 -%} }, - + "basedOn": + [ + { + {% if Observation_ServiceRequest_ID %} + "reference":"ServiceRequest/{{ Observation_ServiceRequest_ID }}", + {% endif %} + }, + ], {% if OBX.11.1.Value == 'X' or OBX.11.1.Value == 'N' %} "dataAbsentReason" : { "coding" : [ @@ -365,26 +372,29 @@ Observation_Specimen_ID: A resource Id, used to fill "specimen.reference" proper }, {% endfor %} ], - - - - {%- comment -%} + "specimen": + { + {% if Observation_Specimen_ID %} + "reference":"{{ Observation_Specimen_ID }}", + {% endif %} + }, "subject": { "reference":"{{ Observation_Subject_ID }}", }, + {%- comment -%} "encounter": { "reference":"{{ Observation_Encounter_ID }}", }, - "specimen": - { - "reference":"{{ Observation_Specimen_ID }}", - }, - {%- endcomment -%} + {%- endcomment -%} + }, "request":{ "method":"PUT", + {% if Root_Template == "ADT_A29" -%} + "method":"DELETE", + {% endif -%} "url":"Observation/{{ ID }}", }, }, diff --git a/data/Templates/Hl7v2/Resource/_Organization.liquid b/data/Templates/Hl7v2/Resource/_Organization.liquid index a888197bc..ab3fbe5db 100644 --- a/data/Templates/Hl7v2/Resource/_Organization.liquid +++ b/data/Templates/Hl7v2/Resource/_Organization.liquid @@ -22,11 +22,43 @@ {% if MSHXON2 -%} {% include 'DataType/XONOrganization' XON: MSHXON2 -%} {% endif -%} + + {% if OBR_NTE -%} + {% include 'DataType/HDOrganization_InternalValue' HD: OBR_NTE -%} + {% endif -%} + + {% if OBX_NTE -%} + {% include 'DataType/HDOrganization_InternalValue' HD: OBX_NTE -%} + {% endif -%} {% if OBX_23 -%} {% include 'DataType/XONOrganization' XON: OBX_23 -%} {% endif -%} + {% if OBR_SEG_10 %} + {% include 'DataType/HDOrganization_InternalValue' HD: OBR_SEG_10 -%} + {% endif %} + + {% if OBR_SEG_16 %} + {% include 'DataType/HDOrganization_InternalValue' HD: OBR_SEG_16 -%} + {% endif %} + + {% if OBR_SEG_34 %} + {% include 'DataType/HDOrganization_InternalValue' HD: OBR_SEG_34 -%} + {% endif %} + + {% if OBR_SEG_35 %} + {% include 'DataType/HDOrganization_InternalValue' HD: OBR_SEG_35 -%} + {% endif %} + + {% if ORC_SEG.21 %} + {% include 'DataType/XONOrganization' XON: ORC_SEG.21 -%} + {% endif %} + + {% if SPM -%} + {% include 'DataType/HDOrganization_InternalValue' HD: SPM -%} + {% endif -%} + {% if PID -%} {% include 'DataType/HDOrganization_InternalValue' HD: PID.4 -%} {% endif -%} @@ -51,6 +83,10 @@ {% include 'DataType/HDOrganization_InternalValue' HD: IN2_61.4 -%} {% endif -%} + {% if TXA -%} + {% include 'DataType/HDOrganization_InternalValue' HD: TXA -%} + {% endif -%} + {% if PV1 -%} {% include 'DataType/HDOrganization_InternalValue' HD: PV1 -%} {% endif -%} @@ -126,6 +162,8 @@ {% include 'DataType/XONOrganization' XON: IN2_70.70.Repeats[0] -%} {% endif -%} + {% include 'DataType/HDOrganization_InternalValue' HD: AIP -%} + {% if MSHHD1 %} {% if MSH.22 and organization_ID_MSH_22 -%} "partOf": @@ -146,23 +184,27 @@ [ { "country":"{{ MSH.17.Value | get_property: 'CodeSystem/Countries', 'code' }}", - }, + }, + { + {% if ORC_SEG_22 %} + {% for orc22 in ORC_SEG_22.Repeats %} + {% include 'DataType/XADAddress' XAD: orc22 -%} + {% endfor -%} + {% endif %} + }, + { + {% include 'DataType/XAD' XAD: OBX_ORU.24 -%} + }, { {% if OBX_24 -%} {% include 'DataType/XADAddress' XAD: OBX_24 -%} {% endif -%} }, - { - {% include 'DataType/XAD' XAD: OBX_ORU.24 -%} - }, {% if OBX_ORU.25 -%} { {% include 'DataType/XAD' XAD: OBX_ORU.24 -%} }, {% endif -%} - { - {% include 'DataType/XAD' XAD: ORC.22.Repeats[0] -%} - }, {% for gt1_5 in GT1.5.Repeats -%} { {% include 'DataType/XAD' XAD: gt1_5 -%} @@ -198,6 +240,11 @@ {% include 'DataType/XTN' XTN: gt1_46 -%} }, {% endfor -%} + {% for orc23 in ORC_SEG_23.Repeats -%} + { + {% include 'DataType/XTN' XTN: orc23 -%} + }, + {% endfor -%} ], "address": { @@ -254,9 +301,6 @@ ], "telecom": [ - { - {% include 'DataType/XTN' XTN: ORC.23.Repeats[0] -%} - }, {% for gt1_6 in GT1.6.Repeats -%} { {% include 'DataType/XTN' XTN: gt1_6 -%} @@ -340,6 +384,9 @@ }, "request":{ "method":"PUT", + {% if Root_Template == "ADT_A29" -%} + "method":"DELETE", + {% endif -%} "url":"Organization/{{ ID }}", }, }, diff --git a/data/Templates/Hl7v2/Resource/_PLLocation.liquid b/data/Templates/Hl7v2/Resource/_PLLocation.liquid index 8d2178341..9c5644e64 100644 --- a/data/Templates/Hl7v2/Resource/_PLLocation.liquid +++ b/data/Templates/Hl7v2/Resource/_PLLocation.liquid @@ -17,6 +17,19 @@ {% endif %} {% include 'DataType/PL_HDLocation' HD: PL.1 -%}, "mode":"instance", + {% assign PLValue= PL.Value%} + {% capture textstring %}{{ PLValue | split: "^" | join: "--" }}{% endcapture -%} + {% capture specomp %}{{ textstring | split: "~" | join: "+" }}{% endcapture -%} + {% capture description %}{{ specomp | split: "&" | join: "--" }}{% endcapture -%} + "description" : "{{ description }}", + "alias" : [ + "{{NTE.3.Value}}", + ], + "type" : [ + { + {% include 'DataType/CWECodeableConcept' mapping: 'CodeSystem/LocationRoleType', CWE: AIL_4 -%} + }, + ], "physicalType":{ "coding":[ { @@ -28,6 +41,9 @@ }, "request":{ "method":"PUT", + {% if Root_Template == "ADT_A29" -%} + "method":"DELETE", + {% endif -%} "url":"Location/{{ locationId_PL_1 }}", }, }, @@ -45,6 +61,19 @@ {% endif %} {% include 'DataType/PL_HDLocation' HD: PL.2 -%}, "mode":"instance", + {% assign PLValue= PL.Value%} + {% capture textstring %}{{ PLValue | split: "^" | join: "--" }}{% endcapture -%} + {% capture specomp %}{{ textstring | split: "~" | join: "+" }}{% endcapture -%} + {% capture description %}{{ specomp | split: "&" | join: "--" }}{% endcapture -%} + "description" : "{{ description }}", + "alias" : [ + "{{NTE.3.Value}}", + ], + "type" : [ + { + {% include 'DataType/CWECodeableConcept' mapping: 'CodeSystem/LocationRoleType', CWE: AIL_4 -%} + }, + ], "physicalType":{ "coding":[ { @@ -56,6 +85,9 @@ }, "request":{ "method":"PUT", + {% if Root_Template == "ADT_A29" -%} + "method":"DELETE", + {% endif -%} "url":"Location/{{ locationId_PL_2 }}", }, }, @@ -73,6 +105,19 @@ {% endif %} {% include 'DataType/PL_HDLocation' HD: PL.3 -%}, "mode":"instance", + {% assign PLValue= PL.Value%} + {% capture textstring %}{{ PLValue | split: "^" | join: "--" }}{% endcapture -%} + {% capture specomp %}{{ textstring | split: "~" | join: "+" }}{% endcapture -%} + {% capture description %}{{ specomp | split: "&" | join: "--" }}{% endcapture -%} + "description" : "{{ description }}", + "alias" : [ + "{{NTE.3.Value}}", + ], + "type" : [ + { + {% include 'DataType/CWECodeableConcept' mapping: 'CodeSystem/LocationRoleType', CWE: AIL_4 -%} + }, + ], "physicalType":{ "coding":[ { @@ -84,6 +129,9 @@ }, "request":{ "method":"PUT", + {% if Root_Template == "ADT_A29" -%} + "method":"DELETE", + {% endif -%} "url":"Location/{{ locationId_PL_3 }}", }, }, @@ -96,6 +144,19 @@ "id":"{{ locationId_PL_4 }}", {% include 'DataType/PL_HDLocation' HD: PL.4 -%}, "mode":"instance", + {% assign PLValue= PL.Value%} + {% capture textstring %}{{ PLValue | split: "^" | join: "--" }}{% endcapture -%} + {% capture specomp %}{{ textstring | split: "~" | join: "+" }}{% endcapture -%} + {% capture description %}{{ specomp | split: "&" | join: "--" }}{% endcapture -%} + "description" : "{{ description }}", + "alias" : [ + "{{NTE.3.Value}}", + ], + "type" : [ + { + {% include 'DataType/CWECodeableConcept' mapping: 'CodeSystem/LocationRoleType', CWE: AIL_4 -%} + }, + ], "physicalType":{ "coding":[ { @@ -107,6 +168,9 @@ }, "request":{ "method":"PUT", + {% if Root_Template == "ADT_A29" -%} + "method":"DELETE", + {% endif -%} "url":"Location/{{ locationId_PL_4 }}", }, }, @@ -124,6 +188,19 @@ {% endif %} {% include 'DataType/PL_HDLocation' HD: PL.7 -%}, "mode":"instance", + {% assign PLValue= PL.Value%} + {% capture textstring %}{{ PLValue | split: "^" | join: "--" }}{% endcapture -%} + {% capture specomp %}{{ textstring | split: "~" | join: "+" }}{% endcapture -%} + {% capture description %}{{ specomp | split: "&" | join: "--" }}{% endcapture -%} + "description" : "{{ description }}", + "alias" : [ + "{{NTE.3.Value}}", + ], + "type" : [ + { + {% include 'DataType/CWECodeableConcept' mapping: 'CodeSystem/LocationRoleType', CWE: AIL_4 -%} + }, + ], "physicalType":{ "coding":[ { @@ -135,6 +212,9 @@ }, "request":{ "method":"PUT", + {% if Root_Template == "ADT_A29" -%} + "method":"DELETE", + {% endif -%} "url":"Location/{{ locationId_PL_7 }}", }, }, @@ -152,6 +232,19 @@ {% endif %} {% include 'DataType/PL_HDLocation' HD: PL.8 -%}, "mode":"instance", + {% assign PLValue= PL.Value%} + {% capture textstring %}{{ PLValue | split: "^" | join: "--" }}{% endcapture -%} + {% capture specomp %}{{ textstring | split: "~" | join: "+" }}{% endcapture -%} + {% capture description %}{{ specomp | split: "&" | join: "--" }}{% endcapture -%} + "description" : "{{ description }}", + "alias" : [ + "{{NTE.3.Value}}", + ], + "type" : [ + { + {% include 'DataType/CWECodeableConcept' mapping: 'CodeSystem/LocationRoleType', CWE: AIL_4 -%} + }, + ], "physicalType":{ "coding":[ { @@ -163,6 +256,9 @@ }, "request":{ "method":"PUT", + {% if Root_Template == "ADT_A29" -%} + "method":"DELETE", + {% endif -%} "url":"Location/{{ locationId_PL_8 }}", }, }, @@ -183,15 +279,17 @@ "code":"lvl" } ] - }, + }, }, "request":{ "method":"PUT", + {% if Root_Template == "ADT_A29" -%} + "method":"DELETE", + {% endif -%} "url":"Location/{{ ID }}", }, }, {% endif -%} - {% if PL_2 -%} { "fullUrl":"urn:uuid:{{ ID }}", @@ -211,7 +309,10 @@ }, "request":{ "method":"PUT", + {% if Root_Template == "ADT_A29" -%} + "method":"DELETE", + {% endif -%} "url":"Location/{{ ID }}", }, }, -{% endif -%} \ No newline at end of file +{% endif -%} diff --git a/data/Templates/Hl7v2/Resource/_Patient.liquid b/data/Templates/Hl7v2/Resource/_Patient.liquid index 48eb50c36..5b1f44b6d 100644 --- a/data/Templates/Hl7v2/Resource/_Patient.liquid +++ b/data/Templates/Hl7v2/Resource/_Patient.liquid @@ -402,6 +402,7 @@ Patient_ManagingOrganization_ID: A resource Id, used to fill "managingOrganizati {% if NK1_PER.7.1.Value == "E" -%} {% include 'DataType/XPN' XPN: GT1.16.Repeats[0] -%} {% endif -%} + {% include 'DataType/XPN' XPN: CTD.2.Repeats[0] -%} }, "address": { @@ -409,6 +410,7 @@ Patient_ManagingOrganization_ID: A resource Id, used to fill "managingOrganizati {% if NK1_PER.7.1.Value == "E" -%} {% include 'DataType/XAD' XAD: GT1.17.Repeats[0] -%} {% endif -%} + {% include 'DataType/XAD' XAD: CTD.3.Repeats[0] -%} }, "telecom": [ @@ -434,12 +436,22 @@ Patient_ManagingOrganization_ID: A resource Id, used to fill "managingOrganizati { {% include 'DataType/XTN' XTN: NK1.41 -%} }, + {% for ctd5 in CTD.5.Repeats -%} + { + {% include 'DataType/XTN' XTN: ctd5 -%} + }, + {% endfor -%} ], "relationship": [ { {% include 'DataType/CWECodeableConcept' mapping: 'CodeSystem/ContactRole', CWE: NK1.7 -%} }, + {% for ctd1 in CTD.1.Repeats -%} + { + {% include 'DataType/CWECodeableConcept' mapping: 'CodeSystem/ContactRole', CWE: ctd1 -%} + }, + {% endfor -%} ], "period": { @@ -506,6 +518,9 @@ Patient_ManagingOrganization_ID: A resource Id, used to fill "managingOrganizati }, "request":{ "method":"PUT", + {% if Root_Template == "ADT_A29" -%} + "method":"DELETE", + {% endif -%} "url":"Patient/{{ ID }}", }, }, diff --git a/data/Templates/Hl7v2/Resource/_Practitioner.liquid b/data/Templates/Hl7v2/Resource/_Practitioner.liquid index 07437619b..dc4ef469f 100644 --- a/data/Templates/Hl7v2/Resource/_Practitioner.liquid +++ b/data/Templates/Hl7v2/Resource/_Practitioner.liquid @@ -23,6 +23,13 @@ "address": [ + {% if ORC_SEG_24 %} + {% for orc24 in ORC_SEG_24.Repeats %} + { + {% include 'DataType/XAD' XAD: orc24 -%} + }, + {% endfor -%} + {% endif %} { {% include 'DataType/XAD' XAD: ROL.11 -%} }, @@ -32,11 +39,58 @@ { {% include 'DataType/XAD' XAD: ORC.24.Repeats[0] -%} }, + {% for sch_14 in SCH_12.14.Repeats -%} + { + {% include 'DataType/XAD' XAD: sch_14 -%} + }, + {% endfor -%} + {% for sch_18 in SCH_16.18.Repeats -%} + { + {% include 'DataType/XAD' XAD: sch_18 -%} + }, + {% endfor -%} ], - + "telecom": + [ + {% for sch_13 in SCH_12.13.Repeats -%} + { + {% include 'DataType/XTN' XTN: sch_13 -%} + }, + {% endfor -%} + {% for sch_17 in SCH_16.17.Repeats -%} + { + {% include 'DataType/XTN' XTN: sch_17 -%} + }, + {% endfor -%} + {% for sch_21 in SCH_20.21.Repeats -%} + { + {% include 'DataType/XTN' XTN: sch_21 -%} + }, + {% endfor -%} + ], {% if OBXXCN1 %} {% include 'DataType/XCNPractitioner' XCN: OBXXCN1 -%} {% endif %} + {% if OBR_SEG %} + {% include 'DataType/XCNPractitioner' XCN: OBRXCN_10 -%} + {% endif %} + {% if OBR_SEG %} + {% include 'DataType/XCNPractitioner' XCN: OBRXCN_16 -%} + {% endif %} + + {% if ORC_SEG %} + {% include 'DataType/XCNPractitioner' XCN: ORCXCN_12 -%} + {% endif %} + + {% if CNN_OBR_32 %} + {% include 'DataType/CNN' CNN_val: CNN_OBR_32.1 -%} + {% endif %} + {% if CNN_OBR_34_1 %} + {% include 'DataType/CNN' CNN_val: CNN_OBR_34_1 -%} + {% endif %} + {% if CNN_OBR_35_1 %} + {% include 'DataType/CNN' CNN_val: CNN_OBR_35_1 -%} + {% endif %} {% include 'DataType/XCNPractitioner' XCN: DG1.16.Repeats[0] -%} {% include 'DataType/XCNPractitioner' XCN: PR1 -%} {% include 'DataType/XCNPractitioner' XCN: ORC.10 -%} @@ -50,6 +104,11 @@ {% include 'DataType/XCNPractitioner' XCN: NTE -%} {% include 'DataType/XCNPractitioner' XCN: RF1 -%} {% include 'DataType/XCNPractitioner' XCN: IAM -%} + {% include 'DataType/XCNPractitioner' XCN: AIP -%} + {% include 'DataType/XCNPractitioner' XCN: SCH_12.12.Repeats[0] -%} + {% include 'DataType/XCNPractitioner' XCN: SCH_16.16.Repeats[0] -%} + {% include 'DataType/XCNPractitioner' XCN: SCH_20.20.Repeats[0] -%} + {% include 'DataType/XCNPractitioner' XCN: TXA -%} {% if IAM_NAME -%} @@ -62,6 +121,9 @@ }, "request":{ "method":"PUT", + {% if Root_Template == "ADT_A29" -%} + "method":"DELETE", + {% endif -%} "url":"Practitioner/{{ ID }}", }, }, diff --git a/data/Templates/Hl7v2/Resource/_PractitionerRole.liquid b/data/Templates/Hl7v2/Resource/_PractitionerRole.liquid index 37086e05f..c5957de8b 100644 --- a/data/Templates/Hl7v2/Resource/_PractitionerRole.liquid +++ b/data/Templates/Hl7v2/Resource/_PractitionerRole.liquid @@ -13,8 +13,33 @@ Organization_ID_ORC_21: A resource Id, used to fill "organization.reference" pro "resource":{ "resourceType": "PractitionerRole", "id":"{{ ID }}", - {% include 'DataType/XCNPractitionerRole' XCN: PD1.4 -%} - + {% include 'DataType/XCNPractitionerRole' XCN: PD1.4 -%} + {% include 'DataType/NDLPractitionerRole' NDL: OBR_32 -%} + {% if OBR_34 %} + "code": [ + { + "coding": [ + { + "code": "TECH", + }, + ], + } + ], + {% include 'DataType/NDLPractitionerRole' NDL: OBR_34 -%} + {% endif %} + {% if OBR_35 %} + "code": [ + { + "coding": [ + { + "code": "TRANS", + }, + ], + } + ], + {% include 'DataType/NDLPractitionerRole' NDL: OBR_35 -%} + {% endif %} + "identifier": [ { @@ -39,9 +64,29 @@ Organization_ID_ORC_21: A resource Id, used to fill "organization.reference" pro "system" : "http://example.com/v2-to-fhir-converter/PractitionerRole", } {% endif %} + {% if SCH_12.12 %} + { + "code" : "placer-contact", + "display" : "Placer Contact", + "system" : "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role", + } + {% endif %} + {% if SCH_16.16 %} + { + "code" : "filler-contact", + "display" : "Filler Contact", + "system" : "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role", + } + {% endif %} + {% if SCH_20.20 %} + { + "code" : "enterer", + "display" : "Enterer", + "system" : "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role", + } + {% endif %} ], - }, - + }, { {% include 'DataType/CWECodeableConcept' mapping: 'CodeSystem/Role', CWE: ROL.3 -%} {% include 'DataType/CWECodeableConcept' mapping: 'CodeSystem/Participation', CWE: ROL.4 -%} @@ -73,6 +118,105 @@ Organization_ID_ORC_21: A resource Id, used to fill "organization.reference" pro "reference":"Location/{{ Location_ID_ROL_13 }}", {% endif -%} }, + {% if SCH_12.15 -%} + {% if SCH_12.15.1 -%} + { + {% evaluate Location_ID_SCH_12 using 'ID/Location' PL: SCH_12.15.1 -%} + "reference":"Location/{{ Location_ID_SCH_12 }}", + }, + {% elseif SCH_12.15.2 -%} + { + {% evaluate Location_ID_SCH_12 using 'ID/Location' PL: SCH_12.15.2 -%} + "reference":"Location/{{ Location_ID_SCH_12 }}", + }, + {% elseif SCH_12.15.3 -%} + { + {% evaluate Location_ID_SCH_12 using 'ID/Location' PL: SCH_12.15.3 -%} + "reference":"Location/{{ Location_ID_SCH_12 }}", + }, + {% elseif SCH_12.15.4 -%} + { + {% evaluate Location_ID_SCH_12 using 'ID/Location' PL: SCH_12.15.4 -%} + "reference":"Location/{{ Location_ID_SCH_12 }}", + }, + {% elseif SCH_12.15.7 -%} + { + {% evaluate Location_ID_SCH_12 using 'ID/Location' PL: SCH_12.15.7 -%} + "reference":"Location/{{ Location_ID_SCH_12 }}", + }, + {% elseif SCH_12.15.8 -%} + { + {% evaluate Location_ID_SCH_12 using 'ID/Location' PL: SCH_12.15.8 -%} + "reference":"Location/{{ Location_ID_SCH_12 }}", + }, + {% endif %} + {% endif %} + {% if SCH_16.19 -%} + {% if SCH_16.19.1 -%} + { + {% evaluate Location_ID_SCH_16 using 'ID/Location' PL: SCH_16.19.1 -%} + "reference":"Location/{{ Location_ID_SCH_16 }}", + }, + {% elseif SCH_16.19.2 -%} + { + {% evaluate Location_ID_SCH_16 using 'ID/Location' PL: SCH_16.19.2 -%} + "reference":"Location/{{ Location_ID_SCH_16 }}", + }, + {% elseif SCH_16.19.3 -%} + { + {% evaluate Location_ID_SCH_16 using 'ID/Location' PL: SCH_16.19.3 -%} + "reference":"Location/{{ Location_ID_SCH_16 }}", + }, + {% elseif SCH_16.19.4 -%} + { + {% evaluate Location_ID_SCH_16 using 'ID/Location' PL: SCH_16.19.4 -%} + "reference":"Location/{{ Location_ID_SCH_16 }}", + }, + {% elseif SCH_16.19.7 -%} + { + {% evaluate Location_ID_SCH_16 using 'ID/Location' PL: SCH_16.19.7 -%} + "reference":"Location/{{ Location_ID_SCH_16 }}", + }, + {% elseif SCH_16.19.8 -%} + { + {% evaluate Location_ID_SCH_16 using 'ID/Location' PL: SCH_16.19.8 -%} + "reference":"Location/{{ Location_ID_SCH_16 }}", + }, + {% endif %} + {% endif -%} + {% if SCH_20.22 -%} + {% if SCH_20.22.1 -%} + { + {% evaluate Location_ID_SCH_20 using 'ID/Location' PL: SCH_20.22.1 -%} + "reference":"Location/{{ Location_ID_SCH_20 }}", + }, + {% elseif SCH_20.22.2 -%} + { + {% evaluate Location_ID_SCH_20 using 'ID/Location' PL: SCH_20.22.2 -%} + "reference":"Location/{{ Location_ID_SCH_20 }}", + }, + {% elseif SCH_20.22.3 -%} + { + {% evaluate Location_ID_SCH_20 using 'ID/Location' PL: SCH_20.22.3 -%} + "reference":"Location/{{ Location_ID_SCH_20 }}", + }, + {% elseif SCH_20.22.4 -%} + { + {% evaluate Location_ID_SCH_20 using 'ID/Location' PL: SCH_20.22.4 -%} + "reference":"Location/{{ Location_ID_SCH_20 }}", + }, + {% elseif SCH_20.22.7 -%} + { + {% evaluate Location_ID_SCH_20 using 'ID/Location' PL: SCH_20.22.7 -%} + "reference":"Location/{{ Location_ID_SCH_20 }}", + }, + {% elseif SCH_20.22.8 -%} + { + {% evaluate Location_ID_SCH_20 using 'ID/Location' PL: SCH_20.22.8 -%} + "reference":"Location/{{ Location_ID_SCH_20 }}", + }, + {% endif %} + {% endif -%} ], {% include 'DataType/XCNPractitionerRole' XCN: ROL.4 -%} @@ -81,8 +225,8 @@ Organization_ID_ORC_21: A resource Id, used to fill "organization.reference" pro {% if PRT.8 and Organization_ID_PRT_8 -%} "reference":"Organization/{{ Organization_ID_PRT_8 }}", {% endif -%} - {% if ORC.21 and Organization_ID_ORC_21 -%} - "reference":"Organization/{{ Organization_ID_ORC_21 }}", + {% if requestor_organization %} + "reference":"Organization/{{requestor_organization}}", {% endif -%} }, {% include 'DataType/XCNPractitionerRole' XCN: PRT.5.Repeats[0] -%} @@ -92,13 +236,38 @@ Organization_ID_ORC_21: A resource Id, used to fill "organization.reference" pro {% include 'DataType/CWECodeableConcept' CWE: PRT.6 -%} }, ], + {%- comment -%} {% include 'DataType/XCNPractitionerRole' XCN: ORC.12.Repeats[0] -%} - {% include 'DataType/NDLPractitionerRole' NDL: OBR.32 -%} - {% include 'DataType/NDLPractitionerRole' NDL: OBR.34 -%} - {% include 'DataType/NDLPractitionerRole' NDL: OBR.35 -%} + {%- endcomment -%} + "practitioner" : { + {% if requestor_practitioner1 %} + "reference":"Practitioner/{{requestor_practitioner1}}", + {% elsif requestor_practitioner2 %} + "reference":"Practitioner/{{requestor_practitioner2}}", + {% endif %} + {% if collection_collector_practitioner %} + "reference":"Practitioner/{{collection_collector_practitioner}}", + {% endif %} + {% if REF_SCH_12 -%} + "reference":"Practitioner/{{REF_SCH_12}}", + {% endif -%} + {% if REF_SCH_16 -%} + "reference":"Practitioner/{{ REF_SCH_16 }}", + {% endif -%} + {% if REF_SCH_20 -%} + "reference":"Practitioner/{{ REF_SCH_20 }}", + {% endif -%} + {% if practitionerId_TXA -%} + "reference":"Practitioner/{{ practitionerId_TXA }}", + {% endif -%} + + }, }, "request":{ "method":"PUT", + {% if Root_Template == "ADT_A29" -%} + "method":"DELETE", + {% endif -%} "url":"PractitionerRole/{{ ID }}", }, }, diff --git a/data/Templates/Hl7v2/Resource/_Procedure.liquid b/data/Templates/Hl7v2/Resource/_Procedure.liquid index 617289fbb..646e7bd78 100644 --- a/data/Templates/Hl7v2/Resource/_Procedure.liquid +++ b/data/Templates/Hl7v2/Resource/_Procedure.liquid @@ -12,8 +12,6 @@ Procedure_Asserter_ID: A resource Id, used to fill "asserter.reference" property {% evaluate Practitioner_ID_PR1_11 using 'ID/Practitioner' XCN: PR1.11 -%} {% evaluate Practitioner_ID_PR1_12 using 'ID/Practitioner' XCN: PR1.12 -%} {% evaluate Procedure_ID_PR1_25 using 'ID/Procedure' PR1: PR1.25, baseId: Procedure_Subject_ID -%} -{% evaluate Location_ID_PR1_23_1 using 'ID/Location' PL: PR1.23.1 -%} -{% evaluate Location_ID_PR1_23_2 using 'ID/Location' PL: PR1.23.2 -%} { "fullUrl":"urn:uuid:{{ ID }}", @@ -124,15 +122,28 @@ Procedure_Asserter_ID: A resource Id, used to fill "asserter.reference" property }, ], "location": - { - {% if PR1.23.1 -%} - "reference":"Location/{{ Location_ID_PR1_23_1 }}", - {% else %} - {% if PR1.23.2 %} - "reference":"Location/{{ Location_ID_PR1_23_2 }}", + { + {% if PR1.23 -%} + {% if PR1.23.1 -%} + {% evaluate Location_ID_PR1_23 using 'ID/Location' PL: PR1.23.1 -%} + {% elseif PR1.23.2 -%} + {% evaluate Location_ID_PR1_23 using 'ID/Location' PL: PR1.23.2 -%} + {% elseif PR1.23.3 -%} + {% evaluate Location_ID_PR1_23 using 'ID/Location' PL: PR1.23.3 -%} + {% elseif PR1.23.4 -%} + {% evaluate Location_ID_PR1_23 using 'ID/Location' PL: PR1.23.4 -%} + {% elseif PR1.23.7 -%} + {% evaluate Location_ID_PR1_23 using 'ID/Location' PL: PR1.23.7 -%} + {% elseif PR1.23.8 -%} + {% evaluate Location_ID_PR1_23 using 'ID/Location' PL: PR1.23.8 -%} + {% endif %} + + {% if PR1.23 and Location_ID_PR1_23 -%} + "reference":"Location/{{ Location_ID_PR1_23 }}", + {% endif -%} {% endif %} - {% endif %} - }, + }, + "partOf": [ { diff --git a/data/Templates/Hl7v2/Resource/_Provenance.liquid b/data/Templates/Hl7v2/Resource/_Provenance.liquid index d600f22c1..52df045c2 100644 --- a/data/Templates/Hl7v2/Resource/_Provenance.liquid +++ b/data/Templates/Hl7v2/Resource/_Provenance.liquid @@ -268,6 +268,9 @@ Device_ID_MSH_3: A resource Id, used to fill "entity.what.reference" property. T }, "request":{ "method":"PUT", + {% if Root_Template_1 == "ADT_A29" -%} + "method":"DELETE", + {% endif -%} "url":"Provenance/{{ ID }}", }, }, diff --git a/data/Templates/Hl7v2/Resource/_RelatedPerson.liquid b/data/Templates/Hl7v2/Resource/_RelatedPerson.liquid index c8a52a6b8..5e794bd5d 100644 --- a/data/Templates/Hl7v2/Resource/_RelatedPerson.liquid +++ b/data/Templates/Hl7v2/Resource/_RelatedPerson.liquid @@ -328,6 +328,9 @@ RelatedPerson_Patient_ID: A resource Id, used to fill "patient.reference" proper }, "request":{ "method":"PUT", + {% if Root_Template == "ADT_A29" -%} + "method":"DELETE", + {% endif -%} "url":"RelatedPerson/{{ ID }}", }, }, diff --git a/data/Templates/Hl7v2/Resource/_ServiceRequest.liquid b/data/Templates/Hl7v2/Resource/_ServiceRequest.liquid index 30d769150..8eb75b2b2 100644 --- a/data/Templates/Hl7v2/Resource/_ServiceRequest.liquid +++ b/data/Templates/Hl7v2/Resource/_ServiceRequest.liquid @@ -2,268 +2,815 @@ The following reference IDs are accepted by this template. Practitioner_ID_NTE_5: A resource Id, used to fill "note.reference" property. The resource is of "Practitioner" type and generated based on "NTE.5" HL7 V2 identifier. -PractitionerRole_ID_ORC_12: A resource Id, used to fill "requester.reference" property. The resource is of "PractitionerRole" type and generated based on "ORC.12" HL7 V2 identifier. -Organization_ID_ORC_21: A resource Id, used to fill "requester.reference" property. The resource is of "Organization" type and generated based on "ORC.21" HL7 V2 identifier. -Practitioner_ID_OBR_10: A resource Id, used to fill "specimen.reference" property. The resource is of "Practitioner" type and generated based on "OBR.10" HL7 V2 identifier. -Specimen_ID_OBR_15: A resource Id, used to fill "specimen.reference" property. The resource is of "Practitioner" type and generated based on "OBR.15" HL7 V2 identifier. +PractitionerRole_ID_ORC_12: A resource Id, used to fill "requester.reference" property. The resource is of "PractitionerRole" type and generated based on "parentSegment.ORC.12" HL7 V2 identifier. +Organization_ID_ORC_21: A resource Id, used to fill "requester.reference" property. The resource is of "Organization" type and generated based on "parentSegment.ORC.21" HL7 V2 identifier. +Practitioner_ID_OBR_10: A resource Id, used to fill "specimen.reference" property. The resource is of "Practitioner" type and generated based on "OBR_child.10" HL7 V2 identifier. +Specimen_ID_OBR_15: A resource Id, used to fill "specimen.reference" property. The resource is of "Practitioner" type and generated based on "OBR_child.15" HL7 V2 identifier. ServiceRequest_Subject_ID: A resource Id, used to fill "subject.reference" property. ServiceRequest_Encounter_ID: A resource Id, used to fill "encounter.reference" property. {% endcomment -%} {% evaluate Practitioner_ID_NTE_5 using 'ID/Practitioner' XCN: NTE.5 -%} -{% evaluate Organization_ID_ORC_21 using 'ID/Organization' CWE: ORC.21 -%} -{% evaluate Practitioner_ID_OBR_10 using 'ID/Practitioner' XCN: OBR.10 -%} +{% evaluate PractitionerRole_ID_ORC_12 using 'ID/PractitionerRole' XCN: parentSegment.12 -%} +{% evaluate Organization_ID_ORC_21 using 'ID/Organization' CWE: parentSegment.21 -%} {% evaluate Organization_ID_RF1_19 using 'ID/Organization' XON: RF1.19 -%} {% evaluate Practitioner_ID_RF1_20 using 'ID/Practitioner' XCN: RF1.20 -%} { + "fullUrl":"urn:uuid:{{ ID }}", "resource":{ "resourceType": "ServiceRequest", "id":"{{ ID }}", - - "status":"{{ ORC.5.Value | get_property: 'CodeSystem/OrderStatus', 'code' }}", - - {% if RF1.1 -%} - "status": {% include 'DataType/CWECode' mapping: 'CodeSystem/RequestStatus', CWE: RF1.1 -%}, - {% endif -%} - {% if RF1.25.Value == "D" -%} - "status": "entered-in-error", - {% endif -%} + {% if OBR_parent == null %} + {% if parentSegment or OBR_child %} + {% if parentSegment.5 -%} + "status":"{{ parentSegment.5.Value | get_property: 'CodeSystem/OrderStatus', 'code' }}", + {% else -%} + "status": "active", + {% endif %} + {% endif %} + + {% if RF1.1 -%} + "status": {% include 'DataType/CWECode' mapping: 'CodeSystem/RequestStatus', CWE: RF1.1 -%}, + {% endif -%} - {% if RF1 -%} - "intent": "order", - {% endif%} - - {% if ORC.1 -%} - "intent":"order", - {% endif -%} - - {% if OBR.11.Value%} - {% if OBR.11.Value == "G" -%} - "intent":"reflex-order", - {% else -%} - "intent":"order", + {% if AIS -%} + {% if AIS.10 -%} + "status": {% include 'DataType/CWECode' mapping: 'CodeSystem/FillerStatusServiceRequestStatus', CWE: AIS.10 -%}, + {% else -%} + "status": "draft", + {% endif -%} + {% if AIS.2.Value == "D"-%} + "status": "entered-in-error", + {% endif -%} + "intent": "filler-order", {% endif -%} - {% endif -%} - - "identifier": - [ - {% if OBR %} - { - {% if OBR.2 == null -%} - {% include 'DataType/EIIdentifier' EI: ORC.2 -%} + + {% if RF1.25.Value == "D" -%} + "status": "entered-in-error", + {% endif -%} + + {% if RF1 -%} + "intent": "order", + {% endif %} + + {% if OBR_child or parentSegment %} + {% if OBR_child.11.Value == "G" -%} + "intent":"reflex-order", + {% elsif OBR_child and type_msg == 'ORU' -%} + "intent":"filler-order", + {% else -%} + "intent":"order", {% endif -%} - "type": + {% endif -%} + + "orderDetail" : [ + {% for o in OBR_child.46.Repeats -%} { - "coding": - [ + {% include 'DataType/CWECodeableConcept', CWE: o -%} + }, + {% endfor -%} + {% for o in OBR_child.47.Repeats -%} + { + {% include 'DataType/CWECodeableConcept', CWE: o -%} + }, + {% endfor -%} + {% for a in AIS.11.Repeats -%} + { + {% include 'DataType/CWECodeableConcept', CWE: a -%} + }, + {% endfor -%} + {% for a in AIS.12.Repeats -%} + { + {% include 'DataType/CWECodeableConcept', CWE: a -%} + }, + {% endfor -%} + ], + + "identifier": + [ + { + {% if OBR_child.2 == null %} + {% if parentSegment.2 -%} + {% include 'DataType/EIIdentifier' EI: parentSegment.2 -%} + "type": { - {% if OBR.2 == null -%} - "code":"PLAC", - {% endif -%} - {% if OBR.2 -%} - "code":"PLAC", - {% endif -%} - {% if OBR.3 -%} - "code":"FILL", - {% endif -%} - {% if OBR.53 -%} - "code":"PLAC", - {% endif -%} - {% if OBR.2 == null -%} - "system":"http://terminology.hl7.org/CodeSystem/v2-0203", - {% endif -%} - {% if OBR.2 -%} - "system":"http://terminology.hl7.org/CodeSystem/v2-0203", - {% endif -%} - {% if OBR.3 -%} - "system":"http://terminology.hl7.org/CodeSystem/v2-0203", - {% endif -%} - {% if OBR.53 -%} - "system":"http://terminology.hl7.org/CodeSystem/v2-0203", - {% endif -%} + "coding": + [ + { + "code":"PLAC", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + }, + ], }, - ], - }, + {% endif %} + {% else %} + {% include 'DataType/EIIdentifier' EI: OBR_child.2 -%} + "type": + { + "coding": + [ + { + {% if OBR_child.2 -%} + "code":"PLAC", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + {% endif -%} + }, + ], + }, + {% endif %} }, - {% endif %} { - {% include 'DataType/EIIdentifier' EI: ORC.3 -%} - "type": - { - "coding": - [ + {% if OBR_child.3 == null %} + {% if parentSegment.3 -%} + {% include 'DataType/EIIdentifier' EI: parentSegment.3 -%} + "type": { - {% if ORC.3 -%} - "code":"FILL", - {% endif -%} - {% if ORC.3 -%} - "system":"http://terminology.hl7.org/CodeSystem/v2-0203", - {% endif -%} + "coding": + [ + { + "code":"FILL", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + }, + ], }, - ], - }, - }, + {% endif %} + {% else %} + {% include 'DataType/EIIdentifier' EI: OBR_child.3 -%} + "type": + { + "coding": + [ + { + {% if OBR_child.3 -%} + "code":"FILL", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + {% endif -%} + }, + ], + }, + {% endif %} + }, { - {% include 'DataType/EIIdentifier' EI: ORC.4 -%} + {% include 'DataType/EIIdentifier' EI: parentSegment.4 -%} "type": { "coding": [ { - {% if ORC.4 -%} + {% if parentSegment.4 -%} "code":"PGN", {% endif -%} - {% if ORC.4 -%} + {% if parentSegment.4 -%} "system":"http://terminology.hl7.org/CodeSystem/v2-0203", {% endif -%} }, ], }, }, - {% if OBR.2 -%} - { - {% include 'DataType/EIIdentifier' EI: OBR.2 -%} - }, - {% endif -%} - { - {% include 'DataType/EIIdentifier' EI: OBR.3 -%} - }, { - {% include 'DataType/EIIdentifier' EI: OBR.53 -%} + {% if OBR_child.53 -%} + "value" : "{{OBR_child.53.1.Value}}", + "type": + { + "coding": + [ + { + "code":"PLAC", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + }, + ], + }, + {% endif -%} }, { - {% include 'DataType/EIIdentifier' EI: RF1.6 -%} + {% include 'DataType/EIIdentifier' EI: RF1.6 -%} }, - {% for r in RF1.11.Repeats -%} - {% if r.Value != RF1.6.Value -%} + {% for r in RF1.11.Repeats -%} + {% if r.Value != RF1.6.Value -%} + { + {% include 'DataType/EIIdentifier' EI: r -%} + }, + {% endif -%} + {% endfor -%} + ], + {% if parentSegment.1.Value == 'NW' -%} + "authoredOn":"{{ parentSegment.9.Value | format_as_date_time }}", + {% endif -%} + "authoredOn":"{{ RF1.7.Value | format_as_date_time }}", + {% unless RF1.7.Value -%} + "authoredOn":"{{ RF1.9.Value | format_as_date_time }}", + {% endunless -%} + {% if OBR_child.29 %} + "basedOn": + [ { - {% include 'DataType/EIIdentifier' EI: r -%} + {% if OBR_child.50 and OBR_child.29 %} + "reference":"ServiceRequest/{{ ServiceRequest_ID_OBR_29 }}", + {% endif %} + {% unless OBR_child.50 %} + "type": "ServiceRequest", + "identifier": + { + {% if OBR_child.29.1 -%} + {% if OBR_child.29.1.1 %} + "value" : "{{OBR_child.29.1.1}}", + {% endif %} + "type": + { + "coding": + [ + { + "code":"PLAC", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + }, + ], + }, + {% endif %} + {% unless OBR_child.29.1 %} + {% if OBR_child.29.2.1 %} + "value" : "{{OBR_child.29.2.1}}", + {% endif %} + "type": + { + "coding": + [ + { + "code":"FILL", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + }, + ], + }, + {% endunless -%} + }, + {% endunless %} + } + ], + {% endif %} + {% unless OBR_child.29 %} + {% if parentSegment.8 %} + "basedOn": + [ + { + {% if parentSegment.31 and parentSegment.8 %} + "reference":"ServiceRequest/{{ ServiceRequest_ID_ORC_8 }}", + {% endif %} + {% unless parentSegment.31 %} + "type": "ServiceRequest", + "identifier": + { + {% if parentSegment.8.1 and parentSegment.8.2 or parentSegment.8.1 %} + "value" : "{{parentSegment.8.1.1}}", + "type": + { + "coding": + [ + { + "code":"PLAC", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + }, + ], + }, + {% elsif parentSegment.8.2 %} + "value" : "{{parentSegment.8.2.1}}", + "type": + { + "coding": + [ + { + "code":"FILL", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + }, + ], + }, + {% endif -%} + }, + {% endunless %} + } + ], + {% endif %} + {% endunless %} + "performer": [ + {% if RF1.19 and Organization_ID_RF1_19 -%} + { + "reference": "Organization/{{Organization_ID_RF1_19}}", + }, + {% endif -%} + {% if RF1.20 and Practitioner_ID_RF1_20-%} + { + "reference": "Practitioner/{{Practitioner_ID_RF1_20}}", }, + {% endif -%} + ], + "performerType" : { + {% include 'DataType/CWECodeableConcept', CWE: RF1.3 -%} + }, + + {% if type_msg == 'ORM' %} + {% if OBR_child.27 == null -%} + "occurrenceDateTime":"{{ OBR_child.6.Value | format_as_date_time }}", + {% endif -%} + {% if OBR_child.6 == null and OBR_child.27 == null and parentSegment.7 == null -%} + "occurrenceDateTime":"{{ parentSegment.15.Value | format_as_date_time }}", + {% endif %} {% endif -%} - {% endfor -%} + + {% if OBR_tq1.6 == null and OBR_tq1.27 == null -%} + "occurrenceDateTime":"{{ ORC_tq1.15.Value | format_as_date_time }}", + {% endif %} - ], - {% if ORC.1.Value -%} - "authoredOn":"{{ ORC.9.Value | format_as_date_time }}", - {% endif -%} - "authoredOn":"{{ RF1.7.Value | format_as_date_time }}", - {% unless RF1.7.Value -%} - "authoredOn":"{{ RF1.9.Value | format_as_date_time }}", - {% endunless -%} - "performer": [ - {% if RF1.19 and Organization_ID_RF1_19 -%} + {% if OBR_tq1.27 == "" or OBR_tq1.27 == null -%} + "occurrenceDateTime":"{{ OBR_tq1.6.Value | format_as_date_time }}", + {% endif %} + + "locationCode": + [ + {% if OBR_child.24 %} + { + {% include 'DataType/IDCodeableConcept' mapping: 'CodeSystem/DiagnosticServiceSection', ID: OBR_child.24 -%} + }, + {% endif %} + {% if parentSegment.29 %} + { + {% include 'DataType/CWECodeableConcept' mapping: 'CodeSystem/OrderType', CWE: parentSegment.29 -%} + }, + {% endif %} + ], + "note": [ + {% if NTE %} { - "reference": "Organization/{{Organization_ID_RF1_19}}", + "text": "{{NTE.3.Value}}", + "time": "{{ NTE.6.Value | format_as_date_time }}", + {% if Practitioner_ID_NTE_5 %} + "authorReference": + { + "reference":"Practitioner/{{ Practitioner_ID_NTE_5 }}", + } + {% endif %} }, - {% endif -%} - {% if RF1.20 and Practitioner_ID_RF1_20-%} + {% endif %} { - "reference": "Practitioner/{{Practitioner_ID_RF1_20}}", + "text": "{{ RF1.24.Value }}", }, - {% endif -%} - ], - "performerType" : { - {% include 'DataType/CWECodeableConcept', CWE: RF1.3 -%} - }, - "occurrenceDateTime":"{{ ORC.15.Value | format_as_date_time }}", - "occurrenceDateTime":"{{ OBR.6.Value | format_as_date_time }}", - "locationCode": - [ + {% if OBR_child.18 %} { - {% include 'DataType/CWECodeableConcept' mapping: 'CodeSystem/OrderType', CWE: ORC.29 -%} + "text": "{{ OBR_child.18.Value }}", + "authorString": "Placer Field 1", }, - ], - "note": [ - { - "text": "{{NTE.3.Value}}", - "text": "{{ RF1.24.Value }}", - "time": "{{ NTE.6.Value | format_as_date_time }}", - {% if Practitioner_ID_NTE_5%} - "authorReference": + {% endif %} + {% if OBR_child.19 %} { - "reference":"Practitioner/{{ Practitioner_ID_NTE_5 }}", - } + "text": "{{ OBR_child.19.Value }}", + "authorString": "Placer Field 2", + }, {% endif %} - } - ], - "requester": - { - {% if ORC.12 and PractitionerRole_ID_ORC_12 -%} - "reference":"PractitionerRole/{{ PractitionerRole_ID_ORC_12 }}", - {% endif -%} - {% if ORC.21 and Organization_ID_ORC_21 -%} - "reference":"Organization/{{ Organization_ID_ORC_21 }}", - {% endif -%} - }, - "quantityQuantity": - { - {% include 'DataType/CQ' CQ: TQ1.2 -%} - }, - "occurrenceTiming": - { - "repeat": + {% if OBR_child.20 %} { - "boundsDuration": + "text": "{{ OBR_child.20.Value }}", + "authorString": "Filler Field 1", + }, + {% endif %} + {% if OBR_child.21 %} { - {% include 'DataType/CQ' CQ: TQ1.6 -%} + "text": "{{ OBR_child.21.Value }}", + "authorString": "Filler Field 2", }, - "boundsPeriod": + {% endif %} + {% if OBR_child.27.8 %} { - "start":"{{ TQ1.7.Value | format_as_date_time }}", - "end":"{{ TQ1.8.Value | format_as_date_time }}", + "text": "{{ OBR_child.27.8.Value }}", + }, + {% endif %} + { + {% if type_msg == 'ORM' -%} + {% unless OBR_child.27 %} + {% if parentSegment.7.Repeats[0] -%} + "text": "{{ parentSegment.7.Repeats[0].8.Value }}", + {% endif %} + {% endunless %} + {% endif -%} }, - {% include 'DataType/CQServiceRequestduration' CQ: TQ1.13 -%} - "count":"{{ TQ1.14.Value }}", + { + "text": "{{ TQ1.11.Value }}", + }, + ], + "asNeededCodeableConcept": { + "text": "{{ TQ1.10.Value }}", }, - }, - "priority":"{{ TQ1.9.Value }}", - {% if RF1.2 -%} - "priority": {% include 'DataType/CWECode' mapping: 'CodeSystem/RequestPriority', CWE: RF1.2 -%}, - {% endif -%} - "priority":"{{ OBR.5.Value | get_property: 'CodeSystem/Priority', 'code' }}", - - "code": - { - {% include 'DataType/CWECodeableConcept' CWE: OBR.4 -%} - }, - "reasonCode": - [ + "quantityQuantity": { - {% include 'DataType/CWECodeableConcept' CWE: OBR.31 -%} + {% if TQ1 -%} + {% if TQ1.2 == null -%} + "value": 1, + {% endif -%} + {% endif -%} + {% include 'DataType/CQ' CQ: TQ1.2 -%} + {% include 'DataType/CQ' CQ_val: OBR_child.27.1 -%} + + {% if type_msg == 'ORM' -%} + {% unless OBR_child.27 %} + {% if parentSegment.7.Repeats[0] -%} + + {% include 'DataType/CQ' CQ_val: parentSegment.7.Repeats[0].1 -%} + {% endif %} + {% endunless %} + {% endif -%} + }, + "occurrencePeriod" : { + "start" : "{{ AIS.4.Value | format_as_date_time }}", }, - {% for r in RF1.10.Repeats -%} + "occurrenceTiming": + { + + "code": { + {% include 'DataType/CWECodeableConceptInternalValues' CWE: TQ1.3.Repeats[0].1 -%} + }, + {% if TQ1.3 == null -%} + {% include 'DataType/RITiming' RI_val: OBR_timeday.27.2 -%} + {% include 'DataType/RITiming' RI_val: OBR_child.27.2 -%} + {% endif -%} + {% if type_msg == "ORM" -%} + {% include 'DataType/RITiming' RI_val: OBR_child.27.2 -%} + {% unless OBR_child.27 %} + {% unless OBR_child.6 %} + {% include 'DataType/RITiming' RI_val: parentSegment.7.Repeats[0].2 -%} + {% endunless %} + {% endunless %} + {% endif -%} + "repeat": { - {% include 'DataType/CWECodeableConcept', CWE: r -%} - {% if r.9.Value == null or r.9.Value == '' -%} - "text":"{{ RF1.14.Value }}", + {% include 'DataType/RPTTiming' RPT: TQ1.3.Repeats[0] -%} + "boundsDuration": + { + {% if TQ1.7 == null and TQ1.8 == null -%} + {% include 'DataType/CQ' CQ_duration: TQ1.6 -%} + {% endif -%} + }, + {% if type_msg == 'ORM' -%} + {% unless OBR_child.27 %} + {% unless OBR_child.6 %} + {% if parentSegment.7.Repeats[0] -%} + {% if parentSegment.7.Repeats[0].3 %} + {% assign durationUnitsValue = parentSegment.7.Repeats[0].3.Value | slice: 0 -%} + {% if durationUnitsValue == "S" %} + "durationUnit": "s", + {% assign durationValue = parentSegment.7.Repeats[0].3.Value | slice: 1,2 -%} + "duration": {{durationValue}}, + {% elsif durationUnitsValue == "M" %} + "durationUnit": "min", + {% assign durationValue = parentSegment.7.Repeats[0].3.Value | slice: 1,2 -%} + "duration": {{durationValue}}, + {% elsif durationUnitsValue == "H" %} + "durationUnit": "h", + {% assign durationValue = parentSegment.7.Repeats[0].3.Value | slice: 1,2 -%} + "duration": {{durationValue}}, + {% elsif durationUnitsValue == "D" %} + "durationUnit": "d", + {% assign durationValue = parentSegment.7.Repeats[0].3.Value | slice: 1,3 -%} + "duration": {{durationValue}}, + {% elsif durationUnitsValue == "W" %} + "durationUnit": "wk", + {% assign durationValue = parentSegment.7.Repeats[0].3.Value | slice: 1,2 -%} + "duration": {{durationValue}}, + {% elsif durationUnitsValue == "L" %} + "durationUnit": "mo", + {% assign durationValue = parentSegment.7.Repeats[0].3.Value | slice: 1,2 -%} + "duration": {{durationValue}}, + {% elsif durationUnitsValue == "X" %} + {% assign durationValue = parentSegment.7.Repeats[0].3.Value | slice: 1,2 -%} + "frequency": "{{durationValue}}", + {% endif %} + {% endif %} + {% if parentSegment.7.Repeats[0].12 %} + "count": {{ parentSegment.7.Repeats[0].12.Value }}, + {% endif %} + + {% endif %} + {% endunless %} + {% endunless %} + {% endif -%} + "timeOfDay": + [ + {% if TQ1.3.Repeats[0].5 == null and TQ1.3.Repeats[0].8 == null and TQ1.4 == null -%} + "{{ OBR_timeday.27.2.2 }}", + {% endif -%} + {% if TQ1.3.Repeats[0].5 == null and TQ1.3.Repeats[0].8 == null -%} + {% for tq1_4 in TQ1.4.Repeats -%} + "{{ tq1_4.Value }}", + {% endfor %} + {% endif -%} + {% if type_msg == "ORM" -%} + "{{ OBR_child.27.2.2 }}", + {% endif -%} + {% if type_msg == 'ORM' -%} + {% unless OBR_child.27 %} + {% unless OBR_child.6 %} + {% if parentSegment.7.Repeats[0] -%} + "{{ parentSegment.7.Repeats[0].2.2 }}", + {% endif %} + {% endunless %} + {% endunless %} + {% endif -%} + ], + {% if TQ1.3.Repeats[0].5 == null -%} + {% if TQ1.5 -%} + "period" : {{ TQ1.5.Repeats[0].1.Value }}, + "periodUnit" : {% include 'DataType/CWECode' mapping: 'CodeSystem/DurationUnit', CWE_internal: TQ1.5.Repeats[0].2 -%}, + {% endif -%} {% endif -%} + {% if OBR_child.27.3 %} + {% assign durationUnitsValue = OBR_child.27.3.Value | slice: 0 -%} + {% if durationUnitsValue == "S" %} + "durationUnit": "s", + {% assign durationValue = OBR_child.27.3.Value | slice: 1,2 -%} + "duration": {{durationValue}}, + {% elsif durationUnitsValue == "M" %} + "durationUnit": "min", + {% assign durationValue = OBR_child.27.3.Value | slice: 1,2 -%} + "duration": {{durationValue}}, + {% elsif durationUnitsValue == "H" %} + "durationUnit": "h", + {% assign durationValue = OBR_child.27.3.Value | slice: 1,2 -%} + "duration": {{durationValue}}, + {% elsif durationUnitsValue == "D" %} + "durationUnit": "d", + {% assign durationValue = OBR_child.27.3.Value | slice: 1,3 -%} + "duration": {{durationValue}}, + {% elsif durationUnitsValue == "W" %} + "durationUnit": "wk", + {% assign durationValue = OBR_child.27.3.Value | slice: 1,2 -%} + "duration": {{durationValue}}, + {% elsif durationUnitsValue == "L" %} + "durationUnit": "mo", + {% assign durationValue = OBR_child.27.3.Value | slice: 1,2 -%} + "duration": {{durationValue}}, + {% elsif durationUnitsValue == "X" %} + {% assign durationValue = OBR_child.27.3.Value | slice: 1,2 -%} + "frequency": "{{durationValue}}", + {% endif %} + {% endif %} + + "boundsPeriod": + { + "start":"{{ TQ1.7.Value | format_as_date_time }}", + "start":"{{ OBR_child.27.4.Value | format_as_date_time }}", + {% if type_msg == 'ORM' -%} + {% unless OBR_child.27 %} + {% unless OBR_child.6 %} + {% if parentSegment.7.Repeats[0] -%} + "start": "{{ parentSegment.7.Repeats[0].4.Value | format_as_date_time }}", + "end": "{{ parentSegment.7.Repeats[0].5.Value | format_as_date_time }}", + {% endif %} + {% endunless %} + {% endunless %} + {% endif -%} + "end":"{{ TQ1.8.Value | format_as_date_time }}", + "end":"{{ OBR_child.27.5.Value | format_as_date_time }}", + }, + + {% include 'DataType/CQServiceRequestduration' CQ: TQ1.13 -%} + {% if TQ1.14 -%} + "count":{{ TQ1.14.Value }}, + {% endif %} + {% if OBR_child.27.12 %} + "count": {{ OBR_child.27.12.Value }}, + {% endif %} }, - {% endfor -%} - ], - "specimen": - [ + }, + {% if TQ1 -%} + {% if TQ1.9 -%} + "priority":{% include 'DataType/CWECode' mapping: 'CodeSystem/RequestPriority', CWE: TQ1.9 -%}, + {% else -%} + "priority": "routine", + {% endif -%} + {% endif -%} + {% if OBR_child.5 %} + "priority":"{{ OBR_child.5.Value | get_property: 'CodeSystem/RequestPriority', 'code' }}", + {% endif %} + {% if RF1.2 -%} + "priority": {% include 'DataType/CWECode' mapping: 'CodeSystem/RequestPriority', CWE: RF1.2 -%}, + {% endif -%} + + "code": + { + {% include 'DataType/CWECodeableConcept' CWE: AIS.3 -%} + {% include 'DataType/CWECodeableConcept' CWE: OBR_child.4 -%} + }, + "reasonCode": + [ + {% for OBR_31 in OBR_child.31.Repeats %} + { + {% include 'DataType/CWECodeableConcept' CWE: OBR_31 -%} + }, + {% endfor -%} + {% for r in RF1.10.Repeats -%} + { + {% include 'DataType/CWECodeableConcept', CWE: r -%} + {% if r.9.Value == null or r.9.Value == '' -%} + "text":"{{ RF1.14.Value }}", + {% endif -%} + }, + {% endfor -%} + ], + "subject": + { + "reference":"{{ ServiceRequest_Subject_ID }}", + }, + "encounter": { - {% if OBR.10 and Practitioner_ID_OBR_10 -%} - "reference":"Practitioner/{{ Practitioner_ID_OBR_10 }}", + "reference":"{{ ServiceRequest_Encounter_ID }}", + }, + {% endif %} + +{% comment %} The below mapping is for the new service request created from OBR. This coding is for reference service request created from OBR {% endcomment -%} + + {% if OBR_parent -%} + {% if OBR_parent.29 %} + "identifier": + [ + {% if OBR_parent.29.1 %} + { + {% if OBR_parent.29.1.1 %} + "value" : "{{OBR_parent.29.1.1}}", + {% endif %} + "type": + { + "coding": + [ + { + "code":"PLAC", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + }, + ], + }, + }, {% endif -%} - {% if OBR.15 and Specimen_ID_OBR_15 -%} - "reference":"Specimen/{{ Specimen_ID_OBR_15 }}", + {% if OBR_parent.29.2 %} + { + {% if OBR_parent.29.2.1 %} + "value" : "{{OBR_parent.29.2.1}}", + {% endif %} + "type": + { + "coding": + [ + { + "code":"FILL", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + }, + ], + }, + }, + {% endif %} + { + "type" : { + {% include 'DataType/CWECodeableConcept' CWE: OBR_parent.50 %} + }, + }, + ], + {% endif %} + {% unless OBR_parent.29 -%} + {% if parentSegment.8 %} + "identifier": + [ + { + {% if parentSegment.8.1 %} + "value" : "{{parentSegment.8.1.1}}", + "type": + { + "coding": + [ + { + "code":"PLAC", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + }, + ], + {% endif -%} + }, + }, + { + {% if parentSegment.8.2 %} + "value" : "{{parentSegment.8.2.1}}", + "type": + { + "coding": + [ + { + "code":"FILL", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + }, + ], + }, + {% endif %} + }, + ], + {% endif %} + {% endunless -%} + + + {% if parentSegment.5 -%} + "status":"{{ parentSegment.5.Value | get_property: 'CodeSystem/OrderStatus', 'code' }}", + {% else -%} + "status": "active", + {% endif %} + + {% if OBR_parent.11.Value == "G" -%} + "intent":"reflex-order", + {% elsif OBR_parent and type_msg == 'ORU' -%} + "intent":"filler-order", + {% else -%} + "intent":"order", + {% endif -%} + "subject": + { + "reference":"{{ ServiceRequest_Subject_ID }}", + }, + {% endif %} + +{% comment %} End of mapping for the new service request created from OBR. This coding is for reference service request created from OBR {% endcomment -%} + + +{% comment %} The below mapping is for the new service request created from ORC. This coding is for reference service request created from RC {% endcomment -%} + + {% if ORC -%} + {% if ORC.8 %} + "identifier": + [ + { + {% if ORC.8.1 %} + "value" : "{{ORC.8.1.1}}", + "type": + { + "coding": + [ + { + "code":"PLAC", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + }, + ], + }, {% endif -%} }, + { + {% if ORC.8.2 %} + "value" : "{{ORC.8.2.1}}", + "type": + { + "coding": + [ + { + "code":"FILL", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + }, + ], + }, + {% endif %} + }, + { + "type" : { + {% include 'DataType/CWECodeableConcept' CWE: ORC.31 %} + }, + }, ], + {% endif %} + + + {% if ORC.5 -%} + "status":"{{ ORC.5.Value | get_property: 'CodeSystem/OrderStatus', 'code' }}", + {% else -%} + "status": "active", + {% endif %} + + {% if OBR.11.Value == "G" -%} + "intent":"reflex-order", + {% elsif OBR and type_msg == 'ORU' -%} + "intent":"filler-order", + {% else -%} + "intent":"order", + {% endif -%} + + {% comment %} + {% if OBR.11.Value == "G" -%} + "intent":"reflex-order", + {% elsif parentSegment and type_msg == 'ORU' -%} + "intent":"filler-order", + {% elsif parentSegment and type_msg == 'ORM' or type_msg == 'OML' -%} + "intent":"order", + {% endif -%} + {% endcomment %} "subject": { "reference":"{{ ServiceRequest_Subject_ID }}", }, - "encounter": - { - "reference":"{{ ServiceRequest_Encounter_ID }}", - }, - }, + {% endif %} + +{% comment %} End of mapping for the new service request created from OBR. This coding is for reference service request created from OBR {% endcomment -%} + + +}, "request":{ "method":"PUT", "url":"ServiceRequest/{{ ID }}", diff --git a/data/Templates/Hl7v2/Resource/_Specimen.liquid b/data/Templates/Hl7v2/Resource/_Specimen.liquid index 6347e63a5..27f3f0b45 100644 --- a/data/Templates/Hl7v2/Resource/_Specimen.liquid +++ b/data/Templates/Hl7v2/Resource/_Specimen.liquid @@ -3,7 +3,10 @@ The following reference IDs are accepted by this template. Practitioner_ID_OBR_10: A resource Id, used to fill "collection.collector.reference" property. The resource is of "Practitioner" type and generated based on "OBR.10" HL7 V2 identifier. Specimen_Subject_ID: A resource Id, used to fill "subject.reference" property. + +{% evaluate Practitioner_ID_NTE_5 using 'ID/Practitioner' XCN: NTE.5 -%} {% endcomment -%} +{% evaluate PractitionerRole_ID_OBR_10 using 'ID/PractitionerRole' XCN: OBR.10 -%} { "fullUrl":"urn:uuid:{{ ID }}", @@ -12,48 +15,125 @@ Specimen_Subject_ID: A resource Id, used to fill "subject.reference" property. "id":"{{ ID }}", "collection": { - {% comment -%} Placeholder provided for customization by users. If left empty, it will be removed in post-processing. {% endcomment -%} - "quantity": + "quantity": { + {% include 'DataType/CQ' CQ: OBR.9 -%} + {% include 'DataType/CQ' CQ: SPM.12 -%} }, "collector": { - {% if OBR.10 and Practitioner_ID_OBR_10 -%} - "reference":"Practitioner/{{ Practitioner_ID_OBR_10 }}", + {% if OBR.10 and PractitionerRole_ID_OBR_10 -%} + "reference":"PractitionerRole/{{ PractitionerRole_ID_OBR_10 }}", {% endif -%} }, + + "bodySite": { + {% include 'DataType/CWECodeableConceptInternalValues' CWE: OBR.15.4 -%} + {% include 'DataType/CWECodeableConcept' CWE: SPM.8 -%} + }, + "method": { - {% include 'DataType/CWECodeableConcept' CWE: SPM.7 -%} + "coding": + [ + {% if SPM.7 -%} + {% assign hardcodedUrl = "http://terminology.hl7.org/CodeSystem/v2-0488" %} + {% include 'DataType/CWECodeableConcept_hardcodedURL' CWE: SPM.7, systemHardcodedUrl: hardcodedUrl -%} + {% endif -%} + ], + "text": "{{ SPM.7.9.Value }}", + "text": "{{ OBR.15.3.Value }}", }, + {% if OBR.7 and OBR.8 -%} + "collectedPeriod": + { + "start": "{{ OBR.7.Value | format_as_date_time }}", + "end": "{{ OBR.8.Value | format_as_date_time }}", + }, + {% elsif OBR.7 and OBR.8 == null -%} + "collectedDateTime": "{{ OBR.7.Value | format_as_date_time }}", + {% endif -%} + {% if SPM.17.2 -%} "collectedPeriod": - { - {% if SPM.17.2 -%} + { {% include 'DataType/DR' DR: SPM.17 -%} - {% endif -%} - }, + }, + {% endif -%} {% if SPM.17.2 == null -%} "collectedDateTime":"{{ SPM.17.Value | format_as_date_time }}", {% endif -%} }, "receivedTime":"{{ OBR.14.Value | format_as_date_time }}", "receivedTime":"{{ SPM.18.Value | format_as_date_time }}", - "receivedTime":"{{ OBR.13.Value | format_as_date_time }}", - {% comment -%} Placeholder provided for customization by users. If left empty, it will be removed in post-processing. {% endcomment -%} - "note": - [ - ], - "identifier": - [ + + "identifier":[ { - {% include 'DataType/EIPIdentifier' EIP: SPM.2 -%} + {% include 'DataType/EIIdentifier' EI: OBR.2 -%} + "type": + { + "coding": + [ + { + {% if OBR.2 -%} + "code":"PLAC", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + {% endif -%} + }, + ], + }, }, + { + {% include 'DataType/EIIdentifier' EI: OBR.3 -%} + "type": { - {% include 'DataType/EIPIdentifier' EIP: SPM.3 -%} + "coding": + [ + { + {% if OBR.3 -%} + "code":"FILL", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + {% endif -%} + }, + ], + }, + }, + { + {% if OBR.53 -%} + "value" : "{{OBR.53.1.Value}}", + "type": + { + "coding": + [ + { + "code":"PLAC", + "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + }, + ], + }, + {% endif -%} + }, + { + {% include 'DataType/EIPIdentifier' EIP_Specimen_child1: SPM.2.1 -%} }, { - {% include 'DataType/CX' CX: SPM.31 -%} + {% include 'DataType/EIPIdentifier' EIP_Specimen_child2: SPM.2.2 -%} }, + {% if SPM_parent %} + { + {% if SPM_parent.1 %} + {% include 'DataType/EIPIdentifier' EIP_Specimen_parent1: SPM_parent.1 -%} + {% elsif SPM_parent.2 %} + {% include 'DataType/EIPIdentifier' EIP_Specimen_parent2: SPM_parent.2 -%} + {% endif %} + }, + {% endif %} + + {% for spm_31 in SPM.31.Repeats %} + { + {% include 'DataType/CX' CX: spm_31 -%} + }, + {% endfor %} + { {% include 'DataType/EIIdentifier' EI: SPM.32 -%} "type": @@ -62,7 +142,8 @@ Specimen_Subject_ID: A resource Id, used to fill "subject.reference" property. [ { {% if SPM.32 -%} - "system":"http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "SHIP", + "system":"http://example.com/v2-to-fhir-converter/CodeSystem/additional-identifierType", {% endif -%} }, ], @@ -71,14 +152,31 @@ Specimen_Subject_ID: A resource Id, used to fill "subject.reference" property. ], "type": { - {% include 'DataType/CWECodeableConcept' CWE: SPM.4 -%} + "coding": + [ + {% if SPM.4 -%} + {% assign hardcodedUrl = "http://terminology.hl7.org/CodeSystem/v2-0487" %} + {% include 'DataType/CWECodeableConcept_hardcodedURL' CWE: SPM.4, systemHardcodedUrl: hardcodedUrl -%} + {% endif -%} + ], + "text": "{{SPM.4.9.Value}}", + {% include 'DataType/CWECodeableConceptInternalValues' CWE: OBR.15.1 -%} + }, "container": [ { "additiveCodeableConcept": { - {% include 'DataType/CWECodeableConcept' CWE: SPM.6 -%} + "coding": + [ + {% if SPM.6 -%} + {% assign hardcodedUrl = "http://terminology.hl7.org/CodeSystem/v2-0371" %} + {% include 'DataType/CWECodeableConcept_hardcodedURL' CWE: SPM.6, systemHardcodedUrl: hardcodedUrl -%} + {% endif -%} + ], + "text": "{{SPM.6.9.Value}}", + {% include 'DataType/CWECodeableConceptInternalValues' CWE: OBR.15.2 -%} }, "type": { @@ -87,12 +185,21 @@ Specimen_Subject_ID: A resource Id, used to fill "subject.reference" property. }, ], "status":"{{ SPM.20.Value | get_property: 'CodeSystem/SpecimenAvailability', 'code' }}", - "condition": - [ - { - {% include 'DataType/CWECodeableConcept' CWE: SPM.24 -%} - }, - ], + + {% if SPM.24 -%} + "condition": + [ + {% for spm_24 in SPM.24.Repeats %} + { + "coding": + [ + {% include 'DataType/CWECodeableConceptRepeatable' mapping: 'CodeSystem/SpecimenCondition', CWE: spm_24 -%} + ], + "text": "{{spm_24.9.Value}}", + }, + {% endfor %} + ], + {% endif %} "accessionIdentifier": { {% include 'DataType/CX' CX: SPM.30.Repeats[0] -%} @@ -101,6 +208,20 @@ Specimen_Subject_ID: A resource Id, used to fill "subject.reference" property. { "reference":"{{ Specimen_Subject_ID }}", }, + "note": [ + {% if OBR.39-%} + {% for OBR_39 in OBR.39.Repeats %} + { + "text": "{{OBR_39.Value}}", + }, + {% endfor %} + {% endif %} + {% if SPM.14-%} + { + "text": "{{SPM.14.Value}}", + } + {% endif %} + ], }, "request":{ "method":"PUT", diff --git a/data/Templates/Hl7v2/SIU_S12.liquid b/data/Templates/Hl7v2/SIU_S12.liquid new file mode 100644 index 000000000..4388e4e93 --- /dev/null +++ b/data/Templates/Hl7v2/SIU_S12.liquid @@ -0,0 +1,476 @@ +{% assign firstSegments = hl7v2Data | get_first_segments: 'MSH|SCH' -%} +{% assign tq1SegmentLists = hl7v2Data | get_segment_lists: 'TQ1' -%} +{% assign pidSegmentLists = hl7v2Data | get_segment_lists: 'PID' -%} +{% assign rgsSegmentLists = hl7v2Data | get_segment_lists: 'RGS' -%} +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} + +{ + "resourceType": "Bundle", + "type": "batch", + {% if firstSegments.MSH.7 -%} + "timestamp":"{{ firstSegments.MSH.7.Value | format_as_date_time }}", + {% endif -%} + "identifier": + { + "value":"{{ firstSegments.MSH.10.Value }}", + }, + "id":"{{ bundleID }}", + "entry": [ + + {% evaluate patientId using 'ID/Patient' PID: pidSegmentLists.PID[0], type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% evaluate messageHeaderId using 'ID/MessageHeader' MSH: firstSegments.MSH -%} + + {% if firstSegments.MSH -%} + + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, ID: messageHeaderId -%} + {% evaluate provenanceId using 'ID/Provenance' MSH: firstSegments.MSH, baseId: patientId -%} + {% include 'Resource/Provenance' Root_Template: 'SIU_S12', MSH: firstSegments.MSH, REF_BUNDLE: bundleID, ID: provenanceId -%} + + {%- comment -%} + {% assign transformation_val = 'provenance_transformation' %} + {% evaluate provenanceOrganizationId using 'ID/Organization', prov_id: firstSegments.MSH -%} + {% evaluate provenanceTransformationId using 'ID/Provenance_transformation' prov_id: transformation_val -%} + {% include 'Resource/Organization' org_name: 'Microsoft Corporation', ID: provenanceOrganizationId -%} + {% include 'Resource/Provenance_transformation' Root_Template: 'ADT_A01', Provenance_Organization_ID: provenanceOrganizationId, REF_MSH: messageHeaderId, provenanceOrganizationId, ID: provenanceTransformationId -%} + {%- endcomment -%} + + {% if firstSegments.MSH.4 -%} + {% if firstSegments.MSH.4.1 != "" and firstSegments.MSH.4.1 != null or firstSegments.MSH.4.2 != "" and firstSegments.MSH.4.2 != null or firstSegments.MSH.4.3 != "" and firstSegments.MSH.4.3 != null -%} + {% evaluate organization_ID_MSH_4 using 'ID/Organization' HD: firstSegments.MSH.4 -%} + {% include 'Resource/Organization' MSHHD1: firstSegments.MSH.4, MSH: firstSegments.MSH, ID: organization_ID_MSH_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.6 %} + {% if firstSegments.MSH.6.1 != "" and firstSegments.MSH.6.1 != null or firstSegments.MSH.6.2 != "" and firstSegments.MSH.6.2 != null or firstSegments.MSH.6.3 != "" and firstSegments.MSH.6.3 != null -%} + {% evaluate organization_Id_MSH_6 using 'ID/Organization' HD: firstSegments.MSH.6 -%} + {% include 'Resource/Organization' MSHHD2: firstSegments.MSH.6, MSH: firstSegments.MSH, ID: organization_Id_MSH_6 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.22 %} + {% if firstSegments.MSH.22.1 != "" and firstSegments.MSH.22.1 != null -%} + {% evaluate organization_Id_MSH_22 using 'ID/Organization' XON: firstSegments.MSH.22 -%} + {% include 'Resource/Organization' MSHXON1: firstSegments.MSH.22, ID: organization_Id_MSH_22 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.23 %} + {% if firstSegments.MSH.23.1 != "" and firstSegments.MSH.23.1 != null -%} + {% evaluate organization_Id_MSH_23 using 'ID/Organization' XON: firstSegments.MSH.23 -%} + {% include 'Resource/Organization' MSHXON2: firstSegments.MSH.23, ID: organization_Id_MSH_23 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.3 and firstSegments.MSH.24 %} + {% evaluate device_Id_MSH_3 using 'ID/Device' HD: firstSegments.MSH.3 -%} + {% include 'Resource/Device' MSH: firstSegments.MSH, ID: device_Id_MSH_3 -%} + {% endif -%} + + {% endif -%} + + {% if firstSegments.SCH -%} + {% assign nteSegmentSchLists = hl7v2Data | get_segment_lists: 'NTE' -%} + {% evaluate appointmentID using 'ID/Appointment' SCH: firstSegments.SCH, baseId: patientId-%} + {% include 'Resource/Appointment' SCH: firstSegments.SCH, ID: appointmentID, pidseg: pidSegmentLists, TQ1:tq1SegmentLists.TQ1[0], NTE: nteSegmentSchLists.NTE[0] -%} + {% if firstSegments.SCH.12 -%} + {% if firstSegments.SCH.12.9.1 != "" and firstSegments.SCH.12.9.1 != null and firstSegments.SCH.12.9.2 != "" and firstSegments.SCH.12.9.2 != null and firstSegments.SCH.12.9.3 != "" and firstSegments.SCH.12.9.3 != null -%} + {% evaluate Organization_ID_SCH_12 using 'ID/Organization' HDORG: firstSegments.SCH.12.9 -%} + {% include 'Resource/Organization' OBX: firstSegments.SCH.12.9, ID: Organization_ID_SCH_12 -%} + {% endif -%} + {% evaluate practitionerId_SCH_12 using 'ID/Practitioner' XCN: firstSegments.SCH.12 -%} + {% include 'Resource/Practitioner' SCH_12: firstSegments.SCH, ID: practitionerId_SCH_12 -%} + + {% evaluate practitionerRoleId_SCH_12 using 'ID/PractitionerRole' XCN: firstSegments.SCH.12 -%} + {% include 'Resource/PractitionerRole' SCH_12: firstSegments.SCH, ID: practitionerRoleId_SCH_12, REF_SCH_12: practitionerId_SCH_12 -%} + + {% include 'Resource/PLLocation' PL: firstSegments.SCH.15 -%} + + {% endif -%} + {% if firstSegments.SCH.16 -%} + {% if firstSegments.SCH.16.9.1 != "" and firstSegments.SCH.16.9.1 != null and firstSegments.SCH.16.9.2 != "" and firstSegments.SCH.16.9.2 != null and firstSegments.SCH.16.9.3 != "" and firstSegments.SCH.16.9.3 != null -%} + {% evaluate Organization_ID_SCH_16 using 'ID/Organization' HDORG: firstSegments.SCH.16.9 -%} + {% include 'Resource/Organization' OBX: firstSegments.SCH.16.9, ID: Organization_ID_SCH_16 -%} + {% endif -%} + {% evaluate practitionerId_SCH_16 using 'ID/Practitioner' XCN: firstSegments.SCH.16 -%} + {% include 'Resource/Practitioner' SCH_16: firstSegments.SCH, ID: practitionerId_SCH_16 -%} + + {% evaluate practitionerRoleId_SCH_16 using 'ID/PractitionerRole' XCN: firstSegments.SCH.16 -%} + {% include 'Resource/PractitionerRole' SCH_16: firstSegments.SCH, ID: practitionerRoleId_SCH_16, REF_SCH_16: practitionerId_SCH_16 -%} + + {% include 'Resource/PLLocation' PL: firstSegments.SCH.19 -%} + + {% endif -%} + {% if firstSegments.SCH.20 -%} + {% if firstSegments.SCH.20.9.1 != "" and firstSegments.SCH.20.9.1 != null and firstSegments.SCH.20.9.2 != "" and firstSegments.SCH.20.9.2 != null and firstSegments.SCH.20.9.3 != "" and firstSegments.SCH.20.9.3 != null -%} + {% evaluate Organization_ID_SCH_20 using 'ID/Organization' HDORG: firstSegments.SCH.20.9 -%} + {% include 'Resource/Organization' OBX: firstSegments.SCH.20.9, ID: Organization_ID_SCH_20 -%} + {% endif -%} + {% evaluate practitionerId_SCH_20 using 'ID/Practitioner' XCN: firstSegments.SCH.20 -%} + {% include 'Resource/Practitioner' SCH_20: firstSegments.SCH, ID: practitionerId_SCH_20 -%} + + {% evaluate practitionerRoleId_SCH_20 using 'ID/PractitionerRole' XCN: firstSegments.SCH.20 -%} + {% include 'Resource/PractitionerRole' SCH_20: firstSegments.SCH, ID: practitionerRoleId_SCH_20, REF_SCH_20: practitionerId_SCH_20 -%} + + {% include 'Resource/PLLocation' PL: firstSegments.SCH.22 -%} + + {% endif -%} + {% endif -%} + + {% for pidSegment in pidSegmentLists.PID -%} + {% evaluate patientId using 'ID/Patient' PID: pidSegment, type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + + {% assign pd1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PD1' -%} + {% assign pd1Segment = pd1SegmentLists.PD1[0] %} + {% assign pv1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PV1' -%} + {% assign pv1Segment = pv1SegmentLists.PV1[0] %} + {% assign pv2SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PV2' -%} + {% assign pv2Segment = pv2SegmentLists.PV2[0] %} + {% assign obxSegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'OBX' -%} + {% assign dg1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'DG1' -%} + + + {% include 'Resource/Patient' PID: pidSegment, PD1: pd1Segment, ID: patientId -%} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, PID: pidSegment, PD1: pd1Segment, PV1: pv1Segment -%} + + {% if pidSegment.18 -%} + {% evaluate accountId using 'ID/Account' CX: pidSegment.3 -%} + {% include 'Resource/Account' PID: pidSegment, ID: accountId -%} + {% include 'Reference/Account/Subject' ID: accountId, REF: fullPatientId -%} + {% if pidSegment.18.4.1 != "" and pidSegment.18.4.1 != null and pidSegment.18.4.2 != "" and pidSegment.18.4.2 != null and pidSegment.18.4.3 != "" and pidSegment.18.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_18 using 'ID/Organization' HDORG: pidSegment.18.4 -%} + {% include 'Resource/Organization', PID: pidSegment.18, ID: Organization_ID_pid_CX_18 -%} + {% endif -%} + {% endif -%} + + {% if pidSegment.2 -%} + {% if pidSegment.2.4.1 != "" and pidSegment.2.4.1 != null and pidSegment.2.4.2 != "" and pidSegment.2.4.2 != null and pidSegment.2.4.3 != "" and pidSegment.2.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_2 using 'ID/Organization' HDORG: pidSegment.2.4 -%} + {% include 'Resource/Organization', PID: pidSegment.2, ID: Organization_ID_pid_CX_2 -%} + {% endif -%} + {% endif -%} + {% for pid3 in pidSegment.3.Repeats -%} + {% if pid3.4.1 != "" and pid3.4.1 != null and pid3.4.2 != "" and pid3.4.2 != null and pid3.4.3 != "" and pid3.4.3 != null -%} + {% evaluate Organization_ID_pid_CX using 'ID/Organization' HDORG: pid3.4 -%} + {% include 'Resource/Organization', PID: pid3, ID: Organization_ID_pid_CX -%} + {% endif -%} + {% endfor -%} + {% if pidSegment.4 -%} + {% if pidSegment.4.4.1 != "" and pidSegment.4.4.1 != null and pidSegment.4.4.2 != "" and pidSegment.4.4.2 != null and pidSegment.4.4.3 != "" and pidSegment.4.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_4 using 'ID/Organization' HDORG: pidSegment.4.4 -%} + {% include 'Resource/Organization', PID: pidSegment.4, ID: Organization_ID_pid_CX_4 -%} + {% endif -%} + {% endif -%} + + {% unless nk1SegmentLists.NK1 -%} + {% if pidSegment.21 -%} + {% if pidSegment.21.4.1 != "" and pidSegment.21.4.1 != null and pidSegment.21.4.2 != "" and pidSegment.21.4.2 != null and pidSegment.21.4.3 != "" and pidSegment.21.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_21 using 'ID/Organization' HDORG: pidSegment.21.4 -%} + {% include 'Resource/Organization', PID: pidSegment.21, ID: Organization_ID_pid_CX_21 -%} + {% endif -%} + {% evaluate pidrelatedPersonId using 'ID/RelatedPerson' PID: pidSegment, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: pidrelatedPersonId, PID: pidSegment -%} + {% endif -%} + {% endunless -%} + + {% if pd1Segment.3 -%} + {% evaluate Organization_ID_PD1_3 using 'ID/Organization' XON: pd1Segment.3 -%} + {% include 'Resource/Organization' PD1: pd1Segment, ID: Organization_ID_PD1_3 -%} + {% endif -%} + + {% if pd1Segment.4 -%} + {% if pd1Segment.4.9.1 != "" and pd1Segment.4.9.1 != null and pd1Segment.4.9.2 != "" and pd1Segment.4.9.2 != null and pd1Segment.4.9.3 != "" and pd1Segment.4.9.3 != null -%} + {% evaluate Organization_ID_PD1_4_9 using 'ID/Organization' HDORG: pd1Segment.4.9 -%} + {% include 'Resource/Organization', PD1_4: pd1Segment.4.9, ID: Organization_ID_PD1_4_9 -%} + {% endif -%} + {% evaluate Practitioner_ID_PD1_4 using 'ID/Practitioner' XCN: pd1Segment.4 -%} + {% include 'Resource/Practitioner' PD1: pd1Segment.4, ID: Practitioner_ID_PD1_4 -%} + {% endif -%} + + + {% if pv1Segment -%} + {% if pv1Segment.5 -%} + {% if pv1Segment.5.4.1 != "" and pv1Segment.5.4.1 != null and pv1Segment.5.4.2 != "" and pv1Segment.5.4.2 != null and pv1Segment.5.4.3 != "" and pv1Segment.5.4.3 != null -%} + {% evaluate Organization_ID_PV1_5_4 using 'ID/Organization' HDORG: pv1Segment.5.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.5.4, ID: Organization_ID_PV1_5_4 -%} + {% endif -%} + {% endif -%} + + {% if pv1Segment.19 -%} + {% if pv1Segment.19.4.1 != "" and pv1Segment.19.4.1 != null and pv1Segment.19.4.2 != "" and pv1Segment.19.4.2 != null and pv1Segment.19.4.3 != "" and pv1Segment.19.4.3 != null -%} + {% evaluate Organization_ID_PV1_19_4 using 'ID/Organization' HDORG: pv1Segment.19.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.19.4, ID: Organization_ID_PV1_19_4 -%} + {% endif -%} + {% endif -%} + + {% if pv1Segment.7 -%} + {% if pv1Segment.7.9.1 != "" and pv1Segment.7.9.1 != null and pv1Segment.7.9.2 != "" and pv1Segment.7.9.2 != null and pv1Segment.7.9.3 != "" and pv1Segment.7.9.3 != null -%} + {% evaluate Organization_ID_PV1_7_9 using 'ID/Organization' HDORG: pv1Segment.7.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.7.9, ID: Organization_ID_PV1_7_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_7 using 'ID/Practitioner' XCN: pv1Segment.7 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.7, ID: practitionerId_PV1_7 -%} + {% endif -%} + + {% if pv1Segment.8 -%} + {% if pv1Segment.8.9.1 != "" and pv1Segment.8.9.1 != null and pv1Segment.8.9.2 != "" and pv1Segment.8.9.2 != null and pv1Segment.8.9.3 != "" and pv1Segment.8.9.3 != null -%} + {% evaluate Organization_ID_PV1_8_9 using 'ID/Organization' HDORG: pv1Segment.8.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.8.9, ID: Organization_ID_PV1_8_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_8 using 'ID/Practitioner' XCN: pv1Segment.8 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.8, ID: practitionerId_PV1_8 -%} + {% endif -%} + + {% if pv1Segment.9 -%} + {% if pv1Segment.9.9.1 != "" and pv1Segment.9.9.1 != null and pv1Segment.9.9.2 != "" and pv1Segment.9.9.2 != null and pv1Segment.9.9.3 != "" and pv1Segment.9.9.3 != null -%} + {% evaluate Organization_ID_PV1_9_9 using 'ID/Organization' HDORG: pv1Segment.9.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.9.9, ID: Organization_ID_PV1_9_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_9 using 'ID/Practitioner' XCN: pv1Segment.9 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.9, ID: practitionerId_PV1_9 -%} + {% endif -%} + + {% if pv1Segment.17 -%} + {% if pv1Segment.17.9.1 != "" and pv1Segment.17.9.1 != null and pv1Segment.17.9.2 != "" and pv1Segment.17.9.2 != null and pv1Segment.17.9.3 != "" and pv1Segment.17.9.3 != null -%} + {% evaluate Organization_ID_PV1_17_9 using 'ID/Organization' HDORG: pv1Segment.17.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.17.9, ID: Organization_ID_PV1_17_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_17 using 'ID/Practitioner' XCN: pv1Segment.17 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.17, ID: practitionerId_PV1_17 -%} + {% endif -%} + + {% if pv1Segment.50 -%} + {% for p in pv1Segment.50.Repeats -%} + {% if p.4.1 != "" and p.4.1 != null and p.4.2 != "" and p.4.2 != null and p.4.3 != "" and p.4.3 != null -%} + {% evaluate Organization_ID_PV1_50_4 using 'ID/Organization' HDORG: p.4 -%} + {% include 'Resource/Organization', PV1: p.4, ID: Organization_ID_PV1_50_4 -%} + {% endif -%} + {% endfor -%} + {% endif -%} + + {% if pv1Segment.52 -%} + {% if pv1Segment.52.9.1 != "" and pv1Segment.52.9.1 != null and pv1Segment.52.9.2 != "" and pv1Segment.52.9.2 != null and pv1Segment.52.9.3 != "" and pv1Segment.52.9.3 != null -%} + {% evaluate Organization_ID_PV1_52_9 using 'ID/Organization' HDORG: pv1Segment.52.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.52.9, ID: Organization_ID_PV1_52_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_52 using 'ID/Practitioner' XCN: pv1Segment.52 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.52, ID: practitionerId_PV1_52 -%} + {% endif -%} + + {% if pv2Segment.13 -%} + {% if pv2Segment.13.9.1 != "" and pv2Segment.13.9.1 != null and pv2Segment.13.9.2 != "" and pv2Segment.13.9.2 != null and pv2Segment.13.9.3 != "" and pv2Segment.13.9.3 != null -%} + {% evaluate Organization_ID_PV2_13_9 using 'ID/Organization' HDORG: pv2Segment.13.9 -%} + {% include 'Resource/Organization', PV2: pv2Segment.13.9, ID: Organization_ID_PV2_13_9 -%} + {% endif -%} + {% evaluate practitionerId_PV2_13 using 'ID/Practitioner' XCN: pv2Segment.13 -%} + {% include 'Resource/Practitioner' PV1: pv2Segment.13, ID: practitionerId_PV2_13 -%} + {% endif -%} + + {% if pv1Segment.3 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.3-%} + {% endif -%} + + {% if pv1Segment.6 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.6 -%} + {% endif -%} + + {% if pv1Segment.37 -%} + {% evaluate location_ID_PV1_37 using 'ID/Location' DLD: pv1Segment.37 -%} + {% include 'Resource/Location' PV1: pv1Segment.37, ID: location_ID_PV1_37-%} + {% endif -%} + + {% if pv1Segment.42 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.42-%} + {% endif -%} + + {% if pv1Segment.43 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.43-%} + {% endif -%} + + {% if pv2Segment.1 -%} + {% include 'Resource/PLLocation' PL: pv2Segment.1-%} + {% endif -%} + + {% if pv1Segment.54 -%} + {% if pv1Segment.54.4.1 != "" and pv1Segment.54.4.1 != null and pv1Segment.54.4.2 != "" and pv1Segment.54.4.2 != null and pv1Segment.54.4.3 != "" and pv1Segment.54.4.3 != null -%} + {% evaluate Organization_ID_PV1_54_4 using 'ID/Organization' HDORG: pv1Segment.54.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.54.4, ID: Organization_ID_PV1_54_4 -%} + {% endif -%} + {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: pv1Segment.54 -%} + {% include 'Resource/EpisodeOfCare' PV1: pv1Segment, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId -%} + {% endif -%} + + {% evaluate encounterId using 'ID/Encounter' PV1: pv1Segment, baseId: patientId -%} + {% assign fullEncounterId = encounterId | prepend: 'Encounter/' -%} + {% include 'Resource/Encounter' Root_Template: 'SIU_S12', PV1: pv1Segment, PV2: pv2Segment, ID: encounterId -%} + {% include 'Reference/Encounter/Subject' ID: encounterId, REF: fullPatientId -%} + {% include 'Extensions/Encounter/EncounterExtension' ID: encounterId, PV1: pv1Segment, PV2: pv2Segment -%} + {% endif -%} + + + {% for obxSegment in obxSegmentLists.OBX -%} + + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16 -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16 -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + + {% if obxSegment.18 -%} + {% evaluate deviceId_OBX_18 using 'ID/Device' EI: obxSegment.18.Repeats[0] -%} + {% include 'Resource/Device' EI_OBX18: obxSegment.18, ID: deviceId_OBX_18 -%} + {% endif -%} + + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23 -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + + {% evaluate observationId using 'ID/Observation' OBX: obxSegment, baseId: patientId -%} + + {% include 'Resource/Observation' OBX: obxSegment, Observation_Subject_ID: fullPatientId, ID: observationId -%} + {% include 'Extensions/Observation/ObservationExtension' OBX: obxSegment, ID: observationId %} + + {% endfor -%} + + {% for dg1Segment in dg1SegmentLists.DG1 -%} + + {% if dg1Segment.16.Repeats[0] %} + {% if dg1Segment.16.Repeats[0].9.1 != "" and dg1Segment.16.Repeats[0].9.1 != null and dg1Segment.16.Repeats[0].9.2 != "" and dg1Segment.16.Repeats[0].9.2 != null and dg1Segment.16.Repeats[0].9.3 != "" and dg1Segment.16.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_DG1_16 using 'ID/Organization' HDORG: dg1Segment.16.Repeats[0].9 -%} + {% include 'Resource/Organization', DG1: dg1Segment.16.Repeats[0].9, ID: Organization_ID_DG1_16 -%} + {% endif -%} + {% evaluate practitionerId_DG1_16 using 'ID/Practitioner' XCN: dg1Segment.16.Repeats[0] -%} + {% include 'Resource/Practitioner' DG1: dg1Segment, ID: practitionerId_DG1_16 -%} + {% endif -%} + + {% evaluate conditionId using 'ID/Condition' DG1: dg1Segment, baseId: patientId -%} + {% include 'Resource/Condition' DG1: dg1Segment, Condition_Subject_ID: fullPatientId, baseId: patientId, ID: conditionId -%} + + {% if encounterId -%} + {% include 'Resource/Encounter' DG1: dg1Segment, conditionId: conditionId, ID: encounterId -%} + {% endif %} + + {% if EpisodeOfCare_ID %} + {% include 'Resource/EpisodeOfCare' DG1: dg1Segment, conditionId: conditionId, ID: EpisodeOfCare_ID -%} + {% endif %} + + {% if dg1Segment.22 %} + {% evaluate conditionId_DG1_22 using 'ID/Condition' DG1: dg1Segment.22, baseId: patientId -%} + {% include 'Resource/Condition' DG1_22: dg1Segment.22, Condition_Subject_ID_DG1_22: fullPatientId, ID: conditionId_DG1_22 -%} + {% endif %} + {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} + {% endfor -%} + + {% endfor -%} + + {% for rgsSegment in rgsSegmentLists.RGS -%} + {% evaluate patientId using 'ID/Patient' PID: pidSegmentLists.PID[0], type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% assign aisSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIS' -%} + {% assign ailSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIL' -%} + {% assign aigSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIG' -%} + {% assign aipSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIP' -%} + + {% for aisSegment in aisSegmentLists.AIS -%} + {% assign nteSegmentLists = hl7v2Data | get_related_segment_list: aisSegment, 'NTE' -%} + {% evaluate serviceRequestId using 'ID/ServiceRequest' AIS: aisSegment, baseId: patientId -%} + {% include 'Resource/ServiceRequest' AIS: aisSegment, ID: serviceRequestId, ServiceRequest_Subject_ID: fullPatientId, ServiceRequest_Encounter_ID: fullEncounterId -%} + {% assign fullServiceRequestId = serviceRequestId | prepend: 'ServiceRequest/' -%} + {% include 'Reference/Appointment/BasedOn' ID: appointmentID, REF: fullServiceRequestId -%} + {% for nteSegment in nteSegmentLists.NTE -%} + {% if nteSegment.5 -%} + {% if nteSegment.5.9.1 != "" and nteSegment.5.9.1 != null and nteSegment.5.9.2 != "" and nteSegment.5.9.2 != null and nteSegment.5.9.3 != "" and nteSegment.5.9.3 != null -%} + {% evaluate Organization_ID_EVN_5_9 using 'ID/Organization' HDORG: nteSegment.5.9 -%} + {% include 'Resource/Organization', PV2: nteSegment.5.9, ID: Organization_ID_EVN_5_9 -%} + {% endif -%} + {% evaluate Practitioner_ID_NTE_5 using 'ID/Practitioner' XCN: nteSegment.5 -%} + {% include 'Resource/Practitioner' NTE: nteSegment.5, ID: Practitioner_ID_NTE_5 -%} + {% endif -%} + {% include 'Resource/ServiceRequest' NTE: nteSegment, ID: serviceRequestId -%} + {% endfor -%} + {% endfor -%} + + {% for aigSegment in aigSegmentLists.AIG -%} + {% assign nteSegmentLists = hl7v2Data | get_related_segment_list: aigSegment, 'NTE' -%} + {% evaluate device_Id_AIG_3 using 'ID/Device' AIG: aigSegment -%} + {% include 'Resource/Device' AIG: aigSegment, ID: device_Id_AIG_3 -%} + {% include 'Resource/Appointment' AIG: aigSegment, ID: appointmentID -%} + {% assign fullDevice_Id_AIG_3 = device_Id_AIG_3 | prepend: 'Device/' -%} + {% if aisSegmentLists.AIS -%} + {% include 'Reference/ServiceRequest/Performer' ID: serviceRequestId, REF: fullDevice_Id_AIG_3 -%} + {% endif -%} + {% for nteSegment in nteSegmentLists.NTE -%} + {% include 'Resource/Device' NTE: nteSegment, ID: device_Id_AIG_3 -%} + {% endfor -%} + {% endfor -%} + + {% for ailSegment in ailSegmentLists.AIL -%} + {% assign nteSegmentLists = hl7v2Data | get_related_segment_list: ailSegment, 'NTE' -%} + {% include 'Resource/PLLocation' PL: ailSegment.3, AIL_4: ailSegment.4 -%} + {% for nteSegment in nteSegmentLists.NTE -%} + {% include 'Resource/PLLocation' PL: ailSegment.3, NTE: nteSegment -%} + {% endfor -%} + + {% if ailSegment.3.1 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.1 -%} + {% elseif ailSegment.3.2 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.2 -%} + {% elseif ailSegment.3.3 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.3 -%} + {% elseif ailSegment.3.4 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.4 -%} + {% elseif ailSegment.3.7 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.7 -%} + {% elseif ailSegment.3.8 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.8 -%} + {% endif %} + {% assign fullLocation_ID_AIL_3 = Location_ID_AIL_3 | prepend: 'Location/' -%} + {% if aisSegmentLists.AIS -%} + {% include 'Reference/ServiceRequest/LocationReference' ID: serviceRequestId, REF: fullLocation_ID_AIL_3 -%} + {% endif %} + {% include 'Resource/Appointment' AIL: ailSegment, ID: appointmentID -%} + {% endfor -%} + + {% for aipSegment in aipSegmentLists.AIP -%} + {% if aipSegment.3 -%} + {% if aipSegment.3.9.1 != "" and aipSegment.3.9.1 != null and aipSegment.3.9.2 != "" and aipSegment.3.2 != null and aipSegment.3.9.3 != "" and aipSegment.3.9.3 != null -%} + {% evaluate organization_ID_AIP_3_9 using 'ID/Organization' HDORG: aipSegment.3.9 -%} + {% include 'Resource/Organization', AIP: aipSegment.3.9, ID: organization_ID_AIP_3_9 -%} + {% endif -%} + {% evaluate practitioner_ID_AIP_3 using 'ID/Practitioner' XCN: aipSegment.3 -%} + {% include 'Resource/Practitioner' AIP: aipSegment.3, ID: practitioner_ID_AIP_3 -%} + {% assign fullPractitioner_ID_AIP_3 = practitioner_ID_AIP_3 | prepend: 'Practitioner/' -%} + {% if aisSegmentLists.AIS -%} + {% include 'Reference/ServiceRequest/Performer' ID: serviceRequestId, REF: fullPractitioner_ID_AIP_3 -%} + {% endif -%} + {% endif -%} + {% include 'Resource/Appointment' AIP: aipSegment, ID: appointmentID -%} + {% endfor -%} + {% endfor -%} + ] +} \ No newline at end of file diff --git a/data/Templates/Hl7v2/SIU_S13.liquid b/data/Templates/Hl7v2/SIU_S13.liquid new file mode 100644 index 000000000..e1fde434a --- /dev/null +++ b/data/Templates/Hl7v2/SIU_S13.liquid @@ -0,0 +1,476 @@ +{% assign firstSegments = hl7v2Data | get_first_segments: 'MSH|SCH' -%} +{% assign tq1SegmentLists = hl7v2Data | get_segment_lists: 'TQ1' -%} +{% assign pidSegmentLists = hl7v2Data | get_segment_lists: 'PID' -%} +{% assign rgsSegmentLists = hl7v2Data | get_segment_lists: 'RGS' -%} +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} + +{ + "resourceType": "Bundle", + "type": "batch", + {% if firstSegments.MSH.7 -%} + "timestamp":"{{ firstSegments.MSH.7.Value | format_as_date_time }}", + {% endif -%} + "identifier": + { + "value":"{{ firstSegments.MSH.10.Value }}", + }, + "id":"{{ bundleID }}", + "entry": [ + + {% evaluate patientId using 'ID/Patient' PID: pidSegmentLists.PID[0], type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% evaluate messageHeaderId using 'ID/MessageHeader' MSH: firstSegments.MSH -%} + + {% if firstSegments.MSH -%} + + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, ID: messageHeaderId -%} + {% evaluate provenanceId using 'ID/Provenance' MSH: firstSegments.MSH, baseId: patientId -%} + {% include 'Resource/Provenance' Root_Template: 'SIU_S13', MSH: firstSegments.MSH, REF_BUNDLE: bundleID, ID: provenanceId -%} + + {%- comment -%} + {% assign transformation_val = 'provenance_transformation' %} + {% evaluate provenanceOrganizationId using 'ID/Organization', prov_id: firstSegments.MSH -%} + {% evaluate provenanceTransformationId using 'ID/Provenance_transformation' prov_id: transformation_val -%} + {% include 'Resource/Organization' org_name: 'Microsoft Corporation', ID: provenanceOrganizationId -%} + {% include 'Resource/Provenance_transformation' Root_Template: 'ADT_A01', Provenance_Organization_ID: provenanceOrganizationId, REF_MSH: messageHeaderId, provenanceOrganizationId, ID: provenanceTransformationId -%} + {%- endcomment -%} + + {% if firstSegments.MSH.4 -%} + {% if firstSegments.MSH.4.1 != "" and firstSegments.MSH.4.1 != null or firstSegments.MSH.4.2 != "" and firstSegments.MSH.4.2 != null or firstSegments.MSH.4.3 != "" and firstSegments.MSH.4.3 != null -%} + {% evaluate organization_ID_MSH_4 using 'ID/Organization' HD: firstSegments.MSH.4 -%} + {% include 'Resource/Organization' MSHHD1: firstSegments.MSH.4, MSH: firstSegments.MSH, ID: organization_ID_MSH_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.6 %} + {% if firstSegments.MSH.6.1 != "" and firstSegments.MSH.6.1 != null or firstSegments.MSH.6.2 != "" and firstSegments.MSH.6.2 != null or firstSegments.MSH.6.3 != "" and firstSegments.MSH.6.3 != null -%} + {% evaluate organization_Id_MSH_6 using 'ID/Organization' HD: firstSegments.MSH.6 -%} + {% include 'Resource/Organization' MSHHD2: firstSegments.MSH.6, MSH: firstSegments.MSH, ID: organization_Id_MSH_6 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.22 %} + {% if firstSegments.MSH.22.1 != "" and firstSegments.MSH.22.1 != null -%} + {% evaluate organization_Id_MSH_22 using 'ID/Organization' XON: firstSegments.MSH.22 -%} + {% include 'Resource/Organization' MSHXON1: firstSegments.MSH.22, ID: organization_Id_MSH_22 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.23 %} + {% if firstSegments.MSH.23.1 != "" and firstSegments.MSH.23.1 != null -%} + {% evaluate organization_Id_MSH_23 using 'ID/Organization' XON: firstSegments.MSH.23 -%} + {% include 'Resource/Organization' MSHXON2: firstSegments.MSH.23, ID: organization_Id_MSH_23 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.3 and firstSegments.MSH.24 %} + {% evaluate device_Id_MSH_3 using 'ID/Device' HD: firstSegments.MSH.3 -%} + {% include 'Resource/Device' MSH: firstSegments.MSH, ID: device_Id_MSH_3 -%} + {% endif -%} + + {% endif -%} + + {% if firstSegments.SCH -%} + {% assign nteSegmentSchLists = hl7v2Data | get_segment_lists: 'NTE' -%} + {% evaluate appointmentID using 'ID/Appointment' SCH: firstSegments.SCH, baseId: patientId-%} + {% include 'Resource/Appointment' SCH: firstSegments.SCH, ID: appointmentID, pidseg: pidSegmentLists, TQ1:tq1SegmentLists.TQ1[0], NTE: nteSegmentSchLists.NTE[0] -%} + {% if firstSegments.SCH.12 -%} + {% if firstSegments.SCH.12.9.1 != "" and firstSegments.SCH.12.9.1 != null and firstSegments.SCH.12.9.2 != "" and firstSegments.SCH.12.9.2 != null and firstSegments.SCH.12.9.3 != "" and firstSegments.SCH.12.9.3 != null -%} + {% evaluate Organization_ID_SCH_12 using 'ID/Organization' HDORG: firstSegments.SCH.12.9 -%} + {% include 'Resource/Organization' OBX: firstSegments.SCH.12.9, ID: Organization_ID_SCH_12 -%} + {% endif -%} + {% evaluate practitionerId_SCH_12 using 'ID/Practitioner' XCN: firstSegments.SCH.12 -%} + {% include 'Resource/Practitioner' SCH_12: firstSegments.SCH, ID: practitionerId_SCH_12 -%} + + {% evaluate practitionerRoleId_SCH_12 using 'ID/PractitionerRole' XCN: firstSegments.SCH.12 -%} + {% include 'Resource/PractitionerRole' SCH_12: firstSegments.SCH, ID: practitionerRoleId_SCH_12, REF_SCH_12: practitionerId_SCH_12 -%} + + {% include 'Resource/PLLocation' PL: firstSegments.SCH.15 -%} + + {% endif -%} + {% if firstSegments.SCH.16 -%} + {% if firstSegments.SCH.16.9.1 != "" and firstSegments.SCH.16.9.1 != null and firstSegments.SCH.16.9.2 != "" and firstSegments.SCH.16.9.2 != null and firstSegments.SCH.16.9.3 != "" and firstSegments.SCH.16.9.3 != null -%} + {% evaluate Organization_ID_SCH_16 using 'ID/Organization' HDORG: firstSegments.SCH.16.9 -%} + {% include 'Resource/Organization' OBX: firstSegments.SCH.16.9, ID: Organization_ID_SCH_16 -%} + {% endif -%} + {% evaluate practitionerId_SCH_16 using 'ID/Practitioner' XCN: firstSegments.SCH.16 -%} + {% include 'Resource/Practitioner' SCH_16: firstSegments.SCH, ID: practitionerId_SCH_16 -%} + + {% evaluate practitionerRoleId_SCH_16 using 'ID/PractitionerRole' XCN: firstSegments.SCH.16 -%} + {% include 'Resource/PractitionerRole' SCH_16: firstSegments.SCH, ID: practitionerRoleId_SCH_16, REF_SCH_16: practitionerId_SCH_16 -%} + + {% include 'Resource/PLLocation' PL: firstSegments.SCH.19 -%} + + {% endif -%} + {% if firstSegments.SCH.20 -%} + {% if firstSegments.SCH.20.9.1 != "" and firstSegments.SCH.20.9.1 != null and firstSegments.SCH.20.9.2 != "" and firstSegments.SCH.20.9.2 != null and firstSegments.SCH.20.9.3 != "" and firstSegments.SCH.20.9.3 != null -%} + {% evaluate Organization_ID_SCH_20 using 'ID/Organization' HDORG: firstSegments.SCH.20.9 -%} + {% include 'Resource/Organization' OBX: firstSegments.SCH.20.9, ID: Organization_ID_SCH_20 -%} + {% endif -%} + {% evaluate practitionerId_SCH_20 using 'ID/Practitioner' XCN: firstSegments.SCH.20 -%} + {% include 'Resource/Practitioner' SCH_20: firstSegments.SCH, ID: practitionerId_SCH_20 -%} + + {% evaluate practitionerRoleId_SCH_20 using 'ID/PractitionerRole' XCN: firstSegments.SCH.20 -%} + {% include 'Resource/PractitionerRole' SCH_20: firstSegments.SCH, ID: practitionerRoleId_SCH_20, REF_SCH_20: practitionerId_SCH_20 -%} + + {% include 'Resource/PLLocation' PL: firstSegments.SCH.22 -%} + + {% endif -%} + {% endif -%} + + {% for pidSegment in pidSegmentLists.PID -%} + {% evaluate patientId using 'ID/Patient' PID: pidSegment, type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + + {% assign pd1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PD1' -%} + {% assign pd1Segment = pd1SegmentLists.PD1[0] %} + {% assign pv1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PV1' -%} + {% assign pv1Segment = pv1SegmentLists.PV1[0] %} + {% assign pv2SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PV2' -%} + {% assign pv2Segment = pv2SegmentLists.PV2[0] %} + {% assign obxSegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'OBX' -%} + {% assign dg1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'DG1' -%} + + + {% include 'Resource/Patient' PID: pidSegment, PD1: pd1Segment, ID: patientId -%} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, PID: pidSegment, PD1: pd1Segment, PV1: pv1Segment -%} + + {% if pidSegment.18 -%} + {% evaluate accountId using 'ID/Account' CX: pidSegment.3 -%} + {% include 'Resource/Account' PID: pidSegment, ID: accountId -%} + {% include 'Reference/Account/Subject' ID: accountId, REF: fullPatientId -%} + {% if pidSegment.18.4.1 != "" and pidSegment.18.4.1 != null and pidSegment.18.4.2 != "" and pidSegment.18.4.2 != null and pidSegment.18.4.3 != "" and pidSegment.18.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_18 using 'ID/Organization' HDORG: pidSegment.18.4 -%} + {% include 'Resource/Organization', PID: pidSegment.18, ID: Organization_ID_pid_CX_18 -%} + {% endif -%} + {% endif -%} + + {% if pidSegment.2 -%} + {% if pidSegment.2.4.1 != "" and pidSegment.2.4.1 != null and pidSegment.2.4.2 != "" and pidSegment.2.4.2 != null and pidSegment.2.4.3 != "" and pidSegment.2.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_2 using 'ID/Organization' HDORG: pidSegment.2.4 -%} + {% include 'Resource/Organization', PID: pidSegment.2, ID: Organization_ID_pid_CX_2 -%} + {% endif -%} + {% endif -%} + {% for pid3 in pidSegment.3.Repeats -%} + {% if pid3.4.1 != "" and pid3.4.1 != null and pid3.4.2 != "" and pid3.4.2 != null and pid3.4.3 != "" and pid3.4.3 != null -%} + {% evaluate Organization_ID_pid_CX using 'ID/Organization' HDORG: pid3.4 -%} + {% include 'Resource/Organization', PID: pid3, ID: Organization_ID_pid_CX -%} + {% endif -%} + {% endfor -%} + {% if pidSegment.4 -%} + {% if pidSegment.4.4.1 != "" and pidSegment.4.4.1 != null and pidSegment.4.4.2 != "" and pidSegment.4.4.2 != null and pidSegment.4.4.3 != "" and pidSegment.4.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_4 using 'ID/Organization' HDORG: pidSegment.4.4 -%} + {% include 'Resource/Organization', PID: pidSegment.4, ID: Organization_ID_pid_CX_4 -%} + {% endif -%} + {% endif -%} + + {% unless nk1SegmentLists.NK1 -%} + {% if pidSegment.21 -%} + {% if pidSegment.21.4.1 != "" and pidSegment.21.4.1 != null and pidSegment.21.4.2 != "" and pidSegment.21.4.2 != null and pidSegment.21.4.3 != "" and pidSegment.21.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_21 using 'ID/Organization' HDORG: pidSegment.21.4 -%} + {% include 'Resource/Organization', PID: pidSegment.21, ID: Organization_ID_pid_CX_21 -%} + {% endif -%} + {% evaluate pidrelatedPersonId using 'ID/RelatedPerson' PID: pidSegment, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: pidrelatedPersonId, PID: pidSegment -%} + {% endif -%} + {% endunless -%} + + {% if pd1Segment.3 -%} + {% evaluate Organization_ID_PD1_3 using 'ID/Organization' XON: pd1Segment.3 -%} + {% include 'Resource/Organization' PD1: pd1Segment, ID: Organization_ID_PD1_3 -%} + {% endif -%} + + {% if pd1Segment.4 -%} + {% if pd1Segment.4.9.1 != "" and pd1Segment.4.9.1 != null and pd1Segment.4.9.2 != "" and pd1Segment.4.9.2 != null and pd1Segment.4.9.3 != "" and pd1Segment.4.9.3 != null -%} + {% evaluate Organization_ID_PD1_4_9 using 'ID/Organization' HDORG: pd1Segment.4.9 -%} + {% include 'Resource/Organization', PD1_4: pd1Segment.4.9, ID: Organization_ID_PD1_4_9 -%} + {% endif -%} + {% evaluate Practitioner_ID_PD1_4 using 'ID/Practitioner' XCN: pd1Segment.4 -%} + {% include 'Resource/Practitioner' PD1: pd1Segment.4, ID: Practitioner_ID_PD1_4 -%} + {% endif -%} + + + {% if pv1Segment -%} + {% if pv1Segment.5 -%} + {% if pv1Segment.5.4.1 != "" and pv1Segment.5.4.1 != null and pv1Segment.5.4.2 != "" and pv1Segment.5.4.2 != null and pv1Segment.5.4.3 != "" and pv1Segment.5.4.3 != null -%} + {% evaluate Organization_ID_PV1_5_4 using 'ID/Organization' HDORG: pv1Segment.5.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.5.4, ID: Organization_ID_PV1_5_4 -%} + {% endif -%} + {% endif -%} + + {% if pv1Segment.19 -%} + {% if pv1Segment.19.4.1 != "" and pv1Segment.19.4.1 != null and pv1Segment.19.4.2 != "" and pv1Segment.19.4.2 != null and pv1Segment.19.4.3 != "" and pv1Segment.19.4.3 != null -%} + {% evaluate Organization_ID_PV1_19_4 using 'ID/Organization' HDORG: pv1Segment.19.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.19.4, ID: Organization_ID_PV1_19_4 -%} + {% endif -%} + {% endif -%} + + {% if pv1Segment.7 -%} + {% if pv1Segment.7.9.1 != "" and pv1Segment.7.9.1 != null and pv1Segment.7.9.2 != "" and pv1Segment.7.9.2 != null and pv1Segment.7.9.3 != "" and pv1Segment.7.9.3 != null -%} + {% evaluate Organization_ID_PV1_7_9 using 'ID/Organization' HDORG: pv1Segment.7.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.7.9, ID: Organization_ID_PV1_7_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_7 using 'ID/Practitioner' XCN: pv1Segment.7 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.7, ID: practitionerId_PV1_7 -%} + {% endif -%} + + {% if pv1Segment.8 -%} + {% if pv1Segment.8.9.1 != "" and pv1Segment.8.9.1 != null and pv1Segment.8.9.2 != "" and pv1Segment.8.9.2 != null and pv1Segment.8.9.3 != "" and pv1Segment.8.9.3 != null -%} + {% evaluate Organization_ID_PV1_8_9 using 'ID/Organization' HDORG: pv1Segment.8.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.8.9, ID: Organization_ID_PV1_8_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_8 using 'ID/Practitioner' XCN: pv1Segment.8 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.8, ID: practitionerId_PV1_8 -%} + {% endif -%} + + {% if pv1Segment.9 -%} + {% if pv1Segment.9.9.1 != "" and pv1Segment.9.9.1 != null and pv1Segment.9.9.2 != "" and pv1Segment.9.9.2 != null and pv1Segment.9.9.3 != "" and pv1Segment.9.9.3 != null -%} + {% evaluate Organization_ID_PV1_9_9 using 'ID/Organization' HDORG: pv1Segment.9.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.9.9, ID: Organization_ID_PV1_9_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_9 using 'ID/Practitioner' XCN: pv1Segment.9 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.9, ID: practitionerId_PV1_9 -%} + {% endif -%} + + {% if pv1Segment.17 -%} + {% if pv1Segment.17.9.1 != "" and pv1Segment.17.9.1 != null and pv1Segment.17.9.2 != "" and pv1Segment.17.9.2 != null and pv1Segment.17.9.3 != "" and pv1Segment.17.9.3 != null -%} + {% evaluate Organization_ID_PV1_17_9 using 'ID/Organization' HDORG: pv1Segment.17.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.17.9, ID: Organization_ID_PV1_17_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_17 using 'ID/Practitioner' XCN: pv1Segment.17 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.17, ID: practitionerId_PV1_17 -%} + {% endif -%} + + {% if pv1Segment.50 -%} + {% for p in pv1Segment.50.Repeats -%} + {% if p.4.1 != "" and p.4.1 != null and p.4.2 != "" and p.4.2 != null and p.4.3 != "" and p.4.3 != null -%} + {% evaluate Organization_ID_PV1_50_4 using 'ID/Organization' HDORG: p.4 -%} + {% include 'Resource/Organization', PV1: p.4, ID: Organization_ID_PV1_50_4 -%} + {% endif -%} + {% endfor -%} + {% endif -%} + + {% if pv1Segment.52 -%} + {% if pv1Segment.52.9.1 != "" and pv1Segment.52.9.1 != null and pv1Segment.52.9.2 != "" and pv1Segment.52.9.2 != null and pv1Segment.52.9.3 != "" and pv1Segment.52.9.3 != null -%} + {% evaluate Organization_ID_PV1_52_9 using 'ID/Organization' HDORG: pv1Segment.52.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.52.9, ID: Organization_ID_PV1_52_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_52 using 'ID/Practitioner' XCN: pv1Segment.52 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.52, ID: practitionerId_PV1_52 -%} + {% endif -%} + + {% if pv2Segment.13 -%} + {% if pv2Segment.13.9.1 != "" and pv2Segment.13.9.1 != null and pv2Segment.13.9.2 != "" and pv2Segment.13.9.2 != null and pv2Segment.13.9.3 != "" and pv2Segment.13.9.3 != null -%} + {% evaluate Organization_ID_PV2_13_9 using 'ID/Organization' HDORG: pv2Segment.13.9 -%} + {% include 'Resource/Organization', PV2: pv2Segment.13.9, ID: Organization_ID_PV2_13_9 -%} + {% endif -%} + {% evaluate practitionerId_PV2_13 using 'ID/Practitioner' XCN: pv2Segment.13 -%} + {% include 'Resource/Practitioner' PV1: pv2Segment.13, ID: practitionerId_PV2_13 -%} + {% endif -%} + + {% if pv1Segment.3 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.3-%} + {% endif -%} + + {% if pv1Segment.6 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.6 -%} + {% endif -%} + + {% if pv1Segment.37 -%} + {% evaluate location_ID_PV1_37 using 'ID/Location' DLD: pv1Segment.37 -%} + {% include 'Resource/Location' PV1: pv1Segment.37, ID: location_ID_PV1_37-%} + {% endif -%} + + {% if pv1Segment.42 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.42-%} + {% endif -%} + + {% if pv1Segment.43 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.43-%} + {% endif -%} + + {% if pv2Segment.1 -%} + {% include 'Resource/PLLocation' PL: pv2Segment.1-%} + {% endif -%} + + {% if pv1Segment.54 -%} + {% if pv1Segment.54.4.1 != "" and pv1Segment.54.4.1 != null and pv1Segment.54.4.2 != "" and pv1Segment.54.4.2 != null and pv1Segment.54.4.3 != "" and pv1Segment.54.4.3 != null -%} + {% evaluate Organization_ID_PV1_54_4 using 'ID/Organization' HDORG: pv1Segment.54.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.54.4, ID: Organization_ID_PV1_54_4 -%} + {% endif -%} + {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: pv1Segment.54 -%} + {% include 'Resource/EpisodeOfCare' PV1: pv1Segment, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId -%} + {% endif -%} + + {% evaluate encounterId using 'ID/Encounter' PV1: pv1Segment, baseId: patientId -%} + {% assign fullEncounterId = encounterId | prepend: 'Encounter/' -%} + {% include 'Resource/Encounter' Root_Template: 'SIU_S13', PV1: pv1Segment, PV2: pv2Segment, ID: encounterId -%} + {% include 'Reference/Encounter/Subject' ID: encounterId, REF: fullPatientId -%} + {% include 'Extensions/Encounter/EncounterExtension' ID: encounterId, PV1: pv1Segment, PV2: pv2Segment -%} + {% endif -%} + + + {% for obxSegment in obxSegmentLists.OBX -%} + + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16 -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16 -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + + {% if obxSegment.18 -%} + {% evaluate deviceId_OBX_18 using 'ID/Device' EI: obxSegment.18.Repeats[0] -%} + {% include 'Resource/Device' EI_OBX18: obxSegment.18, ID: deviceId_OBX_18 -%} + {% endif -%} + + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23 -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + + {% evaluate observationId using 'ID/Observation' OBX: obxSegment, baseId: patientId -%} + + {% include 'Resource/Observation' OBX: obxSegment, Observation_Subject_ID: fullPatientId, ID: observationId -%} + {% include 'Extensions/Observation/ObservationExtension' OBX: obxSegment, ID: observationId %} + + {% endfor -%} + + {% for dg1Segment in dg1SegmentLists.DG1 -%} + + {% if dg1Segment.16.Repeats[0] %} + {% if dg1Segment.16.Repeats[0].9.1 != "" and dg1Segment.16.Repeats[0].9.1 != null and dg1Segment.16.Repeats[0].9.2 != "" and dg1Segment.16.Repeats[0].9.2 != null and dg1Segment.16.Repeats[0].9.3 != "" and dg1Segment.16.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_DG1_16 using 'ID/Organization' HDORG: dg1Segment.16.Repeats[0].9 -%} + {% include 'Resource/Organization', DG1: dg1Segment.16.Repeats[0].9, ID: Organization_ID_DG1_16 -%} + {% endif -%} + {% evaluate practitionerId_DG1_16 using 'ID/Practitioner' XCN: dg1Segment.16.Repeats[0] -%} + {% include 'Resource/Practitioner' DG1: dg1Segment, ID: practitionerId_DG1_16 -%} + {% endif -%} + + {% evaluate conditionId using 'ID/Condition' DG1: dg1Segment, baseId: patientId -%} + {% include 'Resource/Condition' DG1: dg1Segment, Condition_Subject_ID: fullPatientId, baseId: patientId, ID: conditionId -%} + + {% if encounterId -%} + {% include 'Resource/Encounter' DG1: dg1Segment, conditionId: conditionId, ID: encounterId -%} + {% endif %} + + {% if EpisodeOfCare_ID %} + {% include 'Resource/EpisodeOfCare' DG1: dg1Segment, conditionId: conditionId, ID: EpisodeOfCare_ID -%} + {% endif %} + + {% if dg1Segment.22 %} + {% evaluate conditionId_DG1_22 using 'ID/Condition' DG1: dg1Segment.22, baseId: patientId -%} + {% include 'Resource/Condition' DG1_22: dg1Segment.22, Condition_Subject_ID_DG1_22: fullPatientId, ID: conditionId_DG1_22 -%} + {% endif %} + {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} + {% endfor -%} + + {% endfor -%} + + {% for rgsSegment in rgsSegmentLists.RGS -%} + {% evaluate patientId using 'ID/Patient' PID: pidSegmentLists.PID[0], type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% assign aisSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIS' -%} + {% assign ailSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIL' -%} + {% assign aigSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIG' -%} + {% assign aipSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIP' -%} + + {% for aisSegment in aisSegmentLists.AIS -%} + {% assign nteSegmentLists = hl7v2Data | get_related_segment_list: aisSegment, 'NTE' -%} + {% evaluate serviceRequestId using 'ID/ServiceRequest' AIS: aisSegment, baseId: patientId -%} + {% include 'Resource/ServiceRequest' AIS: aisSegment, ID: serviceRequestId, ServiceRequest_Subject_ID: fullPatientId, ServiceRequest_Encounter_ID: fullEncounterId -%} + {% assign fullServiceRequestId = serviceRequestId | prepend: 'ServiceRequest/' -%} + {% include 'Reference/Appointment/BasedOn' ID: appointmentID, REF: fullServiceRequestId -%} + {% for nteSegment in nteSegmentLists.NTE -%} + {% if nteSegment.5 -%} + {% if nteSegment.5.9.1 != "" and nteSegment.5.9.1 != null and nteSegment.5.9.2 != "" and nteSegment.5.9.2 != null and nteSegment.5.9.3 != "" and nteSegment.5.9.3 != null -%} + {% evaluate Organization_ID_EVN_5_9 using 'ID/Organization' HDORG: nteSegment.5.9 -%} + {% include 'Resource/Organization', PV2: nteSegment.5.9, ID: Organization_ID_EVN_5_9 -%} + {% endif -%} + {% evaluate Practitioner_ID_NTE_5 using 'ID/Practitioner' XCN: nteSegment.5 -%} + {% include 'Resource/Practitioner' NTE: nteSegment.5, ID: Practitioner_ID_NTE_5 -%} + {% endif -%} + {% include 'Resource/ServiceRequest' NTE: nteSegment, ID: serviceRequestId -%} + {% endfor -%} + {% endfor -%} + + {% for aigSegment in aigSegmentLists.AIG -%} + {% assign nteSegmentLists = hl7v2Data | get_related_segment_list: aigSegment, 'NTE' -%} + {% evaluate device_Id_AIG_3 using 'ID/Device' AIG: aigSegment -%} + {% include 'Resource/Device' AIG: aigSegment, ID: device_Id_AIG_3 -%} + {% include 'Resource/Appointment' AIG: aigSegment, ID: appointmentID -%} + {% assign fullDevice_Id_AIG_3 = device_Id_AIG_3 | prepend: 'Device/' -%} + {% if aisSegmentLists.AIS -%} + {% include 'Reference/ServiceRequest/Performer' ID: serviceRequestId, REF: fullDevice_Id_AIG_3 -%} + {% endif -%} + {% for nteSegment in nteSegmentLists.NTE -%} + {% include 'Resource/Device' NTE: nteSegment, ID: device_Id_AIG_3 -%} + {% endfor -%} + {% endfor -%} + + {% for ailSegment in ailSegmentLists.AIL -%} + {% assign nteSegmentLists = hl7v2Data | get_related_segment_list: ailSegment, 'NTE' -%} + {% include 'Resource/PLLocation' PL: ailSegment.3, AIL_4: ailSegment.4 -%} + {% for nteSegment in nteSegmentLists.NTE -%} + {% include 'Resource/PLLocation' PL: ailSegment.3, NTE: nteSegment -%} + {% endfor -%} + + {% if ailSegment.3.1 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.1 -%} + {% elseif ailSegment.3.2 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.2 -%} + {% elseif ailSegment.3.3 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.3 -%} + {% elseif ailSegment.3.4 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.4 -%} + {% elseif ailSegment.3.7 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.7 -%} + {% elseif ailSegment.3.8 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.8 -%} + {% endif %} + {% assign fullLocation_ID_AIL_3 = Location_ID_AIL_3 | prepend: 'Location/' -%} + {% if aisSegmentLists.AIS -%} + {% include 'Reference/ServiceRequest/LocationReference' ID: serviceRequestId, REF: fullLocation_ID_AIL_3 -%} + {% endif %} + {% include 'Resource/Appointment' AIL: ailSegment, ID: appointmentID -%} + {% endfor -%} + + {% for aipSegment in aipSegmentLists.AIP -%} + {% if aipSegment.3 -%} + {% if aipSegment.3.9.1 != "" and aipSegment.3.9.1 != null and aipSegment.3.9.2 != "" and aipSegment.3.2 != null and aipSegment.3.9.3 != "" and aipSegment.3.9.3 != null -%} + {% evaluate organization_ID_AIP_3_9 using 'ID/Organization' HDORG: aipSegment.3.9 -%} + {% include 'Resource/Organization', AIP: aipSegment.3.9, ID: organization_ID_AIP_3_9 -%} + {% endif -%} + {% evaluate practitioner_ID_AIP_3 using 'ID/Practitioner' XCN: aipSegment.3 -%} + {% include 'Resource/Practitioner' AIP: aipSegment.3, ID: practitioner_ID_AIP_3 -%} + {% assign fullPractitioner_ID_AIP_3 = practitioner_ID_AIP_3 | prepend: 'Practitioner/' -%} + {% if aisSegmentLists.AIS -%} + {% include 'Reference/ServiceRequest/Performer' ID: serviceRequestId, REF: fullPractitioner_ID_AIP_3 -%} + {% endif -%} + {% endif -%} + {% include 'Resource/Appointment' AIP: aipSegment, ID: appointmentID -%} + {% endfor -%} + {% endfor -%} + ] +} \ No newline at end of file diff --git a/data/Templates/Hl7v2/SIU_S14.liquid b/data/Templates/Hl7v2/SIU_S14.liquid new file mode 100644 index 000000000..8a97cc666 --- /dev/null +++ b/data/Templates/Hl7v2/SIU_S14.liquid @@ -0,0 +1,476 @@ +{% assign firstSegments = hl7v2Data | get_first_segments: 'MSH|SCH' -%} +{% assign tq1SegmentLists = hl7v2Data | get_segment_lists: 'TQ1' -%} +{% assign pidSegmentLists = hl7v2Data | get_segment_lists: 'PID' -%} +{% assign rgsSegmentLists = hl7v2Data | get_segment_lists: 'RGS' -%} +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} + +{ + "resourceType": "Bundle", + "type": "batch", + {% if firstSegments.MSH.7 -%} + "timestamp":"{{ firstSegments.MSH.7.Value | format_as_date_time }}", + {% endif -%} + "identifier": + { + "value":"{{ firstSegments.MSH.10.Value }}", + }, + "id":"{{ bundleID }}", + "entry": [ + + {% evaluate patientId using 'ID/Patient' PID: pidSegmentLists.PID[0], type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% evaluate messageHeaderId using 'ID/MessageHeader' MSH: firstSegments.MSH -%} + + {% if firstSegments.MSH -%} + + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, ID: messageHeaderId -%} + {% evaluate provenanceId using 'ID/Provenance' MSH: firstSegments.MSH, baseId: patientId -%} + {% include 'Resource/Provenance' Root_Template: 'SIU_S14', MSH: firstSegments.MSH, REF_BUNDLE: bundleID, ID: provenanceId -%} + + {%- comment -%} + {% assign transformation_val = 'provenance_transformation' %} + {% evaluate provenanceOrganizationId using 'ID/Organization', prov_id: firstSegments.MSH -%} + {% evaluate provenanceTransformationId using 'ID/Provenance_transformation' prov_id: transformation_val -%} + {% include 'Resource/Organization' org_name: 'Microsoft Corporation', ID: provenanceOrganizationId -%} + {% include 'Resource/Provenance_transformation' Root_Template: 'ADT_A01', Provenance_Organization_ID: provenanceOrganizationId, REF_MSH: messageHeaderId, provenanceOrganizationId, ID: provenanceTransformationId -%} + {%- endcomment -%} + + {% if firstSegments.MSH.4 -%} + {% if firstSegments.MSH.4.1 != "" and firstSegments.MSH.4.1 != null or firstSegments.MSH.4.2 != "" and firstSegments.MSH.4.2 != null or firstSegments.MSH.4.3 != "" and firstSegments.MSH.4.3 != null -%} + {% evaluate organization_ID_MSH_4 using 'ID/Organization' HD: firstSegments.MSH.4 -%} + {% include 'Resource/Organization' MSHHD1: firstSegments.MSH.4, MSH: firstSegments.MSH, ID: organization_ID_MSH_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.6 %} + {% if firstSegments.MSH.6.1 != "" and firstSegments.MSH.6.1 != null or firstSegments.MSH.6.2 != "" and firstSegments.MSH.6.2 != null or firstSegments.MSH.6.3 != "" and firstSegments.MSH.6.3 != null -%} + {% evaluate organization_Id_MSH_6 using 'ID/Organization' HD: firstSegments.MSH.6 -%} + {% include 'Resource/Organization' MSHHD2: firstSegments.MSH.6, MSH: firstSegments.MSH, ID: organization_Id_MSH_6 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.22 %} + {% if firstSegments.MSH.22.1 != "" and firstSegments.MSH.22.1 != null -%} + {% evaluate organization_Id_MSH_22 using 'ID/Organization' XON: firstSegments.MSH.22 -%} + {% include 'Resource/Organization' MSHXON1: firstSegments.MSH.22, ID: organization_Id_MSH_22 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.23 %} + {% if firstSegments.MSH.23.1 != "" and firstSegments.MSH.23.1 != null -%} + {% evaluate organization_Id_MSH_23 using 'ID/Organization' XON: firstSegments.MSH.23 -%} + {% include 'Resource/Organization' MSHXON2: firstSegments.MSH.23, ID: organization_Id_MSH_23 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.3 and firstSegments.MSH.24 %} + {% evaluate device_Id_MSH_3 using 'ID/Device' HD: firstSegments.MSH.3 -%} + {% include 'Resource/Device' MSH: firstSegments.MSH, ID: device_Id_MSH_3 -%} + {% endif -%} + + {% endif -%} + + {% if firstSegments.SCH -%} + {% assign nteSegmentSchLists = hl7v2Data | get_segment_lists: 'NTE' -%} + {% evaluate appointmentID using 'ID/Appointment' SCH: firstSegments.SCH, baseId: patientId-%} + {% include 'Resource/Appointment' SCH: firstSegments.SCH, ID: appointmentID, pidseg: pidSegmentLists, TQ1:tq1SegmentLists.TQ1[0], NTE: nteSegmentSchLists.NTE[0] -%} + {% if firstSegments.SCH.12 -%} + {% if firstSegments.SCH.12.9.1 != "" and firstSegments.SCH.12.9.1 != null and firstSegments.SCH.12.9.2 != "" and firstSegments.SCH.12.9.2 != null and firstSegments.SCH.12.9.3 != "" and firstSegments.SCH.12.9.3 != null -%} + {% evaluate Organization_ID_SCH_12 using 'ID/Organization' HDORG: firstSegments.SCH.12.9 -%} + {% include 'Resource/Organization' OBX: firstSegments.SCH.12.9, ID: Organization_ID_SCH_12 -%} + {% endif -%} + {% evaluate practitionerId_SCH_12 using 'ID/Practitioner' XCN: firstSegments.SCH.12 -%} + {% include 'Resource/Practitioner' SCH_12: firstSegments.SCH, ID: practitionerId_SCH_12 -%} + + {% evaluate practitionerRoleId_SCH_12 using 'ID/PractitionerRole' XCN: firstSegments.SCH.12 -%} + {% include 'Resource/PractitionerRole' SCH_12: firstSegments.SCH, ID: practitionerRoleId_SCH_12, REF_SCH_12: practitionerId_SCH_12 -%} + + {% include 'Resource/PLLocation' PL: firstSegments.SCH.15 -%} + + {% endif -%} + {% if firstSegments.SCH.16 -%} + {% if firstSegments.SCH.16.9.1 != "" and firstSegments.SCH.16.9.1 != null and firstSegments.SCH.16.9.2 != "" and firstSegments.SCH.16.9.2 != null and firstSegments.SCH.16.9.3 != "" and firstSegments.SCH.16.9.3 != null -%} + {% evaluate Organization_ID_SCH_16 using 'ID/Organization' HDORG: firstSegments.SCH.16.9 -%} + {% include 'Resource/Organization' OBX: firstSegments.SCH.16.9, ID: Organization_ID_SCH_16 -%} + {% endif -%} + {% evaluate practitionerId_SCH_16 using 'ID/Practitioner' XCN: firstSegments.SCH.16 -%} + {% include 'Resource/Practitioner' SCH_16: firstSegments.SCH, ID: practitionerId_SCH_16 -%} + + {% evaluate practitionerRoleId_SCH_16 using 'ID/PractitionerRole' XCN: firstSegments.SCH.16 -%} + {% include 'Resource/PractitionerRole' SCH_16: firstSegments.SCH, ID: practitionerRoleId_SCH_16, REF_SCH_16: practitionerId_SCH_16 -%} + + {% include 'Resource/PLLocation' PL: firstSegments.SCH.19 -%} + + {% endif -%} + {% if firstSegments.SCH.20 -%} + {% if firstSegments.SCH.20.9.1 != "" and firstSegments.SCH.20.9.1 != null and firstSegments.SCH.20.9.2 != "" and firstSegments.SCH.20.9.2 != null and firstSegments.SCH.20.9.3 != "" and firstSegments.SCH.20.9.3 != null -%} + {% evaluate Organization_ID_SCH_20 using 'ID/Organization' HDORG: firstSegments.SCH.20.9 -%} + {% include 'Resource/Organization' OBX: firstSegments.SCH.20.9, ID: Organization_ID_SCH_20 -%} + {% endif -%} + {% evaluate practitionerId_SCH_20 using 'ID/Practitioner' XCN: firstSegments.SCH.20 -%} + {% include 'Resource/Practitioner' SCH_20: firstSegments.SCH, ID: practitionerId_SCH_20 -%} + + {% evaluate practitionerRoleId_SCH_20 using 'ID/PractitionerRole' XCN: firstSegments.SCH.20 -%} + {% include 'Resource/PractitionerRole' SCH_20: firstSegments.SCH, ID: practitionerRoleId_SCH_20, REF_SCH_20: practitionerId_SCH_20 -%} + + {% include 'Resource/PLLocation' PL: firstSegments.SCH.22 -%} + + {% endif -%} + {% endif -%} + + {% for pidSegment in pidSegmentLists.PID -%} + {% evaluate patientId using 'ID/Patient' PID: pidSegment, type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + + {% assign pd1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PD1' -%} + {% assign pd1Segment = pd1SegmentLists.PD1[0] %} + {% assign pv1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PV1' -%} + {% assign pv1Segment = pv1SegmentLists.PV1[0] %} + {% assign pv2SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PV2' -%} + {% assign pv2Segment = pv2SegmentLists.PV2[0] %} + {% assign obxSegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'OBX' -%} + {% assign dg1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'DG1' -%} + + + {% include 'Resource/Patient' PID: pidSegment, PD1: pd1Segment, ID: patientId -%} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, PID: pidSegment, PD1: pd1Segment, PV1: pv1Segment -%} + + {% if pidSegment.18 -%} + {% evaluate accountId using 'ID/Account' CX: pidSegment.3 -%} + {% include 'Resource/Account' PID: pidSegment, ID: accountId -%} + {% include 'Reference/Account/Subject' ID: accountId, REF: fullPatientId -%} + {% if pidSegment.18.4.1 != "" and pidSegment.18.4.1 != null and pidSegment.18.4.2 != "" and pidSegment.18.4.2 != null and pidSegment.18.4.3 != "" and pidSegment.18.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_18 using 'ID/Organization' HDORG: pidSegment.18.4 -%} + {% include 'Resource/Organization', PID: pidSegment.18, ID: Organization_ID_pid_CX_18 -%} + {% endif -%} + {% endif -%} + + {% if pidSegment.2 -%} + {% if pidSegment.2.4.1 != "" and pidSegment.2.4.1 != null and pidSegment.2.4.2 != "" and pidSegment.2.4.2 != null and pidSegment.2.4.3 != "" and pidSegment.2.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_2 using 'ID/Organization' HDORG: pidSegment.2.4 -%} + {% include 'Resource/Organization', PID: pidSegment.2, ID: Organization_ID_pid_CX_2 -%} + {% endif -%} + {% endif -%} + {% for pid3 in pidSegment.3.Repeats -%} + {% if pid3.4.1 != "" and pid3.4.1 != null and pid3.4.2 != "" and pid3.4.2 != null and pid3.4.3 != "" and pid3.4.3 != null -%} + {% evaluate Organization_ID_pid_CX using 'ID/Organization' HDORG: pid3.4 -%} + {% include 'Resource/Organization', PID: pid3, ID: Organization_ID_pid_CX -%} + {% endif -%} + {% endfor -%} + {% if pidSegment.4 -%} + {% if pidSegment.4.4.1 != "" and pidSegment.4.4.1 != null and pidSegment.4.4.2 != "" and pidSegment.4.4.2 != null and pidSegment.4.4.3 != "" and pidSegment.4.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_4 using 'ID/Organization' HDORG: pidSegment.4.4 -%} + {% include 'Resource/Organization', PID: pidSegment.4, ID: Organization_ID_pid_CX_4 -%} + {% endif -%} + {% endif -%} + + {% unless nk1SegmentLists.NK1 -%} + {% if pidSegment.21 -%} + {% if pidSegment.21.4.1 != "" and pidSegment.21.4.1 != null and pidSegment.21.4.2 != "" and pidSegment.21.4.2 != null and pidSegment.21.4.3 != "" and pidSegment.21.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_21 using 'ID/Organization' HDORG: pidSegment.21.4 -%} + {% include 'Resource/Organization', PID: pidSegment.21, ID: Organization_ID_pid_CX_21 -%} + {% endif -%} + {% evaluate pidrelatedPersonId using 'ID/RelatedPerson' PID: pidSegment, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: pidrelatedPersonId, PID: pidSegment -%} + {% endif -%} + {% endunless -%} + + {% if pd1Segment.3 -%} + {% evaluate Organization_ID_PD1_3 using 'ID/Organization' XON: pd1Segment.3 -%} + {% include 'Resource/Organization' PD1: pd1Segment, ID: Organization_ID_PD1_3 -%} + {% endif -%} + + {% if pd1Segment.4 -%} + {% if pd1Segment.4.9.1 != "" and pd1Segment.4.9.1 != null and pd1Segment.4.9.2 != "" and pd1Segment.4.9.2 != null and pd1Segment.4.9.3 != "" and pd1Segment.4.9.3 != null -%} + {% evaluate Organization_ID_PD1_4_9 using 'ID/Organization' HDORG: pd1Segment.4.9 -%} + {% include 'Resource/Organization', PD1_4: pd1Segment.4.9, ID: Organization_ID_PD1_4_9 -%} + {% endif -%} + {% evaluate Practitioner_ID_PD1_4 using 'ID/Practitioner' XCN: pd1Segment.4 -%} + {% include 'Resource/Practitioner' PD1: pd1Segment.4, ID: Practitioner_ID_PD1_4 -%} + {% endif -%} + + + {% if pv1Segment -%} + {% if pv1Segment.5 -%} + {% if pv1Segment.5.4.1 != "" and pv1Segment.5.4.1 != null and pv1Segment.5.4.2 != "" and pv1Segment.5.4.2 != null and pv1Segment.5.4.3 != "" and pv1Segment.5.4.3 != null -%} + {% evaluate Organization_ID_PV1_5_4 using 'ID/Organization' HDORG: pv1Segment.5.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.5.4, ID: Organization_ID_PV1_5_4 -%} + {% endif -%} + {% endif -%} + + {% if pv1Segment.19 -%} + {% if pv1Segment.19.4.1 != "" and pv1Segment.19.4.1 != null and pv1Segment.19.4.2 != "" and pv1Segment.19.4.2 != null and pv1Segment.19.4.3 != "" and pv1Segment.19.4.3 != null -%} + {% evaluate Organization_ID_PV1_19_4 using 'ID/Organization' HDORG: pv1Segment.19.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.19.4, ID: Organization_ID_PV1_19_4 -%} + {% endif -%} + {% endif -%} + + {% if pv1Segment.7 -%} + {% if pv1Segment.7.9.1 != "" and pv1Segment.7.9.1 != null and pv1Segment.7.9.2 != "" and pv1Segment.7.9.2 != null and pv1Segment.7.9.3 != "" and pv1Segment.7.9.3 != null -%} + {% evaluate Organization_ID_PV1_7_9 using 'ID/Organization' HDORG: pv1Segment.7.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.7.9, ID: Organization_ID_PV1_7_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_7 using 'ID/Practitioner' XCN: pv1Segment.7 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.7, ID: practitionerId_PV1_7 -%} + {% endif -%} + + {% if pv1Segment.8 -%} + {% if pv1Segment.8.9.1 != "" and pv1Segment.8.9.1 != null and pv1Segment.8.9.2 != "" and pv1Segment.8.9.2 != null and pv1Segment.8.9.3 != "" and pv1Segment.8.9.3 != null -%} + {% evaluate Organization_ID_PV1_8_9 using 'ID/Organization' HDORG: pv1Segment.8.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.8.9, ID: Organization_ID_PV1_8_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_8 using 'ID/Practitioner' XCN: pv1Segment.8 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.8, ID: practitionerId_PV1_8 -%} + {% endif -%} + + {% if pv1Segment.9 -%} + {% if pv1Segment.9.9.1 != "" and pv1Segment.9.9.1 != null and pv1Segment.9.9.2 != "" and pv1Segment.9.9.2 != null and pv1Segment.9.9.3 != "" and pv1Segment.9.9.3 != null -%} + {% evaluate Organization_ID_PV1_9_9 using 'ID/Organization' HDORG: pv1Segment.9.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.9.9, ID: Organization_ID_PV1_9_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_9 using 'ID/Practitioner' XCN: pv1Segment.9 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.9, ID: practitionerId_PV1_9 -%} + {% endif -%} + + {% if pv1Segment.17 -%} + {% if pv1Segment.17.9.1 != "" and pv1Segment.17.9.1 != null and pv1Segment.17.9.2 != "" and pv1Segment.17.9.2 != null and pv1Segment.17.9.3 != "" and pv1Segment.17.9.3 != null -%} + {% evaluate Organization_ID_PV1_17_9 using 'ID/Organization' HDORG: pv1Segment.17.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.17.9, ID: Organization_ID_PV1_17_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_17 using 'ID/Practitioner' XCN: pv1Segment.17 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.17, ID: practitionerId_PV1_17 -%} + {% endif -%} + + {% if pv1Segment.50 -%} + {% for p in pv1Segment.50.Repeats -%} + {% if p.4.1 != "" and p.4.1 != null and p.4.2 != "" and p.4.2 != null and p.4.3 != "" and p.4.3 != null -%} + {% evaluate Organization_ID_PV1_50_4 using 'ID/Organization' HDORG: p.4 -%} + {% include 'Resource/Organization', PV1: p.4, ID: Organization_ID_PV1_50_4 -%} + {% endif -%} + {% endfor -%} + {% endif -%} + + {% if pv1Segment.52 -%} + {% if pv1Segment.52.9.1 != "" and pv1Segment.52.9.1 != null and pv1Segment.52.9.2 != "" and pv1Segment.52.9.2 != null and pv1Segment.52.9.3 != "" and pv1Segment.52.9.3 != null -%} + {% evaluate Organization_ID_PV1_52_9 using 'ID/Organization' HDORG: pv1Segment.52.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.52.9, ID: Organization_ID_PV1_52_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_52 using 'ID/Practitioner' XCN: pv1Segment.52 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.52, ID: practitionerId_PV1_52 -%} + {% endif -%} + + {% if pv2Segment.13 -%} + {% if pv2Segment.13.9.1 != "" and pv2Segment.13.9.1 != null and pv2Segment.13.9.2 != "" and pv2Segment.13.9.2 != null and pv2Segment.13.9.3 != "" and pv2Segment.13.9.3 != null -%} + {% evaluate Organization_ID_PV2_13_9 using 'ID/Organization' HDORG: pv2Segment.13.9 -%} + {% include 'Resource/Organization', PV2: pv2Segment.13.9, ID: Organization_ID_PV2_13_9 -%} + {% endif -%} + {% evaluate practitionerId_PV2_13 using 'ID/Practitioner' XCN: pv2Segment.13 -%} + {% include 'Resource/Practitioner' PV1: pv2Segment.13, ID: practitionerId_PV2_13 -%} + {% endif -%} + + {% if pv1Segment.3 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.3-%} + {% endif -%} + + {% if pv1Segment.6 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.6 -%} + {% endif -%} + + {% if pv1Segment.37 -%} + {% evaluate location_ID_PV1_37 using 'ID/Location' DLD: pv1Segment.37 -%} + {% include 'Resource/Location' PV1: pv1Segment.37, ID: location_ID_PV1_37-%} + {% endif -%} + + {% if pv1Segment.42 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.42-%} + {% endif -%} + + {% if pv1Segment.43 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.43-%} + {% endif -%} + + {% if pv2Segment.1 -%} + {% include 'Resource/PLLocation' PL: pv2Segment.1-%} + {% endif -%} + + {% if pv1Segment.54 -%} + {% if pv1Segment.54.4.1 != "" and pv1Segment.54.4.1 != null and pv1Segment.54.4.2 != "" and pv1Segment.54.4.2 != null and pv1Segment.54.4.3 != "" and pv1Segment.54.4.3 != null -%} + {% evaluate Organization_ID_PV1_54_4 using 'ID/Organization' HDORG: pv1Segment.54.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.54.4, ID: Organization_ID_PV1_54_4 -%} + {% endif -%} + {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: pv1Segment.54 -%} + {% include 'Resource/EpisodeOfCare' PV1: pv1Segment, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId -%} + {% endif -%} + + {% evaluate encounterId using 'ID/Encounter' PV1: pv1Segment, baseId: patientId -%} + {% assign fullEncounterId = encounterId | prepend: 'Encounter/' -%} + {% include 'Resource/Encounter' Root_Template: 'SIU_S14', PV1: pv1Segment, PV2: pv2Segment, ID: encounterId -%} + {% include 'Reference/Encounter/Subject' ID: encounterId, REF: fullPatientId -%} + {% include 'Extensions/Encounter/EncounterExtension' ID: encounterId, PV1: pv1Segment, PV2: pv2Segment -%} + {% endif -%} + + + {% for obxSegment in obxSegmentLists.OBX -%} + + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16 -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16 -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + + {% if obxSegment.18 -%} + {% evaluate deviceId_OBX_18 using 'ID/Device' EI: obxSegment.18.Repeats[0] -%} + {% include 'Resource/Device' EI_OBX18: obxSegment.18, ID: deviceId_OBX_18 -%} + {% endif -%} + + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23 -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + + {% evaluate observationId using 'ID/Observation' OBX: obxSegment, baseId: patientId -%} + + {% include 'Resource/Observation' OBX: obxSegment, Observation_Subject_ID: fullPatientId, ID: observationId -%} + {% include 'Extensions/Observation/ObservationExtension' OBX: obxSegment, ID: observationId %} + + {% endfor -%} + + {% for dg1Segment in dg1SegmentLists.DG1 -%} + + {% if dg1Segment.16.Repeats[0] %} + {% if dg1Segment.16.Repeats[0].9.1 != "" and dg1Segment.16.Repeats[0].9.1 != null and dg1Segment.16.Repeats[0].9.2 != "" and dg1Segment.16.Repeats[0].9.2 != null and dg1Segment.16.Repeats[0].9.3 != "" and dg1Segment.16.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_DG1_16 using 'ID/Organization' HDORG: dg1Segment.16.Repeats[0].9 -%} + {% include 'Resource/Organization', DG1: dg1Segment.16.Repeats[0].9, ID: Organization_ID_DG1_16 -%} + {% endif -%} + {% evaluate practitionerId_DG1_16 using 'ID/Practitioner' XCN: dg1Segment.16.Repeats[0] -%} + {% include 'Resource/Practitioner' DG1: dg1Segment, ID: practitionerId_DG1_16 -%} + {% endif -%} + + {% evaluate conditionId using 'ID/Condition' DG1: dg1Segment, baseId: patientId -%} + {% include 'Resource/Condition' DG1: dg1Segment, Condition_Subject_ID: fullPatientId, baseId: patientId, ID: conditionId -%} + + {% if encounterId -%} + {% include 'Resource/Encounter' DG1: dg1Segment, conditionId: conditionId, ID: encounterId -%} + {% endif %} + + {% if EpisodeOfCare_ID %} + {% include 'Resource/EpisodeOfCare' DG1: dg1Segment, conditionId: conditionId, ID: EpisodeOfCare_ID -%} + {% endif %} + + {% if dg1Segment.22 %} + {% evaluate conditionId_DG1_22 using 'ID/Condition' DG1: dg1Segment.22, baseId: patientId -%} + {% include 'Resource/Condition' DG1_22: dg1Segment.22, Condition_Subject_ID_DG1_22: fullPatientId, ID: conditionId_DG1_22 -%} + {% endif %} + {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} + {% endfor -%} + + {% endfor -%} + + {% for rgsSegment in rgsSegmentLists.RGS -%} + {% evaluate patientId using 'ID/Patient' PID: pidSegmentLists.PID[0], type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% assign aisSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIS' -%} + {% assign ailSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIL' -%} + {% assign aigSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIG' -%} + {% assign aipSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIP' -%} + + {% for aisSegment in aisSegmentLists.AIS -%} + {% assign nteSegmentLists = hl7v2Data | get_related_segment_list: aisSegment, 'NTE' -%} + {% evaluate serviceRequestId using 'ID/ServiceRequest' AIS: aisSegment, baseId: patientId -%} + {% include 'Resource/ServiceRequest' AIS: aisSegment, ID: serviceRequestId, ServiceRequest_Subject_ID: fullPatientId, ServiceRequest_Encounter_ID: fullEncounterId -%} + {% assign fullServiceRequestId = serviceRequestId | prepend: 'ServiceRequest/' -%} + {% include 'Reference/Appointment/BasedOn' ID: appointmentID, REF: fullServiceRequestId -%} + {% for nteSegment in nteSegmentLists.NTE -%} + {% if nteSegment.5 -%} + {% if nteSegment.5.9.1 != "" and nteSegment.5.9.1 != null and nteSegment.5.9.2 != "" and nteSegment.5.9.2 != null and nteSegment.5.9.3 != "" and nteSegment.5.9.3 != null -%} + {% evaluate Organization_ID_EVN_5_9 using 'ID/Organization' HDORG: nteSegment.5.9 -%} + {% include 'Resource/Organization', PV2: nteSegment.5.9, ID: Organization_ID_EVN_5_9 -%} + {% endif -%} + {% evaluate Practitioner_ID_NTE_5 using 'ID/Practitioner' XCN: nteSegment.5 -%} + {% include 'Resource/Practitioner' NTE: nteSegment.5, ID: Practitioner_ID_NTE_5 -%} + {% endif -%} + {% include 'Resource/ServiceRequest' NTE: nteSegment, ID: serviceRequestId -%} + {% endfor -%} + {% endfor -%} + + {% for aigSegment in aigSegmentLists.AIG -%} + {% assign nteSegmentLists = hl7v2Data | get_related_segment_list: aigSegment, 'NTE' -%} + {% evaluate device_Id_AIG_3 using 'ID/Device' AIG: aigSegment -%} + {% include 'Resource/Device' AIG: aigSegment, ID: device_Id_AIG_3 -%} + {% include 'Resource/Appointment' AIG: aigSegment, ID: appointmentID -%} + {% assign fullDevice_Id_AIG_3 = device_Id_AIG_3 | prepend: 'Device/' -%} + {% if aisSegmentLists.AIS -%} + {% include 'Reference/ServiceRequest/Performer' ID: serviceRequestId, REF: fullDevice_Id_AIG_3 -%} + {% endif -%} + {% for nteSegment in nteSegmentLists.NTE -%} + {% include 'Resource/Device' NTE: nteSegment, ID: device_Id_AIG_3 -%} + {% endfor -%} + {% endfor -%} + + {% for ailSegment in ailSegmentLists.AIL -%} + {% assign nteSegmentLists = hl7v2Data | get_related_segment_list: ailSegment, 'NTE' -%} + {% include 'Resource/PLLocation' PL: ailSegment.3, AIL_4: ailSegment.4 -%} + {% for nteSegment in nteSegmentLists.NTE -%} + {% include 'Resource/PLLocation' PL: ailSegment.3, NTE: nteSegment -%} + {% endfor -%} + + {% if ailSegment.3.1 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.1 -%} + {% elseif ailSegment.3.2 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.2 -%} + {% elseif ailSegment.3.3 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.3 -%} + {% elseif ailSegment.3.4 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.4 -%} + {% elseif ailSegment.3.7 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.7 -%} + {% elseif ailSegment.3.8 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.8 -%} + {% endif %} + {% assign fullLocation_ID_AIL_3 = Location_ID_AIL_3 | prepend: 'Location/' -%} + {% if aisSegmentLists.AIS -%} + {% include 'Reference/ServiceRequest/LocationReference' ID: serviceRequestId, REF: fullLocation_ID_AIL_3 -%} + {% endif %} + {% include 'Resource/Appointment' AIL: ailSegment, ID: appointmentID -%} + {% endfor -%} + + {% for aipSegment in aipSegmentLists.AIP -%} + {% if aipSegment.3 -%} + {% if aipSegment.3.9.1 != "" and aipSegment.3.9.1 != null and aipSegment.3.9.2 != "" and aipSegment.3.2 != null and aipSegment.3.9.3 != "" and aipSegment.3.9.3 != null -%} + {% evaluate organization_ID_AIP_3_9 using 'ID/Organization' HDORG: aipSegment.3.9 -%} + {% include 'Resource/Organization', AIP: aipSegment.3.9, ID: organization_ID_AIP_3_9 -%} + {% endif -%} + {% evaluate practitioner_ID_AIP_3 using 'ID/Practitioner' XCN: aipSegment.3 -%} + {% include 'Resource/Practitioner' AIP: aipSegment.3, ID: practitioner_ID_AIP_3 -%} + {% assign fullPractitioner_ID_AIP_3 = practitioner_ID_AIP_3 | prepend: 'Practitioner/' -%} + {% if aisSegmentLists.AIS -%} + {% include 'Reference/ServiceRequest/Performer' ID: serviceRequestId, REF: fullPractitioner_ID_AIP_3 -%} + {% endif -%} + {% endif -%} + {% include 'Resource/Appointment' AIP: aipSegment, ID: appointmentID -%} + {% endfor -%} + {% endfor -%} + ] +} \ No newline at end of file diff --git a/data/Templates/Hl7v2/SIU_S15.liquid b/data/Templates/Hl7v2/SIU_S15.liquid new file mode 100644 index 000000000..68c5c2556 --- /dev/null +++ b/data/Templates/Hl7v2/SIU_S15.liquid @@ -0,0 +1,476 @@ +{% assign firstSegments = hl7v2Data | get_first_segments: 'MSH|SCH' -%} +{% assign tq1SegmentLists = hl7v2Data | get_segment_lists: 'TQ1' -%} +{% assign pidSegmentLists = hl7v2Data | get_segment_lists: 'PID' -%} +{% assign rgsSegmentLists = hl7v2Data | get_segment_lists: 'RGS' -%} +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} + +{ + "resourceType": "Bundle", + "type": "batch", + {% if firstSegments.MSH.7 -%} + "timestamp":"{{ firstSegments.MSH.7.Value | format_as_date_time }}", + {% endif -%} + "identifier": + { + "value":"{{ firstSegments.MSH.10.Value }}", + }, + "id":"{{ bundleID }}", + "entry": [ + + {% evaluate patientId using 'ID/Patient' PID: pidSegmentLists.PID[0], type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% evaluate messageHeaderId using 'ID/MessageHeader' MSH: firstSegments.MSH -%} + + {% if firstSegments.MSH -%} + + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, ID: messageHeaderId -%} + {% evaluate provenanceId using 'ID/Provenance' MSH: firstSegments.MSH, baseId: patientId -%} + {% include 'Resource/Provenance' Root_Template: 'SIU_S15', MSH: firstSegments.MSH, REF_BUNDLE: bundleID, ID: provenanceId -%} + + {%- comment -%} + {% assign transformation_val = 'provenance_transformation' %} + {% evaluate provenanceOrganizationId using 'ID/Organization', prov_id: firstSegments.MSH -%} + {% evaluate provenanceTransformationId using 'ID/Provenance_transformation' prov_id: transformation_val -%} + {% include 'Resource/Organization' org_name: 'Microsoft Corporation', ID: provenanceOrganizationId -%} + {% include 'Resource/Provenance_transformation' Root_Template: 'ADT_A01', Provenance_Organization_ID: provenanceOrganizationId, REF_MSH: messageHeaderId, provenanceOrganizationId, ID: provenanceTransformationId -%} + {%- endcomment -%} + + {% if firstSegments.MSH.4 -%} + {% if firstSegments.MSH.4.1 != "" and firstSegments.MSH.4.1 != null or firstSegments.MSH.4.2 != "" and firstSegments.MSH.4.2 != null or firstSegments.MSH.4.3 != "" and firstSegments.MSH.4.3 != null -%} + {% evaluate organization_ID_MSH_4 using 'ID/Organization' HD: firstSegments.MSH.4 -%} + {% include 'Resource/Organization' MSHHD1: firstSegments.MSH.4, MSH: firstSegments.MSH, ID: organization_ID_MSH_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.6 %} + {% if firstSegments.MSH.6.1 != "" and firstSegments.MSH.6.1 != null or firstSegments.MSH.6.2 != "" and firstSegments.MSH.6.2 != null or firstSegments.MSH.6.3 != "" and firstSegments.MSH.6.3 != null -%} + {% evaluate organization_Id_MSH_6 using 'ID/Organization' HD: firstSegments.MSH.6 -%} + {% include 'Resource/Organization' MSHHD2: firstSegments.MSH.6, MSH: firstSegments.MSH, ID: organization_Id_MSH_6 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.22 %} + {% if firstSegments.MSH.22.1 != "" and firstSegments.MSH.22.1 != null -%} + {% evaluate organization_Id_MSH_22 using 'ID/Organization' XON: firstSegments.MSH.22 -%} + {% include 'Resource/Organization' MSHXON1: firstSegments.MSH.22, ID: organization_Id_MSH_22 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.23 %} + {% if firstSegments.MSH.23.1 != "" and firstSegments.MSH.23.1 != null -%} + {% evaluate organization_Id_MSH_23 using 'ID/Organization' XON: firstSegments.MSH.23 -%} + {% include 'Resource/Organization' MSHXON2: firstSegments.MSH.23, ID: organization_Id_MSH_23 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.3 and firstSegments.MSH.24 %} + {% evaluate device_Id_MSH_3 using 'ID/Device' HD: firstSegments.MSH.3 -%} + {% include 'Resource/Device' MSH: firstSegments.MSH, ID: device_Id_MSH_3 -%} + {% endif -%} + + {% endif -%} + + {% if firstSegments.SCH -%} + {% assign nteSegmentSchLists = hl7v2Data | get_segment_lists: 'NTE' -%} + {% evaluate appointmentID using 'ID/Appointment' SCH: firstSegments.SCH, baseId: patientId-%} + {% include 'Resource/Appointment' SCH: firstSegments.SCH, ID: appointmentID, pidseg: pidSegmentLists, TQ1:tq1SegmentLists.TQ1[0], NTE: nteSegmentSchLists.NTE[0], type_sch: 15 -%} + {% if firstSegments.SCH.12 -%} + {% if firstSegments.SCH.12.9.1 != "" and firstSegments.SCH.12.9.1 != null and firstSegments.SCH.12.9.2 != "" and firstSegments.SCH.12.9.2 != null and firstSegments.SCH.12.9.3 != "" and firstSegments.SCH.12.9.3 != null -%} + {% evaluate Organization_ID_SCH_12 using 'ID/Organization' HDORG: firstSegments.SCH.12.9 -%} + {% include 'Resource/Organization' OBX: firstSegments.SCH.12.9, ID: Organization_ID_SCH_12 -%} + {% endif -%} + {% evaluate practitionerId_SCH_12 using 'ID/Practitioner' XCN: firstSegments.SCH.12 -%} + {% include 'Resource/Practitioner' SCH_12: firstSegments.SCH, ID: practitionerId_SCH_12 -%} + + {% evaluate practitionerRoleId_SCH_12 using 'ID/PractitionerRole' XCN: firstSegments.SCH.12 -%} + {% include 'Resource/PractitionerRole' SCH_12: firstSegments.SCH, ID: practitionerRoleId_SCH_12, REF_SCH_12: practitionerId_SCH_12 -%} + + {% include 'Resource/PLLocation' PL: firstSegments.SCH.15 -%} + + {% endif -%} + {% if firstSegments.SCH.16 -%} + {% if firstSegments.SCH.16.9.1 != "" and firstSegments.SCH.16.9.1 != null and firstSegments.SCH.16.9.2 != "" and firstSegments.SCH.16.9.2 != null and firstSegments.SCH.16.9.3 != "" and firstSegments.SCH.16.9.3 != null -%} + {% evaluate Organization_ID_SCH_16 using 'ID/Organization' HDORG: firstSegments.SCH.16.9 -%} + {% include 'Resource/Organization' OBX: firstSegments.SCH.16.9, ID: Organization_ID_SCH_16 -%} + {% endif -%} + {% evaluate practitionerId_SCH_16 using 'ID/Practitioner' XCN: firstSegments.SCH.16 -%} + {% include 'Resource/Practitioner' SCH_16: firstSegments.SCH, ID: practitionerId_SCH_16 -%} + + {% evaluate practitionerRoleId_SCH_16 using 'ID/PractitionerRole' XCN: firstSegments.SCH.16 -%} + {% include 'Resource/PractitionerRole' SCH_16: firstSegments.SCH, ID: practitionerRoleId_SCH_16, REF_SCH_16: practitionerId_SCH_16 -%} + + {% include 'Resource/PLLocation' PL: firstSegments.SCH.19 -%} + + {% endif -%} + {% if firstSegments.SCH.20 -%} + {% if firstSegments.SCH.20.9.1 != "" and firstSegments.SCH.20.9.1 != null and firstSegments.SCH.20.9.2 != "" and firstSegments.SCH.20.9.2 != null and firstSegments.SCH.20.9.3 != "" and firstSegments.SCH.20.9.3 != null -%} + {% evaluate Organization_ID_SCH_20 using 'ID/Organization' HDORG: firstSegments.SCH.20.9 -%} + {% include 'Resource/Organization' OBX: firstSegments.SCH.20.9, ID: Organization_ID_SCH_20 -%} + {% endif -%} + {% evaluate practitionerId_SCH_20 using 'ID/Practitioner' XCN: firstSegments.SCH.20 -%} + {% include 'Resource/Practitioner' SCH_20: firstSegments.SCH, ID: practitionerId_SCH_20 -%} + + {% evaluate practitionerRoleId_SCH_20 using 'ID/PractitionerRole' XCN: firstSegments.SCH.20 -%} + {% include 'Resource/PractitionerRole' SCH_20: firstSegments.SCH, ID: practitionerRoleId_SCH_20, REF_SCH_20: practitionerId_SCH_20 -%} + + {% include 'Resource/PLLocation' PL: firstSegments.SCH.22 -%} + + {% endif -%} + {% endif -%} + + {% for pidSegment in pidSegmentLists.PID -%} + {% evaluate patientId using 'ID/Patient' PID: pidSegment, type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + + {% assign pd1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PD1' -%} + {% assign pd1Segment = pd1SegmentLists.PD1[0] %} + {% assign pv1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PV1' -%} + {% assign pv1Segment = pv1SegmentLists.PV1[0] %} + {% assign pv2SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PV2' -%} + {% assign pv2Segment = pv2SegmentLists.PV2[0] %} + {% assign obxSegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'OBX' -%} + {% assign dg1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'DG1' -%} + + + {% include 'Resource/Patient' PID: pidSegment, PD1: pd1Segment, ID: patientId -%} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, PID: pidSegment, PD1: pd1Segment, PV1: pv1Segment -%} + + {% if pidSegment.18 -%} + {% evaluate accountId using 'ID/Account' CX: pidSegment.3 -%} + {% include 'Resource/Account' PID: pidSegment, ID: accountId -%} + {% include 'Reference/Account/Subject' ID: accountId, REF: fullPatientId -%} + {% if pidSegment.18.4.1 != "" and pidSegment.18.4.1 != null and pidSegment.18.4.2 != "" and pidSegment.18.4.2 != null and pidSegment.18.4.3 != "" and pidSegment.18.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_18 using 'ID/Organization' HDORG: pidSegment.18.4 -%} + {% include 'Resource/Organization', PID: pidSegment.18, ID: Organization_ID_pid_CX_18 -%} + {% endif -%} + {% endif -%} + + {% if pidSegment.2 -%} + {% if pidSegment.2.4.1 != "" and pidSegment.2.4.1 != null and pidSegment.2.4.2 != "" and pidSegment.2.4.2 != null and pidSegment.2.4.3 != "" and pidSegment.2.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_2 using 'ID/Organization' HDORG: pidSegment.2.4 -%} + {% include 'Resource/Organization', PID: pidSegment.2, ID: Organization_ID_pid_CX_2 -%} + {% endif -%} + {% endif -%} + {% for pid3 in pidSegment.3.Repeats -%} + {% if pid3.4.1 != "" and pid3.4.1 != null and pid3.4.2 != "" and pid3.4.2 != null and pid3.4.3 != "" and pid3.4.3 != null -%} + {% evaluate Organization_ID_pid_CX using 'ID/Organization' HDORG: pid3.4 -%} + {% include 'Resource/Organization', PID: pid3, ID: Organization_ID_pid_CX -%} + {% endif -%} + {% endfor -%} + {% if pidSegment.4 -%} + {% if pidSegment.4.4.1 != "" and pidSegment.4.4.1 != null and pidSegment.4.4.2 != "" and pidSegment.4.4.2 != null and pidSegment.4.4.3 != "" and pidSegment.4.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_4 using 'ID/Organization' HDORG: pidSegment.4.4 -%} + {% include 'Resource/Organization', PID: pidSegment.4, ID: Organization_ID_pid_CX_4 -%} + {% endif -%} + {% endif -%} + + {% unless nk1SegmentLists.NK1 -%} + {% if pidSegment.21 -%} + {% if pidSegment.21.4.1 != "" and pidSegment.21.4.1 != null and pidSegment.21.4.2 != "" and pidSegment.21.4.2 != null and pidSegment.21.4.3 != "" and pidSegment.21.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_21 using 'ID/Organization' HDORG: pidSegment.21.4 -%} + {% include 'Resource/Organization', PID: pidSegment.21, ID: Organization_ID_pid_CX_21 -%} + {% endif -%} + {% evaluate pidrelatedPersonId using 'ID/RelatedPerson' PID: pidSegment, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: pidrelatedPersonId, PID: pidSegment -%} + {% endif -%} + {% endunless -%} + + {% if pd1Segment.3 -%} + {% evaluate Organization_ID_PD1_3 using 'ID/Organization' XON: pd1Segment.3 -%} + {% include 'Resource/Organization' PD1: pd1Segment, ID: Organization_ID_PD1_3 -%} + {% endif -%} + + {% if pd1Segment.4 -%} + {% if pd1Segment.4.9.1 != "" and pd1Segment.4.9.1 != null and pd1Segment.4.9.2 != "" and pd1Segment.4.9.2 != null and pd1Segment.4.9.3 != "" and pd1Segment.4.9.3 != null -%} + {% evaluate Organization_ID_PD1_4_9 using 'ID/Organization' HDORG: pd1Segment.4.9 -%} + {% include 'Resource/Organization', PD1_4: pd1Segment.4.9, ID: Organization_ID_PD1_4_9 -%} + {% endif -%} + {% evaluate Practitioner_ID_PD1_4 using 'ID/Practitioner' XCN: pd1Segment.4 -%} + {% include 'Resource/Practitioner' PD1: pd1Segment.4, ID: Practitioner_ID_PD1_4 -%} + {% endif -%} + + + {% if pv1Segment -%} + {% if pv1Segment.5 -%} + {% if pv1Segment.5.4.1 != "" and pv1Segment.5.4.1 != null and pv1Segment.5.4.2 != "" and pv1Segment.5.4.2 != null and pv1Segment.5.4.3 != "" and pv1Segment.5.4.3 != null -%} + {% evaluate Organization_ID_PV1_5_4 using 'ID/Organization' HDORG: pv1Segment.5.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.5.4, ID: Organization_ID_PV1_5_4 -%} + {% endif -%} + {% endif -%} + + {% if pv1Segment.19 -%} + {% if pv1Segment.19.4.1 != "" and pv1Segment.19.4.1 != null and pv1Segment.19.4.2 != "" and pv1Segment.19.4.2 != null and pv1Segment.19.4.3 != "" and pv1Segment.19.4.3 != null -%} + {% evaluate Organization_ID_PV1_19_4 using 'ID/Organization' HDORG: pv1Segment.19.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.19.4, ID: Organization_ID_PV1_19_4 -%} + {% endif -%} + {% endif -%} + + {% if pv1Segment.7 -%} + {% if pv1Segment.7.9.1 != "" and pv1Segment.7.9.1 != null and pv1Segment.7.9.2 != "" and pv1Segment.7.9.2 != null and pv1Segment.7.9.3 != "" and pv1Segment.7.9.3 != null -%} + {% evaluate Organization_ID_PV1_7_9 using 'ID/Organization' HDORG: pv1Segment.7.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.7.9, ID: Organization_ID_PV1_7_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_7 using 'ID/Practitioner' XCN: pv1Segment.7 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.7, ID: practitionerId_PV1_7 -%} + {% endif -%} + + {% if pv1Segment.8 -%} + {% if pv1Segment.8.9.1 != "" and pv1Segment.8.9.1 != null and pv1Segment.8.9.2 != "" and pv1Segment.8.9.2 != null and pv1Segment.8.9.3 != "" and pv1Segment.8.9.3 != null -%} + {% evaluate Organization_ID_PV1_8_9 using 'ID/Organization' HDORG: pv1Segment.8.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.8.9, ID: Organization_ID_PV1_8_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_8 using 'ID/Practitioner' XCN: pv1Segment.8 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.8, ID: practitionerId_PV1_8 -%} + {% endif -%} + + {% if pv1Segment.9 -%} + {% if pv1Segment.9.9.1 != "" and pv1Segment.9.9.1 != null and pv1Segment.9.9.2 != "" and pv1Segment.9.9.2 != null and pv1Segment.9.9.3 != "" and pv1Segment.9.9.3 != null -%} + {% evaluate Organization_ID_PV1_9_9 using 'ID/Organization' HDORG: pv1Segment.9.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.9.9, ID: Organization_ID_PV1_9_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_9 using 'ID/Practitioner' XCN: pv1Segment.9 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.9, ID: practitionerId_PV1_9 -%} + {% endif -%} + + {% if pv1Segment.17 -%} + {% if pv1Segment.17.9.1 != "" and pv1Segment.17.9.1 != null and pv1Segment.17.9.2 != "" and pv1Segment.17.9.2 != null and pv1Segment.17.9.3 != "" and pv1Segment.17.9.3 != null -%} + {% evaluate Organization_ID_PV1_17_9 using 'ID/Organization' HDORG: pv1Segment.17.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.17.9, ID: Organization_ID_PV1_17_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_17 using 'ID/Practitioner' XCN: pv1Segment.17 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.17, ID: practitionerId_PV1_17 -%} + {% endif -%} + + {% if pv1Segment.50 -%} + {% for p in pv1Segment.50.Repeats -%} + {% if p.4.1 != "" and p.4.1 != null and p.4.2 != "" and p.4.2 != null and p.4.3 != "" and p.4.3 != null -%} + {% evaluate Organization_ID_PV1_50_4 using 'ID/Organization' HDORG: p.4 -%} + {% include 'Resource/Organization', PV1: p.4, ID: Organization_ID_PV1_50_4 -%} + {% endif -%} + {% endfor -%} + {% endif -%} + + {% if pv1Segment.52 -%} + {% if pv1Segment.52.9.1 != "" and pv1Segment.52.9.1 != null and pv1Segment.52.9.2 != "" and pv1Segment.52.9.2 != null and pv1Segment.52.9.3 != "" and pv1Segment.52.9.3 != null -%} + {% evaluate Organization_ID_PV1_52_9 using 'ID/Organization' HDORG: pv1Segment.52.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.52.9, ID: Organization_ID_PV1_52_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_52 using 'ID/Practitioner' XCN: pv1Segment.52 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.52, ID: practitionerId_PV1_52 -%} + {% endif -%} + + {% if pv2Segment.13 -%} + {% if pv2Segment.13.9.1 != "" and pv2Segment.13.9.1 != null and pv2Segment.13.9.2 != "" and pv2Segment.13.9.2 != null and pv2Segment.13.9.3 != "" and pv2Segment.13.9.3 != null -%} + {% evaluate Organization_ID_PV2_13_9 using 'ID/Organization' HDORG: pv2Segment.13.9 -%} + {% include 'Resource/Organization', PV2: pv2Segment.13.9, ID: Organization_ID_PV2_13_9 -%} + {% endif -%} + {% evaluate practitionerId_PV2_13 using 'ID/Practitioner' XCN: pv2Segment.13 -%} + {% include 'Resource/Practitioner' PV1: pv2Segment.13, ID: practitionerId_PV2_13 -%} + {% endif -%} + + {% if pv1Segment.3 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.3-%} + {% endif -%} + + {% if pv1Segment.6 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.6 -%} + {% endif -%} + + {% if pv1Segment.37 -%} + {% evaluate location_ID_PV1_37 using 'ID/Location' DLD: pv1Segment.37 -%} + {% include 'Resource/Location' PV1: pv1Segment.37, ID: location_ID_PV1_37-%} + {% endif -%} + + {% if pv1Segment.42 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.42-%} + {% endif -%} + + {% if pv1Segment.43 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.43-%} + {% endif -%} + + {% if pv2Segment.1 -%} + {% include 'Resource/PLLocation' PL: pv2Segment.1-%} + {% endif -%} + + {% if pv1Segment.54 -%} + {% if pv1Segment.54.4.1 != "" and pv1Segment.54.4.1 != null and pv1Segment.54.4.2 != "" and pv1Segment.54.4.2 != null and pv1Segment.54.4.3 != "" and pv1Segment.54.4.3 != null -%} + {% evaluate Organization_ID_PV1_54_4 using 'ID/Organization' HDORG: pv1Segment.54.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.54.4, ID: Organization_ID_PV1_54_4 -%} + {% endif -%} + {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: pv1Segment.54 -%} + {% include 'Resource/EpisodeOfCare' PV1: pv1Segment, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId -%} + {% endif -%} + + {% evaluate encounterId using 'ID/Encounter' PV1: pv1Segment, baseId: patientId -%} + {% assign fullEncounterId = encounterId | prepend: 'Encounter/' -%} + {% include 'Resource/Encounter' Root_Template: 'SIU_S15', PV1: pv1Segment, PV2: pv2Segment, ID: encounterId -%} + {% include 'Reference/Encounter/Subject' ID: encounterId, REF: fullPatientId -%} + {% include 'Extensions/Encounter/EncounterExtension' ID: encounterId, PV1: pv1Segment, PV2: pv2Segment -%} + {% endif -%} + + + {% for obxSegment in obxSegmentLists.OBX -%} + + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16 -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16 -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + + {% if obxSegment.18 -%} + {% evaluate deviceId_OBX_18 using 'ID/Device' EI: obxSegment.18.Repeats[0] -%} + {% include 'Resource/Device' EI_OBX18: obxSegment.18, ID: deviceId_OBX_18 -%} + {% endif -%} + + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23 -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + + {% evaluate observationId using 'ID/Observation' OBX: obxSegment, baseId: patientId -%} + + {% include 'Resource/Observation' OBX: obxSegment, Observation_Subject_ID: fullPatientId, ID: observationId -%} + {% include 'Extensions/Observation/ObservationExtension' OBX: obxSegment, ID: observationId %} + + {% endfor -%} + + {% for dg1Segment in dg1SegmentLists.DG1 -%} + + {% if dg1Segment.16.Repeats[0] %} + {% if dg1Segment.16.Repeats[0].9.1 != "" and dg1Segment.16.Repeats[0].9.1 != null and dg1Segment.16.Repeats[0].9.2 != "" and dg1Segment.16.Repeats[0].9.2 != null and dg1Segment.16.Repeats[0].9.3 != "" and dg1Segment.16.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_DG1_16 using 'ID/Organization' HDORG: dg1Segment.16.Repeats[0].9 -%} + {% include 'Resource/Organization', DG1: dg1Segment.16.Repeats[0].9, ID: Organization_ID_DG1_16 -%} + {% endif -%} + {% evaluate practitionerId_DG1_16 using 'ID/Practitioner' XCN: dg1Segment.16.Repeats[0] -%} + {% include 'Resource/Practitioner' DG1: dg1Segment, ID: practitionerId_DG1_16 -%} + {% endif -%} + + {% evaluate conditionId using 'ID/Condition' DG1: dg1Segment, baseId: patientId -%} + {% include 'Resource/Condition' DG1: dg1Segment, Condition_Subject_ID: fullPatientId, baseId: patientId, ID: conditionId -%} + + {% if encounterId -%} + {% include 'Resource/Encounter' DG1: dg1Segment, conditionId: conditionId, ID: encounterId -%} + {% endif %} + + {% if EpisodeOfCare_ID %} + {% include 'Resource/EpisodeOfCare' DG1: dg1Segment, conditionId: conditionId, ID: EpisodeOfCare_ID -%} + {% endif %} + + {% if dg1Segment.22 %} + {% evaluate conditionId_DG1_22 using 'ID/Condition' DG1: dg1Segment.22, baseId: patientId -%} + {% include 'Resource/Condition' DG1_22: dg1Segment.22, Condition_Subject_ID_DG1_22: fullPatientId, ID: conditionId_DG1_22 -%} + {% endif %} + {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} + {% endfor -%} + + {% endfor -%} + + {% for rgsSegment in rgsSegmentLists.RGS -%} + {% evaluate patientId using 'ID/Patient' PID: pidSegmentLists.PID[0], type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% assign aisSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIS' -%} + {% assign ailSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIL' -%} + {% assign aigSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIG' -%} + {% assign aipSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIP' -%} + + {% for aisSegment in aisSegmentLists.AIS -%} + {% assign nteSegmentLists = hl7v2Data | get_related_segment_list: aisSegment, 'NTE' -%} + {% evaluate serviceRequestId using 'ID/ServiceRequest' AIS: aisSegment, baseId: patientId -%} + {% include 'Resource/ServiceRequest' AIS: aisSegment, ID: serviceRequestId, ServiceRequest_Subject_ID: fullPatientId, ServiceRequest_Encounter_ID: fullEncounterId -%} + {% assign fullServiceRequestId = serviceRequestId | prepend: 'ServiceRequest/' -%} + {% include 'Reference/Appointment/BasedOn' ID: appointmentID, REF: fullServiceRequestId -%} + {% for nteSegment in nteSegmentLists.NTE -%} + {% if nteSegment.5 -%} + {% if nteSegment.5.9.1 != "" and nteSegment.5.9.1 != null and nteSegment.5.9.2 != "" and nteSegment.5.9.2 != null and nteSegment.5.9.3 != "" and nteSegment.5.9.3 != null -%} + {% evaluate Organization_ID_EVN_5_9 using 'ID/Organization' HDORG: nteSegment.5.9 -%} + {% include 'Resource/Organization', PV2: nteSegment.5.9, ID: Organization_ID_EVN_5_9 -%} + {% endif -%} + {% evaluate Practitioner_ID_NTE_5 using 'ID/Practitioner' XCN: nteSegment.5 -%} + {% include 'Resource/Practitioner' NTE: nteSegment.5, ID: Practitioner_ID_NTE_5 -%} + {% endif -%} + {% include 'Resource/ServiceRequest' NTE: nteSegment, ID: serviceRequestId -%} + {% endfor -%} + {% endfor -%} + + {% for aigSegment in aigSegmentLists.AIG -%} + {% assign nteSegmentLists = hl7v2Data | get_related_segment_list: aigSegment, 'NTE' -%} + {% evaluate device_Id_AIG_3 using 'ID/Device' AIG: aigSegment -%} + {% include 'Resource/Device' AIG: aigSegment, ID: device_Id_AIG_3 -%} + {% include 'Resource/Appointment' AIG: aigSegment, ID: appointmentID -%} + {% assign fullDevice_Id_AIG_3 = device_Id_AIG_3 | prepend: 'Device/' -%} + {% if aisSegmentLists.AIS -%} + {% include 'Reference/ServiceRequest/Performer' ID: serviceRequestId, REF: fullDevice_Id_AIG_3 -%} + {% endif -%} + {% for nteSegment in nteSegmentLists.NTE -%} + {% include 'Resource/Device' NTE: nteSegment, ID: device_Id_AIG_3 -%} + {% endfor -%} + {% endfor -%} + + {% for ailSegment in ailSegmentLists.AIL -%} + {% assign nteSegmentLists = hl7v2Data | get_related_segment_list: ailSegment, 'NTE' -%} + {% include 'Resource/PLLocation' PL: ailSegment.3, AIL_4: ailSegment.4 -%} + {% for nteSegment in nteSegmentLists.NTE -%} + {% include 'Resource/PLLocation' PL: ailSegment.3, NTE: nteSegment -%} + {% endfor -%} + + {% if ailSegment.3.1 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.1 -%} + {% elseif ailSegment.3.2 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.2 -%} + {% elseif ailSegment.3.3 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.3 -%} + {% elseif ailSegment.3.4 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.4 -%} + {% elseif ailSegment.3.7 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.7 -%} + {% elseif ailSegment.3.8 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.8 -%} + {% endif %} + {% assign fullLocation_ID_AIL_3 = Location_ID_AIL_3 | prepend: 'Location/' -%} + {% if aisSegmentLists.AIS -%} + {% include 'Reference/ServiceRequest/LocationReference' ID: serviceRequestId, REF: fullLocation_ID_AIL_3 -%} + {% endif %} + {% include 'Resource/Appointment' AIL: ailSegment, ID: appointmentID -%} + {% endfor -%} + + {% for aipSegment in aipSegmentLists.AIP -%} + {% if aipSegment.3 -%} + {% if aipSegment.3.9.1 != "" and aipSegment.3.9.1 != null and aipSegment.3.9.2 != "" and aipSegment.3.2 != null and aipSegment.3.9.3 != "" and aipSegment.3.9.3 != null -%} + {% evaluate organization_ID_AIP_3_9 using 'ID/Organization' HDORG: aipSegment.3.9 -%} + {% include 'Resource/Organization', AIP: aipSegment.3.9, ID: organization_ID_AIP_3_9 -%} + {% endif -%} + {% evaluate practitioner_ID_AIP_3 using 'ID/Practitioner' XCN: aipSegment.3 -%} + {% include 'Resource/Practitioner' AIP: aipSegment.3, ID: practitioner_ID_AIP_3 -%} + {% assign fullPractitioner_ID_AIP_3 = practitioner_ID_AIP_3 | prepend: 'Practitioner/' -%} + {% if aisSegmentLists.AIS -%} + {% include 'Reference/ServiceRequest/Performer' ID: serviceRequestId, REF: fullPractitioner_ID_AIP_3 -%} + {% endif -%} + {% endif -%} + {% include 'Resource/Appointment' AIP: aipSegment, ID: appointmentID -%} + {% endfor -%} + {% endfor -%} + ] +} \ No newline at end of file diff --git a/data/Templates/Hl7v2/SIU_S16.liquid b/data/Templates/Hl7v2/SIU_S16.liquid new file mode 100644 index 000000000..3e7aa99fd --- /dev/null +++ b/data/Templates/Hl7v2/SIU_S16.liquid @@ -0,0 +1,476 @@ +{% assign firstSegments = hl7v2Data | get_first_segments: 'MSH|SCH' -%} +{% assign tq1SegmentLists = hl7v2Data | get_segment_lists: 'TQ1' -%} +{% assign pidSegmentLists = hl7v2Data | get_segment_lists: 'PID' -%} +{% assign rgsSegmentLists = hl7v2Data | get_segment_lists: 'RGS' -%} +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} + +{ + "resourceType": "Bundle", + "type": "batch", + {% if firstSegments.MSH.7 -%} + "timestamp":"{{ firstSegments.MSH.7.Value | format_as_date_time }}", + {% endif -%} + "identifier": + { + "value":"{{ firstSegments.MSH.10.Value }}", + }, + "id":"{{ bundleID }}", + "entry": [ + + {% evaluate patientId using 'ID/Patient' PID: pidSegmentLists.PID[0], type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% evaluate messageHeaderId using 'ID/MessageHeader' MSH: firstSegments.MSH -%} + + {% if firstSegments.MSH -%} + + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, ID: messageHeaderId -%} + {% evaluate provenanceId using 'ID/Provenance' MSH: firstSegments.MSH, baseId: patientId -%} + {% include 'Resource/Provenance' Root_Template: 'SIU_S16', MSH: firstSegments.MSH, REF_BUNDLE: bundleID, ID: provenanceId -%} + + {%- comment -%} + {% assign transformation_val = 'provenance_transformation' %} + {% evaluate provenanceOrganizationId using 'ID/Organization', prov_id: firstSegments.MSH -%} + {% evaluate provenanceTransformationId using 'ID/Provenance_transformation' prov_id: transformation_val -%} + {% include 'Resource/Organization' org_name: 'Microsoft Corporation', ID: provenanceOrganizationId -%} + {% include 'Resource/Provenance_transformation' Root_Template: 'ADT_A01', Provenance_Organization_ID: provenanceOrganizationId, REF_MSH: messageHeaderId, provenanceOrganizationId, ID: provenanceTransformationId -%} + {%- endcomment -%} + + {% if firstSegments.MSH.4 -%} + {% if firstSegments.MSH.4.1 != "" and firstSegments.MSH.4.1 != null or firstSegments.MSH.4.2 != "" and firstSegments.MSH.4.2 != null or firstSegments.MSH.4.3 != "" and firstSegments.MSH.4.3 != null -%} + {% evaluate organization_ID_MSH_4 using 'ID/Organization' HD: firstSegments.MSH.4 -%} + {% include 'Resource/Organization' MSHHD1: firstSegments.MSH.4, MSH: firstSegments.MSH, ID: organization_ID_MSH_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.6 %} + {% if firstSegments.MSH.6.1 != "" and firstSegments.MSH.6.1 != null or firstSegments.MSH.6.2 != "" and firstSegments.MSH.6.2 != null or firstSegments.MSH.6.3 != "" and firstSegments.MSH.6.3 != null -%} + {% evaluate organization_Id_MSH_6 using 'ID/Organization' HD: firstSegments.MSH.6 -%} + {% include 'Resource/Organization' MSHHD2: firstSegments.MSH.6, MSH: firstSegments.MSH, ID: organization_Id_MSH_6 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.22 %} + {% if firstSegments.MSH.22.1 != "" and firstSegments.MSH.22.1 != null -%} + {% evaluate organization_Id_MSH_22 using 'ID/Organization' XON: firstSegments.MSH.22 -%} + {% include 'Resource/Organization' MSHXON1: firstSegments.MSH.22, ID: organization_Id_MSH_22 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.23 %} + {% if firstSegments.MSH.23.1 != "" and firstSegments.MSH.23.1 != null -%} + {% evaluate organization_Id_MSH_23 using 'ID/Organization' XON: firstSegments.MSH.23 -%} + {% include 'Resource/Organization' MSHXON2: firstSegments.MSH.23, ID: organization_Id_MSH_23 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.3 and firstSegments.MSH.24 %} + {% evaluate device_Id_MSH_3 using 'ID/Device' HD: firstSegments.MSH.3 -%} + {% include 'Resource/Device' MSH: firstSegments.MSH, ID: device_Id_MSH_3 -%} + {% endif -%} + + {% endif -%} + + {% if firstSegments.SCH -%} + {% assign nteSegmentSchLists = hl7v2Data | get_segment_lists: 'NTE' -%} + {% evaluate appointmentID using 'ID/Appointment' SCH: firstSegments.SCH, baseId: patientId-%} + {% include 'Resource/Appointment' SCH: firstSegments.SCH, ID: appointmentID, pidseg: pidSegmentLists, TQ1:tq1SegmentLists.TQ1[0], NTE: nteSegmentSchLists.NTE[0], type_sch: 16 -%} + {% if firstSegments.SCH.12 -%} + {% if firstSegments.SCH.12.9.1 != "" and firstSegments.SCH.12.9.1 != null and firstSegments.SCH.12.9.2 != "" and firstSegments.SCH.12.9.2 != null and firstSegments.SCH.12.9.3 != "" and firstSegments.SCH.12.9.3 != null -%} + {% evaluate Organization_ID_SCH_12 using 'ID/Organization' HDORG: firstSegments.SCH.12.9 -%} + {% include 'Resource/Organization' OBX: firstSegments.SCH.12.9, ID: Organization_ID_SCH_12 -%} + {% endif -%} + {% evaluate practitionerId_SCH_12 using 'ID/Practitioner' XCN: firstSegments.SCH.12 -%} + {% include 'Resource/Practitioner' SCH_12: firstSegments.SCH, ID: practitionerId_SCH_12 -%} + + {% evaluate practitionerRoleId_SCH_12 using 'ID/PractitionerRole' XCN: firstSegments.SCH.12 -%} + {% include 'Resource/PractitionerRole' SCH_12: firstSegments.SCH, ID: practitionerRoleId_SCH_12, REF_SCH_12: practitionerId_SCH_12 -%} + + {% include 'Resource/PLLocation' PL: firstSegments.SCH.15 -%} + + {% endif -%} + {% if firstSegments.SCH.16 -%} + {% if firstSegments.SCH.16.9.1 != "" and firstSegments.SCH.16.9.1 != null and firstSegments.SCH.16.9.2 != "" and firstSegments.SCH.16.9.2 != null and firstSegments.SCH.16.9.3 != "" and firstSegments.SCH.16.9.3 != null -%} + {% evaluate Organization_ID_SCH_16 using 'ID/Organization' HDORG: firstSegments.SCH.16.9 -%} + {% include 'Resource/Organization' OBX: firstSegments.SCH.16.9, ID: Organization_ID_SCH_16 -%} + {% endif -%} + {% evaluate practitionerId_SCH_16 using 'ID/Practitioner' XCN: firstSegments.SCH.16 -%} + {% include 'Resource/Practitioner' SCH_16: firstSegments.SCH, ID: practitionerId_SCH_16 -%} + + {% evaluate practitionerRoleId_SCH_16 using 'ID/PractitionerRole' XCN: firstSegments.SCH.16 -%} + {% include 'Resource/PractitionerRole' SCH_16: firstSegments.SCH, ID: practitionerRoleId_SCH_16, REF_SCH_16: practitionerId_SCH_16 -%} + + {% include 'Resource/PLLocation' PL: firstSegments.SCH.19 -%} + + {% endif -%} + {% if firstSegments.SCH.20 -%} + {% if firstSegments.SCH.20.9.1 != "" and firstSegments.SCH.20.9.1 != null and firstSegments.SCH.20.9.2 != "" and firstSegments.SCH.20.9.2 != null and firstSegments.SCH.20.9.3 != "" and firstSegments.SCH.20.9.3 != null -%} + {% evaluate Organization_ID_SCH_20 using 'ID/Organization' HDORG: firstSegments.SCH.20.9 -%} + {% include 'Resource/Organization' OBX: firstSegments.SCH.20.9, ID: Organization_ID_SCH_20 -%} + {% endif -%} + {% evaluate practitionerId_SCH_20 using 'ID/Practitioner' XCN: firstSegments.SCH.20 -%} + {% include 'Resource/Practitioner' SCH_20: firstSegments.SCH, ID: practitionerId_SCH_20 -%} + + {% evaluate practitionerRoleId_SCH_20 using 'ID/PractitionerRole' XCN: firstSegments.SCH.20 -%} + {% include 'Resource/PractitionerRole' SCH_20: firstSegments.SCH, ID: practitionerRoleId_SCH_20, REF_SCH_20: practitionerId_SCH_20 -%} + + {% include 'Resource/PLLocation' PL: firstSegments.SCH.22 -%} + + {% endif -%} + {% endif -%} + + {% for pidSegment in pidSegmentLists.PID -%} + {% evaluate patientId using 'ID/Patient' PID: pidSegment, type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + + {% assign pd1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PD1' -%} + {% assign pd1Segment = pd1SegmentLists.PD1[0] %} + {% assign pv1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PV1' -%} + {% assign pv1Segment = pv1SegmentLists.PV1[0] %} + {% assign pv2SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PV2' -%} + {% assign pv2Segment = pv2SegmentLists.PV2[0] %} + {% assign obxSegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'OBX' -%} + {% assign dg1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'DG1' -%} + + + {% include 'Resource/Patient' PID: pidSegment, PD1: pd1Segment, ID: patientId -%} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, PID: pidSegment, PD1: pd1Segment, PV1: pv1Segment -%} + + {% if pidSegment.18 -%} + {% evaluate accountId using 'ID/Account' CX: pidSegment.3 -%} + {% include 'Resource/Account' PID: pidSegment, ID: accountId -%} + {% include 'Reference/Account/Subject' ID: accountId, REF: fullPatientId -%} + {% if pidSegment.18.4.1 != "" and pidSegment.18.4.1 != null and pidSegment.18.4.2 != "" and pidSegment.18.4.2 != null and pidSegment.18.4.3 != "" and pidSegment.18.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_18 using 'ID/Organization' HDORG: pidSegment.18.4 -%} + {% include 'Resource/Organization', PID: pidSegment.18, ID: Organization_ID_pid_CX_18 -%} + {% endif -%} + {% endif -%} + + {% if pidSegment.2 -%} + {% if pidSegment.2.4.1 != "" and pidSegment.2.4.1 != null and pidSegment.2.4.2 != "" and pidSegment.2.4.2 != null and pidSegment.2.4.3 != "" and pidSegment.2.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_2 using 'ID/Organization' HDORG: pidSegment.2.4 -%} + {% include 'Resource/Organization', PID: pidSegment.2, ID: Organization_ID_pid_CX_2 -%} + {% endif -%} + {% endif -%} + {% for pid3 in pidSegment.3.Repeats -%} + {% if pid3.4.1 != "" and pid3.4.1 != null and pid3.4.2 != "" and pid3.4.2 != null and pid3.4.3 != "" and pid3.4.3 != null -%} + {% evaluate Organization_ID_pid_CX using 'ID/Organization' HDORG: pid3.4 -%} + {% include 'Resource/Organization', PID: pid3, ID: Organization_ID_pid_CX -%} + {% endif -%} + {% endfor -%} + {% if pidSegment.4 -%} + {% if pidSegment.4.4.1 != "" and pidSegment.4.4.1 != null and pidSegment.4.4.2 != "" and pidSegment.4.4.2 != null and pidSegment.4.4.3 != "" and pidSegment.4.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_4 using 'ID/Organization' HDORG: pidSegment.4.4 -%} + {% include 'Resource/Organization', PID: pidSegment.4, ID: Organization_ID_pid_CX_4 -%} + {% endif -%} + {% endif -%} + + {% unless nk1SegmentLists.NK1 -%} + {% if pidSegment.21 -%} + {% if pidSegment.21.4.1 != "" and pidSegment.21.4.1 != null and pidSegment.21.4.2 != "" and pidSegment.21.4.2 != null and pidSegment.21.4.3 != "" and pidSegment.21.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_21 using 'ID/Organization' HDORG: pidSegment.21.4 -%} + {% include 'Resource/Organization', PID: pidSegment.21, ID: Organization_ID_pid_CX_21 -%} + {% endif -%} + {% evaluate pidrelatedPersonId using 'ID/RelatedPerson' PID: pidSegment, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: pidrelatedPersonId, PID: pidSegment -%} + {% endif -%} + {% endunless -%} + + {% if pd1Segment.3 -%} + {% evaluate Organization_ID_PD1_3 using 'ID/Organization' XON: pd1Segment.3 -%} + {% include 'Resource/Organization' PD1: pd1Segment, ID: Organization_ID_PD1_3 -%} + {% endif -%} + + {% if pd1Segment.4 -%} + {% if pd1Segment.4.9.1 != "" and pd1Segment.4.9.1 != null and pd1Segment.4.9.2 != "" and pd1Segment.4.9.2 != null and pd1Segment.4.9.3 != "" and pd1Segment.4.9.3 != null -%} + {% evaluate Organization_ID_PD1_4_9 using 'ID/Organization' HDORG: pd1Segment.4.9 -%} + {% include 'Resource/Organization', PD1_4: pd1Segment.4.9, ID: Organization_ID_PD1_4_9 -%} + {% endif -%} + {% evaluate Practitioner_ID_PD1_4 using 'ID/Practitioner' XCN: pd1Segment.4 -%} + {% include 'Resource/Practitioner' PD1: pd1Segment.4, ID: Practitioner_ID_PD1_4 -%} + {% endif -%} + + + {% if pv1Segment -%} + {% if pv1Segment.5 -%} + {% if pv1Segment.5.4.1 != "" and pv1Segment.5.4.1 != null and pv1Segment.5.4.2 != "" and pv1Segment.5.4.2 != null and pv1Segment.5.4.3 != "" and pv1Segment.5.4.3 != null -%} + {% evaluate Organization_ID_PV1_5_4 using 'ID/Organization' HDORG: pv1Segment.5.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.5.4, ID: Organization_ID_PV1_5_4 -%} + {% endif -%} + {% endif -%} + + {% if pv1Segment.19 -%} + {% if pv1Segment.19.4.1 != "" and pv1Segment.19.4.1 != null and pv1Segment.19.4.2 != "" and pv1Segment.19.4.2 != null and pv1Segment.19.4.3 != "" and pv1Segment.19.4.3 != null -%} + {% evaluate Organization_ID_PV1_19_4 using 'ID/Organization' HDORG: pv1Segment.19.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.19.4, ID: Organization_ID_PV1_19_4 -%} + {% endif -%} + {% endif -%} + + {% if pv1Segment.7 -%} + {% if pv1Segment.7.9.1 != "" and pv1Segment.7.9.1 != null and pv1Segment.7.9.2 != "" and pv1Segment.7.9.2 != null and pv1Segment.7.9.3 != "" and pv1Segment.7.9.3 != null -%} + {% evaluate Organization_ID_PV1_7_9 using 'ID/Organization' HDORG: pv1Segment.7.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.7.9, ID: Organization_ID_PV1_7_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_7 using 'ID/Practitioner' XCN: pv1Segment.7 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.7, ID: practitionerId_PV1_7 -%} + {% endif -%} + + {% if pv1Segment.8 -%} + {% if pv1Segment.8.9.1 != "" and pv1Segment.8.9.1 != null and pv1Segment.8.9.2 != "" and pv1Segment.8.9.2 != null and pv1Segment.8.9.3 != "" and pv1Segment.8.9.3 != null -%} + {% evaluate Organization_ID_PV1_8_9 using 'ID/Organization' HDORG: pv1Segment.8.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.8.9, ID: Organization_ID_PV1_8_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_8 using 'ID/Practitioner' XCN: pv1Segment.8 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.8, ID: practitionerId_PV1_8 -%} + {% endif -%} + + {% if pv1Segment.9 -%} + {% if pv1Segment.9.9.1 != "" and pv1Segment.9.9.1 != null and pv1Segment.9.9.2 != "" and pv1Segment.9.9.2 != null and pv1Segment.9.9.3 != "" and pv1Segment.9.9.3 != null -%} + {% evaluate Organization_ID_PV1_9_9 using 'ID/Organization' HDORG: pv1Segment.9.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.9.9, ID: Organization_ID_PV1_9_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_9 using 'ID/Practitioner' XCN: pv1Segment.9 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.9, ID: practitionerId_PV1_9 -%} + {% endif -%} + + {% if pv1Segment.17 -%} + {% if pv1Segment.17.9.1 != "" and pv1Segment.17.9.1 != null and pv1Segment.17.9.2 != "" and pv1Segment.17.9.2 != null and pv1Segment.17.9.3 != "" and pv1Segment.17.9.3 != null -%} + {% evaluate Organization_ID_PV1_17_9 using 'ID/Organization' HDORG: pv1Segment.17.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.17.9, ID: Organization_ID_PV1_17_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_17 using 'ID/Practitioner' XCN: pv1Segment.17 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.17, ID: practitionerId_PV1_17 -%} + {% endif -%} + + {% if pv1Segment.50 -%} + {% for p in pv1Segment.50.Repeats -%} + {% if p.4.1 != "" and p.4.1 != null and p.4.2 != "" and p.4.2 != null and p.4.3 != "" and p.4.3 != null -%} + {% evaluate Organization_ID_PV1_50_4 using 'ID/Organization' HDORG: p.4 -%} + {% include 'Resource/Organization', PV1: p.4, ID: Organization_ID_PV1_50_4 -%} + {% endif -%} + {% endfor -%} + {% endif -%} + + {% if pv1Segment.52 -%} + {% if pv1Segment.52.9.1 != "" and pv1Segment.52.9.1 != null and pv1Segment.52.9.2 != "" and pv1Segment.52.9.2 != null and pv1Segment.52.9.3 != "" and pv1Segment.52.9.3 != null -%} + {% evaluate Organization_ID_PV1_52_9 using 'ID/Organization' HDORG: pv1Segment.52.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.52.9, ID: Organization_ID_PV1_52_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_52 using 'ID/Practitioner' XCN: pv1Segment.52 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.52, ID: practitionerId_PV1_52 -%} + {% endif -%} + + {% if pv2Segment.13 -%} + {% if pv2Segment.13.9.1 != "" and pv2Segment.13.9.1 != null and pv2Segment.13.9.2 != "" and pv2Segment.13.9.2 != null and pv2Segment.13.9.3 != "" and pv2Segment.13.9.3 != null -%} + {% evaluate Organization_ID_PV2_13_9 using 'ID/Organization' HDORG: pv2Segment.13.9 -%} + {% include 'Resource/Organization', PV2: pv2Segment.13.9, ID: Organization_ID_PV2_13_9 -%} + {% endif -%} + {% evaluate practitionerId_PV2_13 using 'ID/Practitioner' XCN: pv2Segment.13 -%} + {% include 'Resource/Practitioner' PV1: pv2Segment.13, ID: practitionerId_PV2_13 -%} + {% endif -%} + + {% if pv1Segment.3 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.3-%} + {% endif -%} + + {% if pv1Segment.6 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.6 -%} + {% endif -%} + + {% if pv1Segment.37 -%} + {% evaluate location_ID_PV1_37 using 'ID/Location' DLD: pv1Segment.37 -%} + {% include 'Resource/Location' PV1: pv1Segment.37, ID: location_ID_PV1_37-%} + {% endif -%} + + {% if pv1Segment.42 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.42-%} + {% endif -%} + + {% if pv1Segment.43 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.43-%} + {% endif -%} + + {% if pv2Segment.1 -%} + {% include 'Resource/PLLocation' PL: pv2Segment.1-%} + {% endif -%} + + {% if pv1Segment.54 -%} + {% if pv1Segment.54.4.1 != "" and pv1Segment.54.4.1 != null and pv1Segment.54.4.2 != "" and pv1Segment.54.4.2 != null and pv1Segment.54.4.3 != "" and pv1Segment.54.4.3 != null -%} + {% evaluate Organization_ID_PV1_54_4 using 'ID/Organization' HDORG: pv1Segment.54.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.54.4, ID: Organization_ID_PV1_54_4 -%} + {% endif -%} + {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: pv1Segment.54 -%} + {% include 'Resource/EpisodeOfCare' PV1: pv1Segment, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId -%} + {% endif -%} + + {% evaluate encounterId using 'ID/Encounter' PV1: pv1Segment, baseId: patientId -%} + {% assign fullEncounterId = encounterId | prepend: 'Encounter/' -%} + {% include 'Resource/Encounter' Root_Template: 'SIU_S16', PV1: pv1Segment, PV2: pv2Segment, ID: encounterId -%} + {% include 'Reference/Encounter/Subject' ID: encounterId, REF: fullPatientId -%} + {% include 'Extensions/Encounter/EncounterExtension' ID: encounterId, PV1: pv1Segment, PV2: pv2Segment -%} + {% endif -%} + + + {% for obxSegment in obxSegmentLists.OBX -%} + + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16 -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16 -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + + {% if obxSegment.18 -%} + {% evaluate deviceId_OBX_18 using 'ID/Device' EI: obxSegment.18.Repeats[0] -%} + {% include 'Resource/Device' EI_OBX18: obxSegment.18, ID: deviceId_OBX_18 -%} + {% endif -%} + + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23 -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + + {% evaluate observationId using 'ID/Observation' OBX: obxSegment, baseId: patientId -%} + + {% include 'Resource/Observation' OBX: obxSegment, Observation_Subject_ID: fullPatientId, ID: observationId -%} + {% include 'Extensions/Observation/ObservationExtension' OBX: obxSegment, ID: observationId %} + + {% endfor -%} + + {% for dg1Segment in dg1SegmentLists.DG1 -%} + + {% if dg1Segment.16.Repeats[0] %} + {% if dg1Segment.16.Repeats[0].9.1 != "" and dg1Segment.16.Repeats[0].9.1 != null and dg1Segment.16.Repeats[0].9.2 != "" and dg1Segment.16.Repeats[0].9.2 != null and dg1Segment.16.Repeats[0].9.3 != "" and dg1Segment.16.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_DG1_16 using 'ID/Organization' HDORG: dg1Segment.16.Repeats[0].9 -%} + {% include 'Resource/Organization', DG1: dg1Segment.16.Repeats[0].9, ID: Organization_ID_DG1_16 -%} + {% endif -%} + {% evaluate practitionerId_DG1_16 using 'ID/Practitioner' XCN: dg1Segment.16.Repeats[0] -%} + {% include 'Resource/Practitioner' DG1: dg1Segment, ID: practitionerId_DG1_16 -%} + {% endif -%} + + {% evaluate conditionId using 'ID/Condition' DG1: dg1Segment, baseId: patientId -%} + {% include 'Resource/Condition' DG1: dg1Segment, Condition_Subject_ID: fullPatientId, baseId: patientId, ID: conditionId -%} + + {% if encounterId -%} + {% include 'Resource/Encounter' DG1: dg1Segment, conditionId: conditionId, ID: encounterId -%} + {% endif %} + + {% if EpisodeOfCare_ID %} + {% include 'Resource/EpisodeOfCare' DG1: dg1Segment, conditionId: conditionId, ID: EpisodeOfCare_ID -%} + {% endif %} + + {% if dg1Segment.22 %} + {% evaluate conditionId_DG1_22 using 'ID/Condition' DG1: dg1Segment.22, baseId: patientId -%} + {% include 'Resource/Condition' DG1_22: dg1Segment.22, Condition_Subject_ID_DG1_22: fullPatientId, ID: conditionId_DG1_22 -%} + {% endif %} + {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} + {% endfor -%} + + {% endfor -%} + + {% for rgsSegment in rgsSegmentLists.RGS -%} + {% evaluate patientId using 'ID/Patient' PID: pidSegmentLists.PID[0], type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% assign aisSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIS' -%} + {% assign ailSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIL' -%} + {% assign aigSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIG' -%} + {% assign aipSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIP' -%} + + {% for aisSegment in aisSegmentLists.AIS -%} + {% assign nteSegmentLists = hl7v2Data | get_related_segment_list: aisSegment, 'NTE' -%} + {% evaluate serviceRequestId using 'ID/ServiceRequest' AIS: aisSegment, baseId: patientId -%} + {% include 'Resource/ServiceRequest' AIS: aisSegment, ID: serviceRequestId, ServiceRequest_Subject_ID: fullPatientId, ServiceRequest_Encounter_ID: fullEncounterId -%} + {% assign fullServiceRequestId = serviceRequestId | prepend: 'ServiceRequest/' -%} + {% include 'Reference/Appointment/BasedOn' ID: appointmentID, REF: fullServiceRequestId -%} + {% for nteSegment in nteSegmentLists.NTE -%} + {% if nteSegment.5 -%} + {% if nteSegment.5.9.1 != "" and nteSegment.5.9.1 != null and nteSegment.5.9.2 != "" and nteSegment.5.9.2 != null and nteSegment.5.9.3 != "" and nteSegment.5.9.3 != null -%} + {% evaluate Organization_ID_EVN_5_9 using 'ID/Organization' HDORG: nteSegment.5.9 -%} + {% include 'Resource/Organization', PV2: nteSegment.5.9, ID: Organization_ID_EVN_5_9 -%} + {% endif -%} + {% evaluate Practitioner_ID_NTE_5 using 'ID/Practitioner' XCN: nteSegment.5 -%} + {% include 'Resource/Practitioner' NTE: nteSegment.5, ID: Practitioner_ID_NTE_5 -%} + {% endif -%} + {% include 'Resource/ServiceRequest' NTE: nteSegment, ID: serviceRequestId -%} + {% endfor -%} + {% endfor -%} + + {% for aigSegment in aigSegmentLists.AIG -%} + {% assign nteSegmentLists = hl7v2Data | get_related_segment_list: aigSegment, 'NTE' -%} + {% evaluate device_Id_AIG_3 using 'ID/Device' AIG: aigSegment -%} + {% include 'Resource/Device' AIG: aigSegment, ID: device_Id_AIG_3 -%} + {% include 'Resource/Appointment' AIG: aigSegment, ID: appointmentID -%} + {% assign fullDevice_Id_AIG_3 = device_Id_AIG_3 | prepend: 'Device/' -%} + {% if aisSegmentLists.AIS -%} + {% include 'Reference/ServiceRequest/Performer' ID: serviceRequestId, REF: fullDevice_Id_AIG_3 -%} + {% endif -%} + {% for nteSegment in nteSegmentLists.NTE -%} + {% include 'Resource/Device' NTE: nteSegment, ID: device_Id_AIG_3 -%} + {% endfor -%} + {% endfor -%} + + {% for ailSegment in ailSegmentLists.AIL -%} + {% assign nteSegmentLists = hl7v2Data | get_related_segment_list: ailSegment, 'NTE' -%} + {% include 'Resource/PLLocation' PL: ailSegment.3, AIL_4: ailSegment.4 -%} + {% for nteSegment in nteSegmentLists.NTE -%} + {% include 'Resource/PLLocation' PL: ailSegment.3, NTE: nteSegment -%} + {% endfor -%} + + {% if ailSegment.3.1 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.1 -%} + {% elseif ailSegment.3.2 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.2 -%} + {% elseif ailSegment.3.3 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.3 -%} + {% elseif ailSegment.3.4 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.4 -%} + {% elseif ailSegment.3.7 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.7 -%} + {% elseif ailSegment.3.8 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.8 -%} + {% endif %} + {% assign fullLocation_ID_AIL_3 = Location_ID_AIL_3 | prepend: 'Location/' -%} + {% if aisSegmentLists.AIS -%} + {% include 'Reference/ServiceRequest/LocationReference' ID: serviceRequestId, REF: fullLocation_ID_AIL_3 -%} + {% endif %} + {% include 'Resource/Appointment' AIL: ailSegment, ID: appointmentID -%} + {% endfor -%} + + {% for aipSegment in aipSegmentLists.AIP -%} + {% if aipSegment.3 -%} + {% if aipSegment.3.9.1 != "" and aipSegment.3.9.1 != null and aipSegment.3.9.2 != "" and aipSegment.3.2 != null and aipSegment.3.9.3 != "" and aipSegment.3.9.3 != null -%} + {% evaluate organization_ID_AIP_3_9 using 'ID/Organization' HDORG: aipSegment.3.9 -%} + {% include 'Resource/Organization', AIP: aipSegment.3.9, ID: organization_ID_AIP_3_9 -%} + {% endif -%} + {% evaluate practitioner_ID_AIP_3 using 'ID/Practitioner' XCN: aipSegment.3 -%} + {% include 'Resource/Practitioner' AIP: aipSegment.3, ID: practitioner_ID_AIP_3 -%} + {% assign fullPractitioner_ID_AIP_3 = practitioner_ID_AIP_3 | prepend: 'Practitioner/' -%} + {% if aisSegmentLists.AIS -%} + {% include 'Reference/ServiceRequest/Performer' ID: serviceRequestId, REF: fullPractitioner_ID_AIP_3 -%} + {% endif -%} + {% endif -%} + {% include 'Resource/Appointment' AIP: aipSegment, ID: appointmentID -%} + {% endfor -%} + {% endfor -%} + ] +} \ No newline at end of file diff --git a/data/Templates/Hl7v2/SIU_S17.liquid b/data/Templates/Hl7v2/SIU_S17.liquid new file mode 100644 index 000000000..2c64c02e8 --- /dev/null +++ b/data/Templates/Hl7v2/SIU_S17.liquid @@ -0,0 +1,476 @@ +{% assign firstSegments = hl7v2Data | get_first_segments: 'MSH|SCH' -%} +{% assign tq1SegmentLists = hl7v2Data | get_segment_lists: 'TQ1' -%} +{% assign pidSegmentLists = hl7v2Data | get_segment_lists: 'PID' -%} +{% assign rgsSegmentLists = hl7v2Data | get_segment_lists: 'RGS' -%} +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} + +{ + "resourceType": "Bundle", + "type": "batch", + {% if firstSegments.MSH.7 -%} + "timestamp":"{{ firstSegments.MSH.7.Value | format_as_date_time }}", + {% endif -%} + "identifier": + { + "value":"{{ firstSegments.MSH.10.Value }}", + }, + "id":"{{ bundleID }}", + "entry": [ + + {% evaluate patientId using 'ID/Patient' PID: pidSegmentLists.PID[0], type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% evaluate messageHeaderId using 'ID/MessageHeader' MSH: firstSegments.MSH -%} + + {% if firstSegments.MSH -%} + + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, ID: messageHeaderId -%} + {% evaluate provenanceId using 'ID/Provenance' MSH: firstSegments.MSH, baseId: patientId -%} + {% include 'Resource/Provenance' Root_Template: 'SIU_S17', MSH: firstSegments.MSH, REF_BUNDLE: bundleID, ID: provenanceId -%} + + {%- comment -%} + {% assign transformation_val = 'provenance_transformation' %} + {% evaluate provenanceOrganizationId using 'ID/Organization', prov_id: firstSegments.MSH -%} + {% evaluate provenanceTransformationId using 'ID/Provenance_transformation' prov_id: transformation_val -%} + {% include 'Resource/Organization' org_name: 'Microsoft Corporation', ID: provenanceOrganizationId -%} + {% include 'Resource/Provenance_transformation' Root_Template: 'ADT_A01', Provenance_Organization_ID: provenanceOrganizationId, REF_MSH: messageHeaderId, provenanceOrganizationId, ID: provenanceTransformationId -%} + {%- endcomment -%} + + {% if firstSegments.MSH.4 -%} + {% if firstSegments.MSH.4.1 != "" and firstSegments.MSH.4.1 != null or firstSegments.MSH.4.2 != "" and firstSegments.MSH.4.2 != null or firstSegments.MSH.4.3 != "" and firstSegments.MSH.4.3 != null -%} + {% evaluate organization_ID_MSH_4 using 'ID/Organization' HD: firstSegments.MSH.4 -%} + {% include 'Resource/Organization' MSHHD1: firstSegments.MSH.4, MSH: firstSegments.MSH, ID: organization_ID_MSH_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.6 %} + {% if firstSegments.MSH.6.1 != "" and firstSegments.MSH.6.1 != null or firstSegments.MSH.6.2 != "" and firstSegments.MSH.6.2 != null or firstSegments.MSH.6.3 != "" and firstSegments.MSH.6.3 != null -%} + {% evaluate organization_Id_MSH_6 using 'ID/Organization' HD: firstSegments.MSH.6 -%} + {% include 'Resource/Organization' MSHHD2: firstSegments.MSH.6, MSH: firstSegments.MSH, ID: organization_Id_MSH_6 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.22 %} + {% if firstSegments.MSH.22.1 != "" and firstSegments.MSH.22.1 != null -%} + {% evaluate organization_Id_MSH_22 using 'ID/Organization' XON: firstSegments.MSH.22 -%} + {% include 'Resource/Organization' MSHXON1: firstSegments.MSH.22, ID: organization_Id_MSH_22 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.23 %} + {% if firstSegments.MSH.23.1 != "" and firstSegments.MSH.23.1 != null -%} + {% evaluate organization_Id_MSH_23 using 'ID/Organization' XON: firstSegments.MSH.23 -%} + {% include 'Resource/Organization' MSHXON2: firstSegments.MSH.23, ID: organization_Id_MSH_23 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.3 and firstSegments.MSH.24 %} + {% evaluate device_Id_MSH_3 using 'ID/Device' HD: firstSegments.MSH.3 -%} + {% include 'Resource/Device' MSH: firstSegments.MSH, ID: device_Id_MSH_3 -%} + {% endif -%} + + {% endif -%} + + {% if firstSegments.SCH -%} + {% assign nteSegmentSchLists = hl7v2Data | get_segment_lists: 'NTE' -%} + {% evaluate appointmentID using 'ID/Appointment' SCH: firstSegments.SCH, baseId: patientId-%} + {% include 'Resource/Appointment' SCH: firstSegments.SCH, ID: appointmentID, pidseg: pidSegmentLists, TQ1:tq1SegmentLists.TQ1[0], NTE: nteSegmentSchLists.NTE[0], type_sch: 17 -%} + {% if firstSegments.SCH.12 -%} + {% if firstSegments.SCH.12.9.1 != "" and firstSegments.SCH.12.9.1 != null and firstSegments.SCH.12.9.2 != "" and firstSegments.SCH.12.9.2 != null and firstSegments.SCH.12.9.3 != "" and firstSegments.SCH.12.9.3 != null -%} + {% evaluate Organization_ID_SCH_12 using 'ID/Organization' HDORG: firstSegments.SCH.12.9 -%} + {% include 'Resource/Organization' OBX: firstSegments.SCH.12.9, ID: Organization_ID_SCH_12 -%} + {% endif -%} + {% evaluate practitionerId_SCH_12 using 'ID/Practitioner' XCN: firstSegments.SCH.12 -%} + {% include 'Resource/Practitioner' SCH_12: firstSegments.SCH, ID: practitionerId_SCH_12 -%} + + {% evaluate practitionerRoleId_SCH_12 using 'ID/PractitionerRole' XCN: firstSegments.SCH.12 -%} + {% include 'Resource/PractitionerRole' SCH_12: firstSegments.SCH, ID: practitionerRoleId_SCH_12, REF_SCH_12: practitionerId_SCH_12 -%} + + {% include 'Resource/PLLocation' PL: firstSegments.SCH.15 -%} + + {% endif -%} + {% if firstSegments.SCH.16 -%} + {% if firstSegments.SCH.16.9.1 != "" and firstSegments.SCH.16.9.1 != null and firstSegments.SCH.16.9.2 != "" and firstSegments.SCH.16.9.2 != null and firstSegments.SCH.16.9.3 != "" and firstSegments.SCH.16.9.3 != null -%} + {% evaluate Organization_ID_SCH_16 using 'ID/Organization' HDORG: firstSegments.SCH.16.9 -%} + {% include 'Resource/Organization' OBX: firstSegments.SCH.16.9, ID: Organization_ID_SCH_16 -%} + {% endif -%} + {% evaluate practitionerId_SCH_16 using 'ID/Practitioner' XCN: firstSegments.SCH.16 -%} + {% include 'Resource/Practitioner' SCH_16: firstSegments.SCH, ID: practitionerId_SCH_16 -%} + + {% evaluate practitionerRoleId_SCH_16 using 'ID/PractitionerRole' XCN: firstSegments.SCH.16 -%} + {% include 'Resource/PractitionerRole' SCH_16: firstSegments.SCH, ID: practitionerRoleId_SCH_16, REF_SCH_16: practitionerId_SCH_16 -%} + + {% include 'Resource/PLLocation' PL: firstSegments.SCH.19 -%} + + {% endif -%} + {% if firstSegments.SCH.20 -%} + {% if firstSegments.SCH.20.9.1 != "" and firstSegments.SCH.20.9.1 != null and firstSegments.SCH.20.9.2 != "" and firstSegments.SCH.20.9.2 != null and firstSegments.SCH.20.9.3 != "" and firstSegments.SCH.20.9.3 != null -%} + {% evaluate Organization_ID_SCH_20 using 'ID/Organization' HDORG: firstSegments.SCH.20.9 -%} + {% include 'Resource/Organization' OBX: firstSegments.SCH.20.9, ID: Organization_ID_SCH_20 -%} + {% endif -%} + {% evaluate practitionerId_SCH_20 using 'ID/Practitioner' XCN: firstSegments.SCH.20 -%} + {% include 'Resource/Practitioner' SCH_20: firstSegments.SCH, ID: practitionerId_SCH_20 -%} + + {% evaluate practitionerRoleId_SCH_20 using 'ID/PractitionerRole' XCN: firstSegments.SCH.20 -%} + {% include 'Resource/PractitionerRole' SCH_20: firstSegments.SCH, ID: practitionerRoleId_SCH_20, REF_SCH_20: practitionerId_SCH_20 -%} + + {% include 'Resource/PLLocation' PL: firstSegments.SCH.22 -%} + + {% endif -%} + {% endif -%} + + {% for pidSegment in pidSegmentLists.PID -%} + {% evaluate patientId using 'ID/Patient' PID: pidSegment, type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + + {% assign pd1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PD1' -%} + {% assign pd1Segment = pd1SegmentLists.PD1[0] %} + {% assign pv1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PV1' -%} + {% assign pv1Segment = pv1SegmentLists.PV1[0] %} + {% assign pv2SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PV2' -%} + {% assign pv2Segment = pv2SegmentLists.PV2[0] %} + {% assign obxSegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'OBX' -%} + {% assign dg1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'DG1' -%} + + + {% include 'Resource/Patient' PID: pidSegment, PD1: pd1Segment, ID: patientId -%} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, PID: pidSegment, PD1: pd1Segment, PV1: pv1Segment -%} + + {% if pidSegment.18 -%} + {% evaluate accountId using 'ID/Account' CX: pidSegment.3 -%} + {% include 'Resource/Account' PID: pidSegment, ID: accountId -%} + {% include 'Reference/Account/Subject' ID: accountId, REF: fullPatientId -%} + {% if pidSegment.18.4.1 != "" and pidSegment.18.4.1 != null and pidSegment.18.4.2 != "" and pidSegment.18.4.2 != null and pidSegment.18.4.3 != "" and pidSegment.18.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_18 using 'ID/Organization' HDORG: pidSegment.18.4 -%} + {% include 'Resource/Organization', PID: pidSegment.18, ID: Organization_ID_pid_CX_18 -%} + {% endif -%} + {% endif -%} + + {% if pidSegment.2 -%} + {% if pidSegment.2.4.1 != "" and pidSegment.2.4.1 != null and pidSegment.2.4.2 != "" and pidSegment.2.4.2 != null and pidSegment.2.4.3 != "" and pidSegment.2.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_2 using 'ID/Organization' HDORG: pidSegment.2.4 -%} + {% include 'Resource/Organization', PID: pidSegment.2, ID: Organization_ID_pid_CX_2 -%} + {% endif -%} + {% endif -%} + {% for pid3 in pidSegment.3.Repeats -%} + {% if pid3.4.1 != "" and pid3.4.1 != null and pid3.4.2 != "" and pid3.4.2 != null and pid3.4.3 != "" and pid3.4.3 != null -%} + {% evaluate Organization_ID_pid_CX using 'ID/Organization' HDORG: pid3.4 -%} + {% include 'Resource/Organization', PID: pid3, ID: Organization_ID_pid_CX -%} + {% endif -%} + {% endfor -%} + {% if pidSegment.4 -%} + {% if pidSegment.4.4.1 != "" and pidSegment.4.4.1 != null and pidSegment.4.4.2 != "" and pidSegment.4.4.2 != null and pidSegment.4.4.3 != "" and pidSegment.4.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_4 using 'ID/Organization' HDORG: pidSegment.4.4 -%} + {% include 'Resource/Organization', PID: pidSegment.4, ID: Organization_ID_pid_CX_4 -%} + {% endif -%} + {% endif -%} + + {% unless nk1SegmentLists.NK1 -%} + {% if pidSegment.21 -%} + {% if pidSegment.21.4.1 != "" and pidSegment.21.4.1 != null and pidSegment.21.4.2 != "" and pidSegment.21.4.2 != null and pidSegment.21.4.3 != "" and pidSegment.21.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_21 using 'ID/Organization' HDORG: pidSegment.21.4 -%} + {% include 'Resource/Organization', PID: pidSegment.21, ID: Organization_ID_pid_CX_21 -%} + {% endif -%} + {% evaluate pidrelatedPersonId using 'ID/RelatedPerson' PID: pidSegment, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: pidrelatedPersonId, PID: pidSegment -%} + {% endif -%} + {% endunless -%} + + {% if pd1Segment.3 -%} + {% evaluate Organization_ID_PD1_3 using 'ID/Organization' XON: pd1Segment.3 -%} + {% include 'Resource/Organization' PD1: pd1Segment, ID: Organization_ID_PD1_3 -%} + {% endif -%} + + {% if pd1Segment.4 -%} + {% if pd1Segment.4.9.1 != "" and pd1Segment.4.9.1 != null and pd1Segment.4.9.2 != "" and pd1Segment.4.9.2 != null and pd1Segment.4.9.3 != "" and pd1Segment.4.9.3 != null -%} + {% evaluate Organization_ID_PD1_4_9 using 'ID/Organization' HDORG: pd1Segment.4.9 -%} + {% include 'Resource/Organization', PD1_4: pd1Segment.4.9, ID: Organization_ID_PD1_4_9 -%} + {% endif -%} + {% evaluate Practitioner_ID_PD1_4 using 'ID/Practitioner' XCN: pd1Segment.4 -%} + {% include 'Resource/Practitioner' PD1: pd1Segment.4, ID: Practitioner_ID_PD1_4 -%} + {% endif -%} + + + {% if pv1Segment -%} + {% if pv1Segment.5 -%} + {% if pv1Segment.5.4.1 != "" and pv1Segment.5.4.1 != null and pv1Segment.5.4.2 != "" and pv1Segment.5.4.2 != null and pv1Segment.5.4.3 != "" and pv1Segment.5.4.3 != null -%} + {% evaluate Organization_ID_PV1_5_4 using 'ID/Organization' HDORG: pv1Segment.5.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.5.4, ID: Organization_ID_PV1_5_4 -%} + {% endif -%} + {% endif -%} + + {% if pv1Segment.19 -%} + {% if pv1Segment.19.4.1 != "" and pv1Segment.19.4.1 != null and pv1Segment.19.4.2 != "" and pv1Segment.19.4.2 != null and pv1Segment.19.4.3 != "" and pv1Segment.19.4.3 != null -%} + {% evaluate Organization_ID_PV1_19_4 using 'ID/Organization' HDORG: pv1Segment.19.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.19.4, ID: Organization_ID_PV1_19_4 -%} + {% endif -%} + {% endif -%} + + {% if pv1Segment.7 -%} + {% if pv1Segment.7.9.1 != "" and pv1Segment.7.9.1 != null and pv1Segment.7.9.2 != "" and pv1Segment.7.9.2 != null and pv1Segment.7.9.3 != "" and pv1Segment.7.9.3 != null -%} + {% evaluate Organization_ID_PV1_7_9 using 'ID/Organization' HDORG: pv1Segment.7.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.7.9, ID: Organization_ID_PV1_7_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_7 using 'ID/Practitioner' XCN: pv1Segment.7 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.7, ID: practitionerId_PV1_7 -%} + {% endif -%} + + {% if pv1Segment.8 -%} + {% if pv1Segment.8.9.1 != "" and pv1Segment.8.9.1 != null and pv1Segment.8.9.2 != "" and pv1Segment.8.9.2 != null and pv1Segment.8.9.3 != "" and pv1Segment.8.9.3 != null -%} + {% evaluate Organization_ID_PV1_8_9 using 'ID/Organization' HDORG: pv1Segment.8.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.8.9, ID: Organization_ID_PV1_8_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_8 using 'ID/Practitioner' XCN: pv1Segment.8 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.8, ID: practitionerId_PV1_8 -%} + {% endif -%} + + {% if pv1Segment.9 -%} + {% if pv1Segment.9.9.1 != "" and pv1Segment.9.9.1 != null and pv1Segment.9.9.2 != "" and pv1Segment.9.9.2 != null and pv1Segment.9.9.3 != "" and pv1Segment.9.9.3 != null -%} + {% evaluate Organization_ID_PV1_9_9 using 'ID/Organization' HDORG: pv1Segment.9.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.9.9, ID: Organization_ID_PV1_9_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_9 using 'ID/Practitioner' XCN: pv1Segment.9 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.9, ID: practitionerId_PV1_9 -%} + {% endif -%} + + {% if pv1Segment.17 -%} + {% if pv1Segment.17.9.1 != "" and pv1Segment.17.9.1 != null and pv1Segment.17.9.2 != "" and pv1Segment.17.9.2 != null and pv1Segment.17.9.3 != "" and pv1Segment.17.9.3 != null -%} + {% evaluate Organization_ID_PV1_17_9 using 'ID/Organization' HDORG: pv1Segment.17.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.17.9, ID: Organization_ID_PV1_17_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_17 using 'ID/Practitioner' XCN: pv1Segment.17 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.17, ID: practitionerId_PV1_17 -%} + {% endif -%} + + {% if pv1Segment.50 -%} + {% for p in pv1Segment.50.Repeats -%} + {% if p.4.1 != "" and p.4.1 != null and p.4.2 != "" and p.4.2 != null and p.4.3 != "" and p.4.3 != null -%} + {% evaluate Organization_ID_PV1_50_4 using 'ID/Organization' HDORG: p.4 -%} + {% include 'Resource/Organization', PV1: p.4, ID: Organization_ID_PV1_50_4 -%} + {% endif -%} + {% endfor -%} + {% endif -%} + + {% if pv1Segment.52 -%} + {% if pv1Segment.52.9.1 != "" and pv1Segment.52.9.1 != null and pv1Segment.52.9.2 != "" and pv1Segment.52.9.2 != null and pv1Segment.52.9.3 != "" and pv1Segment.52.9.3 != null -%} + {% evaluate Organization_ID_PV1_52_9 using 'ID/Organization' HDORG: pv1Segment.52.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.52.9, ID: Organization_ID_PV1_52_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_52 using 'ID/Practitioner' XCN: pv1Segment.52 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.52, ID: practitionerId_PV1_52 -%} + {% endif -%} + + {% if pv2Segment.13 -%} + {% if pv2Segment.13.9.1 != "" and pv2Segment.13.9.1 != null and pv2Segment.13.9.2 != "" and pv2Segment.13.9.2 != null and pv2Segment.13.9.3 != "" and pv2Segment.13.9.3 != null -%} + {% evaluate Organization_ID_PV2_13_9 using 'ID/Organization' HDORG: pv2Segment.13.9 -%} + {% include 'Resource/Organization', PV2: pv2Segment.13.9, ID: Organization_ID_PV2_13_9 -%} + {% endif -%} + {% evaluate practitionerId_PV2_13 using 'ID/Practitioner' XCN: pv2Segment.13 -%} + {% include 'Resource/Practitioner' PV1: pv2Segment.13, ID: practitionerId_PV2_13 -%} + {% endif -%} + + {% if pv1Segment.3 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.3-%} + {% endif -%} + + {% if pv1Segment.6 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.6 -%} + {% endif -%} + + {% if pv1Segment.37 -%} + {% evaluate location_ID_PV1_37 using 'ID/Location' DLD: pv1Segment.37 -%} + {% include 'Resource/Location' PV1: pv1Segment.37, ID: location_ID_PV1_37-%} + {% endif -%} + + {% if pv1Segment.42 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.42-%} + {% endif -%} + + {% if pv1Segment.43 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.43-%} + {% endif -%} + + {% if pv2Segment.1 -%} + {% include 'Resource/PLLocation' PL: pv2Segment.1-%} + {% endif -%} + + {% if pv1Segment.54 -%} + {% if pv1Segment.54.4.1 != "" and pv1Segment.54.4.1 != null and pv1Segment.54.4.2 != "" and pv1Segment.54.4.2 != null and pv1Segment.54.4.3 != "" and pv1Segment.54.4.3 != null -%} + {% evaluate Organization_ID_PV1_54_4 using 'ID/Organization' HDORG: pv1Segment.54.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.54.4, ID: Organization_ID_PV1_54_4 -%} + {% endif -%} + {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: pv1Segment.54 -%} + {% include 'Resource/EpisodeOfCare' PV1: pv1Segment, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId -%} + {% endif -%} + + {% evaluate encounterId using 'ID/Encounter' PV1: pv1Segment, baseId: patientId -%} + {% assign fullEncounterId = encounterId | prepend: 'Encounter/' -%} + {% include 'Resource/Encounter' Root_Template: 'SIU_S17', PV1: pv1Segment, PV2: pv2Segment, ID: encounterId -%} + {% include 'Reference/Encounter/Subject' ID: encounterId, REF: fullPatientId -%} + {% include 'Extensions/Encounter/EncounterExtension' ID: encounterId, PV1: pv1Segment, PV2: pv2Segment -%} + {% endif -%} + + + {% for obxSegment in obxSegmentLists.OBX -%} + + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16 -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16 -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + + {% if obxSegment.18 -%} + {% evaluate deviceId_OBX_18 using 'ID/Device' EI: obxSegment.18.Repeats[0] -%} + {% include 'Resource/Device' EI_OBX18: obxSegment.18, ID: deviceId_OBX_18 -%} + {% endif -%} + + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23 -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + + {% evaluate observationId using 'ID/Observation' OBX: obxSegment, baseId: patientId -%} + + {% include 'Resource/Observation' OBX: obxSegment, Observation_Subject_ID: fullPatientId, ID: observationId -%} + {% include 'Extensions/Observation/ObservationExtension' OBX: obxSegment, ID: observationId %} + + {% endfor -%} + + {% for dg1Segment in dg1SegmentLists.DG1 -%} + + {% if dg1Segment.16.Repeats[0] %} + {% if dg1Segment.16.Repeats[0].9.1 != "" and dg1Segment.16.Repeats[0].9.1 != null and dg1Segment.16.Repeats[0].9.2 != "" and dg1Segment.16.Repeats[0].9.2 != null and dg1Segment.16.Repeats[0].9.3 != "" and dg1Segment.16.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_DG1_16 using 'ID/Organization' HDORG: dg1Segment.16.Repeats[0].9 -%} + {% include 'Resource/Organization', DG1: dg1Segment.16.Repeats[0].9, ID: Organization_ID_DG1_16 -%} + {% endif -%} + {% evaluate practitionerId_DG1_16 using 'ID/Practitioner' XCN: dg1Segment.16.Repeats[0] -%} + {% include 'Resource/Practitioner' DG1: dg1Segment, ID: practitionerId_DG1_16 -%} + {% endif -%} + + {% evaluate conditionId using 'ID/Condition' DG1: dg1Segment, baseId: patientId -%} + {% include 'Resource/Condition' DG1: dg1Segment, Condition_Subject_ID: fullPatientId, baseId: patientId, ID: conditionId -%} + + {% if encounterId -%} + {% include 'Resource/Encounter' DG1: dg1Segment, conditionId: conditionId, ID: encounterId -%} + {% endif %} + + {% if EpisodeOfCare_ID %} + {% include 'Resource/EpisodeOfCare' DG1: dg1Segment, conditionId: conditionId, ID: EpisodeOfCare_ID -%} + {% endif %} + + {% if dg1Segment.22 %} + {% evaluate conditionId_DG1_22 using 'ID/Condition' DG1: dg1Segment.22, baseId: patientId -%} + {% include 'Resource/Condition' DG1_22: dg1Segment.22, Condition_Subject_ID_DG1_22: fullPatientId, ID: conditionId_DG1_22 -%} + {% endif %} + {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} + {% endfor -%} + + {% endfor -%} + + {% for rgsSegment in rgsSegmentLists.RGS -%} + {% evaluate patientId using 'ID/Patient' PID: pidSegmentLists.PID[0], type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% assign aisSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIS' -%} + {% assign ailSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIL' -%} + {% assign aigSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIG' -%} + {% assign aipSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIP' -%} + + {% for aisSegment in aisSegmentLists.AIS -%} + {% assign nteSegmentLists = hl7v2Data | get_related_segment_list: aisSegment, 'NTE' -%} + {% evaluate serviceRequestId using 'ID/ServiceRequest' AIS: aisSegment, baseId: patientId -%} + {% include 'Resource/ServiceRequest' AIS: aisSegment, ID: serviceRequestId, ServiceRequest_Subject_ID: fullPatientId, ServiceRequest_Encounter_ID: fullEncounterId -%} + {% assign fullServiceRequestId = serviceRequestId | prepend: 'ServiceRequest/' -%} + {% include 'Reference/Appointment/BasedOn' ID: appointmentID, REF: fullServiceRequestId -%} + {% for nteSegment in nteSegmentLists.NTE -%} + {% if nteSegment.5 -%} + {% if nteSegment.5.9.1 != "" and nteSegment.5.9.1 != null and nteSegment.5.9.2 != "" and nteSegment.5.9.2 != null and nteSegment.5.9.3 != "" and nteSegment.5.9.3 != null -%} + {% evaluate Organization_ID_EVN_5_9 using 'ID/Organization' HDORG: nteSegment.5.9 -%} + {% include 'Resource/Organization', PV2: nteSegment.5.9, ID: Organization_ID_EVN_5_9 -%} + {% endif -%} + {% evaluate Practitioner_ID_NTE_5 using 'ID/Practitioner' XCN: nteSegment.5 -%} + {% include 'Resource/Practitioner' NTE: nteSegment.5, ID: Practitioner_ID_NTE_5 -%} + {% endif -%} + {% include 'Resource/ServiceRequest' NTE: nteSegment, ID: serviceRequestId -%} + {% endfor -%} + {% endfor -%} + + {% for aigSegment in aigSegmentLists.AIG -%} + {% assign nteSegmentLists = hl7v2Data | get_related_segment_list: aigSegment, 'NTE' -%} + {% evaluate device_Id_AIG_3 using 'ID/Device' AIG: aigSegment -%} + {% include 'Resource/Device' AIG: aigSegment, ID: device_Id_AIG_3 -%} + {% include 'Resource/Appointment' AIG: aigSegment, ID: appointmentID -%} + {% assign fullDevice_Id_AIG_3 = device_Id_AIG_3 | prepend: 'Device/' -%} + {% if aisSegmentLists.AIS -%} + {% include 'Reference/ServiceRequest/Performer' ID: serviceRequestId, REF: fullDevice_Id_AIG_3 -%} + {% endif -%} + {% for nteSegment in nteSegmentLists.NTE -%} + {% include 'Resource/Device' NTE: nteSegment, ID: device_Id_AIG_3 -%} + {% endfor -%} + {% endfor -%} + + {% for ailSegment in ailSegmentLists.AIL -%} + {% assign nteSegmentLists = hl7v2Data | get_related_segment_list: ailSegment, 'NTE' -%} + {% include 'Resource/PLLocation' PL: ailSegment.3, AIL_4: ailSegment.4 -%} + {% for nteSegment in nteSegmentLists.NTE -%} + {% include 'Resource/PLLocation' PL: ailSegment.3, NTE: nteSegment -%} + {% endfor -%} + + {% if ailSegment.3.1 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.1 -%} + {% elseif ailSegment.3.2 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.2 -%} + {% elseif ailSegment.3.3 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.3 -%} + {% elseif ailSegment.3.4 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.4 -%} + {% elseif ailSegment.3.7 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.7 -%} + {% elseif ailSegment.3.8 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.8 -%} + {% endif %} + {% assign fullLocation_ID_AIL_3 = Location_ID_AIL_3 | prepend: 'Location/' -%} + {% if aisSegmentLists.AIS -%} + {% include 'Reference/ServiceRequest/LocationReference' ID: serviceRequestId, REF: fullLocation_ID_AIL_3 -%} + {% endif %} + {% include 'Resource/Appointment' AIL: ailSegment, ID: appointmentID -%} + {% endfor -%} + + {% for aipSegment in aipSegmentLists.AIP -%} + {% if aipSegment.3 -%} + {% if aipSegment.3.9.1 != "" and aipSegment.3.9.1 != null and aipSegment.3.9.2 != "" and aipSegment.3.2 != null and aipSegment.3.9.3 != "" and aipSegment.3.9.3 != null -%} + {% evaluate organization_ID_AIP_3_9 using 'ID/Organization' HDORG: aipSegment.3.9 -%} + {% include 'Resource/Organization', AIP: aipSegment.3.9, ID: organization_ID_AIP_3_9 -%} + {% endif -%} + {% evaluate practitioner_ID_AIP_3 using 'ID/Practitioner' XCN: aipSegment.3 -%} + {% include 'Resource/Practitioner' AIP: aipSegment.3, ID: practitioner_ID_AIP_3 -%} + {% assign fullPractitioner_ID_AIP_3 = practitioner_ID_AIP_3 | prepend: 'Practitioner/' -%} + {% if aisSegmentLists.AIS -%} + {% include 'Reference/ServiceRequest/Performer' ID: serviceRequestId, REF: fullPractitioner_ID_AIP_3 -%} + {% endif -%} + {% endif -%} + {% include 'Resource/Appointment' AIP: aipSegment, ID: appointmentID -%} + {% endfor -%} + {% endfor -%} + ] +} \ No newline at end of file diff --git a/data/Templates/Hl7v2/SIU_S26.liquid b/data/Templates/Hl7v2/SIU_S26.liquid new file mode 100644 index 000000000..2b32446c9 --- /dev/null +++ b/data/Templates/Hl7v2/SIU_S26.liquid @@ -0,0 +1,476 @@ +{% assign firstSegments = hl7v2Data | get_first_segments: 'MSH|SCH' -%} +{% assign tq1SegmentLists = hl7v2Data | get_segment_lists: 'TQ1' -%} +{% assign pidSegmentLists = hl7v2Data | get_segment_lists: 'PID' -%} +{% assign rgsSegmentLists = hl7v2Data | get_segment_lists: 'RGS' -%} +{% evaluate bundleID using 'ID/Bundle' Data: firstSegments.MSH.10 -%} + +{ + "resourceType": "Bundle", + "type": "batch", + {% if firstSegments.MSH.7 -%} + "timestamp":"{{ firstSegments.MSH.7.Value | format_as_date_time }}", + {% endif -%} + "identifier": + { + "value":"{{ firstSegments.MSH.10.Value }}", + }, + "id":"{{ bundleID }}", + "entry": [ + + {% evaluate patientId using 'ID/Patient' PID: pidSegmentLists.PID[0], type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% evaluate messageHeaderId using 'ID/MessageHeader' MSH: firstSegments.MSH -%} + + {% if firstSegments.MSH -%} + + {% include 'Resource/MessageHeader' MSH: firstSegments.MSH, ID: messageHeaderId -%} + {% evaluate provenanceId using 'ID/Provenance' MSH: firstSegments.MSH, baseId: patientId -%} + {% include 'Resource/Provenance' Root_Template: 'SIU_S26', MSH: firstSegments.MSH, REF_BUNDLE: bundleID, ID: provenanceId -%} + + {%- comment -%} + {% assign transformation_val = 'provenance_transformation' %} + {% evaluate provenanceOrganizationId using 'ID/Organization', prov_id: firstSegments.MSH -%} + {% evaluate provenanceTransformationId using 'ID/Provenance_transformation' prov_id: transformation_val -%} + {% include 'Resource/Organization' org_name: 'Microsoft Corporation', ID: provenanceOrganizationId -%} + {% include 'Resource/Provenance_transformation' Root_Template: 'ADT_A01', Provenance_Organization_ID: provenanceOrganizationId, REF_MSH: messageHeaderId, provenanceOrganizationId, ID: provenanceTransformationId -%} + {%- endcomment -%} + + {% if firstSegments.MSH.4 -%} + {% if firstSegments.MSH.4.1 != "" and firstSegments.MSH.4.1 != null or firstSegments.MSH.4.2 != "" and firstSegments.MSH.4.2 != null or firstSegments.MSH.4.3 != "" and firstSegments.MSH.4.3 != null -%} + {% evaluate organization_ID_MSH_4 using 'ID/Organization' HD: firstSegments.MSH.4 -%} + {% include 'Resource/Organization' MSHHD1: firstSegments.MSH.4, MSH: firstSegments.MSH, ID: organization_ID_MSH_4 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.6 %} + {% if firstSegments.MSH.6.1 != "" and firstSegments.MSH.6.1 != null or firstSegments.MSH.6.2 != "" and firstSegments.MSH.6.2 != null or firstSegments.MSH.6.3 != "" and firstSegments.MSH.6.3 != null -%} + {% evaluate organization_Id_MSH_6 using 'ID/Organization' HD: firstSegments.MSH.6 -%} + {% include 'Resource/Organization' MSHHD2: firstSegments.MSH.6, MSH: firstSegments.MSH, ID: organization_Id_MSH_6 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.22 %} + {% if firstSegments.MSH.22.1 != "" and firstSegments.MSH.22.1 != null -%} + {% evaluate organization_Id_MSH_22 using 'ID/Organization' XON: firstSegments.MSH.22 -%} + {% include 'Resource/Organization' MSHXON1: firstSegments.MSH.22, ID: organization_Id_MSH_22 -%} + {% endif -%} + {% endif -%} + + {% if firstSegments.MSH.23 %} + {% if firstSegments.MSH.23.1 != "" and firstSegments.MSH.23.1 != null -%} + {% evaluate organization_Id_MSH_23 using 'ID/Organization' XON: firstSegments.MSH.23 -%} + {% include 'Resource/Organization' MSHXON2: firstSegments.MSH.23, ID: organization_Id_MSH_23 -%} + {% endif -%} + {% endif -%} + {% if firstSegments.MSH.3 and firstSegments.MSH.24 %} + {% evaluate device_Id_MSH_3 using 'ID/Device' HD: firstSegments.MSH.3 -%} + {% include 'Resource/Device' MSH: firstSegments.MSH, ID: device_Id_MSH_3 -%} + {% endif -%} + + {% endif -%} + + {% if firstSegments.SCH -%} + {% assign nteSegmentSchLists = hl7v2Data | get_segment_lists: 'NTE' -%} + {% evaluate appointmentID using 'ID/Appointment' SCH: firstSegments.SCH, baseId: patientId-%} + {% include 'Resource/Appointment' SCH: firstSegments.SCH, ID: appointmentID, pidseg: pidSegmentLists, TQ1:tq1SegmentLists.TQ1[0], NTE: nteSegmentSchLists.NTE[0], type_sch: 26 -%} + {% if firstSegments.SCH.12 -%} + {% if firstSegments.SCH.12.9.1 != "" and firstSegments.SCH.12.9.1 != null and firstSegments.SCH.12.9.2 != "" and firstSegments.SCH.12.9.2 != null and firstSegments.SCH.12.9.3 != "" and firstSegments.SCH.12.9.3 != null -%} + {% evaluate Organization_ID_SCH_12 using 'ID/Organization' HDORG: firstSegments.SCH.12.9 -%} + {% include 'Resource/Organization' OBX: firstSegments.SCH.12.9, ID: Organization_ID_SCH_12 -%} + {% endif -%} + {% evaluate practitionerId_SCH_12 using 'ID/Practitioner' XCN: firstSegments.SCH.12 -%} + {% include 'Resource/Practitioner' SCH_12: firstSegments.SCH, ID: practitionerId_SCH_12 -%} + + {% evaluate practitionerRoleId_SCH_12 using 'ID/PractitionerRole' XCN: firstSegments.SCH.12 -%} + {% include 'Resource/PractitionerRole' SCH_12: firstSegments.SCH, ID: practitionerRoleId_SCH_12, REF_SCH_12: practitionerId_SCH_12 -%} + + {% include 'Resource/PLLocation' PL: firstSegments.SCH.15 -%} + + {% endif -%} + {% if firstSegments.SCH.16 -%} + {% if firstSegments.SCH.16.9.1 != "" and firstSegments.SCH.16.9.1 != null and firstSegments.SCH.16.9.2 != "" and firstSegments.SCH.16.9.2 != null and firstSegments.SCH.16.9.3 != "" and firstSegments.SCH.16.9.3 != null -%} + {% evaluate Organization_ID_SCH_16 using 'ID/Organization' HDORG: firstSegments.SCH.16.9 -%} + {% include 'Resource/Organization' OBX: firstSegments.SCH.16.9, ID: Organization_ID_SCH_16 -%} + {% endif -%} + {% evaluate practitionerId_SCH_16 using 'ID/Practitioner' XCN: firstSegments.SCH.16 -%} + {% include 'Resource/Practitioner' SCH_16: firstSegments.SCH, ID: practitionerId_SCH_16 -%} + + {% evaluate practitionerRoleId_SCH_16 using 'ID/PractitionerRole' XCN: firstSegments.SCH.16 -%} + {% include 'Resource/PractitionerRole' SCH_16: firstSegments.SCH, ID: practitionerRoleId_SCH_16, REF_SCH_16: practitionerId_SCH_16 -%} + + {% include 'Resource/PLLocation' PL: firstSegments.SCH.19 -%} + + {% endif -%} + {% if firstSegments.SCH.20 -%} + {% if firstSegments.SCH.20.9.1 != "" and firstSegments.SCH.20.9.1 != null and firstSegments.SCH.20.9.2 != "" and firstSegments.SCH.20.9.2 != null and firstSegments.SCH.20.9.3 != "" and firstSegments.SCH.20.9.3 != null -%} + {% evaluate Organization_ID_SCH_20 using 'ID/Organization' HDORG: firstSegments.SCH.20.9 -%} + {% include 'Resource/Organization' OBX: firstSegments.SCH.20.9, ID: Organization_ID_SCH_20 -%} + {% endif -%} + {% evaluate practitionerId_SCH_20 using 'ID/Practitioner' XCN: firstSegments.SCH.20 -%} + {% include 'Resource/Practitioner' SCH_20: firstSegments.SCH, ID: practitionerId_SCH_20 -%} + + {% evaluate practitionerRoleId_SCH_20 using 'ID/PractitionerRole' XCN: firstSegments.SCH.20 -%} + {% include 'Resource/PractitionerRole' SCH_20: firstSegments.SCH, ID: practitionerRoleId_SCH_20, REF_SCH_20: practitionerId_SCH_20 -%} + + {% include 'Resource/PLLocation' PL: firstSegments.SCH.22 -%} + + {% endif -%} + {% endif -%} + + {% for pidSegment in pidSegmentLists.PID -%} + {% evaluate patientId using 'ID/Patient' PID: pidSegment, type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + + {% assign pd1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PD1' -%} + {% assign pd1Segment = pd1SegmentLists.PD1[0] %} + {% assign pv1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PV1' -%} + {% assign pv1Segment = pv1SegmentLists.PV1[0] %} + {% assign pv2SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'PV2' -%} + {% assign pv2Segment = pv2SegmentLists.PV2[0] %} + {% assign obxSegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'OBX' -%} + {% assign dg1SegmentLists = hl7v2Data | get_related_segment_list: pidSegment, 'DG1' -%} + + + {% include 'Resource/Patient' PID: pidSegment, PD1: pd1Segment, ID: patientId -%} + {% include 'Extensions/Patient/PatientExtension' ID: PatientId, PID: pidSegment, PD1: pd1Segment, PV1: pv1Segment -%} + + {% if pidSegment.18 -%} + {% evaluate accountId using 'ID/Account' CX: pidSegment.3 -%} + {% include 'Resource/Account' PID: pidSegment, ID: accountId -%} + {% include 'Reference/Account/Subject' ID: accountId, REF: fullPatientId -%} + {% if pidSegment.18.4.1 != "" and pidSegment.18.4.1 != null and pidSegment.18.4.2 != "" and pidSegment.18.4.2 != null and pidSegment.18.4.3 != "" and pidSegment.18.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_18 using 'ID/Organization' HDORG: pidSegment.18.4 -%} + {% include 'Resource/Organization', PID: pidSegment.18, ID: Organization_ID_pid_CX_18 -%} + {% endif -%} + {% endif -%} + + {% if pidSegment.2 -%} + {% if pidSegment.2.4.1 != "" and pidSegment.2.4.1 != null and pidSegment.2.4.2 != "" and pidSegment.2.4.2 != null and pidSegment.2.4.3 != "" and pidSegment.2.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_2 using 'ID/Organization' HDORG: pidSegment.2.4 -%} + {% include 'Resource/Organization', PID: pidSegment.2, ID: Organization_ID_pid_CX_2 -%} + {% endif -%} + {% endif -%} + {% for pid3 in pidSegment.3.Repeats -%} + {% if pid3.4.1 != "" and pid3.4.1 != null and pid3.4.2 != "" and pid3.4.2 != null and pid3.4.3 != "" and pid3.4.3 != null -%} + {% evaluate Organization_ID_pid_CX using 'ID/Organization' HDORG: pid3.4 -%} + {% include 'Resource/Organization', PID: pid3, ID: Organization_ID_pid_CX -%} + {% endif -%} + {% endfor -%} + {% if pidSegment.4 -%} + {% if pidSegment.4.4.1 != "" and pidSegment.4.4.1 != null and pidSegment.4.4.2 != "" and pidSegment.4.4.2 != null and pidSegment.4.4.3 != "" and pidSegment.4.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_4 using 'ID/Organization' HDORG: pidSegment.4.4 -%} + {% include 'Resource/Organization', PID: pidSegment.4, ID: Organization_ID_pid_CX_4 -%} + {% endif -%} + {% endif -%} + + {% unless nk1SegmentLists.NK1 -%} + {% if pidSegment.21 -%} + {% if pidSegment.21.4.1 != "" and pidSegment.21.4.1 != null and pidSegment.21.4.2 != "" and pidSegment.21.4.2 != null and pidSegment.21.4.3 != "" and pidSegment.21.4.3 != null -%} + {% evaluate Organization_ID_pid_CX_21 using 'ID/Organization' HDORG: pidSegment.21.4 -%} + {% include 'Resource/Organization', PID: pidSegment.21, ID: Organization_ID_pid_CX_21 -%} + {% endif -%} + {% evaluate pidrelatedPersonId using 'ID/RelatedPerson' PID: pidSegment, baseId: patientId -%} + {% include 'Resource/RelatedPerson' RelatedPerson_Patient_ID: fullPatientId, ID: pidrelatedPersonId, PID: pidSegment -%} + {% endif -%} + {% endunless -%} + + {% if pd1Segment.3 -%} + {% evaluate Organization_ID_PD1_3 using 'ID/Organization' XON: pd1Segment.3 -%} + {% include 'Resource/Organization' PD1: pd1Segment, ID: Organization_ID_PD1_3 -%} + {% endif -%} + + {% if pd1Segment.4 -%} + {% if pd1Segment.4.9.1 != "" and pd1Segment.4.9.1 != null and pd1Segment.4.9.2 != "" and pd1Segment.4.9.2 != null and pd1Segment.4.9.3 != "" and pd1Segment.4.9.3 != null -%} + {% evaluate Organization_ID_PD1_4_9 using 'ID/Organization' HDORG: pd1Segment.4.9 -%} + {% include 'Resource/Organization', PD1_4: pd1Segment.4.9, ID: Organization_ID_PD1_4_9 -%} + {% endif -%} + {% evaluate Practitioner_ID_PD1_4 using 'ID/Practitioner' XCN: pd1Segment.4 -%} + {% include 'Resource/Practitioner' PD1: pd1Segment.4, ID: Practitioner_ID_PD1_4 -%} + {% endif -%} + + + {% if pv1Segment -%} + {% if pv1Segment.5 -%} + {% if pv1Segment.5.4.1 != "" and pv1Segment.5.4.1 != null and pv1Segment.5.4.2 != "" and pv1Segment.5.4.2 != null and pv1Segment.5.4.3 != "" and pv1Segment.5.4.3 != null -%} + {% evaluate Organization_ID_PV1_5_4 using 'ID/Organization' HDORG: pv1Segment.5.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.5.4, ID: Organization_ID_PV1_5_4 -%} + {% endif -%} + {% endif -%} + + {% if pv1Segment.19 -%} + {% if pv1Segment.19.4.1 != "" and pv1Segment.19.4.1 != null and pv1Segment.19.4.2 != "" and pv1Segment.19.4.2 != null and pv1Segment.19.4.3 != "" and pv1Segment.19.4.3 != null -%} + {% evaluate Organization_ID_PV1_19_4 using 'ID/Organization' HDORG: pv1Segment.19.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.19.4, ID: Organization_ID_PV1_19_4 -%} + {% endif -%} + {% endif -%} + + {% if pv1Segment.7 -%} + {% if pv1Segment.7.9.1 != "" and pv1Segment.7.9.1 != null and pv1Segment.7.9.2 != "" and pv1Segment.7.9.2 != null and pv1Segment.7.9.3 != "" and pv1Segment.7.9.3 != null -%} + {% evaluate Organization_ID_PV1_7_9 using 'ID/Organization' HDORG: pv1Segment.7.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.7.9, ID: Organization_ID_PV1_7_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_7 using 'ID/Practitioner' XCN: pv1Segment.7 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.7, ID: practitionerId_PV1_7 -%} + {% endif -%} + + {% if pv1Segment.8 -%} + {% if pv1Segment.8.9.1 != "" and pv1Segment.8.9.1 != null and pv1Segment.8.9.2 != "" and pv1Segment.8.9.2 != null and pv1Segment.8.9.3 != "" and pv1Segment.8.9.3 != null -%} + {% evaluate Organization_ID_PV1_8_9 using 'ID/Organization' HDORG: pv1Segment.8.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.8.9, ID: Organization_ID_PV1_8_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_8 using 'ID/Practitioner' XCN: pv1Segment.8 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.8, ID: practitionerId_PV1_8 -%} + {% endif -%} + + {% if pv1Segment.9 -%} + {% if pv1Segment.9.9.1 != "" and pv1Segment.9.9.1 != null and pv1Segment.9.9.2 != "" and pv1Segment.9.9.2 != null and pv1Segment.9.9.3 != "" and pv1Segment.9.9.3 != null -%} + {% evaluate Organization_ID_PV1_9_9 using 'ID/Organization' HDORG: pv1Segment.9.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.9.9, ID: Organization_ID_PV1_9_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_9 using 'ID/Practitioner' XCN: pv1Segment.9 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.9, ID: practitionerId_PV1_9 -%} + {% endif -%} + + {% if pv1Segment.17 -%} + {% if pv1Segment.17.9.1 != "" and pv1Segment.17.9.1 != null and pv1Segment.17.9.2 != "" and pv1Segment.17.9.2 != null and pv1Segment.17.9.3 != "" and pv1Segment.17.9.3 != null -%} + {% evaluate Organization_ID_PV1_17_9 using 'ID/Organization' HDORG: pv1Segment.17.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.17.9, ID: Organization_ID_PV1_17_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_17 using 'ID/Practitioner' XCN: pv1Segment.17 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.17, ID: practitionerId_PV1_17 -%} + {% endif -%} + + {% if pv1Segment.50 -%} + {% for p in pv1Segment.50.Repeats -%} + {% if p.4.1 != "" and p.4.1 != null and p.4.2 != "" and p.4.2 != null and p.4.3 != "" and p.4.3 != null -%} + {% evaluate Organization_ID_PV1_50_4 using 'ID/Organization' HDORG: p.4 -%} + {% include 'Resource/Organization', PV1: p.4, ID: Organization_ID_PV1_50_4 -%} + {% endif -%} + {% endfor -%} + {% endif -%} + + {% if pv1Segment.52 -%} + {% if pv1Segment.52.9.1 != "" and pv1Segment.52.9.1 != null and pv1Segment.52.9.2 != "" and pv1Segment.52.9.2 != null and pv1Segment.52.9.3 != "" and pv1Segment.52.9.3 != null -%} + {% evaluate Organization_ID_PV1_52_9 using 'ID/Organization' HDORG: pv1Segment.52.9 -%} + {% include 'Resource/Organization', PV1: pv1Segment.52.9, ID: Organization_ID_PV1_52_9 -%} + {% endif -%} + {% evaluate practitionerId_PV1_52 using 'ID/Practitioner' XCN: pv1Segment.52 -%} + {% include 'Resource/Practitioner' PV1: pv1Segment.52, ID: practitionerId_PV1_52 -%} + {% endif -%} + + {% if pv2Segment.13 -%} + {% if pv2Segment.13.9.1 != "" and pv2Segment.13.9.1 != null and pv2Segment.13.9.2 != "" and pv2Segment.13.9.2 != null and pv2Segment.13.9.3 != "" and pv2Segment.13.9.3 != null -%} + {% evaluate Organization_ID_PV2_13_9 using 'ID/Organization' HDORG: pv2Segment.13.9 -%} + {% include 'Resource/Organization', PV2: pv2Segment.13.9, ID: Organization_ID_PV2_13_9 -%} + {% endif -%} + {% evaluate practitionerId_PV2_13 using 'ID/Practitioner' XCN: pv2Segment.13 -%} + {% include 'Resource/Practitioner' PV1: pv2Segment.13, ID: practitionerId_PV2_13 -%} + {% endif -%} + + {% if pv1Segment.3 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.3-%} + {% endif -%} + + {% if pv1Segment.6 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.6 -%} + {% endif -%} + + {% if pv1Segment.37 -%} + {% evaluate location_ID_PV1_37 using 'ID/Location' DLD: pv1Segment.37 -%} + {% include 'Resource/Location' PV1: pv1Segment.37, ID: location_ID_PV1_37-%} + {% endif -%} + + {% if pv1Segment.42 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.42-%} + {% endif -%} + + {% if pv1Segment.43 -%} + {% include 'Resource/PLLocation' PL: pv1Segment.43-%} + {% endif -%} + + {% if pv2Segment.1 -%} + {% include 'Resource/PLLocation' PL: pv2Segment.1-%} + {% endif -%} + + {% if pv1Segment.54 -%} + {% if pv1Segment.54.4.1 != "" and pv1Segment.54.4.1 != null and pv1Segment.54.4.2 != "" and pv1Segment.54.4.2 != null and pv1Segment.54.4.3 != "" and pv1Segment.54.4.3 != null -%} + {% evaluate Organization_ID_PV1_54_4 using 'ID/Organization' HDORG: pv1Segment.54.4 -%} + {% include 'Resource/Organization', PV1: pv1Segment.54.4, ID: Organization_ID_PV1_54_4 -%} + {% endif -%} + {% evaluate EpisodeOfCare_ID using 'ID/EpisodeOfCare' PV1: pv1Segment.54 -%} + {% include 'Resource/EpisodeOfCare' PV1: pv1Segment, ID: EpisodeOfCare_ID, patientRefrenceID: fullPatientId -%} + {% endif -%} + + {% evaluate encounterId using 'ID/Encounter' PV1: pv1Segment, baseId: patientId -%} + {% assign fullEncounterId = encounterId | prepend: 'Encounter/' -%} + {% include 'Resource/Encounter' Root_Template: 'SIU_S26', PV1: pv1Segment, PV2: pv2Segment, ID: encounterId -%} + {% include 'Reference/Encounter/Subject' ID: encounterId, REF: fullPatientId -%} + {% include 'Extensions/Encounter/EncounterExtension' ID: encounterId, PV1: pv1Segment, PV2: pv2Segment -%} + {% endif -%} + + + {% for obxSegment in obxSegmentLists.OBX -%} + + {% for obx_16 in obxSegment.16.Repeats -%} + {% if obx_16.9.1 != "" and obx_16.9.1 != null and obx_16.9.2 != "" and obx_16.9.2 != null and obx_16.9.3 != "" and obx_16.9.3 != null -%} + {% evaluate Organization_ID_OBX_16 using 'ID/Organization' HDORG: obx_16.9 -%} + {% include 'Resource/Organization' OBX: obx_16.9, ID: Organization_ID_OBX_16 -%} + {% endif -%} + {% evaluate practitionerId_OBX_16 using 'ID/Practitioner' XCN: obx_16 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN1: obx_16, ID: practitionerId_OBX_16 -%} + {% evaluate practitionerRoleId_OBX_16 using 'ID/PractitionerRole' XCN: obx_16 -%} + {% assign full_practitionerId_OBX_16 = practitionerId_OBX_16 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN1: obx_16, ID: practitionerRoleId_OBX_16 -%} + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_16, ID: practitionerRoleId_OBX_16 -%} + {% endfor %} + + {% if obxSegment.18 -%} + {% evaluate deviceId_OBX_18 using 'ID/Device' EI: obxSegment.18.Repeats[0] -%} + {% include 'Resource/Device' EI_OBX18: obxSegment.18, ID: deviceId_OBX_18 -%} + {% endif -%} + + {% if obxSegment.23 or obxSegment.25 %} + {% evaluate practitionerRoleId_OBX_25 using 'ID/PractitionerRole' XCN: obxSegment.25 -%} + {% endif %} + + {% if obxSegment.25 -%} + {% evaluate practitionerId_OBX_25 using 'ID/Practitioner' XCN: obxSegment.25 -%} + {% include 'Resource/Practitioner' OBX: obxSegment, OBXXCN2: obxSegment.25, ID: practitionerId_OBX_25 -%} + {% assign full_practitionerId_OBX_25 = practitionerId_OBX_25 | prepend: 'Practitioner/' %} + {% include 'Resource/PractitionerRole' OBXXCN2: obxSegment.25, ID: practitionerRoleId_OBX_25 -%} + + {% include 'Reference/PractitionerRole/Practitioner' REF: full_practitionerId_OBX_25, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% if obxSegment.23 -%} + {% evaluate organizationId_OBX_23 using 'ID/Organization' XON: obxSegment.23 -%} + {% include 'Resource/Organization' OBX_23: obxSegment.23, OBX_24: obxSegment.24, ID: organizationId_OBX_23 -%} + {% if obxSegment.25 -%} + {% assign full_organizationId_OBX_23 = organizationId_OBX_23 | prepend: 'Organization/' %} + {% include 'Reference/PractitionerRole/Organization' REF: full_organizationId_OBX_23, ID: practitionerRoleId_OBX_25 -%} + {% endif -%} + {% endif -%} + + {% evaluate observationId using 'ID/Observation' OBX: obxSegment, baseId: patientId -%} + + {% include 'Resource/Observation' OBX: obxSegment, Observation_Subject_ID: fullPatientId, ID: observationId -%} + {% include 'Extensions/Observation/ObservationExtension' OBX: obxSegment, ID: observationId %} + + {% endfor -%} + + {% for dg1Segment in dg1SegmentLists.DG1 -%} + + {% if dg1Segment.16.Repeats[0] %} + {% if dg1Segment.16.Repeats[0].9.1 != "" and dg1Segment.16.Repeats[0].9.1 != null and dg1Segment.16.Repeats[0].9.2 != "" and dg1Segment.16.Repeats[0].9.2 != null and dg1Segment.16.Repeats[0].9.3 != "" and dg1Segment.16.Repeats[0].9.3 != null -%} + {% evaluate Organization_ID_DG1_16 using 'ID/Organization' HDORG: dg1Segment.16.Repeats[0].9 -%} + {% include 'Resource/Organization', DG1: dg1Segment.16.Repeats[0].9, ID: Organization_ID_DG1_16 -%} + {% endif -%} + {% evaluate practitionerId_DG1_16 using 'ID/Practitioner' XCN: dg1Segment.16.Repeats[0] -%} + {% include 'Resource/Practitioner' DG1: dg1Segment, ID: practitionerId_DG1_16 -%} + {% endif -%} + + {% evaluate conditionId using 'ID/Condition' DG1: dg1Segment, baseId: patientId -%} + {% include 'Resource/Condition' DG1: dg1Segment, Condition_Subject_ID: fullPatientId, baseId: patientId, ID: conditionId -%} + + {% if encounterId -%} + {% include 'Resource/Encounter' DG1: dg1Segment, conditionId: conditionId, ID: encounterId -%} + {% endif %} + + {% if EpisodeOfCare_ID %} + {% include 'Resource/EpisodeOfCare' DG1: dg1Segment, conditionId: conditionId, ID: EpisodeOfCare_ID -%} + {% endif %} + + {% if dg1Segment.22 %} + {% evaluate conditionId_DG1_22 using 'ID/Condition' DG1: dg1Segment.22, baseId: patientId -%} + {% include 'Resource/Condition' DG1_22: dg1Segment.22, Condition_Subject_ID_DG1_22: fullPatientId, ID: conditionId_DG1_22 -%} + {% endif %} + {% include 'Extensions/Condition/ConditionExtension' DG1: dg1Segment, ID_DG1_22:conditionId_DG1_22, ID: conditionId %} + {% endfor -%} + + {% endfor -%} + + {% for rgsSegment in rgsSegmentLists.RGS -%} + {% evaluate patientId using 'ID/Patient' PID: pidSegmentLists.PID[0], type: 'First' -%} + {% assign fullPatientId = patientId | prepend: 'Patient/' -%} + {% assign aisSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIS' -%} + {% assign ailSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIL' -%} + {% assign aigSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIG' -%} + {% assign aipSegmentLists = hl7v2Data | get_related_segment_list: rgsSegment, 'AIP' -%} + + {% for aisSegment in aisSegmentLists.AIS -%} + {% assign nteSegmentLists = hl7v2Data | get_related_segment_list: aisSegment, 'NTE' -%} + {% evaluate serviceRequestId using 'ID/ServiceRequest' AIS: aisSegment, baseId: patientId -%} + {% include 'Resource/ServiceRequest' AIS: aisSegment, ID: serviceRequestId, ServiceRequest_Subject_ID: fullPatientId, ServiceRequest_Encounter_ID: fullEncounterId -%} + {% assign fullServiceRequestId = serviceRequestId | prepend: 'ServiceRequest/' -%} + {% include 'Reference/Appointment/BasedOn' ID: appointmentID, REF: fullServiceRequestId -%} + {% for nteSegment in nteSegmentLists.NTE -%} + {% if nteSegment.5 -%} + {% if nteSegment.5.9.1 != "" and nteSegment.5.9.1 != null and nteSegment.5.9.2 != "" and nteSegment.5.9.2 != null and nteSegment.5.9.3 != "" and nteSegment.5.9.3 != null -%} + {% evaluate Organization_ID_EVN_5_9 using 'ID/Organization' HDORG: nteSegment.5.9 -%} + {% include 'Resource/Organization', PV2: nteSegment.5.9, ID: Organization_ID_EVN_5_9 -%} + {% endif -%} + {% evaluate Practitioner_ID_NTE_5 using 'ID/Practitioner' XCN: nteSegment.5 -%} + {% include 'Resource/Practitioner' NTE: nteSegment.5, ID: Practitioner_ID_NTE_5 -%} + {% endif -%} + {% include 'Resource/ServiceRequest' NTE: nteSegment, ID: serviceRequestId -%} + {% endfor -%} + {% endfor -%} + + {% for aigSegment in aigSegmentLists.AIG -%} + {% assign nteSegmentLists = hl7v2Data | get_related_segment_list: aigSegment, 'NTE' -%} + {% evaluate device_Id_AIG_3 using 'ID/Device' AIG: aigSegment -%} + {% include 'Resource/Device' AIG: aigSegment, ID: device_Id_AIG_3 -%} + {% include 'Resource/Appointment' AIG: aigSegment, ID: appointmentID -%} + {% assign fullDevice_Id_AIG_3 = device_Id_AIG_3 | prepend: 'Device/' -%} + {% if aisSegmentLists.AIS -%} + {% include 'Reference/ServiceRequest/Performer' ID: serviceRequestId, REF: fullDevice_Id_AIG_3 -%} + {% endif -%} + {% for nteSegment in nteSegmentLists.NTE -%} + {% include 'Resource/Device' NTE: nteSegment, ID: device_Id_AIG_3 -%} + {% endfor -%} + {% endfor -%} + + {% for ailSegment in ailSegmentLists.AIL -%} + {% assign nteSegmentLists = hl7v2Data | get_related_segment_list: ailSegment, 'NTE' -%} + {% include 'Resource/PLLocation' PL: ailSegment.3, AIL_4: ailSegment.4 -%} + {% for nteSegment in nteSegmentLists.NTE -%} + {% include 'Resource/PLLocation' PL: ailSegment.3, NTE: nteSegment -%} + {% endfor -%} + + {% if ailSegment.3.1 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.1 -%} + {% elseif ailSegment.3.2 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.2 -%} + {% elseif ailSegment.3.3 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.3 -%} + {% elseif ailSegment.3.4 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.4 -%} + {% elseif ailSegment.3.7 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.7 -%} + {% elseif ailSegment.3.8 -%} + {% evaluate Location_ID_AIL_3 using 'ID/Location' PL: ailSegment.3.8 -%} + {% endif %} + {% assign fullLocation_ID_AIL_3 = Location_ID_AIL_3 | prepend: 'Location/' -%} + {% if aisSegmentLists.AIS -%} + {% include 'Reference/ServiceRequest/LocationReference' ID: serviceRequestId, REF: fullLocation_ID_AIL_3 -%} + {% endif %} + {% include 'Resource/Appointment' AIL: ailSegment, ID: appointmentID -%} + {% endfor -%} + + {% for aipSegment in aipSegmentLists.AIP -%} + {% if aipSegment.3 -%} + {% if aipSegment.3.9.1 != "" and aipSegment.3.9.1 != null and aipSegment.3.9.2 != "" and aipSegment.3.2 != null and aipSegment.3.9.3 != "" and aipSegment.3.9.3 != null -%} + {% evaluate organization_ID_AIP_3_9 using 'ID/Organization' HDORG: aipSegment.3.9 -%} + {% include 'Resource/Organization', AIP: aipSegment.3.9, ID: organization_ID_AIP_3_9 -%} + {% endif -%} + {% evaluate practitioner_ID_AIP_3 using 'ID/Practitioner' XCN: aipSegment.3 -%} + {% include 'Resource/Practitioner' AIP: aipSegment.3, ID: practitioner_ID_AIP_3 -%} + {% assign fullPractitioner_ID_AIP_3 = practitioner_ID_AIP_3 | prepend: 'Practitioner/' -%} + {% if aisSegmentLists.AIS -%} + {% include 'Reference/ServiceRequest/Performer' ID: serviceRequestId, REF: fullPractitioner_ID_AIP_3 -%} + {% endif -%} + {% endif -%} + {% include 'Resource/Appointment' AIP: aipSegment, ID: appointmentID -%} + {% endfor -%} + {% endfor -%} + ] +} \ No newline at end of file diff --git a/release.yml b/release.yml index f8dcf5de6..623aba57c 100644 --- a/release.yml +++ b/release.yml @@ -8,7 +8,7 @@ trigger: pr: - dotliquid - main -- xoriant/* +- templates/* variables: solution: '**/*.sln' @@ -17,7 +17,7 @@ variables: functionalTests: "**/*FunctionalTests/*.csproj" buildConfiguration: 'Release' major: 4 - minor: 3 + minor: 4 patch: 0 buildnum: $[counter(format('{0}.{1}.{2}',variables['major'],variables['minor'], variables['patch']), 1)] version: $(major).$(minor).$(patch).$(buildnum) diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/FunctionalTests.cs b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/FunctionalTests.cs index 5f8434b38..449c51fa2 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/FunctionalTests.cs +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/FunctionalTests.cs @@ -24,32 +24,74 @@ public static IEnumerable GetDataForHl7v2() { var data = new List { - new[] { @"ADT_A01", @"ADT_A01.hl7", @"ADT-A01-expected.json" }, - new[] { @"ADT_A01", @"ADT_A01-2.hl7", @"ADT-A01-expected-2.json" }, - new[] { @"ADT_A02", @"ADT_A02.hl7", @"ADT-A02-expected.json" }, - new[] { @"ADT_A02", @"ADT_A02-2.hl7", @"ADT-A02-expected-2.json" }, - new[] { @"ADT_A03", @"ADT_A03.hl7", @"ADT-A03-expected.json" }, - new[] { @"ADT_A03", @"ADT_A03-2.hl7", @"ADT-A03-expected-2.json" }, - new[] { @"ADT_A04", @"ADT_A04.hl7", @"ADT-A04-expected.json" }, - new[] { @"ADT_A04", @"ADT_A04-2.hl7", @"ADT-A04-expected-2.json" }, - new[] { @"ADT_A05", @"ADT_A05.hl7", @"ADT-A05-expected.json" }, - new[] { @"ADT_A05", @"ADT_A05-2.hl7", @"ADT-A05-expected-2.json" }, - new[] { @"ADT_A08", @"ADT_A08.hl7", @"ADT-A08-expected.json" }, - new[] { @"ADT_A08", @"ADT_A08-2.hl7", @"ADT-A08-expected-2.json" }, - new[] { @"ADT_A14", @"ADT_A14.hl7", @"ADT-A14-expected.json" }, - new[] { @"ADT_A14", @"ADT_A14-2.hl7", @"ADT-A14-expected-2.json" }, - new[] { @"ADT_A15", @"ADT_A15.hl7", @"ADT-A15-expected.json" }, - new[] { @"ADT_A15", @"ADT_A15-2.hl7", @"ADT-A15-expected-2.json" }, - new[] { @"ADT_A16", @"ADT_A16.hl7", @"ADT-A16-expected.json" }, - new[] { @"ADT_A16", @"ADT_A16-2.hl7", @"ADT-A16-expected-2.json" }, - new[] { @"ADT_A28", @"ADT_A28.hl7", @"ADT-A28-expected.json" }, - new[] { @"ADT_A28", @"ADT_A28-2.hl7", @"ADT-A28-expected-2.json" }, - new[] { @"ADT_A31", @"ADT_A31.hl7", @"ADT-A31-expected.json" }, - new[] { @"ADT_A31", @"ADT_A31-2.hl7", @"ADT-A31-expected-2.json" }, - new[] { @"ADT_A47", @"ADT_A47.hl7", @"ADT-A47-expected.json" }, - new[] { @"ADT_A47", @"ADT_A47-2.hl7", @"ADT-A47-expected-2.json" }, - new[] { @"ADT_A60", @"ADT_A60.hl7", @"ADT-A60-expected.json" }, - new[] { @"ADT_A60", @"ADT_A60-2.hl7", @"ADT-A60-expected-2.json" }, + new[] { @"ADT_A01", @"ADT-A01-01.hl7", @"ADT-A01-01-expected.json" }, + new[] { @"ADT_A01", @"ADT-A01-02.hl7", @"ADT-A01-02-expected.json" }, + new[] { @"ADT_A02", @"ADT-A02-01.hl7", @"ADT-A02-01-expected.json" }, + new[] { @"ADT_A02", @"ADT-A02-02.hl7", @"ADT-A02-02-expected.json" }, + new[] { @"ADT_A03", @"ADT-A03-01.hl7", @"ADT-A03-01-expected.json" }, + new[] { @"ADT_A03", @"ADT-A03-02.hl7", @"ADT-A03-02-expected.json" }, + new[] { @"ADT_A04", @"ADT-A04-01.hl7", @"ADT-A04-01-expected.json" }, + new[] { @"ADT_A04", @"ADT-A04-02.hl7", @"ADT-A04-02-expected.json" }, + new[] { @"ADT_A05", @"ADT-A05-01.hl7", @"ADT-A05-01-expected.json" }, + new[] { @"ADT_A05", @"ADT-A05-02.hl7", @"ADT-A05-02-expected.json" }, + new[] { @"ADT_A08", @"ADT-A08-01.hl7", @"ADT-A08-01-expected.json" }, + new[] { @"ADT_A08", @"ADT-A08-02.hl7", @"ADT-A08-02-expected.json" }, + new[] { @"ADT_A11", @"ADT-A11-01.hl7", @"ADT-A11-01-expected.json" }, + new[] { @"ADT_A11", @"ADT-A11-02.hl7", @"ADT-A11-02-expected.json" }, + new[] { @"ADT_A13", @"ADT-A13-01.hl7", @"ADT-A13-01-expected.json" }, + new[] { @"ADT_A13", @"ADT-A13-02.hl7", @"ADT-A13-02-expected.json" }, + new[] { @"ADT_A14", @"ADT-A14-01.hl7", @"ADT-A14-01-expected.json" }, + new[] { @"ADT_A14", @"ADT-A14-02.hl7", @"ADT-A14-02-expected.json" }, + new[] { @"ADT_A15", @"ADT-A15-01.hl7", @"ADT-A15-01-expected.json" }, + new[] { @"ADT_A15", @"ADT-A15-02.hl7", @"ADT-A15-02-expected.json" }, + new[] { @"ADT_A16", @"ADT-A16-01.hl7", @"ADT-A16-01-expected.json" }, + new[] { @"ADT_A16", @"ADT-A16-02.hl7", @"ADT-A16-02-expected.json" }, + new[] { @"ADT_A25", @"ADT-A25-01.hl7", @"ADT-A25-01-expected.json" }, + new[] { @"ADT_A25", @"ADT-A25-02.hl7", @"ADT-A25-02-expected.json" }, + new[] { @"ADT_A26", @"ADT-A26-01.hl7", @"ADT-A26-01-expected.json" }, + new[] { @"ADT_A26", @"ADT-A26-02.hl7", @"ADT-A26-02-expected.json" }, + new[] { @"ADT_A27", @"ADT-A27-01.hl7", @"ADT-A27-01-expected.json" }, + new[] { @"ADT_A27", @"ADT-A27-02.hl7", @"ADT-A27-02-expected.json" }, + new[] { @"ADT_A28", @"ADT-A28-01.hl7", @"ADT-A28-01-expected.json" }, + new[] { @"ADT_A28", @"ADT-A28-02.hl7", @"ADT-A28-02-expected.json" }, + new[] { @"ADT_A29", @"ADT-A29-01.hl7", @"ADT-A29-01-expected.json" }, + new[] { @"ADT_A29", @"ADT-A29-02.hl7", @"ADT-A29-02-expected.json" }, + new[] { @"ADT_A31", @"ADT-A31-01.hl7", @"ADT-A31-01-expected.json" }, + new[] { @"ADT_A31", @"ADT-A31-02.hl7", @"ADT-A31-02-expected.json" }, + new[] { @"ADT_A47", @"ADT-A47-01.hl7", @"ADT-A47-01-expected.json" }, + new[] { @"ADT_A47", @"ADT-A47-02.hl7", @"ADT-A47-02-expected.json" }, + new[] { @"ADT_A60", @"ADT-A60-01.hl7", @"ADT-A60-01-expected.json" }, + new[] { @"ADT_A60", @"ADT-A60-02.hl7", @"ADT-A60-02-expected.json" }, + + new[] { @"SIU_S12", @"SIU-S12-01.hl7", @"SIU-S12-01-expected.json" }, + new[] { @"SIU_S12", @"SIU-S12-02.hl7", @"SIU-S12-02-expected.json" }, + new[] { @"SIU_S13", @"SIU-S13-01.hl7", @"SIU-S13-01-expected.json" }, + new[] { @"SIU_S13", @"SIU-S13-02.hl7", @"SIU-S13-02-expected.json" }, + new[] { @"SIU_S14", @"SIU-S14-01.hl7", @"SIU-S14-01-expected.json" }, + new[] { @"SIU_S14", @"SIU-S14-02.hl7", @"SIU-S14-02-expected.json" }, + new[] { @"SIU_S15", @"SIU-S15-01.hl7", @"SIU-S15-01-expected.json" }, + new[] { @"SIU_S15", @"SIU-S15-02.hl7", @"SIU-S15-02-expected.json" }, + new[] { @"SIU_S16", @"SIU-S16-01.hl7", @"SIU-S16-01-expected.json" }, + new[] { @"SIU_S16", @"SIU-S16-02.hl7", @"SIU-S16-02-expected.json" }, + new[] { @"SIU_S17", @"SIU-S17-01.hl7", @"SIU-S17-01-expected.json" }, + new[] { @"SIU_S17", @"SIU-S17-02.hl7", @"SIU-S17-02-expected.json" }, + new[] { @"SIU_S26", @"SIU-S26-01.hl7", @"SIU-S26-01-expected.json" }, + new[] { @"SIU_S26", @"SIU-S26-02.hl7", @"SIU-S26-02-expected.json" }, + + new[] { "ORU_R01", "ORU-R01-01.hl7", @"ORU-R01-01-expected.json"}, + + new[] { @"ORM_O01", @"ORM-O01-01.hl7", @"ORM-O01-01-expected.json" }, + new[] { @"ORM_O01", @"ORM-O01-02.hl7", @"ORM-O01-02-expected.json" }, + new[] { @"ORM_O01", @"ORM-O01-03.hl7", @"ORM-O01-03-expected.json" }, + + new[] { "MDM_T01", "MDM-T01-01.hl7", @"MDM-T01-01-expected.json"}, + new[] { "MDM_T01", "MDM-T01-02.hl7", @"MDM-T01-02-expected.json"}, + new[] { "MDM_T02", "MDM-T02-01.hl7", @"MDM-T02-01-expected.json"}, + new[] { "MDM_T02", "MDM-T02-02.hl7", @"MDM-T02-02-expected.json"}, + new[] { "MDM_T02", "MDM-T02-03.hl7", @"MDM-T02-03-expected.json"}, + + new[] { "OML_O21", "OML-O21-01.hl7", @"OML-O21-01-expected.json"}, + new[] { "OML_O21", "OML-O21-02.hl7", @"OML-O21-02-expected.json"}, new[] { @"ADT_A01", @"ADT01-23.hl7", @"ADT01-23-expected.json" }, new[] { @"ADT_A01", @"ADT01-28.hl7", @"ADT01-28-expected.json" }, diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/RuleBasedTests.cs b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/RuleBasedTests.cs index 5249537a9..552c9ce4d 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/RuleBasedTests.cs +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/RuleBasedTests.cs @@ -47,32 +47,71 @@ public static IEnumerable GetHL7V2Cases() { var cases = new List { - new object[] { "ADT_A01", "ADT_A01.hl7" }, - new object[] { "ADT_A01", "ADT_A01-2.hl7" }, - new object[] { "ADT_A02", "ADT_A02.hl7" }, - new object[] { "ADT_A02", "ADT_A02-2.hl7" }, - new object[] { "ADT_A03", "ADT_A03.hl7" }, - new object[] { "ADT_A03", "ADT_A03-2.hl7" }, - new object[] { "ADT_A04", "ADT_A04.hl7" }, - new object[] { "ADT_A04", "ADT_A04-2.hl7" }, - new object[] { "ADT_A05", "ADT_A05.hl7" }, - new object[] { "ADT_A05", "ADT_A05-2.hl7" }, - new object[] { "ADT_A08", "ADT_A08.hl7" }, - new object[] { "ADT_A08", "ADT_A08-2.hl7" }, - new object[] { "ADT_A14", "ADT_A14.hl7" }, - new object[] { "ADT_A14", "ADT_A14-2.hl7" }, - new object[] { "ADT_A15", "ADT_A15.hl7" }, - new object[] { "ADT_A15", "ADT_A15-2.hl7" }, - new object[] { "ADT_A16", "ADT_A16.hl7" }, - new object[] { "ADT_A16", "ADT_A16-2.hl7" }, - new object[] { "ADT_A28", "ADT_A28.hl7" }, - new object[] { "ADT_A28", "ADT_A28-2.hl7" }, - new object[] { "ADT_A31", "ADT_A31.hl7" }, - new object[] { "ADT_A31", "ADT_A31-2.hl7" }, - new object[] { "ADT_A47", "ADT_A47.hl7" }, - new object[] { "ADT_A47", "ADT_A47-2.hl7" }, - new object[] { "ADT_A60", "ADT_A60.hl7" }, - new object[] { "ADT_A60", "ADT_A60-2.hl7" }, + new object[] { "ADT_A01", "ADT-A01-01.hl7" }, + new object[] { "ADT_A01", "ADT-A01-02.hl7" }, + new object[] { "ADT_A02", "ADT-A02-01.hl7" }, + new object[] { "ADT_A02", "ADT-A02-02.hl7" }, + new object[] { "ADT_A03", "ADT-A03-01.hl7" }, + new object[] { "ADT_A03", "ADT-A03-02.hl7" }, + new object[] { "ADT_A04", "ADT-A04-01.hl7" }, + new object[] { "ADT_A04", "ADT-A04-02.hl7" }, + new object[] { "ADT_A05", "ADT-A05-01.hl7" }, + new object[] { "ADT_A05", "ADT-A05-02.hl7" }, + new object[] { "ADT_A08", "ADT-A08-01.hl7" }, + new object[] { "ADT_A08", "ADT-A08-02.hl7" }, + new object[] { "ADT_A11", "ADT-A11-01.hl7" }, + new object[] { "ADT_A11", "ADT-A11-02.hl7" }, + new object[] { "ADT_A13", "ADT-A13-01.hl7" }, + new object[] { "ADT_A13", "ADT-A13-02.hl7" }, + new object[] { "ADT_A14", "ADT-A14-01.hl7" }, + new object[] { "ADT_A14", "ADT-A14-02.hl7" }, + new object[] { "ADT_A15", "ADT-A15-01.hl7" }, + new object[] { "ADT_A15", "ADT-A15-02.hl7" }, + new object[] { "ADT_A16", "ADT-A16-01.hl7" }, + new object[] { "ADT_A16", "ADT-A16-02.hl7" }, + new object[] { "ADT_A25", "ADT-A25-01.hl7" }, + new object[] { "ADT_A25", "ADT-A25-02.hl7" }, + new object[] { "ADT_A26", "ADT-A26-01.hl7" }, + new object[] { "ADT_A26", "ADT-A26-02.hl7" }, + new object[] { "ADT_A27", "ADT-A27-01.hl7" }, + new object[] { "ADT_A27", "ADT-A27-02.hl7" }, + new object[] { "ADT_A28", "ADT-A28-01.hl7" }, + new object[] { "ADT_A28", "ADT-A28-02.hl7" }, + new object[] { "ADT_A29", "ADT-A29-01.hl7" }, + new object[] { "ADT_A29", "ADT-A29-02.hl7" }, + new object[] { "ADT_A31", "ADT-A31-01.hl7" }, + new object[] { "ADT_A31", "ADT-A31-02.hl7" }, + new object[] { "ADT_A47", "ADT-A47-01.hl7" }, + new object[] { "ADT_A47", "ADT-A47-02.hl7" }, + new object[] { "ADT_A60", "ADT-A60-01.hl7" }, + new object[] { "ADT_A60", "ADT-A60-02.hl7" }, + new object[] { "ORU_R01", "ORU-R01-01.hl7" }, + new object[] { "SIU_S12", "SIU-S12-01.hl7" }, + new object[] { "SIU_S12", "SIU-S12-02.hl7" }, + new object[] { "SIU_S13", "SIU-S13-01.hl7" }, + new object[] { "SIU_S13", "SIU-S13-02.hl7" }, + new object[] { "SIU_S14", "SIU-S14-01.hl7" }, + new object[] { "SIU_S14", "SIU-S14-02.hl7" }, + new object[] { "SIU_S15", "SIU-S15-01.hl7" }, + new object[] { "SIU_S15", "SIU-S15-02.hl7" }, + new object[] { "SIU_S16", "SIU-S16-01.hl7" }, + new object[] { "SIU_S16", "SIU-S16-02.hl7" }, + new object[] { "SIU_S17", "SIU-S17-01.hl7" }, + new object[] { "SIU_S17", "SIU-S17-02.hl7" }, + new object[] { "SIU_S26", "SIU-S26-01.hl7" }, + new object[] { "SIU_S26", "SIU-S26-02.hl7" }, + new object[] { "ORM_O01", "ORM-O01-01.hl7" }, + new object[] { "ORM_O01", "ORM-O01-02.hl7" }, + new object[] { "ORM_O01", "ORM-O01-03.hl7" }, + + new object[] { "MDM_T01", "MDM-T01-01.hl7" }, + new object[] { "MDM_T01", "MDM-T01-02.hl7" }, + new object[] { "MDM_T02", "MDM-T02-01.hl7" }, + new object[] { "MDM_T02", "MDM-T02-02.hl7" }, + new object[] { "MDM_T02", "MDM-T02-03.hl7" }, + + new object[] { "OML_O21", "OML-O21-01.hl7" }, + new object[] { "OML_O21", "OML-O21-02.hl7" }, new object[] { "ADT_A01", "ADT01-23.hl7" }, new object[] { "ADT_A01", "ADT01-28.hl7" }, @@ -415,6 +454,7 @@ internal static class ResourceFilter "resourceType", "type", "fullUrl", "id", "method", "url", "reference", "system", "code", "display", "gender", "use", "preferred", "status", "mode", "div", "valueString", "valueCode", "text", "endpoint", "value", "category", "type", "criticality", "priority", "severity", "description", + "intent", "docStatus", "contentType", "authorString" }; private static readonly HashSet _explicitValues = new HashSet diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Ccda/ProgressNote/PROBLEMS_in_Empty_C-CDA_2.1-C-CDAR2.1-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Ccda/ProgressNote/PROBLEMS_in_Empty_C-CDA_2.1-C-CDAR2.1-expected.json index 6165dfba7..e0726ce0e 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Ccda/ProgressNote/PROBLEMS_in_Empty_C-CDA_2.1-C-CDAR2.1-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Ccda/ProgressNote/PROBLEMS_in_Empty_C-CDA_2.1-C-CDAR2.1-expected.json @@ -3,10 +3,10 @@ "type": "batch", "entry": [ { - "fullUrl": "urn:uuid:3ca52ba9-ae49-fe85-c18d-6cc5a9b835ff", + "fullUrl": "urn:uuid:46a4ae4a-031e-7e0a-fee4-540ad5938724", "resource": { "resourceType": "Composition", - "id": "3ca52ba9-ae49-fe85-c18d-6cc5a9b835ff", + "id": "46a4ae4a-031e-7e0a-fee4-540ad5938724", "identifier": { "use": "official", "value": "2.16.840.1.113883.19.5.99999.1" @@ -37,7 +37,7 @@ { "period": { "start": "2015-07-23T07:00:00+08:00", - "end": "2015-07-23T09:00:00+08:00" + "end": "2015-07-23T12:00:00+08:00" } } ], @@ -385,7 +385,7 @@ "reference": "Patient/89236d99-8509-7d3a-9dfb-a82c6b81d268" }, "encounter": { - "reference": "Encounter/adcab029-7e17-83ea-f6fd-de590f2deae8" + "reference": "Encounter/b6f5ed56-7748-00d5-9ceb-39811c553b86" }, "custodian": { "reference": "Organization/60584e77-f1e2-7864-31ce-931c9781c1dc" @@ -398,7 +398,7 @@ }, "request": { "method": "PUT", - "url": "Composition/3ca52ba9-ae49-fe85-c18d-6cc5a9b835ff" + "url": "Composition/46a4ae4a-031e-7e0a-fee4-540ad5938724" } }, { @@ -453,10 +453,10 @@ } }, { - "fullUrl": "urn:uuid:adcab029-7e17-83ea-f6fd-de590f2deae8", + "fullUrl": "urn:uuid:b6f5ed56-7748-00d5-9ceb-39811c553b86", "resource": { "resourceType": "Encounter", - "id": "adcab029-7e17-83ea-f6fd-de590f2deae8", + "id": "b6f5ed56-7748-00d5-9ceb-39811c553b86", "status": "unknown", "identifier": [ { @@ -466,12 +466,12 @@ ], "period": { "start": "2015-07-23T07:00:00+08:00", - "end": "2015-07-23T09:00:00+08:00" + "end": "2015-07-23T12:00:00+08:00" } }, "request": { "method": "PUT", - "url": "Encounter/adcab029-7e17-83ea-f6fd-de590f2deae8" + "url": "Encounter/b6f5ed56-7748-00d5-9ceb-39811c553b86" } }, { diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A01/ADT-A01-01-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A01/ADT-A01-01-expected.json new file mode 100644 index 000000000..81f5eb19c --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A01/ADT-A01-01-expected.json @@ -0,0 +1,4623 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "1989-08-18T14:41:00+05:30", + "identifier": { + "value": "MSG00001" + }, + "id": "513a3d06-5e87-6fbc-ad1b-170ab430499f", + "entry": [ + { + "fullUrl": "urn:uuid:b4ca189b-51ae-33df-cbe2-559b4423a321", + "resource": { + "resourceType": "MessageHeader", + "id": "b4ca189b-51ae-33df-cbe2-559b4423a321", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20", + "version": "2.4.3.52854", + "software": "Rhapsody" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "A01", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "ADT^A01^ADT_A01" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/b4ca189b-51ae-33df-cbe2-559b4423a321" + } + }, + { + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "resource": { + "resourceType": "Provenance", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-11-08T05:55:14.38Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A01.

" + }, + "occurredDateTime": "1989-08-18T14:41:00+05:30", + "recorded": "1989-08-18T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "ADT^A01^ADT_A01" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + } + ], + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:503eb873-22fb-8199-ae28-3604ad59fe13", + "resource": { + "resourceType": "Device", + "id": "503eb873-22fb-8199-ae28-3604ad59fe13", + "identifier": [ + { + "value": "ADTApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + }, + { + "fullUrl": "urn:uuid:4b549918-a84d-cdaf-e150-c773a5d306e5", + "resource": { + "resourceType": "Device", + "id": "4b549918-a84d-cdaf-e150-c773a5d306e5", + "manufacturer": "Orion", + "deviceName": [ + { + "name": "Rhapsody", + "type": "manufacturer-name" + } + ], + "version": [ + { + "value": "2.4.3.52854" + } + ], + "modelNumber": "2.4.3", + "note": [ + { + "text": "Testactivity" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/4b549918-a84d-cdaf-e150-c773a5d306e5" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + }, + { + "value": "1516", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "55121", + "type": { + "coding": [ + { + "code": "FI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Facility ID" + } + ] + } + }, + { + "value": "DB123", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "urn:oid:1.12", + "assigner": { + "reference": "Organization/4e68b44e-c053-02b1-6d6d-fe816f9fdfec" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "Medicare-12345", + "type": { + "coding": [ + { + "code": "MC", + "display": "Patient's Medicare number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-medicare" + }, + { + "value": "MCN-008", + "type": { + "coding": [ + { + "code": "MA", + "display": "Patient Medicaid number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/identifier-medicaid" + }, + { + "value": "MI-12345", + "type": { + "coding": [ + { + "code": "MI", + "display": "Military ID number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/identifier-military" + }, + { + "value": "PNM1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/1fca4c8f-7562-b755-9a05-5f0f49096e5b" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + }, + { + "family": "RADIANT", + "given": [ + "LUCY" + ] + }, + { + "family": "Jack", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + }, + { + "line": [ + "1619 SOUTH UNIVERSITY" + ], + "city": "MADISON", + "state": "WI", + "postalCode": "53703", + "country": "US" + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + }, + { + "value": "8484", + "system": "email", + "use": "home" + }, + { + "value": "717171", + "system": "phone", + "use": "home" + }, + { + "value": "021212", + "system": "other", + "use": "work" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "generalPractitioner": [ + { + "reference": "Organization/4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11" + }, + { + "reference": "Practitioner/76aaad38-1077-6a5c-0c5c-102ec160a60d" + } + ], + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/VeteranMilitaryStatus", + "valueCodeableConcept": { + "coding": [ + { + "code": "Vet123", + "display": "retired", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ART" + } + ], + "text": "retired" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-animal", + "extension": [ + { + "url": "species", + "valueCodeableConcept": { + "coding": [ + { + "code": "125097000", + "display": "Goat", + "system": "http://snomed.info/sct" + } + ], + "text": "Goat" + } + }, + { + "url": "breed", + "valueCodeableConcept": { + "coding": [ + { + "code": "4880003", + "display": "Beagle", + "system": "http://snomed.info/sct" + } + ], + "text": "Beagle" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-nationality", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "BT", + "display": "Bhutan", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Bhutan" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-congregation", + "valueString": "Methodist Church" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-importance", + "valueCodeableConcept": { + "coding": [ + { + "code": "VIP", + "display": "Very Important Person", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L", + "version": "v1.1" + }, + { + "code": "IMP", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/DCM", + "version": "v1.2" + } + ], + "text": "Inportant Person" + } + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/patient-disabilityIndicator", + "valueBoolean": true + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/DisabilityPeriod", + "valuePeriod": { + "start": "2021-08-30", + "end": "2021-09-30" + } + } + ], + "contact": [ + { + "organization": { + "reference": "Organization/3bb64820-2a2b-956c-9f45-125ec102f353" + } + }, + { + "name": { + "family": "Evan", + "given": [ + "ADAM", + "A" + ], + "suffix": [ + "III", + "MD" + ], + "prefix": [ + "Dr." + ], + "use": "usual" + }, + "address": { + "line": [ + "2222", + "HOME", + "STREET", + "Highway" + ], + "city": "GREENSBORO", + "state": "NC", + "postalCode": "27401-1020", + "country": "US", + "use": "billing", + "district": "test", + "period": { + "start": "2000-01-10", + "end": "2005-01-11" + } + }, + "telecom": [ + { + "value": "5555", + "use": "work", + "system": "email", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18 + }, + { + "value": "121111", + "use": "home", + "system": "phone" + }, + { + "value": "878777", + "use": "home", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18 + }, + { + "value": "6666666", + "system": "pager", + "use": "work" + }, + { + "value": "777", + "use": "work", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 1 + }, + { + "value": "444444", + "system": "phone" + } + ], + "relationship": [ + { + "coding": [ + { + "code": "O", + "display": "Other", + "system": "http://terminology.hl7.org/CodeSystem/v2-0131" + } + ] + } + ], + "period": { + "start": "2021-08-18", + "end": "2021-12-18" + }, + "gender": "female" + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ], + "guarantor": [ + { + "party": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "onHold": false, + "period": { + "start": "2001-04-10", + "end": "2001-04-15" + } + }, + { + "party": { + "reference": "Organization/98678cfe-0455-73c8-d2a1-2ede2d55943f" + }, + "onHold": false, + "period": { + "start": "2001-04-10", + "end": "2001-04-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:98678cfe-0455-73c8-d2a1-2ede2d55943f", + "resource": { + "resourceType": "Organization", + "id": "98678cfe-0455-73c8-d2a1-2ede2d55943f", + "name": "Jupiter Hospital", + "address": [ + { + "line": [ + "1619 SOUTH UNIVERSITY" + ], + "city": "MADISON", + "state": "WI", + "postalCode": "53703", + "country": "US" + } + ], + "contact": [ + { + "telecom": [ + { + "value": "000352", + "system": "phone" + }, + { + "value": "00121", + "system": "fax" + } + ], + "purpose": { + "coding": [ + { + "code": "Urgent requirement" + } + ] + } + }, + { + "name": { + "family": "RADIANT", + "given": [ + "LUCY" + ] + } + }, + { + "name": { + "family": "Ben", + "given": [ + "Charles" + ] + } + }, + { + "name": { + "family": "Ben2" + } + } + ], + "telecom": [ + { + "value": "8484", + "system": "email" + }, + { + "value": "717171", + "system": "phone" + }, + { + "value": "021212", + "system": "other" + } + ], + "identifier": [ + { + "value": "1516", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/98678cfe-0455-73c8-d2a1-2ede2d55943f" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11", + "resource": { + "resourceType": "Organization", + "id": "4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11", + "name": "LINDAS TEST ORGANIZATION", + "identifier": [ + { + "value": "SIISCLIENT818" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11" + } + }, + { + "fullUrl": "urn:uuid:76aaad38-1077-6a5c-0c5c-102ec160a60d", + "resource": { + "resourceType": "Practitioner", + "id": "76aaad38-1077-6a5c-0c5c-102ec160a60d", + "identifier": [ + { + "value": "88", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TE", + "type": { + "coding": [ + { + "code": "DN", + "display": "Doctor number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Hippo", + "given": [ + "rold", + "H" + ], + "suffix": [ + "V", + "MD" + ], + "prefix": [ + "Dr" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/76aaad38-1077-6a5c-0c5c-102ec160a60d" + } + }, + { + "fullUrl": "urn:uuid:11967e28-8dd4-a112-0fdc-377866bf12a0", + "resource": { + "resourceType": "Organization", + "id": "11967e28-8dd4-a112-0fdc-377866bf12a0", + "identifier": [ + { + "value": "t", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-t" + }, + { + "value": "2.16.840.1.113883.19", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + } + }, + { + "fullUrl": "urn:uuid:7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "resource": { + "resourceType": "Organization", + "id": "7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "identifier": [ + { + "value": "AccMng", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMng" + }, + { + "value": "1.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + } + }, + { + "fullUrl": "urn:uuid:0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "resource": { + "resourceType": "Organization", + "id": "0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "identifier": [ + { + "value": "PERSONNELt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSONNELt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + } + }, + { + "fullUrl": "urn:uuid:f6775f99-5279-be04-bf81-0906c81f7443", + "resource": { + "resourceType": "Practitioner", + "id": "f6775f99-5279-be04-bf81-0906c81f7443", + "identifier": [ + { + "value": "1122334", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Alaz", + "given": [ + "Mohammed", + "Mahi" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "fullUrl": "urn:uuid:c613d7b2-525f-8c08-a7ac-b2b91486e257", + "resource": { + "resourceType": "Organization", + "id": "c613d7b2-525f-8c08-a7ac-b2b91486e257", + "identifier": [ + { + "value": "TEST", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TEST" + }, + { + "value": "23.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + } + }, + { + "fullUrl": "urn:uuid:04f8cfc8-62ca-12df-63ce-6304ef577d44", + "resource": { + "resourceType": "Practitioner", + "id": "04f8cfc8-62ca-12df-63ce-6304ef577d44", + "identifier": [ + { + "value": "C006", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + }, + "type": { + "coding": [ + { + "code": "BA", + "display": "Bank Account Number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen" + ], + "prefix": [ + "Dr" + ], + "use": "anonymous" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "fullUrl": "urn:uuid:99edcabd-fbeb-7e25-f823-11da8d8ed342", + "resource": { + "resourceType": "Practitioner", + "id": "99edcabd-fbeb-7e25-f823-11da8d8ed342", + "identifier": [ + { + "value": "C008", + "system": "urn:oid:2.8", + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Condoc", + "given": [ + "leen" + ], + "prefix": [ + "Dr" + ], + "use": "temp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "fullUrl": "urn:uuid:b065b233-8738-f1ec-1314-d61e4aac2c9e", + "resource": { + "resourceType": "Practitioner", + "id": "b065b233-8738-f1ec-1314-d61e4aac2c9e", + "identifier": [ + { + "value": "37", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr", + "type": { + "coding": [ + { + "code": "ANC", + "display": "Account number Creditor", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "DISNEY", + "given": [ + "WALT" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "fullUrl": "urn:uuid:9f974d4f-47e8-21a6-e549-4de4599c3764", + "resource": { + "resourceType": "Organization", + "id": "9f974d4f-47e8-21a6-e549-4de4599c3764", + "identifier": [ + { + "value": "T123", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-T123" + }, + { + "value": "urn:oid:r2.3", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + }, + { + "fullUrl": "urn:uuid:84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "resource": { + "resourceType": "Practitioner", + "id": "84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "identifier": [ + { + "value": "Othhel", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "fullUrl": "urn:uuid:24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "resource": { + "resourceType": "Organization", + "id": "24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "identifier": [ + { + "value": "TE", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TE" + }, + { + "value": "Provider Master.Community Health and Hospitals", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "type": { + "coding": [ + { + "code": "DNS", + "display": "An Internet host name, in accordance with RFC 1035; or an IP address. Either in ASCII or as integers, with periods between components (“dotted” notation).", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + } + }, + { + "fullUrl": "urn:uuid:36e3aaa4-569a-7d9d-037f-27235ed05701", + "resource": { + "resourceType": "Practitioner", + "id": "36e3aaa4-569a-7d9d-037f-27235ed05701", + "identifier": [ + { + "value": "12188", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "assigner": { + "reference": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + }, + "type": { + "coding": [ + { + "code": "DN", + "display": "Doctor number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Hippocrates", + "given": [ + "Harold", + "H" + ], + "suffix": [ + "IV", + "MD" + ], + "prefix": [ + "Dr" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + }, + { + "fullUrl": "urn:uuid:9172e4a0-1ca5-646d-2183-b179f4daa737", + "resource": { + "resourceType": "Location", + "id": "9172e4a0-1ca5-646d-2183-b179f4daa737", + "partOf": { + "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + }, + "name": "HUH AE OMU", + "identifier": [ + { + "value": "urn:oid:9.8", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "fullUrl": "urn:uuid:3913ec4d-6576-5e1a-ac31-e8280583371c", + "resource": { + "resourceType": "Location", + "id": "3913ec4d-6576-5e1a-ac31-e8280583371c", + "partOf": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + }, + "name": "OMU B", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + } + }, + { + "fullUrl": "urn:uuid:804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "resource": { + "resourceType": "Location", + "id": "804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "partOf": { + "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + }, + "name": "Bed 03", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" + } + }, + { + "fullUrl": "urn:uuid:c043880b-0fab-1cb8-14f7-0475282c4d0e", + "resource": { + "resourceType": "Location", + "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", + "name": "HOMERTON UNIVER", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + } + }, + { + "fullUrl": "urn:uuid:f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "resource": { + "resourceType": "Location", + "id": "f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "partOf": { + "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + }, + "name": "Homerton UH", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + } + }, + { + "fullUrl": "urn:uuid:7e38808c-44a8-cb0c-4709-9d6092abc32c", + "resource": { + "resourceType": "Location", + "id": "7e38808c-44a8-cb0c-4709-9d6092abc32c", + "partOf": { + "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + }, + "name": "Floor5", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + } + }, + { + "fullUrl": "urn:uuid:59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "resource": { + "resourceType": "Location", + "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "name": "4 East, room 136, bed B 4E", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + } + }, + { + "fullUrl": "urn:uuid:d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "resource": { + "resourceType": "Location", + "id": "d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "partOf": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "name": "136", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + } + }, + { + "fullUrl": "urn:uuid:5783dafa-c6c0-e673-cca4-42087ee1831b", + "resource": { + "resourceType": "Location", + "id": "5783dafa-c6c0-e673-cca4-42087ee1831b", + "partOf": { + "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + }, + "name": "B", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" + } + }, + { + "fullUrl": "urn:uuid:8b39e6e5-78cd-63ab-2441-f43ca5554096", + "resource": { + "resourceType": "Location", + "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", + "name": "CommunityHospital", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" + } + }, + { + "fullUrl": "urn:uuid:42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "resource": { + "resourceType": "Location", + "id": "42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "name": "Homes", + "identifier": [ + { + "value": "22", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/FDK" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + { + "fullUrl": "urn:uuid:84634858-74aa-5cdb-4547-60ec27339ac6", + "resource": { + "resourceType": "Location", + "id": "84634858-74aa-5cdb-4547-60ec27339ac6", + "name": "POC", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + } + }, + { + "fullUrl": "urn:uuid:9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", + "resource": { + "resourceType": "Location", + "id": "9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", + "partOf": { + "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + }, + "name": "Room-2", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" + } + }, + { + "fullUrl": "urn:uuid:35353f20-6254-e794-98ed-8007490447e3", + "resource": { + "resourceType": "Location", + "id": "35353f20-6254-e794-98ed-8007490447e3", + "partOf": { + "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" + }, + "name": "Bed-103", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/35353f20-6254-e794-98ed-8007490447e3" + } + }, + { + "fullUrl": "urn:uuid:055e10f1-222e-df73-2325-0e4396db1a55", + "resource": { + "resourceType": "Location", + "id": "055e10f1-222e-df73-2325-0e4396db1a55", + "name": "Greenland", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/055e10f1-222e-df73-2325-0e4396db1a55" + } + }, + { + "fullUrl": "urn:uuid:1154e6b2-b022-b3be-7dce-2b940ab5376d", + "resource": { + "resourceType": "Location", + "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", + "name": "Nursing home", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + } + }, + { + "fullUrl": "urn:uuid:08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "resource": { + "resourceType": "Location", + "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "name": "Rosewood", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" + } + }, + { + "fullUrl": "urn:uuid:c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "resource": { + "resourceType": "Location", + "id": "c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "name": "ROOM1", + "identifier": [ + { + "value": "urn:oid:2.16.840.1.113883.4.642.1.1108", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + } + }, + { + "fullUrl": "urn:uuid:6f159848-5f01-01b3-9594-80fbbe9ab510", + "resource": { + "resourceType": "Location", + "id": "6f159848-5f01-01b3-9594-80fbbe9ab510", + "partOf": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "name": "BED1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" + } + }, + { + "fullUrl": "urn:uuid:4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "resource": { + "resourceType": "Location", + "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "name": "FACILITY1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + } + }, + { + "fullUrl": "urn:uuid:3b0911cb-4361-cd8d-b188-463af033c699", + "resource": { + "resourceType": "Location", + "id": "3b0911cb-4361-cd8d-b188-463af033c699", + "partOf": { + "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + }, + "name": "BUILDING1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:08314073-410a-3dc7-512c-0f2d206fb59d", + "resource": { + "resourceType": "Organization", + "id": "08314073-410a-3dc7-512c-0f2d206fb59d", + "identifier": [ + { + "value": "Etest", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-Etest" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + }, + { + "fullUrl": "urn:uuid:919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "resource": { + "resourceType": "EpisodeOfCare", + "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "status": "active", + "identifier": [ + { + "value": "EOC124", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "diagnosis": [ + { + "condition": { + "reference": "Condition/481123a1-ca9c-c3c8-0284-e6926c3a50d8" + }, + "role": { + "coding": [ + { + "code": "AD", + "display": "Admission Diagnosis", + "system": "http://terminology.hl7.org/CodeSystem/diagnosis-role" + } + ] + }, + "rank": 1 + } + ] + }, + "request": { + "method": "PUT", + "url": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + }, + { + "fullUrl": "urn:uuid:4b192760-03d2-aec4-b0a6-fde323912e1e", + "resource": { + "resourceType": "Encounter", + "id": "4b192760-03d2-aec4-b0a6-fde323912e1e", + "class": { + "code": "PRENC", + "display": "pre-admission", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "in-progress", + "location": [ + { + "status": "active", + "location": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "status": "completed", + "location": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "status": "planned", + "location": { + "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "status": "completed", + "location": { + "reference": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": true + } + ] + }, + { + "status": "planned", + "location": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + } + ], + "type": [ + { + "coding": [ + { + "code": "E", + "display": "Emergency", + "system": "http://terminology.hl7.org/CodeSystem/v2-0007" + } + ] + } + ], + "hospitalization": { + "preAdmissionIdentifier": { + "value": "1234567", + "type": { + "coding": [ + { + "code": "ANON", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Anonymous identifier" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + "reAdmission": { + "coding": [ + { + "code": "R", + "display": "Re-admission", + "system": "http://terminology.hl7.org/CodeSystem/v2-0092" + } + ] + }, + "admitSource": { + "coding": [ + { + "code": "NHS Provider-General (inc.A&E-this Hosp)" + } + ] + }, + "dischargeDisposition": { + "coding": [ + { + "code": "Admitted as Inpatient", + "display": "Sample", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ACR" + } + ] + }, + "dietPreference": [ + { + "coding": [ + { + "code": "Vegan", + "display": "Vegetarian" + } + ] + } + ], + "destination": { + "reference": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + "episodeOfCare": [ + { + "reference": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "CON", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "consultant" + } + ], + "individual": { + "reference": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "ADM", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "admitter" + } + ], + "individual": { + "reference": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "PART", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "Participation" + } + ], + "individual": { + "reference": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + } + ], + "serviceType": { + "coding": [ + { + "code": "SUR" + } + ] + }, + "identifier": [ + { + "value": "40007716", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + }, + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + }, + { + "value": "50", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "urn:oid:r2.3", + "assigner": { + "reference": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + } + ], + "period": { + "start": "2015-02-08T15:54:19+05:30" + }, + "reasonCode": [ + { + "coding": [ + { + "code": "140004", + "display": "Chronic pharyngitis", + "system": "http://snomed.info/sct" + } + ] + } + ], + "length": { + "value": 2, + "unit": "d", + "system": "http://unitsofmeasure.org/" + }, + "meta": { + "security": [ + { + "code": "N", + "display": "normal", + "system": "http://terminology.hl7.org/CodeSystem/v3-Confidentiality" + } + ] + }, + "text": { + "status": "generated", + "div": "

Visit Description: Health Checkup

" + }, + "priority": { + "coding": [ + { + "code": "UR", + "display": "urgent", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.2" + }, + { + "code": "EL", + "display": "elective", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.3" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/encounter-modeOfArrival", + "valueCoding": { + "code": "C", + "display": "Car", + "system": "http://terminology.hl7.org/CodeSystem/v2-0430" + } + } + ], + "diagnosis": [ + { + "condition": { + "reference": "Condition/481123a1-ca9c-c3c8-0284-e6926c3a50d8" + }, + "use": { + "coding": [ + { + "code": "AD", + "display": "Admission Diagnosis", + "system": "http://terminology.hl7.org/CodeSystem/diagnosis-role" + } + ] + }, + "rank": 1 + } + ] + }, + "request": { + "method": "PUT", + "url": "Encounter/4b192760-03d2-aec4-b0a6-fde323912e1e" + } + }, + { + "fullUrl": "urn:uuid:9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "resource": { + "resourceType": "Provenance", + "id": "9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "occurredDateTime": "2021-08-17T18:49:43.004+05:30", + "recorded": "2029-08-01T11:21:24+05:30", + "reason": [ + { + "coding": [ + { + "code": "PATRQT", + "display": "patient requested", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActReason" + } + ] + } + ], + "agent": [ + { + "who": { + "reference": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + } + ], + "activity": { + "text": "ADT^A01^ADT_A01" + }, + "location": { + "reference": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + }, + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c" + } + }, + { + "fullUrl": "urn:uuid:ef39f581-5e8f-3917-35a9-3443303d9eee", + "resource": { + "resourceType": "Organization", + "id": "ef39f581-5e8f-3917-35a9-3443303d9eee", + "identifier": [ + { + "value": "DRNBR", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-DRNBR" + }, + { + "value": "urn:oid:W1.2", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + } + }, + { + "fullUrl": "urn:uuid:95aea53b-8d49-d57f-d16f-4d14b914f992", + "resource": { + "resourceType": "Practitioner", + "id": "95aea53b-8d49-d57f-d16f-4d14b914f992", + "identifier": [ + { + "value": "C08", + "system": "urn:oid:W1.2", + "assigner": { + "reference": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + }, + "type": { + "coding": [ + { + "code": "ANON", + "display": "Anonymous identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen", + "2ndname" + ], + "suffix": [ + "Jr", + "MD" + ], + "prefix": [ + "Dr" + ], + "use": "official" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + }, + { + "fullUrl": "urn:uuid:59d5e519-0108-5dd8-adfa-1eef5658009e", + "resource": { + "resourceType": "Location", + "id": "59d5e519-0108-5dd8-adfa-1eef5658009e", + "name": "Cona_Health", + "identifier": [ + { + "value": "urn:oid:1.3.6.1.4.1.44750.1.4", + "system": "urn:ietf:rfc:3986" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "display": "site", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + } + }, + { + "fullUrl": "urn:uuid:396e6ab6-624f-44a8-841c-6e1c4cebd765", + "resource": { + "resourceType": "Practitioner", + "id": "396e6ab6-624f-44a8-841c-6e1c4cebd765", + "identifier": [ + { + "value": "1210" + } + ], + "name": [ + { + "family": "ANES", + "given": [ + "MARK", + "B" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/396e6ab6-624f-44a8-841c-6e1c4cebd765" + } + }, + { + "fullUrl": "urn:uuid:6a01e35c-52c3-892a-2ea0-0a283eb6757b", + "resource": { + "resourceType": "Practitioner", + "id": "6a01e35c-52c3-892a-2ea0-0a283eb6757b", + "identifier": [ + { + "value": "121188", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-L", + "type": { + "coding": [ + { + "code": "DN", + "display": "Doctor number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Patrick", + "given": [ + "Harold", + "H" + ], + "suffix": [ + "IV", + "MD" + ], + "prefix": [ + "Dr" + ], + "use": "official" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/6a01e35c-52c3-892a-2ea0-0a283eb6757b" + } + }, + { + "fullUrl": "urn:uuid:a8fc538f-624b-0cee-df30-6377fabae47c", + "resource": { + "resourceType": "Practitioner", + "id": "a8fc538f-624b-0cee-df30-6377fabae47c", + "identifier": [ + { + "value": "12345689", + "type": { + "coding": [ + { + "code": "MR", + "display": "Medical record number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Everyman2", + "given": [ + "Adam2", + "A" + ], + "suffix": [ + "III", + "PHD" + ], + "prefix": [ + "DR" + ], + "use": "official" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/a8fc538f-624b-0cee-df30-6377fabae47c" + } + }, + { + "fullUrl": "urn:uuid:a9c75502-d60a-d89b-5912-f046100cd47e", + "resource": { + "resourceType": "Location", + "id": "a9c75502-d60a-d89b-5912-f046100cd47e", + "name": "OT", + "mode": "instance", + "description": "OT--201", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/a9c75502-d60a-d89b-5912-f046100cd47e" + } + }, + { + "fullUrl": "urn:uuid:55f70355-863d-579a-b4aa-81fcaf3e1fb0", + "resource": { + "resourceType": "Location", + "id": "55f70355-863d-579a-b4aa-81fcaf3e1fb0", + "partOf": { + "reference": "Location/a9c75502-d60a-d89b-5912-f046100cd47e" + }, + "name": "201", + "mode": "instance", + "description": "OT--201", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/55f70355-863d-579a-b4aa-81fcaf3e1fb0" + } + }, + { + "fullUrl": "urn:uuid:2e2e33a1-60f8-7e38-c827-fe070237c3fb", + "resource": { + "resourceType": "Procedure", + "id": "2e2e33a1-60f8-7e38-c827-fe070237c3fb", + "status": "unknown", + "identifier": [ + { + "value": "PR1001" + } + ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "Procedure/2e2e33a1-60f8-7e38-c827-fe070237c3fb" + } + }, + { + "fullUrl": "urn:uuid:c06db9c2-d07b-bac2-53c2-48ed83dd32b6", + "resource": { + "resourceType": "Procedure", + "id": "c06db9c2-d07b-bac2-53c2-48ed83dd32b6", + "code": { + "coding": [ + { + "code": "76164006", + "display": "Biopsy of colon (procedure)", + "system": "http://snomed.info/sct" + } + ], + "text": "Biopsy of colon, which was part of colonoscopy" + }, + "status": "completed", + "performedDateTime": "2005-01-25T16:10:00+05:30", + "category": { + "coding": [ + { + "code": "D", + "display": "Diagnostic Procedure", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/HL70230" + } + ] + }, + "performer": [ + { + "actor": { + "reference": "Practitioner/396e6ab6-624f-44a8-841c-6e1c4cebd765" + }, + "function": { + "coding": [ + { + "code": "88189002", + "system": "http://snomed.info/sct", + "display": "Anesthesiologist" + } + ], + "text": "Anesthesiologist" + } + }, + { + "actor": { + "reference": "Practitioner/6a01e35c-52c3-892a-2ea0-0a283eb6757b" + }, + "function": { + "coding": [ + { + "code": "304292004", + "system": "http://snomed.info/sct", + "display": "Surgeon" + } + ], + "text": "Surgeon" + } + }, + { + "actor": { + "reference": "Practitioner/a8fc538f-624b-0cee-df30-6377fabae47c" + }, + "function": { + "text": "Procedure Practitioner" + } + } + ], + "reasonCode": [ + { + "coding": [ + { + "code": "799008", + "display": "Sigmoid colon ulcer", + "system": "http://snomed.info/sct" + } + ] + } + ], + "identifier": [ + { + "value": "PR1006" + } + ], + "location": { + "reference": "Location/a9c75502-d60a-d89b-5912-f046100cd47e" + }, + "partOf": [ + { + "reference": "Procedure/2e2e33a1-60f8-7e38-c827-fe070237c3fb" + } + ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "Procedure/c06db9c2-d07b-bac2-53c2-48ed83dd32b6" + } + }, + { + "fullUrl": "urn:uuid:3bb64820-2a2b-956c-9f45-125ec102f353", + "resource": { + "resourceType": "Organization", + "id": "3bb64820-2a2b-956c-9f45-125ec102f353", + "name": "TestOrg", + "identifier": [ + { + "value": "Org12", + "type": { + "coding": [ + { + "code": "EI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "contact": [ + { + "name": { + "family": "Green", + "given": [ + "John", + "A" + ], + "suffix": [ + "II", + "MD" + ], + "prefix": [ + "DR" + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + "telecom": [ + { + "value": "898989898", + "system": "fax" + }, + { + "value": "88888888", + "system": "phone" + } + ], + "address": { + "line": [ + "Street1", + "Palkstreet" + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/3bb64820-2a2b-956c-9f45-125ec102f353" + } + }, + { + "fullUrl": "urn:uuid:abdee378-0d3b-337f-a31e-83e002ce92a0", + "resource": { + "resourceType": "RelatedPerson", + "id": "abdee378-0d3b-337f-a31e-83e002ce92a0", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "12345567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/e76154d7-9084-80e4-6274-c929d7c39880" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "I-123", + "type": { + "coding": [ + { + "code": "BA", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Bank Account Number" + } + ] + } + }, + { + "value": "I-222", + "type": { + "coding": [ + { + "code": "DI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Diner’s Club card" + } + ] + } + }, + { + "value": "Security no-23", + "system": "http://hl7.org/fhir/sid/us-ssn" + } + ], + "relationship": [ + { + "coding": [ + { + "code": "C", + "display": "Emergency Contact", + "system": "http://terminology.hl7.org/CodeSystem/v2-0131", + "version": "9.0" + }, + { + "code": "CHILD", + "display": "child", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode", + "version": "10.0" + } + ] + }, + { + "coding": [ + { + "code": "O", + "display": "Other", + "system": "http://terminology.hl7.org/CodeSystem/v2-0131" + } + ] + }, + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "period": { + "start": "2021-08-18", + "end": "2021-12-18" + }, + "address": [ + { + "line": [ + "2222", + "HOME", + "STREET", + "Highway" + ], + "city": "GREENSBORO", + "state": "NC", + "postalCode": "27401-1020", + "country": "US", + "use": "billing", + "district": "test", + "period": { + "start": "2000-01-10", + "end": "2005-01-11" + } + }, + { + "line": [ + "111", + "Duck ST" + ], + "city": "Fowl" + }, + { + "line": [ + "Street1", + "Palkstreet" + ] + }, + { + "line": [ + "ST-2" + ] + } + ], + "telecom": [ + { + "value": "5555", + "use": "work", + "system": "email", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18 + }, + { + "value": "121111", + "use": "home", + "system": "phone" + }, + { + "value": "878777", + "use": "home", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18 + }, + { + "value": "6666666", + "system": "pager", + "use": "work" + }, + { + "value": "898989898", + "system": "fax" + }, + { + "value": "88888888", + "system": "phone" + }, + { + "value": "777", + "use": "work", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 1 + }, + { + "value": "444444", + "system": "phone" + } + ], + "name": [ + { + "family": "Evan", + "given": [ + "ADAM", + "A" + ], + "suffix": [ + "III", + "MD" + ], + "prefix": [ + "Dr." + ], + "use": "usual" + }, + { + "family": "Green", + "given": [ + "John", + "A" + ], + "suffix": [ + "II", + "MD" + ], + "prefix": [ + "DR" + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official" + } + ], + "gender": "female", + "birthDate": "1962-01-10", + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47" + } + ] + } + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White" + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/abdee378-0d3b-337f-a31e-83e002ce92a0" + } + }, + { + "fullUrl": "urn:uuid:e76154d7-9084-80e4-6274-c929d7c39880", + "resource": { + "resourceType": "Organization", + "id": "e76154d7-9084-80e4-6274-c929d7c39880", + "identifier": [ + { + "value": "T1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-T1" + }, + { + "value": "2.16.840.1.113883.19", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/e76154d7-9084-80e4-6274-c929d7c39880" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:4e68b44e-c053-02b1-6d6d-fe816f9fdfec", + "resource": { + "resourceType": "Organization", + "id": "4e68b44e-c053-02b1-6d6d-fe816f9fdfec", + "identifier": [ + { + "value": "t", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-t" + }, + { + "value": "urn:oid:1.12", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4e68b44e-c053-02b1-6d6d-fe816f9fdfec" + } + }, + { + "fullUrl": "urn:uuid:e82402a9-b2d1-2a28-3250-c099d5a77bf7", + "resource": { + "resourceType": "Organization", + "id": "e82402a9-b2d1-2a28-3250-c099d5a77bf7", + "identifier": [ + { + "value": "PERSt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/e82402a9-b2d1-2a28-3250-c099d5a77bf7" + } + }, + { + "fullUrl": "urn:uuid:ce70e6c3-c190-121d-c251-e4bae5cde6a1", + "resource": { + "resourceType": "Practitioner", + "id": "ce70e6c3-c190-121d-c251-e4bae5cde6a1", + "identifier": [ + { + "value": "1134", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/e82402a9-b2d1-2a28-3250-c099d5a77bf7" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Aly", + "given": [ + "Zafar", + "Mahendra" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/ce70e6c3-c190-121d-c251-e4bae5cde6a1" + } + }, + { + "fullUrl": "urn:uuid:88a53755-c972-6904-b4ce-8884b84ddc2e", + "resource": { + "resourceType": "PractitionerRole", + "id": "88a53755-c972-6904-b4ce-8884b84ddc2e", + "code": [ + { + "coding": [ + { + "code": "ResponsibleObserver", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/ce70e6c3-c190-121d-c251-e4bae5cde6a1" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/88a53755-c972-6904-b4ce-8884b84ddc2e" + } + }, + { + "fullUrl": "urn:uuid:3e0952c6-eea0-8938-96f8-07c224bf1577", + "resource": { + "resourceType": "Practitioner", + "id": "3e0952c6-eea0-8938-96f8-07c224bf1577", + "identifier": [ + { + "value": "2234" + } + ], + "name": [ + { + "family": "Pauly", + "given": [ + "Berrie", + "Raud" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/3e0952c6-eea0-8938-96f8-07c224bf1577" + } + }, + { + "fullUrl": "urn:uuid:bc78e290-ec67-c238-1e05-aefb6b252b0c", + "resource": { + "resourceType": "PractitionerRole", + "id": "bc78e290-ec67-c238-1e05-aefb6b252b0c", + "code": [ + { + "coding": [ + { + "code": "ResponsibleObserver", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/3e0952c6-eea0-8938-96f8-07c224bf1577" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/bc78e290-ec67-c238-1e05-aefb6b252b0c" + } + }, + { + "fullUrl": "urn:uuid:fe0adb86-ebe9-6479-0055-9db8dc1ff99a", + "resource": { + "resourceType": "Device", + "id": "fe0adb86-ebe9-6479-0055-9db8dc1ff99a", + "identifier": [ + { + "value": "EI12.3", + "system": "urn:uuid:UI2", + "type": { + "coding": [ + { + "code": "GUID", + "display": "Same as UUID.", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + }, + { + "system": "urn:oid:UI1", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/fe0adb86-ebe9-6479-0055-9db8dc1ff99a" + } + }, + { + "fullUrl": "urn:uuid:45f65e47-46c4-1a54-f9fb-1321258e79b2", + "resource": { + "resourceType": "Practitioner", + "id": "45f65e47-46c4-1a54-f9fb-1321258e79b2", + "identifier": [ + { + "type": { + "coding": [ + { + "code": "MD-25" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/45f65e47-46c4-1a54-f9fb-1321258e79b2" + } + }, + { + "fullUrl": "urn:uuid:090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3", + "resource": { + "resourceType": "PractitionerRole", + "id": "090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3", + "code": [ + { + "coding": [ + { + "code": "LabMedicalDirector", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/45f65e47-46c4-1a54-f9fb-1321258e79b2" + }, + "organization": { + "reference": "Organization/056aa7c7-6b75-3c67-63c5-cf9604f16d25" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3" + } + }, + { + "fullUrl": "urn:uuid:056aa7c7-6b75-3c67-63c5-cf9604f16d25", + "resource": { + "resourceType": "Organization", + "id": "056aa7c7-6b75-3c67-63c5-cf9604f16d25", + "name": "FairOaks Hspital", + "address": [ + { + "line": [ + "Research Park", + "Fairfax" + ], + "city": "VA", + "state": "22031", + "postalCode": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/056aa7c7-6b75-3c67-63c5-cf9604f16d25" + } + }, + { + "fullUrl": "urn:uuid:07fd2dd3-dbd6-5bb1-cfda-02226795d9a0", + "resource": { + "resourceType": "Observation", + "id": "07fd2dd3-dbd6-5bb1-cfda-02226795d9a0", + "identifier": [ + { + "value": "EI21", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-OII" + }, + { + "type": { + "coding": [ + { + "code": "FILL" + } + ] + } + } + ], + "status": "unknown", + "code": { + "coding": [ + { + "code": "8867-4", + "display": "heartrate", + "system": "http://loinc.org" + } + ] + }, + "component": [ + { + "code": { + "coding": [ + { + "code": "8867-4", + "display": "heartrate", + "system": "http://loinc.org" + } + ] + }, + "valueQuantity": { + "value": 60, + "code": "beats/min", + "unit": "beats/min", + "system": "urn:iso:std:iso:3986" + }, + "referenceRange": [ + { + "text": "70-80" + } + ] + }, + { + "code": { + "coding": [ + { + "code": "8867-4", + "display": "heartrate", + "system": "http://loinc.org" + } + ] + }, + "valueQuantity": { + "value": 120, + "code": "beats/min", + "unit": "beats/min", + "system": "urn:iso:std:iso:3986" + }, + "referenceRange": [ + { + "text": "70-80" + } + ] + } + ], + "effectiveDateTime": "1999-07-02", + "method": { + "coding": [ + { + "code": "OBS", + "display": "This is test method", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/AS4" + } + ] + }, + "device": { + "reference": "Device/fe0adb86-ebe9-6479-0055-9db8dc1ff99a" + }, + "bodySite": { + "coding": [ + { + "code": "BU", + "display": "Observation site", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/E5" + } + ] + }, + "performer": [ + { + "reference": "PractitionerRole/88a53755-c972-6904-b4ce-8884b84ddc2e" + }, + { + "reference": "PractitionerRole/bc78e290-ec67-c238-1e05-aefb6b252b0c" + }, + { + "reference": "PractitionerRole/090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3" + } + ], + "interpretation": [ + { + "coding": [ + { + "code": "A", + "display": "Abnormal", + "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation" + } + ] + }, + { + "coding": [ + { + "code": "B", + "display": "Better", + "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation" + } + ] + } + ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "S", + "display": "Partial", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Partial" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/07fd2dd3-dbd6-5bb1-cfda-02226795d9a0" + } + }, + { + "fullUrl": "urn:uuid:a0adcda8-0b28-d089-1955-c04308d5fe28", + "resource": { + "resourceType": "AllergyIntolerance", + "id": "a0adcda8-0b28-d089-1955-c04308d5fe28", + "category": [ + "environment" + ], + "type": "allergy", + "code": { + "coding": [ + { + "code": "P", + "display": "PENICILLIN", + "system": "http://terminology.hl7.org/CodeSystem/icd-o" + } + ] + }, + "reaction": [ + { + "manifestation": [ + { + "text": "CODE16" + } + ], + "onset": "2021-08-24" + } + ], + "criticality": "low", + "clinicalStatus": { + "coding": [ + { + "code": "active", + "display": "Active", + "system": "http://terminology.hl7.org/CodeSystem/allergyintolerance-clinical" + } + ] + }, + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "AllergyIntolerance/a0adcda8-0b28-d089-1955-c04308d5fe28" + } + }, + { + "fullUrl": "urn:uuid:14493a95-7780-ead5-89cc-ad6c3bc31d51", + "resource": { + "resourceType": "Practitioner", + "id": "14493a95-7780-ead5-89cc-ad6c3bc31d51", + "identifier": [ + { + "value": "005454" + } + ], + "name": [ + { + "family": "DIAG", + "given": [ + "ROBIN", + "B" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/14493a95-7780-ead5-89cc-ad6c3bc31d51" + } + }, + { + "fullUrl": "urn:uuid:481123a1-ca9c-c3c8-0284-e6926c3a50d8", + "resource": { + "resourceType": "Condition", + "id": "481123a1-ca9c-c3c8-0284-e6926c3a50d8", + "code": { + "coding": [ + { + "code": "422504002", + "display": "Ischemic stroke(disorder)", + "system": "http://snomed.info/sct" + } + ], + "text": "Stroke" + }, + "onsetDateTime": "2004-01-25T12:50:25+05:30", + "identifier": [ + { + "value": "DI20", + "system": "urn:oid:DTUI", + "type": { + "coding": [ + { + "code": "CLIP", + "display": "Clinical laboratory Improvement Program. Allows for the ability to designate organization identifier as a “CLIP” assigned number (for labs). Used by US Department of Defense.", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "asserter": { + "reference": "Practitioner/14493a95-7780-ead5-89cc-ad6c3bc31d51" + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/condition-assertedDate", + "valueDateTime": "2020-05-01T16:45:15+05:30" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/condition-dueTo", + "valueReference": { + "reference": "Condition/98e2ecfc-6e04-bc30-6624-4f3686214b22" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Condition/481123a1-ca9c-c3c8-0284-e6926c3a50d8" + } + }, + { + "fullUrl": "urn:uuid:98e2ecfc-6e04-bc30-6624-4f3686214b22", + "resource": { + "resourceType": "Condition", + "id": "98e2ecfc-6e04-bc30-6624-4f3686214b22", + "identifier": [ + { + "system": "urn:oid:UI", + "type": { + "coding": [ + { + "code": "CLIP", + "display": "Clinical laboratory Improvement Program. Allows for the ability to designate organization identifier as a “CLIP” assigned number (for labs). Used by US Department of Defense.", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "Condition/98e2ecfc-6e04-bc30-6624-4f3686214b22" + } + }, + { + "fullUrl": "urn:uuid:c073f2c1-a818-924b-8881-1481ac88d691", + "resource": { + "resourceType": "Organization", + "id": "c073f2c1-a818-924b-8881-1481ac88d691", + "name": "AuthProvider", + "identifier": [ + { + "value": "A", + "type": { + "coding": [ + { + "code": "LR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/c073f2c1-a818-924b-8881-1481ac88d691" + } + }, + { + "fullUrl": "urn:uuid:e0ba3d6b-452f-7c22-a79d-1035e4b33ceb", + "resource": { + "resourceType": "Practitioner", + "id": "e0ba3d6b-452f-7c22-a79d-1035e4b33ceb", + "identifier": [ + { + "value": "114", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-2.3", + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Beverly", + "given": [ + "Crusher", + "An" + ], + "suffix": [ + "Mr", + "AHP", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/e0ba3d6b-452f-7c22-a79d-1035e4b33ceb" + } + }, + { + "fullUrl": "urn:uuid:739ae409-c591-1a59-32ad-d2ef1b937b0f", + "resource": { + "resourceType": "ServiceRequest", + "id": "739ae409-c591-1a59-32ad-d2ef1b937b0f", + "status": "on-hold", + "intent": "order", + "identifier": [ + { + "value": "123-1", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-name" + }, + { + "value": "123-2", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-Testname" + } + ], + "authoredOn": "1990-05-01T12:16:00+05:30", + "performer": [ + { + "reference": "Organization/c073f2c1-a818-924b-8881-1481ac88d691" + }, + { + "reference": "Practitioner/e0ba3d6b-452f-7c22-a79d-1035e4b33ceb" + } + ], + "performerType": { + "coding": [ + { + "code": "EXTERNAL" + } + ] + }, + "note": [ + { + "text": "Check for metastatic disease" + } + ], + "priority": "asap", + "reasonCode": [ + { + "coding": [ + { + "code": "R-1", + "display": "Reason", + "system": "http://www.ama-assn.org/go/cpt" + } + ], + "text": "Patient has a spinal fracture" + } + ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/739ae409-c591-1a59-32ad-d2ef1b937b0f" + } + }, + { + "fullUrl": "urn:uuid:dfab6985-a691-c4f5-d2b2-6481fdfd59e4", + "resource": { + "resourceType": "Coverage", + "id": "dfab6985-a691-c4f5-d2b2-6481fdfd59e4", + "class": [ + { + "value": "BAV", + "name": "Blue Advantage HMO", + "type": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/coverage-class", + "code": "plan", + "display": "Plan" + } + ] + } + }, + { + "value": "PUBSUMB", + "name": "SelfPay", + "type": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/coverage-class", + "code": "group", + "display": "Group" + } + ] + } + } + ], + "network": "Blue Advantage HMO", + "period": { + "start": "1989-10-01", + "end": "2050-10-01" + }, + "type": { + "coding": [ + { + "code": "HMO", + "display": "health maintenance organization policy", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + } + ] + }, + "identifier": [ + { + "value": "PN-145", + "type": { + "coding": [ + { + "code": "PLN", + "display": "Policy Number", + "system": "http://example.com/CodeSystem/additional-identifier" + } + ] + }, + "system": "http://www.examplehealthplan.com/fhir/policyidentifier" + }, + { + "value": "Medicare-12345", + "type": { + "coding": [ + { + "code": "MC", + "display": "Patient's Medicare number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-medicare" + }, + { + "value": "MCN-008", + "type": { + "coding": [ + { + "code": "MA", + "display": "Patient Medicaid number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/identifier-medicaid" + }, + { + "value": "PNM1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/1fca4c8f-7562-b755-9a05-5f0f49096e5b" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "costToBeneficiary": [ + { + "type": { + "coding": [ + { + "code": "DC", + "display": "direct unit cost", + "system": "http://terminology.hl7.org/CodeSystem/v2-0205" + } + ] + }, + "valueMoney": { + "value": 150, + "currency": "USD" + } + } + ], + "subscriberId": "HMO-12345", + "status": "active", + "beneficiary": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "payor": [ + { + "reference": "Organization/04a2a5f2-c971-1e42-e788-250ea487a889" + } + ], + "policyHolder": { + "reference": "Organization/4829e288-ac03-22cc-c65e-922004275fd0" + }, + "subscriber": { + "reference": "RelatedPerson/fd1eed45-4ccb-bb7c-d157-58eb0366d777" + }, + "relationship": { + "coding": [ + { + "code": "spouse", + "display": "Spouse", + "system": "http://terminology.hl7.org/CodeSystem/subscriber-relationship" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Coverage/dfab6985-a691-c4f5-d2b2-6481fdfd59e4" + } + }, + { + "fullUrl": "urn:uuid:04a2a5f2-c971-1e42-e788-250ea487a889", + "resource": { + "resourceType": "Organization", + "id": "04a2a5f2-c971-1e42-e788-250ea487a889", + "address": [ + { + "line": [ + "1979 MILKY WAY" + ], + "city": "VERONA", + "state": "WI", + "postalCode": "53593", + "country": "US" + } + ], + "contact": [ + { + "name": { + "family": "Henry", + "given": [ + "Rony", + "A" + ], + "suffix": [ + "III", + "MD" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1925-10-12" + } + } + } + ], + "telecom": [ + { + "value": "(555)555-5555", + "system": "phone" + } + ], + "identifier": [ + { + "value": "IC-1.31", + "type": { + "coding": [ + { + "code": "NIIP", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "National Insurance Payor Identifier (Payor)" + } + ] + }, + "system": "urn:oid:2.16.840.1.113883.1.1", + "period": { + "start": "1929-10-11", + "end": "1929-10-12" + } + } + ], + "name": "Blue Cross Blue Shield of Texas" + }, + "request": { + "method": "PUT", + "url": "Organization/04a2a5f2-c971-1e42-e788-250ea487a889" + } + }, + { + "fullUrl": "urn:uuid:4829e288-ac03-22cc-c65e-922004275fd0", + "resource": { + "resourceType": "Organization", + "id": "4829e288-ac03-22cc-c65e-922004275fd0", + "address": [ + { + "line": [ + "2000 MILKY WAY" + ], + "city": "VERONA", + "state": "WI", + "postalCode": "53593", + "country": "US" + } + ], + "name": "Sam P. Hil", + "contact": [ + { + "name": { + "family": "Richard", + "given": [ + "Paul" + ] + }, + "telecom": [ + { + "value": "254622222", + "system": "phone" + } + ] + } + ], + "telecom": [ + { + "value": "555777888", + "system": "fax" + }, + { + "system": "phone" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4829e288-ac03-22cc-c65e-922004275fd0" + } + }, + { + "fullUrl": "urn:uuid:fd1eed45-4ccb-bb7c-d157-58eb0366d777", + "resource": { + "resourceType": "RelatedPerson", + "id": "fd1eed45-4ccb-bb7c-d157-58eb0366d777", + "identifier": [ + { + "value": "HMO-12345", + "type": { + "coding": [ + { + "code": "NI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "National unique individual identifier" + } + ] + }, + "system": "urn:oid:2.16.840.1.113883.1.3" + }, + { + "value": "1117", + "type": { + "coding": [ + { + "code": "EI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Employee number" + } + ] + }, + "system": "urn:oid:2.16.840.1.113883.1.4" + }, + { + "value": "1118", + "type": { + "coding": [ + { + "code": "BC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Bank Card Number" + } + ] + } + }, + { + "value": "425-57-9745", + "type": { + "coding": [ + { + "code": "SS", + "display": "Social Security number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + } + ], + "relationship": [ + { + "coding": [ + { + "code": "SPS", + "display": "spouse", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "address": [ + { + "line": [ + "3857 Velvet Treasure Terrace" + ], + "city": "Midnight", + "state": "NC", + "postalCode": "27878", + "country": "US" + } + ], + "name": [ + { + "family": "Doe", + "given": [ + "Rosallie", + "John" + ], + "suffix": [ + "III", + "Bachelors" + ], + "prefix": [ + "Mrs." + ], + "use": "official" + } + ], + "gender": "female", + "birthDate": "1975-02-28", + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "telecom": [ + { + "value": "0005245", + "use": "work", + "system": "email" + }, + { + "system": "phone" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47" + } + ] + }, + "preferred": true + } + ] + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/fd1eed45-4ccb-bb7c-d157-58eb0366d777" + } + }, + { + "fullUrl": "urn:uuid:1fca4c8f-7562-b755-9a05-5f0f49096e5b", + "resource": { + "resourceType": "Organization", + "id": "1fca4c8f-7562-b755-9a05-5f0f49096e5b", + "identifier": [ + { + "value": "PM", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PM" + }, + { + "value": "2.6.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/1fca4c8f-7562-b755-9a05-5f0f49096e5b" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A01/ADT-A01-expected-2.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A01/ADT-A01-02-expected.json similarity index 93% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A01/ADT-A01-expected-2.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A01/ADT-A01-02-expected.json index 6461ef5d6..f24bef22f 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A01/ADT-A01-expected-2.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A01/ADT-A01-02-expected.json @@ -58,13 +58,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T12:34:25.014Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A01.

" + "div": "

Resource bundle generated on 2021-10-29T11:13:16.987Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A01.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -106,7 +106,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { @@ -1155,6 +1155,7 @@ } ], "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1179,6 +1180,7 @@ }, "name": "OMU B", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1203,6 +1205,7 @@ }, "name": "Bed 03", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1224,6 +1227,7 @@ "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", "name": "HOMERTON UNIVER", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1248,6 +1252,7 @@ }, "name": "Homerton UH", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1272,6 +1277,7 @@ }, "name": "Floor5", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1293,6 +1299,7 @@ "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", "name": "4 East, room 136, bed B 4E", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1317,6 +1324,7 @@ }, "name": "136", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1341,6 +1349,7 @@ }, "name": "B", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1362,6 +1371,7 @@ "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", "name": "CommunityHospital", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1409,6 +1419,7 @@ "id": "84634858-74aa-5cdb-4547-60ec27339ac6", "name": "POC", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1433,6 +1444,7 @@ }, "name": "Room-2", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1457,6 +1469,7 @@ }, "name": "Bed-103", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1478,6 +1491,7 @@ "id": "055e10f1-222e-df73-2325-0e4396db1a55", "name": "Greenland", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1499,6 +1513,7 @@ "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", "name": "Nursing home", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1520,6 +1535,7 @@ "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", "name": "Rosewood", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1569,7 +1585,7 @@ "resource": { "resourceType": "EpisodeOfCare", "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", - "status": "planned", + "status": "active", "identifier": [ { "value": "EOC124", @@ -1607,44 +1623,14 @@ "display": "pre-admission", "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" }, - "status": "planned", + "status": "in-progress", "location": [ { - "status": "planned", + "status": "active", "location": { "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, { "status": "completed", "location": { @@ -1657,42 +1643,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "planned", "location": { @@ -1705,42 +1655,6 @@ } ] }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "completed", "location": { @@ -1752,18 +1666,6 @@ "valueBoolean": true } ] - }, - { - "status": "completed", - "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true - } - ] } ], "type": [ diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A01/ADT01-23-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A01/ADT01-23-expected.json index d7045b8b2..c8a95a9a4 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A01/ADT01-23-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A01/ADT01-23-expected.json @@ -46,13 +46,13 @@ } }, { - "fullUrl": "urn:uuid:fbc2f60d-f7f1-af9a-17ea-ff70b3f4d7ea", + "fullUrl": "urn:uuid:4e45fbdc-bab9-f433-dde6-a8adf26acf93", "resource": { "resourceType": "Provenance", - "id": "fbc2f60d-f7f1-af9a-17ea-ff70b3f4d7ea", + "id": "4e45fbdc-bab9-f433-dde6-a8adf26acf93", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T12:39:33.152Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A01.

" + "div": "

Resource bundle generated on 2021-10-29T11:19:18.321Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A01.

" }, "occurredDateTime": "2005-01-10T04:55:04", "recorded": "2005-01-10T04:55:04", @@ -86,7 +86,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/fbc2f60d-f7f1-af9a-17ea-ff70b3f4d7ea" + "url": "Provenance/4e45fbdc-bab9-f433-dde6-a8adf26acf93" } }, { @@ -452,6 +452,7 @@ "id": "eafc9bd8-6600-8232-f911-25b4ea83f641", "name": "PREOP", "mode": "instance", + "description": "PREOP--101--1--1--S", "physicalType": { "coding": [ { @@ -476,6 +477,7 @@ }, "name": "101", "mode": "instance", + "description": "PREOP--101--1--1--S", "physicalType": { "coding": [ { @@ -500,6 +502,7 @@ }, "name": "1", "mode": "instance", + "description": "PREOP--101--1--1--S", "physicalType": { "coding": [ { @@ -528,6 +531,7 @@ }, "name": "S", "mode": "instance", + "description": "PREOP--101--1--1--S", "physicalType": { "coding": [ { @@ -559,30 +563,6 @@ "location": { "reference": "Location/eafc9bd8-6600-8232-f911-25b4ea83f641" } - }, - { - "status": "active", - "location": { - "reference": "Location/3ab35502-6cac-adb6-225e-1d28c3082bf5" - } - }, - { - "status": "active", - "location": { - "reference": "Location/b2d5327c-354a-b91d-541d-c6b0fe91a841" - } - }, - { - "status": "active", - "location": { - "reference": "Location/b2d5327c-354a-b91d-541d-c6b0fe91a841" - } - }, - { - "status": "active", - "location": { - "reference": "Location/cb0cbfcd-bdcd-775d-ed89-65b953b8e1de" - } } ], "type": [ @@ -837,9 +817,6 @@ ] }, "system": "http://www.examplehealthplan.com/fhir/policyidentifier" - }, - { - "value": "8291 " } ], "subscriberId": "8291 ", @@ -1069,9 +1046,6 @@ ] }, "system": "http://www.examplehealthplan.com/fhir/policyidentifier" - }, - { - "value": "8291 " } ], "subscriberId": "8291 ", diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A01/ADT01-28-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A01/ADT01-28-expected.json index d7294055c..94b45be45 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A01/ADT01-28-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A01/ADT01-28-expected.json @@ -1,7 +1,7 @@ { "resourceType": "Bundle", "type": "batch", - "timestamp": "1988-08-18T11:26:00", + "timestamp": "1988-10-18T11:26:00", "identifier": { "value": "MSG00001" }, @@ -68,16 +68,16 @@ } }, { - "fullUrl": "urn:uuid:ae8c8e53-d120-6815-afb1-783160fb3e48", + "fullUrl": "urn:uuid:aaf37d11-5d66-af8d-c286-16b46b7f9ada", "resource": { "resourceType": "Provenance", - "id": "ae8c8e53-d120-6815-afb1-783160fb3e48", + "id": "aaf37d11-5d66-af8d-c286-16b46b7f9ada", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T12:40:34.086Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A01.

" + "div": "

Resource bundle generated on 2021-10-29T11:20:28.107Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A01.

" }, - "occurredDateTime": "1988-08-18T11:26:00", - "recorded": "1988-08-18T11:26:00", + "occurredDateTime": "1988-10-18T11:26:00", + "recorded": "1988-10-18T11:26:00", "agent": [ { "type": { @@ -108,7 +108,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/ae8c8e53-d120-6815-afb1-783160fb3e48" + "url": "Provenance/aaf37d11-5d66-af8d-c286-16b46b7f9ada" } }, { @@ -262,7 +262,7 @@ "coding": [ { "code": "NK", - "display": "NK" + "display": "NEXT OF KIN" } ] } @@ -339,6 +339,7 @@ "id": "55fb6bcf-59d7-2cc4-2ddc-d38ba31ff1d2", "name": "2000", "mode": "instance", + "description": "2000--2012--01", "physicalType": { "coding": [ { @@ -363,6 +364,7 @@ }, "name": "2012", "mode": "instance", + "description": "2000--2012--01", "physicalType": { "coding": [ { @@ -387,6 +389,7 @@ }, "name": "01", "mode": "instance", + "description": "2000--2012--01", "physicalType": { "coding": [ { @@ -418,18 +421,6 @@ "location": { "reference": "Location/55fb6bcf-59d7-2cc4-2ddc-d38ba31ff1d2" } - }, - { - "status": "active", - "location": { - "reference": "Location/95fb96ed-bf64-1327-6204-e8e66a472eb6" - } - }, - { - "status": "active", - "location": { - "reference": "Location/408220ee-3137-d895-e8a9-8937117bf0c1" - } } ], "hospitalization": { @@ -518,7 +509,7 @@ "coding": [ { "code": "NK", - "display": "NK" + "display": "NEXT OF KIN" } ] } diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A02/ADT-A02-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A02/ADT-A02-01-expected.json similarity index 93% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A02/ADT-A02-expected.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A02/ADT-A02-01-expected.json index 1c8a51d08..1d5c92813 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A02/ADT-A02-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A02/ADT-A02-01-expected.json @@ -60,13 +60,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T12:44:55.028Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A02.

" + "div": "

Resource bundle generated on 2021-10-29T11:26:30.302Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A02.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -108,7 +108,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { @@ -1363,6 +1363,7 @@ } ], "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1387,6 +1388,7 @@ }, "name": "OMU B", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1411,6 +1413,7 @@ }, "name": "Bed 03", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1432,6 +1435,7 @@ "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", "name": "HOMERTON UNIVER", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1456,6 +1460,7 @@ }, "name": "Homerton UH", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1480,6 +1485,7 @@ }, "name": "Floor5", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1501,6 +1507,7 @@ "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", "name": "4 East, room 136, bed B 4E", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1525,6 +1532,7 @@ }, "name": "136", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1549,6 +1557,7 @@ }, "name": "B", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1570,6 +1579,7 @@ "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", "name": "CommunityHospital", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1617,6 +1627,7 @@ "id": "84634858-74aa-5cdb-4547-60ec27339ac6", "name": "POC", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1641,6 +1652,7 @@ }, "name": "Room-2", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1665,6 +1677,7 @@ }, "name": "Bed-103", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1686,6 +1699,7 @@ "id": "055e10f1-222e-df73-2325-0e4396db1a55", "name": "Greenland", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1707,6 +1721,7 @@ "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", "name": "Nursing home", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1728,6 +1743,7 @@ "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", "name": "Rosewood", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1755,6 +1771,7 @@ } ], "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -1779,6 +1796,7 @@ }, "name": "BED1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -1800,6 +1818,7 @@ "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", "name": "FACILITY1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -1824,6 +1843,7 @@ }, "name": "BUILDING1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -1848,6 +1868,7 @@ }, "name": "FLOOR1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -1897,7 +1918,7 @@ "resource": { "resourceType": "EpisodeOfCare", "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", - "status": "planned", + "status": "active", "identifier": [ { "value": "EOC124", @@ -1935,44 +1956,14 @@ "display": "pre-admission", "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" }, - "status": "planned", + "status": "in-progress", "location": [ { - "status": "planned", + "status": "active", "location": { "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, { "status": "completed", "location": { @@ -1985,42 +1976,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "planned", "location": { @@ -2033,42 +1988,6 @@ } ] }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "completed", "location": { @@ -2081,18 +2000,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true - } - ] - }, { "status": "planned", "location": { @@ -2104,54 +2011,6 @@ "valueBoolean": false } ] - }, - { - "status": "planned", - "location": { - "reference": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] } ], "type": [ @@ -3003,6 +2862,9 @@ ] } ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, "extension": [ { "url": "http://example.com/v2-to-fhir-converter/Observation_Status", diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A02/ADT-A02-expected-2.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A02/ADT-A02-02-expected.json similarity index 93% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A02/ADT-A02-expected-2.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A02/ADT-A02-02-expected.json index c6561eb8e..95a33a3f9 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A02/ADT-A02-expected-2.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A02/ADT-A02-02-expected.json @@ -58,13 +58,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T12:42:35.872Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A02.

" + "div": "

Resource bundle generated on 2021-10-29T11:24:20.654Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A02.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -106,7 +106,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { @@ -1155,6 +1155,7 @@ } ], "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1179,6 +1180,7 @@ }, "name": "OMU B", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1203,6 +1205,7 @@ }, "name": "Bed 03", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1224,6 +1227,7 @@ "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", "name": "HOMERTON UNIVER", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1248,6 +1252,7 @@ }, "name": "Homerton UH", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1272,6 +1277,7 @@ }, "name": "Floor5", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1293,6 +1299,7 @@ "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", "name": "4 East, room 136, bed B 4E", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1317,6 +1324,7 @@ }, "name": "136", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1341,6 +1349,7 @@ }, "name": "B", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1362,6 +1371,7 @@ "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", "name": "CommunityHospital", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1409,6 +1419,7 @@ "id": "84634858-74aa-5cdb-4547-60ec27339ac6", "name": "POC", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1433,6 +1444,7 @@ }, "name": "Room-2", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1457,6 +1469,7 @@ }, "name": "Bed-103", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1478,6 +1491,7 @@ "id": "055e10f1-222e-df73-2325-0e4396db1a55", "name": "Greenland", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1499,6 +1513,7 @@ "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", "name": "Nursing home", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1520,6 +1535,7 @@ "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", "name": "Rosewood", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1569,7 +1585,7 @@ "resource": { "resourceType": "EpisodeOfCare", "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", - "status": "planned", + "status": "active", "identifier": [ { "value": "EOC124", @@ -1607,44 +1623,14 @@ "display": "pre-admission", "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" }, - "status": "planned", + "status": "in-progress", "location": [ { - "status": "planned", + "status": "active", "location": { "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, { "status": "completed", "location": { @@ -1657,42 +1643,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "planned", "location": { @@ -1705,42 +1655,6 @@ } ] }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "completed", "location": { @@ -1752,18 +1666,6 @@ "valueBoolean": true } ] - }, - { - "status": "completed", - "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true - } - ] } ], "type": [ diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A03/ADT-A03-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A03/ADT-A03-01-expected.json similarity index 95% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A03/ADT-A03-expected.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A03/ADT-A03-01-expected.json index 182a244ca..802736f13 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A03/ADT-A03-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A03/ADT-A03-01-expected.json @@ -60,13 +60,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T12:47:57.113Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A03.

" + "div": "

Resource bundle generated on 2021-10-29T11:28:17.443Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A03.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -108,7 +108,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { @@ -1649,6 +1649,7 @@ } ], "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1673,6 +1674,7 @@ }, "name": "OMU B", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1697,6 +1699,7 @@ }, "name": "Bed 03", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1718,6 +1721,7 @@ "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", "name": "HOMERTON UNIVER", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1742,6 +1746,7 @@ }, "name": "Homerton UH", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1766,6 +1771,7 @@ }, "name": "Floor5", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1787,6 +1793,7 @@ "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", "name": "4 East, room 136, bed B 4E", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1811,6 +1818,7 @@ }, "name": "136", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1835,6 +1843,7 @@ }, "name": "B", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1856,6 +1865,7 @@ "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", "name": "CommunityHospital", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1903,6 +1913,7 @@ "id": "84634858-74aa-5cdb-4547-60ec27339ac6", "name": "POC", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1927,6 +1938,7 @@ }, "name": "Room-2", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1951,6 +1963,7 @@ }, "name": "Bed-103", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1972,6 +1985,7 @@ "id": "055e10f1-222e-df73-2325-0e4396db1a55", "name": "Greenland", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1993,6 +2007,7 @@ "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", "name": "Nursing home", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -2014,6 +2029,7 @@ "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", "name": "Rosewood", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -2041,6 +2057,7 @@ } ], "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2065,6 +2082,7 @@ }, "name": "BED1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2086,6 +2104,7 @@ "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", "name": "FACILITY1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2110,6 +2129,7 @@ }, "name": "BUILDING1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2134,6 +2154,7 @@ }, "name": "FLOOR1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2183,7 +2204,7 @@ "resource": { "resourceType": "EpisodeOfCare", "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", - "status": "planned", + "status": "finished", "identifier": [ { "value": "EOC124", @@ -2238,44 +2259,14 @@ "display": "pre-admission", "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" }, - "status": "planned", + "status": "finished", "location": [ { - "status": "planned", + "status": "completed", "location": { "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, { "status": "completed", "location": { @@ -2288,42 +2279,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "planned", "location": { @@ -2336,42 +2291,6 @@ } ] }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "completed", "location": { @@ -2384,18 +2303,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true - } - ] - }, { "status": "planned", "location": { @@ -2407,54 +2314,6 @@ "valueBoolean": false } ] - }, - { - "status": "planned", - "location": { - "reference": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] } ], "type": [ @@ -2673,7 +2532,8 @@ } ], "period": { - "start": "2015-02-08T15:54:19+05:30" + "start": "2015-02-08T15:54:19+05:30", + "end": "2015-02-09T15:54:19+05:30" }, "reasonCode": [ { @@ -3018,6 +2878,7 @@ "id": "a9c75502-d60a-d89b-5912-f046100cd47e", "name": "OT", "mode": "instance", + "description": "OT--201", "physicalType": { "coding": [ { @@ -3032,6 +2893,31 @@ "url": "Location/a9c75502-d60a-d89b-5912-f046100cd47e" } }, + { + "fullUrl": "urn:uuid:55f70355-863d-579a-b4aa-81fcaf3e1fb0", + "resource": { + "resourceType": "Location", + "id": "55f70355-863d-579a-b4aa-81fcaf3e1fb0", + "partOf": { + "reference": "Location/a9c75502-d60a-d89b-5912-f046100cd47e" + }, + "name": "201", + "mode": "instance", + "description": "OT--201", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/55f70355-863d-579a-b4aa-81fcaf3e1fb0" + } + }, { "fullUrl": "urn:uuid:2e2e33a1-60f8-7e38-c827-fe070237c3fb", "resource": { @@ -3987,6 +3873,9 @@ ] } ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, "extension": [ { "url": "http://example.com/v2-to-fhir-converter/Observation_Status", @@ -4356,19 +4245,6 @@ }, "system": "http://www.examplehealthplan.com/fhir/policyidentifier" }, - { - "value": "HMO-12345", - "type": { - "coding": [ - { - "code": "NI", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203", - "display": "National unique individual identifier" - } - ] - }, - "system": "urn:oid:2.16.840.1.113883.1.3" - }, { "value": "Medicare-12345", "type": { diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT-A04-expected-2.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A03/ADT-A03-02-expected.json similarity index 93% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT-A04-expected-2.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A03/ADT-A03-02-expected.json index 3f2b73bf2..a10e0bd8c 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT-A04-expected-2.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A03/ADT-A03-02-expected.json @@ -40,9 +40,9 @@ ] }, "eventCoding": { - "code": "A04", + "code": "A03", "system": "http://terminology.hl7.org/CodeSystem/v2-0003", - "display": "ADT^A04^ADT_A04" + "display": "ADT^A03^ADT_A03" }, "language": "en-US", "sender": { @@ -58,13 +58,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T12:48:40.101Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A04.

" + "div": "

Resource bundle generated on 2021-10-29T11:27:35.836Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A03.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -86,7 +86,7 @@ "activity": { "coding": [ { - "display": "ADT^A04^ADT_A04" + "display": "ADT^A03^ADT_A03" } ] }, @@ -106,7 +106,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { @@ -1155,6 +1155,7 @@ } ], "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1179,6 +1180,7 @@ }, "name": "OMU B", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1203,6 +1205,7 @@ }, "name": "Bed 03", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1224,6 +1227,7 @@ "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", "name": "HOMERTON UNIVER", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1248,6 +1252,7 @@ }, "name": "Homerton UH", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1272,6 +1277,7 @@ }, "name": "Floor5", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1293,6 +1299,7 @@ "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", "name": "4 East, room 136, bed B 4E", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1317,6 +1324,7 @@ }, "name": "136", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1341,6 +1349,7 @@ }, "name": "B", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1362,6 +1371,7 @@ "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", "name": "CommunityHospital", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1409,6 +1419,7 @@ "id": "84634858-74aa-5cdb-4547-60ec27339ac6", "name": "POC", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1433,6 +1444,7 @@ }, "name": "Room-2", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1457,6 +1469,7 @@ }, "name": "Bed-103", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1478,6 +1491,7 @@ "id": "055e10f1-222e-df73-2325-0e4396db1a55", "name": "Greenland", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1499,6 +1513,7 @@ "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", "name": "Nursing home", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1520,6 +1535,7 @@ "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", "name": "Rosewood", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1569,7 +1585,7 @@ "resource": { "resourceType": "EpisodeOfCare", "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", - "status": "planned", + "status": "finished", "identifier": [ { "value": "EOC124", @@ -1607,44 +1623,14 @@ "display": "pre-admission", "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" }, - "status": "planned", + "status": "finished", "location": [ { - "status": "planned", + "status": "completed", "location": { "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, { "status": "completed", "location": { @@ -1657,42 +1643,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "planned", "location": { @@ -1705,42 +1655,6 @@ } ] }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "completed", "location": { @@ -1752,18 +1666,6 @@ "valueBoolean": true } ] - }, - { - "status": "completed", - "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true - } - ] } ], "type": [ @@ -1966,7 +1868,8 @@ } ], "period": { - "start": "2015-02-08T15:54:19+05:30" + "start": "2015-02-08T15:54:19+05:30", + "end": "2015-02-09T15:54:19+05:30" }, "text": { "status": "generated", @@ -2007,7 +1910,7 @@ } ], "activity": { - "text": "ADT^A04^ADT_A04" + "text": "ADT^A03^ADT_A03" }, "location": { "reference": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT-A04-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT-A04-01-expected.json similarity index 95% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT-A04-expected.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT-A04-01-expected.json index ea8a4e526..13f82adb5 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT-A04-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT-A04-01-expected.json @@ -60,13 +60,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T12:50:12.142Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A04.

" + "div": "

Resource bundle generated on 2021-10-29T11:30:18.389Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A04.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -108,7 +108,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { @@ -1649,6 +1649,7 @@ } ], "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1673,6 +1674,7 @@ }, "name": "OMU B", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1697,6 +1699,7 @@ }, "name": "Bed 03", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1718,6 +1721,7 @@ "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", "name": "HOMERTON UNIVER", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1742,6 +1746,7 @@ }, "name": "Homerton UH", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1766,6 +1771,7 @@ }, "name": "Floor5", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1787,6 +1793,7 @@ "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", "name": "4 East, room 136, bed B 4E", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1811,6 +1818,7 @@ }, "name": "136", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1835,6 +1843,7 @@ }, "name": "B", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1856,6 +1865,7 @@ "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", "name": "CommunityHospital", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1903,6 +1913,7 @@ "id": "84634858-74aa-5cdb-4547-60ec27339ac6", "name": "POC", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1927,6 +1938,7 @@ }, "name": "Room-2", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1951,6 +1963,7 @@ }, "name": "Bed-103", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1972,6 +1985,7 @@ "id": "055e10f1-222e-df73-2325-0e4396db1a55", "name": "Greenland", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1993,6 +2007,7 @@ "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", "name": "Nursing home", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -2014,6 +2029,7 @@ "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", "name": "Rosewood", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -2041,6 +2057,7 @@ } ], "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2065,6 +2082,7 @@ }, "name": "BED1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2086,6 +2104,7 @@ "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", "name": "FACILITY1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2110,6 +2129,7 @@ }, "name": "BUILDING1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2134,6 +2154,7 @@ }, "name": "FLOOR1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2183,7 +2204,7 @@ "resource": { "resourceType": "EpisodeOfCare", "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", - "status": "planned", + "status": "active", "identifier": [ { "value": "EOC124", @@ -2238,44 +2259,14 @@ "display": "pre-admission", "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" }, - "status": "planned", + "status": "in-progress", "location": [ { - "status": "planned", + "status": "active", "location": { "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, { "status": "completed", "location": { @@ -2288,42 +2279,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "planned", "location": { @@ -2336,42 +2291,6 @@ } ] }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "completed", "location": { @@ -2384,18 +2303,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true - } - ] - }, { "status": "planned", "location": { @@ -2407,54 +2314,6 @@ "valueBoolean": false } ] - }, - { - "status": "planned", - "location": { - "reference": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] } ], "type": [ @@ -2673,7 +2532,8 @@ } ], "period": { - "start": "2015-02-08T15:54:19+05:30" + "start": "2015-02-08T15:54:19+05:30", + "end": "2015-02-09T15:54:19+05:30" }, "reasonCode": [ { @@ -3018,6 +2878,7 @@ "id": "a9c75502-d60a-d89b-5912-f046100cd47e", "name": "OT", "mode": "instance", + "description": "OT--201", "physicalType": { "coding": [ { @@ -3032,6 +2893,31 @@ "url": "Location/a9c75502-d60a-d89b-5912-f046100cd47e" } }, + { + "fullUrl": "urn:uuid:55f70355-863d-579a-b4aa-81fcaf3e1fb0", + "resource": { + "resourceType": "Location", + "id": "55f70355-863d-579a-b4aa-81fcaf3e1fb0", + "partOf": { + "reference": "Location/a9c75502-d60a-d89b-5912-f046100cd47e" + }, + "name": "201", + "mode": "instance", + "description": "OT--201", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/55f70355-863d-579a-b4aa-81fcaf3e1fb0" + } + }, { "fullUrl": "urn:uuid:2e2e33a1-60f8-7e38-c827-fe070237c3fb", "resource": { @@ -3987,6 +3873,9 @@ ] } ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, "extension": [ { "url": "http://example.com/v2-to-fhir-converter/Observation_Status", @@ -4356,19 +4245,6 @@ }, "system": "http://www.examplehealthplan.com/fhir/policyidentifier" }, - { - "value": "HMO-12345", - "type": { - "coding": [ - { - "code": "NI", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203", - "display": "National unique individual identifier" - } - ] - }, - "system": "urn:oid:2.16.840.1.113883.1.3" - }, { "value": "Medicare-12345", "type": { diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT-A04-02-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT-A04-02-expected.json new file mode 100644 index 000000000..95a539321 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT-A04-02-expected.json @@ -0,0 +1,2312 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "1989-08-18T14:41:00+05:30", + "identifier": { + "value": "MSG00001" + }, + "id": "513a3d06-5e87-6fbc-ad1b-170ab430499f", + "entry": [ + { + "fullUrl": "urn:uuid:b4ca189b-51ae-33df-cbe2-559b4423a321", + "resource": { + "resourceType": "MessageHeader", + "id": "b4ca189b-51ae-33df-cbe2-559b4423a321", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "A04", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "ADT^A04^ADT_A04" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/b4ca189b-51ae-33df-cbe2-559b4423a321" + } + }, + { + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "resource": { + "resourceType": "Provenance", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T11:29:35.836Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A04.

" + }, + "occurredDateTime": "1989-08-18T14:41:00+05:30", + "recorded": "1989-08-18T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "ADT^A04^ADT_A04" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + } + ], + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:503eb873-22fb-8199-ae28-3604ad59fe13", + "resource": { + "resourceType": "Device", + "id": "503eb873-22fb-8199-ae28-3604ad59fe13", + "identifier": [ + { + "value": "ADTApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/VeteranMilitaryStatus", + "valueCodeableConcept": { + "coding": [ + { + "code": "Vet123", + "display": "retired", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ART" + } + ], + "text": "retired" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-animal", + "extension": [ + { + "url": "species", + "valueCodeableConcept": { + "coding": [ + { + "code": "125097000", + "display": "Goat", + "system": "http://snomed.info/sct" + } + ], + "text": "Goat" + } + }, + { + "url": "breed", + "valueCodeableConcept": { + "coding": [ + { + "code": "4880003", + "display": "Beagle", + "system": "http://snomed.info/sct" + } + ], + "text": "Beagle" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-nationality", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "BT", + "display": "Bhutan", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Bhutan" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-importance", + "valueCodeableConcept": { + "coding": [ + { + "code": "VIP", + "display": "Very Important Person", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L", + "version": "v1.1" + }, + { + "code": "IMP", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/DCM", + "version": "v1.2" + } + ], + "text": "Inportant Person" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:11967e28-8dd4-a112-0fdc-377866bf12a0", + "resource": { + "resourceType": "Organization", + "id": "11967e28-8dd4-a112-0fdc-377866bf12a0", + "identifier": [ + { + "value": "t", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-t" + }, + { + "value": "2.16.840.1.113883.19", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + } + }, + { + "fullUrl": "urn:uuid:7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "resource": { + "resourceType": "Organization", + "id": "7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "identifier": [ + { + "value": "AccMng", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMng" + }, + { + "value": "1.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + } + }, + { + "fullUrl": "urn:uuid:0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "resource": { + "resourceType": "Organization", + "id": "0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "identifier": [ + { + "value": "PERSONNELt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSONNELt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + } + }, + { + "fullUrl": "urn:uuid:f6775f99-5279-be04-bf81-0906c81f7443", + "resource": { + "resourceType": "Practitioner", + "id": "f6775f99-5279-be04-bf81-0906c81f7443", + "identifier": [ + { + "value": "1122334", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Alaz", + "given": [ + "Mohammed", + "Mahi" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "fullUrl": "urn:uuid:c613d7b2-525f-8c08-a7ac-b2b91486e257", + "resource": { + "resourceType": "Organization", + "id": "c613d7b2-525f-8c08-a7ac-b2b91486e257", + "identifier": [ + { + "value": "TEST", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TEST" + }, + { + "value": "23.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + } + }, + { + "fullUrl": "urn:uuid:04f8cfc8-62ca-12df-63ce-6304ef577d44", + "resource": { + "resourceType": "Practitioner", + "id": "04f8cfc8-62ca-12df-63ce-6304ef577d44", + "identifier": [ + { + "value": "C006", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + }, + "type": { + "coding": [ + { + "code": "BA", + "display": "Bank Account Number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen" + ], + "prefix": [ + "Dr" + ], + "use": "anonymous" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "fullUrl": "urn:uuid:99edcabd-fbeb-7e25-f823-11da8d8ed342", + "resource": { + "resourceType": "Practitioner", + "id": "99edcabd-fbeb-7e25-f823-11da8d8ed342", + "identifier": [ + { + "value": "C008", + "system": "urn:oid:2.8", + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Condoc", + "given": [ + "leen" + ], + "prefix": [ + "Dr" + ], + "use": "temp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "fullUrl": "urn:uuid:b065b233-8738-f1ec-1314-d61e4aac2c9e", + "resource": { + "resourceType": "Practitioner", + "id": "b065b233-8738-f1ec-1314-d61e4aac2c9e", + "identifier": [ + { + "value": "37", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr", + "type": { + "coding": [ + { + "code": "ANC", + "display": "Account number Creditor", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "DISNEY", + "given": [ + "WALT" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "fullUrl": "urn:uuid:9f974d4f-47e8-21a6-e549-4de4599c3764", + "resource": { + "resourceType": "Organization", + "id": "9f974d4f-47e8-21a6-e549-4de4599c3764", + "identifier": [ + { + "value": "T123", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-T123" + }, + { + "value": "urn:oid:r2.3", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + }, + { + "fullUrl": "urn:uuid:84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "resource": { + "resourceType": "Practitioner", + "id": "84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "identifier": [ + { + "value": "Othhel", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "fullUrl": "urn:uuid:24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "resource": { + "resourceType": "Organization", + "id": "24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "identifier": [ + { + "value": "TE", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TE" + }, + { + "value": "Provider Master.Community Health and Hospitals", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "type": { + "coding": [ + { + "code": "DNS", + "display": "An Internet host name, in accordance with RFC 1035; or an IP address. Either in ASCII or as integers, with periods between components (“dotted” notation).", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + } + }, + { + "fullUrl": "urn:uuid:36e3aaa4-569a-7d9d-037f-27235ed05701", + "resource": { + "resourceType": "Practitioner", + "id": "36e3aaa4-569a-7d9d-037f-27235ed05701", + "identifier": [ + { + "value": "12188", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "assigner": { + "reference": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + }, + "type": { + "coding": [ + { + "code": "DN", + "display": "Doctor number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Hippocrates", + "given": [ + "Harold", + "H" + ], + "suffix": [ + "IV", + "MD" + ], + "prefix": [ + "Dr" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + }, + { + "fullUrl": "urn:uuid:9172e4a0-1ca5-646d-2183-b179f4daa737", + "resource": { + "resourceType": "Location", + "id": "9172e4a0-1ca5-646d-2183-b179f4daa737", + "partOf": { + "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + }, + "name": "HUH AE OMU", + "identifier": [ + { + "value": "urn:oid:9.8", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "fullUrl": "urn:uuid:3913ec4d-6576-5e1a-ac31-e8280583371c", + "resource": { + "resourceType": "Location", + "id": "3913ec4d-6576-5e1a-ac31-e8280583371c", + "partOf": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + }, + "name": "OMU B", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + } + }, + { + "fullUrl": "urn:uuid:804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "resource": { + "resourceType": "Location", + "id": "804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "partOf": { + "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + }, + "name": "Bed 03", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" + } + }, + { + "fullUrl": "urn:uuid:c043880b-0fab-1cb8-14f7-0475282c4d0e", + "resource": { + "resourceType": "Location", + "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", + "name": "HOMERTON UNIVER", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + } + }, + { + "fullUrl": "urn:uuid:f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "resource": { + "resourceType": "Location", + "id": "f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "partOf": { + "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + }, + "name": "Homerton UH", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + } + }, + { + "fullUrl": "urn:uuid:7e38808c-44a8-cb0c-4709-9d6092abc32c", + "resource": { + "resourceType": "Location", + "id": "7e38808c-44a8-cb0c-4709-9d6092abc32c", + "partOf": { + "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + }, + "name": "Floor5", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + } + }, + { + "fullUrl": "urn:uuid:59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "resource": { + "resourceType": "Location", + "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "name": "4 East, room 136, bed B 4E", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + } + }, + { + "fullUrl": "urn:uuid:d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "resource": { + "resourceType": "Location", + "id": "d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "partOf": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "name": "136", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + } + }, + { + "fullUrl": "urn:uuid:5783dafa-c6c0-e673-cca4-42087ee1831b", + "resource": { + "resourceType": "Location", + "id": "5783dafa-c6c0-e673-cca4-42087ee1831b", + "partOf": { + "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + }, + "name": "B", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" + } + }, + { + "fullUrl": "urn:uuid:8b39e6e5-78cd-63ab-2441-f43ca5554096", + "resource": { + "resourceType": "Location", + "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", + "name": "CommunityHospital", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" + } + }, + { + "fullUrl": "urn:uuid:42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "resource": { + "resourceType": "Location", + "id": "42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "name": "Homes", + "identifier": [ + { + "value": "22", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/FDK" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + { + "fullUrl": "urn:uuid:84634858-74aa-5cdb-4547-60ec27339ac6", + "resource": { + "resourceType": "Location", + "id": "84634858-74aa-5cdb-4547-60ec27339ac6", + "name": "POC", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + } + }, + { + "fullUrl": "urn:uuid:9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", + "resource": { + "resourceType": "Location", + "id": "9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", + "partOf": { + "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + }, + "name": "Room-2", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" + } + }, + { + "fullUrl": "urn:uuid:35353f20-6254-e794-98ed-8007490447e3", + "resource": { + "resourceType": "Location", + "id": "35353f20-6254-e794-98ed-8007490447e3", + "partOf": { + "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" + }, + "name": "Bed-103", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/35353f20-6254-e794-98ed-8007490447e3" + } + }, + { + "fullUrl": "urn:uuid:055e10f1-222e-df73-2325-0e4396db1a55", + "resource": { + "resourceType": "Location", + "id": "055e10f1-222e-df73-2325-0e4396db1a55", + "name": "Greenland", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/055e10f1-222e-df73-2325-0e4396db1a55" + } + }, + { + "fullUrl": "urn:uuid:1154e6b2-b022-b3be-7dce-2b940ab5376d", + "resource": { + "resourceType": "Location", + "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", + "name": "Nursing home", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + } + }, + { + "fullUrl": "urn:uuid:08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "resource": { + "resourceType": "Location", + "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "name": "Rosewood", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" + } + }, + { + "fullUrl": "urn:uuid:c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "resource": { + "resourceType": "Location", + "id": "c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "name": "ROOM1", + "identifier": [ + { + "value": "urn:oid:2.16.840.1.113883.4.642.1.1108", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + } + }, + { + "fullUrl": "urn:uuid:6f159848-5f01-01b3-9594-80fbbe9ab510", + "resource": { + "resourceType": "Location", + "id": "6f159848-5f01-01b3-9594-80fbbe9ab510", + "partOf": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "name": "BED1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" + } + }, + { + "fullUrl": "urn:uuid:4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "resource": { + "resourceType": "Location", + "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "name": "FACILITY1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + } + }, + { + "fullUrl": "urn:uuid:3b0911cb-4361-cd8d-b188-463af033c699", + "resource": { + "resourceType": "Location", + "id": "3b0911cb-4361-cd8d-b188-463af033c699", + "partOf": { + "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + }, + "name": "BUILDING1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:08314073-410a-3dc7-512c-0f2d206fb59d", + "resource": { + "resourceType": "Organization", + "id": "08314073-410a-3dc7-512c-0f2d206fb59d", + "identifier": [ + { + "value": "Etest", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-Etest" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + }, + { + "fullUrl": "urn:uuid:919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "resource": { + "resourceType": "EpisodeOfCare", + "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "status": "active", + "identifier": [ + { + "value": "EOC124", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + }, + { + "fullUrl": "urn:uuid:4b192760-03d2-aec4-b0a6-fde323912e1e", + "resource": { + "resourceType": "Encounter", + "id": "4b192760-03d2-aec4-b0a6-fde323912e1e", + "class": { + "code": "PRENC", + "display": "pre-admission", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "in-progress", + "location": [ + { + "status": "active", + "location": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "status": "completed", + "location": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "status": "planned", + "location": { + "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "status": "completed", + "location": { + "reference": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": true + } + ] + }, + { + "status": "planned", + "location": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + } + ], + "type": [ + { + "coding": [ + { + "code": "E", + "display": "Emergency", + "system": "http://terminology.hl7.org/CodeSystem/v2-0007" + } + ] + } + ], + "hospitalization": { + "preAdmissionIdentifier": { + "value": "1234567", + "type": { + "coding": [ + { + "code": "ANON", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Anonymous identifier" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + "reAdmission": { + "coding": [ + { + "code": "R", + "display": "Re-admission", + "system": "http://terminology.hl7.org/CodeSystem/v2-0092" + } + ] + }, + "admitSource": { + "coding": [ + { + "code": "NHS Provider-General (inc.A&E-this Hosp)" + } + ] + }, + "dischargeDisposition": { + "coding": [ + { + "code": "Admitted as Inpatient", + "display": "Sample", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ACR" + } + ] + }, + "dietPreference": [ + { + "coding": [ + { + "code": "Vegan", + "display": "Vegetarian" + } + ] + } + ], + "destination": { + "reference": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + "episodeOfCare": [ + { + "reference": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "CON", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "consultant" + } + ], + "individual": { + "reference": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "ADM", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "admitter" + } + ], + "individual": { + "reference": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "PART", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "Participation" + } + ], + "individual": { + "reference": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + } + ], + "serviceType": { + "coding": [ + { + "code": "SUR" + } + ] + }, + "identifier": [ + { + "value": "40007716", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + }, + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + }, + { + "value": "50", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "urn:oid:r2.3", + "assigner": { + "reference": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + } + ], + "period": { + "start": "2015-02-08T15:54:19+05:30", + "end": "2015-02-09T15:54:19+05:30" + }, + "reasonCode": [ + { + "coding": [ + { + "code": "140004", + "display": "Chronic pharyngitis", + "system": "http://snomed.info/sct" + } + ] + } + ], + "length": { + "value": 2, + "unit": "d", + "system": "http://unitsofmeasure.org/" + }, + "meta": { + "security": [ + { + "code": "N", + "display": "normal", + "system": "http://terminology.hl7.org/CodeSystem/v3-Confidentiality" + } + ] + }, + "text": { + "status": "generated", + "div": "

Visit Description: Health Checkup

" + }, + "priority": { + "coding": [ + { + "code": "UR", + "display": "urgent", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.2" + }, + { + "code": "EL", + "display": "elective", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.3" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/encounter-modeOfArrival", + "valueCoding": { + "code": "C", + "display": "Car", + "system": "http://terminology.hl7.org/CodeSystem/v2-0430" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Encounter/4b192760-03d2-aec4-b0a6-fde323912e1e" + } + }, + { + "fullUrl": "urn:uuid:9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "resource": { + "resourceType": "Provenance", + "id": "9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "occurredDateTime": "2021-08-17T18:49:43.004+05:30", + "recorded": "2029-08-01T11:21:24+05:30", + "reason": [ + { + "coding": [ + { + "code": "PATRQT", + "display": "patient requested", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActReason" + } + ] + } + ], + "agent": [ + { + "who": { + "reference": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + } + ], + "activity": { + "text": "ADT^A04^ADT_A04" + }, + "location": { + "reference": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + }, + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c" + } + }, + { + "fullUrl": "urn:uuid:ef39f581-5e8f-3917-35a9-3443303d9eee", + "resource": { + "resourceType": "Organization", + "id": "ef39f581-5e8f-3917-35a9-3443303d9eee", + "identifier": [ + { + "value": "DRNBR", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-DRNBR" + }, + { + "value": "urn:oid:W1.2", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + } + }, + { + "fullUrl": "urn:uuid:95aea53b-8d49-d57f-d16f-4d14b914f992", + "resource": { + "resourceType": "Practitioner", + "id": "95aea53b-8d49-d57f-d16f-4d14b914f992", + "identifier": [ + { + "value": "C08", + "system": "urn:oid:W1.2", + "assigner": { + "reference": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + }, + "type": { + "coding": [ + { + "code": "ANON", + "display": "Anonymous identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen", + "2ndname" + ], + "suffix": [ + "Jr", + "MD" + ], + "prefix": [ + "Dr" + ], + "use": "official" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + }, + { + "fullUrl": "urn:uuid:59d5e519-0108-5dd8-adfa-1eef5658009e", + "resource": { + "resourceType": "Location", + "id": "59d5e519-0108-5dd8-adfa-1eef5658009e", + "name": "Cona_Health", + "identifier": [ + { + "value": "urn:oid:1.3.6.1.4.1.44750.1.4", + "system": "urn:ietf:rfc:3986" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "display": "site", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT04-23-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT04-23-expected.json index f8747cfea..0e04e628b 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT04-23-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT04-23-expected.json @@ -62,13 +62,13 @@ } }, { - "fullUrl": "urn:uuid:2f736e70-b192-155c-b224-66a1c8102fac", + "fullUrl": "urn:uuid:b8bf5f81-bc6a-5fda-5fb2-fd273ac267a8", "resource": { "resourceType": "Provenance", - "id": "2f736e70-b192-155c-b224-66a1c8102fac", + "id": "b8bf5f81-bc6a-5fda-5fb2-fd273ac267a8", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T12:50:51.504Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A04.

" + "div": "

Resource bundle generated on 2021-10-29T11:30:59.573Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A04.

" }, "occurredDateTime": "2001-01-01T00:00:00", "recorded": "2001-01-01T00:00:00", @@ -102,7 +102,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/2f736e70-b192-155c-b224-66a1c8102fac" + "url": "Provenance/b8bf5f81-bc6a-5fda-5fb2-fd273ac267a8" } }, { @@ -386,6 +386,7 @@ "id": "a0f6171b-0f81-c7fd-61da-2c2db32aafc9", "name": "ABCD", "mode": "instance", + "description": "ABCD--EFGH", "physicalType": { "coding": [ { @@ -410,6 +411,7 @@ }, "name": "EFGH", "mode": "instance", + "description": "ABCD--EFGH", "physicalType": { "coding": [ { @@ -441,9 +443,6 @@ "location": { "reference": "Location/a0f6171b-0f81-c7fd-61da-2c2db32aafc9" } - }, - { - "status": "active" } ], "participant": [ diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT04-251-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT04-251-expected.json index 12d5c751f..a46beccac 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT04-251-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT04-251-expected.json @@ -46,13 +46,13 @@ } }, { - "fullUrl": "urn:uuid:2f44b60d-43f6-3deb-3f3d-3a1041aa219c", + "fullUrl": "urn:uuid:73105c01-0c83-840e-6dbb-9ef4928175f8", "resource": { "resourceType": "Provenance", - "id": "2f44b60d-43f6-3deb-3f3d-3a1041aa219c", + "id": "73105c01-0c83-840e-6dbb-9ef4928175f8", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T12:52:28.121Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A04.

" + "div": "

Resource bundle generated on 2021-10-29T11:32:25.221Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A04.

" }, "occurredDateTime": "2019-05-04T18:12:05", "recorded": "2019-05-04T18:12:05", @@ -86,7 +86,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/2f44b60d-43f6-3deb-3f3d-3a1041aa219c" + "url": "Provenance/73105c01-0c83-840e-6dbb-9ef4928175f8" } }, { diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT04-28-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT04-28-expected.json index 778f6a010..c7f4ea65d 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT04-28-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A04/ADT04-28-expected.json @@ -46,13 +46,13 @@ } }, { - "fullUrl": "urn:uuid:2c3f6df7-9434-e16e-8340-f505268b140b", + "fullUrl": "urn:uuid:312fba25-b9c6-151e-8c0c-45a36f66ed03", "resource": { "resourceType": "Provenance", - "id": "2c3f6df7-9434-e16e-8340-f505268b140b", + "id": "312fba25-b9c6-151e-8c0c-45a36f66ed03", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T12:51:46.188Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A04.

" + "div": "

Resource bundle generated on 2021-10-29T11:31:38.533Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A04.

" }, "occurredDateTime": "2019-05-04T18:12:05", "recorded": "2019-05-04T18:12:05", @@ -86,7 +86,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/2c3f6df7-9434-e16e-8340-f505268b140b" + "url": "Provenance/312fba25-b9c6-151e-8c0c-45a36f66ed03" } }, { @@ -346,6 +346,7 @@ "id": "1d17bd3e-c217-b488-dd0a-b87c0652a3f1", "name": "3N", "mode": "instance", + "description": "3N--136--B--RES General Hospital--Inpatient", "physicalType": { "coding": [ { @@ -370,6 +371,7 @@ }, "name": "136", "mode": "instance", + "description": "3N--136--B--RES General Hospital--Inpatient", "physicalType": { "coding": [ { @@ -394,6 +396,7 @@ }, "name": "B", "mode": "instance", + "description": "3N--136--B--RES General Hospital--Inpatient", "physicalType": { "coding": [ { @@ -415,6 +418,7 @@ "id": "9e9deb57-14b7-3c6a-e9da-3874ac02bb5f", "name": "RES General Hospital", "mode": "instance", + "description": "3N--136--B--RES General Hospital--Inpatient", "physicalType": { "coding": [ { @@ -446,24 +450,6 @@ "location": { "reference": "Location/1d17bd3e-c217-b488-dd0a-b87c0652a3f1" } - }, - { - "status": "active", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - } - }, - { - "status": "active", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - } - }, - { - "status": "active", - "location": { - "reference": "Location/9e9deb57-14b7-3c6a-e9da-3874ac02bb5f" - } } ], "participant": [ diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A05/ADT-A05-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A05/ADT-A05-01-expected.json similarity index 95% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A05/ADT-A05-expected.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A05/ADT-A05-01-expected.json index f1da6eb9b..0ad6fc2ea 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A05/ADT-A05-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A05/ADT-A05-01-expected.json @@ -60,13 +60,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:00:57.179Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A05.

" + "div": "

Resource bundle generated on 2021-10-29T11:33:56.296Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A05.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -108,7 +108,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { @@ -1649,6 +1649,7 @@ } ], "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1673,6 +1674,7 @@ }, "name": "OMU B", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1697,6 +1699,7 @@ }, "name": "Bed 03", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1718,6 +1721,7 @@ "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", "name": "HOMERTON UNIVER", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1742,6 +1746,7 @@ }, "name": "Homerton UH", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1766,6 +1771,7 @@ }, "name": "Floor5", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1787,6 +1793,7 @@ "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", "name": "4 East, room 136, bed B 4E", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1811,6 +1818,7 @@ }, "name": "136", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1835,6 +1843,7 @@ }, "name": "B", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1856,6 +1865,7 @@ "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", "name": "CommunityHospital", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1903,6 +1913,7 @@ "id": "84634858-74aa-5cdb-4547-60ec27339ac6", "name": "POC", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1927,6 +1938,7 @@ }, "name": "Room-2", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1951,6 +1963,7 @@ }, "name": "Bed-103", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1972,6 +1985,7 @@ "id": "055e10f1-222e-df73-2325-0e4396db1a55", "name": "Greenland", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1993,6 +2007,7 @@ "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", "name": "Nursing home", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -2014,6 +2029,7 @@ "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", "name": "Rosewood", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -2041,6 +2057,7 @@ } ], "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2065,6 +2082,7 @@ }, "name": "BED1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2086,6 +2104,7 @@ "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", "name": "FACILITY1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2110,6 +2129,7 @@ }, "name": "BUILDING1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2134,6 +2154,7 @@ }, "name": "FLOOR1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2246,36 +2267,6 @@ "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, { "status": "completed", "location": { @@ -2288,42 +2279,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "planned", "location": { @@ -2336,42 +2291,6 @@ } ] }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "completed", "location": { @@ -2384,18 +2303,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true - } - ] - }, { "status": "planned", "location": { @@ -2407,54 +2314,6 @@ "valueBoolean": false } ] - }, - { - "status": "planned", - "location": { - "reference": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] } ], "type": [ @@ -2673,7 +2532,8 @@ } ], "period": { - "start": "2015-02-08T15:54:19+05:30" + "start": "2015-02-08T15:54:19+05:30", + "end": "2015-02-09T15:54:19+05:30" }, "reasonCode": [ { @@ -3018,6 +2878,7 @@ "id": "a9c75502-d60a-d89b-5912-f046100cd47e", "name": "OT", "mode": "instance", + "description": "OT--201", "physicalType": { "coding": [ { @@ -3032,6 +2893,31 @@ "url": "Location/a9c75502-d60a-d89b-5912-f046100cd47e" } }, + { + "fullUrl": "urn:uuid:55f70355-863d-579a-b4aa-81fcaf3e1fb0", + "resource": { + "resourceType": "Location", + "id": "55f70355-863d-579a-b4aa-81fcaf3e1fb0", + "partOf": { + "reference": "Location/a9c75502-d60a-d89b-5912-f046100cd47e" + }, + "name": "201", + "mode": "instance", + "description": "OT--201", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/55f70355-863d-579a-b4aa-81fcaf3e1fb0" + } + }, { "fullUrl": "urn:uuid:2e2e33a1-60f8-7e38-c827-fe070237c3fb", "resource": { @@ -3987,6 +3873,9 @@ ] } ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, "extension": [ { "url": "http://example.com/v2-to-fhir-converter/Observation_Status", @@ -4356,19 +4245,6 @@ }, "system": "http://www.examplehealthplan.com/fhir/policyidentifier" }, - { - "value": "HMO-12345", - "type": { - "coding": [ - { - "code": "NI", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203", - "display": "National unique individual identifier" - } - ] - }, - "system": "urn:oid:2.16.840.1.113883.1.3" - }, { "value": "Medicare-12345", "type": { diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A05/ADT-A05-02-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A05/ADT-A05-02-expected.json new file mode 100644 index 000000000..4925f7dcf --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A05/ADT-A05-02-expected.json @@ -0,0 +1,2312 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "1989-08-18T14:41:00+05:30", + "identifier": { + "value": "MSG00001" + }, + "id": "513a3d06-5e87-6fbc-ad1b-170ab430499f", + "entry": [ + { + "fullUrl": "urn:uuid:b4ca189b-51ae-33df-cbe2-559b4423a321", + "resource": { + "resourceType": "MessageHeader", + "id": "b4ca189b-51ae-33df-cbe2-559b4423a321", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "A05", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "ADT^A05^ADT_A05" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/b4ca189b-51ae-33df-cbe2-559b4423a321" + } + }, + { + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "resource": { + "resourceType": "Provenance", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T11:33:19.244Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A05.

" + }, + "occurredDateTime": "1989-08-18T14:41:00+05:30", + "recorded": "1989-08-18T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "ADT^A05^ADT_A05" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + } + ], + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:503eb873-22fb-8199-ae28-3604ad59fe13", + "resource": { + "resourceType": "Device", + "id": "503eb873-22fb-8199-ae28-3604ad59fe13", + "identifier": [ + { + "value": "ADTApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/VeteranMilitaryStatus", + "valueCodeableConcept": { + "coding": [ + { + "code": "Vet123", + "display": "retired", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ART" + } + ], + "text": "retired" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-animal", + "extension": [ + { + "url": "species", + "valueCodeableConcept": { + "coding": [ + { + "code": "125097000", + "display": "Goat", + "system": "http://snomed.info/sct" + } + ], + "text": "Goat" + } + }, + { + "url": "breed", + "valueCodeableConcept": { + "coding": [ + { + "code": "4880003", + "display": "Beagle", + "system": "http://snomed.info/sct" + } + ], + "text": "Beagle" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-nationality", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "BT", + "display": "Bhutan", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Bhutan" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-importance", + "valueCodeableConcept": { + "coding": [ + { + "code": "VIP", + "display": "Very Important Person", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L", + "version": "v1.1" + }, + { + "code": "IMP", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/DCM", + "version": "v1.2" + } + ], + "text": "Inportant Person" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:11967e28-8dd4-a112-0fdc-377866bf12a0", + "resource": { + "resourceType": "Organization", + "id": "11967e28-8dd4-a112-0fdc-377866bf12a0", + "identifier": [ + { + "value": "t", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-t" + }, + { + "value": "2.16.840.1.113883.19", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + } + }, + { + "fullUrl": "urn:uuid:7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "resource": { + "resourceType": "Organization", + "id": "7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "identifier": [ + { + "value": "AccMng", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMng" + }, + { + "value": "1.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + } + }, + { + "fullUrl": "urn:uuid:0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "resource": { + "resourceType": "Organization", + "id": "0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "identifier": [ + { + "value": "PERSONNELt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSONNELt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + } + }, + { + "fullUrl": "urn:uuid:f6775f99-5279-be04-bf81-0906c81f7443", + "resource": { + "resourceType": "Practitioner", + "id": "f6775f99-5279-be04-bf81-0906c81f7443", + "identifier": [ + { + "value": "1122334", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Alaz", + "given": [ + "Mohammed", + "Mahi" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "fullUrl": "urn:uuid:c613d7b2-525f-8c08-a7ac-b2b91486e257", + "resource": { + "resourceType": "Organization", + "id": "c613d7b2-525f-8c08-a7ac-b2b91486e257", + "identifier": [ + { + "value": "TEST", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TEST" + }, + { + "value": "23.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + } + }, + { + "fullUrl": "urn:uuid:04f8cfc8-62ca-12df-63ce-6304ef577d44", + "resource": { + "resourceType": "Practitioner", + "id": "04f8cfc8-62ca-12df-63ce-6304ef577d44", + "identifier": [ + { + "value": "C006", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + }, + "type": { + "coding": [ + { + "code": "BA", + "display": "Bank Account Number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen" + ], + "prefix": [ + "Dr" + ], + "use": "anonymous" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "fullUrl": "urn:uuid:99edcabd-fbeb-7e25-f823-11da8d8ed342", + "resource": { + "resourceType": "Practitioner", + "id": "99edcabd-fbeb-7e25-f823-11da8d8ed342", + "identifier": [ + { + "value": "C008", + "system": "urn:oid:2.8", + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Condoc", + "given": [ + "leen" + ], + "prefix": [ + "Dr" + ], + "use": "temp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "fullUrl": "urn:uuid:b065b233-8738-f1ec-1314-d61e4aac2c9e", + "resource": { + "resourceType": "Practitioner", + "id": "b065b233-8738-f1ec-1314-d61e4aac2c9e", + "identifier": [ + { + "value": "37", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr", + "type": { + "coding": [ + { + "code": "ANC", + "display": "Account number Creditor", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "DISNEY", + "given": [ + "WALT" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "fullUrl": "urn:uuid:9f974d4f-47e8-21a6-e549-4de4599c3764", + "resource": { + "resourceType": "Organization", + "id": "9f974d4f-47e8-21a6-e549-4de4599c3764", + "identifier": [ + { + "value": "T123", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-T123" + }, + { + "value": "urn:oid:r2.3", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + }, + { + "fullUrl": "urn:uuid:84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "resource": { + "resourceType": "Practitioner", + "id": "84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "identifier": [ + { + "value": "Othhel", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "fullUrl": "urn:uuid:24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "resource": { + "resourceType": "Organization", + "id": "24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "identifier": [ + { + "value": "TE", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TE" + }, + { + "value": "Provider Master.Community Health and Hospitals", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "type": { + "coding": [ + { + "code": "DNS", + "display": "An Internet host name, in accordance with RFC 1035; or an IP address. Either in ASCII or as integers, with periods between components (“dotted” notation).", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + } + }, + { + "fullUrl": "urn:uuid:36e3aaa4-569a-7d9d-037f-27235ed05701", + "resource": { + "resourceType": "Practitioner", + "id": "36e3aaa4-569a-7d9d-037f-27235ed05701", + "identifier": [ + { + "value": "12188", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "assigner": { + "reference": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + }, + "type": { + "coding": [ + { + "code": "DN", + "display": "Doctor number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Hippocrates", + "given": [ + "Harold", + "H" + ], + "suffix": [ + "IV", + "MD" + ], + "prefix": [ + "Dr" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + }, + { + "fullUrl": "urn:uuid:9172e4a0-1ca5-646d-2183-b179f4daa737", + "resource": { + "resourceType": "Location", + "id": "9172e4a0-1ca5-646d-2183-b179f4daa737", + "partOf": { + "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + }, + "name": "HUH AE OMU", + "identifier": [ + { + "value": "urn:oid:9.8", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "fullUrl": "urn:uuid:3913ec4d-6576-5e1a-ac31-e8280583371c", + "resource": { + "resourceType": "Location", + "id": "3913ec4d-6576-5e1a-ac31-e8280583371c", + "partOf": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + }, + "name": "OMU B", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + } + }, + { + "fullUrl": "urn:uuid:804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "resource": { + "resourceType": "Location", + "id": "804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "partOf": { + "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + }, + "name": "Bed 03", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" + } + }, + { + "fullUrl": "urn:uuid:c043880b-0fab-1cb8-14f7-0475282c4d0e", + "resource": { + "resourceType": "Location", + "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", + "name": "HOMERTON UNIVER", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + } + }, + { + "fullUrl": "urn:uuid:f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "resource": { + "resourceType": "Location", + "id": "f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "partOf": { + "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + }, + "name": "Homerton UH", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + } + }, + { + "fullUrl": "urn:uuid:7e38808c-44a8-cb0c-4709-9d6092abc32c", + "resource": { + "resourceType": "Location", + "id": "7e38808c-44a8-cb0c-4709-9d6092abc32c", + "partOf": { + "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + }, + "name": "Floor5", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + } + }, + { + "fullUrl": "urn:uuid:59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "resource": { + "resourceType": "Location", + "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "name": "4 East, room 136, bed B 4E", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + } + }, + { + "fullUrl": "urn:uuid:d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "resource": { + "resourceType": "Location", + "id": "d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "partOf": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "name": "136", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + } + }, + { + "fullUrl": "urn:uuid:5783dafa-c6c0-e673-cca4-42087ee1831b", + "resource": { + "resourceType": "Location", + "id": "5783dafa-c6c0-e673-cca4-42087ee1831b", + "partOf": { + "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + }, + "name": "B", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" + } + }, + { + "fullUrl": "urn:uuid:8b39e6e5-78cd-63ab-2441-f43ca5554096", + "resource": { + "resourceType": "Location", + "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", + "name": "CommunityHospital", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" + } + }, + { + "fullUrl": "urn:uuid:42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "resource": { + "resourceType": "Location", + "id": "42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "name": "Homes", + "identifier": [ + { + "value": "22", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/FDK" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + { + "fullUrl": "urn:uuid:84634858-74aa-5cdb-4547-60ec27339ac6", + "resource": { + "resourceType": "Location", + "id": "84634858-74aa-5cdb-4547-60ec27339ac6", + "name": "POC", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + } + }, + { + "fullUrl": "urn:uuid:9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", + "resource": { + "resourceType": "Location", + "id": "9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", + "partOf": { + "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + }, + "name": "Room-2", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" + } + }, + { + "fullUrl": "urn:uuid:35353f20-6254-e794-98ed-8007490447e3", + "resource": { + "resourceType": "Location", + "id": "35353f20-6254-e794-98ed-8007490447e3", + "partOf": { + "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" + }, + "name": "Bed-103", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/35353f20-6254-e794-98ed-8007490447e3" + } + }, + { + "fullUrl": "urn:uuid:055e10f1-222e-df73-2325-0e4396db1a55", + "resource": { + "resourceType": "Location", + "id": "055e10f1-222e-df73-2325-0e4396db1a55", + "name": "Greenland", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/055e10f1-222e-df73-2325-0e4396db1a55" + } + }, + { + "fullUrl": "urn:uuid:1154e6b2-b022-b3be-7dce-2b940ab5376d", + "resource": { + "resourceType": "Location", + "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", + "name": "Nursing home", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + } + }, + { + "fullUrl": "urn:uuid:08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "resource": { + "resourceType": "Location", + "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "name": "Rosewood", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" + } + }, + { + "fullUrl": "urn:uuid:c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "resource": { + "resourceType": "Location", + "id": "c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "name": "ROOM1", + "identifier": [ + { + "value": "urn:oid:2.16.840.1.113883.4.642.1.1108", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + } + }, + { + "fullUrl": "urn:uuid:6f159848-5f01-01b3-9594-80fbbe9ab510", + "resource": { + "resourceType": "Location", + "id": "6f159848-5f01-01b3-9594-80fbbe9ab510", + "partOf": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "name": "BED1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" + } + }, + { + "fullUrl": "urn:uuid:4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "resource": { + "resourceType": "Location", + "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "name": "FACILITY1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + } + }, + { + "fullUrl": "urn:uuid:3b0911cb-4361-cd8d-b188-463af033c699", + "resource": { + "resourceType": "Location", + "id": "3b0911cb-4361-cd8d-b188-463af033c699", + "partOf": { + "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + }, + "name": "BUILDING1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:08314073-410a-3dc7-512c-0f2d206fb59d", + "resource": { + "resourceType": "Organization", + "id": "08314073-410a-3dc7-512c-0f2d206fb59d", + "identifier": [ + { + "value": "Etest", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-Etest" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + }, + { + "fullUrl": "urn:uuid:919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "resource": { + "resourceType": "EpisodeOfCare", + "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "status": "planned", + "identifier": [ + { + "value": "EOC124", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + }, + { + "fullUrl": "urn:uuid:4b192760-03d2-aec4-b0a6-fde323912e1e", + "resource": { + "resourceType": "Encounter", + "id": "4b192760-03d2-aec4-b0a6-fde323912e1e", + "class": { + "code": "PRENC", + "display": "pre-admission", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "planned", + "location": [ + { + "status": "planned", + "location": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "status": "completed", + "location": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "status": "planned", + "location": { + "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "status": "completed", + "location": { + "reference": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": true + } + ] + }, + { + "status": "planned", + "location": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + } + ], + "type": [ + { + "coding": [ + { + "code": "E", + "display": "Emergency", + "system": "http://terminology.hl7.org/CodeSystem/v2-0007" + } + ] + } + ], + "hospitalization": { + "preAdmissionIdentifier": { + "value": "1234567", + "type": { + "coding": [ + { + "code": "ANON", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Anonymous identifier" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + "reAdmission": { + "coding": [ + { + "code": "R", + "display": "Re-admission", + "system": "http://terminology.hl7.org/CodeSystem/v2-0092" + } + ] + }, + "admitSource": { + "coding": [ + { + "code": "NHS Provider-General (inc.A&E-this Hosp)" + } + ] + }, + "dischargeDisposition": { + "coding": [ + { + "code": "Admitted as Inpatient", + "display": "Sample", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ACR" + } + ] + }, + "dietPreference": [ + { + "coding": [ + { + "code": "Vegan", + "display": "Vegetarian" + } + ] + } + ], + "destination": { + "reference": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + "episodeOfCare": [ + { + "reference": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "CON", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "consultant" + } + ], + "individual": { + "reference": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "ADM", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "admitter" + } + ], + "individual": { + "reference": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "PART", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "Participation" + } + ], + "individual": { + "reference": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + } + ], + "serviceType": { + "coding": [ + { + "code": "SUR" + } + ] + }, + "identifier": [ + { + "value": "40007716", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + }, + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + }, + { + "value": "50", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "urn:oid:r2.3", + "assigner": { + "reference": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + } + ], + "period": { + "start": "2015-02-08T15:54:19+05:30", + "end": "2015-02-09T15:54:19+05:30" + }, + "reasonCode": [ + { + "coding": [ + { + "code": "140004", + "display": "Chronic pharyngitis", + "system": "http://snomed.info/sct" + } + ] + } + ], + "length": { + "value": 2, + "unit": "d", + "system": "http://unitsofmeasure.org/" + }, + "meta": { + "security": [ + { + "code": "N", + "display": "normal", + "system": "http://terminology.hl7.org/CodeSystem/v3-Confidentiality" + } + ] + }, + "text": { + "status": "generated", + "div": "

Visit Description: Health Checkup

" + }, + "priority": { + "coding": [ + { + "code": "UR", + "display": "urgent", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.2" + }, + { + "code": "EL", + "display": "elective", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.3" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/encounter-modeOfArrival", + "valueCoding": { + "code": "C", + "display": "Car", + "system": "http://terminology.hl7.org/CodeSystem/v2-0430" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Encounter/4b192760-03d2-aec4-b0a6-fde323912e1e" + } + }, + { + "fullUrl": "urn:uuid:9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "resource": { + "resourceType": "Provenance", + "id": "9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "occurredDateTime": "2021-08-17T18:49:43.004+05:30", + "recorded": "2029-08-01T11:21:24+05:30", + "reason": [ + { + "coding": [ + { + "code": "PATRQT", + "display": "patient requested", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActReason" + } + ] + } + ], + "agent": [ + { + "who": { + "reference": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + } + ], + "activity": { + "text": "ADT^A05^ADT_A05" + }, + "location": { + "reference": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + }, + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c" + } + }, + { + "fullUrl": "urn:uuid:ef39f581-5e8f-3917-35a9-3443303d9eee", + "resource": { + "resourceType": "Organization", + "id": "ef39f581-5e8f-3917-35a9-3443303d9eee", + "identifier": [ + { + "value": "DRNBR", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-DRNBR" + }, + { + "value": "urn:oid:W1.2", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + } + }, + { + "fullUrl": "urn:uuid:95aea53b-8d49-d57f-d16f-4d14b914f992", + "resource": { + "resourceType": "Practitioner", + "id": "95aea53b-8d49-d57f-d16f-4d14b914f992", + "identifier": [ + { + "value": "C08", + "system": "urn:oid:W1.2", + "assigner": { + "reference": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + }, + "type": { + "coding": [ + { + "code": "ANON", + "display": "Anonymous identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen", + "2ndname" + ], + "suffix": [ + "Jr", + "MD" + ], + "prefix": [ + "Dr" + ], + "use": "official" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + }, + { + "fullUrl": "urn:uuid:59d5e519-0108-5dd8-adfa-1eef5658009e", + "resource": { + "resourceType": "Location", + "id": "59d5e519-0108-5dd8-adfa-1eef5658009e", + "name": "Cona_Health", + "identifier": [ + { + "value": "urn:oid:1.3.6.1.4.1.44750.1.4", + "system": "urn:ietf:rfc:3986" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "display": "site", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A08/ADT-A08-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A08/ADT-A08-01-expected.json similarity index 95% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A08/ADT-A08-expected.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A08/ADT-A08-01-expected.json index 0e5ab8b05..5b184c455 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A08/ADT-A08-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A08/ADT-A08-01-expected.json @@ -60,13 +60,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:17:21.058Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A08.

" + "div": "

Resource bundle generated on 2021-10-29T11:36:54.894Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A08.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -108,7 +108,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { @@ -1649,6 +1649,7 @@ } ], "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1673,6 +1674,7 @@ }, "name": "OMU B", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1697,6 +1699,7 @@ }, "name": "Bed 03", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1718,6 +1721,7 @@ "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", "name": "HOMERTON UNIVER", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1742,6 +1746,7 @@ }, "name": "Homerton UH", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1766,6 +1771,7 @@ }, "name": "Floor5", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1787,6 +1793,7 @@ "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", "name": "4 East, room 136, bed B 4E", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1811,6 +1818,7 @@ }, "name": "136", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1835,6 +1843,7 @@ }, "name": "B", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1856,6 +1865,7 @@ "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", "name": "CommunityHospital", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1903,6 +1913,7 @@ "id": "84634858-74aa-5cdb-4547-60ec27339ac6", "name": "POC", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1927,6 +1938,7 @@ }, "name": "Room-2", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1951,6 +1963,7 @@ }, "name": "Bed-103", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1972,6 +1985,7 @@ "id": "055e10f1-222e-df73-2325-0e4396db1a55", "name": "Greenland", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1993,6 +2007,7 @@ "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", "name": "Nursing home", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -2014,6 +2029,7 @@ "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", "name": "Rosewood", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -2041,6 +2057,7 @@ } ], "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2065,6 +2082,7 @@ }, "name": "BED1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2086,6 +2104,7 @@ "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", "name": "FACILITY1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2110,6 +2129,7 @@ }, "name": "BUILDING1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2134,6 +2154,7 @@ }, "name": "FLOOR1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2183,7 +2204,7 @@ "resource": { "resourceType": "EpisodeOfCare", "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", - "status": "planned", + "status": "finished", "identifier": [ { "value": "EOC124", @@ -2238,7 +2259,7 @@ "display": "pre-admission", "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" }, - "status": "planned", + "status": "finished", "location": [ { "status": "planned", @@ -2246,36 +2267,6 @@ "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, { "status": "completed", "location": { @@ -2288,42 +2279,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "planned", "location": { @@ -2336,42 +2291,6 @@ } ] }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "completed", "location": { @@ -2384,18 +2303,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true - } - ] - }, { "status": "planned", "location": { @@ -2407,54 +2314,6 @@ "valueBoolean": false } ] - }, - { - "status": "planned", - "location": { - "reference": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] } ], "type": [ @@ -2673,7 +2532,8 @@ } ], "period": { - "start": "2015-02-08T15:54:19+05:30" + "start": "2015-02-08T15:54:19+05:30", + "end": "2015-02-09T15:54:19+05:30" }, "reasonCode": [ { @@ -3018,6 +2878,7 @@ "id": "a9c75502-d60a-d89b-5912-f046100cd47e", "name": "OT", "mode": "instance", + "description": "OT--201", "physicalType": { "coding": [ { @@ -3032,6 +2893,31 @@ "url": "Location/a9c75502-d60a-d89b-5912-f046100cd47e" } }, + { + "fullUrl": "urn:uuid:55f70355-863d-579a-b4aa-81fcaf3e1fb0", + "resource": { + "resourceType": "Location", + "id": "55f70355-863d-579a-b4aa-81fcaf3e1fb0", + "partOf": { + "reference": "Location/a9c75502-d60a-d89b-5912-f046100cd47e" + }, + "name": "201", + "mode": "instance", + "description": "OT--201", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/55f70355-863d-579a-b4aa-81fcaf3e1fb0" + } + }, { "fullUrl": "urn:uuid:2e2e33a1-60f8-7e38-c827-fe070237c3fb", "resource": { @@ -3987,6 +3873,9 @@ ] } ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, "extension": [ { "url": "http://example.com/v2-to-fhir-converter/Observation_Status", @@ -4356,19 +4245,6 @@ }, "system": "http://www.examplehealthplan.com/fhir/policyidentifier" }, - { - "value": "HMO-12345", - "type": { - "coding": [ - { - "code": "NI", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203", - "display": "National unique individual identifier" - } - ] - }, - "system": "urn:oid:2.16.840.1.113883.1.3" - }, { "value": "Medicare-12345", "type": { diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A08/ADT-A08-expected-2.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A08/ADT-A08-02-expected.json similarity index 93% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A08/ADT-A08-expected-2.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A08/ADT-A08-02-expected.json index 77526fb11..0c69fe14e 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A08/ADT-A08-expected-2.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A08/ADT-A08-02-expected.json @@ -58,13 +58,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:01:37.828Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A08.

" + "div": "

Resource bundle generated on 2021-10-29T11:35:16.349Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A08.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -106,7 +106,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { @@ -1155,6 +1155,7 @@ } ], "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1179,6 +1180,7 @@ }, "name": "OMU B", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1203,6 +1205,7 @@ }, "name": "Bed 03", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1224,6 +1227,7 @@ "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", "name": "HOMERTON UNIVER", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1248,6 +1252,7 @@ }, "name": "Homerton UH", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1272,6 +1277,7 @@ }, "name": "Floor5", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1293,6 +1299,7 @@ "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", "name": "4 East, room 136, bed B 4E", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1317,6 +1324,7 @@ }, "name": "136", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1341,6 +1349,7 @@ }, "name": "B", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1362,6 +1371,7 @@ "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", "name": "CommunityHospital", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1409,6 +1419,7 @@ "id": "84634858-74aa-5cdb-4547-60ec27339ac6", "name": "POC", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1433,6 +1444,7 @@ }, "name": "Room-2", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1457,6 +1469,7 @@ }, "name": "Bed-103", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1478,6 +1491,7 @@ "id": "055e10f1-222e-df73-2325-0e4396db1a55", "name": "Greenland", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1499,6 +1513,7 @@ "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", "name": "Nursing home", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1520,6 +1535,7 @@ "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", "name": "Rosewood", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1615,36 +1631,6 @@ "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, { "status": "completed", "location": { @@ -1657,42 +1643,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "planned", "location": { @@ -1705,42 +1655,6 @@ } ] }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "completed", "location": { @@ -1752,18 +1666,6 @@ "valueBoolean": true } ] - }, - { - "status": "completed", - "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true - } - ] } ], "type": [ diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A11/ADT-A11-01-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A11/ADT-A11-01-expected.json new file mode 100644 index 000000000..00efa420c --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A11/ADT-A11-01-expected.json @@ -0,0 +1,2886 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "1989-08-18T14:41:00+05:30", + "identifier": { + "value": "MSG00001" + }, + "id": "513a3d06-5e87-6fbc-ad1b-170ab430499f", + "entry": [ + { + "fullUrl": "urn:uuid:b4ca189b-51ae-33df-cbe2-559b4423a321", + "resource": { + "resourceType": "MessageHeader", + "id": "b4ca189b-51ae-33df-cbe2-559b4423a321", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20", + "version": "2.4.3.52854", + "software": "Rhapsody" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "A11", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "ADT^A11^ADT_A11" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/b4ca189b-51ae-33df-cbe2-559b4423a321" + } + }, + { + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "resource": { + "resourceType": "Provenance", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T11:39:19.01Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A11.

" + }, + "occurredDateTime": "1989-08-18T14:41:00+05:30", + "recorded": "1989-08-18T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "ADT^A11^ADT_A11" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + } + ], + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:503eb873-22fb-8199-ae28-3604ad59fe13", + "resource": { + "resourceType": "Device", + "id": "503eb873-22fb-8199-ae28-3604ad59fe13", + "identifier": [ + { + "value": "ADTApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + }, + { + "fullUrl": "urn:uuid:4b549918-a84d-cdaf-e150-c773a5d306e5", + "resource": { + "resourceType": "Device", + "id": "4b549918-a84d-cdaf-e150-c773a5d306e5", + "manufacturer": "Orion", + "deviceName": [ + { + "name": "Rhapsody", + "type": "manufacturer-name" + } + ], + "version": [ + { + "value": "2.4.3.52854" + } + ], + "modelNumber": "2.4.3", + "note": [ + { + "text": "Testactivity" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/4b549918-a84d-cdaf-e150-c773a5d306e5" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + }, + { + "value": "DB123", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "urn:oid:1.12", + "assigner": { + "reference": "Organization/4e68b44e-c053-02b1-6d6d-fe816f9fdfec" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "generalPractitioner": [ + { + "reference": "Organization/4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11" + }, + { + "reference": "Practitioner/76aaad38-1077-6a5c-0c5c-102ec160a60d" + } + ], + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/VeteranMilitaryStatus", + "valueCodeableConcept": { + "coding": [ + { + "code": "Vet123", + "display": "retired", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ART" + } + ], + "text": "retired" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-animal", + "extension": [ + { + "url": "species", + "valueCodeableConcept": { + "coding": [ + { + "code": "125097000", + "display": "Goat", + "system": "http://snomed.info/sct" + } + ], + "text": "Goat" + } + }, + { + "url": "breed", + "valueCodeableConcept": { + "coding": [ + { + "code": "4880003", + "display": "Beagle", + "system": "http://snomed.info/sct" + } + ], + "text": "Beagle" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-nationality", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "BT", + "display": "Bhutan", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Bhutan" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-congregation", + "valueString": "Methodist Church" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-importance", + "valueCodeableConcept": { + "coding": [ + { + "code": "VIP", + "display": "Very Important Person", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L", + "version": "v1.1" + }, + { + "code": "IMP", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/DCM", + "version": "v1.2" + } + ], + "text": "Inportant Person" + } + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/patient-disabilityIndicator", + "valueBoolean": true + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/DisabilityPeriod", + "valuePeriod": { + "start": "2021-08-30", + "end": "2021-09-30" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11", + "resource": { + "resourceType": "Organization", + "id": "4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11", + "name": "LINDAS TEST ORGANIZATION", + "identifier": [ + { + "value": "SIISCLIENT818" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11" + } + }, + { + "fullUrl": "urn:uuid:76aaad38-1077-6a5c-0c5c-102ec160a60d", + "resource": { + "resourceType": "Practitioner", + "id": "76aaad38-1077-6a5c-0c5c-102ec160a60d", + "identifier": [ + { + "value": "88", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TE", + "type": { + "coding": [ + { + "code": "DN", + "display": "Doctor number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Hippo", + "given": [ + "rold", + "H" + ], + "suffix": [ + "V", + "MD" + ], + "prefix": [ + "Dr" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/76aaad38-1077-6a5c-0c5c-102ec160a60d" + } + }, + { + "fullUrl": "urn:uuid:11967e28-8dd4-a112-0fdc-377866bf12a0", + "resource": { + "resourceType": "Organization", + "id": "11967e28-8dd4-a112-0fdc-377866bf12a0", + "identifier": [ + { + "value": "t", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-t" + }, + { + "value": "2.16.840.1.113883.19", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + } + }, + { + "fullUrl": "urn:uuid:7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "resource": { + "resourceType": "Organization", + "id": "7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "identifier": [ + { + "value": "AccMng", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMng" + }, + { + "value": "1.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + } + }, + { + "fullUrl": "urn:uuid:0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "resource": { + "resourceType": "Organization", + "id": "0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "identifier": [ + { + "value": "PERSONNELt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSONNELt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + } + }, + { + "fullUrl": "urn:uuid:f6775f99-5279-be04-bf81-0906c81f7443", + "resource": { + "resourceType": "Practitioner", + "id": "f6775f99-5279-be04-bf81-0906c81f7443", + "identifier": [ + { + "value": "1122334", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Alaz", + "given": [ + "Mohammed", + "Mahi" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "fullUrl": "urn:uuid:c613d7b2-525f-8c08-a7ac-b2b91486e257", + "resource": { + "resourceType": "Organization", + "id": "c613d7b2-525f-8c08-a7ac-b2b91486e257", + "identifier": [ + { + "value": "TEST", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TEST" + }, + { + "value": "23.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + } + }, + { + "fullUrl": "urn:uuid:04f8cfc8-62ca-12df-63ce-6304ef577d44", + "resource": { + "resourceType": "Practitioner", + "id": "04f8cfc8-62ca-12df-63ce-6304ef577d44", + "identifier": [ + { + "value": "C006", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + }, + "type": { + "coding": [ + { + "code": "BA", + "display": "Bank Account Number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen" + ], + "prefix": [ + "Dr" + ], + "use": "anonymous" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "fullUrl": "urn:uuid:99edcabd-fbeb-7e25-f823-11da8d8ed342", + "resource": { + "resourceType": "Practitioner", + "id": "99edcabd-fbeb-7e25-f823-11da8d8ed342", + "identifier": [ + { + "value": "C008", + "system": "urn:oid:2.8", + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Condoc", + "given": [ + "leen" + ], + "prefix": [ + "Dr" + ], + "use": "temp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "fullUrl": "urn:uuid:b065b233-8738-f1ec-1314-d61e4aac2c9e", + "resource": { + "resourceType": "Practitioner", + "id": "b065b233-8738-f1ec-1314-d61e4aac2c9e", + "identifier": [ + { + "value": "37", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr", + "type": { + "coding": [ + { + "code": "ANC", + "display": "Account number Creditor", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "DISNEY", + "given": [ + "WALT" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "fullUrl": "urn:uuid:9f974d4f-47e8-21a6-e549-4de4599c3764", + "resource": { + "resourceType": "Organization", + "id": "9f974d4f-47e8-21a6-e549-4de4599c3764", + "identifier": [ + { + "value": "T123", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-T123" + }, + { + "value": "urn:oid:r2.3", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + }, + { + "fullUrl": "urn:uuid:84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "resource": { + "resourceType": "Practitioner", + "id": "84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "identifier": [ + { + "value": "Othhel", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "fullUrl": "urn:uuid:24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "resource": { + "resourceType": "Organization", + "id": "24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "identifier": [ + { + "value": "TE", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TE" + }, + { + "value": "Provider Master.Community Health and Hospitals", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "type": { + "coding": [ + { + "code": "DNS", + "display": "An Internet host name, in accordance with RFC 1035; or an IP address. Either in ASCII or as integers, with periods between components (“dotted” notation).", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + } + }, + { + "fullUrl": "urn:uuid:36e3aaa4-569a-7d9d-037f-27235ed05701", + "resource": { + "resourceType": "Practitioner", + "id": "36e3aaa4-569a-7d9d-037f-27235ed05701", + "identifier": [ + { + "value": "12188", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "assigner": { + "reference": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + }, + "type": { + "coding": [ + { + "code": "DN", + "display": "Doctor number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Hippocrates", + "given": [ + "Harold", + "H" + ], + "suffix": [ + "IV", + "MD" + ], + "prefix": [ + "Dr" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + }, + { + "fullUrl": "urn:uuid:9172e4a0-1ca5-646d-2183-b179f4daa737", + "resource": { + "resourceType": "Location", + "id": "9172e4a0-1ca5-646d-2183-b179f4daa737", + "partOf": { + "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + }, + "name": "HUH AE OMU", + "identifier": [ + { + "value": "urn:oid:9.8", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "fullUrl": "urn:uuid:3913ec4d-6576-5e1a-ac31-e8280583371c", + "resource": { + "resourceType": "Location", + "id": "3913ec4d-6576-5e1a-ac31-e8280583371c", + "partOf": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + }, + "name": "OMU B", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + } + }, + { + "fullUrl": "urn:uuid:804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "resource": { + "resourceType": "Location", + "id": "804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "partOf": { + "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + }, + "name": "Bed 03", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" + } + }, + { + "fullUrl": "urn:uuid:c043880b-0fab-1cb8-14f7-0475282c4d0e", + "resource": { + "resourceType": "Location", + "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", + "name": "HOMERTON UNIVER", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + } + }, + { + "fullUrl": "urn:uuid:f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "resource": { + "resourceType": "Location", + "id": "f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "partOf": { + "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + }, + "name": "Homerton UH", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + } + }, + { + "fullUrl": "urn:uuid:7e38808c-44a8-cb0c-4709-9d6092abc32c", + "resource": { + "resourceType": "Location", + "id": "7e38808c-44a8-cb0c-4709-9d6092abc32c", + "partOf": { + "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + }, + "name": "Floor5", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + } + }, + { + "fullUrl": "urn:uuid:59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "resource": { + "resourceType": "Location", + "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "name": "4 East, room 136, bed B 4E", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + } + }, + { + "fullUrl": "urn:uuid:d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "resource": { + "resourceType": "Location", + "id": "d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "partOf": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "name": "136", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + } + }, + { + "fullUrl": "urn:uuid:5783dafa-c6c0-e673-cca4-42087ee1831b", + "resource": { + "resourceType": "Location", + "id": "5783dafa-c6c0-e673-cca4-42087ee1831b", + "partOf": { + "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + }, + "name": "B", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" + } + }, + { + "fullUrl": "urn:uuid:8b39e6e5-78cd-63ab-2441-f43ca5554096", + "resource": { + "resourceType": "Location", + "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", + "name": "CommunityHospital", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" + } + }, + { + "fullUrl": "urn:uuid:42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "resource": { + "resourceType": "Location", + "id": "42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "name": "Homes", + "identifier": [ + { + "value": "22", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/FDK" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + { + "fullUrl": "urn:uuid:84634858-74aa-5cdb-4547-60ec27339ac6", + "resource": { + "resourceType": "Location", + "id": "84634858-74aa-5cdb-4547-60ec27339ac6", + "name": "POC", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + } + }, + { + "fullUrl": "urn:uuid:9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", + "resource": { + "resourceType": "Location", + "id": "9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", + "partOf": { + "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + }, + "name": "Room-2", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" + } + }, + { + "fullUrl": "urn:uuid:35353f20-6254-e794-98ed-8007490447e3", + "resource": { + "resourceType": "Location", + "id": "35353f20-6254-e794-98ed-8007490447e3", + "partOf": { + "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" + }, + "name": "Bed-103", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/35353f20-6254-e794-98ed-8007490447e3" + } + }, + { + "fullUrl": "urn:uuid:055e10f1-222e-df73-2325-0e4396db1a55", + "resource": { + "resourceType": "Location", + "id": "055e10f1-222e-df73-2325-0e4396db1a55", + "name": "Greenland", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/055e10f1-222e-df73-2325-0e4396db1a55" + } + }, + { + "fullUrl": "urn:uuid:1154e6b2-b022-b3be-7dce-2b940ab5376d", + "resource": { + "resourceType": "Location", + "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", + "name": "Nursing home", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + } + }, + { + "fullUrl": "urn:uuid:08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "resource": { + "resourceType": "Location", + "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "name": "Rosewood", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" + } + }, + { + "fullUrl": "urn:uuid:c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "resource": { + "resourceType": "Location", + "id": "c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "name": "ROOM1", + "identifier": [ + { + "value": "urn:oid:2.16.840.1.113883.4.642.1.1108", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + } + }, + { + "fullUrl": "urn:uuid:6f159848-5f01-01b3-9594-80fbbe9ab510", + "resource": { + "resourceType": "Location", + "id": "6f159848-5f01-01b3-9594-80fbbe9ab510", + "partOf": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "name": "BED1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" + } + }, + { + "fullUrl": "urn:uuid:4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "resource": { + "resourceType": "Location", + "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "name": "FACILITY1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + } + }, + { + "fullUrl": "urn:uuid:3b0911cb-4361-cd8d-b188-463af033c699", + "resource": { + "resourceType": "Location", + "id": "3b0911cb-4361-cd8d-b188-463af033c699", + "partOf": { + "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + }, + "name": "BUILDING1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:08314073-410a-3dc7-512c-0f2d206fb59d", + "resource": { + "resourceType": "Organization", + "id": "08314073-410a-3dc7-512c-0f2d206fb59d", + "identifier": [ + { + "value": "Etest", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-Etest" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + }, + { + "fullUrl": "urn:uuid:919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "resource": { + "resourceType": "EpisodeOfCare", + "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "status": "cancelled", + "identifier": [ + { + "value": "EOC124", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + }, + { + "fullUrl": "urn:uuid:4b192760-03d2-aec4-b0a6-fde323912e1e", + "resource": { + "resourceType": "Encounter", + "id": "4b192760-03d2-aec4-b0a6-fde323912e1e", + "class": { + "code": "PRENC", + "display": "pre-admission", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "cancelled", + "location": [ + { + "location": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "location": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "location": { + "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "location": { + "reference": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": true + } + ] + }, + { + "location": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + } + ], + "type": [ + { + "coding": [ + { + "code": "E", + "display": "Emergency", + "system": "http://terminology.hl7.org/CodeSystem/v2-0007" + } + ] + } + ], + "hospitalization": { + "preAdmissionIdentifier": { + "value": "1234567", + "type": { + "coding": [ + { + "code": "ANON", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Anonymous identifier" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + "reAdmission": { + "coding": [ + { + "code": "R", + "display": "Re-admission", + "system": "http://terminology.hl7.org/CodeSystem/v2-0092" + } + ] + }, + "admitSource": { + "coding": [ + { + "code": "NHS Provider-General (inc.A&E-this Hosp)" + } + ] + }, + "dischargeDisposition": { + "coding": [ + { + "code": "Admitted as Inpatient", + "display": "Sample", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ACR" + } + ] + }, + "dietPreference": [ + { + "coding": [ + { + "code": "Vegan", + "display": "Vegetarian" + } + ] + } + ], + "destination": { + "reference": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + "episodeOfCare": [ + { + "reference": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "CON", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "consultant" + } + ], + "individual": { + "reference": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "ADM", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "admitter" + } + ], + "individual": { + "reference": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "PART", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "Participation" + } + ], + "individual": { + "reference": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + } + ], + "serviceType": { + "coding": [ + { + "code": "SUR" + } + ] + }, + "identifier": [ + { + "value": "40007716", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + }, + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + }, + { + "value": "50", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "urn:oid:r2.3", + "assigner": { + "reference": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + } + ], + "period": { + "start": "2015-02-08T15:54:19+05:30", + "end": "2015-02-09T15:54:19+05:30" + }, + "reasonCode": [ + { + "coding": [ + { + "code": "140004", + "display": "Chronic pharyngitis", + "system": "http://snomed.info/sct" + } + ] + } + ], + "length": { + "value": 2, + "unit": "d", + "system": "http://unitsofmeasure.org/" + }, + "meta": { + "security": [ + { + "code": "N", + "display": "normal", + "system": "http://terminology.hl7.org/CodeSystem/v3-Confidentiality" + } + ] + }, + "text": { + "status": "generated", + "div": "

Visit Description: Health Checkup

" + }, + "priority": { + "coding": [ + { + "code": "UR", + "display": "urgent", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.2" + }, + { + "code": "EL", + "display": "elective", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.3" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/encounter-modeOfArrival", + "valueCoding": { + "code": "C", + "display": "Car", + "system": "http://terminology.hl7.org/CodeSystem/v2-0430" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Encounter/4b192760-03d2-aec4-b0a6-fde323912e1e" + } + }, + { + "fullUrl": "urn:uuid:9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "resource": { + "resourceType": "Provenance", + "id": "9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "occurredDateTime": "2021-08-17T18:49:43.004+05:30", + "recorded": "2029-08-01T11:21:24+05:30", + "reason": [ + { + "coding": [ + { + "code": "PATRQT", + "display": "patient requested", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActReason" + } + ] + } + ], + "agent": [ + { + "who": { + "reference": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + } + ], + "activity": { + "text": "ADT^A11^ADT_A11" + }, + "location": { + "reference": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + }, + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c" + } + }, + { + "fullUrl": "urn:uuid:ef39f581-5e8f-3917-35a9-3443303d9eee", + "resource": { + "resourceType": "Organization", + "id": "ef39f581-5e8f-3917-35a9-3443303d9eee", + "identifier": [ + { + "value": "DRNBR", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-DRNBR" + }, + { + "value": "urn:oid:W1.2", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + } + }, + { + "fullUrl": "urn:uuid:95aea53b-8d49-d57f-d16f-4d14b914f992", + "resource": { + "resourceType": "Practitioner", + "id": "95aea53b-8d49-d57f-d16f-4d14b914f992", + "identifier": [ + { + "value": "C08", + "system": "urn:oid:W1.2", + "assigner": { + "reference": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + }, + "type": { + "coding": [ + { + "code": "ANON", + "display": "Anonymous identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen", + "2ndname" + ], + "suffix": [ + "Jr", + "MD" + ], + "prefix": [ + "Dr" + ], + "use": "official" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + }, + { + "fullUrl": "urn:uuid:59d5e519-0108-5dd8-adfa-1eef5658009e", + "resource": { + "resourceType": "Location", + "id": "59d5e519-0108-5dd8-adfa-1eef5658009e", + "name": "Cona_Health", + "identifier": [ + { + "value": "urn:oid:1.3.6.1.4.1.44750.1.4", + "system": "urn:ietf:rfc:3986" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "display": "site", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + } + }, + { + "fullUrl": "urn:uuid:e82402a9-b2d1-2a28-3250-c099d5a77bf7", + "resource": { + "resourceType": "Organization", + "id": "e82402a9-b2d1-2a28-3250-c099d5a77bf7", + "identifier": [ + { + "value": "PERSt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/e82402a9-b2d1-2a28-3250-c099d5a77bf7" + } + }, + { + "fullUrl": "urn:uuid:ce70e6c3-c190-121d-c251-e4bae5cde6a1", + "resource": { + "resourceType": "Practitioner", + "id": "ce70e6c3-c190-121d-c251-e4bae5cde6a1", + "identifier": [ + { + "value": "1134", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/e82402a9-b2d1-2a28-3250-c099d5a77bf7" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Aly", + "given": [ + "Zafar", + "Mahendra" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/ce70e6c3-c190-121d-c251-e4bae5cde6a1" + } + }, + { + "fullUrl": "urn:uuid:88a53755-c972-6904-b4ce-8884b84ddc2e", + "resource": { + "resourceType": "PractitionerRole", + "id": "88a53755-c972-6904-b4ce-8884b84ddc2e", + "code": [ + { + "coding": [ + { + "code": "ResponsibleObserver", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/ce70e6c3-c190-121d-c251-e4bae5cde6a1" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/88a53755-c972-6904-b4ce-8884b84ddc2e" + } + }, + { + "fullUrl": "urn:uuid:3e0952c6-eea0-8938-96f8-07c224bf1577", + "resource": { + "resourceType": "Practitioner", + "id": "3e0952c6-eea0-8938-96f8-07c224bf1577", + "identifier": [ + { + "value": "2234" + } + ], + "name": [ + { + "family": "Pauly", + "given": [ + "Berrie", + "Raud" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/3e0952c6-eea0-8938-96f8-07c224bf1577" + } + }, + { + "fullUrl": "urn:uuid:bc78e290-ec67-c238-1e05-aefb6b252b0c", + "resource": { + "resourceType": "PractitionerRole", + "id": "bc78e290-ec67-c238-1e05-aefb6b252b0c", + "code": [ + { + "coding": [ + { + "code": "ResponsibleObserver", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/3e0952c6-eea0-8938-96f8-07c224bf1577" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/bc78e290-ec67-c238-1e05-aefb6b252b0c" + } + }, + { + "fullUrl": "urn:uuid:fe0adb86-ebe9-6479-0055-9db8dc1ff99a", + "resource": { + "resourceType": "Device", + "id": "fe0adb86-ebe9-6479-0055-9db8dc1ff99a", + "identifier": [ + { + "value": "EI12.3", + "system": "urn:uuid:UI2", + "type": { + "coding": [ + { + "code": "GUID", + "display": "Same as UUID.", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + }, + { + "system": "urn:oid:UI1", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/fe0adb86-ebe9-6479-0055-9db8dc1ff99a" + } + }, + { + "fullUrl": "urn:uuid:45f65e47-46c4-1a54-f9fb-1321258e79b2", + "resource": { + "resourceType": "Practitioner", + "id": "45f65e47-46c4-1a54-f9fb-1321258e79b2", + "identifier": [ + { + "type": { + "coding": [ + { + "code": "MD-25" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/45f65e47-46c4-1a54-f9fb-1321258e79b2" + } + }, + { + "fullUrl": "urn:uuid:090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3", + "resource": { + "resourceType": "PractitionerRole", + "id": "090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3", + "code": [ + { + "coding": [ + { + "code": "LabMedicalDirector", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/45f65e47-46c4-1a54-f9fb-1321258e79b2" + }, + "organization": { + "reference": "Organization/056aa7c7-6b75-3c67-63c5-cf9604f16d25" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3" + } + }, + { + "fullUrl": "urn:uuid:056aa7c7-6b75-3c67-63c5-cf9604f16d25", + "resource": { + "resourceType": "Organization", + "id": "056aa7c7-6b75-3c67-63c5-cf9604f16d25", + "name": "FairOaks Hspital", + "address": [ + { + "line": [ + "Research Park", + "Fairfax" + ], + "city": "VA", + "state": "22031", + "postalCode": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/056aa7c7-6b75-3c67-63c5-cf9604f16d25" + } + }, + { + "fullUrl": "urn:uuid:07fd2dd3-dbd6-5bb1-cfda-02226795d9a0", + "resource": { + "resourceType": "Observation", + "id": "07fd2dd3-dbd6-5bb1-cfda-02226795d9a0", + "identifier": [ + { + "value": "EI21", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-OII" + }, + { + "type": { + "coding": [ + { + "code": "FILL" + } + ] + } + } + ], + "status": "unknown", + "code": { + "coding": [ + { + "code": "8867-4", + "display": "heartrate", + "system": "http://loinc.org" + } + ] + }, + "component": [ + { + "code": { + "coding": [ + { + "code": "8867-4", + "display": "heartrate", + "system": "http://loinc.org" + } + ] + }, + "valueQuantity": { + "value": 60, + "code": "beats/min", + "unit": "beats/min", + "system": "urn:iso:std:iso:3986" + }, + "referenceRange": [ + { + "text": "70-80" + } + ] + }, + { + "code": { + "coding": [ + { + "code": "8867-4", + "display": "heartrate", + "system": "http://loinc.org" + } + ] + }, + "valueQuantity": { + "value": 120, + "code": "beats/min", + "unit": "beats/min", + "system": "urn:iso:std:iso:3986" + }, + "referenceRange": [ + { + "text": "70-80" + } + ] + } + ], + "effectiveDateTime": "1999-07-02", + "method": { + "coding": [ + { + "code": "OBS", + "display": "This is test method", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/AS4" + } + ] + }, + "device": { + "reference": "Device/fe0adb86-ebe9-6479-0055-9db8dc1ff99a" + }, + "bodySite": { + "coding": [ + { + "code": "BU", + "display": "Observation site", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/E5" + } + ] + }, + "performer": [ + { + "reference": "PractitionerRole/88a53755-c972-6904-b4ce-8884b84ddc2e" + }, + { + "reference": "PractitionerRole/bc78e290-ec67-c238-1e05-aefb6b252b0c" + }, + { + "reference": "PractitionerRole/090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3" + } + ], + "interpretation": [ + { + "coding": [ + { + "code": "A", + "display": "Abnormal", + "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation" + } + ] + }, + { + "coding": [ + { + "code": "B", + "display": "Better", + "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation" + } + ] + } + ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "S", + "display": "Partial", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Partial" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/07fd2dd3-dbd6-5bb1-cfda-02226795d9a0" + } + }, + { + "fullUrl": "urn:uuid:4e68b44e-c053-02b1-6d6d-fe816f9fdfec", + "resource": { + "resourceType": "Organization", + "id": "4e68b44e-c053-02b1-6d6d-fe816f9fdfec", + "identifier": [ + { + "value": "t", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-t" + }, + { + "value": "urn:oid:1.12", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4e68b44e-c053-02b1-6d6d-fe816f9fdfec" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A11/ADT-A11-02-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A11/ADT-A11-02-expected.json new file mode 100644 index 000000000..05198fcb5 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A11/ADT-A11-02-expected.json @@ -0,0 +1,2307 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "1989-08-18T14:41:00+05:30", + "identifier": { + "value": "MSG00001" + }, + "id": "513a3d06-5e87-6fbc-ad1b-170ab430499f", + "entry": [ + { + "fullUrl": "urn:uuid:b4ca189b-51ae-33df-cbe2-559b4423a321", + "resource": { + "resourceType": "MessageHeader", + "id": "b4ca189b-51ae-33df-cbe2-559b4423a321", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "A11", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "ADT^A11^ADT_A11" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/b4ca189b-51ae-33df-cbe2-559b4423a321" + } + }, + { + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "resource": { + "resourceType": "Provenance", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T11:38:42.01Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A11.

" + }, + "occurredDateTime": "1989-08-18T14:41:00+05:30", + "recorded": "1989-08-18T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "ADT^A11^ADT_A11" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + } + ], + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:503eb873-22fb-8199-ae28-3604ad59fe13", + "resource": { + "resourceType": "Device", + "id": "503eb873-22fb-8199-ae28-3604ad59fe13", + "identifier": [ + { + "value": "ADTApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/VeteranMilitaryStatus", + "valueCodeableConcept": { + "coding": [ + { + "code": "Vet123", + "display": "retired", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ART" + } + ], + "text": "retired" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-animal", + "extension": [ + { + "url": "species", + "valueCodeableConcept": { + "coding": [ + { + "code": "125097000", + "display": "Goat", + "system": "http://snomed.info/sct" + } + ], + "text": "Goat" + } + }, + { + "url": "breed", + "valueCodeableConcept": { + "coding": [ + { + "code": "4880003", + "display": "Beagle", + "system": "http://snomed.info/sct" + } + ], + "text": "Beagle" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-nationality", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "BT", + "display": "Bhutan", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Bhutan" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-importance", + "valueCodeableConcept": { + "coding": [ + { + "code": "VIP", + "display": "Very Important Person", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L", + "version": "v1.1" + }, + { + "code": "IMP", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/DCM", + "version": "v1.2" + } + ], + "text": "Inportant Person" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:11967e28-8dd4-a112-0fdc-377866bf12a0", + "resource": { + "resourceType": "Organization", + "id": "11967e28-8dd4-a112-0fdc-377866bf12a0", + "identifier": [ + { + "value": "t", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-t" + }, + { + "value": "2.16.840.1.113883.19", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + } + }, + { + "fullUrl": "urn:uuid:7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "resource": { + "resourceType": "Organization", + "id": "7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "identifier": [ + { + "value": "AccMng", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMng" + }, + { + "value": "1.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + } + }, + { + "fullUrl": "urn:uuid:0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "resource": { + "resourceType": "Organization", + "id": "0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "identifier": [ + { + "value": "PERSONNELt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSONNELt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + } + }, + { + "fullUrl": "urn:uuid:f6775f99-5279-be04-bf81-0906c81f7443", + "resource": { + "resourceType": "Practitioner", + "id": "f6775f99-5279-be04-bf81-0906c81f7443", + "identifier": [ + { + "value": "1122334", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Alaz", + "given": [ + "Mohammed", + "Mahi" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "fullUrl": "urn:uuid:c613d7b2-525f-8c08-a7ac-b2b91486e257", + "resource": { + "resourceType": "Organization", + "id": "c613d7b2-525f-8c08-a7ac-b2b91486e257", + "identifier": [ + { + "value": "TEST", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TEST" + }, + { + "value": "23.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + } + }, + { + "fullUrl": "urn:uuid:04f8cfc8-62ca-12df-63ce-6304ef577d44", + "resource": { + "resourceType": "Practitioner", + "id": "04f8cfc8-62ca-12df-63ce-6304ef577d44", + "identifier": [ + { + "value": "C006", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + }, + "type": { + "coding": [ + { + "code": "BA", + "display": "Bank Account Number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen" + ], + "prefix": [ + "Dr" + ], + "use": "anonymous" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "fullUrl": "urn:uuid:99edcabd-fbeb-7e25-f823-11da8d8ed342", + "resource": { + "resourceType": "Practitioner", + "id": "99edcabd-fbeb-7e25-f823-11da8d8ed342", + "identifier": [ + { + "value": "C008", + "system": "urn:oid:2.8", + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Condoc", + "given": [ + "leen" + ], + "prefix": [ + "Dr" + ], + "use": "temp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "fullUrl": "urn:uuid:b065b233-8738-f1ec-1314-d61e4aac2c9e", + "resource": { + "resourceType": "Practitioner", + "id": "b065b233-8738-f1ec-1314-d61e4aac2c9e", + "identifier": [ + { + "value": "37", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr", + "type": { + "coding": [ + { + "code": "ANC", + "display": "Account number Creditor", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "DISNEY", + "given": [ + "WALT" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "fullUrl": "urn:uuid:9f974d4f-47e8-21a6-e549-4de4599c3764", + "resource": { + "resourceType": "Organization", + "id": "9f974d4f-47e8-21a6-e549-4de4599c3764", + "identifier": [ + { + "value": "T123", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-T123" + }, + { + "value": "urn:oid:r2.3", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + }, + { + "fullUrl": "urn:uuid:84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "resource": { + "resourceType": "Practitioner", + "id": "84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "identifier": [ + { + "value": "Othhel", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "fullUrl": "urn:uuid:24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "resource": { + "resourceType": "Organization", + "id": "24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "identifier": [ + { + "value": "TE", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TE" + }, + { + "value": "Provider Master.Community Health and Hospitals", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "type": { + "coding": [ + { + "code": "DNS", + "display": "An Internet host name, in accordance with RFC 1035; or an IP address. Either in ASCII or as integers, with periods between components (“dotted” notation).", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + } + }, + { + "fullUrl": "urn:uuid:36e3aaa4-569a-7d9d-037f-27235ed05701", + "resource": { + "resourceType": "Practitioner", + "id": "36e3aaa4-569a-7d9d-037f-27235ed05701", + "identifier": [ + { + "value": "12188", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "assigner": { + "reference": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + }, + "type": { + "coding": [ + { + "code": "DN", + "display": "Doctor number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Hippocrates", + "given": [ + "Harold", + "H" + ], + "suffix": [ + "IV", + "MD" + ], + "prefix": [ + "Dr" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + }, + { + "fullUrl": "urn:uuid:9172e4a0-1ca5-646d-2183-b179f4daa737", + "resource": { + "resourceType": "Location", + "id": "9172e4a0-1ca5-646d-2183-b179f4daa737", + "partOf": { + "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + }, + "name": "HUH AE OMU", + "identifier": [ + { + "value": "urn:oid:9.8", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "fullUrl": "urn:uuid:3913ec4d-6576-5e1a-ac31-e8280583371c", + "resource": { + "resourceType": "Location", + "id": "3913ec4d-6576-5e1a-ac31-e8280583371c", + "partOf": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + }, + "name": "OMU B", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + } + }, + { + "fullUrl": "urn:uuid:804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "resource": { + "resourceType": "Location", + "id": "804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "partOf": { + "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + }, + "name": "Bed 03", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" + } + }, + { + "fullUrl": "urn:uuid:c043880b-0fab-1cb8-14f7-0475282c4d0e", + "resource": { + "resourceType": "Location", + "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", + "name": "HOMERTON UNIVER", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + } + }, + { + "fullUrl": "urn:uuid:f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "resource": { + "resourceType": "Location", + "id": "f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "partOf": { + "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + }, + "name": "Homerton UH", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + } + }, + { + "fullUrl": "urn:uuid:7e38808c-44a8-cb0c-4709-9d6092abc32c", + "resource": { + "resourceType": "Location", + "id": "7e38808c-44a8-cb0c-4709-9d6092abc32c", + "partOf": { + "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + }, + "name": "Floor5", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + } + }, + { + "fullUrl": "urn:uuid:59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "resource": { + "resourceType": "Location", + "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "name": "4 East, room 136, bed B 4E", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + } + }, + { + "fullUrl": "urn:uuid:d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "resource": { + "resourceType": "Location", + "id": "d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "partOf": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "name": "136", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + } + }, + { + "fullUrl": "urn:uuid:5783dafa-c6c0-e673-cca4-42087ee1831b", + "resource": { + "resourceType": "Location", + "id": "5783dafa-c6c0-e673-cca4-42087ee1831b", + "partOf": { + "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + }, + "name": "B", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" + } + }, + { + "fullUrl": "urn:uuid:8b39e6e5-78cd-63ab-2441-f43ca5554096", + "resource": { + "resourceType": "Location", + "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", + "name": "CommunityHospital", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" + } + }, + { + "fullUrl": "urn:uuid:42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "resource": { + "resourceType": "Location", + "id": "42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "name": "Homes", + "identifier": [ + { + "value": "22", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/FDK" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + { + "fullUrl": "urn:uuid:84634858-74aa-5cdb-4547-60ec27339ac6", + "resource": { + "resourceType": "Location", + "id": "84634858-74aa-5cdb-4547-60ec27339ac6", + "name": "POC", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + } + }, + { + "fullUrl": "urn:uuid:9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", + "resource": { + "resourceType": "Location", + "id": "9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", + "partOf": { + "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + }, + "name": "Room-2", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" + } + }, + { + "fullUrl": "urn:uuid:35353f20-6254-e794-98ed-8007490447e3", + "resource": { + "resourceType": "Location", + "id": "35353f20-6254-e794-98ed-8007490447e3", + "partOf": { + "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" + }, + "name": "Bed-103", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/35353f20-6254-e794-98ed-8007490447e3" + } + }, + { + "fullUrl": "urn:uuid:055e10f1-222e-df73-2325-0e4396db1a55", + "resource": { + "resourceType": "Location", + "id": "055e10f1-222e-df73-2325-0e4396db1a55", + "name": "Greenland", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/055e10f1-222e-df73-2325-0e4396db1a55" + } + }, + { + "fullUrl": "urn:uuid:1154e6b2-b022-b3be-7dce-2b940ab5376d", + "resource": { + "resourceType": "Location", + "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", + "name": "Nursing home", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + } + }, + { + "fullUrl": "urn:uuid:08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "resource": { + "resourceType": "Location", + "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "name": "Rosewood", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" + } + }, + { + "fullUrl": "urn:uuid:c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "resource": { + "resourceType": "Location", + "id": "c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "name": "ROOM1", + "identifier": [ + { + "value": "urn:oid:2.16.840.1.113883.4.642.1.1108", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + } + }, + { + "fullUrl": "urn:uuid:6f159848-5f01-01b3-9594-80fbbe9ab510", + "resource": { + "resourceType": "Location", + "id": "6f159848-5f01-01b3-9594-80fbbe9ab510", + "partOf": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "name": "BED1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" + } + }, + { + "fullUrl": "urn:uuid:4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "resource": { + "resourceType": "Location", + "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "name": "FACILITY1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + } + }, + { + "fullUrl": "urn:uuid:3b0911cb-4361-cd8d-b188-463af033c699", + "resource": { + "resourceType": "Location", + "id": "3b0911cb-4361-cd8d-b188-463af033c699", + "partOf": { + "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + }, + "name": "BUILDING1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:08314073-410a-3dc7-512c-0f2d206fb59d", + "resource": { + "resourceType": "Organization", + "id": "08314073-410a-3dc7-512c-0f2d206fb59d", + "identifier": [ + { + "value": "Etest", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-Etest" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + }, + { + "fullUrl": "urn:uuid:919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "resource": { + "resourceType": "EpisodeOfCare", + "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "status": "cancelled", + "identifier": [ + { + "value": "EOC124", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + }, + { + "fullUrl": "urn:uuid:4b192760-03d2-aec4-b0a6-fde323912e1e", + "resource": { + "resourceType": "Encounter", + "id": "4b192760-03d2-aec4-b0a6-fde323912e1e", + "class": { + "code": "PRENC", + "display": "pre-admission", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "cancelled", + "location": [ + { + "location": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "location": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "location": { + "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "location": { + "reference": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": true + } + ] + }, + { + "location": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + } + ], + "type": [ + { + "coding": [ + { + "code": "E", + "display": "Emergency", + "system": "http://terminology.hl7.org/CodeSystem/v2-0007" + } + ] + } + ], + "hospitalization": { + "preAdmissionIdentifier": { + "value": "1234567", + "type": { + "coding": [ + { + "code": "ANON", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Anonymous identifier" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + "reAdmission": { + "coding": [ + { + "code": "R", + "display": "Re-admission", + "system": "http://terminology.hl7.org/CodeSystem/v2-0092" + } + ] + }, + "admitSource": { + "coding": [ + { + "code": "NHS Provider-General (inc.A&E-this Hosp)" + } + ] + }, + "dischargeDisposition": { + "coding": [ + { + "code": "Admitted as Inpatient", + "display": "Sample", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ACR" + } + ] + }, + "dietPreference": [ + { + "coding": [ + { + "code": "Vegan", + "display": "Vegetarian" + } + ] + } + ], + "destination": { + "reference": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + "episodeOfCare": [ + { + "reference": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "CON", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "consultant" + } + ], + "individual": { + "reference": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "ADM", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "admitter" + } + ], + "individual": { + "reference": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "PART", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "Participation" + } + ], + "individual": { + "reference": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + } + ], + "serviceType": { + "coding": [ + { + "code": "SUR" + } + ] + }, + "identifier": [ + { + "value": "40007716", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + }, + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + }, + { + "value": "50", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "urn:oid:r2.3", + "assigner": { + "reference": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + } + ], + "period": { + "start": "2015-02-08T15:54:19+05:30", + "end": "2015-02-09T15:54:19+05:30" + }, + "reasonCode": [ + { + "coding": [ + { + "code": "140004", + "display": "Chronic pharyngitis", + "system": "http://snomed.info/sct" + } + ] + } + ], + "length": { + "value": 2, + "unit": "d", + "system": "http://unitsofmeasure.org/" + }, + "meta": { + "security": [ + { + "code": "N", + "display": "normal", + "system": "http://terminology.hl7.org/CodeSystem/v3-Confidentiality" + } + ] + }, + "text": { + "status": "generated", + "div": "

Visit Description: Health Checkup

" + }, + "priority": { + "coding": [ + { + "code": "UR", + "display": "urgent", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.2" + }, + { + "code": "EL", + "display": "elective", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.3" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/encounter-modeOfArrival", + "valueCoding": { + "code": "C", + "display": "Car", + "system": "http://terminology.hl7.org/CodeSystem/v2-0430" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Encounter/4b192760-03d2-aec4-b0a6-fde323912e1e" + } + }, + { + "fullUrl": "urn:uuid:9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "resource": { + "resourceType": "Provenance", + "id": "9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "occurredDateTime": "2021-08-17T18:49:43.004+05:30", + "recorded": "2029-08-01T11:21:24+05:30", + "reason": [ + { + "coding": [ + { + "code": "PATRQT", + "display": "patient requested", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActReason" + } + ] + } + ], + "agent": [ + { + "who": { + "reference": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + } + ], + "activity": { + "text": "ADT^A11^ADT_A11" + }, + "location": { + "reference": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + }, + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c" + } + }, + { + "fullUrl": "urn:uuid:ef39f581-5e8f-3917-35a9-3443303d9eee", + "resource": { + "resourceType": "Organization", + "id": "ef39f581-5e8f-3917-35a9-3443303d9eee", + "identifier": [ + { + "value": "DRNBR", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-DRNBR" + }, + { + "value": "urn:oid:W1.2", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + } + }, + { + "fullUrl": "urn:uuid:95aea53b-8d49-d57f-d16f-4d14b914f992", + "resource": { + "resourceType": "Practitioner", + "id": "95aea53b-8d49-d57f-d16f-4d14b914f992", + "identifier": [ + { + "value": "C08", + "system": "urn:oid:W1.2", + "assigner": { + "reference": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + }, + "type": { + "coding": [ + { + "code": "ANON", + "display": "Anonymous identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen", + "2ndname" + ], + "suffix": [ + "Jr", + "MD" + ], + "prefix": [ + "Dr" + ], + "use": "official" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + }, + { + "fullUrl": "urn:uuid:59d5e519-0108-5dd8-adfa-1eef5658009e", + "resource": { + "resourceType": "Location", + "id": "59d5e519-0108-5dd8-adfa-1eef5658009e", + "name": "Cona_Health", + "identifier": [ + { + "value": "urn:oid:1.3.6.1.4.1.44750.1.4", + "system": "urn:ietf:rfc:3986" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "display": "site", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A01/ADT-A01-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A13/ADT-A13-01-expected.json similarity index 95% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A01/ADT-A01-expected.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A13/ADT-A13-01-expected.json index 4045aa673..8b7844d5f 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A01/ADT-A01-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A13/ADT-A13-01-expected.json @@ -42,9 +42,9 @@ ] }, "eventCoding": { - "code": "A01", + "code": "A13", "system": "http://terminology.hl7.org/CodeSystem/v2-0003", - "display": "ADT^A01^ADT_A01" + "display": "ADT^A13^ADT_A13" }, "language": "en-US", "sender": { @@ -60,13 +60,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T12:37:12.345Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A01.

" + "div": "

Resource bundle generated on 2021-10-29T11:42:14.552Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A13.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -88,7 +88,7 @@ "activity": { "coding": [ { - "display": "ADT^A01^ADT_A01" + "display": "ADT^A13^ADT_A13" } ] }, @@ -108,7 +108,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { @@ -1649,6 +1649,7 @@ } ], "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1673,6 +1674,7 @@ }, "name": "OMU B", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1697,6 +1699,7 @@ }, "name": "Bed 03", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1718,6 +1721,7 @@ "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", "name": "HOMERTON UNIVER", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1742,6 +1746,7 @@ }, "name": "Homerton UH", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1766,6 +1771,7 @@ }, "name": "Floor5", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1787,6 +1793,7 @@ "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", "name": "4 East, room 136, bed B 4E", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1811,6 +1818,7 @@ }, "name": "136", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1835,6 +1843,7 @@ }, "name": "B", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1856,6 +1865,7 @@ "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", "name": "CommunityHospital", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1903,6 +1913,7 @@ "id": "84634858-74aa-5cdb-4547-60ec27339ac6", "name": "POC", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1927,6 +1938,7 @@ }, "name": "Room-2", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1951,6 +1963,7 @@ }, "name": "Bed-103", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1972,6 +1985,7 @@ "id": "055e10f1-222e-df73-2325-0e4396db1a55", "name": "Greenland", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1993,6 +2007,7 @@ "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", "name": "Nursing home", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -2014,6 +2029,7 @@ "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", "name": "Rosewood", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -2041,6 +2057,7 @@ } ], "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2065,6 +2082,7 @@ }, "name": "BED1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2086,6 +2104,7 @@ "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", "name": "FACILITY1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2110,6 +2129,7 @@ }, "name": "BUILDING1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2134,6 +2154,7 @@ }, "name": "FLOOR1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2183,7 +2204,7 @@ "resource": { "resourceType": "EpisodeOfCare", "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", - "status": "planned", + "status": "active", "identifier": [ { "value": "EOC124", @@ -2238,44 +2259,14 @@ "display": "pre-admission", "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" }, - "status": "planned", + "status": "in-progress", "location": [ { - "status": "planned", + "status": "active", "location": { "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, { "status": "completed", "location": { @@ -2288,42 +2279,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "planned", "location": { @@ -2336,42 +2291,6 @@ } ] }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "completed", "location": { @@ -2384,18 +2303,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true - } - ] - }, { "status": "planned", "location": { @@ -2407,54 +2314,6 @@ "valueBoolean": false } ] - }, - { - "status": "planned", - "location": { - "reference": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] } ], "type": [ @@ -2782,7 +2641,7 @@ } ], "activity": { - "text": "ADT^A01^ADT_A01" + "text": "ADT^A13^ADT_A13" }, "location": { "reference": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" @@ -3018,6 +2877,7 @@ "id": "a9c75502-d60a-d89b-5912-f046100cd47e", "name": "OT", "mode": "instance", + "description": "OT--201", "physicalType": { "coding": [ { @@ -3032,6 +2892,31 @@ "url": "Location/a9c75502-d60a-d89b-5912-f046100cd47e" } }, + { + "fullUrl": "urn:uuid:55f70355-863d-579a-b4aa-81fcaf3e1fb0", + "resource": { + "resourceType": "Location", + "id": "55f70355-863d-579a-b4aa-81fcaf3e1fb0", + "partOf": { + "reference": "Location/a9c75502-d60a-d89b-5912-f046100cd47e" + }, + "name": "201", + "mode": "instance", + "description": "OT--201", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/55f70355-863d-579a-b4aa-81fcaf3e1fb0" + } + }, { "fullUrl": "urn:uuid:2e2e33a1-60f8-7e38-c827-fe070237c3fb", "resource": { @@ -3987,6 +3872,9 @@ ] } ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, "extension": [ { "url": "http://example.com/v2-to-fhir-converter/Observation_Status", @@ -4356,19 +4244,6 @@ }, "system": "http://www.examplehealthplan.com/fhir/policyidentifier" }, - { - "value": "HMO-12345", - "type": { - "coding": [ - { - "code": "NI", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203", - "display": "National unique individual identifier" - } - ] - }, - "system": "urn:oid:2.16.840.1.113883.1.3" - }, { "value": "Medicare-12345", "type": { diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A13/ADT-A13-02-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A13/ADT-A13-02-expected.json new file mode 100644 index 000000000..a3e81e57e --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A13/ADT-A13-02-expected.json @@ -0,0 +1,2311 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "1989-08-18T14:41:00+05:30", + "identifier": { + "value": "MSG00001" + }, + "id": "513a3d06-5e87-6fbc-ad1b-170ab430499f", + "entry": [ + { + "fullUrl": "urn:uuid:b4ca189b-51ae-33df-cbe2-559b4423a321", + "resource": { + "resourceType": "MessageHeader", + "id": "b4ca189b-51ae-33df-cbe2-559b4423a321", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "A13", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "ADT^A13^ADT_A13" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/b4ca189b-51ae-33df-cbe2-559b4423a321" + } + }, + { + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "resource": { + "resourceType": "Provenance", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T11:41:02.113Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A13.

" + }, + "occurredDateTime": "1989-08-18T14:41:00+05:30", + "recorded": "1989-08-18T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "ADT^A13^ADT_A13" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + } + ], + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:503eb873-22fb-8199-ae28-3604ad59fe13", + "resource": { + "resourceType": "Device", + "id": "503eb873-22fb-8199-ae28-3604ad59fe13", + "identifier": [ + { + "value": "ADTApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/VeteranMilitaryStatus", + "valueCodeableConcept": { + "coding": [ + { + "code": "Vet123", + "display": "retired", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ART" + } + ], + "text": "retired" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-animal", + "extension": [ + { + "url": "species", + "valueCodeableConcept": { + "coding": [ + { + "code": "125097000", + "display": "Goat", + "system": "http://snomed.info/sct" + } + ], + "text": "Goat" + } + }, + { + "url": "breed", + "valueCodeableConcept": { + "coding": [ + { + "code": "4880003", + "display": "Beagle", + "system": "http://snomed.info/sct" + } + ], + "text": "Beagle" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-nationality", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "BT", + "display": "Bhutan", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Bhutan" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-importance", + "valueCodeableConcept": { + "coding": [ + { + "code": "VIP", + "display": "Very Important Person", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L", + "version": "v1.1" + }, + { + "code": "IMP", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/DCM", + "version": "v1.2" + } + ], + "text": "Inportant Person" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:11967e28-8dd4-a112-0fdc-377866bf12a0", + "resource": { + "resourceType": "Organization", + "id": "11967e28-8dd4-a112-0fdc-377866bf12a0", + "identifier": [ + { + "value": "t", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-t" + }, + { + "value": "2.16.840.1.113883.19", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + } + }, + { + "fullUrl": "urn:uuid:7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "resource": { + "resourceType": "Organization", + "id": "7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "identifier": [ + { + "value": "AccMng", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMng" + }, + { + "value": "1.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + } + }, + { + "fullUrl": "urn:uuid:0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "resource": { + "resourceType": "Organization", + "id": "0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "identifier": [ + { + "value": "PERSONNELt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSONNELt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + } + }, + { + "fullUrl": "urn:uuid:f6775f99-5279-be04-bf81-0906c81f7443", + "resource": { + "resourceType": "Practitioner", + "id": "f6775f99-5279-be04-bf81-0906c81f7443", + "identifier": [ + { + "value": "1122334", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Alaz", + "given": [ + "Mohammed", + "Mahi" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "fullUrl": "urn:uuid:c613d7b2-525f-8c08-a7ac-b2b91486e257", + "resource": { + "resourceType": "Organization", + "id": "c613d7b2-525f-8c08-a7ac-b2b91486e257", + "identifier": [ + { + "value": "TEST", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TEST" + }, + { + "value": "23.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + } + }, + { + "fullUrl": "urn:uuid:04f8cfc8-62ca-12df-63ce-6304ef577d44", + "resource": { + "resourceType": "Practitioner", + "id": "04f8cfc8-62ca-12df-63ce-6304ef577d44", + "identifier": [ + { + "value": "C006", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + }, + "type": { + "coding": [ + { + "code": "BA", + "display": "Bank Account Number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen" + ], + "prefix": [ + "Dr" + ], + "use": "anonymous" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "fullUrl": "urn:uuid:99edcabd-fbeb-7e25-f823-11da8d8ed342", + "resource": { + "resourceType": "Practitioner", + "id": "99edcabd-fbeb-7e25-f823-11da8d8ed342", + "identifier": [ + { + "value": "C008", + "system": "urn:oid:2.8", + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Condoc", + "given": [ + "leen" + ], + "prefix": [ + "Dr" + ], + "use": "temp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "fullUrl": "urn:uuid:b065b233-8738-f1ec-1314-d61e4aac2c9e", + "resource": { + "resourceType": "Practitioner", + "id": "b065b233-8738-f1ec-1314-d61e4aac2c9e", + "identifier": [ + { + "value": "37", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr", + "type": { + "coding": [ + { + "code": "ANC", + "display": "Account number Creditor", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "DISNEY", + "given": [ + "WALT" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "fullUrl": "urn:uuid:9f974d4f-47e8-21a6-e549-4de4599c3764", + "resource": { + "resourceType": "Organization", + "id": "9f974d4f-47e8-21a6-e549-4de4599c3764", + "identifier": [ + { + "value": "T123", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-T123" + }, + { + "value": "urn:oid:r2.3", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + }, + { + "fullUrl": "urn:uuid:84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "resource": { + "resourceType": "Practitioner", + "id": "84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "identifier": [ + { + "value": "Othhel", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "fullUrl": "urn:uuid:24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "resource": { + "resourceType": "Organization", + "id": "24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "identifier": [ + { + "value": "TE", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TE" + }, + { + "value": "Provider Master.Community Health and Hospitals", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "type": { + "coding": [ + { + "code": "DNS", + "display": "An Internet host name, in accordance with RFC 1035; or an IP address. Either in ASCII or as integers, with periods between components (“dotted” notation).", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + } + }, + { + "fullUrl": "urn:uuid:36e3aaa4-569a-7d9d-037f-27235ed05701", + "resource": { + "resourceType": "Practitioner", + "id": "36e3aaa4-569a-7d9d-037f-27235ed05701", + "identifier": [ + { + "value": "12188", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "assigner": { + "reference": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + }, + "type": { + "coding": [ + { + "code": "DN", + "display": "Doctor number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Hippocrates", + "given": [ + "Harold", + "H" + ], + "suffix": [ + "IV", + "MD" + ], + "prefix": [ + "Dr" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + }, + { + "fullUrl": "urn:uuid:9172e4a0-1ca5-646d-2183-b179f4daa737", + "resource": { + "resourceType": "Location", + "id": "9172e4a0-1ca5-646d-2183-b179f4daa737", + "partOf": { + "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + }, + "name": "HUH AE OMU", + "identifier": [ + { + "value": "urn:oid:9.8", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "fullUrl": "urn:uuid:3913ec4d-6576-5e1a-ac31-e8280583371c", + "resource": { + "resourceType": "Location", + "id": "3913ec4d-6576-5e1a-ac31-e8280583371c", + "partOf": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + }, + "name": "OMU B", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + } + }, + { + "fullUrl": "urn:uuid:804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "resource": { + "resourceType": "Location", + "id": "804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "partOf": { + "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + }, + "name": "Bed 03", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" + } + }, + { + "fullUrl": "urn:uuid:c043880b-0fab-1cb8-14f7-0475282c4d0e", + "resource": { + "resourceType": "Location", + "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", + "name": "HOMERTON UNIVER", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + } + }, + { + "fullUrl": "urn:uuid:f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "resource": { + "resourceType": "Location", + "id": "f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "partOf": { + "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + }, + "name": "Homerton UH", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + } + }, + { + "fullUrl": "urn:uuid:7e38808c-44a8-cb0c-4709-9d6092abc32c", + "resource": { + "resourceType": "Location", + "id": "7e38808c-44a8-cb0c-4709-9d6092abc32c", + "partOf": { + "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + }, + "name": "Floor5", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + } + }, + { + "fullUrl": "urn:uuid:59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "resource": { + "resourceType": "Location", + "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "name": "4 East, room 136, bed B 4E", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + } + }, + { + "fullUrl": "urn:uuid:d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "resource": { + "resourceType": "Location", + "id": "d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "partOf": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "name": "136", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + } + }, + { + "fullUrl": "urn:uuid:5783dafa-c6c0-e673-cca4-42087ee1831b", + "resource": { + "resourceType": "Location", + "id": "5783dafa-c6c0-e673-cca4-42087ee1831b", + "partOf": { + "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + }, + "name": "B", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" + } + }, + { + "fullUrl": "urn:uuid:8b39e6e5-78cd-63ab-2441-f43ca5554096", + "resource": { + "resourceType": "Location", + "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", + "name": "CommunityHospital", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" + } + }, + { + "fullUrl": "urn:uuid:42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "resource": { + "resourceType": "Location", + "id": "42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "name": "Homes", + "identifier": [ + { + "value": "22", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/FDK" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + { + "fullUrl": "urn:uuid:84634858-74aa-5cdb-4547-60ec27339ac6", + "resource": { + "resourceType": "Location", + "id": "84634858-74aa-5cdb-4547-60ec27339ac6", + "name": "POC", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + } + }, + { + "fullUrl": "urn:uuid:9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", + "resource": { + "resourceType": "Location", + "id": "9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", + "partOf": { + "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + }, + "name": "Room-2", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" + } + }, + { + "fullUrl": "urn:uuid:35353f20-6254-e794-98ed-8007490447e3", + "resource": { + "resourceType": "Location", + "id": "35353f20-6254-e794-98ed-8007490447e3", + "partOf": { + "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" + }, + "name": "Bed-103", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/35353f20-6254-e794-98ed-8007490447e3" + } + }, + { + "fullUrl": "urn:uuid:055e10f1-222e-df73-2325-0e4396db1a55", + "resource": { + "resourceType": "Location", + "id": "055e10f1-222e-df73-2325-0e4396db1a55", + "name": "Greenland", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/055e10f1-222e-df73-2325-0e4396db1a55" + } + }, + { + "fullUrl": "urn:uuid:1154e6b2-b022-b3be-7dce-2b940ab5376d", + "resource": { + "resourceType": "Location", + "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", + "name": "Nursing home", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + } + }, + { + "fullUrl": "urn:uuid:08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "resource": { + "resourceType": "Location", + "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "name": "Rosewood", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" + } + }, + { + "fullUrl": "urn:uuid:c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "resource": { + "resourceType": "Location", + "id": "c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "name": "ROOM1", + "identifier": [ + { + "value": "urn:oid:2.16.840.1.113883.4.642.1.1108", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + } + }, + { + "fullUrl": "urn:uuid:6f159848-5f01-01b3-9594-80fbbe9ab510", + "resource": { + "resourceType": "Location", + "id": "6f159848-5f01-01b3-9594-80fbbe9ab510", + "partOf": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "name": "BED1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" + } + }, + { + "fullUrl": "urn:uuid:4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "resource": { + "resourceType": "Location", + "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "name": "FACILITY1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + } + }, + { + "fullUrl": "urn:uuid:3b0911cb-4361-cd8d-b188-463af033c699", + "resource": { + "resourceType": "Location", + "id": "3b0911cb-4361-cd8d-b188-463af033c699", + "partOf": { + "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + }, + "name": "BUILDING1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:08314073-410a-3dc7-512c-0f2d206fb59d", + "resource": { + "resourceType": "Organization", + "id": "08314073-410a-3dc7-512c-0f2d206fb59d", + "identifier": [ + { + "value": "Etest", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-Etest" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + }, + { + "fullUrl": "urn:uuid:919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "resource": { + "resourceType": "EpisodeOfCare", + "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "status": "active", + "identifier": [ + { + "value": "EOC124", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + }, + { + "fullUrl": "urn:uuid:4b192760-03d2-aec4-b0a6-fde323912e1e", + "resource": { + "resourceType": "Encounter", + "id": "4b192760-03d2-aec4-b0a6-fde323912e1e", + "class": { + "code": "PRENC", + "display": "pre-admission", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "in-progress", + "location": [ + { + "status": "active", + "location": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "status": "completed", + "location": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "status": "planned", + "location": { + "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "status": "completed", + "location": { + "reference": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": true + } + ] + }, + { + "status": "planned", + "location": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + } + ], + "type": [ + { + "coding": [ + { + "code": "E", + "display": "Emergency", + "system": "http://terminology.hl7.org/CodeSystem/v2-0007" + } + ] + } + ], + "hospitalization": { + "preAdmissionIdentifier": { + "value": "1234567", + "type": { + "coding": [ + { + "code": "ANON", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Anonymous identifier" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + "reAdmission": { + "coding": [ + { + "code": "R", + "display": "Re-admission", + "system": "http://terminology.hl7.org/CodeSystem/v2-0092" + } + ] + }, + "admitSource": { + "coding": [ + { + "code": "NHS Provider-General (inc.A&E-this Hosp)" + } + ] + }, + "dischargeDisposition": { + "coding": [ + { + "code": "Admitted as Inpatient", + "display": "Sample", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ACR" + } + ] + }, + "dietPreference": [ + { + "coding": [ + { + "code": "Vegan", + "display": "Vegetarian" + } + ] + } + ], + "destination": { + "reference": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + "episodeOfCare": [ + { + "reference": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "CON", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "consultant" + } + ], + "individual": { + "reference": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "ADM", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "admitter" + } + ], + "individual": { + "reference": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "PART", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "Participation" + } + ], + "individual": { + "reference": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + } + ], + "serviceType": { + "coding": [ + { + "code": "SUR" + } + ] + }, + "identifier": [ + { + "value": "40007716", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + }, + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + }, + { + "value": "50", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "urn:oid:r2.3", + "assigner": { + "reference": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + } + ], + "period": { + "start": "2015-02-08T15:54:19+05:30" + }, + "reasonCode": [ + { + "coding": [ + { + "code": "140004", + "display": "Chronic pharyngitis", + "system": "http://snomed.info/sct" + } + ] + } + ], + "length": { + "value": 2, + "unit": "d", + "system": "http://unitsofmeasure.org/" + }, + "meta": { + "security": [ + { + "code": "N", + "display": "normal", + "system": "http://terminology.hl7.org/CodeSystem/v3-Confidentiality" + } + ] + }, + "text": { + "status": "generated", + "div": "

Visit Description: Health Checkup

" + }, + "priority": { + "coding": [ + { + "code": "UR", + "display": "urgent", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.2" + }, + { + "code": "EL", + "display": "elective", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.3" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/encounter-modeOfArrival", + "valueCoding": { + "code": "C", + "display": "Car", + "system": "http://terminology.hl7.org/CodeSystem/v2-0430" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Encounter/4b192760-03d2-aec4-b0a6-fde323912e1e" + } + }, + { + "fullUrl": "urn:uuid:9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "resource": { + "resourceType": "Provenance", + "id": "9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "occurredDateTime": "2021-08-17T18:49:43.004+05:30", + "recorded": "2029-08-01T11:21:24+05:30", + "reason": [ + { + "coding": [ + { + "code": "PATRQT", + "display": "patient requested", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActReason" + } + ] + } + ], + "agent": [ + { + "who": { + "reference": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + } + ], + "activity": { + "text": "ADT^A13^ADT_A13" + }, + "location": { + "reference": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + }, + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c" + } + }, + { + "fullUrl": "urn:uuid:ef39f581-5e8f-3917-35a9-3443303d9eee", + "resource": { + "resourceType": "Organization", + "id": "ef39f581-5e8f-3917-35a9-3443303d9eee", + "identifier": [ + { + "value": "DRNBR", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-DRNBR" + }, + { + "value": "urn:oid:W1.2", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + } + }, + { + "fullUrl": "urn:uuid:95aea53b-8d49-d57f-d16f-4d14b914f992", + "resource": { + "resourceType": "Practitioner", + "id": "95aea53b-8d49-d57f-d16f-4d14b914f992", + "identifier": [ + { + "value": "C08", + "system": "urn:oid:W1.2", + "assigner": { + "reference": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + }, + "type": { + "coding": [ + { + "code": "ANON", + "display": "Anonymous identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen", + "2ndname" + ], + "suffix": [ + "Jr", + "MD" + ], + "prefix": [ + "Dr" + ], + "use": "official" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + }, + { + "fullUrl": "urn:uuid:59d5e519-0108-5dd8-adfa-1eef5658009e", + "resource": { + "resourceType": "Location", + "id": "59d5e519-0108-5dd8-adfa-1eef5658009e", + "name": "Cona_Health", + "identifier": [ + { + "value": "urn:oid:1.3.6.1.4.1.44750.1.4", + "system": "urn:ietf:rfc:3986" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "display": "site", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A14/ADT-A14-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A14/ADT-A14-01-expected.json similarity index 95% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A14/ADT-A14-expected.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A14/ADT-A14-01-expected.json index 68860068c..53c63b0ba 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A14/ADT-A14-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A14/ADT-A14-01-expected.json @@ -60,13 +60,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:22:27.454Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A14.

" + "div": "

Resource bundle generated on 2021-10-29T11:43:58.205Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A14.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -108,7 +108,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { @@ -1649,6 +1649,7 @@ } ], "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1673,6 +1674,7 @@ }, "name": "OMU B", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1697,6 +1699,7 @@ }, "name": "Bed 03", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1718,6 +1721,7 @@ "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", "name": "HOMERTON UNIVER", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1742,6 +1746,7 @@ }, "name": "Homerton UH", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1766,6 +1771,7 @@ }, "name": "Floor5", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1787,6 +1793,7 @@ "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", "name": "4 East, room 136, bed B 4E", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1811,6 +1818,7 @@ }, "name": "136", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1835,6 +1843,7 @@ }, "name": "B", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1856,6 +1865,7 @@ "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", "name": "CommunityHospital", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1903,6 +1913,7 @@ "id": "84634858-74aa-5cdb-4547-60ec27339ac6", "name": "POC", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1927,6 +1938,7 @@ }, "name": "Room-2", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1951,6 +1963,7 @@ }, "name": "Bed-103", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1972,6 +1985,7 @@ "id": "055e10f1-222e-df73-2325-0e4396db1a55", "name": "Greenland", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1993,6 +2007,7 @@ "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", "name": "Nursing home", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -2014,6 +2029,7 @@ "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", "name": "Rosewood", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -2041,6 +2057,7 @@ } ], "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2065,6 +2082,7 @@ }, "name": "BED1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2086,6 +2104,7 @@ "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", "name": "FACILITY1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2110,6 +2129,7 @@ }, "name": "BUILDING1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2134,6 +2154,7 @@ }, "name": "FLOOR1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2246,36 +2267,6 @@ "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, { "status": "completed", "location": { @@ -2288,42 +2279,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "planned", "location": { @@ -2336,42 +2291,6 @@ } ] }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "completed", "location": { @@ -2384,18 +2303,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true - } - ] - }, { "status": "planned", "location": { @@ -2407,54 +2314,6 @@ "valueBoolean": false } ] - }, - { - "status": "planned", - "location": { - "reference": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] } ], "type": [ @@ -2673,7 +2532,8 @@ } ], "period": { - "start": "2015-02-08T15:54:19+05:30" + "start": "2015-02-08T11:34:19", + "end": "2015-02-09T11:34:19" }, "reasonCode": [ { @@ -3018,6 +2878,7 @@ "id": "a9c75502-d60a-d89b-5912-f046100cd47e", "name": "OT", "mode": "instance", + "description": "OT--201", "physicalType": { "coding": [ { @@ -3032,6 +2893,31 @@ "url": "Location/a9c75502-d60a-d89b-5912-f046100cd47e" } }, + { + "fullUrl": "urn:uuid:55f70355-863d-579a-b4aa-81fcaf3e1fb0", + "resource": { + "resourceType": "Location", + "id": "55f70355-863d-579a-b4aa-81fcaf3e1fb0", + "partOf": { + "reference": "Location/a9c75502-d60a-d89b-5912-f046100cd47e" + }, + "name": "201", + "mode": "instance", + "description": "OT--201", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/55f70355-863d-579a-b4aa-81fcaf3e1fb0" + } + }, { "fullUrl": "urn:uuid:2e2e33a1-60f8-7e38-c827-fe070237c3fb", "resource": { @@ -3987,6 +3873,9 @@ ] } ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, "extension": [ { "url": "http://example.com/v2-to-fhir-converter/Observation_Status", @@ -4356,19 +4245,6 @@ }, "system": "http://www.examplehealthplan.com/fhir/policyidentifier" }, - { - "value": "HMO-12345", - "type": { - "coding": [ - { - "code": "NI", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203", - "display": "National unique individual identifier" - } - ] - }, - "system": "urn:oid:2.16.840.1.113883.1.3" - }, { "value": "Medicare-12345", "type": { diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A14/ADT-A14-expected-2.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A14/ADT-A14-02-expected.json similarity index 87% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A14/ADT-A14-expected-2.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A14/ADT-A14-02-expected.json index 1a9090266..78574d69c 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A14/ADT-A14-expected-2.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A14/ADT-A14-02-expected.json @@ -58,13 +58,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:23:27.131Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A14.

" + "div": "

Resource bundle generated on 2021-10-29T11:43:25.443Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A14.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -106,7 +106,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { @@ -1139,6 +1139,81 @@ "url": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" } }, + { + "fullUrl": "urn:uuid:24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "resource": { + "resourceType": "Organization", + "id": "24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "identifier": [ + { + "value": "TE", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TE" + }, + { + "value": "Provider Master.Community Health and Hospitals", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "type": { + "coding": [ + { + "code": "DNS", + "display": "An Internet host name, in accordance with RFC 1035; or an IP address. Either in ASCII or as integers, with periods between components (“dotted” notation).", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + } + }, + { + "fullUrl": "urn:uuid:36e3aaa4-569a-7d9d-037f-27235ed05701", + "resource": { + "resourceType": "Practitioner", + "id": "36e3aaa4-569a-7d9d-037f-27235ed05701", + "identifier": [ + { + "value": "12188", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "assigner": { + "reference": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + }, + "type": { + "coding": [ + { + "code": "DN", + "display": "Doctor number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Hippocrates", + "given": [ + "Harold", + "H" + ], + "suffix": [ + "IV", + "MD" + ], + "prefix": [ + "Dr" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + }, { "fullUrl": "urn:uuid:9172e4a0-1ca5-646d-2183-b179f4daa737", "resource": { @@ -1155,6 +1230,7 @@ } ], "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1179,6 +1255,7 @@ }, "name": "OMU B", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1203,6 +1280,7 @@ }, "name": "Bed 03", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1224,6 +1302,7 @@ "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", "name": "HOMERTON UNIVER", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1248,6 +1327,7 @@ }, "name": "Homerton UH", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1272,6 +1352,7 @@ }, "name": "Floor5", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1293,6 +1374,7 @@ "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", "name": "4 East, room 136, bed B 4E", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1317,6 +1399,7 @@ }, "name": "136", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1341,6 +1424,7 @@ }, "name": "B", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1362,6 +1446,7 @@ "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", "name": "CommunityHospital", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1409,6 +1494,7 @@ "id": "84634858-74aa-5cdb-4547-60ec27339ac6", "name": "POC", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1433,6 +1519,7 @@ }, "name": "Room-2", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1457,6 +1544,7 @@ }, "name": "Bed-103", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1478,6 +1566,7 @@ "id": "055e10f1-222e-df73-2325-0e4396db1a55", "name": "Greenland", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1499,6 +1588,7 @@ "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", "name": "Nursing home", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1520,6 +1610,7 @@ "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", "name": "Rosewood", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1534,6 +1625,131 @@ "url": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" } }, + { + "fullUrl": "urn:uuid:c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "resource": { + "resourceType": "Location", + "id": "c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "name": "ROOM1", + "identifier": [ + { + "value": "urn:oid:2.16.840.1.113883.4.642.1.1108", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + } + }, + { + "fullUrl": "urn:uuid:6f159848-5f01-01b3-9594-80fbbe9ab510", + "resource": { + "resourceType": "Location", + "id": "6f159848-5f01-01b3-9594-80fbbe9ab510", + "partOf": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "name": "BED1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" + } + }, + { + "fullUrl": "urn:uuid:4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "resource": { + "resourceType": "Location", + "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "name": "FACILITY1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + } + }, + { + "fullUrl": "urn:uuid:3b0911cb-4361-cd8d-b188-463af033c699", + "resource": { + "resourceType": "Location", + "id": "3b0911cb-4361-cd8d-b188-463af033c699", + "partOf": { + "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + }, + "name": "BUILDING1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, { "fullUrl": "urn:uuid:08314073-410a-3dc7-512c-0f2d206fb59d", "resource": { @@ -1615,36 +1831,6 @@ "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, { "status": "completed", "location": { @@ -1657,42 +1843,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "planned", "location": { @@ -1705,42 +1855,6 @@ } ] }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "completed", "location": { @@ -1754,14 +1868,14 @@ ] }, { - "status": "completed", + "status": "planned", "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" }, "extension": [ { "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true + "valueBoolean": false } ] } @@ -1922,6 +2036,22 @@ "individual": { "reference": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } } ], "serviceType": { @@ -1966,15 +2096,67 @@ } ], "period": { - "start": "2015-02-08T15:54:19+05:30" + "start": "2015-02-08T15:54:19+05:30", + "end": "2015-02-09T15:54:19+05:30" + }, + "reasonCode": [ + { + "coding": [ + { + "code": "140004", + "display": "Chronic pharyngitis", + "system": "http://snomed.info/sct" + } + ] + } + ], + "length": { + "value": 2, + "unit": "d", + "system": "http://unitsofmeasure.org/" + }, + "meta": { + "security": [ + { + "code": "N", + "display": "normal", + "system": "http://terminology.hl7.org/CodeSystem/v3-Confidentiality" + } + ] }, "text": { "status": "generated", - "div": "

Visit Description:

" + "div": "

Visit Description: Health Checkup

" + }, + "priority": { + "coding": [ + { + "code": "UR", + "display": "urgent", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.2" + }, + { + "code": "EL", + "display": "elective", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.3" + } + ] }, "subject": { "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" - } + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/encounter-modeOfArrival", + "valueCoding": { + "code": "C", + "display": "Car", + "system": "http://terminology.hl7.org/CodeSystem/v2-0430" + } + } + ] }, "request": { "method": "PUT", diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A15/ADT-A15-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A15/ADT-A15-01-expected.json similarity index 93% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A15/ADT-A15-expected.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A15/ADT-A15-01-expected.json index d92012579..0a0068d4d 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A15/ADT-A15-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A15/ADT-A15-01-expected.json @@ -60,13 +60,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:28:37.319Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A15.

" + "div": "

Resource bundle generated on 2021-10-29T11:45:27.133Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A15.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -108,7 +108,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { @@ -1363,6 +1363,7 @@ } ], "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1387,6 +1388,7 @@ }, "name": "OMU B", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1411,6 +1413,7 @@ }, "name": "Bed 03", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1432,6 +1435,7 @@ "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", "name": "HOMERTON UNIVER", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1456,6 +1460,7 @@ }, "name": "Homerton UH", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1480,6 +1485,7 @@ }, "name": "Floor5", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1501,6 +1507,7 @@ "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", "name": "4 East, room 136, bed B 4E", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1525,6 +1532,7 @@ }, "name": "136", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1549,6 +1557,7 @@ }, "name": "B", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1570,6 +1579,7 @@ "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", "name": "CommunityHospital", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1617,6 +1627,7 @@ "id": "84634858-74aa-5cdb-4547-60ec27339ac6", "name": "POC", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1641,6 +1652,7 @@ }, "name": "Room-2", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1665,6 +1677,7 @@ }, "name": "Bed-103", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1686,6 +1699,7 @@ "id": "055e10f1-222e-df73-2325-0e4396db1a55", "name": "Greenland", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1707,6 +1721,7 @@ "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", "name": "Nursing home", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1728,6 +1743,7 @@ "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", "name": "Rosewood", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1755,6 +1771,7 @@ } ], "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -1779,6 +1796,7 @@ }, "name": "BED1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -1800,6 +1818,7 @@ "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", "name": "FACILITY1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -1824,6 +1843,7 @@ }, "name": "BUILDING1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -1848,6 +1868,7 @@ }, "name": "FLOOR1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -1897,7 +1918,7 @@ "resource": { "resourceType": "EpisodeOfCare", "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", - "status": "planned", + "status": "active", "identifier": [ { "value": "EOC124", @@ -1935,44 +1956,14 @@ "display": "pre-admission", "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" }, - "status": "planned", + "status": "in-progress", "location": [ { - "status": "planned", + "status": "active", "location": { "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, { "status": "completed", "location": { @@ -1985,42 +1976,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "planned", "location": { @@ -2033,42 +1988,6 @@ } ] }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "completed", "location": { @@ -2081,18 +2000,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true - } - ] - }, { "status": "planned", "location": { @@ -2104,54 +2011,6 @@ "valueBoolean": false } ] - }, - { - "status": "planned", - "location": { - "reference": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] } ], "type": [ @@ -2369,9 +2228,6 @@ } } ], - "period": { - "start": "2015-02-08T15:54:19+05:30" - }, "reasonCode": [ { "coding": [ @@ -2973,6 +2829,9 @@ ] } ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, "extension": [ { "url": "http://example.com/v2-to-fhir-converter/Observation_Status", diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A15/ADT-A15-expected-2.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A15/ADT-A15-02-expected.json similarity index 93% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A15/ADT-A15-expected-2.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A15/ADT-A15-02-expected.json index 79e6d4be3..29df87fa2 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A15/ADT-A15-expected-2.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A15/ADT-A15-02-expected.json @@ -58,13 +58,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:28:03.014Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A15.

" + "div": "

Resource bundle generated on 2021-10-29T11:44:56.071Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A15.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -106,7 +106,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { @@ -1155,6 +1155,7 @@ } ], "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1179,6 +1180,7 @@ }, "name": "OMU B", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1203,6 +1205,7 @@ }, "name": "Bed 03", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1224,6 +1227,7 @@ "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", "name": "HOMERTON UNIVER", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1248,6 +1252,7 @@ }, "name": "Homerton UH", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1272,6 +1277,7 @@ }, "name": "Floor5", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1293,6 +1299,7 @@ "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", "name": "4 East, room 136, bed B 4E", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1317,6 +1324,7 @@ }, "name": "136", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1341,6 +1349,7 @@ }, "name": "B", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1362,6 +1371,7 @@ "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", "name": "CommunityHospital", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1409,6 +1419,7 @@ "id": "84634858-74aa-5cdb-4547-60ec27339ac6", "name": "POC", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1433,6 +1444,7 @@ }, "name": "Room-2", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1457,6 +1469,7 @@ }, "name": "Bed-103", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1478,6 +1491,7 @@ "id": "055e10f1-222e-df73-2325-0e4396db1a55", "name": "Greenland", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1499,6 +1513,7 @@ "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", "name": "Nursing home", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1520,6 +1535,7 @@ "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", "name": "Rosewood", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1569,7 +1585,7 @@ "resource": { "resourceType": "EpisodeOfCare", "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", - "status": "planned", + "status": "active", "identifier": [ { "value": "EOC124", @@ -1607,44 +1623,14 @@ "display": "pre-admission", "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" }, - "status": "planned", + "status": "in-progress", "location": [ { - "status": "planned", + "status": "active", "location": { "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, { "status": "completed", "location": { @@ -1657,42 +1643,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "planned", "location": { @@ -1705,42 +1655,6 @@ } ] }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "completed", "location": { @@ -1752,18 +1666,6 @@ "valueBoolean": true } ] - }, - { - "status": "completed", - "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true - } - ] } ], "type": [ diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A16/ADT-A16-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A16/ADT-A16-01-expected.json similarity index 95% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A16/ADT-A16-expected.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A16/ADT-A16-01-expected.json index c9e2ea7f2..29b453513 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A16/ADT-A16-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A16/ADT-A16-01-expected.json @@ -60,13 +60,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:31:29.335Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A16.

" + "div": "

Resource bundle generated on 2021-10-29T09:49:54.877Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A16.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -108,7 +108,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { @@ -1649,6 +1649,7 @@ } ], "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1673,6 +1674,7 @@ }, "name": "OMU B", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1697,6 +1699,7 @@ }, "name": "Bed 03", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1718,6 +1721,7 @@ "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", "name": "HOMERTON UNIVER", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1742,6 +1746,7 @@ }, "name": "Homerton UH", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1766,6 +1771,7 @@ }, "name": "Floor5", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1787,6 +1793,7 @@ "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", "name": "4 East, room 136, bed B 4E", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1811,6 +1818,7 @@ }, "name": "136", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1835,6 +1843,7 @@ }, "name": "B", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1856,6 +1865,7 @@ "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", "name": "CommunityHospital", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1903,6 +1913,7 @@ "id": "84634858-74aa-5cdb-4547-60ec27339ac6", "name": "POC", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1927,6 +1938,7 @@ }, "name": "Room-2", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1951,6 +1963,7 @@ }, "name": "Bed-103", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1972,6 +1985,7 @@ "id": "055e10f1-222e-df73-2325-0e4396db1a55", "name": "Greenland", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1993,6 +2007,7 @@ "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", "name": "Nursing home", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -2014,6 +2029,7 @@ "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", "name": "Rosewood", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -2041,6 +2057,7 @@ } ], "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2065,6 +2082,7 @@ }, "name": "BED1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2086,6 +2104,7 @@ "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", "name": "FACILITY1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2110,6 +2129,7 @@ }, "name": "BUILDING1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2134,6 +2154,7 @@ }, "name": "FLOOR1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2183,7 +2204,7 @@ "resource": { "resourceType": "EpisodeOfCare", "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", - "status": "planned", + "status": "active", "identifier": [ { "value": "EOC124", @@ -2238,44 +2259,14 @@ "display": "pre-admission", "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" }, - "status": "planned", + "status": "in-progress", "location": [ { - "status": "planned", + "status": "active", "location": { "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, { "status": "completed", "location": { @@ -2288,42 +2279,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "planned", "location": { @@ -2336,42 +2291,6 @@ } ] }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "completed", "location": { @@ -2384,18 +2303,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true - } - ] - }, { "status": "planned", "location": { @@ -2407,54 +2314,6 @@ "valueBoolean": false } ] - }, - { - "status": "planned", - "location": { - "reference": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] } ], "type": [ @@ -2673,7 +2532,8 @@ } ], "period": { - "start": "2015-02-08T15:54:19+05:30" + "start": "2015-02-08T15:54:19+05:30", + "end": "2015-02-10T15:54:19+05:30" }, "reasonCode": [ { @@ -3018,6 +2878,7 @@ "id": "a9c75502-d60a-d89b-5912-f046100cd47e", "name": "OT", "mode": "instance", + "description": "OT--201", "physicalType": { "coding": [ { @@ -3032,6 +2893,31 @@ "url": "Location/a9c75502-d60a-d89b-5912-f046100cd47e" } }, + { + "fullUrl": "urn:uuid:55f70355-863d-579a-b4aa-81fcaf3e1fb0", + "resource": { + "resourceType": "Location", + "id": "55f70355-863d-579a-b4aa-81fcaf3e1fb0", + "partOf": { + "reference": "Location/a9c75502-d60a-d89b-5912-f046100cd47e" + }, + "name": "201", + "mode": "instance", + "description": "OT--201", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/55f70355-863d-579a-b4aa-81fcaf3e1fb0" + } + }, { "fullUrl": "urn:uuid:2e2e33a1-60f8-7e38-c827-fe070237c3fb", "resource": { @@ -3987,6 +3873,9 @@ ] } ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, "extension": [ { "url": "http://example.com/v2-to-fhir-converter/Observation_Status", @@ -4356,19 +4245,6 @@ }, "system": "http://www.examplehealthplan.com/fhir/policyidentifier" }, - { - "value": "HMO-12345", - "type": { - "coding": [ - { - "code": "NI", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203", - "display": "National unique individual identifier" - } - ] - }, - "system": "urn:oid:2.16.840.1.113883.1.3" - }, { "value": "Medicare-12345", "type": { diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A16/ADT-A16-expected-2.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A16/ADT-A16-02-expected.json similarity index 87% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A16/ADT-A16-expected-2.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A16/ADT-A16-02-expected.json index b1ef585e5..850c9d99d 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A16/ADT-A16-expected-2.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A16/ADT-A16-02-expected.json @@ -58,13 +58,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:30:29.013Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A16.

" + "div": "

Resource bundle generated on 2021-10-29T10:00:57.265Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A16.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -106,7 +106,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { @@ -1139,6 +1139,81 @@ "url": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" } }, + { + "fullUrl": "urn:uuid:24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "resource": { + "resourceType": "Organization", + "id": "24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "identifier": [ + { + "value": "TE", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TE" + }, + { + "value": "Provider Master.Community Health and Hospitals", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "type": { + "coding": [ + { + "code": "DNS", + "display": "An Internet host name, in accordance with RFC 1035; or an IP address. Either in ASCII or as integers, with periods between components (“dotted” notation).", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + } + }, + { + "fullUrl": "urn:uuid:36e3aaa4-569a-7d9d-037f-27235ed05701", + "resource": { + "resourceType": "Practitioner", + "id": "36e3aaa4-569a-7d9d-037f-27235ed05701", + "identifier": [ + { + "value": "12188", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "assigner": { + "reference": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + }, + "type": { + "coding": [ + { + "code": "DN", + "display": "Doctor number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Hippocrates", + "given": [ + "Harold", + "H" + ], + "suffix": [ + "IV", + "MD" + ], + "prefix": [ + "Dr" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + }, { "fullUrl": "urn:uuid:9172e4a0-1ca5-646d-2183-b179f4daa737", "resource": { @@ -1155,6 +1230,7 @@ } ], "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1179,6 +1255,7 @@ }, "name": "OMU B", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1203,6 +1280,7 @@ }, "name": "Bed 03", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1224,6 +1302,7 @@ "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", "name": "HOMERTON UNIVER", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1248,6 +1327,7 @@ }, "name": "Homerton UH", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1272,6 +1352,7 @@ }, "name": "Floor5", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1293,6 +1374,7 @@ "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", "name": "4 East, room 136, bed B 4E", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1317,6 +1399,7 @@ }, "name": "136", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1341,6 +1424,7 @@ }, "name": "B", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1362,6 +1446,7 @@ "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", "name": "CommunityHospital", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1409,6 +1494,7 @@ "id": "84634858-74aa-5cdb-4547-60ec27339ac6", "name": "POC", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1433,6 +1519,7 @@ }, "name": "Room-2", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1457,6 +1544,7 @@ }, "name": "Bed-103", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1478,6 +1566,7 @@ "id": "055e10f1-222e-df73-2325-0e4396db1a55", "name": "Greenland", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1499,6 +1588,7 @@ "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", "name": "Nursing home", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1520,6 +1610,7 @@ "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", "name": "Rosewood", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1534,6 +1625,131 @@ "url": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" } }, + { + "fullUrl": "urn:uuid:c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "resource": { + "resourceType": "Location", + "id": "c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "name": "ROOM1", + "identifier": [ + { + "value": "urn:oid:2.16.840.1.113883.4.642.1.1108", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + } + }, + { + "fullUrl": "urn:uuid:6f159848-5f01-01b3-9594-80fbbe9ab510", + "resource": { + "resourceType": "Location", + "id": "6f159848-5f01-01b3-9594-80fbbe9ab510", + "partOf": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "name": "BED1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" + } + }, + { + "fullUrl": "urn:uuid:4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "resource": { + "resourceType": "Location", + "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "name": "FACILITY1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + } + }, + { + "fullUrl": "urn:uuid:3b0911cb-4361-cd8d-b188-463af033c699", + "resource": { + "resourceType": "Location", + "id": "3b0911cb-4361-cd8d-b188-463af033c699", + "partOf": { + "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + }, + "name": "BUILDING1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, { "fullUrl": "urn:uuid:08314073-410a-3dc7-512c-0f2d206fb59d", "resource": { @@ -1569,7 +1785,7 @@ "resource": { "resourceType": "EpisodeOfCare", "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", - "status": "planned", + "status": "active", "identifier": [ { "value": "EOC124", @@ -1607,44 +1823,14 @@ "display": "pre-admission", "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" }, - "status": "planned", + "status": "in-progress", "location": [ { - "status": "planned", + "status": "active", "location": { "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, { "status": "completed", "location": { @@ -1657,42 +1843,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "planned", "location": { @@ -1705,42 +1855,6 @@ } ] }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "completed", "location": { @@ -1754,14 +1868,14 @@ ] }, { - "status": "completed", + "status": "planned", "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" }, "extension": [ { "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true + "valueBoolean": false } ] } @@ -1922,6 +2036,22 @@ "individual": { "reference": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } } ], "serviceType": { @@ -1966,15 +2096,67 @@ } ], "period": { - "start": "2015-02-08T15:54:19+05:30" + "start": "2015-02-08T15:54:19+05:30", + "end": "2015-02-10T15:54:19+05:30" + }, + "reasonCode": [ + { + "coding": [ + { + "code": "140004", + "display": "Chronic pharyngitis", + "system": "http://snomed.info/sct" + } + ] + } + ], + "length": { + "value": 2, + "unit": "d", + "system": "http://unitsofmeasure.org/" + }, + "meta": { + "security": [ + { + "code": "N", + "display": "normal", + "system": "http://terminology.hl7.org/CodeSystem/v3-Confidentiality" + } + ] }, "text": { "status": "generated", - "div": "

Visit Description:

" + "div": "

Visit Description: Health Checkup

" + }, + "priority": { + "coding": [ + { + "code": "UR", + "display": "urgent", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.2" + }, + { + "code": "EL", + "display": "elective", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.3" + } + ] }, "subject": { "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" - } + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/encounter-modeOfArrival", + "valueCoding": { + "code": "C", + "display": "Car", + "system": "http://terminology.hl7.org/CodeSystem/v2-0430" + } + } + ] }, "request": { "method": "PUT", diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A25/ADT-A25-01-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A25/ADT-A25-01-expected.json new file mode 100644 index 000000000..2663a6b38 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A25/ADT-A25-01-expected.json @@ -0,0 +1,2890 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "1989-08-18T14:41:00+05:30", + "identifier": { + "value": "MSG00001" + }, + "id": "513a3d06-5e87-6fbc-ad1b-170ab430499f", + "entry": [ + { + "fullUrl": "urn:uuid:b4ca189b-51ae-33df-cbe2-559b4423a321", + "resource": { + "resourceType": "MessageHeader", + "id": "b4ca189b-51ae-33df-cbe2-559b4423a321", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20", + "version": "2.4.3.52854", + "software": "Rhapsody" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "A25", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "ADT^A25^ADT_A25" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/b4ca189b-51ae-33df-cbe2-559b4423a321" + } + }, + { + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "resource": { + "resourceType": "Provenance", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T10:08:15.356Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A25.

" + }, + "occurredDateTime": "1989-08-18T14:41:00+05:30", + "recorded": "1989-08-18T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "ADT^A25^ADT_A25" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + } + ], + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:503eb873-22fb-8199-ae28-3604ad59fe13", + "resource": { + "resourceType": "Device", + "id": "503eb873-22fb-8199-ae28-3604ad59fe13", + "identifier": [ + { + "value": "ADTApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + }, + { + "fullUrl": "urn:uuid:4b549918-a84d-cdaf-e150-c773a5d306e5", + "resource": { + "resourceType": "Device", + "id": "4b549918-a84d-cdaf-e150-c773a5d306e5", + "manufacturer": "Orion", + "deviceName": [ + { + "name": "Rhapsody", + "type": "manufacturer-name" + } + ], + "version": [ + { + "value": "2.4.3.52854" + } + ], + "modelNumber": "2.4.3", + "note": [ + { + "text": "Testactivity" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/4b549918-a84d-cdaf-e150-c773a5d306e5" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + }, + { + "value": "DB123", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "urn:oid:1.12", + "assigner": { + "reference": "Organization/4e68b44e-c053-02b1-6d6d-fe816f9fdfec" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "generalPractitioner": [ + { + "reference": "Organization/4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11" + }, + { + "reference": "Practitioner/76aaad38-1077-6a5c-0c5c-102ec160a60d" + } + ], + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/VeteranMilitaryStatus", + "valueCodeableConcept": { + "coding": [ + { + "code": "Vet123", + "display": "retired", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ART" + } + ], + "text": "retired" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-animal", + "extension": [ + { + "url": "species", + "valueCodeableConcept": { + "coding": [ + { + "code": "125097000", + "display": "Goat", + "system": "http://snomed.info/sct" + } + ], + "text": "Goat" + } + }, + { + "url": "breed", + "valueCodeableConcept": { + "coding": [ + { + "code": "4880003", + "display": "Beagle", + "system": "http://snomed.info/sct" + } + ], + "text": "Beagle" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-nationality", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "BT", + "display": "Bhutan", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Bhutan" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-congregation", + "valueString": "Methodist Church" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-importance", + "valueCodeableConcept": { + "coding": [ + { + "code": "VIP", + "display": "Very Important Person", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L", + "version": "v1.1" + }, + { + "code": "IMP", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/DCM", + "version": "v1.2" + } + ], + "text": "Inportant Person" + } + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/patient-disabilityIndicator", + "valueBoolean": true + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/DisabilityPeriod", + "valuePeriod": { + "start": "2021-08-30", + "end": "2021-09-30" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11", + "resource": { + "resourceType": "Organization", + "id": "4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11", + "name": "LINDAS TEST ORGANIZATION", + "identifier": [ + { + "value": "SIISCLIENT818" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11" + } + }, + { + "fullUrl": "urn:uuid:76aaad38-1077-6a5c-0c5c-102ec160a60d", + "resource": { + "resourceType": "Practitioner", + "id": "76aaad38-1077-6a5c-0c5c-102ec160a60d", + "identifier": [ + { + "value": "88", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TE", + "type": { + "coding": [ + { + "code": "DN", + "display": "Doctor number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Hippo", + "given": [ + "rold", + "H" + ], + "suffix": [ + "V", + "MD" + ], + "prefix": [ + "Dr" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/76aaad38-1077-6a5c-0c5c-102ec160a60d" + } + }, + { + "fullUrl": "urn:uuid:11967e28-8dd4-a112-0fdc-377866bf12a0", + "resource": { + "resourceType": "Organization", + "id": "11967e28-8dd4-a112-0fdc-377866bf12a0", + "identifier": [ + { + "value": "t", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-t" + }, + { + "value": "2.16.840.1.113883.19", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + } + }, + { + "fullUrl": "urn:uuid:7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "resource": { + "resourceType": "Organization", + "id": "7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "identifier": [ + { + "value": "AccMng", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMng" + }, + { + "value": "1.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + } + }, + { + "fullUrl": "urn:uuid:0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "resource": { + "resourceType": "Organization", + "id": "0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "identifier": [ + { + "value": "PERSONNELt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSONNELt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + } + }, + { + "fullUrl": "urn:uuid:f6775f99-5279-be04-bf81-0906c81f7443", + "resource": { + "resourceType": "Practitioner", + "id": "f6775f99-5279-be04-bf81-0906c81f7443", + "identifier": [ + { + "value": "1122334", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Alaz", + "given": [ + "Mohammed", + "Mahi" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "fullUrl": "urn:uuid:c613d7b2-525f-8c08-a7ac-b2b91486e257", + "resource": { + "resourceType": "Organization", + "id": "c613d7b2-525f-8c08-a7ac-b2b91486e257", + "identifier": [ + { + "value": "TEST", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TEST" + }, + { + "value": "23.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + } + }, + { + "fullUrl": "urn:uuid:04f8cfc8-62ca-12df-63ce-6304ef577d44", + "resource": { + "resourceType": "Practitioner", + "id": "04f8cfc8-62ca-12df-63ce-6304ef577d44", + "identifier": [ + { + "value": "C006", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + }, + "type": { + "coding": [ + { + "code": "BA", + "display": "Bank Account Number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen" + ], + "prefix": [ + "Dr" + ], + "use": "anonymous" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "fullUrl": "urn:uuid:99edcabd-fbeb-7e25-f823-11da8d8ed342", + "resource": { + "resourceType": "Practitioner", + "id": "99edcabd-fbeb-7e25-f823-11da8d8ed342", + "identifier": [ + { + "value": "C008", + "system": "urn:oid:2.8", + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Condoc", + "given": [ + "leen" + ], + "prefix": [ + "Dr" + ], + "use": "temp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "fullUrl": "urn:uuid:b065b233-8738-f1ec-1314-d61e4aac2c9e", + "resource": { + "resourceType": "Practitioner", + "id": "b065b233-8738-f1ec-1314-d61e4aac2c9e", + "identifier": [ + { + "value": "37", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr", + "type": { + "coding": [ + { + "code": "ANC", + "display": "Account number Creditor", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "DISNEY", + "given": [ + "WALT" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "fullUrl": "urn:uuid:9f974d4f-47e8-21a6-e549-4de4599c3764", + "resource": { + "resourceType": "Organization", + "id": "9f974d4f-47e8-21a6-e549-4de4599c3764", + "identifier": [ + { + "value": "T123", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-T123" + }, + { + "value": "urn:oid:r2.3", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + }, + { + "fullUrl": "urn:uuid:84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "resource": { + "resourceType": "Practitioner", + "id": "84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "identifier": [ + { + "value": "Othhel", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "fullUrl": "urn:uuid:24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "resource": { + "resourceType": "Organization", + "id": "24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "identifier": [ + { + "value": "TE", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TE" + }, + { + "value": "Provider Master.Community Health and Hospitals", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "type": { + "coding": [ + { + "code": "DNS", + "display": "An Internet host name, in accordance with RFC 1035; or an IP address. Either in ASCII or as integers, with periods between components (“dotted” notation).", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + } + }, + { + "fullUrl": "urn:uuid:36e3aaa4-569a-7d9d-037f-27235ed05701", + "resource": { + "resourceType": "Practitioner", + "id": "36e3aaa4-569a-7d9d-037f-27235ed05701", + "identifier": [ + { + "value": "12188", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "assigner": { + "reference": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + }, + "type": { + "coding": [ + { + "code": "DN", + "display": "Doctor number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Hippocrates", + "given": [ + "Harold", + "H" + ], + "suffix": [ + "IV", + "MD" + ], + "prefix": [ + "Dr" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + }, + { + "fullUrl": "urn:uuid:9172e4a0-1ca5-646d-2183-b179f4daa737", + "resource": { + "resourceType": "Location", + "id": "9172e4a0-1ca5-646d-2183-b179f4daa737", + "partOf": { + "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + }, + "name": "HUH AE OMU", + "identifier": [ + { + "value": "urn:oid:9.8", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "fullUrl": "urn:uuid:3913ec4d-6576-5e1a-ac31-e8280583371c", + "resource": { + "resourceType": "Location", + "id": "3913ec4d-6576-5e1a-ac31-e8280583371c", + "partOf": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + }, + "name": "OMU B", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + } + }, + { + "fullUrl": "urn:uuid:804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "resource": { + "resourceType": "Location", + "id": "804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "partOf": { + "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + }, + "name": "Bed 03", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" + } + }, + { + "fullUrl": "urn:uuid:c043880b-0fab-1cb8-14f7-0475282c4d0e", + "resource": { + "resourceType": "Location", + "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", + "name": "HOMERTON UNIVER", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + } + }, + { + "fullUrl": "urn:uuid:f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "resource": { + "resourceType": "Location", + "id": "f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "partOf": { + "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + }, + "name": "Homerton UH", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + } + }, + { + "fullUrl": "urn:uuid:7e38808c-44a8-cb0c-4709-9d6092abc32c", + "resource": { + "resourceType": "Location", + "id": "7e38808c-44a8-cb0c-4709-9d6092abc32c", + "partOf": { + "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + }, + "name": "Floor5", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + } + }, + { + "fullUrl": "urn:uuid:59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "resource": { + "resourceType": "Location", + "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "name": "4 East, room 136, bed B 4E", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + } + }, + { + "fullUrl": "urn:uuid:d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "resource": { + "resourceType": "Location", + "id": "d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "partOf": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "name": "136", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + } + }, + { + "fullUrl": "urn:uuid:5783dafa-c6c0-e673-cca4-42087ee1831b", + "resource": { + "resourceType": "Location", + "id": "5783dafa-c6c0-e673-cca4-42087ee1831b", + "partOf": { + "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + }, + "name": "B", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" + } + }, + { + "fullUrl": "urn:uuid:8b39e6e5-78cd-63ab-2441-f43ca5554096", + "resource": { + "resourceType": "Location", + "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", + "name": "CommunityHospital", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" + } + }, + { + "fullUrl": "urn:uuid:42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "resource": { + "resourceType": "Location", + "id": "42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "name": "Homes", + "identifier": [ + { + "value": "22", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/FDK" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + { + "fullUrl": "urn:uuid:84634858-74aa-5cdb-4547-60ec27339ac6", + "resource": { + "resourceType": "Location", + "id": "84634858-74aa-5cdb-4547-60ec27339ac6", + "name": "POC", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + } + }, + { + "fullUrl": "urn:uuid:9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", + "resource": { + "resourceType": "Location", + "id": "9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", + "partOf": { + "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + }, + "name": "Room-2", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" + } + }, + { + "fullUrl": "urn:uuid:35353f20-6254-e794-98ed-8007490447e3", + "resource": { + "resourceType": "Location", + "id": "35353f20-6254-e794-98ed-8007490447e3", + "partOf": { + "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" + }, + "name": "Bed-103", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/35353f20-6254-e794-98ed-8007490447e3" + } + }, + { + "fullUrl": "urn:uuid:055e10f1-222e-df73-2325-0e4396db1a55", + "resource": { + "resourceType": "Location", + "id": "055e10f1-222e-df73-2325-0e4396db1a55", + "name": "Greenland", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/055e10f1-222e-df73-2325-0e4396db1a55" + } + }, + { + "fullUrl": "urn:uuid:1154e6b2-b022-b3be-7dce-2b940ab5376d", + "resource": { + "resourceType": "Location", + "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", + "name": "Nursing home", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + } + }, + { + "fullUrl": "urn:uuid:08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "resource": { + "resourceType": "Location", + "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "name": "Rosewood", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" + } + }, + { + "fullUrl": "urn:uuid:c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "resource": { + "resourceType": "Location", + "id": "c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "name": "ROOM1", + "identifier": [ + { + "value": "urn:oid:2.16.840.1.113883.4.642.1.1108", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + } + }, + { + "fullUrl": "urn:uuid:6f159848-5f01-01b3-9594-80fbbe9ab510", + "resource": { + "resourceType": "Location", + "id": "6f159848-5f01-01b3-9594-80fbbe9ab510", + "partOf": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "name": "BED1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" + } + }, + { + "fullUrl": "urn:uuid:4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "resource": { + "resourceType": "Location", + "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "name": "FACILITY1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + } + }, + { + "fullUrl": "urn:uuid:3b0911cb-4361-cd8d-b188-463af033c699", + "resource": { + "resourceType": "Location", + "id": "3b0911cb-4361-cd8d-b188-463af033c699", + "partOf": { + "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + }, + "name": "BUILDING1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:08314073-410a-3dc7-512c-0f2d206fb59d", + "resource": { + "resourceType": "Organization", + "id": "08314073-410a-3dc7-512c-0f2d206fb59d", + "identifier": [ + { + "value": "Etest", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-Etest" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + }, + { + "fullUrl": "urn:uuid:919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "resource": { + "resourceType": "EpisodeOfCare", + "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "status": "active", + "identifier": [ + { + "value": "EOC124", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + }, + { + "fullUrl": "urn:uuid:4b192760-03d2-aec4-b0a6-fde323912e1e", + "resource": { + "resourceType": "Encounter", + "id": "4b192760-03d2-aec4-b0a6-fde323912e1e", + "class": { + "code": "PRENC", + "display": "pre-admission", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "in-progress", + "location": [ + { + "status": "active", + "location": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "status": "completed", + "location": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "status": "planned", + "location": { + "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "status": "completed", + "location": { + "reference": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": true + } + ] + }, + { + "status": "planned", + "location": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + } + ], + "type": [ + { + "coding": [ + { + "code": "E", + "display": "Emergency", + "system": "http://terminology.hl7.org/CodeSystem/v2-0007" + } + ] + } + ], + "hospitalization": { + "preAdmissionIdentifier": { + "value": "1234567", + "type": { + "coding": [ + { + "code": "ANON", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Anonymous identifier" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + "reAdmission": { + "coding": [ + { + "code": "R", + "display": "Re-admission", + "system": "http://terminology.hl7.org/CodeSystem/v2-0092" + } + ] + }, + "admitSource": { + "coding": [ + { + "code": "NHS Provider-General (inc.A&E-this Hosp)" + } + ] + }, + "dischargeDisposition": { + "coding": [ + { + "code": "Admitted as Inpatient", + "display": "Sample", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ACR" + } + ] + }, + "dietPreference": [ + { + "coding": [ + { + "code": "Vegan", + "display": "Vegetarian" + } + ] + } + ], + "destination": { + "reference": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + "episodeOfCare": [ + { + "reference": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "CON", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "consultant" + } + ], + "individual": { + "reference": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "ADM", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "admitter" + } + ], + "individual": { + "reference": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "PART", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "Participation" + } + ], + "individual": { + "reference": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + } + ], + "serviceType": { + "coding": [ + { + "code": "SUR" + } + ] + }, + "identifier": [ + { + "value": "40007716", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + }, + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + }, + { + "value": "50", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "urn:oid:r2.3", + "assigner": { + "reference": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + } + ], + "period": { + "start": "2015-02-08T15:54:19+05:30" + }, + "reasonCode": [ + { + "coding": [ + { + "code": "140004", + "display": "Chronic pharyngitis", + "system": "http://snomed.info/sct" + } + ] + } + ], + "length": { + "value": 2, + "unit": "d", + "system": "http://unitsofmeasure.org/" + }, + "meta": { + "security": [ + { + "code": "N", + "display": "normal", + "system": "http://terminology.hl7.org/CodeSystem/v3-Confidentiality" + } + ] + }, + "text": { + "status": "generated", + "div": "

Visit Description: Health Checkup

" + }, + "priority": { + "coding": [ + { + "code": "UR", + "display": "urgent", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.2" + }, + { + "code": "EL", + "display": "elective", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.3" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/encounter-modeOfArrival", + "valueCoding": { + "code": "C", + "display": "Car", + "system": "http://terminology.hl7.org/CodeSystem/v2-0430" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Encounter/4b192760-03d2-aec4-b0a6-fde323912e1e" + } + }, + { + "fullUrl": "urn:uuid:9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "resource": { + "resourceType": "Provenance", + "id": "9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "occurredDateTime": "2021-08-17T18:49:43.004+05:30", + "recorded": "2029-08-01T11:21:24+05:30", + "reason": [ + { + "coding": [ + { + "code": "PATRQT", + "display": "patient requested", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActReason" + } + ] + } + ], + "agent": [ + { + "who": { + "reference": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + } + ], + "activity": { + "text": "ADT^A25^ADT_A25" + }, + "location": { + "reference": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + }, + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c" + } + }, + { + "fullUrl": "urn:uuid:ef39f581-5e8f-3917-35a9-3443303d9eee", + "resource": { + "resourceType": "Organization", + "id": "ef39f581-5e8f-3917-35a9-3443303d9eee", + "identifier": [ + { + "value": "DRNBR", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-DRNBR" + }, + { + "value": "urn:oid:W1.2", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + } + }, + { + "fullUrl": "urn:uuid:95aea53b-8d49-d57f-d16f-4d14b914f992", + "resource": { + "resourceType": "Practitioner", + "id": "95aea53b-8d49-d57f-d16f-4d14b914f992", + "identifier": [ + { + "value": "C08", + "system": "urn:oid:W1.2", + "assigner": { + "reference": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + }, + "type": { + "coding": [ + { + "code": "ANON", + "display": "Anonymous identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen", + "2ndname" + ], + "suffix": [ + "Jr", + "MD" + ], + "prefix": [ + "Dr" + ], + "use": "official" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + }, + { + "fullUrl": "urn:uuid:59d5e519-0108-5dd8-adfa-1eef5658009e", + "resource": { + "resourceType": "Location", + "id": "59d5e519-0108-5dd8-adfa-1eef5658009e", + "name": "Cona_Health", + "identifier": [ + { + "value": "urn:oid:1.3.6.1.4.1.44750.1.4", + "system": "urn:ietf:rfc:3986" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "display": "site", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + } + }, + { + "fullUrl": "urn:uuid:4e68b44e-c053-02b1-6d6d-fe816f9fdfec", + "resource": { + "resourceType": "Organization", + "id": "4e68b44e-c053-02b1-6d6d-fe816f9fdfec", + "identifier": [ + { + "value": "t", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-t" + }, + { + "value": "urn:oid:1.12", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4e68b44e-c053-02b1-6d6d-fe816f9fdfec" + } + }, + { + "fullUrl": "urn:uuid:e82402a9-b2d1-2a28-3250-c099d5a77bf7", + "resource": { + "resourceType": "Organization", + "id": "e82402a9-b2d1-2a28-3250-c099d5a77bf7", + "identifier": [ + { + "value": "PERSt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/e82402a9-b2d1-2a28-3250-c099d5a77bf7" + } + }, + { + "fullUrl": "urn:uuid:ce70e6c3-c190-121d-c251-e4bae5cde6a1", + "resource": { + "resourceType": "Practitioner", + "id": "ce70e6c3-c190-121d-c251-e4bae5cde6a1", + "identifier": [ + { + "value": "1134", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/e82402a9-b2d1-2a28-3250-c099d5a77bf7" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Aly", + "given": [ + "Zafar", + "Mahendra" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/ce70e6c3-c190-121d-c251-e4bae5cde6a1" + } + }, + { + "fullUrl": "urn:uuid:88a53755-c972-6904-b4ce-8884b84ddc2e", + "resource": { + "resourceType": "PractitionerRole", + "id": "88a53755-c972-6904-b4ce-8884b84ddc2e", + "code": [ + { + "coding": [ + { + "code": "ResponsibleObserver", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/ce70e6c3-c190-121d-c251-e4bae5cde6a1" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/88a53755-c972-6904-b4ce-8884b84ddc2e" + } + }, + { + "fullUrl": "urn:uuid:3e0952c6-eea0-8938-96f8-07c224bf1577", + "resource": { + "resourceType": "Practitioner", + "id": "3e0952c6-eea0-8938-96f8-07c224bf1577", + "identifier": [ + { + "value": "2234" + } + ], + "name": [ + { + "family": "Pauly", + "given": [ + "Berrie", + "Raud" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/3e0952c6-eea0-8938-96f8-07c224bf1577" + } + }, + { + "fullUrl": "urn:uuid:bc78e290-ec67-c238-1e05-aefb6b252b0c", + "resource": { + "resourceType": "PractitionerRole", + "id": "bc78e290-ec67-c238-1e05-aefb6b252b0c", + "code": [ + { + "coding": [ + { + "code": "ResponsibleObserver", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/3e0952c6-eea0-8938-96f8-07c224bf1577" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/bc78e290-ec67-c238-1e05-aefb6b252b0c" + } + }, + { + "fullUrl": "urn:uuid:fe0adb86-ebe9-6479-0055-9db8dc1ff99a", + "resource": { + "resourceType": "Device", + "id": "fe0adb86-ebe9-6479-0055-9db8dc1ff99a", + "identifier": [ + { + "value": "EI12.3", + "system": "urn:uuid:UI2", + "type": { + "coding": [ + { + "code": "GUID", + "display": "Same as UUID.", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + }, + { + "system": "urn:oid:UI1", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/fe0adb86-ebe9-6479-0055-9db8dc1ff99a" + } + }, + { + "fullUrl": "urn:uuid:45f65e47-46c4-1a54-f9fb-1321258e79b2", + "resource": { + "resourceType": "Practitioner", + "id": "45f65e47-46c4-1a54-f9fb-1321258e79b2", + "identifier": [ + { + "type": { + "coding": [ + { + "code": "MD-25" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/45f65e47-46c4-1a54-f9fb-1321258e79b2" + } + }, + { + "fullUrl": "urn:uuid:090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3", + "resource": { + "resourceType": "PractitionerRole", + "id": "090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3", + "code": [ + { + "coding": [ + { + "code": "LabMedicalDirector", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/45f65e47-46c4-1a54-f9fb-1321258e79b2" + }, + "organization": { + "reference": "Organization/056aa7c7-6b75-3c67-63c5-cf9604f16d25" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3" + } + }, + { + "fullUrl": "urn:uuid:056aa7c7-6b75-3c67-63c5-cf9604f16d25", + "resource": { + "resourceType": "Organization", + "id": "056aa7c7-6b75-3c67-63c5-cf9604f16d25", + "name": "FairOaks Hspital", + "address": [ + { + "line": [ + "Research Park", + "Fairfax" + ], + "city": "VA", + "state": "22031", + "postalCode": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/056aa7c7-6b75-3c67-63c5-cf9604f16d25" + } + }, + { + "fullUrl": "urn:uuid:07fd2dd3-dbd6-5bb1-cfda-02226795d9a0", + "resource": { + "resourceType": "Observation", + "id": "07fd2dd3-dbd6-5bb1-cfda-02226795d9a0", + "identifier": [ + { + "value": "EI21", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-OII" + }, + { + "type": { + "coding": [ + { + "code": "FILL" + } + ] + } + } + ], + "status": "unknown", + "code": { + "coding": [ + { + "code": "8867-4", + "display": "heartrate", + "system": "http://loinc.org" + } + ] + }, + "component": [ + { + "code": { + "coding": [ + { + "code": "8867-4", + "display": "heartrate", + "system": "http://loinc.org" + } + ] + }, + "valueQuantity": { + "value": 60, + "code": "beats/min", + "unit": "beats/min", + "system": "urn:iso:std:iso:3986" + }, + "referenceRange": [ + { + "text": "70-80" + } + ] + }, + { + "code": { + "coding": [ + { + "code": "8867-4", + "display": "heartrate", + "system": "http://loinc.org" + } + ] + }, + "valueQuantity": { + "value": 120, + "code": "beats/min", + "unit": "beats/min", + "system": "urn:iso:std:iso:3986" + }, + "referenceRange": [ + { + "text": "70-80" + } + ] + } + ], + "effectiveDateTime": "1999-07-02", + "method": { + "coding": [ + { + "code": "OBS", + "display": "This is test method", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/AS4" + } + ] + }, + "device": { + "reference": "Device/fe0adb86-ebe9-6479-0055-9db8dc1ff99a" + }, + "bodySite": { + "coding": [ + { + "code": "BU", + "display": "Observation site", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/E5" + } + ] + }, + "performer": [ + { + "reference": "PractitionerRole/88a53755-c972-6904-b4ce-8884b84ddc2e" + }, + { + "reference": "PractitionerRole/bc78e290-ec67-c238-1e05-aefb6b252b0c" + }, + { + "reference": "PractitionerRole/090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3" + } + ], + "interpretation": [ + { + "coding": [ + { + "code": "A", + "display": "Abnormal", + "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation" + } + ] + }, + { + "coding": [ + { + "code": "B", + "display": "Better", + "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation" + } + ] + } + ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "S", + "display": "Partial", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Partial" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/07fd2dd3-dbd6-5bb1-cfda-02226795d9a0" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A25/ADT-A25-02-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A25/ADT-A25-02-expected.json new file mode 100644 index 000000000..820279490 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A25/ADT-A25-02-expected.json @@ -0,0 +1,2311 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "1989-08-18T14:41:00+05:30", + "identifier": { + "value": "MSG00001" + }, + "id": "513a3d06-5e87-6fbc-ad1b-170ab430499f", + "entry": [ + { + "fullUrl": "urn:uuid:b4ca189b-51ae-33df-cbe2-559b4423a321", + "resource": { + "resourceType": "MessageHeader", + "id": "b4ca189b-51ae-33df-cbe2-559b4423a321", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "A25", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "ADT^A25^ADT_A25" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/b4ca189b-51ae-33df-cbe2-559b4423a321" + } + }, + { + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "resource": { + "resourceType": "Provenance", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T10:13:12.393Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A25.

" + }, + "occurredDateTime": "1989-08-18T14:41:00+05:30", + "recorded": "1989-08-18T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "ADT^A25^ADT_A25" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + } + ], + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:503eb873-22fb-8199-ae28-3604ad59fe13", + "resource": { + "resourceType": "Device", + "id": "503eb873-22fb-8199-ae28-3604ad59fe13", + "identifier": [ + { + "value": "ADTApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/VeteranMilitaryStatus", + "valueCodeableConcept": { + "coding": [ + { + "code": "Vet123", + "display": "retired", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ART" + } + ], + "text": "retired" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-animal", + "extension": [ + { + "url": "species", + "valueCodeableConcept": { + "coding": [ + { + "code": "125097000", + "display": "Goat", + "system": "http://snomed.info/sct" + } + ], + "text": "Goat" + } + }, + { + "url": "breed", + "valueCodeableConcept": { + "coding": [ + { + "code": "4880003", + "display": "Beagle", + "system": "http://snomed.info/sct" + } + ], + "text": "Beagle" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-nationality", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "BT", + "display": "Bhutan", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Bhutan" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-importance", + "valueCodeableConcept": { + "coding": [ + { + "code": "VIP", + "display": "Very Important Person", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L", + "version": "v1.1" + }, + { + "code": "IMP", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/DCM", + "version": "v1.2" + } + ], + "text": "Inportant Person" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:11967e28-8dd4-a112-0fdc-377866bf12a0", + "resource": { + "resourceType": "Organization", + "id": "11967e28-8dd4-a112-0fdc-377866bf12a0", + "identifier": [ + { + "value": "t", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-t" + }, + { + "value": "2.16.840.1.113883.19", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + } + }, + { + "fullUrl": "urn:uuid:7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "resource": { + "resourceType": "Organization", + "id": "7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "identifier": [ + { + "value": "AccMng", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMng" + }, + { + "value": "1.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + } + }, + { + "fullUrl": "urn:uuid:0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "resource": { + "resourceType": "Organization", + "id": "0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "identifier": [ + { + "value": "PERSONNELt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSONNELt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + } + }, + { + "fullUrl": "urn:uuid:f6775f99-5279-be04-bf81-0906c81f7443", + "resource": { + "resourceType": "Practitioner", + "id": "f6775f99-5279-be04-bf81-0906c81f7443", + "identifier": [ + { + "value": "1122334", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Alaz", + "given": [ + "Mohammed", + "Mahi" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "fullUrl": "urn:uuid:c613d7b2-525f-8c08-a7ac-b2b91486e257", + "resource": { + "resourceType": "Organization", + "id": "c613d7b2-525f-8c08-a7ac-b2b91486e257", + "identifier": [ + { + "value": "TEST", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TEST" + }, + { + "value": "23.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + } + }, + { + "fullUrl": "urn:uuid:04f8cfc8-62ca-12df-63ce-6304ef577d44", + "resource": { + "resourceType": "Practitioner", + "id": "04f8cfc8-62ca-12df-63ce-6304ef577d44", + "identifier": [ + { + "value": "C006", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + }, + "type": { + "coding": [ + { + "code": "BA", + "display": "Bank Account Number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen" + ], + "prefix": [ + "Dr" + ], + "use": "anonymous" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "fullUrl": "urn:uuid:99edcabd-fbeb-7e25-f823-11da8d8ed342", + "resource": { + "resourceType": "Practitioner", + "id": "99edcabd-fbeb-7e25-f823-11da8d8ed342", + "identifier": [ + { + "value": "C008", + "system": "urn:oid:2.8", + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Condoc", + "given": [ + "leen" + ], + "prefix": [ + "Dr" + ], + "use": "temp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "fullUrl": "urn:uuid:b065b233-8738-f1ec-1314-d61e4aac2c9e", + "resource": { + "resourceType": "Practitioner", + "id": "b065b233-8738-f1ec-1314-d61e4aac2c9e", + "identifier": [ + { + "value": "37", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr", + "type": { + "coding": [ + { + "code": "ANC", + "display": "Account number Creditor", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "DISNEY", + "given": [ + "WALT" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "fullUrl": "urn:uuid:9f974d4f-47e8-21a6-e549-4de4599c3764", + "resource": { + "resourceType": "Organization", + "id": "9f974d4f-47e8-21a6-e549-4de4599c3764", + "identifier": [ + { + "value": "T123", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-T123" + }, + { + "value": "urn:oid:r2.3", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + }, + { + "fullUrl": "urn:uuid:84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "resource": { + "resourceType": "Practitioner", + "id": "84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "identifier": [ + { + "value": "Othhel", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "fullUrl": "urn:uuid:24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "resource": { + "resourceType": "Organization", + "id": "24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "identifier": [ + { + "value": "TE", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TE" + }, + { + "value": "Provider Master.Community Health and Hospitals", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "type": { + "coding": [ + { + "code": "DNS", + "display": "An Internet host name, in accordance with RFC 1035; or an IP address. Either in ASCII or as integers, with periods between components (“dotted” notation).", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + } + }, + { + "fullUrl": "urn:uuid:36e3aaa4-569a-7d9d-037f-27235ed05701", + "resource": { + "resourceType": "Practitioner", + "id": "36e3aaa4-569a-7d9d-037f-27235ed05701", + "identifier": [ + { + "value": "12188", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "assigner": { + "reference": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + }, + "type": { + "coding": [ + { + "code": "DN", + "display": "Doctor number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Hippocrates", + "given": [ + "Harold", + "H" + ], + "suffix": [ + "IV", + "MD" + ], + "prefix": [ + "Dr" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + }, + { + "fullUrl": "urn:uuid:9172e4a0-1ca5-646d-2183-b179f4daa737", + "resource": { + "resourceType": "Location", + "id": "9172e4a0-1ca5-646d-2183-b179f4daa737", + "partOf": { + "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + }, + "name": "HUH AE OMU", + "identifier": [ + { + "value": "urn:oid:9.8", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "fullUrl": "urn:uuid:3913ec4d-6576-5e1a-ac31-e8280583371c", + "resource": { + "resourceType": "Location", + "id": "3913ec4d-6576-5e1a-ac31-e8280583371c", + "partOf": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + }, + "name": "OMU B", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + } + }, + { + "fullUrl": "urn:uuid:804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "resource": { + "resourceType": "Location", + "id": "804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "partOf": { + "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + }, + "name": "Bed 03", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" + } + }, + { + "fullUrl": "urn:uuid:c043880b-0fab-1cb8-14f7-0475282c4d0e", + "resource": { + "resourceType": "Location", + "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", + "name": "HOMERTON UNIVER", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + } + }, + { + "fullUrl": "urn:uuid:f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "resource": { + "resourceType": "Location", + "id": "f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "partOf": { + "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + }, + "name": "Homerton UH", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + } + }, + { + "fullUrl": "urn:uuid:7e38808c-44a8-cb0c-4709-9d6092abc32c", + "resource": { + "resourceType": "Location", + "id": "7e38808c-44a8-cb0c-4709-9d6092abc32c", + "partOf": { + "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + }, + "name": "Floor5", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + } + }, + { + "fullUrl": "urn:uuid:59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "resource": { + "resourceType": "Location", + "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "name": "4 East, room 136, bed B 4E", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + } + }, + { + "fullUrl": "urn:uuid:d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "resource": { + "resourceType": "Location", + "id": "d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "partOf": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "name": "136", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + } + }, + { + "fullUrl": "urn:uuid:5783dafa-c6c0-e673-cca4-42087ee1831b", + "resource": { + "resourceType": "Location", + "id": "5783dafa-c6c0-e673-cca4-42087ee1831b", + "partOf": { + "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + }, + "name": "B", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" + } + }, + { + "fullUrl": "urn:uuid:8b39e6e5-78cd-63ab-2441-f43ca5554096", + "resource": { + "resourceType": "Location", + "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", + "name": "CommunityHospital", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" + } + }, + { + "fullUrl": "urn:uuid:42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "resource": { + "resourceType": "Location", + "id": "42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "name": "Homes", + "identifier": [ + { + "value": "22", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/FDK" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + { + "fullUrl": "urn:uuid:84634858-74aa-5cdb-4547-60ec27339ac6", + "resource": { + "resourceType": "Location", + "id": "84634858-74aa-5cdb-4547-60ec27339ac6", + "name": "POC", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + } + }, + { + "fullUrl": "urn:uuid:9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", + "resource": { + "resourceType": "Location", + "id": "9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", + "partOf": { + "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + }, + "name": "Room-2", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" + } + }, + { + "fullUrl": "urn:uuid:35353f20-6254-e794-98ed-8007490447e3", + "resource": { + "resourceType": "Location", + "id": "35353f20-6254-e794-98ed-8007490447e3", + "partOf": { + "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" + }, + "name": "Bed-103", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/35353f20-6254-e794-98ed-8007490447e3" + } + }, + { + "fullUrl": "urn:uuid:055e10f1-222e-df73-2325-0e4396db1a55", + "resource": { + "resourceType": "Location", + "id": "055e10f1-222e-df73-2325-0e4396db1a55", + "name": "Greenland", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/055e10f1-222e-df73-2325-0e4396db1a55" + } + }, + { + "fullUrl": "urn:uuid:1154e6b2-b022-b3be-7dce-2b940ab5376d", + "resource": { + "resourceType": "Location", + "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", + "name": "Nursing home", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + } + }, + { + "fullUrl": "urn:uuid:08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "resource": { + "resourceType": "Location", + "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "name": "Rosewood", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" + } + }, + { + "fullUrl": "urn:uuid:c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "resource": { + "resourceType": "Location", + "id": "c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "name": "ROOM1", + "identifier": [ + { + "value": "urn:oid:2.16.840.1.113883.4.642.1.1108", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + } + }, + { + "fullUrl": "urn:uuid:6f159848-5f01-01b3-9594-80fbbe9ab510", + "resource": { + "resourceType": "Location", + "id": "6f159848-5f01-01b3-9594-80fbbe9ab510", + "partOf": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "name": "BED1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" + } + }, + { + "fullUrl": "urn:uuid:4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "resource": { + "resourceType": "Location", + "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "name": "FACILITY1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + } + }, + { + "fullUrl": "urn:uuid:3b0911cb-4361-cd8d-b188-463af033c699", + "resource": { + "resourceType": "Location", + "id": "3b0911cb-4361-cd8d-b188-463af033c699", + "partOf": { + "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + }, + "name": "BUILDING1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:08314073-410a-3dc7-512c-0f2d206fb59d", + "resource": { + "resourceType": "Organization", + "id": "08314073-410a-3dc7-512c-0f2d206fb59d", + "identifier": [ + { + "value": "Etest", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-Etest" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + }, + { + "fullUrl": "urn:uuid:919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "resource": { + "resourceType": "EpisodeOfCare", + "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "status": "active", + "identifier": [ + { + "value": "EOC124", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + }, + { + "fullUrl": "urn:uuid:4b192760-03d2-aec4-b0a6-fde323912e1e", + "resource": { + "resourceType": "Encounter", + "id": "4b192760-03d2-aec4-b0a6-fde323912e1e", + "class": { + "code": "PRENC", + "display": "pre-admission", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "in-progress", + "location": [ + { + "status": "active", + "location": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "status": "completed", + "location": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "status": "planned", + "location": { + "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "status": "completed", + "location": { + "reference": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": true + } + ] + }, + { + "status": "planned", + "location": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + } + ], + "type": [ + { + "coding": [ + { + "code": "E", + "display": "Emergency", + "system": "http://terminology.hl7.org/CodeSystem/v2-0007" + } + ] + } + ], + "hospitalization": { + "preAdmissionIdentifier": { + "value": "1234567", + "type": { + "coding": [ + { + "code": "ANON", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Anonymous identifier" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + "reAdmission": { + "coding": [ + { + "code": "R", + "display": "Re-admission", + "system": "http://terminology.hl7.org/CodeSystem/v2-0092" + } + ] + }, + "admitSource": { + "coding": [ + { + "code": "NHS Provider-General (inc.A&E-this Hosp)" + } + ] + }, + "dischargeDisposition": { + "coding": [ + { + "code": "Admitted as Inpatient", + "display": "Sample", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ACR" + } + ] + }, + "dietPreference": [ + { + "coding": [ + { + "code": "Vegan", + "display": "Vegetarian" + } + ] + } + ], + "destination": { + "reference": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + "episodeOfCare": [ + { + "reference": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "CON", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "consultant" + } + ], + "individual": { + "reference": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "ADM", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "admitter" + } + ], + "individual": { + "reference": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "PART", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "Participation" + } + ], + "individual": { + "reference": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + } + ], + "serviceType": { + "coding": [ + { + "code": "SUR" + } + ] + }, + "identifier": [ + { + "value": "40007716", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + }, + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + }, + { + "value": "50", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "urn:oid:r2.3", + "assigner": { + "reference": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + } + ], + "period": { + "start": "2015-02-08T15:54:19+05:30" + }, + "reasonCode": [ + { + "coding": [ + { + "code": "140004", + "display": "Chronic pharyngitis", + "system": "http://snomed.info/sct" + } + ] + } + ], + "length": { + "value": 2, + "unit": "d", + "system": "http://unitsofmeasure.org/" + }, + "meta": { + "security": [ + { + "code": "N", + "display": "normal", + "system": "http://terminology.hl7.org/CodeSystem/v3-Confidentiality" + } + ] + }, + "text": { + "status": "generated", + "div": "

Visit Description: Health Checkup

" + }, + "priority": { + "coding": [ + { + "code": "UR", + "display": "urgent", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.2" + }, + { + "code": "EL", + "display": "elective", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.3" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/encounter-modeOfArrival", + "valueCoding": { + "code": "C", + "display": "Car", + "system": "http://terminology.hl7.org/CodeSystem/v2-0430" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Encounter/4b192760-03d2-aec4-b0a6-fde323912e1e" + } + }, + { + "fullUrl": "urn:uuid:9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "resource": { + "resourceType": "Provenance", + "id": "9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "occurredDateTime": "2021-08-17T18:49:43.004+05:30", + "recorded": "2029-08-01T11:21:24+05:30", + "reason": [ + { + "coding": [ + { + "code": "PATRQT", + "display": "patient requested", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActReason" + } + ] + } + ], + "agent": [ + { + "who": { + "reference": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + } + ], + "activity": { + "text": "ADT^A25^ADT_A25" + }, + "location": { + "reference": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + }, + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c" + } + }, + { + "fullUrl": "urn:uuid:ef39f581-5e8f-3917-35a9-3443303d9eee", + "resource": { + "resourceType": "Organization", + "id": "ef39f581-5e8f-3917-35a9-3443303d9eee", + "identifier": [ + { + "value": "DRNBR", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-DRNBR" + }, + { + "value": "urn:oid:W1.2", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + } + }, + { + "fullUrl": "urn:uuid:95aea53b-8d49-d57f-d16f-4d14b914f992", + "resource": { + "resourceType": "Practitioner", + "id": "95aea53b-8d49-d57f-d16f-4d14b914f992", + "identifier": [ + { + "value": "C08", + "system": "urn:oid:W1.2", + "assigner": { + "reference": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + }, + "type": { + "coding": [ + { + "code": "ANON", + "display": "Anonymous identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen", + "2ndname" + ], + "suffix": [ + "Jr", + "MD" + ], + "prefix": [ + "Dr" + ], + "use": "official" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + }, + { + "fullUrl": "urn:uuid:59d5e519-0108-5dd8-adfa-1eef5658009e", + "resource": { + "resourceType": "Location", + "id": "59d5e519-0108-5dd8-adfa-1eef5658009e", + "name": "Cona_Health", + "identifier": [ + { + "value": "urn:oid:1.3.6.1.4.1.44750.1.4", + "system": "urn:ietf:rfc:3986" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "display": "site", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A26/ADT-A26-01-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A26/ADT-A26-01-expected.json new file mode 100644 index 000000000..62b532207 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A26/ADT-A26-01-expected.json @@ -0,0 +1,2644 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "1989-08-18T14:41:00+05:30", + "identifier": { + "value": "MSG00001" + }, + "id": "513a3d06-5e87-6fbc-ad1b-170ab430499f", + "entry": [ + { + "fullUrl": "urn:uuid:b4ca189b-51ae-33df-cbe2-559b4423a321", + "resource": { + "resourceType": "MessageHeader", + "id": "b4ca189b-51ae-33df-cbe2-559b4423a321", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20", + "version": "2.4.3.52854", + "software": "Rhapsody" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "A26", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "ADT^A26^ADT_A26" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/b4ca189b-51ae-33df-cbe2-559b4423a321" + } + }, + { + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "resource": { + "resourceType": "Provenance", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T10:14:07.714Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A26.

" + }, + "occurredDateTime": "1989-08-18T14:41:00+05:30", + "recorded": "1989-08-18T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "ADT^A26^ADT_A26" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + } + ], + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:503eb873-22fb-8199-ae28-3604ad59fe13", + "resource": { + "resourceType": "Device", + "id": "503eb873-22fb-8199-ae28-3604ad59fe13", + "identifier": [ + { + "value": "ADTApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + }, + { + "fullUrl": "urn:uuid:4b549918-a84d-cdaf-e150-c773a5d306e5", + "resource": { + "resourceType": "Device", + "id": "4b549918-a84d-cdaf-e150-c773a5d306e5", + "manufacturer": "Orion", + "deviceName": [ + { + "name": "Rhapsody", + "type": "manufacturer-name" + } + ], + "version": [ + { + "value": "2.4.3.52854" + } + ], + "modelNumber": "2.4.3", + "note": [ + { + "text": "Testactivity" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/4b549918-a84d-cdaf-e150-c773a5d306e5" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + }, + { + "value": "DB123", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "urn:oid:1.12", + "assigner": { + "reference": "Organization/4e68b44e-c053-02b1-6d6d-fe816f9fdfec" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "generalPractitioner": [ + { + "reference": "Organization/4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11" + }, + { + "reference": "Practitioner/76aaad38-1077-6a5c-0c5c-102ec160a60d" + } + ], + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/VeteranMilitaryStatus", + "valueCodeableConcept": { + "coding": [ + { + "code": "Vet123", + "display": "retired", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ART" + } + ], + "text": "retired" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-animal", + "extension": [ + { + "url": "species", + "valueCodeableConcept": { + "coding": [ + { + "code": "125097000", + "display": "Goat", + "system": "http://snomed.info/sct" + } + ], + "text": "Goat" + } + }, + { + "url": "breed", + "valueCodeableConcept": { + "coding": [ + { + "code": "4880003", + "display": "Beagle", + "system": "http://snomed.info/sct" + } + ], + "text": "Beagle" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-nationality", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "BT", + "display": "Bhutan", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Bhutan" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-congregation", + "valueString": "Methodist Church" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-importance", + "valueCodeableConcept": { + "coding": [ + { + "code": "VIP", + "display": "Very Important Person", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L", + "version": "v1.1" + }, + { + "code": "IMP", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/DCM", + "version": "v1.2" + } + ], + "text": "Inportant Person" + } + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/patient-disabilityIndicator", + "valueBoolean": true + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/DisabilityPeriod", + "valuePeriod": { + "start": "2021-08-30", + "end": "2021-09-30" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11", + "resource": { + "resourceType": "Organization", + "id": "4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11", + "name": "LINDAS TEST ORGANIZATION", + "identifier": [ + { + "value": "SIISCLIENT818" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11" + } + }, + { + "fullUrl": "urn:uuid:76aaad38-1077-6a5c-0c5c-102ec160a60d", + "resource": { + "resourceType": "Practitioner", + "id": "76aaad38-1077-6a5c-0c5c-102ec160a60d", + "identifier": [ + { + "value": "88", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TE", + "type": { + "coding": [ + { + "code": "DN", + "display": "Doctor number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Hippo", + "given": [ + "rold", + "H" + ], + "suffix": [ + "V", + "MD" + ], + "prefix": [ + "Dr" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/76aaad38-1077-6a5c-0c5c-102ec160a60d" + } + }, + { + "fullUrl": "urn:uuid:11967e28-8dd4-a112-0fdc-377866bf12a0", + "resource": { + "resourceType": "Organization", + "id": "11967e28-8dd4-a112-0fdc-377866bf12a0", + "identifier": [ + { + "value": "t", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-t" + }, + { + "value": "2.16.840.1.113883.19", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + } + }, + { + "fullUrl": "urn:uuid:7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "resource": { + "resourceType": "Organization", + "id": "7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "identifier": [ + { + "value": "AccMng", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMng" + }, + { + "value": "1.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + } + }, + { + "fullUrl": "urn:uuid:0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "resource": { + "resourceType": "Organization", + "id": "0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "identifier": [ + { + "value": "PERSONNELt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSONNELt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + } + }, + { + "fullUrl": "urn:uuid:f6775f99-5279-be04-bf81-0906c81f7443", + "resource": { + "resourceType": "Practitioner", + "id": "f6775f99-5279-be04-bf81-0906c81f7443", + "identifier": [ + { + "value": "1122334", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Alaz", + "given": [ + "Mohammed", + "Mahi" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "fullUrl": "urn:uuid:c613d7b2-525f-8c08-a7ac-b2b91486e257", + "resource": { + "resourceType": "Organization", + "id": "c613d7b2-525f-8c08-a7ac-b2b91486e257", + "identifier": [ + { + "value": "TEST", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TEST" + }, + { + "value": "23.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + } + }, + { + "fullUrl": "urn:uuid:04f8cfc8-62ca-12df-63ce-6304ef577d44", + "resource": { + "resourceType": "Practitioner", + "id": "04f8cfc8-62ca-12df-63ce-6304ef577d44", + "identifier": [ + { + "value": "C006", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + }, + "type": { + "coding": [ + { + "code": "BA", + "display": "Bank Account Number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen" + ], + "prefix": [ + "Dr" + ], + "use": "anonymous" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "fullUrl": "urn:uuid:99edcabd-fbeb-7e25-f823-11da8d8ed342", + "resource": { + "resourceType": "Practitioner", + "id": "99edcabd-fbeb-7e25-f823-11da8d8ed342", + "identifier": [ + { + "value": "C008", + "system": "urn:oid:2.8", + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Condoc", + "given": [ + "leen" + ], + "prefix": [ + "Dr" + ], + "use": "temp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "fullUrl": "urn:uuid:b065b233-8738-f1ec-1314-d61e4aac2c9e", + "resource": { + "resourceType": "Practitioner", + "id": "b065b233-8738-f1ec-1314-d61e4aac2c9e", + "identifier": [ + { + "value": "37", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr", + "type": { + "coding": [ + { + "code": "ANC", + "display": "Account number Creditor", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "DISNEY", + "given": [ + "WALT" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "fullUrl": "urn:uuid:9f974d4f-47e8-21a6-e549-4de4599c3764", + "resource": { + "resourceType": "Organization", + "id": "9f974d4f-47e8-21a6-e549-4de4599c3764", + "identifier": [ + { + "value": "T123", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-T123" + }, + { + "value": "urn:oid:r2.3", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + }, + { + "fullUrl": "urn:uuid:84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "resource": { + "resourceType": "Practitioner", + "id": "84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "identifier": [ + { + "value": "Othhel", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "fullUrl": "urn:uuid:24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "resource": { + "resourceType": "Organization", + "id": "24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "identifier": [ + { + "value": "TE", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TE" + }, + { + "value": "Provider Master.Community Health and Hospitals", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "type": { + "coding": [ + { + "code": "DNS", + "display": "An Internet host name, in accordance with RFC 1035; or an IP address. Either in ASCII or as integers, with periods between components (“dotted” notation).", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + } + }, + { + "fullUrl": "urn:uuid:36e3aaa4-569a-7d9d-037f-27235ed05701", + "resource": { + "resourceType": "Practitioner", + "id": "36e3aaa4-569a-7d9d-037f-27235ed05701", + "identifier": [ + { + "value": "12188", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "assigner": { + "reference": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + }, + "type": { + "coding": [ + { + "code": "DN", + "display": "Doctor number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Hippocrates", + "given": [ + "Harold", + "H" + ], + "suffix": [ + "IV", + "MD" + ], + "prefix": [ + "Dr" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + }, + { + "fullUrl": "urn:uuid:9172e4a0-1ca5-646d-2183-b179f4daa737", + "resource": { + "resourceType": "Location", + "id": "9172e4a0-1ca5-646d-2183-b179f4daa737", + "partOf": { + "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + }, + "name": "HUH AE OMU", + "identifier": [ + { + "value": "urn:oid:9.8", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "fullUrl": "urn:uuid:3913ec4d-6576-5e1a-ac31-e8280583371c", + "resource": { + "resourceType": "Location", + "id": "3913ec4d-6576-5e1a-ac31-e8280583371c", + "partOf": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + }, + "name": "OMU B", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + } + }, + { + "fullUrl": "urn:uuid:804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "resource": { + "resourceType": "Location", + "id": "804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "partOf": { + "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + }, + "name": "Bed 03", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" + } + }, + { + "fullUrl": "urn:uuid:c043880b-0fab-1cb8-14f7-0475282c4d0e", + "resource": { + "resourceType": "Location", + "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", + "name": "HOMERTON UNIVER", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + } + }, + { + "fullUrl": "urn:uuid:f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "resource": { + "resourceType": "Location", + "id": "f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "partOf": { + "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + }, + "name": "Homerton UH", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + } + }, + { + "fullUrl": "urn:uuid:7e38808c-44a8-cb0c-4709-9d6092abc32c", + "resource": { + "resourceType": "Location", + "id": "7e38808c-44a8-cb0c-4709-9d6092abc32c", + "partOf": { + "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + }, + "name": "Floor5", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + } + }, + { + "fullUrl": "urn:uuid:59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "resource": { + "resourceType": "Location", + "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "name": "4 East, room 136, bed B 4E", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + } + }, + { + "fullUrl": "urn:uuid:d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "resource": { + "resourceType": "Location", + "id": "d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "partOf": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "name": "136", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + } + }, + { + "fullUrl": "urn:uuid:5783dafa-c6c0-e673-cca4-42087ee1831b", + "resource": { + "resourceType": "Location", + "id": "5783dafa-c6c0-e673-cca4-42087ee1831b", + "partOf": { + "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + }, + "name": "B", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" + } + }, + { + "fullUrl": "urn:uuid:8b39e6e5-78cd-63ab-2441-f43ca5554096", + "resource": { + "resourceType": "Location", + "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", + "name": "CommunityHospital", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" + } + }, + { + "fullUrl": "urn:uuid:42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "resource": { + "resourceType": "Location", + "id": "42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "name": "Homes", + "identifier": [ + { + "value": "22", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/FDK" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + { + "fullUrl": "urn:uuid:1154e6b2-b022-b3be-7dce-2b940ab5376d", + "resource": { + "resourceType": "Location", + "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", + "name": "Nursing home", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + } + }, + { + "fullUrl": "urn:uuid:08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "resource": { + "resourceType": "Location", + "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "name": "Rosewood", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" + } + }, + { + "fullUrl": "urn:uuid:08314073-410a-3dc7-512c-0f2d206fb59d", + "resource": { + "resourceType": "Organization", + "id": "08314073-410a-3dc7-512c-0f2d206fb59d", + "identifier": [ + { + "value": "Etest", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-Etest" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + }, + { + "fullUrl": "urn:uuid:919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "resource": { + "resourceType": "EpisodeOfCare", + "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "status": "active", + "identifier": [ + { + "value": "EOC124", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + }, + { + "fullUrl": "urn:uuid:4b192760-03d2-aec4-b0a6-fde323912e1e", + "resource": { + "resourceType": "Encounter", + "id": "4b192760-03d2-aec4-b0a6-fde323912e1e", + "class": { + "code": "PRENC", + "display": "pre-admission", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "in-progress", + "location": [ + { + "status": "active", + "location": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "status": "completed", + "location": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "status": "completed", + "location": { + "reference": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": true + } + ] + } + ], + "type": [ + { + "coding": [ + { + "code": "E", + "display": "Emergency", + "system": "http://terminology.hl7.org/CodeSystem/v2-0007" + } + ] + } + ], + "hospitalization": { + "preAdmissionIdentifier": { + "value": "1234567", + "type": { + "coding": [ + { + "code": "ANON", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Anonymous identifier" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + "reAdmission": { + "coding": [ + { + "code": "R", + "display": "Re-admission", + "system": "http://terminology.hl7.org/CodeSystem/v2-0092" + } + ] + }, + "admitSource": { + "coding": [ + { + "code": "NHS Provider-General (inc.A&E-this Hosp)" + } + ] + }, + "dischargeDisposition": { + "coding": [ + { + "code": "Admitted as Inpatient", + "display": "Sample", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ACR" + } + ] + }, + "dietPreference": [ + { + "coding": [ + { + "code": "Vegan", + "display": "Vegetarian" + } + ] + } + ], + "destination": { + "reference": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + "episodeOfCare": [ + { + "reference": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "CON", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "consultant" + } + ], + "individual": { + "reference": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "ADM", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "admitter" + } + ], + "individual": { + "reference": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "PART", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "Participation" + } + ], + "individual": { + "reference": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + } + ], + "serviceType": { + "coding": [ + { + "code": "SUR" + } + ] + }, + "identifier": [ + { + "value": "40007716", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + }, + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + }, + { + "value": "50", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "urn:oid:r2.3", + "assigner": { + "reference": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + } + ], + "reasonCode": [ + { + "coding": [ + { + "code": "140004", + "display": "Chronic pharyngitis", + "system": "http://snomed.info/sct" + } + ] + } + ], + "length": { + "value": 2, + "unit": "d", + "system": "http://unitsofmeasure.org/" + }, + "meta": { + "security": [ + { + "code": "N", + "display": "normal", + "system": "http://terminology.hl7.org/CodeSystem/v3-Confidentiality" + } + ] + }, + "text": { + "status": "generated", + "div": "

Visit Description: Health Checkup

" + }, + "priority": { + "coding": [ + { + "code": "UR", + "display": "urgent", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.2" + }, + { + "code": "EL", + "display": "elective", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.3" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/encounter-modeOfArrival", + "valueCoding": { + "code": "C", + "display": "Car", + "system": "http://terminology.hl7.org/CodeSystem/v2-0430" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Encounter/4b192760-03d2-aec4-b0a6-fde323912e1e" + } + }, + { + "fullUrl": "urn:uuid:9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "resource": { + "resourceType": "Provenance", + "id": "9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "occurredDateTime": "2021-08-17T18:49:43.004+05:30", + "recorded": "2029-08-01T11:21:24+05:30", + "reason": [ + { + "coding": [ + { + "code": "PATRQT", + "display": "patient requested", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActReason" + } + ] + } + ], + "agent": [ + { + "who": { + "reference": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + } + ], + "activity": { + "text": "ADT^A26^ADT_A26" + }, + "location": { + "reference": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + }, + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c" + } + }, + { + "fullUrl": "urn:uuid:ef39f581-5e8f-3917-35a9-3443303d9eee", + "resource": { + "resourceType": "Organization", + "id": "ef39f581-5e8f-3917-35a9-3443303d9eee", + "identifier": [ + { + "value": "DRNBR", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-DRNBR" + }, + { + "value": "urn:oid:W1.2", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + } + }, + { + "fullUrl": "urn:uuid:95aea53b-8d49-d57f-d16f-4d14b914f992", + "resource": { + "resourceType": "Practitioner", + "id": "95aea53b-8d49-d57f-d16f-4d14b914f992", + "identifier": [ + { + "value": "C08", + "system": "urn:oid:W1.2", + "assigner": { + "reference": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + }, + "type": { + "coding": [ + { + "code": "ANON", + "display": "Anonymous identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen", + "2ndname" + ], + "suffix": [ + "Jr", + "MD" + ], + "prefix": [ + "Dr" + ], + "use": "official" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + }, + { + "fullUrl": "urn:uuid:59d5e519-0108-5dd8-adfa-1eef5658009e", + "resource": { + "resourceType": "Location", + "id": "59d5e519-0108-5dd8-adfa-1eef5658009e", + "name": "Cona_Health", + "identifier": [ + { + "value": "urn:oid:1.3.6.1.4.1.44750.1.4", + "system": "urn:ietf:rfc:3986" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "display": "site", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + } + }, + { + "fullUrl": "urn:uuid:4e68b44e-c053-02b1-6d6d-fe816f9fdfec", + "resource": { + "resourceType": "Organization", + "id": "4e68b44e-c053-02b1-6d6d-fe816f9fdfec", + "identifier": [ + { + "value": "t", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-t" + }, + { + "value": "urn:oid:1.12", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4e68b44e-c053-02b1-6d6d-fe816f9fdfec" + } + }, + { + "fullUrl": "urn:uuid:e82402a9-b2d1-2a28-3250-c099d5a77bf7", + "resource": { + "resourceType": "Organization", + "id": "e82402a9-b2d1-2a28-3250-c099d5a77bf7", + "identifier": [ + { + "value": "PERSt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/e82402a9-b2d1-2a28-3250-c099d5a77bf7" + } + }, + { + "fullUrl": "urn:uuid:ce70e6c3-c190-121d-c251-e4bae5cde6a1", + "resource": { + "resourceType": "Practitioner", + "id": "ce70e6c3-c190-121d-c251-e4bae5cde6a1", + "identifier": [ + { + "value": "1134", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/e82402a9-b2d1-2a28-3250-c099d5a77bf7" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Aly", + "given": [ + "Zafar", + "Mahendra" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/ce70e6c3-c190-121d-c251-e4bae5cde6a1" + } + }, + { + "fullUrl": "urn:uuid:88a53755-c972-6904-b4ce-8884b84ddc2e", + "resource": { + "resourceType": "PractitionerRole", + "id": "88a53755-c972-6904-b4ce-8884b84ddc2e", + "code": [ + { + "coding": [ + { + "code": "ResponsibleObserver", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/ce70e6c3-c190-121d-c251-e4bae5cde6a1" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/88a53755-c972-6904-b4ce-8884b84ddc2e" + } + }, + { + "fullUrl": "urn:uuid:3e0952c6-eea0-8938-96f8-07c224bf1577", + "resource": { + "resourceType": "Practitioner", + "id": "3e0952c6-eea0-8938-96f8-07c224bf1577", + "identifier": [ + { + "value": "2234" + } + ], + "name": [ + { + "family": "Pauly", + "given": [ + "Berrie", + "Raud" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/3e0952c6-eea0-8938-96f8-07c224bf1577" + } + }, + { + "fullUrl": "urn:uuid:bc78e290-ec67-c238-1e05-aefb6b252b0c", + "resource": { + "resourceType": "PractitionerRole", + "id": "bc78e290-ec67-c238-1e05-aefb6b252b0c", + "code": [ + { + "coding": [ + { + "code": "ResponsibleObserver", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/3e0952c6-eea0-8938-96f8-07c224bf1577" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/bc78e290-ec67-c238-1e05-aefb6b252b0c" + } + }, + { + "fullUrl": "urn:uuid:fe0adb86-ebe9-6479-0055-9db8dc1ff99a", + "resource": { + "resourceType": "Device", + "id": "fe0adb86-ebe9-6479-0055-9db8dc1ff99a", + "identifier": [ + { + "value": "EI12.3", + "system": "urn:uuid:UI2", + "type": { + "coding": [ + { + "code": "GUID", + "display": "Same as UUID.", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + }, + { + "system": "urn:oid:UI1", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/fe0adb86-ebe9-6479-0055-9db8dc1ff99a" + } + }, + { + "fullUrl": "urn:uuid:45f65e47-46c4-1a54-f9fb-1321258e79b2", + "resource": { + "resourceType": "Practitioner", + "id": "45f65e47-46c4-1a54-f9fb-1321258e79b2", + "identifier": [ + { + "type": { + "coding": [ + { + "code": "MD-25" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/45f65e47-46c4-1a54-f9fb-1321258e79b2" + } + }, + { + "fullUrl": "urn:uuid:090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3", + "resource": { + "resourceType": "PractitionerRole", + "id": "090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3", + "code": [ + { + "coding": [ + { + "code": "LabMedicalDirector", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/45f65e47-46c4-1a54-f9fb-1321258e79b2" + }, + "organization": { + "reference": "Organization/056aa7c7-6b75-3c67-63c5-cf9604f16d25" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3" + } + }, + { + "fullUrl": "urn:uuid:056aa7c7-6b75-3c67-63c5-cf9604f16d25", + "resource": { + "resourceType": "Organization", + "id": "056aa7c7-6b75-3c67-63c5-cf9604f16d25", + "name": "FairOaks Hspital", + "address": [ + { + "line": [ + "Research Park", + "Fairfax" + ], + "city": "VA", + "state": "22031", + "postalCode": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/056aa7c7-6b75-3c67-63c5-cf9604f16d25" + } + }, + { + "fullUrl": "urn:uuid:07fd2dd3-dbd6-5bb1-cfda-02226795d9a0", + "resource": { + "resourceType": "Observation", + "id": "07fd2dd3-dbd6-5bb1-cfda-02226795d9a0", + "identifier": [ + { + "value": "EI21", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-OII" + }, + { + "type": { + "coding": [ + { + "code": "FILL" + } + ] + } + } + ], + "status": "unknown", + "code": { + "coding": [ + { + "code": "8867-4", + "display": "heartrate", + "system": "http://loinc.org" + } + ] + }, + "component": [ + { + "code": { + "coding": [ + { + "code": "8867-4", + "display": "heartrate", + "system": "http://loinc.org" + } + ] + }, + "valueQuantity": { + "value": 60, + "code": "beats/min", + "unit": "beats/min", + "system": "urn:iso:std:iso:3986" + }, + "referenceRange": [ + { + "text": "70-80" + } + ] + }, + { + "code": { + "coding": [ + { + "code": "8867-4", + "display": "heartrate", + "system": "http://loinc.org" + } + ] + }, + "valueQuantity": { + "value": 120, + "code": "beats/min", + "unit": "beats/min", + "system": "urn:iso:std:iso:3986" + }, + "referenceRange": [ + { + "text": "70-80" + } + ] + } + ], + "effectiveDateTime": "1999-07-02", + "method": { + "coding": [ + { + "code": "OBS", + "display": "This is test method", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/AS4" + } + ] + }, + "device": { + "reference": "Device/fe0adb86-ebe9-6479-0055-9db8dc1ff99a" + }, + "bodySite": { + "coding": [ + { + "code": "BU", + "display": "Observation site", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/E5" + } + ] + }, + "performer": [ + { + "reference": "PractitionerRole/88a53755-c972-6904-b4ce-8884b84ddc2e" + }, + { + "reference": "PractitionerRole/bc78e290-ec67-c238-1e05-aefb6b252b0c" + }, + { + "reference": "PractitionerRole/090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3" + } + ], + "interpretation": [ + { + "coding": [ + { + "code": "A", + "display": "Abnormal", + "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation" + } + ] + }, + { + "coding": [ + { + "code": "B", + "display": "Better", + "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation" + } + ] + } + ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "S", + "display": "Partial", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Partial" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/07fd2dd3-dbd6-5bb1-cfda-02226795d9a0" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A26/ADT-A26-02-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A26/ADT-A26-02-expected.json new file mode 100644 index 000000000..c46310fc3 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A26/ADT-A26-02-expected.json @@ -0,0 +1,1926 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "1989-08-18T14:41:00+05:30", + "identifier": { + "value": "MSG00001" + }, + "id": "513a3d06-5e87-6fbc-ad1b-170ab430499f", + "entry": [ + { + "fullUrl": "urn:uuid:b4ca189b-51ae-33df-cbe2-559b4423a321", + "resource": { + "resourceType": "MessageHeader", + "id": "b4ca189b-51ae-33df-cbe2-559b4423a321", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "A26", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "ADT^A26^ADT_A26" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/b4ca189b-51ae-33df-cbe2-559b4423a321" + } + }, + { + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "resource": { + "resourceType": "Provenance", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T10:14:50.627Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A26.

" + }, + "occurredDateTime": "1989-08-18T14:41:00+05:30", + "recorded": "1989-08-18T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "ADT^A26^ADT_A26" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + } + ], + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:503eb873-22fb-8199-ae28-3604ad59fe13", + "resource": { + "resourceType": "Device", + "id": "503eb873-22fb-8199-ae28-3604ad59fe13", + "identifier": [ + { + "value": "ADTApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/VeteranMilitaryStatus", + "valueCodeableConcept": { + "coding": [ + { + "code": "Vet123", + "display": "retired", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ART" + } + ], + "text": "retired" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-animal", + "extension": [ + { + "url": "species", + "valueCodeableConcept": { + "coding": [ + { + "code": "125097000", + "display": "Goat", + "system": "http://snomed.info/sct" + } + ], + "text": "Goat" + } + }, + { + "url": "breed", + "valueCodeableConcept": { + "coding": [ + { + "code": "4880003", + "display": "Beagle", + "system": "http://snomed.info/sct" + } + ], + "text": "Beagle" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-nationality", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "BT", + "display": "Bhutan", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Bhutan" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-importance", + "valueCodeableConcept": { + "coding": [ + { + "code": "VIP", + "display": "Very Important Person", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L", + "version": "v1.1" + }, + { + "code": "IMP", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/DCM", + "version": "v1.2" + } + ], + "text": "Inportant Person" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:11967e28-8dd4-a112-0fdc-377866bf12a0", + "resource": { + "resourceType": "Organization", + "id": "11967e28-8dd4-a112-0fdc-377866bf12a0", + "identifier": [ + { + "value": "t", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-t" + }, + { + "value": "2.16.840.1.113883.19", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + } + }, + { + "fullUrl": "urn:uuid:7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "resource": { + "resourceType": "Organization", + "id": "7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "identifier": [ + { + "value": "AccMng", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMng" + }, + { + "value": "1.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + } + }, + { + "fullUrl": "urn:uuid:0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "resource": { + "resourceType": "Organization", + "id": "0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "identifier": [ + { + "value": "PERSONNELt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSONNELt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + } + }, + { + "fullUrl": "urn:uuid:f6775f99-5279-be04-bf81-0906c81f7443", + "resource": { + "resourceType": "Practitioner", + "id": "f6775f99-5279-be04-bf81-0906c81f7443", + "identifier": [ + { + "value": "1122334", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Alaz", + "given": [ + "Mohammed", + "Mahi" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "fullUrl": "urn:uuid:c613d7b2-525f-8c08-a7ac-b2b91486e257", + "resource": { + "resourceType": "Organization", + "id": "c613d7b2-525f-8c08-a7ac-b2b91486e257", + "identifier": [ + { + "value": "TEST", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TEST" + }, + { + "value": "23.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + } + }, + { + "fullUrl": "urn:uuid:04f8cfc8-62ca-12df-63ce-6304ef577d44", + "resource": { + "resourceType": "Practitioner", + "id": "04f8cfc8-62ca-12df-63ce-6304ef577d44", + "identifier": [ + { + "value": "C006", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + }, + "type": { + "coding": [ + { + "code": "BA", + "display": "Bank Account Number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen" + ], + "prefix": [ + "Dr" + ], + "use": "anonymous" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "fullUrl": "urn:uuid:99edcabd-fbeb-7e25-f823-11da8d8ed342", + "resource": { + "resourceType": "Practitioner", + "id": "99edcabd-fbeb-7e25-f823-11da8d8ed342", + "identifier": [ + { + "value": "C008", + "system": "urn:oid:2.8", + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Condoc", + "given": [ + "leen" + ], + "prefix": [ + "Dr" + ], + "use": "temp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "fullUrl": "urn:uuid:b065b233-8738-f1ec-1314-d61e4aac2c9e", + "resource": { + "resourceType": "Practitioner", + "id": "b065b233-8738-f1ec-1314-d61e4aac2c9e", + "identifier": [ + { + "value": "37", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr", + "type": { + "coding": [ + { + "code": "ANC", + "display": "Account number Creditor", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "DISNEY", + "given": [ + "WALT" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "fullUrl": "urn:uuid:9f974d4f-47e8-21a6-e549-4de4599c3764", + "resource": { + "resourceType": "Organization", + "id": "9f974d4f-47e8-21a6-e549-4de4599c3764", + "identifier": [ + { + "value": "T123", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-T123" + }, + { + "value": "urn:oid:r2.3", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + }, + { + "fullUrl": "urn:uuid:84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "resource": { + "resourceType": "Practitioner", + "id": "84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "identifier": [ + { + "value": "Othhel", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "fullUrl": "urn:uuid:9172e4a0-1ca5-646d-2183-b179f4daa737", + "resource": { + "resourceType": "Location", + "id": "9172e4a0-1ca5-646d-2183-b179f4daa737", + "partOf": { + "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + }, + "name": "HUH AE OMU", + "identifier": [ + { + "value": "urn:oid:9.8", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "fullUrl": "urn:uuid:3913ec4d-6576-5e1a-ac31-e8280583371c", + "resource": { + "resourceType": "Location", + "id": "3913ec4d-6576-5e1a-ac31-e8280583371c", + "partOf": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + }, + "name": "OMU B", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + } + }, + { + "fullUrl": "urn:uuid:804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "resource": { + "resourceType": "Location", + "id": "804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "partOf": { + "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + }, + "name": "Bed 03", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" + } + }, + { + "fullUrl": "urn:uuid:c043880b-0fab-1cb8-14f7-0475282c4d0e", + "resource": { + "resourceType": "Location", + "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", + "name": "HOMERTON UNIVER", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + } + }, + { + "fullUrl": "urn:uuid:f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "resource": { + "resourceType": "Location", + "id": "f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "partOf": { + "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + }, + "name": "Homerton UH", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + } + }, + { + "fullUrl": "urn:uuid:7e38808c-44a8-cb0c-4709-9d6092abc32c", + "resource": { + "resourceType": "Location", + "id": "7e38808c-44a8-cb0c-4709-9d6092abc32c", + "partOf": { + "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + }, + "name": "Floor5", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + } + }, + { + "fullUrl": "urn:uuid:59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "resource": { + "resourceType": "Location", + "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "name": "4 East, room 136, bed B 4E", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + } + }, + { + "fullUrl": "urn:uuid:d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "resource": { + "resourceType": "Location", + "id": "d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "partOf": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "name": "136", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + } + }, + { + "fullUrl": "urn:uuid:5783dafa-c6c0-e673-cca4-42087ee1831b", + "resource": { + "resourceType": "Location", + "id": "5783dafa-c6c0-e673-cca4-42087ee1831b", + "partOf": { + "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + }, + "name": "B", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" + } + }, + { + "fullUrl": "urn:uuid:8b39e6e5-78cd-63ab-2441-f43ca5554096", + "resource": { + "resourceType": "Location", + "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", + "name": "CommunityHospital", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" + } + }, + { + "fullUrl": "urn:uuid:42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "resource": { + "resourceType": "Location", + "id": "42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "name": "Homes", + "identifier": [ + { + "value": "22", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/FDK" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + { + "fullUrl": "urn:uuid:1154e6b2-b022-b3be-7dce-2b940ab5376d", + "resource": { + "resourceType": "Location", + "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", + "name": "Nursing home", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + } + }, + { + "fullUrl": "urn:uuid:08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "resource": { + "resourceType": "Location", + "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "name": "Rosewood", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" + } + }, + { + "fullUrl": "urn:uuid:08314073-410a-3dc7-512c-0f2d206fb59d", + "resource": { + "resourceType": "Organization", + "id": "08314073-410a-3dc7-512c-0f2d206fb59d", + "identifier": [ + { + "value": "Etest", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-Etest" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + }, + { + "fullUrl": "urn:uuid:919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "resource": { + "resourceType": "EpisodeOfCare", + "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "status": "active", + "identifier": [ + { + "value": "EOC124", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + }, + { + "fullUrl": "urn:uuid:4b192760-03d2-aec4-b0a6-fde323912e1e", + "resource": { + "resourceType": "Encounter", + "id": "4b192760-03d2-aec4-b0a6-fde323912e1e", + "class": { + "code": "PRENC", + "display": "pre-admission", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "in-progress", + "location": [ + { + "status": "active", + "location": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "status": "completed", + "location": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "status": "completed", + "location": { + "reference": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": true + } + ] + } + ], + "type": [ + { + "coding": [ + { + "code": "E", + "display": "Emergency", + "system": "http://terminology.hl7.org/CodeSystem/v2-0007" + } + ] + } + ], + "hospitalization": { + "preAdmissionIdentifier": { + "value": "1234567", + "type": { + "coding": [ + { + "code": "ANON", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Anonymous identifier" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + "reAdmission": { + "coding": [ + { + "code": "R", + "display": "Re-admission", + "system": "http://terminology.hl7.org/CodeSystem/v2-0092" + } + ] + }, + "admitSource": { + "coding": [ + { + "code": "NHS Provider-General (inc.A&E-this Hosp)" + } + ] + }, + "dischargeDisposition": { + "coding": [ + { + "code": "Admitted as Inpatient", + "display": "Sample", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ACR" + } + ] + }, + "dietPreference": [ + { + "coding": [ + { + "code": "Vegan", + "display": "Vegetarian" + } + ] + } + ], + "destination": { + "reference": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + "episodeOfCare": [ + { + "reference": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "CON", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "consultant" + } + ], + "individual": { + "reference": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "ADM", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "admitter" + } + ], + "individual": { + "reference": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "PART", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "Participation" + } + ], + "individual": { + "reference": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + } + ], + "serviceType": { + "coding": [ + { + "code": "SUR" + } + ] + }, + "identifier": [ + { + "value": "40007716", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + }, + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + }, + { + "value": "50", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "urn:oid:r2.3", + "assigner": { + "reference": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + } + ], + "period": { + "start": "2015-02-08T15:54:19+05:30" + }, + "text": { + "status": "generated", + "div": "

Visit Description:

" + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "Encounter/4b192760-03d2-aec4-b0a6-fde323912e1e" + } + }, + { + "fullUrl": "urn:uuid:9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "resource": { + "resourceType": "Provenance", + "id": "9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "occurredDateTime": "2021-08-17T18:49:43.004+05:30", + "recorded": "2029-08-01T11:21:24+05:30", + "reason": [ + { + "coding": [ + { + "code": "PATRQT", + "display": "patient requested", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActReason" + } + ] + } + ], + "agent": [ + { + "who": { + "reference": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + } + ], + "activity": { + "text": "ADT^A26^ADT_A26" + }, + "location": { + "reference": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + }, + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c" + } + }, + { + "fullUrl": "urn:uuid:ef39f581-5e8f-3917-35a9-3443303d9eee", + "resource": { + "resourceType": "Organization", + "id": "ef39f581-5e8f-3917-35a9-3443303d9eee", + "identifier": [ + { + "value": "DRNBR", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-DRNBR" + }, + { + "value": "urn:oid:W1.2", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + } + }, + { + "fullUrl": "urn:uuid:95aea53b-8d49-d57f-d16f-4d14b914f992", + "resource": { + "resourceType": "Practitioner", + "id": "95aea53b-8d49-d57f-d16f-4d14b914f992", + "identifier": [ + { + "value": "C08", + "system": "urn:oid:W1.2", + "assigner": { + "reference": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + }, + "type": { + "coding": [ + { + "code": "ANON", + "display": "Anonymous identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen", + "2ndname" + ], + "suffix": [ + "Jr", + "MD" + ], + "prefix": [ + "Dr" + ], + "use": "official" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + }, + { + "fullUrl": "urn:uuid:59d5e519-0108-5dd8-adfa-1eef5658009e", + "resource": { + "resourceType": "Location", + "id": "59d5e519-0108-5dd8-adfa-1eef5658009e", + "name": "Cona_Health", + "identifier": [ + { + "value": "urn:oid:1.3.6.1.4.1.44750.1.4", + "system": "urn:ietf:rfc:3986" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "display": "site", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A27/ADT-A27-01-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A27/ADT-A27-01-expected.json new file mode 100644 index 000000000..7dec6d11d --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A27/ADT-A27-01-expected.json @@ -0,0 +1,2886 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "1989-08-18T14:41:00+05:30", + "identifier": { + "value": "MSG00001" + }, + "id": "513a3d06-5e87-6fbc-ad1b-170ab430499f", + "entry": [ + { + "fullUrl": "urn:uuid:b4ca189b-51ae-33df-cbe2-559b4423a321", + "resource": { + "resourceType": "MessageHeader", + "id": "b4ca189b-51ae-33df-cbe2-559b4423a321", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20", + "version": "2.4.3.52854", + "software": "Rhapsody" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "A27", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "ADT^A27^ADT_A27" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/b4ca189b-51ae-33df-cbe2-559b4423a321" + } + }, + { + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "resource": { + "resourceType": "Provenance", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T10:35:13.183Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A27.

" + }, + "occurredDateTime": "1989-08-18T14:41:00+05:30", + "recorded": "1989-08-18T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "ADT^A27^ADT_A27" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + } + ], + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:503eb873-22fb-8199-ae28-3604ad59fe13", + "resource": { + "resourceType": "Device", + "id": "503eb873-22fb-8199-ae28-3604ad59fe13", + "identifier": [ + { + "value": "ADTApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + }, + { + "fullUrl": "urn:uuid:4b549918-a84d-cdaf-e150-c773a5d306e5", + "resource": { + "resourceType": "Device", + "id": "4b549918-a84d-cdaf-e150-c773a5d306e5", + "manufacturer": "Orion", + "deviceName": [ + { + "name": "Rhapsody", + "type": "manufacturer-name" + } + ], + "version": [ + { + "value": "2.4.3.52854" + } + ], + "modelNumber": "2.4.3", + "note": [ + { + "text": "Testactivity" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/4b549918-a84d-cdaf-e150-c773a5d306e5" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + }, + { + "value": "DB123", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "urn:oid:1.12", + "assigner": { + "reference": "Organization/4e68b44e-c053-02b1-6d6d-fe816f9fdfec" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "generalPractitioner": [ + { + "reference": "Organization/4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11" + }, + { + "reference": "Practitioner/76aaad38-1077-6a5c-0c5c-102ec160a60d" + } + ], + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/VeteranMilitaryStatus", + "valueCodeableConcept": { + "coding": [ + { + "code": "Vet123", + "display": "retired", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ART" + } + ], + "text": "retired" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-animal", + "extension": [ + { + "url": "species", + "valueCodeableConcept": { + "coding": [ + { + "code": "125097000", + "display": "Goat", + "system": "http://snomed.info/sct" + } + ], + "text": "Goat" + } + }, + { + "url": "breed", + "valueCodeableConcept": { + "coding": [ + { + "code": "4880003", + "display": "Beagle", + "system": "http://snomed.info/sct" + } + ], + "text": "Beagle" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-nationality", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "BT", + "display": "Bhutan", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Bhutan" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-congregation", + "valueString": "Methodist Church" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-importance", + "valueCodeableConcept": { + "coding": [ + { + "code": "VIP", + "display": "Very Important Person", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L", + "version": "v1.1" + }, + { + "code": "IMP", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/DCM", + "version": "v1.2" + } + ], + "text": "Inportant Person" + } + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/patient-disabilityIndicator", + "valueBoolean": true + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/DisabilityPeriod", + "valuePeriod": { + "start": "2021-08-30", + "end": "2021-09-30" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11", + "resource": { + "resourceType": "Organization", + "id": "4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11", + "name": "LINDAS TEST ORGANIZATION", + "identifier": [ + { + "value": "SIISCLIENT818" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11" + } + }, + { + "fullUrl": "urn:uuid:76aaad38-1077-6a5c-0c5c-102ec160a60d", + "resource": { + "resourceType": "Practitioner", + "id": "76aaad38-1077-6a5c-0c5c-102ec160a60d", + "identifier": [ + { + "value": "88", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TE", + "type": { + "coding": [ + { + "code": "DN", + "display": "Doctor number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Hippo", + "given": [ + "rold", + "H" + ], + "suffix": [ + "V", + "MD" + ], + "prefix": [ + "Dr" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/76aaad38-1077-6a5c-0c5c-102ec160a60d" + } + }, + { + "fullUrl": "urn:uuid:11967e28-8dd4-a112-0fdc-377866bf12a0", + "resource": { + "resourceType": "Organization", + "id": "11967e28-8dd4-a112-0fdc-377866bf12a0", + "identifier": [ + { + "value": "t", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-t" + }, + { + "value": "2.16.840.1.113883.19", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + } + }, + { + "fullUrl": "urn:uuid:7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "resource": { + "resourceType": "Organization", + "id": "7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "identifier": [ + { + "value": "AccMng", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMng" + }, + { + "value": "1.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + } + }, + { + "fullUrl": "urn:uuid:0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "resource": { + "resourceType": "Organization", + "id": "0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "identifier": [ + { + "value": "PERSONNELt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSONNELt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + } + }, + { + "fullUrl": "urn:uuid:f6775f99-5279-be04-bf81-0906c81f7443", + "resource": { + "resourceType": "Practitioner", + "id": "f6775f99-5279-be04-bf81-0906c81f7443", + "identifier": [ + { + "value": "1122334", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Alaz", + "given": [ + "Mohammed", + "Mahi" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "fullUrl": "urn:uuid:c613d7b2-525f-8c08-a7ac-b2b91486e257", + "resource": { + "resourceType": "Organization", + "id": "c613d7b2-525f-8c08-a7ac-b2b91486e257", + "identifier": [ + { + "value": "TEST", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TEST" + }, + { + "value": "23.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + } + }, + { + "fullUrl": "urn:uuid:04f8cfc8-62ca-12df-63ce-6304ef577d44", + "resource": { + "resourceType": "Practitioner", + "id": "04f8cfc8-62ca-12df-63ce-6304ef577d44", + "identifier": [ + { + "value": "C006", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + }, + "type": { + "coding": [ + { + "code": "BA", + "display": "Bank Account Number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen" + ], + "prefix": [ + "Dr" + ], + "use": "anonymous" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "fullUrl": "urn:uuid:99edcabd-fbeb-7e25-f823-11da8d8ed342", + "resource": { + "resourceType": "Practitioner", + "id": "99edcabd-fbeb-7e25-f823-11da8d8ed342", + "identifier": [ + { + "value": "C008", + "system": "urn:oid:2.8", + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Condoc", + "given": [ + "leen" + ], + "prefix": [ + "Dr" + ], + "use": "temp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "fullUrl": "urn:uuid:b065b233-8738-f1ec-1314-d61e4aac2c9e", + "resource": { + "resourceType": "Practitioner", + "id": "b065b233-8738-f1ec-1314-d61e4aac2c9e", + "identifier": [ + { + "value": "37", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr", + "type": { + "coding": [ + { + "code": "ANC", + "display": "Account number Creditor", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "DISNEY", + "given": [ + "WALT" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "fullUrl": "urn:uuid:9f974d4f-47e8-21a6-e549-4de4599c3764", + "resource": { + "resourceType": "Organization", + "id": "9f974d4f-47e8-21a6-e549-4de4599c3764", + "identifier": [ + { + "value": "T123", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-T123" + }, + { + "value": "urn:oid:r2.3", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + }, + { + "fullUrl": "urn:uuid:84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "resource": { + "resourceType": "Practitioner", + "id": "84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "identifier": [ + { + "value": "Othhel", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "fullUrl": "urn:uuid:24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "resource": { + "resourceType": "Organization", + "id": "24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "identifier": [ + { + "value": "TE", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TE" + }, + { + "value": "Provider Master.Community Health and Hospitals", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "type": { + "coding": [ + { + "code": "DNS", + "display": "An Internet host name, in accordance with RFC 1035; or an IP address. Either in ASCII or as integers, with periods between components (“dotted” notation).", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + } + }, + { + "fullUrl": "urn:uuid:36e3aaa4-569a-7d9d-037f-27235ed05701", + "resource": { + "resourceType": "Practitioner", + "id": "36e3aaa4-569a-7d9d-037f-27235ed05701", + "identifier": [ + { + "value": "12188", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "assigner": { + "reference": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + }, + "type": { + "coding": [ + { + "code": "DN", + "display": "Doctor number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Hippocrates", + "given": [ + "Harold", + "H" + ], + "suffix": [ + "IV", + "MD" + ], + "prefix": [ + "Dr" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + }, + { + "fullUrl": "urn:uuid:9172e4a0-1ca5-646d-2183-b179f4daa737", + "resource": { + "resourceType": "Location", + "id": "9172e4a0-1ca5-646d-2183-b179f4daa737", + "partOf": { + "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + }, + "name": "HUH AE OMU", + "identifier": [ + { + "value": "urn:oid:9.8", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "fullUrl": "urn:uuid:3913ec4d-6576-5e1a-ac31-e8280583371c", + "resource": { + "resourceType": "Location", + "id": "3913ec4d-6576-5e1a-ac31-e8280583371c", + "partOf": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + }, + "name": "OMU B", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + } + }, + { + "fullUrl": "urn:uuid:804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "resource": { + "resourceType": "Location", + "id": "804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "partOf": { + "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + }, + "name": "Bed 03", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" + } + }, + { + "fullUrl": "urn:uuid:c043880b-0fab-1cb8-14f7-0475282c4d0e", + "resource": { + "resourceType": "Location", + "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", + "name": "HOMERTON UNIVER", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + } + }, + { + "fullUrl": "urn:uuid:f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "resource": { + "resourceType": "Location", + "id": "f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "partOf": { + "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + }, + "name": "Homerton UH", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + } + }, + { + "fullUrl": "urn:uuid:7e38808c-44a8-cb0c-4709-9d6092abc32c", + "resource": { + "resourceType": "Location", + "id": "7e38808c-44a8-cb0c-4709-9d6092abc32c", + "partOf": { + "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + }, + "name": "Floor5", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + } + }, + { + "fullUrl": "urn:uuid:59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "resource": { + "resourceType": "Location", + "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "name": "4 East, room 136, bed B 4E", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + } + }, + { + "fullUrl": "urn:uuid:d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "resource": { + "resourceType": "Location", + "id": "d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "partOf": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "name": "136", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + } + }, + { + "fullUrl": "urn:uuid:5783dafa-c6c0-e673-cca4-42087ee1831b", + "resource": { + "resourceType": "Location", + "id": "5783dafa-c6c0-e673-cca4-42087ee1831b", + "partOf": { + "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + }, + "name": "B", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" + } + }, + { + "fullUrl": "urn:uuid:8b39e6e5-78cd-63ab-2441-f43ca5554096", + "resource": { + "resourceType": "Location", + "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", + "name": "CommunityHospital", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" + } + }, + { + "fullUrl": "urn:uuid:42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "resource": { + "resourceType": "Location", + "id": "42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "name": "Homes", + "identifier": [ + { + "value": "22", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/FDK" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + { + "fullUrl": "urn:uuid:84634858-74aa-5cdb-4547-60ec27339ac6", + "resource": { + "resourceType": "Location", + "id": "84634858-74aa-5cdb-4547-60ec27339ac6", + "name": "POC", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + } + }, + { + "fullUrl": "urn:uuid:9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", + "resource": { + "resourceType": "Location", + "id": "9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", + "partOf": { + "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + }, + "name": "Room-2", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" + } + }, + { + "fullUrl": "urn:uuid:35353f20-6254-e794-98ed-8007490447e3", + "resource": { + "resourceType": "Location", + "id": "35353f20-6254-e794-98ed-8007490447e3", + "partOf": { + "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" + }, + "name": "Bed-103", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/35353f20-6254-e794-98ed-8007490447e3" + } + }, + { + "fullUrl": "urn:uuid:055e10f1-222e-df73-2325-0e4396db1a55", + "resource": { + "resourceType": "Location", + "id": "055e10f1-222e-df73-2325-0e4396db1a55", + "name": "Greenland", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/055e10f1-222e-df73-2325-0e4396db1a55" + } + }, + { + "fullUrl": "urn:uuid:1154e6b2-b022-b3be-7dce-2b940ab5376d", + "resource": { + "resourceType": "Location", + "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", + "name": "Nursing home", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + } + }, + { + "fullUrl": "urn:uuid:08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "resource": { + "resourceType": "Location", + "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "name": "Rosewood", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" + } + }, + { + "fullUrl": "urn:uuid:c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "resource": { + "resourceType": "Location", + "id": "c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "name": "ROOM1", + "identifier": [ + { + "value": "urn:oid:2.16.840.1.113883.4.642.1.1108", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + } + }, + { + "fullUrl": "urn:uuid:6f159848-5f01-01b3-9594-80fbbe9ab510", + "resource": { + "resourceType": "Location", + "id": "6f159848-5f01-01b3-9594-80fbbe9ab510", + "partOf": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "name": "BED1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" + } + }, + { + "fullUrl": "urn:uuid:4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "resource": { + "resourceType": "Location", + "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "name": "FACILITY1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + } + }, + { + "fullUrl": "urn:uuid:3b0911cb-4361-cd8d-b188-463af033c699", + "resource": { + "resourceType": "Location", + "id": "3b0911cb-4361-cd8d-b188-463af033c699", + "partOf": { + "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + }, + "name": "BUILDING1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:08314073-410a-3dc7-512c-0f2d206fb59d", + "resource": { + "resourceType": "Organization", + "id": "08314073-410a-3dc7-512c-0f2d206fb59d", + "identifier": [ + { + "value": "Etest", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-Etest" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + }, + { + "fullUrl": "urn:uuid:919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "resource": { + "resourceType": "EpisodeOfCare", + "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "status": "cancelled", + "identifier": [ + { + "value": "EOC124", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + }, + { + "fullUrl": "urn:uuid:4b192760-03d2-aec4-b0a6-fde323912e1e", + "resource": { + "resourceType": "Encounter", + "id": "4b192760-03d2-aec4-b0a6-fde323912e1e", + "class": { + "code": "PRENC", + "display": "pre-admission", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "cancelled", + "location": [ + { + "location": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "location": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "location": { + "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "location": { + "reference": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": true + } + ] + }, + { + "location": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + } + ], + "type": [ + { + "coding": [ + { + "code": "E", + "display": "Emergency", + "system": "http://terminology.hl7.org/CodeSystem/v2-0007" + } + ] + } + ], + "hospitalization": { + "preAdmissionIdentifier": { + "value": "1234567", + "type": { + "coding": [ + { + "code": "ANON", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Anonymous identifier" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + "reAdmission": { + "coding": [ + { + "code": "R", + "display": "Re-admission", + "system": "http://terminology.hl7.org/CodeSystem/v2-0092" + } + ] + }, + "admitSource": { + "coding": [ + { + "code": "NHS Provider-General (inc.A&E-this Hosp)" + } + ] + }, + "dischargeDisposition": { + "coding": [ + { + "code": "Admitted as Inpatient", + "display": "Sample", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ACR" + } + ] + }, + "dietPreference": [ + { + "coding": [ + { + "code": "Vegan", + "display": "Vegetarian" + } + ] + } + ], + "destination": { + "reference": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + "episodeOfCare": [ + { + "reference": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "CON", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "consultant" + } + ], + "individual": { + "reference": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "ADM", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "admitter" + } + ], + "individual": { + "reference": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "PART", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "Participation" + } + ], + "individual": { + "reference": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + } + ], + "serviceType": { + "coding": [ + { + "code": "SUR" + } + ] + }, + "identifier": [ + { + "value": "40007716", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + }, + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + }, + { + "value": "50", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "urn:oid:r2.3", + "assigner": { + "reference": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + } + ], + "period": { + "start": "2015-02-08T15:54:19+05:30", + "end": "2015-02-09T15:54:19+05:30" + }, + "reasonCode": [ + { + "coding": [ + { + "code": "140004", + "display": "Chronic pharyngitis", + "system": "http://snomed.info/sct" + } + ] + } + ], + "length": { + "value": 2, + "unit": "d", + "system": "http://unitsofmeasure.org/" + }, + "meta": { + "security": [ + { + "code": "N", + "display": "normal", + "system": "http://terminology.hl7.org/CodeSystem/v3-Confidentiality" + } + ] + }, + "text": { + "status": "generated", + "div": "

Visit Description: Health Checkup

" + }, + "priority": { + "coding": [ + { + "code": "UR", + "display": "urgent", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.2" + }, + { + "code": "EL", + "display": "elective", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.3" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/encounter-modeOfArrival", + "valueCoding": { + "code": "C", + "display": "Car", + "system": "http://terminology.hl7.org/CodeSystem/v2-0430" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Encounter/4b192760-03d2-aec4-b0a6-fde323912e1e" + } + }, + { + "fullUrl": "urn:uuid:9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "resource": { + "resourceType": "Provenance", + "id": "9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "occurredDateTime": "2021-08-17T18:49:43.004+05:30", + "recorded": "2029-08-01T11:21:24+05:30", + "reason": [ + { + "coding": [ + { + "code": "PATRQT", + "display": "patient requested", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActReason" + } + ] + } + ], + "agent": [ + { + "who": { + "reference": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + } + ], + "activity": { + "text": "ADT^A27^ADT_A27" + }, + "location": { + "reference": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + }, + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c" + } + }, + { + "fullUrl": "urn:uuid:ef39f581-5e8f-3917-35a9-3443303d9eee", + "resource": { + "resourceType": "Organization", + "id": "ef39f581-5e8f-3917-35a9-3443303d9eee", + "identifier": [ + { + "value": "DRNBR", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-DRNBR" + }, + { + "value": "urn:oid:W1.2", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + } + }, + { + "fullUrl": "urn:uuid:95aea53b-8d49-d57f-d16f-4d14b914f992", + "resource": { + "resourceType": "Practitioner", + "id": "95aea53b-8d49-d57f-d16f-4d14b914f992", + "identifier": [ + { + "value": "C08", + "system": "urn:oid:W1.2", + "assigner": { + "reference": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + }, + "type": { + "coding": [ + { + "code": "ANON", + "display": "Anonymous identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen", + "2ndname" + ], + "suffix": [ + "Jr", + "MD" + ], + "prefix": [ + "Dr" + ], + "use": "official" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + }, + { + "fullUrl": "urn:uuid:59d5e519-0108-5dd8-adfa-1eef5658009e", + "resource": { + "resourceType": "Location", + "id": "59d5e519-0108-5dd8-adfa-1eef5658009e", + "name": "Cona_Health", + "identifier": [ + { + "value": "urn:oid:1.3.6.1.4.1.44750.1.4", + "system": "urn:ietf:rfc:3986" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "display": "site", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + } + }, + { + "fullUrl": "urn:uuid:4e68b44e-c053-02b1-6d6d-fe816f9fdfec", + "resource": { + "resourceType": "Organization", + "id": "4e68b44e-c053-02b1-6d6d-fe816f9fdfec", + "identifier": [ + { + "value": "t", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-t" + }, + { + "value": "urn:oid:1.12", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4e68b44e-c053-02b1-6d6d-fe816f9fdfec" + } + }, + { + "fullUrl": "urn:uuid:e82402a9-b2d1-2a28-3250-c099d5a77bf7", + "resource": { + "resourceType": "Organization", + "id": "e82402a9-b2d1-2a28-3250-c099d5a77bf7", + "identifier": [ + { + "value": "PERSt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/e82402a9-b2d1-2a28-3250-c099d5a77bf7" + } + }, + { + "fullUrl": "urn:uuid:ce70e6c3-c190-121d-c251-e4bae5cde6a1", + "resource": { + "resourceType": "Practitioner", + "id": "ce70e6c3-c190-121d-c251-e4bae5cde6a1", + "identifier": [ + { + "value": "1134", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/e82402a9-b2d1-2a28-3250-c099d5a77bf7" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Aly", + "given": [ + "Zafar", + "Mahendra" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/ce70e6c3-c190-121d-c251-e4bae5cde6a1" + } + }, + { + "fullUrl": "urn:uuid:88a53755-c972-6904-b4ce-8884b84ddc2e", + "resource": { + "resourceType": "PractitionerRole", + "id": "88a53755-c972-6904-b4ce-8884b84ddc2e", + "code": [ + { + "coding": [ + { + "code": "ResponsibleObserver", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/ce70e6c3-c190-121d-c251-e4bae5cde6a1" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/88a53755-c972-6904-b4ce-8884b84ddc2e" + } + }, + { + "fullUrl": "urn:uuid:3e0952c6-eea0-8938-96f8-07c224bf1577", + "resource": { + "resourceType": "Practitioner", + "id": "3e0952c6-eea0-8938-96f8-07c224bf1577", + "identifier": [ + { + "value": "2234" + } + ], + "name": [ + { + "family": "Pauly", + "given": [ + "Berrie", + "Raud" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/3e0952c6-eea0-8938-96f8-07c224bf1577" + } + }, + { + "fullUrl": "urn:uuid:bc78e290-ec67-c238-1e05-aefb6b252b0c", + "resource": { + "resourceType": "PractitionerRole", + "id": "bc78e290-ec67-c238-1e05-aefb6b252b0c", + "code": [ + { + "coding": [ + { + "code": "ResponsibleObserver", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/3e0952c6-eea0-8938-96f8-07c224bf1577" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/bc78e290-ec67-c238-1e05-aefb6b252b0c" + } + }, + { + "fullUrl": "urn:uuid:fe0adb86-ebe9-6479-0055-9db8dc1ff99a", + "resource": { + "resourceType": "Device", + "id": "fe0adb86-ebe9-6479-0055-9db8dc1ff99a", + "identifier": [ + { + "value": "EI12.3", + "system": "urn:uuid:UI2", + "type": { + "coding": [ + { + "code": "GUID", + "display": "Same as UUID.", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + }, + { + "system": "urn:oid:UI1", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/fe0adb86-ebe9-6479-0055-9db8dc1ff99a" + } + }, + { + "fullUrl": "urn:uuid:45f65e47-46c4-1a54-f9fb-1321258e79b2", + "resource": { + "resourceType": "Practitioner", + "id": "45f65e47-46c4-1a54-f9fb-1321258e79b2", + "identifier": [ + { + "type": { + "coding": [ + { + "code": "MD-25" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/45f65e47-46c4-1a54-f9fb-1321258e79b2" + } + }, + { + "fullUrl": "urn:uuid:090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3", + "resource": { + "resourceType": "PractitionerRole", + "id": "090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3", + "code": [ + { + "coding": [ + { + "code": "LabMedicalDirector", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/45f65e47-46c4-1a54-f9fb-1321258e79b2" + }, + "organization": { + "reference": "Organization/056aa7c7-6b75-3c67-63c5-cf9604f16d25" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3" + } + }, + { + "fullUrl": "urn:uuid:056aa7c7-6b75-3c67-63c5-cf9604f16d25", + "resource": { + "resourceType": "Organization", + "id": "056aa7c7-6b75-3c67-63c5-cf9604f16d25", + "name": "FairOaks Hspital", + "address": [ + { + "line": [ + "Research Park", + "Fairfax" + ], + "city": "VA", + "state": "22031", + "postalCode": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/056aa7c7-6b75-3c67-63c5-cf9604f16d25" + } + }, + { + "fullUrl": "urn:uuid:07fd2dd3-dbd6-5bb1-cfda-02226795d9a0", + "resource": { + "resourceType": "Observation", + "id": "07fd2dd3-dbd6-5bb1-cfda-02226795d9a0", + "identifier": [ + { + "value": "EI21", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-OII" + }, + { + "type": { + "coding": [ + { + "code": "FILL" + } + ] + } + } + ], + "status": "unknown", + "code": { + "coding": [ + { + "code": "8867-4", + "display": "heartrate", + "system": "http://loinc.org" + } + ] + }, + "component": [ + { + "code": { + "coding": [ + { + "code": "8867-4", + "display": "heartrate", + "system": "http://loinc.org" + } + ] + }, + "valueQuantity": { + "value": 60, + "code": "beats/min", + "unit": "beats/min", + "system": "urn:iso:std:iso:3986" + }, + "referenceRange": [ + { + "text": "70-80" + } + ] + }, + { + "code": { + "coding": [ + { + "code": "8867-4", + "display": "heartrate", + "system": "http://loinc.org" + } + ] + }, + "valueQuantity": { + "value": 120, + "code": "beats/min", + "unit": "beats/min", + "system": "urn:iso:std:iso:3986" + }, + "referenceRange": [ + { + "text": "70-80" + } + ] + } + ], + "effectiveDateTime": "1999-07-02", + "method": { + "coding": [ + { + "code": "OBS", + "display": "This is test method", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/AS4" + } + ] + }, + "device": { + "reference": "Device/fe0adb86-ebe9-6479-0055-9db8dc1ff99a" + }, + "bodySite": { + "coding": [ + { + "code": "BU", + "display": "Observation site", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/E5" + } + ] + }, + "performer": [ + { + "reference": "PractitionerRole/88a53755-c972-6904-b4ce-8884b84ddc2e" + }, + { + "reference": "PractitionerRole/bc78e290-ec67-c238-1e05-aefb6b252b0c" + }, + { + "reference": "PractitionerRole/090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3" + } + ], + "interpretation": [ + { + "coding": [ + { + "code": "A", + "display": "Abnormal", + "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation" + } + ] + }, + { + "coding": [ + { + "code": "B", + "display": "Better", + "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation" + } + ] + } + ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "S", + "display": "Partial", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Partial" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/07fd2dd3-dbd6-5bb1-cfda-02226795d9a0" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A27/ADT-A27-02-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A27/ADT-A27-02-expected.json new file mode 100644 index 000000000..3c8f3ce5a --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A27/ADT-A27-02-expected.json @@ -0,0 +1,2307 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "1989-08-18T14:41:00+05:30", + "identifier": { + "value": "MSG00001" + }, + "id": "513a3d06-5e87-6fbc-ad1b-170ab430499f", + "entry": [ + { + "fullUrl": "urn:uuid:b4ca189b-51ae-33df-cbe2-559b4423a321", + "resource": { + "resourceType": "MessageHeader", + "id": "b4ca189b-51ae-33df-cbe2-559b4423a321", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "A27", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "ADT^A27^ADT_A27" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/b4ca189b-51ae-33df-cbe2-559b4423a321" + } + }, + { + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "resource": { + "resourceType": "Provenance", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T10:35:48.22Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A27.

" + }, + "occurredDateTime": "1989-08-18T14:41:00+05:30", + "recorded": "1989-08-18T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "ADT^A27^ADT_A27" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + } + ], + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:503eb873-22fb-8199-ae28-3604ad59fe13", + "resource": { + "resourceType": "Device", + "id": "503eb873-22fb-8199-ae28-3604ad59fe13", + "identifier": [ + { + "value": "ADTApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/VeteranMilitaryStatus", + "valueCodeableConcept": { + "coding": [ + { + "code": "Vet123", + "display": "retired", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ART" + } + ], + "text": "retired" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-animal", + "extension": [ + { + "url": "species", + "valueCodeableConcept": { + "coding": [ + { + "code": "125097000", + "display": "Goat", + "system": "http://snomed.info/sct" + } + ], + "text": "Goat" + } + }, + { + "url": "breed", + "valueCodeableConcept": { + "coding": [ + { + "code": "4880003", + "display": "Beagle", + "system": "http://snomed.info/sct" + } + ], + "text": "Beagle" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-nationality", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "BT", + "display": "Bhutan", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Bhutan" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-importance", + "valueCodeableConcept": { + "coding": [ + { + "code": "VIP", + "display": "Very Important Person", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L", + "version": "v1.1" + }, + { + "code": "IMP", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/DCM", + "version": "v1.2" + } + ], + "text": "Inportant Person" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:11967e28-8dd4-a112-0fdc-377866bf12a0", + "resource": { + "resourceType": "Organization", + "id": "11967e28-8dd4-a112-0fdc-377866bf12a0", + "identifier": [ + { + "value": "t", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-t" + }, + { + "value": "2.16.840.1.113883.19", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + } + }, + { + "fullUrl": "urn:uuid:7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "resource": { + "resourceType": "Organization", + "id": "7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "identifier": [ + { + "value": "AccMng", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMng" + }, + { + "value": "1.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + } + }, + { + "fullUrl": "urn:uuid:0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "resource": { + "resourceType": "Organization", + "id": "0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "identifier": [ + { + "value": "PERSONNELt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSONNELt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + } + }, + { + "fullUrl": "urn:uuid:f6775f99-5279-be04-bf81-0906c81f7443", + "resource": { + "resourceType": "Practitioner", + "id": "f6775f99-5279-be04-bf81-0906c81f7443", + "identifier": [ + { + "value": "1122334", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Alaz", + "given": [ + "Mohammed", + "Mahi" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "fullUrl": "urn:uuid:c613d7b2-525f-8c08-a7ac-b2b91486e257", + "resource": { + "resourceType": "Organization", + "id": "c613d7b2-525f-8c08-a7ac-b2b91486e257", + "identifier": [ + { + "value": "TEST", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TEST" + }, + { + "value": "23.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + } + }, + { + "fullUrl": "urn:uuid:04f8cfc8-62ca-12df-63ce-6304ef577d44", + "resource": { + "resourceType": "Practitioner", + "id": "04f8cfc8-62ca-12df-63ce-6304ef577d44", + "identifier": [ + { + "value": "C006", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + }, + "type": { + "coding": [ + { + "code": "BA", + "display": "Bank Account Number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen" + ], + "prefix": [ + "Dr" + ], + "use": "anonymous" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "fullUrl": "urn:uuid:99edcabd-fbeb-7e25-f823-11da8d8ed342", + "resource": { + "resourceType": "Practitioner", + "id": "99edcabd-fbeb-7e25-f823-11da8d8ed342", + "identifier": [ + { + "value": "C008", + "system": "urn:oid:2.8", + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Condoc", + "given": [ + "leen" + ], + "prefix": [ + "Dr" + ], + "use": "temp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "fullUrl": "urn:uuid:b065b233-8738-f1ec-1314-d61e4aac2c9e", + "resource": { + "resourceType": "Practitioner", + "id": "b065b233-8738-f1ec-1314-d61e4aac2c9e", + "identifier": [ + { + "value": "37", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr", + "type": { + "coding": [ + { + "code": "ANC", + "display": "Account number Creditor", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "DISNEY", + "given": [ + "WALT" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "fullUrl": "urn:uuid:9f974d4f-47e8-21a6-e549-4de4599c3764", + "resource": { + "resourceType": "Organization", + "id": "9f974d4f-47e8-21a6-e549-4de4599c3764", + "identifier": [ + { + "value": "T123", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-T123" + }, + { + "value": "urn:oid:r2.3", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + }, + { + "fullUrl": "urn:uuid:84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "resource": { + "resourceType": "Practitioner", + "id": "84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "identifier": [ + { + "value": "Othhel", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "fullUrl": "urn:uuid:24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "resource": { + "resourceType": "Organization", + "id": "24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "identifier": [ + { + "value": "TE", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TE" + }, + { + "value": "Provider Master.Community Health and Hospitals", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "type": { + "coding": [ + { + "code": "DNS", + "display": "An Internet host name, in accordance with RFC 1035; or an IP address. Either in ASCII or as integers, with periods between components (“dotted” notation).", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + } + }, + { + "fullUrl": "urn:uuid:36e3aaa4-569a-7d9d-037f-27235ed05701", + "resource": { + "resourceType": "Practitioner", + "id": "36e3aaa4-569a-7d9d-037f-27235ed05701", + "identifier": [ + { + "value": "12188", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "assigner": { + "reference": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + }, + "type": { + "coding": [ + { + "code": "DN", + "display": "Doctor number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Hippocrates", + "given": [ + "Harold", + "H" + ], + "suffix": [ + "IV", + "MD" + ], + "prefix": [ + "Dr" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + }, + { + "fullUrl": "urn:uuid:9172e4a0-1ca5-646d-2183-b179f4daa737", + "resource": { + "resourceType": "Location", + "id": "9172e4a0-1ca5-646d-2183-b179f4daa737", + "partOf": { + "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + }, + "name": "HUH AE OMU", + "identifier": [ + { + "value": "urn:oid:9.8", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "fullUrl": "urn:uuid:3913ec4d-6576-5e1a-ac31-e8280583371c", + "resource": { + "resourceType": "Location", + "id": "3913ec4d-6576-5e1a-ac31-e8280583371c", + "partOf": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + }, + "name": "OMU B", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + } + }, + { + "fullUrl": "urn:uuid:804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "resource": { + "resourceType": "Location", + "id": "804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "partOf": { + "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + }, + "name": "Bed 03", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" + } + }, + { + "fullUrl": "urn:uuid:c043880b-0fab-1cb8-14f7-0475282c4d0e", + "resource": { + "resourceType": "Location", + "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", + "name": "HOMERTON UNIVER", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + } + }, + { + "fullUrl": "urn:uuid:f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "resource": { + "resourceType": "Location", + "id": "f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "partOf": { + "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + }, + "name": "Homerton UH", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + } + }, + { + "fullUrl": "urn:uuid:7e38808c-44a8-cb0c-4709-9d6092abc32c", + "resource": { + "resourceType": "Location", + "id": "7e38808c-44a8-cb0c-4709-9d6092abc32c", + "partOf": { + "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + }, + "name": "Floor5", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + } + }, + { + "fullUrl": "urn:uuid:59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "resource": { + "resourceType": "Location", + "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "name": "4 East, room 136, bed B 4E", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + } + }, + { + "fullUrl": "urn:uuid:d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "resource": { + "resourceType": "Location", + "id": "d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "partOf": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "name": "136", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + } + }, + { + "fullUrl": "urn:uuid:5783dafa-c6c0-e673-cca4-42087ee1831b", + "resource": { + "resourceType": "Location", + "id": "5783dafa-c6c0-e673-cca4-42087ee1831b", + "partOf": { + "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + }, + "name": "B", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" + } + }, + { + "fullUrl": "urn:uuid:8b39e6e5-78cd-63ab-2441-f43ca5554096", + "resource": { + "resourceType": "Location", + "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", + "name": "CommunityHospital", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" + } + }, + { + "fullUrl": "urn:uuid:42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "resource": { + "resourceType": "Location", + "id": "42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "name": "Homes", + "identifier": [ + { + "value": "22", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/FDK" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + { + "fullUrl": "urn:uuid:84634858-74aa-5cdb-4547-60ec27339ac6", + "resource": { + "resourceType": "Location", + "id": "84634858-74aa-5cdb-4547-60ec27339ac6", + "name": "POC", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + } + }, + { + "fullUrl": "urn:uuid:9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", + "resource": { + "resourceType": "Location", + "id": "9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", + "partOf": { + "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + }, + "name": "Room-2", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" + } + }, + { + "fullUrl": "urn:uuid:35353f20-6254-e794-98ed-8007490447e3", + "resource": { + "resourceType": "Location", + "id": "35353f20-6254-e794-98ed-8007490447e3", + "partOf": { + "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" + }, + "name": "Bed-103", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/35353f20-6254-e794-98ed-8007490447e3" + } + }, + { + "fullUrl": "urn:uuid:055e10f1-222e-df73-2325-0e4396db1a55", + "resource": { + "resourceType": "Location", + "id": "055e10f1-222e-df73-2325-0e4396db1a55", + "name": "Greenland", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/055e10f1-222e-df73-2325-0e4396db1a55" + } + }, + { + "fullUrl": "urn:uuid:1154e6b2-b022-b3be-7dce-2b940ab5376d", + "resource": { + "resourceType": "Location", + "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", + "name": "Nursing home", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + } + }, + { + "fullUrl": "urn:uuid:08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "resource": { + "resourceType": "Location", + "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "name": "Rosewood", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" + } + }, + { + "fullUrl": "urn:uuid:c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "resource": { + "resourceType": "Location", + "id": "c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "name": "ROOM1", + "identifier": [ + { + "value": "urn:oid:2.16.840.1.113883.4.642.1.1108", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + } + }, + { + "fullUrl": "urn:uuid:6f159848-5f01-01b3-9594-80fbbe9ab510", + "resource": { + "resourceType": "Location", + "id": "6f159848-5f01-01b3-9594-80fbbe9ab510", + "partOf": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "name": "BED1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" + } + }, + { + "fullUrl": "urn:uuid:4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "resource": { + "resourceType": "Location", + "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "name": "FACILITY1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + } + }, + { + "fullUrl": "urn:uuid:3b0911cb-4361-cd8d-b188-463af033c699", + "resource": { + "resourceType": "Location", + "id": "3b0911cb-4361-cd8d-b188-463af033c699", + "partOf": { + "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + }, + "name": "BUILDING1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:08314073-410a-3dc7-512c-0f2d206fb59d", + "resource": { + "resourceType": "Organization", + "id": "08314073-410a-3dc7-512c-0f2d206fb59d", + "identifier": [ + { + "value": "Etest", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-Etest" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + }, + { + "fullUrl": "urn:uuid:919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "resource": { + "resourceType": "EpisodeOfCare", + "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "status": "cancelled", + "identifier": [ + { + "value": "EOC124", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + }, + { + "fullUrl": "urn:uuid:4b192760-03d2-aec4-b0a6-fde323912e1e", + "resource": { + "resourceType": "Encounter", + "id": "4b192760-03d2-aec4-b0a6-fde323912e1e", + "class": { + "code": "PRENC", + "display": "pre-admission", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "cancelled", + "location": [ + { + "location": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "location": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "location": { + "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "location": { + "reference": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": true + } + ] + }, + { + "location": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + } + ], + "type": [ + { + "coding": [ + { + "code": "E", + "display": "Emergency", + "system": "http://terminology.hl7.org/CodeSystem/v2-0007" + } + ] + } + ], + "hospitalization": { + "preAdmissionIdentifier": { + "value": "1234567", + "type": { + "coding": [ + { + "code": "ANON", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Anonymous identifier" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + "reAdmission": { + "coding": [ + { + "code": "R", + "display": "Re-admission", + "system": "http://terminology.hl7.org/CodeSystem/v2-0092" + } + ] + }, + "admitSource": { + "coding": [ + { + "code": "NHS Provider-General (inc.A&E-this Hosp)" + } + ] + }, + "dischargeDisposition": { + "coding": [ + { + "code": "Admitted as Inpatient", + "display": "Sample", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ACR" + } + ] + }, + "dietPreference": [ + { + "coding": [ + { + "code": "Vegan", + "display": "Vegetarian" + } + ] + } + ], + "destination": { + "reference": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + "episodeOfCare": [ + { + "reference": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "CON", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "consultant" + } + ], + "individual": { + "reference": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "ADM", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "admitter" + } + ], + "individual": { + "reference": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "PART", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "Participation" + } + ], + "individual": { + "reference": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + } + ], + "serviceType": { + "coding": [ + { + "code": "SUR" + } + ] + }, + "identifier": [ + { + "value": "40007716", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + }, + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + }, + { + "value": "50", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "urn:oid:r2.3", + "assigner": { + "reference": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + } + ], + "period": { + "start": "2015-02-08T15:54:19+05:30", + "end": "2015-02-09T15:54:19+05:30" + }, + "reasonCode": [ + { + "coding": [ + { + "code": "140004", + "display": "Chronic pharyngitis", + "system": "http://snomed.info/sct" + } + ] + } + ], + "length": { + "value": 2, + "unit": "d", + "system": "http://unitsofmeasure.org/" + }, + "meta": { + "security": [ + { + "code": "N", + "display": "normal", + "system": "http://terminology.hl7.org/CodeSystem/v3-Confidentiality" + } + ] + }, + "text": { + "status": "generated", + "div": "

Visit Description: Health Checkup

" + }, + "priority": { + "coding": [ + { + "code": "UR", + "display": "urgent", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.2" + }, + { + "code": "EL", + "display": "elective", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.3" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/encounter-modeOfArrival", + "valueCoding": { + "code": "C", + "display": "Car", + "system": "http://terminology.hl7.org/CodeSystem/v2-0430" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Encounter/4b192760-03d2-aec4-b0a6-fde323912e1e" + } + }, + { + "fullUrl": "urn:uuid:9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "resource": { + "resourceType": "Provenance", + "id": "9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "occurredDateTime": "2021-08-17T18:49:43.004+05:30", + "recorded": "2029-08-01T11:21:24+05:30", + "reason": [ + { + "coding": [ + { + "code": "PATRQT", + "display": "patient requested", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActReason" + } + ] + } + ], + "agent": [ + { + "who": { + "reference": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + } + ], + "activity": { + "text": "ADT^A27^ADT_A27" + }, + "location": { + "reference": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + }, + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c" + } + }, + { + "fullUrl": "urn:uuid:ef39f581-5e8f-3917-35a9-3443303d9eee", + "resource": { + "resourceType": "Organization", + "id": "ef39f581-5e8f-3917-35a9-3443303d9eee", + "identifier": [ + { + "value": "DRNBR", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-DRNBR" + }, + { + "value": "urn:oid:W1.2", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + } + }, + { + "fullUrl": "urn:uuid:95aea53b-8d49-d57f-d16f-4d14b914f992", + "resource": { + "resourceType": "Practitioner", + "id": "95aea53b-8d49-d57f-d16f-4d14b914f992", + "identifier": [ + { + "value": "C08", + "system": "urn:oid:W1.2", + "assigner": { + "reference": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + }, + "type": { + "coding": [ + { + "code": "ANON", + "display": "Anonymous identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen", + "2ndname" + ], + "suffix": [ + "Jr", + "MD" + ], + "prefix": [ + "Dr" + ], + "use": "official" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + }, + { + "fullUrl": "urn:uuid:59d5e519-0108-5dd8-adfa-1eef5658009e", + "resource": { + "resourceType": "Location", + "id": "59d5e519-0108-5dd8-adfa-1eef5658009e", + "name": "Cona_Health", + "identifier": [ + { + "value": "urn:oid:1.3.6.1.4.1.44750.1.4", + "system": "urn:ietf:rfc:3986" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "display": "site", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A28/ADT-A28-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A28/ADT-A28-01-expected.json similarity index 95% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A28/ADT-A28-expected.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A28/ADT-A28-01-expected.json index a6a18fd90..75d35d2c5 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A28/ADT-A28-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A28/ADT-A28-01-expected.json @@ -60,13 +60,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:33:25.099Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A28.

" + "div": "

Resource bundle generated on 2021-10-29T10:36:37.507Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A28.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -108,7 +108,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { @@ -1649,6 +1649,7 @@ } ], "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1673,6 +1674,7 @@ }, "name": "OMU B", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1697,6 +1699,7 @@ }, "name": "Bed 03", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1718,6 +1721,7 @@ "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", "name": "HOMERTON UNIVER", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1742,6 +1746,7 @@ }, "name": "Homerton UH", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1766,6 +1771,7 @@ }, "name": "Floor5", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1787,6 +1793,7 @@ "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", "name": "4 East, room 136, bed B 4E", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1811,6 +1818,7 @@ }, "name": "136", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1835,6 +1843,7 @@ }, "name": "B", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1856,6 +1865,7 @@ "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", "name": "CommunityHospital", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1903,6 +1913,7 @@ "id": "84634858-74aa-5cdb-4547-60ec27339ac6", "name": "POC", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1927,6 +1938,7 @@ }, "name": "Room-2", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1951,6 +1963,7 @@ }, "name": "Bed-103", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1972,6 +1985,7 @@ "id": "055e10f1-222e-df73-2325-0e4396db1a55", "name": "Greenland", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1993,6 +2007,7 @@ "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", "name": "Nursing home", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -2014,6 +2029,7 @@ "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", "name": "Rosewood", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -2041,6 +2057,7 @@ } ], "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2065,6 +2082,7 @@ }, "name": "BED1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2086,6 +2104,7 @@ "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", "name": "FACILITY1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2110,6 +2129,7 @@ }, "name": "BUILDING1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2134,6 +2154,7 @@ }, "name": "FLOOR1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2183,7 +2204,7 @@ "resource": { "resourceType": "EpisodeOfCare", "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", - "status": "planned", + "status": "finished", "identifier": [ { "value": "EOC124", @@ -2238,7 +2259,7 @@ "display": "pre-admission", "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" }, - "status": "planned", + "status": "finished", "location": [ { "status": "planned", @@ -2246,36 +2267,6 @@ "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, { "status": "completed", "location": { @@ -2288,42 +2279,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "planned", "location": { @@ -2336,42 +2291,6 @@ } ] }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "completed", "location": { @@ -2384,18 +2303,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true - } - ] - }, { "status": "planned", "location": { @@ -2407,54 +2314,6 @@ "valueBoolean": false } ] - }, - { - "status": "planned", - "location": { - "reference": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] } ], "type": [ @@ -2673,7 +2532,8 @@ } ], "period": { - "start": "2015-02-08T15:54:19+05:30" + "start": "2015-02-08T15:54:19+05:30", + "end": "2015-02-09T15:54:19+05:30" }, "reasonCode": [ { @@ -3018,6 +2878,7 @@ "id": "a9c75502-d60a-d89b-5912-f046100cd47e", "name": "OT", "mode": "instance", + "description": "OT--201", "physicalType": { "coding": [ { @@ -3032,6 +2893,31 @@ "url": "Location/a9c75502-d60a-d89b-5912-f046100cd47e" } }, + { + "fullUrl": "urn:uuid:55f70355-863d-579a-b4aa-81fcaf3e1fb0", + "resource": { + "resourceType": "Location", + "id": "55f70355-863d-579a-b4aa-81fcaf3e1fb0", + "partOf": { + "reference": "Location/a9c75502-d60a-d89b-5912-f046100cd47e" + }, + "name": "201", + "mode": "instance", + "description": "OT--201", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/55f70355-863d-579a-b4aa-81fcaf3e1fb0" + } + }, { "fullUrl": "urn:uuid:2e2e33a1-60f8-7e38-c827-fe070237c3fb", "resource": { @@ -3987,6 +3873,9 @@ ] } ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, "extension": [ { "url": "http://example.com/v2-to-fhir-converter/Observation_Status", @@ -4356,19 +4245,6 @@ }, "system": "http://www.examplehealthplan.com/fhir/policyidentifier" }, - { - "value": "HMO-12345", - "type": { - "coding": [ - { - "code": "NI", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203", - "display": "National unique individual identifier" - } - ] - }, - "system": "urn:oid:2.16.840.1.113883.1.3" - }, { "value": "Medicare-12345", "type": { diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A03/ADT-A03-expected-2.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A28/ADT-A28-02-expected.json similarity index 93% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A03/ADT-A03-expected-2.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A28/ADT-A28-02-expected.json index c71493f8e..d2bdb8001 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A03/ADT-A03-expected-2.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A28/ADT-A28-02-expected.json @@ -40,9 +40,9 @@ ] }, "eventCoding": { - "code": "A03", + "code": "A28", "system": "http://terminology.hl7.org/CodeSystem/v2-0003", - "display": "ADT^A03^ADT_A03" + "display": "ADT^A28^ADT_A28" }, "language": "en-US", "sender": { @@ -58,13 +58,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T12:46:08.88Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A03.

" + "div": "

Resource bundle generated on 2021-10-29T10:37:09.88Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A28.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -86,7 +86,7 @@ "activity": { "coding": [ { - "display": "ADT^A03^ADT_A03" + "display": "ADT^A28^ADT_A28" } ] }, @@ -106,7 +106,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { @@ -1155,6 +1155,7 @@ } ], "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1179,6 +1180,7 @@ }, "name": "OMU B", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1203,6 +1205,7 @@ }, "name": "Bed 03", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1224,6 +1227,7 @@ "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", "name": "HOMERTON UNIVER", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1248,6 +1252,7 @@ }, "name": "Homerton UH", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1272,6 +1277,7 @@ }, "name": "Floor5", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1293,6 +1299,7 @@ "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", "name": "4 East, room 136, bed B 4E", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1317,6 +1324,7 @@ }, "name": "136", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1341,6 +1349,7 @@ }, "name": "B", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1362,6 +1371,7 @@ "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", "name": "CommunityHospital", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1409,6 +1419,7 @@ "id": "84634858-74aa-5cdb-4547-60ec27339ac6", "name": "POC", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1433,6 +1444,7 @@ }, "name": "Room-2", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1457,6 +1469,7 @@ }, "name": "Bed-103", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1478,6 +1491,7 @@ "id": "055e10f1-222e-df73-2325-0e4396db1a55", "name": "Greenland", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1499,6 +1513,7 @@ "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", "name": "Nursing home", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1520,6 +1535,7 @@ "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", "name": "Rosewood", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1615,36 +1631,6 @@ "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, { "status": "completed", "location": { @@ -1657,42 +1643,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "planned", "location": { @@ -1705,42 +1655,6 @@ } ] }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "completed", "location": { @@ -1752,18 +1666,6 @@ "valueBoolean": true } ] - }, - { - "status": "completed", - "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true - } - ] } ], "type": [ @@ -2007,7 +1909,7 @@ } ], "activity": { - "text": "ADT^A03^ADT_A03" + "text": "ADT^A28^ADT_A28" }, "location": { "reference": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A28/ADT-A28-expected-2.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A28/ADT-A28-expected-2.json deleted file mode 100644 index e671dfd68..000000000 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A28/ADT-A28-expected-2.json +++ /dev/null @@ -1,2130 +0,0 @@ -{ - "resourceType": "Bundle", - "type": "batch", - "timestamp": "1989-08-18T14:41:00+05:30", - "identifier": { - "value": "MSG00001" - }, - "id": "513a3d06-5e87-6fbc-ad1b-170ab430499f", - "entry": [ - { - "fullUrl": "urn:uuid:b4ca189b-51ae-33df-cbe2-559b4423a321", - "resource": { - "resourceType": "MessageHeader", - "id": "b4ca189b-51ae-33df-cbe2-559b4423a321", - "source": { - "name": "24GHH", - "endpoint": "urn:oid:2.16.840.1.114884.10.20" - }, - "destination": [ - { - "name": "25GHH", - "endpoint": "urn:oid:2.16.840.1.114884.10.23", - "receiver": { - "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" - } - } - ], - "meta": { - "security": [ - { - "display": "SECURITY", - "system": "http://example.com/v2-to-fhirconverter/security-label" - } - ], - "tag": [ - { - "code": "P", - "system": "http://terminology.hl7.org/CodeSystem/v2-0103" - } - ] - }, - "eventCoding": { - "code": "A28", - "system": "http://terminology.hl7.org/CodeSystem/v2-0003", - "display": "ADT^A28^ADT_A28" - }, - "language": "en-US", - "sender": { - "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" - }, - "responsible": { - "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" - } - }, - "request": { - "method": "PUT", - "url": "MessageHeader/b4ca189b-51ae-33df-cbe2-559b4423a321" - } - }, - { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", - "resource": { - "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", - "text": { - "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:32:14.385Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A28.

" - }, - "occurredDateTime": "1989-08-18T14:41:00+05:30", - "recorded": "1989-08-18T14:41:00+05:30", - "agent": [ - { - "type": { - "coding": [ - { - "code": "author", - "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" - } - ] - }, - "who": { - "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" - } - } - ], - "activity": { - "coding": [ - { - "display": "ADT^A28^ADT_A28" - } - ] - }, - "entity": [ - { - "role": "source", - "what": { - "reference": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" - } - } - ], - "target": [ - { - "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" - } - ] - }, - "request": { - "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" - } - }, - { - "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", - "resource": { - "resourceType": "Organization", - "id": "4356fb81-6ecd-2d70-57b1-47812638e785", - "identifier": [ - { - "value": "GHHSFacility", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" - }, - { - "value": "urn:oid:2.16.840.1.122848.1.30", - "system": "urn:ietf:rfc:3986", - "type": { - "coding": [ - { - "code": "ISO", - "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", - "system": "http://terminology.hl7.org/CodeSystem/v2-0301" - } - ] - } - } - ], - "partOf": { - "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" - }, - "address": [ - { - "country": "USA" - } - ] - }, - "request": { - "method": "PUT", - "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" - } - }, - { - "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", - "resource": { - "resourceType": "Organization", - "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", - "identifier": [ - { - "value": "GHHRFacility", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" - }, - { - "value": "urn:oid:2.16.840.1.1122848.1.32", - "system": "urn:ietf:rfc:3986", - "type": { - "coding": [ - { - "code": "ISO", - "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", - "system": "http://terminology.hl7.org/CodeSystem/v2-0301" - } - ] - } - } - ], - "partOf": { - "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" - }, - "address": [ - { - "country": "USA" - } - ] - }, - "request": { - "method": "PUT", - "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" - } - }, - { - "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", - "resource": { - "resourceType": "Organization", - "id": "33532a82-d220-4c0d-1abe-53e48951c201", - "name": "22 GHH Inc." - }, - "request": { - "method": "PUT", - "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" - } - }, - { - "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", - "resource": { - "resourceType": "Organization", - "id": "527280c1-34d1-c639-e9ba-61986d28e266", - "name": "23 GHH Inc." - }, - "request": { - "method": "PUT", - "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" - } - }, - { - "fullUrl": "urn:uuid:503eb873-22fb-8199-ae28-3604ad59fe13", - "resource": { - "resourceType": "Device", - "id": "503eb873-22fb-8199-ae28-3604ad59fe13", - "identifier": [ - { - "value": "ADTApp" - } - ] - }, - "request": { - "method": "PUT", - "url": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" - } - }, - { - "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", - "resource": { - "resourceType": "Patient", - "id": "9e909e52-61a1-be50-1878-a12ef8c36346", - "identifier": [ - { - "value": "1234567", - "type": { - "coding": [ - { - "code": "MR", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203", - "display": "Medical record number" - } - ] - }, - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", - "period": { - "start": "1924-10-11", - "end": "1924-10-12" - } - }, - { - "value": "PATID1234", - "type": { - "coding": [ - { - "code": "MR", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203", - "display": "Medical record number" - } - ] - }, - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", - "assigner": { - "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" - } - }, - { - "value": "123456789", - "type": { - "coding": [ - { - "code": "SS", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203", - "display": "Social Security number" - } - ] - }, - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" - }, - { - "value": "PATID567", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" - }, - { - "value": "PSSN123121234", - "type": { - "coding": [ - { - "code": "SB", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203" - } - ] - }, - "system": "http://hl7.org/fhir/sid/us-ssn" - }, - { - "value": "DLN-123", - "type": { - "coding": [ - { - "code": "DL" - } - ] - }, - "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", - "period": { - "end": "2001-01-23" - } - } - ], - "name": [ - { - "family": "EVERYMAN", - "given": [ - "ADAM", - "A", - "Addsm" - ], - "suffix": [ - "III", - "MD", - "PF" - ], - "prefix": [ - "Dr." - ], - "use": "usual", - "period": { - "start": "1924-10-12" - } - }, - { - "family": "Josh", - "given": [ - "stanley" - ], - "use": "official", - "period": { - "start": "1924-10-10", - "end": "1924-10-15" - } - }, - { - "family": "elbert", - "given": [ - "Son" - ] - } - ], - "birthDate": "1988-08-18", - "_birthDate": { - "extension": [ - { - "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", - "valueDateTime": "1988-08-18T14:41:00+05:30" - } - ] - }, - "gender": "male", - "address": [ - { - "line": [ - "1000", - "Hospital Lane", - "Ste. 123", - "Near Highway" - ], - "city": "Ann Arbor ", - "state": "MI", - "postalCode": "99999", - "country": "USA", - "type": "postal", - "district": "W", - "period": { - "start": "2000-01-10", - "end": "2000-01-20" - } - } - ], - "telecom": [ - { - "value": "2222", - "system": "phone", - "period": { - "start": "2001-01-10", - "end": "2002-01-10" - }, - "rank": 18, - "use": "home" - }, - { - "value": "12121212", - "system": "phone", - "use": "home" - }, - { - "value": "7777", - "system": "phone", - "use": "work" - }, - { - "value": "1111", - "system": "other", - "use": "work" - }, - { - "value": "89898989", - "use": "work", - "system": "email" - } - ], - "communication": [ - { - "language": { - "coding": [ - { - "code": "ar", - "display": "Arabic", - "system": "urn:ietf:bcp:47", - "version": "v2" - }, - { - "code": "en", - "display": "English", - "system": "urn:ietf:bcp:47", - "version": "v2.1" - } - ], - "text": "TextInEnglish" - }, - "preferred": true - } - ], - "maritalStatus": { - "coding": [ - { - "code": "M", - "display": "Married", - "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" - } - ] - }, - "multipleBirthInteger": 2, - "deceasedDateTime": "2008-08-25T15:31:30+05:30", - "meta": { - "lastUpdated": "2005-01-10T04:05:14+05:30" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", - "extension": [ - { - "url": "ombCategory", - "valueCoding": { - "code": "2106-3", - "display": "White", - "system": "urn:oid:2.16.840.1.113883.6.238" - } - }, - { - "url": "ombCategory", - "valueCoding": { - "code": "2028-9", - "display": "Asian", - "system": "urn:oid:2.16.840.1.113883.6.238" - } - }, - { - "url": "text", - "valueString": "White+Asian" - } - ] - }, - { - "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", - "valueString": "SMITH--Angela--L" - }, - { - "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", - "valueAddress": { - "text": "St. Francis Community Hospital of Lower South Side" - } - }, - { - "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", - "valueCodeableConcept": { - "coding": [ - { - "code": "1002", - "display": "African Religions", - "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" - } - ] - } - }, - { - "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", - "extension": [ - { - "url": "ombCategory", - "valueCoding": { - "code": "2186-5", - "display": "Non Hispanic or Latino", - "system": "urn:oid:2.16.840.1.113883.6.238" - } - }, - { - "url": "text", - "valueString": "Non Hispanic or Latino" - } - ] - }, - { - "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/VeteranMilitaryStatus", - "valueCodeableConcept": { - "coding": [ - { - "code": "Vet123", - "display": "retired", - "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ART" - } - ], - "text": "retired" - } - }, - { - "url": "http://hl7.org/fhir/StructureDefinition/patient-animal", - "extension": [ - { - "url": "species", - "valueCodeableConcept": { - "coding": [ - { - "code": "125097000", - "display": "Goat", - "system": "http://snomed.info/sct" - } - ], - "text": "Goat" - } - }, - { - "url": "breed", - "valueCodeableConcept": { - "coding": [ - { - "code": "4880003", - "display": "Beagle", - "system": "http://snomed.info/sct" - } - ], - "text": "Beagle" - } - } - ] - }, - { - "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", - "extension": [ - { - "url": "code", - "valueCodeableConcept": { - "coding": [ - { - "code": "US", - "display": "United States of America", - "system": "urn:iso:std:iso:3166" - } - ], - "text": "United States of America" - } - } - ] - }, - { - "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", - "extension": [ - { - "url": "code", - "valueCodeableConcept": { - "coding": [ - { - "code": "CA", - "display": "Canada", - "system": "urn:iso:std:iso:3166" - } - ], - "text": "Canada" - } - } - ] - }, - { - "url": "http://hl7.org/fhir/StructureDefinition/patient-nationality", - "extension": [ - { - "url": "code", - "valueCodeableConcept": { - "coding": [ - { - "code": "BT", - "display": "Bhutan", - "system": "urn:iso:std:iso:3166" - } - ], - "text": "Bhutan" - } - } - ] - }, - { - "url": "http://hl7.org/fhir/StructureDefinition/patient-importance", - "valueCodeableConcept": { - "coding": [ - { - "code": "VIP", - "display": "Very Important Person", - "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L", - "version": "v1.1" - }, - { - "code": "IMP", - "system": "http://example.com/v2-to-fhir-converter/CodeSystem/DCM", - "version": "v1.2" - } - ], - "text": "Inportant Person" - } - } - ] - }, - "request": { - "method": "PUT", - "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" - } - }, - { - "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", - "resource": { - "resourceType": "Account", - "id": "78295402-9b84-4829-b945-502ab3402de5", - "identifier": [ - { - "value": "4000776", - "type": { - "coding": [ - { - "code": "VN", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203", - "display": "Visit number" - } - ] - }, - "system": "urn:oid:2.4", - "assigner": { - "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" - }, - "period": { - "start": "1924-10-11", - "end": "1924-10-12" - } - } - ], - "status": "active", - "subject": [ - { - "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" - } - ] - }, - "request": { - "method": "PUT", - "url": "Account/78295402-9b84-4829-b945-502ab3402de5" - } - }, - { - "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", - "resource": { - "resourceType": "Organization", - "id": "9d4c8327-8a28-8152-1898-8251baa707b7", - "identifier": [ - { - "value": "AccMgr", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" - }, - { - "value": "urn:oid:2.4", - "system": "urn:ietf:rfc:3986", - "type": { - "coding": [ - { - "code": "ISO", - "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", - "system": "http://terminology.hl7.org/CodeSystem/v2-0301" - } - ] - } - } - ] - }, - "request": { - "method": "PUT", - "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" - } - }, - { - "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", - "resource": { - "resourceType": "Organization", - "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", - "identifier": [ - { - "value": "test1", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" - }, - { - "value": "2.16.1", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", - "type": { - "coding": [ - { - "code": "HCD", - "display": "The CEN Healthcare Coding Scheme Designator", - "system": "http://terminology.hl7.org/CodeSystem/v2-0301" - } - ] - } - } - ] - }, - "request": { - "method": "PUT", - "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" - } - }, - { - "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", - "resource": { - "resourceType": "Organization", - "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", - "identifier": [ - { - "value": "NTH", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" - }, - { - "value": "rt23", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", - "type": { - "coding": [ - { - "code": "HCD", - "display": "The CEN Healthcare Coding Scheme Designator", - "system": "http://terminology.hl7.org/CodeSystem/v2-0301" - } - ] - } - } - ] - }, - "request": { - "method": "PUT", - "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" - } - }, - { - "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", - "resource": { - "resourceType": "RelatedPerson", - "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", - "identifier": [ - { - "value": "1212121", - "type": { - "coding": [ - { - "code": "AND", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203", - "display": "Account number debitor" - } - ] - }, - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", - "assigner": { - "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" - }, - "period": { - "start": "1924-10-11", - "end": "1924-10-12" - } - } - ], - "relationship": [ - { - "coding": [ - { - "code": "MTH", - "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" - } - ] - } - ], - "patient": { - "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" - } - }, - "request": { - "method": "PUT", - "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" - } - }, - { - "fullUrl": "urn:uuid:11967e28-8dd4-a112-0fdc-377866bf12a0", - "resource": { - "resourceType": "Organization", - "id": "11967e28-8dd4-a112-0fdc-377866bf12a0", - "identifier": [ - { - "value": "t", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-t" - }, - { - "value": "2.16.840.1.113883.19", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", - "type": { - "coding": [ - { - "code": "HCD", - "display": "The CEN Healthcare Coding Scheme Designator", - "system": "http://terminology.hl7.org/CodeSystem/v2-0301" - } - ] - } - } - ] - }, - "request": { - "method": "PUT", - "url": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" - } - }, - { - "fullUrl": "urn:uuid:7452d91f-ae92-d8ce-5b4a-148be5b6538e", - "resource": { - "resourceType": "Organization", - "id": "7452d91f-ae92-d8ce-5b4a-148be5b6538e", - "identifier": [ - { - "value": "AccMng", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMng" - }, - { - "value": "1.2", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", - "type": { - "coding": [ - { - "code": "HCD", - "display": "The CEN Healthcare Coding Scheme Designator", - "system": "http://terminology.hl7.org/CodeSystem/v2-0301" - } - ] - } - } - ] - }, - "request": { - "method": "PUT", - "url": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" - } - }, - { - "fullUrl": "urn:uuid:0ccb76ca-b97e-1c86-4617-912a6d65c1f9", - "resource": { - "resourceType": "Organization", - "id": "0ccb76ca-b97e-1c86-4617-912a6d65c1f9", - "identifier": [ - { - "value": "PERSONNELt", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSONNELt" - }, - { - "value": "1.23", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", - "type": { - "coding": [ - { - "code": "HCD", - "display": "The CEN Healthcare Coding Scheme Designator", - "system": "http://terminology.hl7.org/CodeSystem/v2-0301" - } - ] - } - } - ] - }, - "request": { - "method": "PUT", - "url": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" - } - }, - { - "fullUrl": "urn:uuid:f6775f99-5279-be04-bf81-0906c81f7443", - "resource": { - "resourceType": "Practitioner", - "id": "f6775f99-5279-be04-bf81-0906c81f7443", - "identifier": [ - { - "value": "1122334", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", - "assigner": { - "reference": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" - }, - "type": { - "coding": [ - { - "code": "BR", - "display": "Birth registry number", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203" - } - ] - } - } - ], - "name": [ - { - "family": "Alaz", - "given": [ - "Mohammed", - "Mahi" - ], - "suffix": [ - "JR", - "MD", - "Al" - ], - "prefix": [ - "Dr." - ], - "period": { - "start": "1924-10-10", - "end": "1924-10-15" - } - } - ] - }, - "request": { - "method": "PUT", - "url": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" - } - }, - { - "fullUrl": "urn:uuid:c613d7b2-525f-8c08-a7ac-b2b91486e257", - "resource": { - "resourceType": "Organization", - "id": "c613d7b2-525f-8c08-a7ac-b2b91486e257", - "identifier": [ - { - "value": "TEST", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TEST" - }, - { - "value": "23.2", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", - "type": { - "coding": [ - { - "code": "HCD", - "display": "The CEN Healthcare Coding Scheme Designator", - "system": "http://terminology.hl7.org/CodeSystem/v2-0301" - } - ] - } - } - ] - }, - "request": { - "method": "PUT", - "url": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" - } - }, - { - "fullUrl": "urn:uuid:04f8cfc8-62ca-12df-63ce-6304ef577d44", - "resource": { - "resourceType": "Practitioner", - "id": "04f8cfc8-62ca-12df-63ce-6304ef577d44", - "identifier": [ - { - "value": "C006", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", - "assigner": { - "reference": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" - }, - "type": { - "coding": [ - { - "code": "BA", - "display": "Bank Account Number", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203" - } - ] - } - } - ], - "name": [ - { - "family": "Woolfson", - "given": [ - "Kathleen" - ], - "prefix": [ - "Dr" - ], - "use": "anonymous" - } - ] - }, - "request": { - "method": "PUT", - "url": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" - } - }, - { - "fullUrl": "urn:uuid:99edcabd-fbeb-7e25-f823-11da8d8ed342", - "resource": { - "resourceType": "Practitioner", - "id": "99edcabd-fbeb-7e25-f823-11da8d8ed342", - "identifier": [ - { - "value": "C008", - "system": "urn:oid:2.8", - "type": { - "coding": [ - { - "code": "BR", - "display": "Birth registry number", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203" - } - ] - } - } - ], - "name": [ - { - "family": "Condoc", - "given": [ - "leen" - ], - "prefix": [ - "Dr" - ], - "use": "temp" - } - ] - }, - "request": { - "method": "PUT", - "url": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" - } - }, - { - "fullUrl": "urn:uuid:b065b233-8738-f1ec-1314-d61e4aac2c9e", - "resource": { - "resourceType": "Practitioner", - "id": "b065b233-8738-f1ec-1314-d61e4aac2c9e", - "identifier": [ - { - "value": "37", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr", - "type": { - "coding": [ - { - "code": "ANC", - "display": "Account number Creditor", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203" - } - ] - } - } - ], - "name": [ - { - "family": "DISNEY", - "given": [ - "WALT" - ] - } - ] - }, - "request": { - "method": "PUT", - "url": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" - } - }, - { - "fullUrl": "urn:uuid:9f974d4f-47e8-21a6-e549-4de4599c3764", - "resource": { - "resourceType": "Organization", - "id": "9f974d4f-47e8-21a6-e549-4de4599c3764", - "identifier": [ - { - "value": "T123", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-T123" - }, - { - "value": "urn:oid:r2.3", - "system": "urn:ietf:rfc:3986", - "type": { - "coding": [ - { - "code": "ISO", - "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", - "system": "http://terminology.hl7.org/CodeSystem/v2-0301" - } - ] - } - } - ] - }, - "request": { - "method": "PUT", - "url": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" - } - }, - { - "fullUrl": "urn:uuid:84aa3f43-eefe-c16a-90e0-8ebf2306a77d", - "resource": { - "resourceType": "Practitioner", - "id": "84aa3f43-eefe-c16a-90e0-8ebf2306a77d", - "identifier": [ - { - "value": "Othhel", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD" - } - ] - }, - "request": { - "method": "PUT", - "url": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" - } - }, - { - "fullUrl": "urn:uuid:9172e4a0-1ca5-646d-2183-b179f4daa737", - "resource": { - "resourceType": "Location", - "id": "9172e4a0-1ca5-646d-2183-b179f4daa737", - "partOf": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - }, - "name": "HUH AE OMU", - "identifier": [ - { - "value": "urn:oid:9.8", - "system": "urn:ietf:rfc:3986" - } - ], - "mode": "instance", - "physicalType": { - "coding": [ - { - "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", - "code": "lvl" - } - ] - } - }, - "request": { - "method": "PUT", - "url": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" - } - }, - { - "fullUrl": "urn:uuid:3913ec4d-6576-5e1a-ac31-e8280583371c", - "resource": { - "resourceType": "Location", - "id": "3913ec4d-6576-5e1a-ac31-e8280583371c", - "partOf": { - "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" - }, - "name": "OMU B", - "mode": "instance", - "physicalType": { - "coding": [ - { - "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", - "code": "ro" - } - ] - } - }, - "request": { - "method": "PUT", - "url": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "fullUrl": "urn:uuid:804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", - "resource": { - "resourceType": "Location", - "id": "804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", - "partOf": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - }, - "name": "Bed 03", - "mode": "instance", - "physicalType": { - "coding": [ - { - "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", - "code": "bd" - } - ] - } - }, - "request": { - "method": "PUT", - "url": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "fullUrl": "urn:uuid:c043880b-0fab-1cb8-14f7-0475282c4d0e", - "resource": { - "resourceType": "Location", - "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", - "name": "HOMERTON UNIVER", - "mode": "instance", - "physicalType": { - "coding": [ - { - "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", - "code": "si" - } - ] - } - }, - "request": { - "method": "PUT", - "url": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "fullUrl": "urn:uuid:f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", - "resource": { - "resourceType": "Location", - "id": "f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", - "partOf": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - }, - "name": "Homerton UH", - "mode": "instance", - "physicalType": { - "coding": [ - { - "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", - "code": "bu" - } - ] - } - }, - "request": { - "method": "PUT", - "url": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "fullUrl": "urn:uuid:7e38808c-44a8-cb0c-4709-9d6092abc32c", - "resource": { - "resourceType": "Location", - "id": "7e38808c-44a8-cb0c-4709-9d6092abc32c", - "partOf": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - }, - "name": "Floor5", - "mode": "instance", - "physicalType": { - "coding": [ - { - "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", - "code": "lvl" - } - ] - } - }, - "request": { - "method": "PUT", - "url": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, - { - "fullUrl": "urn:uuid:59de4aa7-44c6-860a-88ad-53ae51ef49e8", - "resource": { - "resourceType": "Location", - "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", - "name": "4 East, room 136, bed B 4E", - "mode": "instance", - "physicalType": { - "coding": [ - { - "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", - "code": "lvl" - } - ] - } - }, - "request": { - "method": "PUT", - "url": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" - } - }, - { - "fullUrl": "urn:uuid:d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", - "resource": { - "resourceType": "Location", - "id": "d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", - "partOf": { - "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" - }, - "name": "136", - "mode": "instance", - "physicalType": { - "coding": [ - { - "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", - "code": "ro" - } - ] - } - }, - "request": { - "method": "PUT", - "url": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - } - }, - { - "fullUrl": "urn:uuid:5783dafa-c6c0-e673-cca4-42087ee1831b", - "resource": { - "resourceType": "Location", - "id": "5783dafa-c6c0-e673-cca4-42087ee1831b", - "partOf": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "name": "B", - "mode": "instance", - "physicalType": { - "coding": [ - { - "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", - "code": "bd" - } - ] - } - }, - "request": { - "method": "PUT", - "url": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - } - }, - { - "fullUrl": "urn:uuid:8b39e6e5-78cd-63ab-2441-f43ca5554096", - "resource": { - "resourceType": "Location", - "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", - "name": "CommunityHospital", - "mode": "instance", - "physicalType": { - "coding": [ - { - "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", - "code": "si" - } - ] - } - }, - "request": { - "method": "PUT", - "url": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - } - }, - { - "fullUrl": "urn:uuid:42b81572-ebb4-3f14-7a91-e1f9a9c70460", - "resource": { - "resourceType": "Location", - "id": "42b81572-ebb4-3f14-7a91-e1f9a9c70460", - "name": "Homes", - "identifier": [ - { - "value": "22", - "system": "http://example.com/v2-to-fhir-converter/CodeSystem/FDK" - } - ], - "physicalType": { - "coding": [ - { - "code": "si", - "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" - } - ] - } - }, - "request": { - "method": "PUT", - "url": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" - } - }, - { - "fullUrl": "urn:uuid:84634858-74aa-5cdb-4547-60ec27339ac6", - "resource": { - "resourceType": "Location", - "id": "84634858-74aa-5cdb-4547-60ec27339ac6", - "name": "POC", - "mode": "instance", - "physicalType": { - "coding": [ - { - "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", - "code": "lvl" - } - ] - } - }, - "request": { - "method": "PUT", - "url": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" - } - }, - { - "fullUrl": "urn:uuid:9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", - "resource": { - "resourceType": "Location", - "id": "9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", - "partOf": { - "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" - }, - "name": "Room-2", - "mode": "instance", - "physicalType": { - "coding": [ - { - "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", - "code": "ro" - } - ] - } - }, - "request": { - "method": "PUT", - "url": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - } - }, - { - "fullUrl": "urn:uuid:35353f20-6254-e794-98ed-8007490447e3", - "resource": { - "resourceType": "Location", - "id": "35353f20-6254-e794-98ed-8007490447e3", - "partOf": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "name": "Bed-103", - "mode": "instance", - "physicalType": { - "coding": [ - { - "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", - "code": "bd" - } - ] - } - }, - "request": { - "method": "PUT", - "url": "Location/35353f20-6254-e794-98ed-8007490447e3" - } - }, - { - "fullUrl": "urn:uuid:055e10f1-222e-df73-2325-0e4396db1a55", - "resource": { - "resourceType": "Location", - "id": "055e10f1-222e-df73-2325-0e4396db1a55", - "name": "Greenland", - "mode": "instance", - "physicalType": { - "coding": [ - { - "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", - "code": "bu" - } - ] - } - }, - "request": { - "method": "PUT", - "url": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - } - }, - { - "fullUrl": "urn:uuid:1154e6b2-b022-b3be-7dce-2b940ab5376d", - "resource": { - "resourceType": "Location", - "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", - "name": "Nursing home", - "mode": "instance", - "physicalType": { - "coding": [ - { - "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", - "code": "lvl" - } - ] - } - }, - "request": { - "method": "PUT", - "url": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" - } - }, - { - "fullUrl": "urn:uuid:08b7f694-ec03-e35a-d0b0-2fae5940fe37", - "resource": { - "resourceType": "Location", - "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", - "name": "Rosewood", - "mode": "instance", - "physicalType": { - "coding": [ - { - "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", - "code": "bu" - } - ] - } - }, - "request": { - "method": "PUT", - "url": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" - } - }, - { - "fullUrl": "urn:uuid:08314073-410a-3dc7-512c-0f2d206fb59d", - "resource": { - "resourceType": "Organization", - "id": "08314073-410a-3dc7-512c-0f2d206fb59d", - "identifier": [ - { - "value": "Etest", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-Etest" - }, - { - "value": "2.16.1", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", - "type": { - "coding": [ - { - "code": "HCD", - "display": "The CEN Healthcare Coding Scheme Designator", - "system": "http://terminology.hl7.org/CodeSystem/v2-0301" - } - ] - } - } - ] - }, - "request": { - "method": "PUT", - "url": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" - } - }, - { - "fullUrl": "urn:uuid:919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", - "resource": { - "resourceType": "EpisodeOfCare", - "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", - "status": "planned", - "identifier": [ - { - "value": "EOC124", - "type": { - "coding": [ - { - "code": "MR", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203", - "display": "Medical record number" - } - ] - }, - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", - "assigner": { - "reference": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" - } - } - ], - "patient": { - "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" - } - }, - "request": { - "method": "PUT", - "url": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" - } - }, - { - "fullUrl": "urn:uuid:4b192760-03d2-aec4-b0a6-fde323912e1e", - "resource": { - "resourceType": "Encounter", - "id": "4b192760-03d2-aec4-b0a6-fde323912e1e", - "class": { - "code": "PRENC", - "display": "pre-admission", - "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" - }, - "status": "planned", - "location": [ - { - "status": "planned", - "location": { - "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, - { - "status": "completed", - "location": { - "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true - } - ] - } - ], - "type": [ - { - "coding": [ - { - "code": "E", - "display": "Emergency", - "system": "http://terminology.hl7.org/CodeSystem/v2-0007" - } - ] - } - ], - "hospitalization": { - "preAdmissionIdentifier": { - "value": "1234567", - "type": { - "coding": [ - { - "code": "ANON", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203", - "display": "Anonymous identifier" - } - ] - }, - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", - "assigner": { - "reference": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" - }, - "period": { - "start": "1924-10-11", - "end": "1924-10-12" - } - }, - "reAdmission": { - "coding": [ - { - "code": "R", - "display": "Re-admission", - "system": "http://terminology.hl7.org/CodeSystem/v2-0092" - } - ] - }, - "admitSource": { - "coding": [ - { - "code": "NHS Provider-General (inc.A&E-this Hosp)" - } - ] - }, - "dischargeDisposition": { - "coding": [ - { - "code": "Admitted as Inpatient", - "display": "Sample", - "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ACR" - } - ] - }, - "dietPreference": [ - { - "coding": [ - { - "code": "Vegan", - "display": "Vegetarian" - } - ] - } - ], - "destination": { - "reference": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" - } - }, - "episodeOfCare": [ - { - "reference": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" - } - ], - "participant": [ - { - "type": [ - { - "coding": [ - { - "code": "ATND", - "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", - "display": "attender" - } - ] - } - ], - "individual": { - "reference": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" - } - }, - { - "type": [ - { - "coding": [ - { - "code": "REF", - "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" - } - ], - "text": "referrer" - } - ], - "individual": { - "reference": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" - } - }, - { - "type": [ - { - "coding": [ - { - "code": "CON", - "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" - } - ], - "text": "consultant" - } - ], - "individual": { - "reference": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" - } - }, - { - "type": [ - { - "coding": [ - { - "code": "ADM", - "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" - } - ], - "text": "admitter" - } - ], - "individual": { - "reference": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" - } - }, - { - "type": [ - { - "coding": [ - { - "code": "PART", - "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" - } - ], - "text": "Participation" - } - ], - "individual": { - "reference": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" - } - } - ], - "serviceType": { - "coding": [ - { - "code": "SUR" - } - ] - }, - "identifier": [ - { - "value": "40007716", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", - "assigner": { - "reference": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" - }, - "type": { - "coding": [ - { - "code": "VN", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203" - } - ], - "text": "visit number" - } - }, - { - "value": "50", - "type": { - "coding": [ - { - "code": "MR", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203", - "display": "Medical record number" - } - ] - }, - "system": "urn:oid:r2.3", - "assigner": { - "reference": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" - } - } - ], - "period": { - "start": "2015-02-08T15:54:19+05:30" - }, - "text": { - "status": "generated", - "div": "

Visit Description:

" - }, - "subject": { - "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" - } - }, - "request": { - "method": "PUT", - "url": "Encounter/4b192760-03d2-aec4-b0a6-fde323912e1e" - } - }, - { - "fullUrl": "urn:uuid:9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", - "resource": { - "resourceType": "Provenance", - "id": "9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", - "occurredDateTime": "2021-08-17T18:49:43.004+05:30", - "recorded": "2029-08-01T11:21:24+05:30", - "reason": [ - { - "coding": [ - { - "code": "PATRQT", - "display": "patient requested", - "system": "http://terminology.hl7.org/CodeSystem/v3-ActReason" - } - ] - } - ], - "agent": [ - { - "who": { - "reference": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" - } - } - ], - "activity": { - "text": "ADT^A28^ADT_A28" - }, - "location": { - "reference": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" - }, - "target": [ - { - "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" - } - ] - }, - "request": { - "method": "PUT", - "url": "Provenance/9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c" - } - }, - { - "fullUrl": "urn:uuid:ef39f581-5e8f-3917-35a9-3443303d9eee", - "resource": { - "resourceType": "Organization", - "id": "ef39f581-5e8f-3917-35a9-3443303d9eee", - "identifier": [ - { - "value": "DRNBR", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-DRNBR" - }, - { - "value": "urn:oid:W1.2", - "system": "urn:ietf:rfc:3986", - "type": { - "coding": [ - { - "code": "ISO", - "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", - "system": "http://terminology.hl7.org/CodeSystem/v2-0301" - } - ] - } - } - ] - }, - "request": { - "method": "PUT", - "url": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" - } - }, - { - "fullUrl": "urn:uuid:95aea53b-8d49-d57f-d16f-4d14b914f992", - "resource": { - "resourceType": "Practitioner", - "id": "95aea53b-8d49-d57f-d16f-4d14b914f992", - "identifier": [ - { - "value": "C08", - "system": "urn:oid:W1.2", - "assigner": { - "reference": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" - }, - "type": { - "coding": [ - { - "code": "ANON", - "display": "Anonymous identifier", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203" - } - ] - } - } - ], - "name": [ - { - "family": "Woolfson", - "given": [ - "Kathleen", - "2ndname" - ], - "suffix": [ - "Jr", - "MD" - ], - "prefix": [ - "Dr" - ], - "use": "official" - } - ] - }, - "request": { - "method": "PUT", - "url": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" - } - }, - { - "fullUrl": "urn:uuid:59d5e519-0108-5dd8-adfa-1eef5658009e", - "resource": { - "resourceType": "Location", - "id": "59d5e519-0108-5dd8-adfa-1eef5658009e", - "name": "Cona_Health", - "identifier": [ - { - "value": "urn:oid:1.3.6.1.4.1.44750.1.4", - "system": "urn:ietf:rfc:3986" - } - ], - "physicalType": { - "coding": [ - { - "code": "si", - "display": "site", - "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" - } - ] - } - }, - "request": { - "method": "PUT", - "url": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" - } - } - ] -} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A29/ADT-A29-01-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A29/ADT-A29-01-expected.json new file mode 100644 index 000000000..afce2ef53 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A29/ADT-A29-01-expected.json @@ -0,0 +1,2890 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "1989-08-18T14:41:00+05:30", + "identifier": { + "value": "MSG00001" + }, + "id": "513a3d06-5e87-6fbc-ad1b-170ab430499f", + "entry": [ + { + "fullUrl": "urn:uuid:b4ca189b-51ae-33df-cbe2-559b4423a321", + "resource": { + "resourceType": "MessageHeader", + "id": "b4ca189b-51ae-33df-cbe2-559b4423a321", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20", + "version": "2.4.3.52854", + "software": "Rhapsody" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "A29", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "ADT^A29^ADT_A29" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "DELETE", + "url": "MessageHeader/b4ca189b-51ae-33df-cbe2-559b4423a321" + } + }, + { + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "resource": { + "resourceType": "Provenance", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T10:37:54.011Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A29.

" + }, + "occurredDateTime": "1989-08-18T14:41:00+05:30", + "recorded": "1989-08-18T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "ADT^A29^ADT_A29" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + } + ], + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "DELETE", + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "DELETE", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "DELETE", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "DELETE", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "DELETE", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:503eb873-22fb-8199-ae28-3604ad59fe13", + "resource": { + "resourceType": "Device", + "id": "503eb873-22fb-8199-ae28-3604ad59fe13", + "identifier": [ + { + "value": "ADTApp" + } + ] + }, + "request": { + "method": "DELETE", + "url": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" + } + }, + { + "fullUrl": "urn:uuid:4b549918-a84d-cdaf-e150-c773a5d306e5", + "resource": { + "resourceType": "Device", + "id": "4b549918-a84d-cdaf-e150-c773a5d306e5", + "manufacturer": "Orion", + "deviceName": [ + { + "name": "Rhapsody", + "type": "manufacturer-name" + } + ], + "version": [ + { + "value": "2.4.3.52854" + } + ], + "modelNumber": "2.4.3", + "note": [ + { + "text": "Testactivity" + } + ] + }, + "request": { + "method": "DELETE", + "url": "Device/4b549918-a84d-cdaf-e150-c773a5d306e5" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + }, + { + "value": "DB123", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "urn:oid:1.12", + "assigner": { + "reference": "Organization/4e68b44e-c053-02b1-6d6d-fe816f9fdfec" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "generalPractitioner": [ + { + "reference": "Organization/4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11" + }, + { + "reference": "Practitioner/76aaad38-1077-6a5c-0c5c-102ec160a60d" + } + ], + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/VeteranMilitaryStatus", + "valueCodeableConcept": { + "coding": [ + { + "code": "Vet123", + "display": "retired", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ART" + } + ], + "text": "retired" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-animal", + "extension": [ + { + "url": "species", + "valueCodeableConcept": { + "coding": [ + { + "code": "125097000", + "display": "Goat", + "system": "http://snomed.info/sct" + } + ], + "text": "Goat" + } + }, + { + "url": "breed", + "valueCodeableConcept": { + "coding": [ + { + "code": "4880003", + "display": "Beagle", + "system": "http://snomed.info/sct" + } + ], + "text": "Beagle" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-nationality", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "BT", + "display": "Bhutan", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Bhutan" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-congregation", + "valueString": "Methodist Church" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-importance", + "valueCodeableConcept": { + "coding": [ + { + "code": "VIP", + "display": "Very Important Person", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L", + "version": "v1.1" + }, + { + "code": "IMP", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/DCM", + "version": "v1.2" + } + ], + "text": "Inportant Person" + } + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/patient-disabilityIndicator", + "valueBoolean": true + }, + { + "url": "http://example.com/v2-to-fhir-converter/StructureDefinition/DisabilityPeriod", + "valuePeriod": { + "start": "2021-08-30", + "end": "2021-09-30" + } + } + ] + }, + "request": { + "method": "DELETE", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "DELETE", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "DELETE", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "DELETE", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "DELETE", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "DELETE", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11", + "resource": { + "resourceType": "Organization", + "id": "4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11", + "name": "LINDAS TEST ORGANIZATION", + "identifier": [ + { + "value": "SIISCLIENT818" + } + ] + }, + "request": { + "method": "DELETE", + "url": "Organization/4d8d5b11-b84d-f4a3-f55a-cedc2ab2bc11" + } + }, + { + "fullUrl": "urn:uuid:76aaad38-1077-6a5c-0c5c-102ec160a60d", + "resource": { + "resourceType": "Practitioner", + "id": "76aaad38-1077-6a5c-0c5c-102ec160a60d", + "identifier": [ + { + "value": "88", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TE", + "type": { + "coding": [ + { + "code": "DN", + "display": "Doctor number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Hippo", + "given": [ + "rold", + "H" + ], + "suffix": [ + "V", + "MD" + ], + "prefix": [ + "Dr" + ] + } + ] + }, + "request": { + "method": "DELETE", + "url": "Practitioner/76aaad38-1077-6a5c-0c5c-102ec160a60d" + } + }, + { + "fullUrl": "urn:uuid:11967e28-8dd4-a112-0fdc-377866bf12a0", + "resource": { + "resourceType": "Organization", + "id": "11967e28-8dd4-a112-0fdc-377866bf12a0", + "identifier": [ + { + "value": "t", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-t" + }, + { + "value": "2.16.840.1.113883.19", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "DELETE", + "url": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + } + }, + { + "fullUrl": "urn:uuid:7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "resource": { + "resourceType": "Organization", + "id": "7452d91f-ae92-d8ce-5b4a-148be5b6538e", + "identifier": [ + { + "value": "AccMng", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMng" + }, + { + "value": "1.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "DELETE", + "url": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + } + }, + { + "fullUrl": "urn:uuid:0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "resource": { + "resourceType": "Organization", + "id": "0ccb76ca-b97e-1c86-4617-912a6d65c1f9", + "identifier": [ + { + "value": "PERSONNELt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSONNELt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "DELETE", + "url": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + } + }, + { + "fullUrl": "urn:uuid:f6775f99-5279-be04-bf81-0906c81f7443", + "resource": { + "resourceType": "Practitioner", + "id": "f6775f99-5279-be04-bf81-0906c81f7443", + "identifier": [ + { + "value": "1122334", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Alaz", + "given": [ + "Mohammed", + "Mahi" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "DELETE", + "url": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "fullUrl": "urn:uuid:c613d7b2-525f-8c08-a7ac-b2b91486e257", + "resource": { + "resourceType": "Organization", + "id": "c613d7b2-525f-8c08-a7ac-b2b91486e257", + "identifier": [ + { + "value": "TEST", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TEST" + }, + { + "value": "23.2", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "DELETE", + "url": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + } + }, + { + "fullUrl": "urn:uuid:04f8cfc8-62ca-12df-63ce-6304ef577d44", + "resource": { + "resourceType": "Practitioner", + "id": "04f8cfc8-62ca-12df-63ce-6304ef577d44", + "identifier": [ + { + "value": "C006", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" + }, + "type": { + "coding": [ + { + "code": "BA", + "display": "Bank Account Number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen" + ], + "prefix": [ + "Dr" + ], + "use": "anonymous" + } + ] + }, + "request": { + "method": "DELETE", + "url": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "fullUrl": "urn:uuid:99edcabd-fbeb-7e25-f823-11da8d8ed342", + "resource": { + "resourceType": "Practitioner", + "id": "99edcabd-fbeb-7e25-f823-11da8d8ed342", + "identifier": [ + { + "value": "C008", + "system": "urn:oid:2.8", + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Condoc", + "given": [ + "leen" + ], + "prefix": [ + "Dr" + ], + "use": "temp" + } + ] + }, + "request": { + "method": "DELETE", + "url": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "fullUrl": "urn:uuid:b065b233-8738-f1ec-1314-d61e4aac2c9e", + "resource": { + "resourceType": "Practitioner", + "id": "b065b233-8738-f1ec-1314-d61e4aac2c9e", + "identifier": [ + { + "value": "37", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr", + "type": { + "coding": [ + { + "code": "ANC", + "display": "Account number Creditor", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "DISNEY", + "given": [ + "WALT" + ] + } + ] + }, + "request": { + "method": "DELETE", + "url": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "fullUrl": "urn:uuid:9f974d4f-47e8-21a6-e549-4de4599c3764", + "resource": { + "resourceType": "Organization", + "id": "9f974d4f-47e8-21a6-e549-4de4599c3764", + "identifier": [ + { + "value": "T123", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-T123" + }, + { + "value": "urn:oid:r2.3", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "DELETE", + "url": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + }, + { + "fullUrl": "urn:uuid:84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "resource": { + "resourceType": "Practitioner", + "id": "84aa3f43-eefe-c16a-90e0-8ebf2306a77d", + "identifier": [ + { + "value": "Othhel", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD" + } + ] + }, + "request": { + "method": "DELETE", + "url": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "fullUrl": "urn:uuid:24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "resource": { + "resourceType": "Organization", + "id": "24d4bddf-a1c3-4dc8-049b-1dda7e5112b6", + "identifier": [ + { + "value": "TE", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-TE" + }, + { + "value": "Provider Master.Community Health and Hospitals", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "type": { + "coding": [ + { + "code": "DNS", + "display": "An Internet host name, in accordance with RFC 1035; or an IP address. Either in ASCII or as integers, with periods between components (“dotted” notation).", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "DELETE", + "url": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + } + }, + { + "fullUrl": "urn:uuid:36e3aaa4-569a-7d9d-037f-27235ed05701", + "resource": { + "resourceType": "Practitioner", + "id": "36e3aaa4-569a-7d9d-037f-27235ed05701", + "identifier": [ + { + "value": "12188", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-DNS", + "assigner": { + "reference": "Organization/24d4bddf-a1c3-4dc8-049b-1dda7e5112b6" + }, + "type": { + "coding": [ + { + "code": "DN", + "display": "Doctor number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Hippocrates", + "given": [ + "Harold", + "H" + ], + "suffix": [ + "IV", + "MD" + ], + "prefix": [ + "Dr" + ] + } + ] + }, + "request": { + "method": "DELETE", + "url": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + }, + { + "fullUrl": "urn:uuid:9172e4a0-1ca5-646d-2183-b179f4daa737", + "resource": { + "resourceType": "Location", + "id": "9172e4a0-1ca5-646d-2183-b179f4daa737", + "partOf": { + "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + }, + "name": "HUH AE OMU", + "identifier": [ + { + "value": "urn:oid:9.8", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "fullUrl": "urn:uuid:3913ec4d-6576-5e1a-ac31-e8280583371c", + "resource": { + "resourceType": "Location", + "id": "3913ec4d-6576-5e1a-ac31-e8280583371c", + "partOf": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + }, + "name": "OMU B", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + } + }, + { + "fullUrl": "urn:uuid:804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "resource": { + "resourceType": "Location", + "id": "804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b", + "partOf": { + "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" + }, + "name": "Bed 03", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" + } + }, + { + "fullUrl": "urn:uuid:c043880b-0fab-1cb8-14f7-0475282c4d0e", + "resource": { + "resourceType": "Location", + "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", + "name": "HOMERTON UNIVER", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + } + }, + { + "fullUrl": "urn:uuid:f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "resource": { + "resourceType": "Location", + "id": "f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c", + "partOf": { + "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" + }, + "name": "Homerton UH", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + } + }, + { + "fullUrl": "urn:uuid:7e38808c-44a8-cb0c-4709-9d6092abc32c", + "resource": { + "resourceType": "Location", + "id": "7e38808c-44a8-cb0c-4709-9d6092abc32c", + "partOf": { + "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" + }, + "name": "Floor5", + "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" + } + }, + { + "fullUrl": "urn:uuid:59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "resource": { + "resourceType": "Location", + "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", + "name": "4 East, room 136, bed B 4E", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + } + }, + { + "fullUrl": "urn:uuid:d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "resource": { + "resourceType": "Location", + "id": "d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e", + "partOf": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "name": "136", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + } + }, + { + "fullUrl": "urn:uuid:5783dafa-c6c0-e673-cca4-42087ee1831b", + "resource": { + "resourceType": "Location", + "id": "5783dafa-c6c0-e673-cca4-42087ee1831b", + "partOf": { + "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" + }, + "name": "B", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" + } + }, + { + "fullUrl": "urn:uuid:8b39e6e5-78cd-63ab-2441-f43ca5554096", + "resource": { + "resourceType": "Location", + "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", + "name": "CommunityHospital", + "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" + } + }, + { + "fullUrl": "urn:uuid:42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "resource": { + "resourceType": "Location", + "id": "42b81572-ebb4-3f14-7a91-e1f9a9c70460", + "name": "Homes", + "identifier": [ + { + "value": "22", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/FDK" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + { + "fullUrl": "urn:uuid:84634858-74aa-5cdb-4547-60ec27339ac6", + "resource": { + "resourceType": "Location", + "id": "84634858-74aa-5cdb-4547-60ec27339ac6", + "name": "POC", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + } + }, + { + "fullUrl": "urn:uuid:9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", + "resource": { + "resourceType": "Location", + "id": "9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42", + "partOf": { + "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + }, + "name": "Room-2", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" + } + }, + { + "fullUrl": "urn:uuid:35353f20-6254-e794-98ed-8007490447e3", + "resource": { + "resourceType": "Location", + "id": "35353f20-6254-e794-98ed-8007490447e3", + "partOf": { + "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" + }, + "name": "Bed-103", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/35353f20-6254-e794-98ed-8007490447e3" + } + }, + { + "fullUrl": "urn:uuid:055e10f1-222e-df73-2325-0e4396db1a55", + "resource": { + "resourceType": "Location", + "id": "055e10f1-222e-df73-2325-0e4396db1a55", + "name": "Greenland", + "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/055e10f1-222e-df73-2325-0e4396db1a55" + } + }, + { + "fullUrl": "urn:uuid:1154e6b2-b022-b3be-7dce-2b940ab5376d", + "resource": { + "resourceType": "Location", + "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", + "name": "Nursing home", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + } + }, + { + "fullUrl": "urn:uuid:08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "resource": { + "resourceType": "Location", + "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", + "name": "Rosewood", + "mode": "instance", + "description": "Nursing home--Rosewood", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" + } + }, + { + "fullUrl": "urn:uuid:c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "resource": { + "resourceType": "Location", + "id": "c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "name": "ROOM1", + "identifier": [ + { + "value": "urn:oid:2.16.840.1.113883.4.642.1.1108", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + } + }, + { + "fullUrl": "urn:uuid:6f159848-5f01-01b3-9594-80fbbe9ab510", + "resource": { + "resourceType": "Location", + "id": "6f159848-5f01-01b3-9594-80fbbe9ab510", + "partOf": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "name": "BED1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" + } + }, + { + "fullUrl": "urn:uuid:4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "resource": { + "resourceType": "Location", + "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "name": "FACILITY1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + } + }, + { + "fullUrl": "urn:uuid:3b0911cb-4361-cd8d-b188-463af033c699", + "resource": { + "resourceType": "Location", + "id": "3b0911cb-4361-cd8d-b188-463af033c699", + "partOf": { + "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + }, + "name": "BUILDING1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:08314073-410a-3dc7-512c-0f2d206fb59d", + "resource": { + "resourceType": "Organization", + "id": "08314073-410a-3dc7-512c-0f2d206fb59d", + "identifier": [ + { + "value": "Etest", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-Etest" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "DELETE", + "url": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + }, + { + "fullUrl": "urn:uuid:919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "resource": { + "resourceType": "EpisodeOfCare", + "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", + "status": "planned", + "identifier": [ + { + "value": "EOC124", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" + } + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "DELETE", + "url": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + }, + { + "fullUrl": "urn:uuid:4b192760-03d2-aec4-b0a6-fde323912e1e", + "resource": { + "resourceType": "Encounter", + "id": "4b192760-03d2-aec4-b0a6-fde323912e1e", + "class": { + "code": "PRENC", + "display": "pre-admission", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "planned", + "location": [ + { + "status": "planned", + "location": { + "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" + } + }, + { + "status": "completed", + "location": { + "reference": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "status": "planned", + "location": { + "reference": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + }, + { + "status": "completed", + "location": { + "reference": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": true + } + ] + }, + { + "status": "planned", + "location": { + "reference": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + } + ], + "type": [ + { + "coding": [ + { + "code": "E", + "display": "Emergency", + "system": "http://terminology.hl7.org/CodeSystem/v2-0007" + } + ] + } + ], + "hospitalization": { + "preAdmissionIdentifier": { + "value": "1234567", + "type": { + "coding": [ + { + "code": "ANON", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Anonymous identifier" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + "reAdmission": { + "coding": [ + { + "code": "R", + "display": "Re-admission", + "system": "http://terminology.hl7.org/CodeSystem/v2-0092" + } + ] + }, + "admitSource": { + "coding": [ + { + "code": "NHS Provider-General (inc.A&E-this Hosp)" + } + ] + }, + "dischargeDisposition": { + "coding": [ + { + "code": "Admitted as Inpatient", + "display": "Sample", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ACR" + } + ] + }, + "dietPreference": [ + { + "coding": [ + { + "code": "Vegan", + "display": "Vegetarian" + } + ] + } + ], + "destination": { + "reference": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" + } + }, + "episodeOfCare": [ + { + "reference": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "CON", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "consultant" + } + ], + "individual": { + "reference": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "ADM", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "admitter" + } + ], + "individual": { + "reference": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "PART", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "Participation" + } + ], + "individual": { + "reference": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/36e3aaa4-569a-7d9d-037f-27235ed05701" + } + } + ], + "serviceType": { + "coding": [ + { + "code": "SUR" + } + ] + }, + "identifier": [ + { + "value": "40007716", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" + }, + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + }, + { + "value": "50", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "urn:oid:r2.3", + "assigner": { + "reference": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" + } + } + ], + "period": { + "start": "2015-02-08T15:54:19+05:30" + }, + "reasonCode": [ + { + "coding": [ + { + "code": "140004", + "display": "Chronic pharyngitis", + "system": "http://snomed.info/sct" + } + ] + } + ], + "length": { + "value": 2, + "unit": "d", + "system": "http://unitsofmeasure.org/" + }, + "meta": { + "security": [ + { + "code": "N", + "display": "normal", + "system": "http://terminology.hl7.org/CodeSystem/v3-Confidentiality" + } + ] + }, + "text": { + "status": "generated", + "div": "

Visit Description: Health Checkup

" + }, + "priority": { + "coding": [ + { + "code": "UR", + "display": "urgent", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.2" + }, + { + "code": "EL", + "display": "elective", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority", + "version": "V1.3" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/encounter-modeOfArrival", + "valueCoding": { + "code": "C", + "display": "Car", + "system": "http://terminology.hl7.org/CodeSystem/v2-0430" + } + } + ] + }, + "request": { + "method": "DELETE", + "url": "Encounter/4b192760-03d2-aec4-b0a6-fde323912e1e" + } + }, + { + "fullUrl": "urn:uuid:9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "resource": { + "resourceType": "Provenance", + "id": "9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c", + "occurredDateTime": "2021-08-17T18:49:43.004+05:30", + "recorded": "2029-08-01T11:21:24+05:30", + "reason": [ + { + "coding": [ + { + "code": "PATRQT", + "display": "patient requested", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActReason" + } + ] + } + ], + "agent": [ + { + "who": { + "reference": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + } + ], + "activity": { + "text": "ADT^A29^ADT_A29" + }, + "location": { + "reference": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + }, + "target": [ + { + "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f" + } + ] + }, + "request": { + "method": "DELETE", + "url": "Provenance/9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c" + } + }, + { + "fullUrl": "urn:uuid:ef39f581-5e8f-3917-35a9-3443303d9eee", + "resource": { + "resourceType": "Organization", + "id": "ef39f581-5e8f-3917-35a9-3443303d9eee", + "identifier": [ + { + "value": "DRNBR", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-DRNBR" + }, + { + "value": "urn:oid:W1.2", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "DELETE", + "url": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + } + }, + { + "fullUrl": "urn:uuid:95aea53b-8d49-d57f-d16f-4d14b914f992", + "resource": { + "resourceType": "Practitioner", + "id": "95aea53b-8d49-d57f-d16f-4d14b914f992", + "identifier": [ + { + "value": "C08", + "system": "urn:oid:W1.2", + "assigner": { + "reference": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" + }, + "type": { + "coding": [ + { + "code": "ANON", + "display": "Anonymous identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen", + "2ndname" + ], + "suffix": [ + "Jr", + "MD" + ], + "prefix": [ + "Dr" + ], + "use": "official" + } + ] + }, + "request": { + "method": "DELETE", + "url": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" + } + }, + { + "fullUrl": "urn:uuid:59d5e519-0108-5dd8-adfa-1eef5658009e", + "resource": { + "resourceType": "Location", + "id": "59d5e519-0108-5dd8-adfa-1eef5658009e", + "name": "Cona_Health", + "identifier": [ + { + "value": "urn:oid:1.3.6.1.4.1.44750.1.4", + "system": "urn:ietf:rfc:3986" + } + ], + "physicalType": { + "coding": [ + { + "code": "si", + "display": "site", + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type" + } + ] + } + }, + "request": { + "method": "DELETE", + "url": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" + } + }, + { + "fullUrl": "urn:uuid:4e68b44e-c053-02b1-6d6d-fe816f9fdfec", + "resource": { + "resourceType": "Organization", + "id": "4e68b44e-c053-02b1-6d6d-fe816f9fdfec", + "identifier": [ + { + "value": "t", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-t" + }, + { + "value": "urn:oid:1.12", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "DELETE", + "url": "Organization/4e68b44e-c053-02b1-6d6d-fe816f9fdfec" + } + }, + { + "fullUrl": "urn:uuid:e82402a9-b2d1-2a28-3250-c099d5a77bf7", + "resource": { + "resourceType": "Organization", + "id": "e82402a9-b2d1-2a28-3250-c099d5a77bf7", + "identifier": [ + { + "value": "PERSt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "DELETE", + "url": "Organization/e82402a9-b2d1-2a28-3250-c099d5a77bf7" + } + }, + { + "fullUrl": "urn:uuid:ce70e6c3-c190-121d-c251-e4bae5cde6a1", + "resource": { + "resourceType": "Practitioner", + "id": "ce70e6c3-c190-121d-c251-e4bae5cde6a1", + "identifier": [ + { + "value": "1134", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/e82402a9-b2d1-2a28-3250-c099d5a77bf7" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Aly", + "given": [ + "Zafar", + "Mahendra" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "DELETE", + "url": "Practitioner/ce70e6c3-c190-121d-c251-e4bae5cde6a1" + } + }, + { + "fullUrl": "urn:uuid:88a53755-c972-6904-b4ce-8884b84ddc2e", + "resource": { + "resourceType": "PractitionerRole", + "id": "88a53755-c972-6904-b4ce-8884b84ddc2e", + "code": [ + { + "coding": [ + { + "code": "ResponsibleObserver", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/ce70e6c3-c190-121d-c251-e4bae5cde6a1" + } + }, + "request": { + "method": "DELETE", + "url": "PractitionerRole/88a53755-c972-6904-b4ce-8884b84ddc2e" + } + }, + { + "fullUrl": "urn:uuid:3e0952c6-eea0-8938-96f8-07c224bf1577", + "resource": { + "resourceType": "Practitioner", + "id": "3e0952c6-eea0-8938-96f8-07c224bf1577", + "identifier": [ + { + "value": "2234" + } + ], + "name": [ + { + "family": "Pauly", + "given": [ + "Berrie", + "Raud" + ] + } + ] + }, + "request": { + "method": "DELETE", + "url": "Practitioner/3e0952c6-eea0-8938-96f8-07c224bf1577" + } + }, + { + "fullUrl": "urn:uuid:bc78e290-ec67-c238-1e05-aefb6b252b0c", + "resource": { + "resourceType": "PractitionerRole", + "id": "bc78e290-ec67-c238-1e05-aefb6b252b0c", + "code": [ + { + "coding": [ + { + "code": "ResponsibleObserver", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/3e0952c6-eea0-8938-96f8-07c224bf1577" + } + }, + "request": { + "method": "DELETE", + "url": "PractitionerRole/bc78e290-ec67-c238-1e05-aefb6b252b0c" + } + }, + { + "fullUrl": "urn:uuid:fe0adb86-ebe9-6479-0055-9db8dc1ff99a", + "resource": { + "resourceType": "Device", + "id": "fe0adb86-ebe9-6479-0055-9db8dc1ff99a", + "identifier": [ + { + "value": "EI12.3", + "system": "urn:uuid:UI2", + "type": { + "coding": [ + { + "code": "GUID", + "display": "Same as UUID.", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + }, + { + "system": "urn:oid:UI1", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "DELETE", + "url": "Device/fe0adb86-ebe9-6479-0055-9db8dc1ff99a" + } + }, + { + "fullUrl": "urn:uuid:45f65e47-46c4-1a54-f9fb-1321258e79b2", + "resource": { + "resourceType": "Practitioner", + "id": "45f65e47-46c4-1a54-f9fb-1321258e79b2", + "identifier": [ + { + "type": { + "coding": [ + { + "code": "MD-25" + } + ] + } + } + ] + }, + "request": { + "method": "DELETE", + "url": "Practitioner/45f65e47-46c4-1a54-f9fb-1321258e79b2" + } + }, + { + "fullUrl": "urn:uuid:090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3", + "resource": { + "resourceType": "PractitionerRole", + "id": "090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3", + "code": [ + { + "coding": [ + { + "code": "LabMedicalDirector", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/45f65e47-46c4-1a54-f9fb-1321258e79b2" + }, + "organization": { + "reference": "Organization/056aa7c7-6b75-3c67-63c5-cf9604f16d25" + } + }, + "request": { + "method": "DELETE", + "url": "PractitionerRole/090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3" + } + }, + { + "fullUrl": "urn:uuid:056aa7c7-6b75-3c67-63c5-cf9604f16d25", + "resource": { + "resourceType": "Organization", + "id": "056aa7c7-6b75-3c67-63c5-cf9604f16d25", + "name": "FairOaks Hspital", + "address": [ + { + "line": [ + "Research Park", + "Fairfax" + ], + "city": "VA", + "state": "22031", + "postalCode": "USA" + } + ] + }, + "request": { + "method": "DELETE", + "url": "Organization/056aa7c7-6b75-3c67-63c5-cf9604f16d25" + } + }, + { + "fullUrl": "urn:uuid:07fd2dd3-dbd6-5bb1-cfda-02226795d9a0", + "resource": { + "resourceType": "Observation", + "id": "07fd2dd3-dbd6-5bb1-cfda-02226795d9a0", + "identifier": [ + { + "value": "EI21", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-OII" + }, + { + "type": { + "coding": [ + { + "code": "FILL" + } + ] + } + } + ], + "status": "unknown", + "code": { + "coding": [ + { + "code": "8867-4", + "display": "heartrate", + "system": "http://loinc.org" + } + ] + }, + "component": [ + { + "code": { + "coding": [ + { + "code": "8867-4", + "display": "heartrate", + "system": "http://loinc.org" + } + ] + }, + "valueQuantity": { + "value": 60, + "code": "beats/min", + "unit": "beats/min", + "system": "urn:iso:std:iso:3986" + }, + "referenceRange": [ + { + "text": "70-80" + } + ] + }, + { + "code": { + "coding": [ + { + "code": "8867-4", + "display": "heartrate", + "system": "http://loinc.org" + } + ] + }, + "valueQuantity": { + "value": 120, + "code": "beats/min", + "unit": "beats/min", + "system": "urn:iso:std:iso:3986" + }, + "referenceRange": [ + { + "text": "70-80" + } + ] + } + ], + "effectiveDateTime": "1999-07-02", + "method": { + "coding": [ + { + "code": "OBS", + "display": "This is test method", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/AS4" + } + ] + }, + "device": { + "reference": "Device/fe0adb86-ebe9-6479-0055-9db8dc1ff99a" + }, + "bodySite": { + "coding": [ + { + "code": "BU", + "display": "Observation site", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/E5" + } + ] + }, + "performer": [ + { + "reference": "PractitionerRole/88a53755-c972-6904-b4ce-8884b84ddc2e" + }, + { + "reference": "PractitionerRole/bc78e290-ec67-c238-1e05-aefb6b252b0c" + }, + { + "reference": "PractitionerRole/090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3" + } + ], + "interpretation": [ + { + "coding": [ + { + "code": "A", + "display": "Abnormal", + "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation" + } + ] + }, + { + "coding": [ + { + "code": "B", + "display": "Better", + "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation" + } + ] + } + ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "S", + "display": "Partial", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Partial" + } + } + ] + }, + "request": { + "method": "DELETE", + "url": "Observation/07fd2dd3-dbd6-5bb1-cfda-02226795d9a0" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A05/ADT-A05-expected-2.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A29/ADT-A29-02-expected.json similarity index 91% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A05/ADT-A05-expected-2.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A29/ADT-A29-02-expected.json index a5c546212..b68900756 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A05/ADT-A05-expected-2.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A29/ADT-A29-02-expected.json @@ -40,9 +40,9 @@ ] }, "eventCoding": { - "code": "A05", + "code": "A29", "system": "http://terminology.hl7.org/CodeSystem/v2-0003", - "display": "ADT^A05^ADT_A05" + "display": "ADT^A29^ADT_A29" }, "language": "en-US", "sender": { @@ -53,18 +53,18 @@ } }, "request": { - "method": "PUT", + "method": "DELETE", "url": "MessageHeader/b4ca189b-51ae-33df-cbe2-559b4423a321" } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T12:59:26.319Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A05.

" + "div": "

Resource bundle generated on 2021-10-29T10:38:29.719Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A29.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -86,7 +86,7 @@ "activity": { "coding": [ { - "display": "ADT^A05^ADT_A05" + "display": "ADT^A29^ADT_A29" } ] }, @@ -105,8 +105,8 @@ ] }, "request": { - "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "method": "DELETE", + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { @@ -143,7 +143,7 @@ ] }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" } }, @@ -181,7 +181,7 @@ ] }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" } }, @@ -193,7 +193,7 @@ "name": "22 GHH Inc." }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" } }, @@ -205,7 +205,7 @@ "name": "23 GHH Inc." }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" } }, @@ -221,7 +221,7 @@ ] }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Device/503eb873-22fb-8199-ae28-3604ad59fe13" } }, @@ -630,7 +630,7 @@ ] }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" } }, @@ -669,7 +669,7 @@ ] }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Account/78295402-9b84-4829-b945-502ab3402de5" } }, @@ -699,7 +699,7 @@ ] }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" } }, @@ -729,7 +729,7 @@ ] }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" } }, @@ -759,7 +759,7 @@ ] }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" } }, @@ -805,7 +805,7 @@ } }, "request": { - "method": "PUT", + "method": "DELETE", "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" } }, @@ -835,7 +835,7 @@ ] }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Organization/11967e28-8dd4-a112-0fdc-377866bf12a0" } }, @@ -865,7 +865,7 @@ ] }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Organization/7452d91f-ae92-d8ce-5b4a-148be5b6538e" } }, @@ -895,7 +895,7 @@ ] }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Organization/0ccb76ca-b97e-1c86-4617-912a6d65c1f9" } }, @@ -945,7 +945,7 @@ ] }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Practitioner/f6775f99-5279-be04-bf81-0906c81f7443" } }, @@ -975,7 +975,7 @@ ] }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Organization/c613d7b2-525f-8c08-a7ac-b2b91486e257" } }, @@ -1016,7 +1016,7 @@ ] }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Practitioner/04f8cfc8-62ca-12df-63ce-6304ef577d44" } }, @@ -1054,7 +1054,7 @@ ] }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Practitioner/99edcabd-fbeb-7e25-f823-11da8d8ed342" } }, @@ -1088,7 +1088,7 @@ ] }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Practitioner/b065b233-8738-f1ec-1314-d61e4aac2c9e" } }, @@ -1118,7 +1118,7 @@ ] }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Organization/9f974d4f-47e8-21a6-e549-4de4599c3764" } }, @@ -1135,7 +1135,7 @@ ] }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Practitioner/84aa3f43-eefe-c16a-90e0-8ebf2306a77d" } }, @@ -1155,6 +1155,7 @@ } ], "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1165,7 +1166,7 @@ } }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, @@ -1179,6 +1180,7 @@ }, "name": "OMU B", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1189,7 +1191,7 @@ } }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" } }, @@ -1203,6 +1205,7 @@ }, "name": "Bed 03", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1213,7 +1216,7 @@ } }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" } }, @@ -1224,6 +1227,7 @@ "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", "name": "HOMERTON UNIVER", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1234,7 +1238,7 @@ } }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" } }, @@ -1248,6 +1252,7 @@ }, "name": "Homerton UH", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1258,7 +1263,7 @@ } }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" } }, @@ -1272,6 +1277,7 @@ }, "name": "Floor5", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1282,7 +1288,7 @@ } }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" } }, @@ -1293,6 +1299,7 @@ "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", "name": "4 East, room 136, bed B 4E", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1303,7 +1310,7 @@ } }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Location/59de4aa7-44c6-860a-88ad-53ae51ef49e8" } }, @@ -1317,6 +1324,7 @@ }, "name": "136", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1327,7 +1335,7 @@ } }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" } }, @@ -1341,6 +1349,7 @@ }, "name": "B", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1351,7 +1360,7 @@ } }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" } }, @@ -1362,6 +1371,7 @@ "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", "name": "CommunityHospital", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1372,7 +1382,7 @@ } }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" } }, @@ -1398,7 +1408,7 @@ } }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Location/42b81572-ebb4-3f14-7a91-e1f9a9c70460" } }, @@ -1409,6 +1419,7 @@ "id": "84634858-74aa-5cdb-4547-60ec27339ac6", "name": "POC", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1419,7 +1430,7 @@ } }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Location/84634858-74aa-5cdb-4547-60ec27339ac6" } }, @@ -1433,6 +1444,7 @@ }, "name": "Room-2", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1443,7 +1455,7 @@ } }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" } }, @@ -1457,6 +1469,7 @@ }, "name": "Bed-103", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1467,7 +1480,7 @@ } }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Location/35353f20-6254-e794-98ed-8007490447e3" } }, @@ -1478,6 +1491,7 @@ "id": "055e10f1-222e-df73-2325-0e4396db1a55", "name": "Greenland", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1488,7 +1502,7 @@ } }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Location/055e10f1-222e-df73-2325-0e4396db1a55" } }, @@ -1499,6 +1513,7 @@ "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", "name": "Nursing home", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1509,7 +1524,7 @@ } }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Location/1154e6b2-b022-b3be-7dce-2b940ab5376d" } }, @@ -1520,6 +1535,7 @@ "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", "name": "Rosewood", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1530,7 +1546,7 @@ } }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" } }, @@ -1560,7 +1576,7 @@ ] }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Organization/08314073-410a-3dc7-512c-0f2d206fb59d" } }, @@ -1593,7 +1609,7 @@ } }, "request": { - "method": "PUT", + "method": "DELETE", "url": "EpisodeOfCare/919a86bd-c9a1-86a7-2c9d-e34ae2559ffb" } }, @@ -1615,36 +1631,6 @@ "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, { "status": "completed", "location": { @@ -1657,42 +1643,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "planned", "location": { @@ -1705,42 +1655,6 @@ } ] }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "completed", "location": { @@ -1752,18 +1666,6 @@ "valueBoolean": true } ] - }, - { - "status": "completed", - "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true - } - ] } ], "type": [ @@ -1977,7 +1879,7 @@ } }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Encounter/4b192760-03d2-aec4-b0a6-fde323912e1e" } }, @@ -2007,7 +1909,7 @@ } ], "activity": { - "text": "ADT^A05^ADT_A05" + "text": "ADT^A29^ADT_A29" }, "location": { "reference": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" @@ -2019,7 +1921,7 @@ ] }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Provenance/9f6be243-c2fa-f8c8-0a7a-d168e98bdd4c" } }, @@ -2049,7 +1951,7 @@ ] }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Organization/ef39f581-5e8f-3917-35a9-3443303d9eee" } }, @@ -2095,7 +1997,7 @@ ] }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Practitioner/95aea53b-8d49-d57f-d16f-4d14b914f992" } }, @@ -2122,7 +2024,7 @@ } }, "request": { - "method": "PUT", + "method": "DELETE", "url": "Location/59d5e519-0108-5dd8-adfa-1eef5658009e" } } diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A31/ADT-A31-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A31/ADT-A31-01-expected.json similarity index 95% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A31/ADT-A31-expected.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A31/ADT-A31-01-expected.json index 7cc3b4ad4..e6daf4f2c 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A31/ADT-A31-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A31/ADT-A31-01-expected.json @@ -60,13 +60,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:35:27.489Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A31.

" + "div": "

Resource bundle generated on 2021-10-29T10:39:28.104Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A31.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -108,7 +108,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { @@ -1649,6 +1649,7 @@ } ], "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1673,6 +1674,7 @@ }, "name": "OMU B", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1697,6 +1699,7 @@ }, "name": "Bed 03", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1718,6 +1721,7 @@ "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", "name": "HOMERTON UNIVER", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1742,6 +1746,7 @@ }, "name": "Homerton UH", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1766,6 +1771,7 @@ }, "name": "Floor5", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1787,6 +1793,7 @@ "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", "name": "4 East, room 136, bed B 4E", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1811,6 +1818,7 @@ }, "name": "136", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1835,6 +1843,7 @@ }, "name": "B", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1856,6 +1865,7 @@ "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", "name": "CommunityHospital", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1903,6 +1913,7 @@ "id": "84634858-74aa-5cdb-4547-60ec27339ac6", "name": "POC", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1927,6 +1938,7 @@ }, "name": "Room-2", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1951,6 +1963,7 @@ }, "name": "Bed-103", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1972,6 +1985,7 @@ "id": "055e10f1-222e-df73-2325-0e4396db1a55", "name": "Greenland", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1993,6 +2007,7 @@ "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", "name": "Nursing home", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -2014,6 +2029,7 @@ "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", "name": "Rosewood", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -2041,6 +2057,7 @@ } ], "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2065,6 +2082,7 @@ }, "name": "BED1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2086,6 +2104,7 @@ "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", "name": "FACILITY1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2110,6 +2129,7 @@ }, "name": "BUILDING1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2134,6 +2154,7 @@ }, "name": "FLOOR1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -2183,7 +2204,7 @@ "resource": { "resourceType": "EpisodeOfCare", "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", - "status": "planned", + "status": "finished", "identifier": [ { "value": "EOC124", @@ -2238,7 +2259,7 @@ "display": "pre-admission", "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" }, - "status": "planned", + "status": "finished", "location": [ { "status": "planned", @@ -2246,36 +2267,6 @@ "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, { "status": "completed", "location": { @@ -2288,42 +2279,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "planned", "location": { @@ -2336,42 +2291,6 @@ } ] }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "completed", "location": { @@ -2384,18 +2303,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true - } - ] - }, { "status": "planned", "location": { @@ -2407,54 +2314,6 @@ "valueBoolean": false } ] - }, - { - "status": "planned", - "location": { - "reference": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] } ], "type": [ @@ -2673,7 +2532,8 @@ } ], "period": { - "start": "2015-02-08T15:54:19+05:30" + "start": "2015-02-08T15:54:19+05:30", + "end": "2015-02-09T15:54:19+05:30" }, "reasonCode": [ { @@ -3018,6 +2878,7 @@ "id": "a9c75502-d60a-d89b-5912-f046100cd47e", "name": "OT", "mode": "instance", + "description": "OT--201", "physicalType": { "coding": [ { @@ -3032,6 +2893,31 @@ "url": "Location/a9c75502-d60a-d89b-5912-f046100cd47e" } }, + { + "fullUrl": "urn:uuid:55f70355-863d-579a-b4aa-81fcaf3e1fb0", + "resource": { + "resourceType": "Location", + "id": "55f70355-863d-579a-b4aa-81fcaf3e1fb0", + "partOf": { + "reference": "Location/a9c75502-d60a-d89b-5912-f046100cd47e" + }, + "name": "201", + "mode": "instance", + "description": "OT--201", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/55f70355-863d-579a-b4aa-81fcaf3e1fb0" + } + }, { "fullUrl": "urn:uuid:2e2e33a1-60f8-7e38-c827-fe070237c3fb", "resource": { @@ -3987,6 +3873,9 @@ ] } ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, "extension": [ { "url": "http://example.com/v2-to-fhir-converter/Observation_Status", @@ -4356,19 +4245,6 @@ }, "system": "http://www.examplehealthplan.com/fhir/policyidentifier" }, - { - "value": "HMO-12345", - "type": { - "coding": [ - { - "code": "NI", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203", - "display": "National unique individual identifier" - } - ] - }, - "system": "urn:oid:2.16.840.1.113883.1.3" - }, { "value": "Medicare-12345", "type": { diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A31/ADT-A31-expected-2.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A31/ADT-A31-02-expected.json similarity index 93% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A31/ADT-A31-expected-2.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A31/ADT-A31-02-expected.json index 7ee03f6c5..86934d692 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A31/ADT-A31-expected-2.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A31/ADT-A31-02-expected.json @@ -58,13 +58,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:34:28.183Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A31.

" + "div": "

Resource bundle generated on 2021-10-29T10:40:08.921Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A31.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -106,7 +106,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { @@ -1155,6 +1155,7 @@ } ], "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1179,6 +1180,7 @@ }, "name": "OMU B", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1203,6 +1205,7 @@ }, "name": "Bed 03", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1224,6 +1227,7 @@ "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", "name": "HOMERTON UNIVER", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1248,6 +1252,7 @@ }, "name": "Homerton UH", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1272,6 +1277,7 @@ }, "name": "Floor5", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1293,6 +1299,7 @@ "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", "name": "4 East, room 136, bed B 4E", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1317,6 +1324,7 @@ }, "name": "136", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1341,6 +1349,7 @@ }, "name": "B", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1362,6 +1371,7 @@ "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", "name": "CommunityHospital", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1409,6 +1419,7 @@ "id": "84634858-74aa-5cdb-4547-60ec27339ac6", "name": "POC", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1433,6 +1444,7 @@ }, "name": "Room-2", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1457,6 +1469,7 @@ }, "name": "Bed-103", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1478,6 +1491,7 @@ "id": "055e10f1-222e-df73-2325-0e4396db1a55", "name": "Greenland", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1499,6 +1513,7 @@ "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", "name": "Nursing home", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1520,6 +1535,7 @@ "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", "name": "Rosewood", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1615,36 +1631,6 @@ "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, { "status": "completed", "location": { @@ -1657,42 +1643,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "planned", "location": { @@ -1705,42 +1655,6 @@ } ] }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "completed", "location": { @@ -1752,18 +1666,6 @@ "valueBoolean": true } ] - }, - { - "status": "completed", - "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true - } - ] } ], "type": [ diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A47/ADT-A47-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A47/ADT-A47-01-expected.json similarity index 99% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A47/ADT-A47-expected.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A47/ADT-A47-01-expected.json index 94fc085b7..5fb4e7d51 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A47/ADT-A47-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A47/ADT-A47-01-expected.json @@ -60,13 +60,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:36:45.495Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A47.

" + "div": "

Resource bundle generated on 2021-10-29T10:43:14.216Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A47.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -108,7 +108,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A47/ADT-A47-expected-2.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A47/ADT-A47-02-expected.json similarity index 99% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A47/ADT-A47-expected-2.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A47/ADT-A47-02-expected.json index 51634859b..9c25e84ad 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A47/ADT-A47-expected-2.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A47/ADT-A47-02-expected.json @@ -58,13 +58,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:36:10.646Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A47.

" + "div": "

Resource bundle generated on 2021-10-29T10:46:15.345Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A47.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -106,7 +106,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A60/ADT-A60-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A60/ADT-A60-01-expected.json similarity index 93% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A60/ADT-A60-expected.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A60/ADT-A60-01-expected.json index 41db51003..f592f413d 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A60/ADT-A60-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A60/ADT-A60-01-expected.json @@ -60,13 +60,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:38:14.075Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A60.

" + "div": "

Resource bundle generated on 2021-10-29T10:46:47.034Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A60.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -108,7 +108,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { @@ -1261,6 +1261,7 @@ } ], "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1285,6 +1286,7 @@ }, "name": "OMU B", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1309,6 +1311,7 @@ }, "name": "Bed 03", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1330,6 +1333,7 @@ "id": "c043880b-0fab-1cb8-14f7-0475282c4d0e", "name": "HOMERTON UNIVER", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1354,6 +1358,7 @@ }, "name": "Homerton UH", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1378,6 +1383,7 @@ }, "name": "Floor5", "mode": "instance", + "description": "HUH AE OMU--9.8--ISO--OMU B--Bed 03--HOMERTON UNIVER--C--Homerton UH--Floor5", "physicalType": { "coding": [ { @@ -1399,6 +1405,7 @@ "id": "59de4aa7-44c6-860a-88ad-53ae51ef49e8", "name": "4 East, room 136, bed B 4E", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1423,6 +1430,7 @@ }, "name": "136", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1447,6 +1455,7 @@ }, "name": "B", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1468,6 +1477,7 @@ "id": "8b39e6e5-78cd-63ab-2441-f43ca5554096", "name": "CommunityHospital", "mode": "instance", + "description": "4 East, room 136, bed B 4E--136--B--CommunityHospital--N", "physicalType": { "coding": [ { @@ -1515,6 +1525,7 @@ "id": "84634858-74aa-5cdb-4547-60ec27339ac6", "name": "POC", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1539,6 +1550,7 @@ }, "name": "Room-2", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1563,6 +1575,7 @@ }, "name": "Bed-103", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1584,6 +1597,7 @@ "id": "055e10f1-222e-df73-2325-0e4396db1a55", "name": "Greenland", "mode": "instance", + "description": "POC--Room-2--Bed-103--C--Greenland", "physicalType": { "coding": [ { @@ -1605,6 +1619,7 @@ "id": "1154e6b2-b022-b3be-7dce-2b940ab5376d", "name": "Nursing home", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1626,6 +1641,7 @@ "id": "08b7f694-ec03-e35a-d0b0-2fae5940fe37", "name": "Rosewood", "mode": "instance", + "description": "Nursing home--Rosewood", "physicalType": { "coding": [ { @@ -1653,6 +1669,7 @@ } ], "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -1677,6 +1694,7 @@ }, "name": "BED1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -1698,6 +1716,7 @@ "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", "name": "FACILITY1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -1722,6 +1741,7 @@ }, "name": "BUILDING1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -1746,6 +1766,7 @@ }, "name": "FLOOR1", "mode": "instance", + "description": "ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--BED1--FACILITY1--BUILDING1--FLOOR1", "physicalType": { "coding": [ { @@ -1795,7 +1816,7 @@ "resource": { "resourceType": "EpisodeOfCare", "id": "919a86bd-c9a1-86a7-2c9d-e34ae2559ffb", - "status": "planned", + "status": "finished", "identifier": [ { "value": "EOC124", @@ -1833,7 +1854,7 @@ "display": "pre-admission", "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" }, - "status": "planned", + "status": "finished", "location": [ { "status": "planned", @@ -1841,36 +1862,6 @@ "reference": "Location/9172e4a0-1ca5-646d-2183-b179f4daa737" } }, - { - "status": "planned", - "location": { - "reference": "Location/3913ec4d-6576-5e1a-ac31-e8280583371c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/804a03f1-4eb5-d01d-82f9-0d4b52a9ea3b" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/c043880b-0fab-1cb8-14f7-0475282c4d0e" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/f7ef3d02-a5d5-a361-e9d9-b316ba1ff78c" - } - }, - { - "status": "planned", - "location": { - "reference": "Location/7e38808c-44a8-cb0c-4709-9d6092abc32c" - } - }, { "status": "completed", "location": { @@ -1883,42 +1874,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/d5dd2e32-efbc-854a-cf3c-2bd6a7ff075e" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/5783dafa-c6c0-e673-cca4-42087ee1831b" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "completed", - "location": { - "reference": "Location/8b39e6e5-78cd-63ab-2441-f43ca5554096" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "planned", "location": { @@ -1931,42 +1886,6 @@ } ] }, - { - "status": "planned", - "location": { - "reference": "Location/9bbd3aa6-8cb1-1abe-2b2a-9f320c263b42" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/35353f20-6254-e794-98ed-8007490447e3" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/055e10f1-222e-df73-2325-0e4396db1a55" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, { "status": "completed", "location": { @@ -1979,18 +1898,6 @@ } ] }, - { - "status": "completed", - "location": { - "reference": "Location/08b7f694-ec03-e35a-d0b0-2fae5940fe37" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": true - } - ] - }, { "status": "planned", "location": { @@ -2002,54 +1909,6 @@ "valueBoolean": false } ] - }, - { - "status": "planned", - "location": { - "reference": "Location/6f159848-5f01-01b3-9594-80fbbe9ab510" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/3b0911cb-4361-cd8d-b188-463af033c699" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] - }, - { - "status": "planned", - "location": { - "reference": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" - }, - "extension": [ - { - "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", - "valueBoolean": false - } - ] } ], "type": [ @@ -2268,7 +2127,8 @@ } ], "period": { - "start": "2015-02-08T15:54:19+05:30" + "start": "2015-02-08T15:54:19+05:30", + "end": "2015-02-09T15:54:19+05:30" }, "reasonCode": [ { diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A60/ADT-A60-expected-2.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A60/ADT-A60-02-expected.json similarity index 99% rename from src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A60/ADT-A60-expected-2.json rename to src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A60/ADT-A60-02-expected.json index 5956c616a..48a9962fd 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A60/ADT-A60-expected-2.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ADT_A60/ADT-A60-02-expected.json @@ -58,13 +58,13 @@ } }, { - "fullUrl": "urn:uuid:f65d2168-02c8-1897-210d-361176172856", + "fullUrl": "urn:uuid:0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "resource": { "resourceType": "Provenance", - "id": "f65d2168-02c8-1897-210d-361176172856", + "id": "0a7545d7-202f-96e5-31e9-bb7d27ade3c2", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:37:39.013Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A60.

" + "div": "

Resource bundle generated on 2021-10-29T10:47:28.446Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ADT_A60.

" }, "occurredDateTime": "1989-08-18T14:41:00+05:30", "recorded": "1989-08-18T14:41:00+05:30", @@ -106,7 +106,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/f65d2168-02c8-1897-210d-361176172856" + "url": "Provenance/0a7545d7-202f-96e5-31e9-bb7d27ade3c2" } }, { diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/MDM_T01/MDM-T01-01-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/MDM_T01/MDM-T01-01-expected.json new file mode 100644 index 000000000..117382a80 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/MDM_T01/MDM-T01-01-expected.json @@ -0,0 +1,825 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2008-01-31T19:15:00+05:30", + "identifier": { + "value": "PS1-20080131160038" + }, + "id": "c1cfc1cf-5772-3713-5eb2-0ffdca6df60b", + "entry": [ + { + "fullUrl": "urn:uuid:f6276090-3778-3e87-dab9-2c9dae838d1a", + "resource": { + "resourceType": "MessageHeader", + "id": "f6276090-3778-3e87-dab9-2c9dae838d1a", + "source": { + "name": "PROSOLV", + "_endpoint": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/data-absent-reason", + "valueCode": "unknown" + } + ] + }, + "version": "2.4.3.52854", + "software": "Rhapsody" + }, + "destination": [ + { + "name": "SYSTEM", + "_endpoint": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/data-absent-reason", + "valueCode": "unknown" + } + ] + }, + "receiver": { + "reference": "Organization/a546f42b-2f91-c12a-4596-67ce49a595d9" + } + } + ], + "meta": { + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "T02", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "MDM^T02" + }, + "sender": { + "reference": "Organization/a546f42b-2f91-c12a-4596-67ce49a595d9" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/f6276090-3778-3e87-dab9-2c9dae838d1a" + } + }, + { + "fullUrl": "urn:uuid:62e243a9-2299-8d17-3755-2ea9dcea5246", + "resource": { + "resourceType": "Provenance", + "id": "62e243a9-2299-8d17-3755-2ea9dcea5246", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T09:01:41.469Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: MDM_T01.

" + }, + "occurredDateTime": "2008-01-31T19:15:00+05:30", + "recorded": "2008-01-31T19:15:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/a546f42b-2f91-c12a-4596-67ce49a595d9" + } + } + ], + "activity": { + "coding": [ + { + "display": "MDM^T02^" + } + ] + }, + "target": [ + { + "reference": "Bundle/c1cfc1cf-5772-3713-5eb2-0ffdca6df60b" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/62e243a9-2299-8d17-3755-2ea9dcea5246" + } + }, + { + "fullUrl": "urn:uuid:a546f42b-2f91-c12a-4596-67ce49a595d9", + "resource": { + "resourceType": "Organization", + "id": "a546f42b-2f91-c12a-4596-67ce49a595d9", + "identifier": [ + { + "value": "XYZHOSPITAL", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-XYZHOSPITAL" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/a546f42b-2f91-c12a-4596-67ce49a595d9" + } + }, + { + "fullUrl": "urn:uuid:4b549918-a84d-cdaf-e150-c773a5d306e5", + "resource": { + "resourceType": "Device", + "id": "4b549918-a84d-cdaf-e150-c773a5d306e5", + "manufacturer": "Orion", + "deviceName": [ + { + "name": "Rhapsody", + "type": "manufacturer-name" + } + ], + "version": [ + { + "value": "2.4.3.52854" + } + ], + "modelNumber": "2.4.3", + "note": [ + { + "text": "Testactivity" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/4b549918-a84d-cdaf-e150-c773a5d306e5" + } + }, + { + "fullUrl": "urn:uuid:63520aa7-562e-9367-0c96-f8f720c3a418", + "resource": { + "resourceType": "Provenance", + "id": "63520aa7-562e-9367-0c96-f8f720c3a418", + "recorded": "2008-01-31T19:15:00+05:30", + "agent": [ + { + "who": { + "reference": "Practitioner/983f747a-cf80-25e8-0431-719272f56adf" + } + } + ], + "activity": { + "text": "MDM^T02" + }, + "target": [ + { + "reference": "Bundle/c1cfc1cf-5772-3713-5eb2-0ffdca6df60b" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/63520aa7-562e-9367-0c96-f8f720c3a418" + } + }, + { + "fullUrl": "urn:uuid:983f747a-cf80-25e8-0431-719272f56adf", + "resource": { + "resourceType": "Practitioner", + "id": "983f747a-cf80-25e8-0431-719272f56adf", + "identifier": [ + { + "value": "C08" + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/983f747a-cf80-25e8-0431-719272f56adf" + } + }, + { + "fullUrl": "urn:uuid:073b77fa-7722-30cf-cd8f-218a179da613", + "resource": { + "resourceType": "Patient", + "id": "073b77fa-7722-30cf-cd8f-218a179da613", + "identifier": [ + { + "value": "987654321" + }, + { + "value": "987654321" + }, + { + "value": "111-22-3333", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + } + ], + "name": [ + { + "family": "PROSOLV", + "given": [ + "SAMPLE" + ] + } + ], + "birthDate": "1972-12-01", + "gender": "male" + }, + "request": { + "method": "PUT", + "url": "Patient/073b77fa-7722-30cf-cd8f-218a179da613" + } + }, + { + "fullUrl": "urn:uuid:53abf53e-4d5f-9ac3-01fc-1c57fbc8ff1b", + "resource": { + "resourceType": "Account", + "id": "53abf53e-4d5f-9ac3-01fc-1c57fbc8ff1b", + "identifier": [ + { + "value": "10000001" + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/073b77fa-7722-30cf-cd8f-218a179da613" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/53abf53e-4d5f-9ac3-01fc-1c57fbc8ff1b" + } + }, + { + "fullUrl": "urn:uuid:f91b9450-5b30-513c-e992-770d60ebccca", + "resource": { + "resourceType": "Practitioner", + "id": "f91b9450-5b30-513c-e992-770d60ebccca", + "identifier": [ + { + "value": "1234" + } + ], + "name": [ + { + "family": "HIPPOCRATES", + "given": [ + "KOS" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/f91b9450-5b30-513c-e992-770d60ebccca" + } + }, + { + "fullUrl": "urn:uuid:3ff52588-4f70-e5f9-bd2e-3ff770b6bc16", + "resource": { + "resourceType": "Practitioner", + "id": "3ff52588-4f70-e5f9-bd2e-3ff770b6bc16", + "identifier": [ + { + "value": "9099" + } + ], + "name": [ + { + "family": "KEVORKIAN", + "given": [ + "JACK" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/3ff52588-4f70-e5f9-bd2e-3ff770b6bc16" + } + }, + { + "fullUrl": "urn:uuid:39dfc508-b0aa-36f2-de51-5ff7aee0bc62", + "resource": { + "resourceType": "Practitioner", + "id": "39dfc508-b0aa-36f2-de51-5ff7aee0bc62", + "identifier": [ + { + "value": "8888" + } + ], + "name": [ + { + "family": "HOUSE", + "given": [ + "GREGORY" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/39dfc508-b0aa-36f2-de51-5ff7aee0bc62" + } + }, + { + "fullUrl": "urn:uuid:b4c8d42e-dbcb-9290-7593-7586f4b5d0c9", + "resource": { + "resourceType": "Location", + "id": "b4c8d42e-dbcb-9290-7593-7586f4b5d0c9", + "name": "CCU", + "mode": "instance", + "description": "CCU--2003--1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/b4c8d42e-dbcb-9290-7593-7586f4b5d0c9" + } + }, + { + "fullUrl": "urn:uuid:55fb6bcf-59d7-2cc4-2ddc-d38ba31ff1d2", + "resource": { + "resourceType": "Location", + "id": "55fb6bcf-59d7-2cc4-2ddc-d38ba31ff1d2", + "partOf": { + "reference": "Location/b4c8d42e-dbcb-9290-7593-7586f4b5d0c9" + }, + "name": "2000", + "mode": "instance", + "description": "CCU--2000--1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/55fb6bcf-59d7-2cc4-2ddc-d38ba31ff1d2" + } + }, + { + "fullUrl": "urn:uuid:b2d5327c-354a-b91d-541d-c6b0fe91a841", + "resource": { + "resourceType": "Location", + "id": "b2d5327c-354a-b91d-541d-c6b0fe91a841", + "partOf": { + "reference": "Location/66fd3f3f-1ed8-35f5-002d-40ca03271177" + }, + "name": "1", + "mode": "instance", + "description": "CCU--2003--1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/b2d5327c-354a-b91d-541d-c6b0fe91a841" + } + }, + { + "fullUrl": "urn:uuid:66fd3f3f-1ed8-35f5-002d-40ca03271177", + "resource": { + "resourceType": "Location", + "id": "66fd3f3f-1ed8-35f5-002d-40ca03271177", + "partOf": { + "reference": "Location/b4c8d42e-dbcb-9290-7593-7586f4b5d0c9" + }, + "name": "2003", + "mode": "instance", + "description": "CCU--2003--1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/66fd3f3f-1ed8-35f5-002d-40ca03271177" + } + }, + { + "fullUrl": "urn:uuid:8bc99636-4bdf-d4be-5661-f77f4f3a7ff6", + "resource": { + "resourceType": "Encounter", + "id": "8bc99636-4bdf-d4be-5661-f77f4f3a7ff6", + "class": { + "code": "IMP", + "display": "inpatient encounter", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "in-progress", + "location": [ + { + "status": "active", + "location": { + "reference": "Location/b4c8d42e-dbcb-9290-7593-7586f4b5d0c9" + } + }, + { + "status": "completed", + "location": { + "reference": "Location/b4c8d42e-dbcb-9290-7593-7586f4b5d0c9" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/f91b9450-5b30-513c-e992-770d60ebccca" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/3ff52588-4f70-e5f9-bd2e-3ff770b6bc16" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "CON", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "consultant" + } + ], + "individual": { + "reference": "Practitioner/39dfc508-b0aa-36f2-de51-5ff7aee0bc62" + } + } + ], + "identifier": [ + { + "value": "10000001", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + } + ], + "text": { + "status": "generated", + "div": "

Visit Description:

" + }, + "subject": { + "reference": "Patient/073b77fa-7722-30cf-cd8f-218a179da613" + } + }, + "request": { + "method": "PUT", + "url": "Encounter/8bc99636-4bdf-d4be-5661-f77f4f3a7ff6" + } + }, + { + "fullUrl": "urn:uuid:0bd32673-66cf-0e3e-61df-803590588758", + "resource": { + "resourceType": "DocumentReference", + "id": "0bd32673-66cf-0e3e-61df-803590588758", + "type": { + "coding": [ + { + "code": "DI" + } + ] + }, + "context": { + "period": { + "start": "2008-01-31T19:10:00+05:30" + } + }, + "content": [ + { + "attachment": { + "creation": "2008-01-31T19:15:00+05:30" + } + } + ], + "author": [ + { + "reference": "PractitionerRole/5b91be6c-bce1-d67a-0ac5-3b0d36640a38" + } + ], + "masterIdentifier": { + "value": "1.2.840.317.5947431.51.20080131160038" + }, + "relatesTo": [ + { + "code": "appends", + "target": { + "identifier": { + "value": "1.2.840.317.5947431.51.20080131155715" + } + } + } + ], + "docStatus": "preliminary", + "status": "current" + }, + "request": { + "method": "PUT", + "url": "DocumentReference/0bd32673-66cf-0e3e-61df-803590588758" + } + }, + { + "fullUrl": "urn:uuid:4b1a16a4-4caa-c86f-791b-56cd3dcd5489", + "resource": { + "resourceType": "Practitioner", + "id": "4b1a16a4-4caa-c86f-791b-56cd3dcd5489", + "identifier": [ + { + "value": "IvanDoctorovich" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/4b1a16a4-4caa-c86f-791b-56cd3dcd5489" + } + }, + { + "fullUrl": "urn:uuid:5b91be6c-bce1-d67a-0ac5-3b0d36640a38", + "resource": { + "resourceType": "PractitionerRole", + "id": "5b91be6c-bce1-d67a-0ac5-3b0d36640a38", + "practitioner": { + "reference": "Practitioner/4b1a16a4-4caa-c86f-791b-56cd3dcd5489" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/5b91be6c-bce1-d67a-0ac5-3b0d36640a38" + } + }, + { + "fullUrl": "urn:uuid:759e7d81-3fa3-111c-8580-9c4c71176dc2", + "resource": { + "resourceType": "ServiceRequest", + "id": "759e7d81-3fa3-111c-8580-9c4c71176dc2", + "status": "active", + "intent": "order", + "identifier": [ + { + "value": "00012345", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "1-1", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "code": { + "coding": [ + { + "code": "02585", + "display": "TransthoracicEcho", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/PCV4" + } + ] + }, + "reasonCode": [ + { + "coding": [ + { + "code": "796.4", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/I9M" + } + ] + }, + { + "coding": [ + { + "code": "786.09", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/I9M" + } + ] + }, + { + "coding": [ + { + "code": "414.8", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/I9M" + } + ] + } + ], + "subject": { + "reference": "Patient/073b77fa-7722-30cf-cd8f-218a179da613" + }, + "reasonReference": [ + { + "reference": "DocumentReference/0bd32673-66cf-0e3e-61df-803590588758" + } + ], + "specimen": [ + { + "reference": "Specimen/465cc454-0c8c-9470-e96a-75c3d662e760" + } + ], + "note": [ + { + "text": "No Antibodies Detected", + "time": "2020-10-10T18:15:00+05:30", + "authorReference": { + "reference": "Practitioner/ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2" + } + }, + { + "text": "Please follow the text instructions" + } + ], + "asNeededCodeableConcept": { + "text": "This is condition text" + }, + "quantityQuantity": { + "value": 54, + "unit": "lbs" + }, + "occurrenceTiming": { + "code": { + "coding": [ + { + "code": "ACM", + "display": "Before Breakfast", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/HL7xxx" + } + ] + }, + "repeat": { + "period": 12, + "periodUnit": "min", + "when": [ + "ACM" + ], + "offset": 2, + "boundsPeriod": { + "start": "2021-10-10T05:30:00+05:30", + "end": "2021-11-10T05:30:00+05:30" + }, + "duration": 2, + "durationUnit": "h", + "count": 5 + } + }, + "priority": "asap" + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/759e7d81-3fa3-111c-8580-9c4c71176dc2" + } + }, + { + "fullUrl": "urn:uuid:ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2", + "resource": { + "resourceType": "Practitioner", + "id": "ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2", + "identifier": [ + { + "value": "MLEE" + } + ], + "name": [ + { + "family": "ATTEND", + "given": [ + "AARON", + "A" + ], + "suffix": [ + "MD" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2" + } + }, + { + "fullUrl": "urn:uuid:465cc454-0c8c-9470-e96a-75c3d662e760", + "resource": { + "resourceType": "Specimen", + "id": "465cc454-0c8c-9470-e96a-75c3d662e760", + "collection": { + "collectedDateTime": "2008-01-31T19:10:00+05:30" + }, + "identifier": [ + { + "value": "00012345", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "1-1", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Specimen/465cc454-0c8c-9470-e96a-75c3d662e760" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/MDM_T01/MDM-T01-02-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/MDM_T01/MDM-T01-02-expected.json new file mode 100644 index 000000000..4350324f2 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/MDM_T01/MDM-T01-02-expected.json @@ -0,0 +1,948 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2008-01-31T19:15:00+05:30", + "identifier": { + "value": "PS1-20080131160038" + }, + "id": "c1cfc1cf-5772-3713-5eb2-0ffdca6df60b", + "entry": [ + { + "fullUrl": "urn:uuid:f6276090-3778-3e87-dab9-2c9dae838d1a", + "resource": { + "resourceType": "MessageHeader", + "id": "f6276090-3778-3e87-dab9-2c9dae838d1a", + "source": { + "name": "PROSOLV", + "_endpoint": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/data-absent-reason", + "valueCode": "unknown" + } + ] + }, + "version": "2.4.3.52854", + "software": "Rhapsody" + }, + "destination": [ + { + "name": "SYSTEM", + "_endpoint": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/data-absent-reason", + "valueCode": "unknown" + } + ] + }, + "receiver": { + "reference": "Organization/a546f42b-2f91-c12a-4596-67ce49a595d9" + } + } + ], + "meta": { + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "T01", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "MDM^T01^MDM_T01" + }, + "sender": { + "reference": "Organization/a546f42b-2f91-c12a-4596-67ce49a595d9" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/f6276090-3778-3e87-dab9-2c9dae838d1a" + } + }, + { + "fullUrl": "urn:uuid:62e243a9-2299-8d17-3755-2ea9dcea5246", + "resource": { + "resourceType": "Provenance", + "id": "62e243a9-2299-8d17-3755-2ea9dcea5246", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T09:21:28.605Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: MDM_T01.

" + }, + "occurredDateTime": "2008-01-31T19:15:00+05:30", + "recorded": "2008-01-31T19:15:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/a546f42b-2f91-c12a-4596-67ce49a595d9" + } + } + ], + "activity": { + "coding": [ + { + "display": "MDM^T01^MDM_T01" + } + ] + }, + "target": [ + { + "reference": "Bundle/c1cfc1cf-5772-3713-5eb2-0ffdca6df60b" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/62e243a9-2299-8d17-3755-2ea9dcea5246" + } + }, + { + "fullUrl": "urn:uuid:a546f42b-2f91-c12a-4596-67ce49a595d9", + "resource": { + "resourceType": "Organization", + "id": "a546f42b-2f91-c12a-4596-67ce49a595d9", + "identifier": [ + { + "value": "XYZHOSPITAL", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-XYZHOSPITAL" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/a546f42b-2f91-c12a-4596-67ce49a595d9" + } + }, + { + "fullUrl": "urn:uuid:4b549918-a84d-cdaf-e150-c773a5d306e5", + "resource": { + "resourceType": "Device", + "id": "4b549918-a84d-cdaf-e150-c773a5d306e5", + "manufacturer": "Orion", + "deviceName": [ + { + "name": "Rhapsody", + "type": "manufacturer-name" + } + ], + "version": [ + { + "value": "2.4.3.52854" + } + ], + "modelNumber": "2.4.3", + "note": [ + { + "text": "Testactivity" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/4b549918-a84d-cdaf-e150-c773a5d306e5" + } + }, + { + "fullUrl": "urn:uuid:63520aa7-562e-9367-0c96-f8f720c3a418", + "resource": { + "resourceType": "Provenance", + "id": "63520aa7-562e-9367-0c96-f8f720c3a418", + "recorded": "2008-01-31T19:15:00+05:30", + "agent": [ + { + "who": { + "reference": "Practitioner/983f747a-cf80-25e8-0431-719272f56adf" + } + } + ], + "activity": { + "text": "MDM^T01^MDM_T01" + }, + "target": [ + { + "reference": "Bundle/c1cfc1cf-5772-3713-5eb2-0ffdca6df60b" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/63520aa7-562e-9367-0c96-f8f720c3a418" + } + }, + { + "fullUrl": "urn:uuid:983f747a-cf80-25e8-0431-719272f56adf", + "resource": { + "resourceType": "Practitioner", + "id": "983f747a-cf80-25e8-0431-719272f56adf", + "identifier": [ + { + "value": "C08" + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/983f747a-cf80-25e8-0431-719272f56adf" + } + }, + { + "fullUrl": "urn:uuid:073b77fa-7722-30cf-cd8f-218a179da613", + "resource": { + "resourceType": "Patient", + "id": "073b77fa-7722-30cf-cd8f-218a179da613", + "identifier": [ + { + "value": "987654321" + }, + { + "value": "987654321" + }, + { + "value": "111-22-3333", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + } + ], + "name": [ + { + "family": "PROSOLV", + "given": [ + "SAMPLE" + ] + } + ], + "birthDate": "1972-12-01", + "gender": "male" + }, + "request": { + "method": "PUT", + "url": "Patient/073b77fa-7722-30cf-cd8f-218a179da613" + } + }, + { + "fullUrl": "urn:uuid:53abf53e-4d5f-9ac3-01fc-1c57fbc8ff1b", + "resource": { + "resourceType": "Account", + "id": "53abf53e-4d5f-9ac3-01fc-1c57fbc8ff1b", + "identifier": [ + { + "value": "10000001" + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/073b77fa-7722-30cf-cd8f-218a179da613" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/53abf53e-4d5f-9ac3-01fc-1c57fbc8ff1b" + } + }, + { + "fullUrl": "urn:uuid:f91b9450-5b30-513c-e992-770d60ebccca", + "resource": { + "resourceType": "Practitioner", + "id": "f91b9450-5b30-513c-e992-770d60ebccca", + "identifier": [ + { + "value": "1234" + } + ], + "name": [ + { + "family": "HIPPOCRATES", + "given": [ + "KOS" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/f91b9450-5b30-513c-e992-770d60ebccca" + } + }, + { + "fullUrl": "urn:uuid:3ff52588-4f70-e5f9-bd2e-3ff770b6bc16", + "resource": { + "resourceType": "Practitioner", + "id": "3ff52588-4f70-e5f9-bd2e-3ff770b6bc16", + "identifier": [ + { + "value": "9099" + } + ], + "name": [ + { + "family": "KEVORKIAN", + "given": [ + "JACK" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/3ff52588-4f70-e5f9-bd2e-3ff770b6bc16" + } + }, + { + "fullUrl": "urn:uuid:39dfc508-b0aa-36f2-de51-5ff7aee0bc62", + "resource": { + "resourceType": "Practitioner", + "id": "39dfc508-b0aa-36f2-de51-5ff7aee0bc62", + "identifier": [ + { + "value": "8888" + } + ], + "name": [ + { + "family": "HOUSE", + "given": [ + "GREGORY" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/39dfc508-b0aa-36f2-de51-5ff7aee0bc62" + } + }, + { + "fullUrl": "urn:uuid:b4c8d42e-dbcb-9290-7593-7586f4b5d0c9", + "resource": { + "resourceType": "Location", + "id": "b4c8d42e-dbcb-9290-7593-7586f4b5d0c9", + "name": "CCU", + "mode": "instance", + "description": "CCU--2003--1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/b4c8d42e-dbcb-9290-7593-7586f4b5d0c9" + } + }, + { + "fullUrl": "urn:uuid:55fb6bcf-59d7-2cc4-2ddc-d38ba31ff1d2", + "resource": { + "resourceType": "Location", + "id": "55fb6bcf-59d7-2cc4-2ddc-d38ba31ff1d2", + "partOf": { + "reference": "Location/b4c8d42e-dbcb-9290-7593-7586f4b5d0c9" + }, + "name": "2000", + "mode": "instance", + "description": "CCU--2000--1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/55fb6bcf-59d7-2cc4-2ddc-d38ba31ff1d2" + } + }, + { + "fullUrl": "urn:uuid:b2d5327c-354a-b91d-541d-c6b0fe91a841", + "resource": { + "resourceType": "Location", + "id": "b2d5327c-354a-b91d-541d-c6b0fe91a841", + "partOf": { + "reference": "Location/66fd3f3f-1ed8-35f5-002d-40ca03271177" + }, + "name": "1", + "mode": "instance", + "description": "CCU--2003--1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/b2d5327c-354a-b91d-541d-c6b0fe91a841" + } + }, + { + "fullUrl": "urn:uuid:66fd3f3f-1ed8-35f5-002d-40ca03271177", + "resource": { + "resourceType": "Location", + "id": "66fd3f3f-1ed8-35f5-002d-40ca03271177", + "partOf": { + "reference": "Location/b4c8d42e-dbcb-9290-7593-7586f4b5d0c9" + }, + "name": "2003", + "mode": "instance", + "description": "CCU--2003--1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/66fd3f3f-1ed8-35f5-002d-40ca03271177" + } + }, + { + "fullUrl": "urn:uuid:8bc99636-4bdf-d4be-5661-f77f4f3a7ff6", + "resource": { + "resourceType": "Encounter", + "id": "8bc99636-4bdf-d4be-5661-f77f4f3a7ff6", + "class": { + "code": "IMP", + "display": "inpatient encounter", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "in-progress", + "location": [ + { + "status": "active", + "location": { + "reference": "Location/b4c8d42e-dbcb-9290-7593-7586f4b5d0c9" + } + }, + { + "status": "completed", + "location": { + "reference": "Location/b4c8d42e-dbcb-9290-7593-7586f4b5d0c9" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/f91b9450-5b30-513c-e992-770d60ebccca" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/3ff52588-4f70-e5f9-bd2e-3ff770b6bc16" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "CON", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "consultant" + } + ], + "individual": { + "reference": "Practitioner/39dfc508-b0aa-36f2-de51-5ff7aee0bc62" + } + } + ], + "identifier": [ + { + "value": "10000001", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + } + ], + "text": { + "status": "generated", + "div": "

Visit Description:

" + }, + "subject": { + "reference": "Patient/073b77fa-7722-30cf-cd8f-218a179da613" + } + }, + "request": { + "method": "PUT", + "url": "Encounter/8bc99636-4bdf-d4be-5661-f77f4f3a7ff6" + } + }, + { + "fullUrl": "urn:uuid:0bd32673-66cf-0e3e-61df-803590588758", + "resource": { + "resourceType": "DocumentReference", + "id": "0bd32673-66cf-0e3e-61df-803590588758", + "type": { + "coding": [ + { + "code": "DI" + } + ] + }, + "context": { + "period": { + "start": "2008-01-31T19:10:00+05:30" + } + }, + "content": [ + { + "attachment": { + "creation": "2008-01-31T19:15:00+05:30" + } + } + ], + "author": [ + { + "reference": "PractitionerRole/5b91be6c-bce1-d67a-0ac5-3b0d36640a38" + } + ], + "masterIdentifier": { + "value": "1.2.840.317.5947431.51.20080131160038" + }, + "relatesTo": [ + { + "code": "appends", + "target": { + "identifier": { + "value": "1.2.840.317.5947431.51.20080131155715" + } + } + } + ], + "docStatus": "preliminary", + "status": "current" + }, + "request": { + "method": "PUT", + "url": "DocumentReference/0bd32673-66cf-0e3e-61df-803590588758" + } + }, + { + "fullUrl": "urn:uuid:4b1a16a4-4caa-c86f-791b-56cd3dcd5489", + "resource": { + "resourceType": "Practitioner", + "id": "4b1a16a4-4caa-c86f-791b-56cd3dcd5489", + "identifier": [ + { + "value": "IvanDoctorovich" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/4b1a16a4-4caa-c86f-791b-56cd3dcd5489" + } + }, + { + "fullUrl": "urn:uuid:5b91be6c-bce1-d67a-0ac5-3b0d36640a38", + "resource": { + "resourceType": "PractitionerRole", + "id": "5b91be6c-bce1-d67a-0ac5-3b0d36640a38", + "practitioner": { + "reference": "Practitioner/4b1a16a4-4caa-c86f-791b-56cd3dcd5489" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/5b91be6c-bce1-d67a-0ac5-3b0d36640a38" + } + }, + { + "fullUrl": "urn:uuid:01cd87ac-cb24-4ae6-239f-a3c355aafd49", + "resource": { + "resourceType": "ServiceRequest", + "id": "01cd87ac-cb24-4ae6-239f-a3c355aafd49", + "status": "active", + "intent": "order", + "identifier": [ + { + "value": "00012345", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "1-1", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "code": { + "coding": [ + { + "code": "02585", + "display": "TransthoracicEcho", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/PCV4" + } + ] + }, + "reasonCode": [ + { + "coding": [ + { + "code": "796.4", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/I9M" + } + ] + }, + { + "coding": [ + { + "code": "786.09", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/I9M" + } + ] + }, + { + "coding": [ + { + "code": "414.8", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/I9M" + } + ] + } + ], + "subject": { + "reference": "Patient/073b77fa-7722-30cf-cd8f-218a179da613" + }, + "reasonReference": [ + { + "reference": "DocumentReference/0bd32673-66cf-0e3e-61df-803590588758" + } + ], + "specimen": [ + { + "reference": "Specimen/c4e417ca-4a99-cb34-3d98-3f3ab1ae7363" + } + ], + "note": [ + { + "text": "No Antibodies Detected", + "time": "2020-10-10T18:15:00+05:30", + "authorReference": { + "reference": "Practitioner/ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2" + } + }, + { + "text": "Please follow the text instructions" + } + ], + "asNeededCodeableConcept": { + "text": "This is condition text" + }, + "quantityQuantity": { + "value": 54, + "unit": "lbs" + }, + "occurrenceTiming": { + "code": { + "coding": [ + { + "code": "ACM", + "display": "Before Breakfast", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/HL7xxx" + } + ] + }, + "repeat": { + "period": 12, + "periodUnit": "min", + "when": [ + "ACM" + ], + "offset": 2, + "boundsPeriod": { + "start": "2021-10-10T05:30:00+05:30", + "end": "2021-11-10T05:30:00+05:30" + }, + "duration": 2, + "durationUnit": "h", + "count": 5 + } + }, + "priority": "asap" + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/01cd87ac-cb24-4ae6-239f-a3c355aafd49" + } + }, + { + "fullUrl": "urn:uuid:ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2", + "resource": { + "resourceType": "Practitioner", + "id": "ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2", + "identifier": [ + { + "value": "MLEE" + } + ], + "name": [ + { + "family": "ATTEND", + "given": [ + "AARON", + "A" + ], + "suffix": [ + "MD" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2" + } + }, + { + "fullUrl": "urn:uuid:c4e417ca-4a99-cb34-3d98-3f3ab1ae7363", + "resource": { + "resourceType": "Specimen", + "id": "c4e417ca-4a99-cb34-3d98-3f3ab1ae7363", + "collection": { + "collectedDateTime": "2008-01-31T19:10:00+05:30" + }, + "identifier": [ + { + "value": "00012345", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "1-1", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Specimen/c4e417ca-4a99-cb34-3d98-3f3ab1ae7363" + } + }, + { + "fullUrl": "urn:uuid:ad3dd95e-23fb-17ca-7fa9-259b0939a4f4", + "resource": { + "resourceType": "ServiceRequest", + "id": "ad3dd95e-23fb-17ca-7fa9-259b0939a4f4", + "status": "active", + "intent": "order", + "identifier": [ + { + "value": "00012367", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "1-1", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "code": { + "coding": [ + { + "code": "02588", + "display": "3D echo cardigram", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/PCV4" + } + ] + }, + "reasonCode": [ + { + "coding": [ + { + "code": "796.4", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/I9M" + } + ] + }, + { + "coding": [ + { + "code": "786.09", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/I9M" + } + ] + }, + { + "coding": [ + { + "code": "414.8", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/I9M" + } + ] + } + ], + "subject": { + "reference": "Patient/073b77fa-7722-30cf-cd8f-218a179da613" + }, + "reasonReference": [ + { + "reference": "DocumentReference/0bd32673-66cf-0e3e-61df-803590588758" + } + ], + "specimen": [ + { + "reference": "Specimen/8544aeea-6c95-cc4e-9d21-19aa26595386" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/ad3dd95e-23fb-17ca-7fa9-259b0939a4f4" + } + }, + { + "fullUrl": "urn:uuid:8544aeea-6c95-cc4e-9d21-19aa26595386", + "resource": { + "resourceType": "Specimen", + "id": "8544aeea-6c95-cc4e-9d21-19aa26595386", + "collection": { + "collectedDateTime": "2008-01-31T20:00:00+05:30" + }, + "identifier": [ + { + "value": "00012367", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "1-1", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Specimen/8544aeea-6c95-cc4e-9d21-19aa26595386" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/MDM_T02/MDM-T02-01-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/MDM_T02/MDM-T02-01-expected.json new file mode 100644 index 000000000..fcf7e4c54 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/MDM_T02/MDM-T02-01-expected.json @@ -0,0 +1,871 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2008-01-31T19:15:00+05:30", + "identifier": { + "value": "PS1-20080131160038" + }, + "id": "c1cfc1cf-5772-3713-5eb2-0ffdca6df60b", + "entry": [ + { + "fullUrl": "urn:uuid:f6276090-3778-3e87-dab9-2c9dae838d1a", + "resource": { + "resourceType": "MessageHeader", + "id": "f6276090-3778-3e87-dab9-2c9dae838d1a", + "source": { + "name": "PROSOLV", + "_endpoint": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/data-absent-reason", + "valueCode": "unknown" + } + ] + } + }, + "destination": [ + { + "name": "SYSTEM", + "_endpoint": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/data-absent-reason", + "valueCode": "unknown" + } + ] + }, + "receiver": { + "reference": "Organization/a546f42b-2f91-c12a-4596-67ce49a595d9" + } + } + ], + "meta": { + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "T02", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "MDM^T02^MDM_T02" + }, + "sender": { + "reference": "Organization/a546f42b-2f91-c12a-4596-67ce49a595d9" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/f6276090-3778-3e87-dab9-2c9dae838d1a" + } + }, + { + "fullUrl": "urn:uuid:62e243a9-2299-8d17-3755-2ea9dcea5246", + "resource": { + "resourceType": "Provenance", + "id": "62e243a9-2299-8d17-3755-2ea9dcea5246", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T09:22:01.635Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: MDM_T02.

" + }, + "occurredDateTime": "2008-01-31T19:15:00+05:30", + "recorded": "2008-01-31T19:15:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/a546f42b-2f91-c12a-4596-67ce49a595d9" + } + } + ], + "activity": { + "coding": [ + { + "display": "MDM^T02^MDM_T02" + } + ] + }, + "target": [ + { + "reference": "Bundle/c1cfc1cf-5772-3713-5eb2-0ffdca6df60b" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/62e243a9-2299-8d17-3755-2ea9dcea5246" + } + }, + { + "fullUrl": "urn:uuid:a546f42b-2f91-c12a-4596-67ce49a595d9", + "resource": { + "resourceType": "Organization", + "id": "a546f42b-2f91-c12a-4596-67ce49a595d9", + "identifier": [ + { + "value": "XYZHOSPITAL", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-XYZHOSPITAL" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/a546f42b-2f91-c12a-4596-67ce49a595d9" + } + }, + { + "fullUrl": "urn:uuid:63520aa7-562e-9367-0c96-f8f720c3a418", + "resource": { + "resourceType": "Provenance", + "id": "63520aa7-562e-9367-0c96-f8f720c3a418", + "recorded": "2008-01-31T19:15:00+05:30", + "agent": [ + { + "who": { + "reference": "Practitioner/983f747a-cf80-25e8-0431-719272f56adf" + } + } + ], + "activity": { + "text": "MDM^T02^MDM_T02" + }, + "target": [ + { + "reference": "Bundle/c1cfc1cf-5772-3713-5eb2-0ffdca6df60b" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/63520aa7-562e-9367-0c96-f8f720c3a418" + } + }, + { + "fullUrl": "urn:uuid:983f747a-cf80-25e8-0431-719272f56adf", + "resource": { + "resourceType": "Practitioner", + "id": "983f747a-cf80-25e8-0431-719272f56adf", + "identifier": [ + { + "value": "C08" + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/983f747a-cf80-25e8-0431-719272f56adf" + } + }, + { + "fullUrl": "urn:uuid:073b77fa-7722-30cf-cd8f-218a179da613", + "resource": { + "resourceType": "Patient", + "id": "073b77fa-7722-30cf-cd8f-218a179da613", + "identifier": [ + { + "value": "987654321" + }, + { + "value": "987654321" + }, + { + "value": "111-22-3333", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + } + ], + "name": [ + { + "family": "PROSOLV", + "given": [ + "SAMPLE" + ] + } + ], + "birthDate": "1972-12-01", + "gender": "male" + }, + "request": { + "method": "PUT", + "url": "Patient/073b77fa-7722-30cf-cd8f-218a179da613" + } + }, + { + "fullUrl": "urn:uuid:53abf53e-4d5f-9ac3-01fc-1c57fbc8ff1b", + "resource": { + "resourceType": "Account", + "id": "53abf53e-4d5f-9ac3-01fc-1c57fbc8ff1b", + "identifier": [ + { + "value": "10000001" + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/073b77fa-7722-30cf-cd8f-218a179da613" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/53abf53e-4d5f-9ac3-01fc-1c57fbc8ff1b" + } + }, + { + "fullUrl": "urn:uuid:f91b9450-5b30-513c-e992-770d60ebccca", + "resource": { + "resourceType": "Practitioner", + "id": "f91b9450-5b30-513c-e992-770d60ebccca", + "identifier": [ + { + "value": "1234" + } + ], + "name": [ + { + "family": "HIPPOCRATES", + "given": [ + "KOS" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/f91b9450-5b30-513c-e992-770d60ebccca" + } + }, + { + "fullUrl": "urn:uuid:3ff52588-4f70-e5f9-bd2e-3ff770b6bc16", + "resource": { + "resourceType": "Practitioner", + "id": "3ff52588-4f70-e5f9-bd2e-3ff770b6bc16", + "identifier": [ + { + "value": "9099" + } + ], + "name": [ + { + "family": "KEVORKIAN", + "given": [ + "JACK" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/3ff52588-4f70-e5f9-bd2e-3ff770b6bc16" + } + }, + { + "fullUrl": "urn:uuid:39dfc508-b0aa-36f2-de51-5ff7aee0bc62", + "resource": { + "resourceType": "Practitioner", + "id": "39dfc508-b0aa-36f2-de51-5ff7aee0bc62", + "identifier": [ + { + "value": "8888" + } + ], + "name": [ + { + "family": "HOUSE", + "given": [ + "GREGORY" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/39dfc508-b0aa-36f2-de51-5ff7aee0bc62" + } + }, + { + "fullUrl": "urn:uuid:b4c8d42e-dbcb-9290-7593-7586f4b5d0c9", + "resource": { + "resourceType": "Location", + "id": "b4c8d42e-dbcb-9290-7593-7586f4b5d0c9", + "name": "CCU", + "mode": "instance", + "description": "CCU--2003--1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/b4c8d42e-dbcb-9290-7593-7586f4b5d0c9" + } + }, + { + "fullUrl": "urn:uuid:55fb6bcf-59d7-2cc4-2ddc-d38ba31ff1d2", + "resource": { + "resourceType": "Location", + "id": "55fb6bcf-59d7-2cc4-2ddc-d38ba31ff1d2", + "partOf": { + "reference": "Location/b4c8d42e-dbcb-9290-7593-7586f4b5d0c9" + }, + "name": "2000", + "mode": "instance", + "description": "CCU--2000--1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/55fb6bcf-59d7-2cc4-2ddc-d38ba31ff1d2" + } + }, + { + "fullUrl": "urn:uuid:b2d5327c-354a-b91d-541d-c6b0fe91a841", + "resource": { + "resourceType": "Location", + "id": "b2d5327c-354a-b91d-541d-c6b0fe91a841", + "partOf": { + "reference": "Location/66fd3f3f-1ed8-35f5-002d-40ca03271177" + }, + "name": "1", + "mode": "instance", + "description": "CCU--2003--1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/b2d5327c-354a-b91d-541d-c6b0fe91a841" + } + }, + { + "fullUrl": "urn:uuid:66fd3f3f-1ed8-35f5-002d-40ca03271177", + "resource": { + "resourceType": "Location", + "id": "66fd3f3f-1ed8-35f5-002d-40ca03271177", + "partOf": { + "reference": "Location/b4c8d42e-dbcb-9290-7593-7586f4b5d0c9" + }, + "name": "2003", + "mode": "instance", + "description": "CCU--2003--1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/66fd3f3f-1ed8-35f5-002d-40ca03271177" + } + }, + { + "fullUrl": "urn:uuid:8bc99636-4bdf-d4be-5661-f77f4f3a7ff6", + "resource": { + "resourceType": "Encounter", + "id": "8bc99636-4bdf-d4be-5661-f77f4f3a7ff6", + "class": { + "code": "IMP", + "display": "inpatient encounter", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "in-progress", + "location": [ + { + "status": "active", + "location": { + "reference": "Location/b4c8d42e-dbcb-9290-7593-7586f4b5d0c9" + } + }, + { + "status": "completed", + "location": { + "reference": "Location/b4c8d42e-dbcb-9290-7593-7586f4b5d0c9" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/f91b9450-5b30-513c-e992-770d60ebccca" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/3ff52588-4f70-e5f9-bd2e-3ff770b6bc16" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "CON", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "consultant" + } + ], + "individual": { + "reference": "Practitioner/39dfc508-b0aa-36f2-de51-5ff7aee0bc62" + } + } + ], + "identifier": [ + { + "value": "10000001", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + } + ], + "text": { + "status": "generated", + "div": "

Visit Description:

" + }, + "subject": { + "reference": "Patient/073b77fa-7722-30cf-cd8f-218a179da613" + } + }, + "request": { + "method": "PUT", + "url": "Encounter/8bc99636-4bdf-d4be-5661-f77f4f3a7ff6" + } + }, + { + "fullUrl": "urn:uuid:0bd32673-66cf-0e3e-61df-803590588758", + "resource": { + "resourceType": "DocumentReference", + "id": "0bd32673-66cf-0e3e-61df-803590588758", + "type": { + "coding": [ + { + "code": "DI" + } + ] + }, + "context": { + "period": { + "start": "2008-01-31T19:10:00+05:30" + } + }, + "content": [ + { + "attachment": { + "creation": "2008-01-31T19:15:00+05:30" + } + } + ], + "author": [ + { + "reference": "PractitionerRole/5b91be6c-bce1-d67a-0ac5-3b0d36640a38" + } + ], + "masterIdentifier": { + "value": "1.2.840.317.5947431.51.20080131160038" + }, + "relatesTo": [ + { + "code": "appends", + "target": { + "identifier": { + "value": "1.2.840.317.5947431.51.20080131155715" + } + } + } + ], + "docStatus": "preliminary", + "status": "current" + }, + "request": { + "method": "PUT", + "url": "DocumentReference/0bd32673-66cf-0e3e-61df-803590588758" + } + }, + { + "fullUrl": "urn:uuid:4b1a16a4-4caa-c86f-791b-56cd3dcd5489", + "resource": { + "resourceType": "Practitioner", + "id": "4b1a16a4-4caa-c86f-791b-56cd3dcd5489", + "identifier": [ + { + "value": "IvanDoctorovich" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/4b1a16a4-4caa-c86f-791b-56cd3dcd5489" + } + }, + { + "fullUrl": "urn:uuid:5b91be6c-bce1-d67a-0ac5-3b0d36640a38", + "resource": { + "resourceType": "PractitionerRole", + "id": "5b91be6c-bce1-d67a-0ac5-3b0d36640a38", + "practitioner": { + "reference": "Practitioner/4b1a16a4-4caa-c86f-791b-56cd3dcd5489" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/5b91be6c-bce1-d67a-0ac5-3b0d36640a38" + } + }, + { + "fullUrl": "urn:uuid:46cd7f69-a39b-fcb3-d2bd-2085cc2464cf", + "resource": { + "resourceType": "ServiceRequest", + "id": "46cd7f69-a39b-fcb3-d2bd-2085cc2464cf", + "status": "active", + "intent": "order", + "identifier": [ + { + "value": "00012345", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "1-1", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "code": { + "coding": [ + { + "code": "02585", + "display": "TransthoracicEcho", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/PCV4" + } + ] + }, + "reasonCode": [ + { + "coding": [ + { + "code": "796.4", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/I9M" + } + ] + }, + { + "coding": [ + { + "code": "786.09", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/I9M" + } + ] + }, + { + "coding": [ + { + "code": "414.8", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/I9M" + } + ] + } + ], + "subject": { + "reference": "Patient/073b77fa-7722-30cf-cd8f-218a179da613" + }, + "reasonReference": [ + { + "reference": "DocumentReference/0bd32673-66cf-0e3e-61df-803590588758" + } + ], + "specimen": [ + { + "reference": "Specimen/3edc5abd-8555-96fa-587b-9be9f1c7014c" + } + ], + "note": [ + { + "text": "No Antibodies Detected", + "time": "2020-10-10T18:15:00+05:30", + "authorReference": { + "reference": "Practitioner/ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2" + } + }, + { + "text": "Please follow the text instructions" + } + ], + "asNeededCodeableConcept": { + "text": "This is condition text" + }, + "quantityQuantity": { + "value": 54, + "unit": "lbs" + }, + "occurrenceTiming": { + "code": { + "coding": [ + { + "code": "ACM", + "display": "Before Breakfast", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/HL7xxx" + } + ] + }, + "repeat": { + "period": 12, + "periodUnit": "min", + "when": [ + "ACM" + ], + "offset": 2, + "boundsPeriod": { + "start": "2021-10-10T05:30:00+05:30", + "end": "2021-11-10T05:30:00+05:30" + }, + "duration": 2, + "durationUnit": "h", + "count": 5 + } + }, + "priority": "asap" + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/46cd7f69-a39b-fcb3-d2bd-2085cc2464cf" + } + }, + { + "fullUrl": "urn:uuid:ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2", + "resource": { + "resourceType": "Practitioner", + "id": "ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2", + "identifier": [ + { + "value": "MLEE" + } + ], + "name": [ + { + "family": "ATTEND", + "given": [ + "AARON", + "A" + ], + "suffix": [ + "MD" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2" + } + }, + { + "fullUrl": "urn:uuid:3edc5abd-8555-96fa-587b-9be9f1c7014c", + "resource": { + "resourceType": "Specimen", + "id": "3edc5abd-8555-96fa-587b-9be9f1c7014c", + "collection": { + "collectedDateTime": "2008-01-31T19:10:00+05:30" + }, + "identifier": [ + { + "value": "00012345", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "1-1", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Specimen/3edc5abd-8555-96fa-587b-9be9f1c7014c" + } + }, + { + "fullUrl": "urn:uuid:0f41f515-1c27-f9b4-2fcf-13ee831aeae1", + "resource": { + "resourceType": "Observation", + "id": "0f41f515-1c27-f9b4-2fcf-13ee831aeae1", + "status": "unknown", + "code": { + "coding": [ + { + "code": "113014", + "display": "DICOM Study", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/DCM" + } + ] + }, + "subject": { + "reference": "Patient/073b77fa-7722-30cf-cd8f-218a179da613" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "O", + "display": "Order Detail", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Order Detail" + } + } + ], + "note": [ + { + "text": "Antibodies Detected", + "time": "2020-10-10T18:15:00+05:30", + "authorReference": { + "reference": "Practitioner/ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/0f41f515-1c27-f9b4-2fcf-13ee831aeae1" + } + }, + { + "fullUrl": "urn:uuid:f4a5fc23-084d-c558-a3e2-63fbe9d216d7", + "resource": { + "resourceType": "DiagnosticReport", + "id": "f4a5fc23-084d-c558-a3e2-63fbe9d216d7", + "code": { + "coding": [ + { + "code": "02585", + "display": "TransthoracicEcho", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/PCV4" + } + ] + }, + "status": "unknown", + "presentedForm": [ + { + "contentType": "application/pdf" + } + ], + "subject": { + "reference": "Patient/073b77fa-7722-30cf-cd8f-218a179da613" + } + }, + "request": { + "method": "PUT", + "url": "DiagnosticReport/f4a5fc23-084d-c558-a3e2-63fbe9d216d7" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/MDM_T02/MDM-T02-02-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/MDM_T02/MDM-T02-02-expected.json new file mode 100644 index 000000000..d41a283b5 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/MDM_T02/MDM-T02-02-expected.json @@ -0,0 +1,1029 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2008-01-31T19:15:00+05:30", + "identifier": { + "value": "PS1-20080131160038" + }, + "id": "c1cfc1cf-5772-3713-5eb2-0ffdca6df60b", + "entry": [ + { + "fullUrl": "urn:uuid:f6276090-3778-3e87-dab9-2c9dae838d1a", + "resource": { + "resourceType": "MessageHeader", + "id": "f6276090-3778-3e87-dab9-2c9dae838d1a", + "source": { + "name": "PROSOLV", + "_endpoint": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/data-absent-reason", + "valueCode": "unknown" + } + ] + }, + "version": "2.4.3.52854", + "software": "Rhapsody" + }, + "destination": [ + { + "name": "SYSTEM", + "_endpoint": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/data-absent-reason", + "valueCode": "unknown" + } + ] + }, + "receiver": { + "reference": "Organization/a546f42b-2f91-c12a-4596-67ce49a595d9" + } + } + ], + "meta": { + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "T02", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "MDM^T02^MDM_T02" + }, + "sender": { + "reference": "Organization/a546f42b-2f91-c12a-4596-67ce49a595d9" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/f6276090-3778-3e87-dab9-2c9dae838d1a" + } + }, + { + "fullUrl": "urn:uuid:62e243a9-2299-8d17-3755-2ea9dcea5246", + "resource": { + "resourceType": "Provenance", + "id": "62e243a9-2299-8d17-3755-2ea9dcea5246", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T09:22:23.425Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: MDM_T02.

" + }, + "occurredDateTime": "2008-01-31T19:15:00+05:30", + "recorded": "2008-01-31T19:15:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/a546f42b-2f91-c12a-4596-67ce49a595d9" + } + } + ], + "activity": { + "coding": [ + { + "display": "MDM^T02^MDM_T02" + } + ] + }, + "target": [ + { + "reference": "Bundle/c1cfc1cf-5772-3713-5eb2-0ffdca6df60b" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/62e243a9-2299-8d17-3755-2ea9dcea5246" + } + }, + { + "fullUrl": "urn:uuid:a546f42b-2f91-c12a-4596-67ce49a595d9", + "resource": { + "resourceType": "Organization", + "id": "a546f42b-2f91-c12a-4596-67ce49a595d9", + "identifier": [ + { + "value": "XYZHOSPITAL", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-XYZHOSPITAL" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/a546f42b-2f91-c12a-4596-67ce49a595d9" + } + }, + { + "fullUrl": "urn:uuid:4b549918-a84d-cdaf-e150-c773a5d306e5", + "resource": { + "resourceType": "Device", + "id": "4b549918-a84d-cdaf-e150-c773a5d306e5", + "manufacturer": "Orion", + "deviceName": [ + { + "name": "Rhapsody", + "type": "manufacturer-name" + } + ], + "version": [ + { + "value": "2.4.3.52854" + } + ], + "modelNumber": "2.4.3", + "note": [ + { + "text": "Testactivity" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/4b549918-a84d-cdaf-e150-c773a5d306e5" + } + }, + { + "fullUrl": "urn:uuid:63520aa7-562e-9367-0c96-f8f720c3a418", + "resource": { + "resourceType": "Provenance", + "id": "63520aa7-562e-9367-0c96-f8f720c3a418", + "recorded": "2008-01-31T19:15:00+05:30", + "agent": [ + { + "who": { + "reference": "Practitioner/983f747a-cf80-25e8-0431-719272f56adf" + } + } + ], + "activity": { + "text": "MDM^T02^MDM_T02" + }, + "target": [ + { + "reference": "Bundle/c1cfc1cf-5772-3713-5eb2-0ffdca6df60b" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/63520aa7-562e-9367-0c96-f8f720c3a418" + } + }, + { + "fullUrl": "urn:uuid:983f747a-cf80-25e8-0431-719272f56adf", + "resource": { + "resourceType": "Practitioner", + "id": "983f747a-cf80-25e8-0431-719272f56adf", + "identifier": [ + { + "value": "C08" + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/983f747a-cf80-25e8-0431-719272f56adf" + } + }, + { + "fullUrl": "urn:uuid:073b77fa-7722-30cf-cd8f-218a179da613", + "resource": { + "resourceType": "Patient", + "id": "073b77fa-7722-30cf-cd8f-218a179da613", + "identifier": [ + { + "value": "987654321" + }, + { + "value": "987654321" + }, + { + "value": "111-22-3333", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + } + ], + "name": [ + { + "family": "PROSOLV", + "given": [ + "SAMPLE" + ] + } + ], + "birthDate": "1972-12-01", + "gender": "male" + }, + "request": { + "method": "PUT", + "url": "Patient/073b77fa-7722-30cf-cd8f-218a179da613" + } + }, + { + "fullUrl": "urn:uuid:53abf53e-4d5f-9ac3-01fc-1c57fbc8ff1b", + "resource": { + "resourceType": "Account", + "id": "53abf53e-4d5f-9ac3-01fc-1c57fbc8ff1b", + "identifier": [ + { + "value": "10000001" + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/073b77fa-7722-30cf-cd8f-218a179da613" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/53abf53e-4d5f-9ac3-01fc-1c57fbc8ff1b" + } + }, + { + "fullUrl": "urn:uuid:f91b9450-5b30-513c-e992-770d60ebccca", + "resource": { + "resourceType": "Practitioner", + "id": "f91b9450-5b30-513c-e992-770d60ebccca", + "identifier": [ + { + "value": "1234" + } + ], + "name": [ + { + "family": "HIPPOCRATES", + "given": [ + "KOS" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/f91b9450-5b30-513c-e992-770d60ebccca" + } + }, + { + "fullUrl": "urn:uuid:3ff52588-4f70-e5f9-bd2e-3ff770b6bc16", + "resource": { + "resourceType": "Practitioner", + "id": "3ff52588-4f70-e5f9-bd2e-3ff770b6bc16", + "identifier": [ + { + "value": "9099" + } + ], + "name": [ + { + "family": "KEVORKIAN", + "given": [ + "JACK" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/3ff52588-4f70-e5f9-bd2e-3ff770b6bc16" + } + }, + { + "fullUrl": "urn:uuid:39dfc508-b0aa-36f2-de51-5ff7aee0bc62", + "resource": { + "resourceType": "Practitioner", + "id": "39dfc508-b0aa-36f2-de51-5ff7aee0bc62", + "identifier": [ + { + "value": "8888" + } + ], + "name": [ + { + "family": "HOUSE", + "given": [ + "GREGORY" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/39dfc508-b0aa-36f2-de51-5ff7aee0bc62" + } + }, + { + "fullUrl": "urn:uuid:b4c8d42e-dbcb-9290-7593-7586f4b5d0c9", + "resource": { + "resourceType": "Location", + "id": "b4c8d42e-dbcb-9290-7593-7586f4b5d0c9", + "name": "CCU", + "mode": "instance", + "description": "CCU--2003--1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/b4c8d42e-dbcb-9290-7593-7586f4b5d0c9" + } + }, + { + "fullUrl": "urn:uuid:55fb6bcf-59d7-2cc4-2ddc-d38ba31ff1d2", + "resource": { + "resourceType": "Location", + "id": "55fb6bcf-59d7-2cc4-2ddc-d38ba31ff1d2", + "partOf": { + "reference": "Location/b4c8d42e-dbcb-9290-7593-7586f4b5d0c9" + }, + "name": "2000", + "mode": "instance", + "description": "CCU--2000--1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/55fb6bcf-59d7-2cc4-2ddc-d38ba31ff1d2" + } + }, + { + "fullUrl": "urn:uuid:b2d5327c-354a-b91d-541d-c6b0fe91a841", + "resource": { + "resourceType": "Location", + "id": "b2d5327c-354a-b91d-541d-c6b0fe91a841", + "partOf": { + "reference": "Location/66fd3f3f-1ed8-35f5-002d-40ca03271177" + }, + "name": "1", + "mode": "instance", + "description": "CCU--2003--1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/b2d5327c-354a-b91d-541d-c6b0fe91a841" + } + }, + { + "fullUrl": "urn:uuid:66fd3f3f-1ed8-35f5-002d-40ca03271177", + "resource": { + "resourceType": "Location", + "id": "66fd3f3f-1ed8-35f5-002d-40ca03271177", + "partOf": { + "reference": "Location/b4c8d42e-dbcb-9290-7593-7586f4b5d0c9" + }, + "name": "2003", + "mode": "instance", + "description": "CCU--2003--1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/66fd3f3f-1ed8-35f5-002d-40ca03271177" + } + }, + { + "fullUrl": "urn:uuid:8bc99636-4bdf-d4be-5661-f77f4f3a7ff6", + "resource": { + "resourceType": "Encounter", + "id": "8bc99636-4bdf-d4be-5661-f77f4f3a7ff6", + "class": { + "code": "IMP", + "display": "inpatient encounter", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "in-progress", + "location": [ + { + "status": "active", + "location": { + "reference": "Location/b4c8d42e-dbcb-9290-7593-7586f4b5d0c9" + } + }, + { + "status": "completed", + "location": { + "reference": "Location/b4c8d42e-dbcb-9290-7593-7586f4b5d0c9" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/f91b9450-5b30-513c-e992-770d60ebccca" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/3ff52588-4f70-e5f9-bd2e-3ff770b6bc16" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "CON", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "consultant" + } + ], + "individual": { + "reference": "Practitioner/39dfc508-b0aa-36f2-de51-5ff7aee0bc62" + } + } + ], + "identifier": [ + { + "value": "10000001", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + } + ], + "text": { + "status": "generated", + "div": "

Visit Description:

" + }, + "subject": { + "reference": "Patient/073b77fa-7722-30cf-cd8f-218a179da613" + } + }, + "request": { + "method": "PUT", + "url": "Encounter/8bc99636-4bdf-d4be-5661-f77f4f3a7ff6" + } + }, + { + "fullUrl": "urn:uuid:0bd32673-66cf-0e3e-61df-803590588758", + "resource": { + "resourceType": "DocumentReference", + "id": "0bd32673-66cf-0e3e-61df-803590588758", + "type": { + "coding": [ + { + "code": "DI" + } + ] + }, + "context": { + "period": { + "start": "2008-01-31T19:10:00+05:30" + } + }, + "content": [ + { + "attachment": { + "creation": "2008-01-31T19:15:00+05:30" + } + } + ], + "author": [ + { + "reference": "PractitionerRole/5b91be6c-bce1-d67a-0ac5-3b0d36640a38" + } + ], + "masterIdentifier": { + "value": "1.2.840.317.5947431.51.20080131160038" + }, + "relatesTo": [ + { + "code": "appends", + "target": { + "identifier": { + "value": "1.2.840.317.5947431.51.20080131155715" + } + } + } + ], + "docStatus": "preliminary", + "status": "current" + }, + "request": { + "method": "PUT", + "url": "DocumentReference/0bd32673-66cf-0e3e-61df-803590588758" + } + }, + { + "fullUrl": "urn:uuid:4b1a16a4-4caa-c86f-791b-56cd3dcd5489", + "resource": { + "resourceType": "Practitioner", + "id": "4b1a16a4-4caa-c86f-791b-56cd3dcd5489", + "identifier": [ + { + "value": "IvanDoctorovich" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/4b1a16a4-4caa-c86f-791b-56cd3dcd5489" + } + }, + { + "fullUrl": "urn:uuid:5b91be6c-bce1-d67a-0ac5-3b0d36640a38", + "resource": { + "resourceType": "PractitionerRole", + "id": "5b91be6c-bce1-d67a-0ac5-3b0d36640a38", + "practitioner": { + "reference": "Practitioner/4b1a16a4-4caa-c86f-791b-56cd3dcd5489" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/5b91be6c-bce1-d67a-0ac5-3b0d36640a38" + } + }, + { + "fullUrl": "urn:uuid:01cd87ac-cb24-4ae6-239f-a3c355aafd49", + "resource": { + "resourceType": "ServiceRequest", + "id": "01cd87ac-cb24-4ae6-239f-a3c355aafd49", + "status": "active", + "intent": "order", + "identifier": [ + { + "value": "00012345", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "1-1", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "code": { + "coding": [ + { + "code": "02585", + "display": "TransthoracicEcho", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/PCV4" + } + ] + }, + "reasonCode": [ + { + "coding": [ + { + "code": "796.4", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/I9M" + } + ] + }, + { + "coding": [ + { + "code": "786.09", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/I9M" + } + ] + }, + { + "coding": [ + { + "code": "414.8", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/I9M" + } + ] + } + ], + "subject": { + "reference": "Patient/073b77fa-7722-30cf-cd8f-218a179da613" + }, + "reasonReference": [ + { + "reference": "DocumentReference/0bd32673-66cf-0e3e-61df-803590588758" + } + ], + "specimen": [ + { + "reference": "Specimen/c4e417ca-4a99-cb34-3d98-3f3ab1ae7363" + } + ], + "note": [ + { + "text": "No Antibodies Detected", + "time": "2020-10-10T18:15:00+05:30", + "authorReference": { + "reference": "Practitioner/ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2" + } + }, + { + "text": "Please follow the text instructions" + } + ], + "asNeededCodeableConcept": { + "text": "This is condition text" + }, + "quantityQuantity": { + "value": 54, + "unit": "lbs" + }, + "occurrenceTiming": { + "code": { + "coding": [ + { + "code": "ACM", + "display": "Before Breakfast", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/HL7xxx" + } + ] + }, + "repeat": { + "period": 12, + "periodUnit": "min", + "when": [ + "ACM" + ], + "offset": 2, + "boundsPeriod": { + "start": "2021-10-10T05:30:00+05:30", + "end": "2021-11-10T05:30:00+05:30" + }, + "duration": 2, + "durationUnit": "h", + "count": 5 + } + }, + "priority": "asap" + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/01cd87ac-cb24-4ae6-239f-a3c355aafd49" + } + }, + { + "fullUrl": "urn:uuid:ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2", + "resource": { + "resourceType": "Practitioner", + "id": "ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2", + "identifier": [ + { + "value": "MLEE" + } + ], + "name": [ + { + "family": "ATTEND", + "given": [ + "AARON", + "A" + ], + "suffix": [ + "MD" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2" + } + }, + { + "fullUrl": "urn:uuid:c4e417ca-4a99-cb34-3d98-3f3ab1ae7363", + "resource": { + "resourceType": "Specimen", + "id": "c4e417ca-4a99-cb34-3d98-3f3ab1ae7363", + "collection": { + "collectedDateTime": "2008-01-31T19:10:00+05:30" + }, + "identifier": [ + { + "value": "00012345", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "1-1", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Specimen/c4e417ca-4a99-cb34-3d98-3f3ab1ae7363" + } + }, + { + "fullUrl": "urn:uuid:7b7dd544-782a-d161-1dfe-f5045df43351", + "resource": { + "resourceType": "ServiceRequest", + "id": "7b7dd544-782a-d161-1dfe-f5045df43351", + "status": "active", + "intent": "order", + "identifier": [ + { + "value": "00012367", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "1-1", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "code": { + "coding": [ + { + "code": "02588", + "display": "3D echo cardigram", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/PCV4" + } + ] + }, + "reasonCode": [ + { + "coding": [ + { + "code": "796.4", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/I9M" + } + ] + }, + { + "coding": [ + { + "code": "786.09", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/I9M" + } + ] + }, + { + "coding": [ + { + "code": "414.8", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/I9M" + } + ] + } + ], + "subject": { + "reference": "Patient/073b77fa-7722-30cf-cd8f-218a179da613" + }, + "reasonReference": [ + { + "reference": "DocumentReference/0bd32673-66cf-0e3e-61df-803590588758" + } + ], + "specimen": [ + { + "reference": "Specimen/1d8f51a2-c6cd-d6e0-de4f-c0158d668302" + } + ], + "occurrenceDateTime": "2006-01-31T20:00:00+05:30" + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/7b7dd544-782a-d161-1dfe-f5045df43351" + } + }, + { + "fullUrl": "urn:uuid:1d8f51a2-c6cd-d6e0-de4f-c0158d668302", + "resource": { + "resourceType": "Specimen", + "id": "1d8f51a2-c6cd-d6e0-de4f-c0158d668302", + "collection": { + "collectedDateTime": "2008-01-31T20:00:00+05:30" + }, + "identifier": [ + { + "value": "00012367", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "1-1", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Specimen/1d8f51a2-c6cd-d6e0-de4f-c0158d668302" + } + }, + { + "fullUrl": "urn:uuid:6ffcb8b5-5f1d-5d1f-8c4f-26b23a7dfd69", + "resource": { + "resourceType": "Observation", + "id": "6ffcb8b5-5f1d-5d1f-8c4f-26b23a7dfd69", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Toilet cylinder crackers model step-mother visor opening communication", + "subject": { + "reference": "Patient/073b77fa-7722-30cf-cd8f-218a179da613" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/6ffcb8b5-5f1d-5d1f-8c4f-26b23a7dfd69" + } + }, + { + "fullUrl": "urn:uuid:66fb85aa-6c70-58f5-fadc-c8d270c76ead", + "resource": { + "resourceType": "Observation", + "id": "66fb85aa-6c70-58f5-fadc-c8d270c76ead", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Columnist draft inn brown income ikebana circulation prince", + "subject": { + "reference": "Patient/073b77fa-7722-30cf-cd8f-218a179da613" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/66fb85aa-6c70-58f5-fadc-c8d270c76ead" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/MDM_T02/MDM-T02-03-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/MDM_T02/MDM-T02-03-expected.json new file mode 100644 index 000000000..8d47eb3c0 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/MDM_T02/MDM-T02-03-expected.json @@ -0,0 +1,1989 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2021-08-01T12:21:42+05:30", + "identifier": { + "value": "112" + }, + "id": "b37272c1-881a-0cf2-1120-5ab37ceaf698", + "entry": [ + { + "fullUrl": "urn:uuid:0bd7a2a5-cdc4-50f4-5b85-da3c58cfba27", + "resource": { + "resourceType": "MessageHeader", + "id": "0bd7a2a5-cdc4-50f4-5b85-da3c58cfba27", + "source": { + "name": "SIMHOSP", + "_endpoint": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/data-absent-reason", + "valueCode": "unknown" + } + ] + } + }, + "destination": [ + { + "name": "RAPP", + "_endpoint": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/data-absent-reason", + "valueCode": "unknown" + } + ] + }, + "receiver": { + "reference": "Organization/ab0676d9-fa24-ffd3-327d-f5b4c26ae628" + } + } + ], + "meta": { + "tag": [ + { + "code": "T", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "T02", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "MDM^T02^MDM_T02" + }, + "sender": { + "reference": "Organization/33e23f3e-47b2-9c1b-c1f0-f964c2d28946" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/0bd7a2a5-cdc4-50f4-5b85-da3c58cfba27" + } + }, + { + "fullUrl": "urn:uuid:ff198209-2ee9-a32c-124f-d63637240f8d", + "resource": { + "resourceType": "Provenance", + "id": "ff198209-2ee9-a32c-124f-d63637240f8d", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T09:22:44.962Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: MDM_T02.

" + }, + "occurredDateTime": "2021-08-01T12:21:42+05:30", + "recorded": "2021-08-01T12:21:42+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33e23f3e-47b2-9c1b-c1f0-f964c2d28946" + } + } + ], + "activity": { + "coding": [ + { + "display": "MDM^T02^MDM_T02" + } + ] + }, + "target": [ + { + "reference": "Bundle/b37272c1-881a-0cf2-1120-5ab37ceaf698" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/ff198209-2ee9-a32c-124f-d63637240f8d" + } + }, + { + "fullUrl": "urn:uuid:33e23f3e-47b2-9c1b-c1f0-f964c2d28946", + "resource": { + "resourceType": "Organization", + "id": "33e23f3e-47b2-9c1b-c1f0-f964c2d28946", + "identifier": [ + { + "value": "SFAC", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-SFAC" + } + ], + "address": [ + { + "country": "44" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/33e23f3e-47b2-9c1b-c1f0-f964c2d28946" + } + }, + { + "fullUrl": "urn:uuid:ab0676d9-fa24-ffd3-327d-f5b4c26ae628", + "resource": { + "resourceType": "Organization", + "id": "ab0676d9-fa24-ffd3-327d-f5b4c26ae628", + "identifier": [ + { + "value": "RFAC", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-RFAC" + } + ], + "address": [ + { + "country": "44" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/ab0676d9-fa24-ffd3-327d-f5b4c26ae628" + } + }, + { + "fullUrl": "urn:uuid:e7af414f-7873-8d60-ad37-fd7560092849", + "resource": { + "resourceType": "Provenance", + "id": "e7af414f-7873-8d60-ad37-fd7560092849", + "recorded": "2021-08-01T12:21:42+05:30", + "agent": [ + { + "who": { + "reference": "Practitioner/3a4c8c23-ae16-bb6c-7a8c-897b3043248b" + } + } + ], + "activity": { + "text": "MDM^T02^MDM_T02" + }, + "target": [ + { + "reference": "Bundle/b37272c1-881a-0cf2-1120-5ab37ceaf698" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/e7af414f-7873-8d60-ad37-fd7560092849" + } + }, + { + "fullUrl": "urn:uuid:3a4c8c23-ae16-bb6c-7a8c-897b3043248b", + "resource": { + "resourceType": "Practitioner", + "id": "3a4c8c23-ae16-bb6c-7a8c-897b3043248b", + "identifier": [ + { + "value": "C006", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-DRNBR", + "type": { + "coding": [ + { + "code": "ORGDR", + "display": "ORGDR" + } + ] + } + } + ], + "name": [ + { + "family": "Woolfson", + "given": [ + "Kathleen" + ], + "prefix": [ + "Dr" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/3a4c8c23-ae16-bb6c-7a8c-897b3043248b" + } + }, + { + "fullUrl": "urn:uuid:a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e", + "resource": { + "resourceType": "Patient", + "id": "a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e", + "identifier": [ + { + "value": "3196695816", + "type": { + "coding": [ + { + "code": "MRN", + "display": "MRN" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-SIMULATOR-MRN" + }, + { + "value": "3196695816", + "type": { + "coding": [ + { + "code": "MRN", + "display": "MRN" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-SIMULATOR-MRN" + }, + { + "value": "6597923189", + "type": { + "coding": [ + { + "code": "NHSNMBR", + "display": "NHSNMBR" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NHSNBR" + } + ], + "name": [ + { + "family": "Clark", + "given": [ + "Frederick" + ], + "prefix": [ + "Mr" + ] + } + ], + "birthDate": "1930-01-22", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1930-01-22T03:15:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "19 Blocker House", + "Restaurant Square" + ], + "city": "Ilford", + "postalCode": "WI3 7KU", + "country": "GBR" + } + ], + "telecom": [ + { + "value": "073 0075 3040", + "system": "phone" + } + ], + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "A", + "display": "White - British" + } + }, + { + "url": "text", + "valueString": "A" + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + } + }, + { + "fullUrl": "urn:uuid:635008fa-3d98-895d-90b3-ec0d2efa5f0f", + "resource": { + "resourceType": "Encounter", + "id": "635008fa-3d98-895d-90b3-ec0d2efa5f0f", + "class": { + "code": "AMB", + "display": "ambulatory", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "in-progress", + "type": [ + { + "coding": [ + { + "code": "28b", + "display": "28b" + } + ] + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/3a4c8c23-ae16-bb6c-7a8c-897b3043248b" + } + } + ], + "serviceType": { + "coding": [ + { + "code": "MED" + } + ] + }, + "text": { + "status": "generated", + "div": "

Visit Description:

" + }, + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + } + }, + "request": { + "method": "PUT", + "url": "Encounter/635008fa-3d98-895d-90b3-ec0d2efa5f0f" + } + }, + { + "fullUrl": "urn:uuid:ba02f303-e848-5771-d742-0de5371b5be4", + "resource": { + "resourceType": "DocumentReference", + "id": "ba02f303-e848-5771-d742-0de5371b5be4", + "type": { + "coding": [ + { + "code": "DS" + } + ] + }, + "context": { + "period": { + "start": "2021-08-01T12:21:42+05:30" + }, + "related": [ + { + "reference": "Practitioner/3a4c8c23-ae16-bb6c-7a8c-897b3043248b" + } + ] + }, + "content": [ + { + "attachment": { + "creation": "2021-08-03T03:15:00+05:30" + } + } + ], + "meta": { + "lastUpdated": "2021-08-01T12:21:42+05:30" + }, + "masterIdentifier": { + "value": "2RWRVAJ627408" + }, + "docStatus": "preliminary", + "status": "current" + }, + "request": { + "method": "PUT", + "url": "DocumentReference/ba02f303-e848-5771-d742-0de5371b5be4" + } + }, + { + "fullUrl": "urn:uuid:cb755da5-d1d4-2d4f-0f4d-363679151ac4", + "resource": { + "resourceType": "ServiceRequest", + "id": "cb755da5-d1d4-2d4f-0f4d-363679151ac4", + "status": "active", + "intent": "reflex-order", + "orderDetail": [ + { + "coding": [ + { + "code": "PSS-46", + "display": "Placer service", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + }, + { + "coding": [ + { + "code": "FSS-47", + "display": "Filler service", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "identifier": [ + { + "value": "845439", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHH-OE", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "986", + "system": "urn:oid:2.16.840.1.114222.4.3.3.5.1.2", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "PGN-04", + "type": { + "coding": [ + { + "code": "PGN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "APON-53", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "authoredOn": "2020-09-10T20:15:00+05:30", + "basedOn": [ + { + "reference": "ServiceRequest/29acd79b-adef-1dc7-6103-c65783a04bbb" + } + ], + "locationCode": [ + { + "coding": [ + { + "code": "BLB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + } + ] + }, + { + "coding": [ + { + "code": "OF", + "display": "Outpatient facility", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "note": [ + { + "text": "Placer 1", + "authorString": "Placer Field 1" + }, + { + "text": "Placer 2", + "authorString": "Placer Field 2" + }, + { + "text": "Filler 1", + "authorString": "Filler Field 1" + }, + { + "text": "Filler 2", + "authorString": "Filler Field 2" + } + ], + "priority": "routine", + "code": { + "coding": [ + { + "code": "625-4", + "display": "Bacteria identified in Stool by Culture", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/XYZ", + "version": "2.33" + } + ], + "text": "Enteric Culture" + }, + "reasonCode": [ + { + "coding": [ + { + "code": "444", + "display": "HIPPOCRATES", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/HOWARD-H", + "version": "MD" + } + ] + } + ], + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "reasonReference": [ + { + "reference": "DocumentReference/ba02f303-e848-5771-d742-0de5371b5be4" + } + ], + "requester": { + "reference": "PractitionerRole/beeb9a6e-29ec-7926-4f50-287c7ce3a1f5" + }, + "specimen": [ + { + "reference": "Specimen/2cb11a40-e62b-7255-c309-1dd5b722b803" + } + ], + "occurrenceDateTime": "2020-10-10T20:15:00+05:30" + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/cb755da5-d1d4-2d4f-0f4d-363679151ac4" + } + }, + { + "fullUrl": "urn:uuid:58e7269f-6c76-d387-8454-ff4b18a7fccd", + "resource": { + "resourceType": "Organization", + "id": "58e7269f-6c76-d387-8454-ff4b18a7fccd", + "name": "MISSOURI DEPARTMENT OF HEALTH LABORATORY - MISSOURI DEPARTMENT OF HEALTH LABORATORY", + "address": [ + { + "line": [ + "307 W MCCARTY ST" + ], + "city": "JEFFERSON CITY", + "state": "MO", + "postalCode": "65101", + "country": "USA", + "use": "work" + } + ], + "contact": [ + { + "telecom": [ + { + "use": "work", + "system": "phone" + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/58e7269f-6c76-d387-8454-ff4b18a7fccd" + } + }, + { + "fullUrl": "urn:uuid:beeb9a6e-29ec-7926-4f50-287c7ce3a1f5", + "resource": { + "resourceType": "PractitionerRole", + "id": "beeb9a6e-29ec-7926-4f50-287c7ce3a1f5", + "organization": { + "reference": "Organization/58e7269f-6c76-d387-8454-ff4b18a7fccd" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/beeb9a6e-29ec-7926-4f50-287c7ce3a1f5" + } + }, + { + "fullUrl": "urn:uuid:29acd79b-adef-1dc7-6103-c65783a04bbb", + "resource": { + "resourceType": "ServiceRequest", + "id": "29acd79b-adef-1dc7-6103-c65783a04bbb", + "identifier": [ + { + "value": "PAI-29", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "type": { + "coding": [ + { + "code": "50", + "display": "11.22", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/AR" + } + ] + } + } + ], + "status": "active", + "intent": "reflex-order", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + } + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/29acd79b-adef-1dc7-6103-c65783a04bbb" + } + }, + { + "fullUrl": "urn:uuid:2cb11a40-e62b-7255-c309-1dd5b722b803", + "resource": { + "resourceType": "Specimen", + "id": "2cb11a40-e62b-7255-c309-1dd5b722b803", + "collection": { + "quantity": { + "value": 150, + "unit": "lb" + }, + "collector": { + "reference": "PractitionerRole/9f64bd3b-d5e9-678b-2f14-b0d756a4e7f1" + }, + "bodySite": { + "coding": [ + { + "code": "BN", + "display": "223.3", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + }, + "method": { + "text": "Collection Method" + }, + "collectedDateTime": "2002-02-15T10:45:00+05:30" + }, + "receivedTime": "2002-02-12T10:45:00+05:30", + "identifier": [ + { + "value": "845439", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHH-OE", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "986", + "system": "urn:oid:2.16.840.1.114222.4.3.3.5.1.2", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "APON-53", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "type": { + "coding": [ + { + "code": "SP15", + "display": "1.2", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + }, + "container": [ + { + "additiveCodeableConcept": { + "coding": [ + { + "code": "ACDA" + } + ] + } + } + ], + "note": [ + { + "text": "Collector's comment" + } + ] + }, + "request": { + "method": "PUT", + "url": "Specimen/2cb11a40-e62b-7255-c309-1dd5b722b803" + } + }, + { + "fullUrl": "urn:uuid:ae62dffe-1a0f-c68b-e7a3-e33cfce7761e", + "resource": { + "resourceType": "Practitioner", + "id": "ae62dffe-1a0f-c68b-e7a3-e33cfce7761e", + "identifier": [ + { + "value": "10535", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-L", + "type": { + "coding": [ + { + "code": "MR", + "display": "Medical record number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "van Beethoven", + "given": [ + "Ludwig", + "A" + ], + "suffix": [ + "III", + "PHD" + ], + "prefix": [ + "Dr" + ], + "use": "official" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/ae62dffe-1a0f-c68b-e7a3-e33cfce7761e" + } + }, + { + "fullUrl": "urn:uuid:9f64bd3b-d5e9-678b-2f14-b0d756a4e7f1", + "resource": { + "resourceType": "PractitionerRole", + "id": "9f64bd3b-d5e9-678b-2f14-b0d756a4e7f1", + "practitioner": { + "reference": "Practitioner/ae62dffe-1a0f-c68b-e7a3-e33cfce7761e" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/9f64bd3b-d5e9-678b-2f14-b0d756a4e7f1" + } + }, + { + "fullUrl": "urn:uuid:83cf5a63-9c84-2fa8-884b-1886e9526fd8", + "resource": { + "resourceType": "Observation", + "id": "83cf5a63-9c84-2fa8-884b-1886e9526fd8", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Toilet cylinder crackers model step-mother visor opening communication", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/83cf5a63-9c84-2fa8-884b-1886e9526fd8" + } + }, + { + "fullUrl": "urn:uuid:8485edc6-008c-2b01-b26f-a2af596d30b5", + "resource": { + "resourceType": "Observation", + "id": "8485edc6-008c-2b01-b26f-a2af596d30b5", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Columnist draft inn brown income ikebana circulation prince", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/8485edc6-008c-2b01-b26f-a2af596d30b5" + } + }, + { + "fullUrl": "urn:uuid:c6a42129-232f-3242-4739-73141d3e0c22", + "resource": { + "resourceType": "Observation", + "id": "c6a42129-232f-3242-4739-73141d3e0c22", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Taxicab creator film therapist shelter", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/c6a42129-232f-3242-4739-73141d3e0c22" + } + }, + { + "fullUrl": "urn:uuid:1cd484ad-c654-fbaf-1242-d5c6addb1285", + "resource": { + "resourceType": "Observation", + "id": "1cd484ad-c654-fbaf-1242-d5c6addb1285", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Naming grandmother ruth", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/1cd484ad-c654-fbaf-1242-d5c6addb1285" + } + }, + { + "fullUrl": "urn:uuid:68e0f79f-ad85-113d-c23d-58fec16ee5d9", + "resource": { + "resourceType": "Observation", + "id": "68e0f79f-ad85-113d-c23d-58fec16ee5d9", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Cesspool dress crystallography processing sphynx conspirator plate tool", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/68e0f79f-ad85-113d-c23d-58fec16ee5d9" + } + }, + { + "fullUrl": "urn:uuid:6ba400df-3c94-dccd-275f-87f7bef8cece", + "resource": { + "resourceType": "Observation", + "id": "6ba400df-3c94-dccd-275f-87f7bef8cece", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Let nothing neuropathologist grass", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/6ba400df-3c94-dccd-275f-87f7bef8cece" + } + }, + { + "fullUrl": "urn:uuid:a93e88a9-4706-27a0-e24d-ca7b71a9d5a0", + "resource": { + "resourceType": "Observation", + "id": "a93e88a9-4706-27a0-e24d-ca7b71a9d5a0", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "James flavor source sweats perfume spasm", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/a93e88a9-4706-27a0-e24d-ca7b71a9d5a0" + } + }, + { + "fullUrl": "urn:uuid:b6655c58-2580-31ca-89fa-f71589186f5f", + "resource": { + "resourceType": "Observation", + "id": "b6655c58-2580-31ca-89fa-f71589186f5f", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Stopsign", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/b6655c58-2580-31ca-89fa-f71589186f5f" + } + }, + { + "fullUrl": "urn:uuid:6c24608d-f759-4c1e-75f1-7b530ba5810a", + "resource": { + "resourceType": "Observation", + "id": "6c24608d-f759-4c1e-75f1-7b530ba5810a", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Neat rugby sound evening hostel curio chastity pulley wallet xylophone", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/6c24608d-f759-4c1e-75f1-7b530ba5810a" + } + }, + { + "fullUrl": "urn:uuid:8bdf4549-5339-7eb4-dfa3-c7c8ef981ceb", + "resource": { + "resourceType": "Observation", + "id": "8bdf4549-5339-7eb4-dfa3-c7c8ef981ceb", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Tomorrow survey raffle epee cash herb hovel frame", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/8bdf4549-5339-7eb4-dfa3-c7c8ef981ceb" + } + }, + { + "fullUrl": "urn:uuid:ee71fea8-96b6-a46c-579e-dc5367127579", + "resource": { + "resourceType": "Observation", + "id": "ee71fea8-96b6-a46c-579e-dc5367127579", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Wish orangutan caddy mayor knowledge guilt tight criteria", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/ee71fea8-96b6-a46c-579e-dc5367127579" + } + }, + { + "fullUrl": "urn:uuid:a9f6136e-3718-d3a7-6b0c-089337325264", + "resource": { + "resourceType": "Observation", + "id": "a9f6136e-3718-d3a7-6b0c-089337325264", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Thong", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/a9f6136e-3718-d3a7-6b0c-089337325264" + } + }, + { + "fullUrl": "urn:uuid:1729d3a6-8428-d4df-ad09-54ba86fbe34f", + "resource": { + "resourceType": "Observation", + "id": "1729d3a6-8428-d4df-ad09-54ba86fbe34f", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Scimitar gall-bladder economy orange trade sing town", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/1729d3a6-8428-d4df-ad09-54ba86fbe34f" + } + }, + { + "fullUrl": "urn:uuid:0689f0ef-6812-c40c-7c5b-8da95fcbc61d", + "resource": { + "resourceType": "Observation", + "id": "0689f0ef-6812-c40c-7c5b-8da95fcbc61d", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Vinyl people junk skiing north irony sing scorn cameo", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/0689f0ef-6812-c40c-7c5b-8da95fcbc61d" + } + }, + { + "fullUrl": "urn:uuid:73ca4d9e-6996-d09d-13fc-a0c6bb1a0dd0", + "resource": { + "resourceType": "Observation", + "id": "73ca4d9e-6996-d09d-13fc-a0c6bb1a0dd0", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Math pimp wave leather national nurture responsibility suppression", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/73ca4d9e-6996-d09d-13fc-a0c6bb1a0dd0" + } + }, + { + "fullUrl": "urn:uuid:6b7a5ccb-3e27-58ec-85e2-faae9175191e", + "resource": { + "resourceType": "Observation", + "id": "6b7a5ccb-3e27-58ec-85e2-faae9175191e", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Sash area", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/6b7a5ccb-3e27-58ec-85e2-faae9175191e" + } + }, + { + "fullUrl": "urn:uuid:ae8f0749-b387-eeb6-9455-060899157001", + "resource": { + "resourceType": "Observation", + "id": "ae8f0749-b387-eeb6-9455-060899157001", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Search eyelids", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/ae8f0749-b387-eeb6-9455-060899157001" + } + }, + { + "fullUrl": "urn:uuid:dad4437d-d5a0-2a1f-95a5-adf4cca9ee81", + "resource": { + "resourceType": "Observation", + "id": "dad4437d-d5a0-2a1f-95a5-adf4cca9ee81", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Suffocation face convert soup cricket", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/dad4437d-d5a0-2a1f-95a5-adf4cca9ee81" + } + }, + { + "fullUrl": "urn:uuid:737a80e8-e1f6-3f78-98bf-f051b176be60", + "resource": { + "resourceType": "Observation", + "id": "737a80e8-e1f6-3f78-98bf-f051b176be60", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Step-Grandmother", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/737a80e8-e1f6-3f78-98bf-f051b176be60" + } + }, + { + "fullUrl": "urn:uuid:141338ad-2acf-f6f3-4c96-9db178a297db", + "resource": { + "resourceType": "Observation", + "id": "141338ad-2acf-f6f3-4c96-9db178a297db", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Pheasant shot disembodiment", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/141338ad-2acf-f6f3-4c96-9db178a297db" + } + }, + { + "fullUrl": "urn:uuid:9e207d6a-254c-199e-ace3-73028bbf61e2", + "resource": { + "resourceType": "Observation", + "id": "9e207d6a-254c-199e-ace3-73028bbf61e2", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "White feature", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/9e207d6a-254c-199e-ace3-73028bbf61e2" + } + }, + { + "fullUrl": "urn:uuid:7ece5490-60d5-9c13-80d7-e316eb0f8e11", + "resource": { + "resourceType": "Observation", + "id": "7ece5490-60d5-9c13-80d7-e316eb0f8e11", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Duster", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/7ece5490-60d5-9c13-80d7-e316eb0f8e11" + } + }, + { + "fullUrl": "urn:uuid:e8265970-6279-10e5-e7f2-5c293bfe01be", + "resource": { + "resourceType": "Observation", + "id": "e8265970-6279-10e5-e7f2-5c293bfe01be", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Science cycle demand", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/e8265970-6279-10e5-e7f2-5c293bfe01be" + } + }, + { + "fullUrl": "urn:uuid:447cfa11-4719-8b8c-5d7f-698fe7f2d492", + "resource": { + "resourceType": "Observation", + "id": "447cfa11-4719-8b8c-5d7f-698fe7f2d492", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Charm official", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/447cfa11-4719-8b8c-5d7f-698fe7f2d492" + } + }, + { + "fullUrl": "urn:uuid:11738ca9-487e-3484-ff4d-5d0e04b52681", + "resource": { + "resourceType": "Observation", + "id": "11738ca9-487e-3484-ff4d-5d0e04b52681", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Airport manservant", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/11738ca9-487e-3484-ff4d-5d0e04b52681" + } + }, + { + "fullUrl": "urn:uuid:a7307ba2-a39d-7fac-8333-416851242799", + "resource": { + "resourceType": "Observation", + "id": "a7307ba2-a39d-7fac-8333-416851242799", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Lanai flute unique plain feature parking pressure", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/a7307ba2-a39d-7fac-8333-416851242799" + } + }, + { + "fullUrl": "urn:uuid:a0a317c7-fc88-8e06-1481-20dd212e9dc8", + "resource": { + "resourceType": "Observation", + "id": "a0a317c7-fc88-8e06-1481-20dd212e9dc8", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Instance buggy colt route pier menorah ingrate garb", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/a0a317c7-fc88-8e06-1481-20dd212e9dc8" + } + }, + { + "fullUrl": "urn:uuid:9914967a-1c3e-c037-30f2-362b2135b21b", + "resource": { + "resourceType": "Observation", + "id": "9914967a-1c3e-c037-30f2-362b2135b21b", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Character press mini comic", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/9914967a-1c3e-c037-30f2-362b2135b21b" + } + }, + { + "fullUrl": "urn:uuid:a43d8206-d6e6-95a5-2c99-aa86046ba477", + "resource": { + "resourceType": "Observation", + "id": "a43d8206-d6e6-95a5-2c99-aa86046ba477", + "status": "final", + "code": { + "coding": [ + { + "code": "obs-id", + "display": "obs-text", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/coding-system" + } + ] + }, + "valueString": "Reminder shofar congo vibration mother-in-law bondsman suspect", + "subject": { + "reference": "Patient/a6ea438d-b20e-d59e-c9bf-e31dd88f7e4e" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/a43d8206-d6e6-95a5-2c99-aa86046ba477" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/OML_O21/MDHHS-OML-O21-1-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/OML_O21/MDHHS-OML-O21-1-expected.json index 9cc659b9a..6a7579a4b 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/OML_O21/MDHHS-OML-O21-1-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/OML_O21/MDHHS-OML-O21-1-expected.json @@ -5,6 +5,7 @@ "identifier": { "value": "TC09SAPartAIG030101AA" }, + "id": "b56f609b-5811-993c-e8ce-2ed8e3dbde53", "entry": [ { "fullUrl": "urn:uuid:6eda7d2f-32f8-a6c7-5125-d59f65a25c97", @@ -53,6 +54,97 @@ "url": "MessageHeader/6eda7d2f-32f8-a6c7-5125-d59f65a25c97" } }, + { + "fullUrl": "urn:uuid:a8f237a8-b330-c901-c5c0-5f847b8ecd91", + "resource": { + "resourceType": "Provenance", + "id": "a8f237a8-b330-c901-c5c0-5f847b8ecd91", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:53:15.699Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: OML_O21.

" + }, + "occurredDateTime": "2016-03-09T04:34:05+05:30", + "recorded": "2016-03-09T04:34:05+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/3ec1a91c-4720-6f8c-d861-4fa35aff66a7" + } + } + ], + "activity": { + "coding": [ + { + "display": "OML^O21^OML_O21" + } + ] + }, + "target": [ + { + "reference": "Bundle/b56f609b-5811-993c-e8ce-2ed8e3dbde53" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/a8f237a8-b330-c901-c5c0-5f847b8ecd91" + } + }, + { + "fullUrl": "urn:uuid:3ec1a91c-4720-6f8c-d861-4fa35aff66a7", + "resource": { + "resourceType": "Organization", + "id": "3ec1a91c-4720-6f8c-d861-4fa35aff66a7", + "identifier": [ + { + "value": "MDHHS", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-MDHHS" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/3ec1a91c-4720-6f8c-d861-4fa35aff66a7" + } + }, + { + "fullUrl": "urn:uuid:d6043a57-a50e-abc1-6fcf-96fff9d1bfb0", + "resource": { + "resourceType": "Organization", + "id": "d6043a57-a50e-abc1-6fcf-96fff9d1bfb0", + "identifier": [ + { + "value": "MDHHS", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-MDHHS" + }, + { + "value": "urn:oid:2.16.840.1.114222.4.3.2.2.3.161.1", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/d6043a57-a50e-abc1-6fcf-96fff9d1bfb0" + } + }, { "fullUrl": "urn:uuid:97997f4d-5259-b974-5a44-1b7450c2f4ab", "resource": { @@ -145,43 +237,6 @@ } ] } - ], - "contact": [ - { - "name": { - "family": "Shine", - "given": [ - "Sarah" - ] - }, - "address": { - "line": [ - "123 Main Street", - "Apartment 3-C" - ], - "city": "Oldtown", - "state": "MI", - "postalCode": "48917", - "country": "USA" - }, - "telecom": [ - { - "use": "home", - "system": "phone" - } - ], - "relationship": [ - { - "coding": [ - { - "code": "E", - "display": "Employer", - "system": "http://terminology.hl7.org/CodeSystem/v2-0131" - } - ] - } - ] - } ] }, "request": { @@ -190,136 +245,128 @@ } }, { - "fullUrl": "urn:uuid:", - "resource": { - "resourceType": "Practitioner" - }, - "request": { - "method": "PUT", - "url": "Practitioner/" - } - }, - { - "fullUrl": "urn:uuid:", + "fullUrl": "urn:uuid:b4494dc0-e11b-658a-8cce-5241ed1ccdc0", "resource": { - "resourceType": "Location" - }, - "request": { - "method": "PUT", - "url": "Location/" - } - }, - { - "fullUrl": "urn:uuid:1bf1c1fb-5a57-2c41-d065-7740bdefa1b2", - "resource": { - "resourceType": "Provenance", - "id": "1bf1c1fb-5a57-2c41-d065-7740bdefa1b2", - "text": { - "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:40:34.155Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: OML_O21.

" - }, - "occurredDateTime": "2016-03-09T04:34:05+05:30", - "recorded": "2016-03-09T04:34:05+05:30", - "agent": [ + "resourceType": "Coverage", + "id": "b4494dc0-e11b-658a-8cce-5241ed1ccdc0", + "class": [ { + "value": "NA", "type": { "coding": [ { - "code": "author", - "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + "system": "http://terminology.hl7.org/CodeSystem/coverage-class", + "code": "plan", + "display": "Plan" + } + ] + } + }, + { + "value": "IG030101", + "type": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/coverage-class", + "code": "group", + "display": "Group" } ] - }, - "who": { - "reference": "Organization/3ec1a91c-4720-6f8c-d861-4fa35aff66a7" } } ], - "activity": { - "coding": [ - { - "display": "OML^O21^OML_O21" - } - ] + "period": { + "end": "2017-10-08T01:34:05+05:30" }, - "target": [ + "identifier": [ { - "reference": "Bundle/" + "value": "TC09SA-PartA", + "type": { + "coding": [ + { + "code": "PLN", + "display": "Policy Number", + "system": "http://example.com/CodeSystem/additional-identifier" + } + ] + }, + "system": "http://www.examplehealthplan.com/fhir/policyidentifier" } - ] - }, - "request": { - "method": "PUT", - "url": "Provenance/1bf1c1fb-5a57-2c41-d065-7740bdefa1b2" - } - }, - { - "fullUrl": "urn:uuid:d26a5004-0934-26f5-0201-4e302d6163c4", - "resource": { - "resourceType": "Account", - "id": "d26a5004-0934-26f5-0201-4e302d6163c4", + ], "status": "active", - "subject": [ + "beneficiary": { + "reference": "Patient/97997f4d-5259-b974-5a44-1b7450c2f4ab" + }, + "payor": [ { - "reference": "Patient/97997f4d-5259-b974-5a44-1b7450c2f4ab" + "reference": "Organization/c30aa783-68cc-9ce0-504f-9e4b50183350" } - ] + ], + "policyHolder": { + "reference": "Organization/0c8a9af0-2231-f818-ed7c-40bdb2aea2d1" + }, + "subscriber": { + "reference": "RelatedPerson/fed1892c-d5ce-3318-bc7c-692fa1cc5093" + } }, "request": { "method": "PUT", - "url": "Account/d26a5004-0934-26f5-0201-4e302d6163c4" + "url": "Coverage/b4494dc0-e11b-658a-8cce-5241ed1ccdc0" } }, { - "fullUrl": "urn:uuid:", + "fullUrl": "urn:uuid:c30aa783-68cc-9ce0-504f-9e4b50183350", "resource": { - "resourceType": "Encounter", - "text": { - "status": "generated", - "div": "

Visit Description:

" - }, - "subject": { - "reference": "Patient/97997f4d-5259-b974-5a44-1b7450c2f4ab" - } + "resourceType": "Organization", + "id": "c30aa783-68cc-9ce0-504f-9e4b50183350", + "address": [ + { + "line": [ + "30555" + ], + "city": "Lansing", + "state": "MI", + "postalCode": "48933" + } + ], + "identifier": [ + { + "value": "LHC" + } + ], + "name": "Lansing Health Care" }, "request": { "method": "PUT", - "url": "Encounter/" + "url": "Organization/c30aa783-68cc-9ce0-504f-9e4b50183350" } }, { - "fullUrl": "urn:uuid:", + "fullUrl": "urn:uuid:0c8a9af0-2231-f818-ed7c-40bdb2aea2d1", "resource": { - "resourceType": "Organization" + "resourceType": "Organization", + "id": "0c8a9af0-2231-f818-ed7c-40bdb2aea2d1", + "name": "Walmart" }, "request": { "method": "PUT", - "url": "Organization/" + "url": "Organization/0c8a9af0-2231-f818-ed7c-40bdb2aea2d1" } }, { - "fullUrl": "urn:uuid:39780c38-eef5-37af-195d-4a60184c0354", + "fullUrl": "urn:uuid:fed1892c-d5ce-3318-bc7c-692fa1cc5093", "resource": { "resourceType": "RelatedPerson", - "id": "39780c38-eef5-37af-195d-4a60184c0354", + "id": "fed1892c-d5ce-3318-bc7c-692fa1cc5093", "relationship": [ { "coding": [ { - "code": "MTH", - "display": "mother", + "code": "CHILD", + "display": "child", "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" } ] - }, - { - "coding": [ - { - "code": "E", - "display": "Employer", - "system": "http://terminology.hl7.org/CodeSystem/v2-0131" - } - ] } ], "address": [ @@ -334,12 +381,6 @@ "country": "USA" } ], - "telecom": [ - { - "use": "home", - "system": "phone" - } - ], "name": [ { "family": "Shine", @@ -348,13 +389,14 @@ ] } ], + "birthDate": "1975-06-27", "patient": { "reference": "Patient/97997f4d-5259-b974-5a44-1b7450c2f4ab" } }, "request": { "method": "PUT", - "url": "RelatedPerson/39780c38-eef5-37af-195d-4a60184c0354" + "url": "RelatedPerson/fed1892c-d5ce-3318-bc7c-692fa1cc5093" } } ] diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/OML_O21/MDHHS-OML-O21-2-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/OML_O21/MDHHS-OML-O21-2-expected.json index f14a72369..9de9c05dc 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/OML_O21/MDHHS-OML-O21-2-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/OML_O21/MDHHS-OML-O21-2-expected.json @@ -5,6 +5,7 @@ "identifier": { "value": "TC14IG030107AA" }, + "id": "65e80ae9-58dc-500c-8ad4-ab62c0bb6898", "entry": [ { "fullUrl": "urn:uuid:f651f710-5269-afaa-f743-57b7a501b0c6", @@ -53,6 +54,97 @@ "url": "MessageHeader/f651f710-5269-afaa-f743-57b7a501b0c6" } }, + { + "fullUrl": "urn:uuid:2f0f2d7d-7f93-e624-fa21-11d1c490897f", + "resource": { + "resourceType": "Provenance", + "id": "2f0f2d7d-7f93-e624-fa21-11d1c490897f", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:53:34.627Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: OML_O21.

" + }, + "occurredDateTime": "2016-03-09T21:02:05+05:30", + "recorded": "2016-03-09T21:02:05+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/3ec1a91c-4720-6f8c-d861-4fa35aff66a7" + } + } + ], + "activity": { + "coding": [ + { + "display": "OML^O21^OML_O21" + } + ] + }, + "target": [ + { + "reference": "Bundle/65e80ae9-58dc-500c-8ad4-ab62c0bb6898" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/2f0f2d7d-7f93-e624-fa21-11d1c490897f" + } + }, + { + "fullUrl": "urn:uuid:3ec1a91c-4720-6f8c-d861-4fa35aff66a7", + "resource": { + "resourceType": "Organization", + "id": "3ec1a91c-4720-6f8c-d861-4fa35aff66a7", + "identifier": [ + { + "value": "MDHHS", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-MDHHS" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/3ec1a91c-4720-6f8c-d861-4fa35aff66a7" + } + }, + { + "fullUrl": "urn:uuid:d6043a57-a50e-abc1-6fcf-96fff9d1bfb0", + "resource": { + "resourceType": "Organization", + "id": "d6043a57-a50e-abc1-6fcf-96fff9d1bfb0", + "identifier": [ + { + "value": "MDHHS", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-MDHHS" + }, + { + "value": "urn:oid:2.16.840.1.114222.4.3.2.2.3.161.1", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/d6043a57-a50e-abc1-6fcf-96fff9d1bfb0" + } + }, { "fullUrl": "urn:uuid:daed9284-6d12-ca12-4260-9aad09e1f201", "resource": { @@ -145,43 +237,6 @@ } ] } - ], - "contact": [ - { - "name": { - "family": "Shonal", - "given": [ - "Old" - ] - }, - "address": { - "line": [ - "123 Main Street", - "Apartment 3-C" - ], - "city": "Oldtown", - "state": "MI", - "postalCode": "48917", - "country": "USA" - }, - "telecom": [ - { - "use": "home", - "system": "phone" - } - ], - "relationship": [ - { - "coding": [ - { - "code": "E", - "display": "Employer", - "system": "http://terminology.hl7.org/CodeSystem/v2-0131" - } - ] - } - ] - } ] }, "request": { @@ -190,223 +245,128 @@ } }, { - "fullUrl": "urn:uuid:", - "resource": { - "resourceType": "Practitioner", - "identifier": [ - { - "value": "8075000001", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NPI" - } - ], - "name": [ - { - "family": "Smiles", - "given": [ - "Minnie" - ], - "suffix": [ - "DR" - ] - } - ] - }, - "request": { - "method": "PUT", - "url": "Practitioner/" - } - }, - { - "fullUrl": "urn:uuid:0ac4aa7e-de74-bd40-3b64-97a1c0f3a414", + "fullUrl": "urn:uuid:2839c7cc-58ca-f08d-1358-a15fa18660d3", "resource": { - "resourceType": "Practitioner", - "id": "0ac4aa7e-de74-bd40-3b64-97a1c0f3a414", - "identifier": [ + "resourceType": "Coverage", + "id": "2839c7cc-58ca-f08d-1358-a15fa18660d3", + "class": [ { - "value": "8075000001", - "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NPI" - } - ], - "name": [ - { - "family": "Smiles", - "given": [ - "Minnie" - ], - "suffix": [ - "DR" - ] - } - ] - }, - "request": { - "method": "PUT", - "url": "Practitioner/0ac4aa7e-de74-bd40-3b64-97a1c0f3a414" - } - }, - { - "fullUrl": "urn:uuid:8d21e8ca-50c4-05e7-edb8-9f74c624369e", - "resource": { - "resourceType": "Location", - "id": "8d21e8ca-50c4-05e7-edb8-9f74c624369e", - "name": "Detroit City Hospital", - "identifier": [ + "value": "NA", + "type": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/coverage-class", + "code": "plan", + "display": "Plan" + } + ] + } + }, { - "value": "8175000005" + "value": "FR080901", + "type": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/coverage-class", + "code": "group", + "display": "Group" + } + ] + } } ], - "address": { - "line": [ - "2405 Garden St" - ], - "city": "Detroit", - "state": "MI", - "postalCode": "48201", - "country": "USA" + "period": { + "end": "2017-10-08T01:34:05+05:30" }, - "telecom": [ - { - "use": "work", - "system": "phone" - } - ] - }, - "request": { - "method": "PUT", - "url": "Location/8d21e8ca-50c4-05e7-edb8-9f74c624369e" - } - }, - { - "fullUrl": "urn:uuid:a0ade8a7-09f2-7ce2-46bf-2ab7facb9e9d", - "resource": { - "resourceType": "Provenance", - "id": "a0ade8a7-09f2-7ce2-46bf-2ab7facb9e9d", - "text": { - "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:57:06.13Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: OML_O21.

" - }, - "occurredDateTime": "2016-03-09T21:02:05+05:30", - "recorded": "2016-03-09T21:02:05+05:30", - "agent": [ + "identifier": [ { + "value": "TC05SA", "type": { "coding": [ { - "code": "author", - "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + "code": "PLN", + "display": "Policy Number", + "system": "http://example.com/CodeSystem/additional-identifier" } ] }, - "who": { - "reference": "Organization/3ec1a91c-4720-6f8c-d861-4fa35aff66a7" - } + "system": "http://www.examplehealthplan.com/fhir/policyidentifier" } ], - "activity": { - "coding": [ - { - "display": "OML^O21^OML_O21" - } - ] - }, - "location": { - "reference": "Location/8d21e8ca-50c4-05e7-edb8-9f74c624369e" - }, - "target": [ - { - "reference": "Bundle/" - } - ] - }, - "request": { - "method": "PUT", - "url": "Provenance/a0ade8a7-09f2-7ce2-46bf-2ab7facb9e9d" - } - }, - { - "fullUrl": "urn:uuid:6143ab70-4f28-7863-6edf-704abf375c8d", - "resource": { - "resourceType": "Account", - "id": "6143ab70-4f28-7863-6edf-704abf375c8d", "status": "active", - "subject": [ + "beneficiary": { + "reference": "Patient/daed9284-6d12-ca12-4260-9aad09e1f201" + }, + "payor": [ { - "reference": "Patient/daed9284-6d12-ca12-4260-9aad09e1f201" + "reference": "Organization/c30aa783-68cc-9ce0-504f-9e4b50183350" } - ] - }, - "request": { - "method": "PUT", - "url": "Account/6143ab70-4f28-7863-6edf-704abf375c8d" - } - }, - { - "fullUrl": "urn:uuid:", - "resource": { - "resourceType": "Encounter", - "text": { - "status": "generated", - "div": "

Visit Description:

" + ], + "policyHolder": { + "reference": "Organization/0c8a9af0-2231-f818-ed7c-40bdb2aea2d1" }, - "subject": { - "reference": "Patient/daed9284-6d12-ca12-4260-9aad09e1f201" + "subscriber": { + "reference": "RelatedPerson/ff1b880e-468e-7a2f-41cb-8b6e204901f3" } }, "request": { "method": "PUT", - "url": "Encounter/" + "url": "Coverage/2839c7cc-58ca-f08d-1358-a15fa18660d3" } }, { - "fullUrl": "urn:uuid:", + "fullUrl": "urn:uuid:c30aa783-68cc-9ce0-504f-9e4b50183350", "resource": { "resourceType": "Organization", + "id": "c30aa783-68cc-9ce0-504f-9e4b50183350", "address": [ { "line": [ - "2405 Garden St" + "30555" ], - "city": "Detroit", + "city": "Lansing", "state": "MI", - "postalCode": "48201", - "country": "USA" + "postalCode": "48933" } ], - "telecom": [ + "identifier": [ { - "use": "work", - "system": "phone" + "value": "LHC" } - ] + ], + "name": "Lansing Health Care" + }, + "request": { + "method": "PUT", + "url": "Organization/c30aa783-68cc-9ce0-504f-9e4b50183350" + } + }, + { + "fullUrl": "urn:uuid:0c8a9af0-2231-f818-ed7c-40bdb2aea2d1", + "resource": { + "resourceType": "Organization", + "id": "0c8a9af0-2231-f818-ed7c-40bdb2aea2d1", + "name": "Walmart" }, "request": { "method": "PUT", - "url": "Organization/" + "url": "Organization/0c8a9af0-2231-f818-ed7c-40bdb2aea2d1" } }, { - "fullUrl": "urn:uuid:0f9b5688-7b42-3a39-344c-59b068f35f16", + "fullUrl": "urn:uuid:ff1b880e-468e-7a2f-41cb-8b6e204901f3", "resource": { "resourceType": "RelatedPerson", - "id": "0f9b5688-7b42-3a39-344c-59b068f35f16", + "id": "ff1b880e-468e-7a2f-41cb-8b6e204901f3", "relationship": [ { "coding": [ { - "code": "MTH", - "display": "mother", + "code": "CHILD", + "display": "child", "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" } ] - }, - { - "coding": [ - { - "code": "E", - "display": "Employer", - "system": "http://terminology.hl7.org/CodeSystem/v2-0131" - } - ] } ], "address": [ @@ -421,12 +381,6 @@ "country": "USA" } ], - "telecom": [ - { - "use": "home", - "system": "phone" - } - ], "name": [ { "family": "Shonal", @@ -435,41 +389,14 @@ ] } ], + "birthDate": "1975-06-27", "patient": { "reference": "Patient/daed9284-6d12-ca12-4260-9aad09e1f201" } }, "request": { "method": "PUT", - "url": "RelatedPerson/0f9b5688-7b42-3a39-344c-59b068f35f16" - } - }, - { - "fullUrl": "urn:uuid:a07e0fa5-e133-7049-7e66-15c22f36bfbf", - "resource": { - "resourceType": "Organization", - "id": "a07e0fa5-e133-7049-7e66-15c22f36bfbf", - "address": [ - { - "line": [ - "2405 Garden St" - ], - "city": "Detroit", - "state": "MI", - "postalCode": "48201", - "country": "USA" - } - ], - "telecom": [ - { - "use": "work", - "system": "phone" - } - ] - }, - "request": { - "method": "PUT", - "url": "Organization/a07e0fa5-e133-7049-7e66-15c22f36bfbf" + "url": "RelatedPerson/ff1b880e-468e-7a2f-41cb-8b6e204901f3" } }, { @@ -477,33 +404,24 @@ "resource": { "resourceType": "ServiceRequest", "id": "bafe469c-5cc7-f800-feae-81b33cf36940", + "status": "active", "intent": "order", "identifier": [ { - "value": "R783274", - "system": "urn:oid:2.16.840.1.113883.3.72.5.25", - "type": { - "coding": [ - { - "code": "FILL", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203" - } - ] - } - }, - { - "value": "GORD874211", + "value": "ORD723222", "system": "urn:oid:2.16.840.1.113883.3.72.5.24", "type": { "coding": [ { - "code": "PGN", + "code": "PLAC", "system": "http://terminology.hl7.org/CodeSystem/v2-0203" } ] } }, { + "value": "R-783274", + "system": "urn:oid:2.16.840.1.113883.3.72.5.25", "type": { "coding": [ { @@ -514,117 +432,134 @@ } }, { - "value": "ORD723222", + "value": "GORD874211", "system": "urn:oid:2.16.840.1.113883.3.72.5.24", "type": { "coding": [ { - "code": "ISO", - "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", - "system": "http://terminology.hl7.org/CodeSystem/v2-0301" - } - ] - } - }, - { - "value": "R-783274", - "system": "urn:oid:2.16.840.1.113883.3.72.5.25", - "type": { - "coding": [ - { - "code": "ISO", - "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", - "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + "code": "PGN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" } ] } } ], "authoredOn": "2016-02-23T20:07:05+05:30", - "occurrenceDateTime": "2016-02-23T20:17:05+05:30", - "requester": { - "reference": "Organization/a07e0fa5-e133-7049-7e66-15c22f36bfbf" - }, - "subject": { - "reference": "Patient/daed9284-6d12-ca12-4260-9aad09e1f201" - }, "code": { "coding": [ { "code": "1320", "display": "HIV Ag/Ab - Serum", "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" - }, - { - "code": "1680", - "display": "Syphilis (USR test)(1)", - "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" } ] }, - "reasonCode": [ + "subject": { + "reference": "Patient/daed9284-6d12-ca12-4260-9aad09e1f201" + }, + "requester": { + "reference": "PractitionerRole/9996be7d-26c8-997e-2f57-9ce40fe59181" + }, + "specimen": [ { - "coding": [ - { - "code": "RFS01", - "display": "Diagnosis", - "system": "http://example.com/v2-to-fhir-converter/CodeSystem/BOL_0001" - } - ] + "reference": "Specimen/29fb3250-9864-4dad-e590-4126768684d4" } ], - "supportingInfo": [ + "note": [ { - "reference": "Observation/c55789d4-78ae-5836-21d4-48191c4763a7" + "text": "the sky is blue" } ], - "specimen": [ + "occurrenceDateTime": "2016-02-23T20:17:05+05:30" + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/bafe469c-5cc7-f800-feae-81b33cf36940" + } + }, + { + "fullUrl": "urn:uuid:0ac4aa7e-de74-bd40-3b64-97a1c0f3a414", + "resource": { + "resourceType": "Practitioner", + "id": "0ac4aa7e-de74-bd40-3b64-97a1c0f3a414", + "identifier": [ { - "reference": "Specimen/92af9b9a-bcfc-b6f6-ce19-bf5bc7b28707" + "value": "8075000001", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NPI" + } + ], + "name": [ + { + "family": "Smiles", + "given": [ + "Minnie" + ], + "suffix": [ + "DR" + ] } ] }, "request": { "method": "PUT", - "url": "ServiceRequest/bafe469c-5cc7-f800-feae-81b33cf36940" + "url": "Practitioner/0ac4aa7e-de74-bd40-3b64-97a1c0f3a414" } }, { - "fullUrl": "urn:uuid:", + "fullUrl": "urn:uuid:9996be7d-26c8-997e-2f57-9ce40fe59181", "resource": { - "resourceType": "Provenance", - "recorded": "2016-02-23T20:07:05+05:30", - "occurredDateTime": "2016-02-23T20:07:05+05:30", - "agent": [ + "resourceType": "PractitionerRole", + "id": "9996be7d-26c8-997e-2f57-9ce40fe59181", + "practitioner": { + "reference": "Practitioner/0ac4aa7e-de74-bd40-3b64-97a1c0f3a414" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/9996be7d-26c8-997e-2f57-9ce40fe59181" + } + }, + { + "fullUrl": "urn:uuid:29fb3250-9864-4dad-e590-4126768684d4", + "resource": { + "resourceType": "Specimen", + "id": "29fb3250-9864-4dad-e590-4126768684d4", + "collection": { + "collectedPeriod": { + "start": "2016-03-08T21:02:05+05:30", + "end": "2016-03-08T21:02:05+05:30" + } + }, + "identifier": [ { + "value": "ORD723222", + "system": "urn:oid:2.16.840.1.113883.3.72.5.24", "type": { "coding": [ { - "code": "author", - "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" } ] - }, - "who": { - "reference": "Practitioner/0ac4aa7e-de74-bd40-3b64-97a1c0f3a414" } - } - ], - "location": { - "reference": "Location/8d21e8ca-50c4-05e7-edb8-9f74c624369e" - }, - "target": [ - { - "reference": "Bundle/" }, { - "reference": "ServiceRequest/bafe469c-5cc7-f800-feae-81b33cf36940" + "value": "R-783274", + "system": "urn:oid:2.16.840.1.113883.3.72.5.25", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } } ] }, "request": { "method": "PUT", - "url": "Provenance/" + "url": "Specimen/29fb3250-9864-4dad-e590-4126768684d4" } }, { @@ -642,8 +577,31 @@ } ] }, + "basedOn": [ + { + "reference": "ServiceRequest/bafe469c-5cc7-f800-feae-81b33cf36940" + } + ], "valueString": "NO", - "effectiveDateTime": "2016-03-08T21:02:05+05:30" + "effectiveDateTime": "2016-03-08T21:02:05+05:30", + "subject": { + "reference": "Patient/daed9284-6d12-ca12-4260-9aad09e1f201" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "O", + "display": "Order Detail", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Order Detail" + } + } + ] }, "request": { "method": "PUT", @@ -663,7 +621,7 @@ { "code": "119339001", "display": "Stool Specimen (Specimen)", - "system": "http://snomed.info/sct" + "system": "http://terminology.hl7.org/CodeSystem/v2-0487" } ] }, @@ -672,11 +630,17 @@ "additiveCodeableConcept": { "coding": [ { - "code": "NONE" + "code": "NONE", + "system": "http://terminology.hl7.org/CodeSystem/v2-0371" } ] } } + ], + "request": [ + { + "reference": "ServiceRequest/bafe469c-5cc7-f800-feae-81b33cf36940" + } ] }, "request": { diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/OML_O21/OML-O21-01-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/OML_O21/OML-O21-01-expected.json new file mode 100644 index 000000000..23f9d2541 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/OML_O21/OML-O21-01-expected.json @@ -0,0 +1,2681 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2021-10-20T14:41:00+05:30", + "identifier": { + "value": "MSG00019" + }, + "id": "850fa16f-dec7-80c7-978f-7276e0f16e62", + "entry": [ + { + "fullUrl": "urn:uuid:85946184-5877-2309-6765-683c677d000d", + "resource": { + "resourceType": "MessageHeader", + "id": "85946184-5877-2309-6765-683c677d000d", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "O21", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "OML^O21^OML_O21" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/85946184-5877-2309-6765-683c677d000d" + } + }, + { + "fullUrl": "urn:uuid:58988e57-a45e-285b-5942-4480980652df", + "resource": { + "resourceType": "Provenance", + "id": "58988e57-a45e-285b-5942-4480980652df", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:52:34.631Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: OML_O21.

" + }, + "occurredDateTime": "2021-10-20T14:41:00+05:30", + "recorded": "2021-10-20T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "OML^O21^OML_O21" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/ad64f1d1-3e5b-a041-c1b3-3e157882ed69" + } + } + ], + "target": [ + { + "reference": "Bundle/850fa16f-dec7-80c7-978f-7276e0f16e62" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/58988e57-a45e-285b-5942-4480980652df" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:ad64f1d1-3e5b-a041-c1b3-3e157882ed69", + "resource": { + "resourceType": "Device", + "id": "ad64f1d1-3e5b-a041-c1b3-3e157882ed69", + "identifier": [ + { + "value": "ORDApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/ad64f1d1-3e5b-a041-c1b3-3e157882ed69" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + }, + { + "value": "Medicare-12345", + "type": { + "coding": [ + { + "code": "MC", + "display": "Patient's Medicare number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-medicare" + }, + { + "value": "MI-12345", + "type": { + "coding": [ + { + "code": "MI", + "display": "Military ID number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/identifier-military" + }, + { + "value": "MB-12345", + "type": { + "coding": [ + { + "code": "MB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Member Number" + } + ] + }, + "system": "urn:oid:2.16.840.1.113883.1.5" + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + } + ], + "contact": [ + { + "name": { + "family": "Abbot", + "given": [ + "Adam", + "A" + ], + "suffix": [ + "III", + "PHD" + ], + "prefix": [ + "DR" + ], + "use": "official" + }, + "address": { + "line": [ + "1000 Hospital Lane", + "Ste.123" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "use": "work" + }, + "telecom": [ + { + "value": "(626)555-1234", + "use": "work", + "system": "phone" + } + ], + "relationship": [ + { + "coding": [ + { + "code": "C", + "display": "Emergency Contact", + "system": "http://terminology.hl7.org/CodeSystem/v2-0131" + } + ] + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ], + "guarantor": [ + { + "party": { + "reference": "RelatedPerson/e42e5df9-fef2-9072-3b17-3f2475927f98" + }, + "onHold": false, + "period": { + "start": "2016-01-01" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:e42e5df9-fef2-9072-3b17-3f2475927f98", + "resource": { + "resourceType": "RelatedPerson", + "id": "e42e5df9-fef2-9072-3b17-3f2475927f98", + "identifier": [ + { + "value": "1516", + "type": { + "coding": [ + { + "code": "LN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "License number" + } + ] + } + }, + { + "value": "19290207", + "type": { + "coding": [ + { + "code": "EI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Employee number" + } + ] + } + }, + { + "value": "2245367687", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "display": "mother", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "address": [ + { + "line": [ + "1619 SOUTH UNIVERSITY" + ], + "city": "MADISON", + "state": "WI", + "postalCode": "53703", + "country": "US" + } + ], + "telecom": [ + { + "value": "(608)251-7777", + "system": "phone", + "use": "home" + }, + { + "value": "(608)2517777", + "system": "phone", + "use": "work" + } + ], + "name": [ + { + "family": "RADIANT", + "given": [ + "LUCY" + ] + } + ], + "gender": "female", + "birthDate": "2001-04-12", + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/e42e5df9-fef2-9072-3b17-3f2475927f98" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:d00df304-17fa-8d9a-bd02-3276b1781ea1", + "resource": { + "resourceType": "Practitioner", + "id": "d00df304-17fa-8d9a-bd02-3276b1781ea1", + "identifier": [ + { + "value": "0210" + } + ], + "name": [ + { + "family": "ATTEND", + "given": [ + "AARON", + "A" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/d00df304-17fa-8d9a-bd02-3276b1781ea1" + } + }, + { + "fullUrl": "urn:uuid:21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9", + "resource": { + "resourceType": "Practitioner", + "id": "21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9", + "identifier": [ + { + "value": "0310" + } + ], + "name": [ + { + "family": "REFER", + "given": [ + "LINDA", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9" + } + }, + { + "fullUrl": "urn:uuid:6c138e7c-e841-af07-8948-d01692bd2739", + "resource": { + "resourceType": "Practitioner", + "id": "6c138e7c-e841-af07-8948-d01692bd2739", + "identifier": [ + { + "value": "03410" + } + ], + "name": [ + { + "family": "ADMIT", + "given": [ + "LINDA", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/6c138e7c-e841-af07-8948-d01692bd2739" + } + }, + { + "fullUrl": "urn:uuid:ed401da2-2b32-f3d0-d128-9766ac20c0ad", + "resource": { + "resourceType": "Location", + "id": "ed401da2-2b32-f3d0-d128-9766ac20c0ad", + "name": "LABUnit01", + "mode": "instance", + "description": "LABUnit01--Room01--GHH", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/ed401da2-2b32-f3d0-d128-9766ac20c0ad" + } + }, + { + "fullUrl": "urn:uuid:ee586d80-706a-5933-8500-a8026c48fb27", + "resource": { + "resourceType": "Location", + "id": "ee586d80-706a-5933-8500-a8026c48fb27", + "partOf": { + "reference": "Location/ed401da2-2b32-f3d0-d128-9766ac20c0ad" + }, + "name": "Room01", + "mode": "instance", + "description": "LABUnit01--Room01--GHH", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/ee586d80-706a-5933-8500-a8026c48fb27" + } + }, + { + "fullUrl": "urn:uuid:3ffd504f-44ae-ce29-6fc0-6baf5bc0a821", + "resource": { + "resourceType": "Location", + "id": "3ffd504f-44ae-ce29-6fc0-6baf5bc0a821", + "name": "GHH", + "mode": "instance", + "description": "LABUnit01--Room01--GHH", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3ffd504f-44ae-ce29-6fc0-6baf5bc0a821" + } + }, + { + "fullUrl": "urn:uuid:5357a3e3-2c50-7c10-6b22-00b646c8b396", + "resource": { + "resourceType": "Location", + "id": "5357a3e3-2c50-7c10-6b22-00b646c8b396", + "name": "TraumaCentre", + "mode": "instance", + "description": "TraumaCentre--ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--GHH1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5357a3e3-2c50-7c10-6b22-00b646c8b396" + } + }, + { + "fullUrl": "urn:uuid:c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "resource": { + "resourceType": "Location", + "id": "c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "partOf": { + "reference": "Location/5357a3e3-2c50-7c10-6b22-00b646c8b396" + }, + "name": "ROOM1", + "identifier": [ + { + "value": "urn:oid:2.16.840.1.113883.4.642.1.1108", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "TraumaCentre--ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--GHH1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + } + }, + { + "fullUrl": "urn:uuid:e9bd830d-8f94-01b9-7562-854da22940d3", + "resource": { + "resourceType": "Location", + "id": "e9bd830d-8f94-01b9-7562-854da22940d3", + "name": "GHH1", + "mode": "instance", + "description": "TraumaCentre--ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--GHH1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/e9bd830d-8f94-01b9-7562-854da22940d3" + } + }, + { + "fullUrl": "urn:uuid:da6f322f-ef5e-4f2c-c1f8-6e38dffbf995", + "resource": { + "resourceType": "Encounter", + "id": "da6f322f-ef5e-4f2c-c1f8-6e38dffbf995", + "class": { + "code": "AMB", + "display": "ambulatory", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "in-progress", + "location": [ + { + "status": "active", + "location": { + "reference": "Location/ed401da2-2b32-f3d0-d128-9766ac20c0ad" + } + }, + { + "status": "completed", + "location": { + "reference": "Location/5357a3e3-2c50-7c10-6b22-00b646c8b396" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/d00df304-17fa-8d9a-bd02-3276b1781ea1" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "ADM", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "admitter" + } + ], + "individual": { + "reference": "Practitioner/6c138e7c-e841-af07-8948-d01692bd2739" + } + } + ], + "identifier": [ + { + "value": "5001", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + } + ], + "period": { + "start": "2021-10-20T14:41:00+05:30" + }, + "text": { + "status": "generated", + "div": "

Visit Description:

" + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "diagnosis": [ + { + "condition": { + "reference": "Condition/e06055fc-0230-24ef-7d66-7ae83cafb322" + }, + "use": { + "coding": [ + { + "code": "DD", + "display": "Discharge Diagnosis", + "system": "http://terminology.hl7.org/CodeSystem/diagnosis-role" + } + ] + }, + "rank": 1 + } + ] + }, + "request": { + "method": "PUT", + "url": "Encounter/da6f322f-ef5e-4f2c-c1f8-6e38dffbf995" + } + }, + { + "fullUrl": "urn:uuid:6415af3e-e19f-4ebe-e028-68273aa308ff", + "resource": { + "resourceType": "AllergyIntolerance", + "id": "6415af3e-e19f-4ebe-e028-68273aa308ff", + "category": [ + "food" + ], + "type": "allergy", + "code": { + "coding": [ + { + "code": "12345", + "display": "Peanut Allergy", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + }, + "reaction": [ + { + "manifestation": [ + { + "text": "moderate" + } + ], + "onset": "2021-01-21" + } + ], + "criticality": "low", + "clinicalStatus": { + "coding": [ + { + "code": "active", + "display": "Active", + "system": "http://terminology.hl7.org/CodeSystem/allergyintolerance-clinical" + } + ] + }, + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "AllergyIntolerance/6415af3e-e19f-4ebe-e028-68273aa308ff" + } + }, + { + "fullUrl": "urn:uuid:dfab6985-a691-c4f5-d2b2-6481fdfd59e4", + "resource": { + "resourceType": "Coverage", + "id": "dfab6985-a691-c4f5-d2b2-6481fdfd59e4", + "class": [ + { + "value": "BAV", + "name": "Blue Advantage HMO", + "type": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/coverage-class", + "code": "plan", + "display": "Plan" + } + ] + } + }, + { + "value": "Grp-12345", + "name": "BCBS HMO", + "type": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/coverage-class", + "code": "group", + "display": "Group" + } + ] + } + } + ], + "network": "Blue Advantage HMO", + "period": { + "start": "1998-11-01" + }, + "type": { + "coding": [ + { + "code": "HMO", + "display": "health maintenance organization policy", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + } + ] + }, + "identifier": [ + { + "value": "548851236L", + "type": { + "coding": [ + { + "code": "PLN", + "display": "Policy Number", + "system": "http://example.com/CodeSystem/additional-identifier" + } + ] + }, + "system": "http://www.examplehealthplan.com/fhir/policyidentifier" + }, + { + "value": "Medicare-12345", + "type": { + "coding": [ + { + "code": "MC", + "display": "Patient's Medicare number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-medicare" + }, + { + "value": "MB-12345", + "type": { + "coding": [ + { + "code": "MB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Member Number" + } + ] + }, + "system": "urn:oid:2.16.840.1.113883.1.5" + } + ], + "costToBeneficiary": [ + { + "type": { + "coding": [ + { + "code": "DC", + "display": "direct unit cost", + "system": "http://terminology.hl7.org/CodeSystem/v2-0205" + } + ] + }, + "valueMoney": { + "value": 150, + "currency": "USD" + } + } + ], + "subscriberId": "HMO-12345", + "status": "active", + "beneficiary": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "payor": [ + { + "reference": "Organization/04a2a5f2-c971-1e42-e788-250ea487a889" + } + ], + "policyHolder": { + "reference": "Organization/0f21af2c-9880-54cb-14a5-5493a766da42" + }, + "subscriber": { + "reference": "RelatedPerson/fd1eed45-4ccb-bb7c-d157-58eb0366d777" + }, + "relationship": { + "coding": [ + { + "code": "spouse", + "display": "Spouse", + "system": "http://terminology.hl7.org/CodeSystem/subscriber-relationship" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Coverage/dfab6985-a691-c4f5-d2b2-6481fdfd59e4" + } + }, + { + "fullUrl": "urn:uuid:04a2a5f2-c971-1e42-e788-250ea487a889", + "resource": { + "resourceType": "Organization", + "id": "04a2a5f2-c971-1e42-e788-250ea487a889", + "address": [ + { + "line": [ + "1979 MILKY WAY" + ], + "city": "VERONA", + "state": "WI", + "postalCode": "53593", + "country": "US" + } + ], + "contact": [ + { + "name": { + "family": "Roger", + "given": [ + "Dann" + ] + } + } + ], + "telecom": [ + { + "value": "(555)555-5555", + "system": "phone" + } + ], + "identifier": [ + { + "value": "Org-12345", + "type": { + "coding": [ + { + "code": "NIIP", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "National Insurance Payor Identifier (Payor)" + } + ] + }, + "system": "urn:oid:2.16.840.1.113883.1.1" + } + ], + "name": "Blue Cross Blue Shield of Texas" + }, + "request": { + "method": "PUT", + "url": "Organization/04a2a5f2-c971-1e42-e788-250ea487a889" + } + }, + { + "fullUrl": "urn:uuid:0f21af2c-9880-54cb-14a5-5493a766da42", + "resource": { + "resourceType": "Organization", + "id": "0f21af2c-9880-54cb-14a5-5493a766da42", + "address": [ + { + "line": [ + "2000 MILKY WAY" + ], + "city": "VERONA", + "state": "WI", + "postalCode": "53593", + "country": "US" + } + ], + "identifier": [ + { + "value": "Tel-12345", + "type": { + "coding": [ + { + "code": "EN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Employer number" + } + ] + }, + "system": "urn:oid:2.16.840.1.113883.1.2" + } + ], + "name": "Telstra", + "contact": [ + { + "name": { + "family": "Richard", + "given": [ + "Paul" + ] + }, + "telecom": [ + { + "value": "(555)555-1234", + "system": "phone" + } + ] + } + ], + "telecom": [ + { + "value": "(555)123-5678", + "system": "phone" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/0f21af2c-9880-54cb-14a5-5493a766da42" + } + }, + { + "fullUrl": "urn:uuid:fd1eed45-4ccb-bb7c-d157-58eb0366d777", + "resource": { + "resourceType": "RelatedPerson", + "id": "fd1eed45-4ccb-bb7c-d157-58eb0366d777", + "identifier": [ + { + "value": "HMO-12345", + "type": { + "coding": [ + { + "code": "NI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "National unique individual identifier" + } + ] + }, + "system": "urn:oid:2.16.840.1.113883.1.3" + }, + { + "value": "EI-12345", + "type": { + "coding": [ + { + "code": "EI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Employee number" + } + ] + }, + "system": "urn:oid:2.16.840.1.113883.1.4" + }, + { + "value": "425-57-9745", + "type": { + "coding": [ + { + "code": "SS", + "display": "Social Security number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + } + ], + "relationship": [ + { + "coding": [ + { + "code": "SPS", + "display": "spouse", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "address": [ + { + "line": [ + "3857 Velvet Treasure Terrace" + ], + "city": "Midnight", + "state": "NC", + "postalCode": "27878", + "country": "US" + } + ], + "name": [ + { + "family": "Doe", + "given": [ + "Rosallie", + "John" + ], + "suffix": [ + "III", + "Bachelors" + ], + "prefix": [ + "Mrs." + ], + "use": "official" + } + ], + "gender": "female", + "birthDate": "1975-02-28", + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "telecom": [ + { + "value": "(555)123-1234", + "system": "phone" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "en", + "display": "English" + } + ] + }, + "preferred": true + } + ] + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/fd1eed45-4ccb-bb7c-d157-58eb0366d777" + } + }, + { + "fullUrl": "urn:uuid:3622230f-85a9-b313-e26b-eabfc755e34f", + "resource": { + "resourceType": "ServiceRequest", + "id": "3622230f-85a9-b313-e26b-eabfc755e34f", + "status": "active", + "intent": "order", + "identifier": [ + { + "value": "1101", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHHPlacer", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "1201", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHHFiller", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "authoredOn": "2021-10-20T14:41:00+05:30", + "locationCode": [ + { + "coding": [ + { + "code": "OF", + "display": "Outpatient facility", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "code": { + "coding": [ + { + "code": "57698-3", + "display": "Lipid panel with direct LDL - Serum or Plasma", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "requester": { + "reference": "PractitionerRole/d4536528-5e14-2c7a-8d87-c0dcd7311649" + }, + "specimen": [ + { + "reference": "Specimen/b3a1bcae-087f-966b-7cfd-fc61a168d02a" + } + ], + "note": [ + { + "text": "Urgent" + }, + { + "text": "Fasting Sugar" + } + ], + "reasonReference": [ + { + "reference": "Condition/e06055fc-0230-24ef-7d66-7ae83cafb322" + } + ], + "asNeededCodeableConcept": { + "text": "Pain" + }, + "quantityQuantity": { + "value": 1 + }, + "occurrenceTiming": { + "code": { + "coding": [ + { + "code": "Once" + } + ] + }, + "repeat": { + "period": 1, + "periodUnit": "d", + "when": [ + "AC" + ], + "offset": 60, + "boundsDuration": { + "value": 1, + "unit": "Day", + "code": "d", + "system": "http://unitsofmeasure.org" + }, + "duration": 15, + "durationUnit": "min", + "count": 1 + } + }, + "priority": "routine" + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/3622230f-85a9-b313-e26b-eabfc755e34f" + } + }, + { + "fullUrl": "urn:uuid:8af87360-4a75-1531-6192-9bdbb1b0351c", + "resource": { + "resourceType": "Practitioner", + "id": "8af87360-4a75-1531-6192-9bdbb1b0351c", + "identifier": [ + { + "value": "005454" + } + ], + "name": [ + { + "family": "LAB", + "given": [ + "ROBIN", + "B" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/8af87360-4a75-1531-6192-9bdbb1b0351c" + } + }, + { + "fullUrl": "urn:uuid:d4536528-5e14-2c7a-8d87-c0dcd7311649", + "resource": { + "resourceType": "PractitionerRole", + "id": "d4536528-5e14-2c7a-8d87-c0dcd7311649", + "practitioner": { + "reference": "Practitioner/8af87360-4a75-1531-6192-9bdbb1b0351c" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/d4536528-5e14-2c7a-8d87-c0dcd7311649" + } + }, + { + "fullUrl": "urn:uuid:b3a1bcae-087f-966b-7cfd-fc61a168d02a", + "resource": { + "resourceType": "Specimen", + "id": "b3a1bcae-087f-966b-7cfd-fc61a168d02a", + "collection": { + "collectedDateTime": "2021-10-20T15:15:00+05:30" + } + }, + "request": { + "method": "PUT", + "url": "Specimen/b3a1bcae-087f-966b-7cfd-fc61a168d02a" + } + }, + { + "fullUrl": "urn:uuid:e06055fc-0230-24ef-7d66-7ae83cafb322", + "resource": { + "resourceType": "Condition", + "id": "e06055fc-0230-24ef-7d66-7ae83cafb322", + "code": { + "coding": [ + { + "code": "E10.9", + "display": "Diabetes Mellitus Type 1", + "system": "http://hl7.org/fhir/sid/icd-10" + } + ], + "text": "Diabetes" + }, + "onsetDateTime": "2020-05-01T15:45:09+05:30", + "identifier": [ + { + "value": "DG1002" + } + ], + "asserter": { + "reference": "Practitioner/8af87360-4a75-1531-6192-9bdbb1b0351c" + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/condition-assertedDate", + "valueDateTime": "2020-05-01T16:45:15+05:30" + } + ] + }, + "request": { + "method": "PUT", + "url": "Condition/e06055fc-0230-24ef-7d66-7ae83cafb322" + } + }, + { + "fullUrl": "urn:uuid:e82402a9-b2d1-2a28-3250-c099d5a77bf7", + "resource": { + "resourceType": "Organization", + "id": "e82402a9-b2d1-2a28-3250-c099d5a77bf7", + "identifier": [ + { + "value": "PERSt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/e82402a9-b2d1-2a28-3250-c099d5a77bf7" + } + }, + { + "fullUrl": "urn:uuid:ce70e6c3-c190-121d-c251-e4bae5cde6a1", + "resource": { + "resourceType": "Practitioner", + "id": "ce70e6c3-c190-121d-c251-e4bae5cde6a1", + "identifier": [ + { + "value": "1134", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/e82402a9-b2d1-2a28-3250-c099d5a77bf7" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Aly", + "given": [ + "Zafar", + "Mahendra" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/ce70e6c3-c190-121d-c251-e4bae5cde6a1" + } + }, + { + "fullUrl": "urn:uuid:88a53755-c972-6904-b4ce-8884b84ddc2e", + "resource": { + "resourceType": "PractitionerRole", + "id": "88a53755-c972-6904-b4ce-8884b84ddc2e", + "code": [ + { + "coding": [ + { + "code": "ResponsibleObserver", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/ce70e6c3-c190-121d-c251-e4bae5cde6a1" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/88a53755-c972-6904-b4ce-8884b84ddc2e" + } + }, + { + "fullUrl": "urn:uuid:fe0adb86-ebe9-6479-0055-9db8dc1ff99a", + "resource": { + "resourceType": "Device", + "id": "fe0adb86-ebe9-6479-0055-9db8dc1ff99a", + "identifier": [ + { + "value": "EI12.3", + "system": "urn:uuid:UI2", + "type": { + "coding": [ + { + "code": "GUID", + "display": "Same as UUID.", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + }, + { + "system": "urn:oid:UI1", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/fe0adb86-ebe9-6479-0055-9db8dc1ff99a" + } + }, + { + "fullUrl": "urn:uuid:45f65e47-46c4-1a54-f9fb-1321258e79b2", + "resource": { + "resourceType": "Practitioner", + "id": "45f65e47-46c4-1a54-f9fb-1321258e79b2", + "identifier": [ + { + "type": { + "coding": [ + { + "code": "MD-25" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/45f65e47-46c4-1a54-f9fb-1321258e79b2" + } + }, + { + "fullUrl": "urn:uuid:090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3", + "resource": { + "resourceType": "PractitionerRole", + "id": "090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3", + "code": [ + { + "coding": [ + { + "code": "LabMedicalDirector", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/45f65e47-46c4-1a54-f9fb-1321258e79b2" + }, + "organization": { + "reference": "Organization/08c155be-912e-af06-d464-5b6bb63d660f" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3" + } + }, + { + "fullUrl": "urn:uuid:08c155be-912e-af06-d464-5b6bb63d660f", + "resource": { + "resourceType": "Organization", + "id": "08c155be-912e-af06-d464-5b6bb63d660f", + "name": "State Hygienic Laboratory", + "identifier": [ + { + "value": "16D0648109", + "type": { + "coding": [ + { + "code": "FI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "address": [ + { + "line": [ + "State Hygienic Laboratory", + "UI Research Park -Coralville" + ], + "city": "Iowa City", + "state": "IA", + "postalCode": "52242-5002", + "country": "USA", + "use": "work" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/08c155be-912e-af06-d464-5b6bb63d660f" + } + }, + { + "fullUrl": "urn:uuid:07fd2dd3-dbd6-5bb1-cfda-02226795d9a0", + "resource": { + "resourceType": "Observation", + "id": "07fd2dd3-dbd6-5bb1-cfda-02226795d9a0", + "identifier": [ + { + "value": "EI21", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-OII" + }, + { + "type": { + "coding": [ + { + "code": "FILL" + } + ] + } + } + ], + "status": "preliminary", + "code": { + "coding": [ + { + "code": "625-4", + "display": "Bacteria identified in Stool by Culture", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/XYZ", + "version": "2.33" + } + ], + "text": "result1" + }, + "basedOn": [ + { + "reference": "ServiceRequest/3622230f-85a9-b313-e26b-eabfc755e34f" + } + ], + "valueCodeableConcept": { + "coding": [ + { + "code": "27268008", + "display": "Salmonella", + "system": "http://snomed.info/sct", + "version": "20090731" + } + ], + "text": "Salmonella species" + }, + "referenceRange": [ + { + "text": "70-80" + } + ], + "effectiveDateTime": "2012-03-01", + "method": { + "text": "Bacterial Culture" + }, + "device": { + "reference": "Device/fe0adb86-ebe9-6479-0055-9db8dc1ff99a" + }, + "bodySite": { + "coding": [ + { + "code": "BU", + "display": "Observation site", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/E5" + } + ] + }, + "performer": [ + { + "reference": "PractitionerRole/88a53755-c972-6904-b4ce-8884b84ddc2e" + }, + { + "reference": "PractitionerRole/090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3" + } + ], + "interpretation": [ + { + "coding": [ + { + "code": "A", + "display": "Abnormal", + "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation", + "version": "2.5" + } + ] + } + ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "P", + "display": "Preliminary", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Preliminary" + } + } + ], + "note": [ + { + "text": "No Antibodies Detected", + "time": "2020-10-10T18:15:00+05:30", + "authorReference": { + "reference": "Practitioner/ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/07fd2dd3-dbd6-5bb1-cfda-02226795d9a0" + } + }, + { + "fullUrl": "urn:uuid:ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2", + "resource": { + "resourceType": "Practitioner", + "id": "ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2", + "identifier": [ + { + "value": "MLEE" + } + ], + "name": [ + { + "family": "ATTEND", + "given": [ + "AARON", + "A" + ], + "suffix": [ + "MD" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2" + } + }, + { + "fullUrl": "urn:uuid:257786a3-0c2e-44c7-69ea-3456e7152e68", + "resource": { + "resourceType": "DiagnosticReport", + "id": "257786a3-0c2e-44c7-69ea-3456e7152e68", + "code": { + "coding": [ + { + "code": "1063-7", + "display": "Serum or Plasma", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/XYZ", + "version": "2.33" + } + ], + "text": "result1" + }, + "basedOn": [ + { + "reference": "ServiceRequest/3622230f-85a9-b313-e26b-eabfc755e34f" + } + ], + "status": "unknown", + "presentedForm": [ + { + "contentType": "image/pict", + "url": "https://testurl.com" + } + ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "DiagnosticReport/257786a3-0c2e-44c7-69ea-3456e7152e68" + } + }, + { + "fullUrl": "urn:uuid:5dccf96a-1490-c206-c930-bded2f3d05fe", + "resource": { + "resourceType": "Specimen", + "id": "5dccf96a-1490-c206-c930-bded2f3d05fe", + "collection": { + "quantity": { + "value": 40, + "unit": "lbs" + }, + "bodySite": { + "coding": [ + { + "code": "BAP", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/HL70488" + } + ], + "text": "Specimen source site" + }, + "method": { + "coding": [ + { + "code": "BCAE", + "system": "http://terminology.hl7.org/CodeSystem/v2-0488" + } + ] + }, + "collectedPeriod": { + "start": "2011-01-04T04:04:28+05:30", + "end": "2011-11-04T04:04:28+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/specimen-specialHandling", + "valueCodeableConcept": { + "coding": [ + { + "code": "AMB", + "display": "Ambient Temperature", + "system": "http://terminology.hl7.org/CodeSystem/v2-0376" + }, + { + "code": "DRY", + "display": "dry", + "system": "http://terminology.hl7.org/CodeSystem/v2-0376" + } + ] + } + } + ] + }, + "receivedTime": "2012-03-01", + "identifier": [ + { + "value": "2012545", + "type": { + "coding": [ + { + "code": "PGN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "2012999999", + "type": { + "coding": [ + { + "code": "FGN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "OSI-31", + "type": { + "coding": [ + { + "code": "PI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Patient internal identifier" + } + ] + }, + "system": "urn:uuid:2.16.840.1.114222", + "assigner": { + "reference": "Organization/322ca8cf-e43e-973c-3149-9e499675ddca" + } + }, + { + "value": "ShipID-32", + "system": "urn:oid:SID-32", + "type": { + "coding": [ + { + "code": "SHIP", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-identifierType" + } + ] + } + } + ], + "type": { + "coding": [ + { + "code": "ASERU", + "display": "Serum", + "system": "http://terminology.hl7.org/CodeSystem/v2-0487" + }, + { + "code": "FUR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0487" + } + ], + "text": "Blood" + }, + "container": [ + { + "additiveCodeableConcept": { + "coding": [ + { + "code": "STUTM", + "display": "Stuart transport medium", + "system": "http://terminology.hl7.org/CodeSystem/v2-0371", + "version": "20" + }, + { + "code": "PHENOL", + "display": "Stool", + "system": "http://terminology.hl7.org/CodeSystem/v2-0371" + } + ] + }, + "type": { + "coding": [ + { + "code": "T-container", + "display": "ContainerType", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ABC" + } + ] + } + } + ], + "status": "available", + "condition": [ + { + "coding": [ + { + "code": "AUT", + "display": "Autolyzed", + "system": "http://terminology.hl7.org/CodeSystem/v2-0493" + }, + { + "code": "CLOT", + "display": "CLOT", + "system": "http://terminology.hl7.org/CodeSystem/v2-0493" + } + ] + }, + { + "coding": [ + { + "code": "HEM", + "display": "HEM", + "system": "http://terminology.hl7.org/CodeSystem/v2-0493" + } + ] + } + ], + "accessionIdentifier": { + "value": "AI-30", + "type": { + "coding": [ + { + "code": "PI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Patient internal identifier" + } + ] + }, + "system": "urn:oid:2.16.840.1.114222", + "assigner": { + "reference": "Organization/f210e7e3-f1e7-297a-9d54-9db2d312cb96" + } + }, + "note": [ + { + "text": "This is a specimen resource" + } + ], + "request": [ + { + "reference": "ServiceRequest/3622230f-85a9-b313-e26b-eabfc755e34f" + } + ], + "parent": [ + { + "reference": "Specimen/0755f744-dafd-776b-bff7-2d023e54406e" + } + ] + }, + "request": { + "method": "PUT", + "url": "Specimen/5dccf96a-1490-c206-c930-bded2f3d05fe" + } + }, + { + "fullUrl": "urn:uuid:0755f744-dafd-776b-bff7-2d023e54406e", + "resource": { + "resourceType": "Specimen", + "id": "0755f744-dafd-776b-bff7-2d023e54406e", + "identifier": [ + { + "value": "PAI12", + "type": { + "coding": [ + { + "code": "PGN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Specimen/0755f744-dafd-776b-bff7-2d023e54406e" + } + }, + { + "fullUrl": "urn:uuid:f210e7e3-f1e7-297a-9d54-9db2d312cb96", + "resource": { + "resourceType": "Organization", + "id": "f210e7e3-f1e7-297a-9d54-9db2d312cb96", + "identifier": [ + { + "value": "IA PHIMS Stage", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-IA-PHIMS-Stage" + }, + { + "value": "urn:oid:2.16.840.1.114222", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f210e7e3-f1e7-297a-9d54-9db2d312cb96" + } + }, + { + "fullUrl": "urn:uuid:322ca8cf-e43e-973c-3149-9e499675ddca", + "resource": { + "resourceType": "Organization", + "id": "322ca8cf-e43e-973c-3149-9e499675ddca", + "identifier": [ + { + "value": "IPHIMS Stage", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-IPHIMS-Stage" + }, + { + "value": "urn:uuid:2.16.840.1.114222", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "GUID", + "display": "Same as UUID.", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/322ca8cf-e43e-973c-3149-9e499675ddca" + } + }, + { + "fullUrl": "urn:uuid:4355ddc5-5edc-38ea-65e6-cd3479bcd9f5", + "resource": { + "resourceType": "Observation", + "id": "4355ddc5-5edc-38ea-65e6-cd3479bcd9f5", + "status": "unknown", + "code": { + "coding": [ + { + "code": "8867-4", + "display": "Bacteria identified", + "system": "http://loinc.org", + "version": "2.33" + } + ], + "text": "result1" + }, + "component": [ + { + "code": { + "coding": [ + { + "code": "8867-4", + "display": "Bacteria identified", + "system": "http://loinc.org", + "version": "2.33" + } + ], + "text": "result1" + }, + "valueQuantity": { + "value": 27 + } + }, + { + "code": { + "coding": [ + { + "code": "8867-4", + "display": "Bacteria identified", + "system": "http://loinc.org", + "version": "2.33" + } + ], + "text": "result1" + }, + "valueQuantity": { + "value": 25 + } + } + ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "specimen": { + "reference": "Specimen/5dccf96a-1490-c206-c930-bded2f3d05fe" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "I", + "display": "In Process", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "In Process" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/4355ddc5-5edc-38ea-65e6-cd3479bcd9f5" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/OML_O21/OML-O21-02-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/OML_O21/OML-O21-02-expected.json new file mode 100644 index 000000000..feef96c85 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/OML_O21/OML-O21-02-expected.json @@ -0,0 +1,2480 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2021-10-20T14:41:00+05:30", + "identifier": { + "value": "MSG00018" + }, + "id": "4d03cb6d-610f-5d9e-b9ac-f14883a17462", + "entry": [ + { + "fullUrl": "urn:uuid:4f80efdd-5499-39ca-474f-6dca4b4f9a22", + "resource": { + "resourceType": "MessageHeader", + "id": "4f80efdd-5499-39ca-474f-6dca4b4f9a22", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "O01", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "ORM^O01^ORM_O01" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/4f80efdd-5499-39ca-474f-6dca4b4f9a22" + } + }, + { + "fullUrl": "urn:uuid:58988e57-a45e-285b-5942-4480980652df", + "resource": { + "resourceType": "Provenance", + "id": "58988e57-a45e-285b-5942-4480980652df", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:52:56.946Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: OML_O21.

" + }, + "occurredDateTime": "2021-10-20T14:41:00+05:30", + "recorded": "2021-10-20T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "ORM^O01^ORM_O01" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/ad64f1d1-3e5b-a041-c1b3-3e157882ed69" + } + } + ], + "target": [ + { + "reference": "Bundle/4d03cb6d-610f-5d9e-b9ac-f14883a17462" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/58988e57-a45e-285b-5942-4480980652df" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:ad64f1d1-3e5b-a041-c1b3-3e157882ed69", + "resource": { + "resourceType": "Device", + "id": "ad64f1d1-3e5b-a041-c1b3-3e157882ed69", + "identifier": [ + { + "value": "ORDApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/ad64f1d1-3e5b-a041-c1b3-3e157882ed69" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W" + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + } + ], + "contact": [ + { + "name": { + "family": "Abbot", + "given": [ + "Adam", + "A" + ], + "suffix": [ + "III", + "PHD" + ], + "prefix": [ + "DR" + ], + "use": "official" + }, + "address": { + "line": [ + "1000 Hospital Lane", + "Ste.123" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "use": "work" + }, + "telecom": [ + { + "value": "(626)555-1234", + "use": "work", + "system": "phone" + } + ], + "relationship": [ + { + "coding": [ + { + "code": "C", + "display": "Emergency Contact", + "system": "http://terminology.hl7.org/CodeSystem/v2-0131" + } + ] + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:d00df304-17fa-8d9a-bd02-3276b1781ea1", + "resource": { + "resourceType": "Practitioner", + "id": "d00df304-17fa-8d9a-bd02-3276b1781ea1", + "identifier": [ + { + "value": "0210" + } + ], + "name": [ + { + "family": "ATTEND", + "given": [ + "AARON", + "A" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/d00df304-17fa-8d9a-bd02-3276b1781ea1" + } + }, + { + "fullUrl": "urn:uuid:21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9", + "resource": { + "resourceType": "Practitioner", + "id": "21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9", + "identifier": [ + { + "value": "0310" + } + ], + "name": [ + { + "family": "REFER", + "given": [ + "LINDA", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9" + } + }, + { + "fullUrl": "urn:uuid:6c138e7c-e841-af07-8948-d01692bd2739", + "resource": { + "resourceType": "Practitioner", + "id": "6c138e7c-e841-af07-8948-d01692bd2739", + "identifier": [ + { + "value": "03410" + } + ], + "name": [ + { + "family": "ADMIT", + "given": [ + "LINDA", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/6c138e7c-e841-af07-8948-d01692bd2739" + } + }, + { + "fullUrl": "urn:uuid:ed401da2-2b32-f3d0-d128-9766ac20c0ad", + "resource": { + "resourceType": "Location", + "id": "ed401da2-2b32-f3d0-d128-9766ac20c0ad", + "name": "LABUnit01", + "mode": "instance", + "description": "LABUnit01--Room01--GHH", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/ed401da2-2b32-f3d0-d128-9766ac20c0ad" + } + }, + { + "fullUrl": "urn:uuid:ee586d80-706a-5933-8500-a8026c48fb27", + "resource": { + "resourceType": "Location", + "id": "ee586d80-706a-5933-8500-a8026c48fb27", + "partOf": { + "reference": "Location/ed401da2-2b32-f3d0-d128-9766ac20c0ad" + }, + "name": "Room01", + "mode": "instance", + "description": "LABUnit01--Room01--GHH", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/ee586d80-706a-5933-8500-a8026c48fb27" + } + }, + { + "fullUrl": "urn:uuid:3ffd504f-44ae-ce29-6fc0-6baf5bc0a821", + "resource": { + "resourceType": "Location", + "id": "3ffd504f-44ae-ce29-6fc0-6baf5bc0a821", + "name": "GHH", + "mode": "instance", + "description": "LABUnit01--Room01--GHH", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3ffd504f-44ae-ce29-6fc0-6baf5bc0a821" + } + }, + { + "fullUrl": "urn:uuid:5357a3e3-2c50-7c10-6b22-00b646c8b396", + "resource": { + "resourceType": "Location", + "id": "5357a3e3-2c50-7c10-6b22-00b646c8b396", + "name": "TraumaCentre", + "mode": "instance", + "description": "TraumaCentre--ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--GHH1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5357a3e3-2c50-7c10-6b22-00b646c8b396" + } + }, + { + "fullUrl": "urn:uuid:c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "resource": { + "resourceType": "Location", + "id": "c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "partOf": { + "reference": "Location/5357a3e3-2c50-7c10-6b22-00b646c8b396" + }, + "name": "ROOM1", + "identifier": [ + { + "value": "urn:oid:2.16.840.1.113883.4.642.1.1108", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "TraumaCentre--ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--GHH1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + } + }, + { + "fullUrl": "urn:uuid:e9bd830d-8f94-01b9-7562-854da22940d3", + "resource": { + "resourceType": "Location", + "id": "e9bd830d-8f94-01b9-7562-854da22940d3", + "name": "GHH1", + "mode": "instance", + "description": "TraumaCentre--ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--GHH1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/e9bd830d-8f94-01b9-7562-854da22940d3" + } + }, + { + "fullUrl": "urn:uuid:da6f322f-ef5e-4f2c-c1f8-6e38dffbf995", + "resource": { + "resourceType": "Encounter", + "id": "da6f322f-ef5e-4f2c-c1f8-6e38dffbf995", + "class": { + "code": "AMB", + "display": "ambulatory", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "in-progress", + "location": [ + { + "status": "active", + "location": { + "reference": "Location/ed401da2-2b32-f3d0-d128-9766ac20c0ad" + } + }, + { + "status": "completed", + "location": { + "reference": "Location/5357a3e3-2c50-7c10-6b22-00b646c8b396" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/d00df304-17fa-8d9a-bd02-3276b1781ea1" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "ADM", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "admitter" + } + ], + "individual": { + "reference": "Practitioner/6c138e7c-e841-af07-8948-d01692bd2739" + } + } + ], + "identifier": [ + { + "value": "5001", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + } + ], + "period": { + "start": "2021-10-20T14:41:00+05:30" + }, + "text": { + "status": "generated", + "div": "

Visit Description:

" + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "diagnosis": [ + { + "condition": { + "reference": "Condition/e06055fc-0230-24ef-7d66-7ae83cafb322" + }, + "use": { + "coding": [ + { + "code": "DD", + "display": "Discharge Diagnosis", + "system": "http://terminology.hl7.org/CodeSystem/diagnosis-role" + } + ] + }, + "rank": 1 + } + ] + }, + "request": { + "method": "PUT", + "url": "Encounter/da6f322f-ef5e-4f2c-c1f8-6e38dffbf995" + } + }, + { + "fullUrl": "urn:uuid:3622230f-85a9-b313-e26b-eabfc755e34f", + "resource": { + "resourceType": "ServiceRequest", + "id": "3622230f-85a9-b313-e26b-eabfc755e34f", + "status": "active", + "intent": "order", + "identifier": [ + { + "value": "1101", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHHPlacer", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "1201", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHHFiller", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "authoredOn": "2021-10-20T14:41:00+05:30", + "locationCode": [ + { + "coding": [ + { + "code": "OF", + "display": "Outpatient facility", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "code": { + "coding": [ + { + "code": "57698-3", + "display": "Lipid panel with direct LDL - Serum or Plasma", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "requester": { + "reference": "PractitionerRole/d4536528-5e14-2c7a-8d87-c0dcd7311649" + }, + "specimen": [ + { + "reference": "Specimen/b3a1bcae-087f-966b-7cfd-fc61a168d02a" + } + ], + "note": [ + { + "text": "Urgent" + }, + { + "text": "Fasting Sugar" + } + ], + "reasonReference": [ + { + "reference": "Condition/e06055fc-0230-24ef-7d66-7ae83cafb322" + } + ], + "asNeededCodeableConcept": { + "text": "Pain" + }, + "quantityQuantity": { + "value": 1 + }, + "occurrenceTiming": { + "code": { + "coding": [ + { + "code": "Once" + } + ] + }, + "repeat": { + "period": 1, + "periodUnit": "d", + "when": [ + "AC" + ], + "offset": 60, + "boundsDuration": { + "value": 1, + "unit": "Day", + "code": "d", + "system": "http://unitsofmeasure.org" + }, + "duration": 15, + "durationUnit": "min", + "count": 1 + } + }, + "priority": "routine" + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/3622230f-85a9-b313-e26b-eabfc755e34f" + } + }, + { + "fullUrl": "urn:uuid:8af87360-4a75-1531-6192-9bdbb1b0351c", + "resource": { + "resourceType": "Practitioner", + "id": "8af87360-4a75-1531-6192-9bdbb1b0351c", + "identifier": [ + { + "value": "005454" + } + ], + "name": [ + { + "family": "LAB", + "given": [ + "ROBIN", + "B" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/8af87360-4a75-1531-6192-9bdbb1b0351c" + } + }, + { + "fullUrl": "urn:uuid:d4536528-5e14-2c7a-8d87-c0dcd7311649", + "resource": { + "resourceType": "PractitionerRole", + "id": "d4536528-5e14-2c7a-8d87-c0dcd7311649", + "practitioner": { + "reference": "Practitioner/8af87360-4a75-1531-6192-9bdbb1b0351c" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/d4536528-5e14-2c7a-8d87-c0dcd7311649" + } + }, + { + "fullUrl": "urn:uuid:b3a1bcae-087f-966b-7cfd-fc61a168d02a", + "resource": { + "resourceType": "Specimen", + "id": "b3a1bcae-087f-966b-7cfd-fc61a168d02a", + "collection": { + "collectedDateTime": "2021-10-20T15:15:00+05:30" + } + }, + "request": { + "method": "PUT", + "url": "Specimen/b3a1bcae-087f-966b-7cfd-fc61a168d02a" + } + }, + { + "fullUrl": "urn:uuid:e06055fc-0230-24ef-7d66-7ae83cafb322", + "resource": { + "resourceType": "Condition", + "id": "e06055fc-0230-24ef-7d66-7ae83cafb322", + "code": { + "coding": [ + { + "code": "E10.9", + "display": "Diabetes Mellitus Type 1", + "system": "http://hl7.org/fhir/sid/icd-10" + } + ], + "text": "Diabetes" + }, + "onsetDateTime": "2020-05-01T15:45:09+05:30", + "identifier": [ + { + "value": "DG1002" + } + ], + "asserter": { + "reference": "Practitioner/8af87360-4a75-1531-6192-9bdbb1b0351c" + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/condition-assertedDate", + "valueDateTime": "2020-05-01T16:45:15+05:30" + } + ] + }, + "request": { + "method": "PUT", + "url": "Condition/e06055fc-0230-24ef-7d66-7ae83cafb322" + } + }, + { + "fullUrl": "urn:uuid:e82402a9-b2d1-2a28-3250-c099d5a77bf7", + "resource": { + "resourceType": "Organization", + "id": "e82402a9-b2d1-2a28-3250-c099d5a77bf7", + "identifier": [ + { + "value": "PERSt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/e82402a9-b2d1-2a28-3250-c099d5a77bf7" + } + }, + { + "fullUrl": "urn:uuid:ce70e6c3-c190-121d-c251-e4bae5cde6a1", + "resource": { + "resourceType": "Practitioner", + "id": "ce70e6c3-c190-121d-c251-e4bae5cde6a1", + "identifier": [ + { + "value": "1134", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/e82402a9-b2d1-2a28-3250-c099d5a77bf7" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Aly", + "given": [ + "Zafar", + "Mahendra" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/ce70e6c3-c190-121d-c251-e4bae5cde6a1" + } + }, + { + "fullUrl": "urn:uuid:88a53755-c972-6904-b4ce-8884b84ddc2e", + "resource": { + "resourceType": "PractitionerRole", + "id": "88a53755-c972-6904-b4ce-8884b84ddc2e", + "code": [ + { + "coding": [ + { + "code": "ResponsibleObserver", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/ce70e6c3-c190-121d-c251-e4bae5cde6a1" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/88a53755-c972-6904-b4ce-8884b84ddc2e" + } + }, + { + "fullUrl": "urn:uuid:fe0adb86-ebe9-6479-0055-9db8dc1ff99a", + "resource": { + "resourceType": "Device", + "id": "fe0adb86-ebe9-6479-0055-9db8dc1ff99a", + "identifier": [ + { + "value": "EI12.3", + "system": "urn:uuid:UI2", + "type": { + "coding": [ + { + "code": "GUID", + "display": "Same as UUID.", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + }, + { + "system": "urn:oid:UI1", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/fe0adb86-ebe9-6479-0055-9db8dc1ff99a" + } + }, + { + "fullUrl": "urn:uuid:45f65e47-46c4-1a54-f9fb-1321258e79b2", + "resource": { + "resourceType": "Practitioner", + "id": "45f65e47-46c4-1a54-f9fb-1321258e79b2", + "identifier": [ + { + "type": { + "coding": [ + { + "code": "MD-25" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/45f65e47-46c4-1a54-f9fb-1321258e79b2" + } + }, + { + "fullUrl": "urn:uuid:090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3", + "resource": { + "resourceType": "PractitionerRole", + "id": "090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3", + "code": [ + { + "coding": [ + { + "code": "LabMedicalDirector", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/45f65e47-46c4-1a54-f9fb-1321258e79b2" + }, + "organization": { + "reference": "Organization/08c155be-912e-af06-d464-5b6bb63d660f" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3" + } + }, + { + "fullUrl": "urn:uuid:08c155be-912e-af06-d464-5b6bb63d660f", + "resource": { + "resourceType": "Organization", + "id": "08c155be-912e-af06-d464-5b6bb63d660f", + "name": "State Hygienic Laboratory", + "identifier": [ + { + "value": "16D0648109", + "type": { + "coding": [ + { + "code": "FI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "address": [ + { + "line": [ + "State Hygienic Laboratory", + "UI Research Park -Coralville" + ], + "city": "Iowa City", + "state": "IA", + "postalCode": "52242-5002", + "country": "USA", + "use": "work" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/08c155be-912e-af06-d464-5b6bb63d660f" + } + }, + { + "fullUrl": "urn:uuid:07fd2dd3-dbd6-5bb1-cfda-02226795d9a0", + "resource": { + "resourceType": "Observation", + "id": "07fd2dd3-dbd6-5bb1-cfda-02226795d9a0", + "identifier": [ + { + "value": "EI21", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-OII" + }, + { + "type": { + "coding": [ + { + "code": "FILL" + } + ] + } + } + ], + "status": "preliminary", + "code": { + "coding": [ + { + "code": "625-4", + "display": "Bacteria identified in Stool by Culture", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/XYZ", + "version": "2.33" + } + ], + "text": "result1" + }, + "basedOn": [ + { + "reference": "ServiceRequest/3622230f-85a9-b313-e26b-eabfc755e34f" + } + ], + "valueCodeableConcept": { + "coding": [ + { + "code": "27268008", + "display": "Salmonella", + "system": "http://snomed.info/sct", + "version": "20090731" + } + ], + "text": "Salmonella species" + }, + "referenceRange": [ + { + "text": "70-80" + } + ], + "effectiveDateTime": "2012-03-01", + "method": { + "text": "Bacterial Culture" + }, + "device": { + "reference": "Device/fe0adb86-ebe9-6479-0055-9db8dc1ff99a" + }, + "bodySite": { + "coding": [ + { + "code": "BU", + "display": "Observation site", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/E5" + } + ] + }, + "performer": [ + { + "reference": "PractitionerRole/88a53755-c972-6904-b4ce-8884b84ddc2e" + }, + { + "reference": "PractitionerRole/090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3" + } + ], + "interpretation": [ + { + "coding": [ + { + "code": "A", + "display": "Abnormal", + "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation", + "version": "2.5" + } + ] + } + ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "P", + "display": "Preliminary", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Preliminary" + } + } + ], + "note": [ + { + "text": "Submission of serum", + "time": "2020-10-10T19:15:00+05:30", + "authorReference": { + "reference": "Practitioner/ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/07fd2dd3-dbd6-5bb1-cfda-02226795d9a0" + } + }, + { + "fullUrl": "urn:uuid:ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2", + "resource": { + "resourceType": "Practitioner", + "id": "ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2", + "identifier": [ + { + "value": "MLEE" + } + ], + "name": [ + { + "family": "ATTEND", + "given": [ + "AARON", + "A" + ], + "suffix": [ + "MD" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2" + } + }, + { + "fullUrl": "urn:uuid:10189bc7-6ef6-44fc-e74d-a24678a00fc2", + "resource": { + "resourceType": "Specimen", + "id": "10189bc7-6ef6-44fc-e74d-a24678a00fc2", + "collection": { + "quantity": { + "value": 40, + "unit": "lbs" + }, + "bodySite": { + "coding": [ + { + "code": "BAP", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/HL70488" + } + ], + "text": "Specimen source site" + }, + "method": { + "coding": [ + { + "code": "BCAE", + "system": "http://terminology.hl7.org/CodeSystem/v2-0488" + } + ] + }, + "collectedPeriod": { + "start": "2011-01-04T04:04:28+05:30", + "end": "2011-11-04T04:04:28+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/specimen-specialHandling", + "valueCodeableConcept": { + "coding": [ + { + "code": "AMB", + "display": "Ambient Temperature", + "system": "http://terminology.hl7.org/CodeSystem/v2-0376" + }, + { + "code": "DRY", + "display": "dry", + "system": "http://terminology.hl7.org/CodeSystem/v2-0376" + } + ] + } + } + ] + }, + "receivedTime": "2012-03-01", + "identifier": [ + { + "value": "2545", + "type": { + "coding": [ + { + "code": "PGN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "2012999999", + "type": { + "coding": [ + { + "code": "FGN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "OSI-31", + "type": { + "coding": [ + { + "code": "PI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Patient internal identifier" + } + ] + }, + "system": "urn:uuid:2.16.840.1.114222", + "assigner": { + "reference": "Organization/322ca8cf-e43e-973c-3149-9e499675ddca" + } + }, + { + "value": "ShipID-32", + "system": "urn:oid:SID-32", + "type": { + "coding": [ + { + "code": "SHIP", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-identifierType" + } + ] + } + } + ], + "type": { + "coding": [ + { + "code": "ASERU", + "display": "Serum", + "system": "http://terminology.hl7.org/CodeSystem/v2-0487" + }, + { + "code": "FUR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0487" + } + ], + "text": "Blood" + }, + "container": [ + { + "additiveCodeableConcept": { + "coding": [ + { + "code": "STUTM", + "display": "Stuart transport medium", + "system": "http://terminology.hl7.org/CodeSystem/v2-0371", + "version": "20" + }, + { + "code": "PHENOL", + "display": "Stool", + "system": "http://terminology.hl7.org/CodeSystem/v2-0371" + } + ] + }, + "type": { + "coding": [ + { + "code": "T-container", + "display": "ContainerType", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ABC" + } + ] + } + } + ], + "status": "available", + "condition": [ + { + "coding": [ + { + "code": "AUT", + "display": "Autolyzed", + "system": "http://terminology.hl7.org/CodeSystem/v2-0493" + }, + { + "code": "CLOT", + "display": "CLOT", + "system": "http://terminology.hl7.org/CodeSystem/v2-0493" + } + ] + }, + { + "coding": [ + { + "code": "HEM", + "display": "HEM", + "system": "http://terminology.hl7.org/CodeSystem/v2-0493" + } + ] + } + ], + "accessionIdentifier": { + "value": "AI-30", + "type": { + "coding": [ + { + "code": "PI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Patient internal identifier" + } + ] + }, + "system": "urn:oid:2.16.840.1.114222", + "assigner": { + "reference": "Organization/f210e7e3-f1e7-297a-9d54-9db2d312cb96" + } + }, + "note": [ + { + "text": "This is a specimen resource" + } + ], + "request": [ + { + "reference": "ServiceRequest/3622230f-85a9-b313-e26b-eabfc755e34f" + } + ], + "parent": [ + { + "reference": "Specimen/0755f744-dafd-776b-bff7-2d023e54406e" + } + ] + }, + "request": { + "method": "PUT", + "url": "Specimen/10189bc7-6ef6-44fc-e74d-a24678a00fc2" + } + }, + { + "fullUrl": "urn:uuid:0755f744-dafd-776b-bff7-2d023e54406e", + "resource": { + "resourceType": "Specimen", + "id": "0755f744-dafd-776b-bff7-2d023e54406e", + "identifier": [ + { + "value": "PAI12", + "type": { + "coding": [ + { + "code": "PGN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Specimen/0755f744-dafd-776b-bff7-2d023e54406e" + } + }, + { + "fullUrl": "urn:uuid:f210e7e3-f1e7-297a-9d54-9db2d312cb96", + "resource": { + "resourceType": "Organization", + "id": "f210e7e3-f1e7-297a-9d54-9db2d312cb96", + "identifier": [ + { + "value": "IA PHIMS Stage", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-IA-PHIMS-Stage" + }, + { + "value": "urn:oid:2.16.840.1.114222", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f210e7e3-f1e7-297a-9d54-9db2d312cb96" + } + }, + { + "fullUrl": "urn:uuid:322ca8cf-e43e-973c-3149-9e499675ddca", + "resource": { + "resourceType": "Organization", + "id": "322ca8cf-e43e-973c-3149-9e499675ddca", + "identifier": [ + { + "value": "IPHIMS Stage", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-IPHIMS-Stage" + }, + { + "value": "urn:uuid:2.16.840.1.114222", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "GUID", + "display": "Same as UUID.", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/322ca8cf-e43e-973c-3149-9e499675ddca" + } + }, + { + "fullUrl": "urn:uuid:257786a3-0c2e-44c7-69ea-3456e7152e68", + "resource": { + "resourceType": "DiagnosticReport", + "id": "257786a3-0c2e-44c7-69ea-3456e7152e68", + "code": { + "coding": [ + { + "code": "1063-7", + "display": "Serum or Plasma", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/XYZ", + "version": "2.33" + } + ], + "text": "result1" + }, + "status": "unknown", + "presentedForm": [ + { + "contentType": "image/pict", + "url": "https://testurl.com" + } + ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "specimen": [ + { + "reference": "Specimen/10189bc7-6ef6-44fc-e74d-a24678a00fc2" + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/a003235d-4049-0bbd-9cac-d9dee4a90908" + } + ] + }, + "request": { + "method": "PUT", + "url": "DiagnosticReport/257786a3-0c2e-44c7-69ea-3456e7152e68" + } + }, + { + "fullUrl": "urn:uuid:a003235d-4049-0bbd-9cac-d9dee4a90908", + "resource": { + "resourceType": "ServiceRequest", + "id": "a003235d-4049-0bbd-9cac-d9dee4a90908", + "status": "active", + "intent": "order", + "identifier": [ + { + "value": "2203", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHHPlacer", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "2301", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHHFiller", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "authoredOn": "2021-10-20T14:41:00+05:30", + "basedOn": [ + { + "reference": "ServiceRequest/e7554134-0706-cbec-4d30-016ba0bf5d74" + } + ], + "locationCode": [ + { + "coding": [ + { + "code": "OF", + "display": "Outpatient facility", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "quantityQuantity": { + "value": 1 + }, + "occurrenceTiming": { + "repeat": { + "boundsPeriod": { + "start": "2021-10-20T16:15:00+05:30" + } + } + }, + "code": { + "coding": [ + { + "code": "24590-2", + "display": "MR Brain", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "requester": { + "reference": "PractitionerRole/d47a42cd-ee8d-858a-81ba-093cd6c2b737" + }, + "specimen": [ + { + "reference": "Specimen/27d3f840-ef8c-5086-ea3a-4217ca3dca3f" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/a003235d-4049-0bbd-9cac-d9dee4a90908" + } + }, + { + "fullUrl": "urn:uuid:98f6382a-649f-0339-4fa8-982d9760cf42", + "resource": { + "resourceType": "Practitioner", + "id": "98f6382a-649f-0339-4fa8-982d9760cf42", + "identifier": [ + { + "value": "005454" + } + ], + "name": [ + { + "family": "RAD", + "given": [ + "ROBIN", + "B" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/98f6382a-649f-0339-4fa8-982d9760cf42" + } + }, + { + "fullUrl": "urn:uuid:d47a42cd-ee8d-858a-81ba-093cd6c2b737", + "resource": { + "resourceType": "PractitionerRole", + "id": "d47a42cd-ee8d-858a-81ba-093cd6c2b737", + "practitioner": { + "reference": "Practitioner/98f6382a-649f-0339-4fa8-982d9760cf42" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/d47a42cd-ee8d-858a-81ba-093cd6c2b737" + } + }, + { + "fullUrl": "urn:uuid:e7554134-0706-cbec-4d30-016ba0bf5d74", + "resource": { + "resourceType": "ServiceRequest", + "id": "e7554134-0706-cbec-4d30-016ba0bf5d74", + "identifier": [ + { + "value": "PAI-291", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "FAI-292", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "type": { + "coding": [ + { + "code": "test50" + } + ] + } + } + ], + "status": "active", + "intent": "order", + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/e7554134-0706-cbec-4d30-016ba0bf5d74" + } + }, + { + "fullUrl": "urn:uuid:27d3f840-ef8c-5086-ea3a-4217ca3dca3f", + "resource": { + "resourceType": "Specimen", + "id": "27d3f840-ef8c-5086-ea3a-4217ca3dca3f", + "collection": { + "collectedDateTime": "2021-10-20T16:15:00+05:30" + } + }, + "request": { + "method": "PUT", + "url": "Specimen/27d3f840-ef8c-5086-ea3a-4217ca3dca3f" + } + }, + { + "fullUrl": "urn:uuid:5dccf96a-1490-c206-c930-bded2f3d05fe", + "resource": { + "resourceType": "Specimen", + "id": "5dccf96a-1490-c206-c930-bded2f3d05fe", + "collection": { + "quantity": { + "value": 40, + "unit": "lbs" + }, + "bodySite": { + "coding": [ + { + "code": "BAP", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/HL70488" + } + ], + "text": "Specimen source site" + }, + "method": { + "coding": [ + { + "code": "BCAE", + "system": "http://terminology.hl7.org/CodeSystem/v2-0488" + } + ] + }, + "collectedPeriod": { + "start": "2011-01-04T04:04:28+05:30", + "end": "2011-11-04T04:04:28+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/specimen-specialHandling", + "valueCodeableConcept": { + "coding": [ + { + "code": "AMB", + "display": "Ambient Temperature", + "system": "http://terminology.hl7.org/CodeSystem/v2-0376" + }, + { + "code": "DRY", + "display": "dry", + "system": "http://terminology.hl7.org/CodeSystem/v2-0376" + } + ] + } + } + ] + }, + "receivedTime": "2012-03-01", + "identifier": [ + { + "value": "2012545", + "type": { + "coding": [ + { + "code": "PGN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "2012999999", + "type": { + "coding": [ + { + "code": "FGN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "OSI-31", + "type": { + "coding": [ + { + "code": "PI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Patient internal identifier" + } + ] + }, + "system": "urn:uuid:2.16.840.1.114222", + "assigner": { + "reference": "Organization/322ca8cf-e43e-973c-3149-9e499675ddca" + } + }, + { + "value": "ShipID-32", + "system": "urn:oid:SID-32", + "type": { + "coding": [ + { + "code": "SHIP", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-identifierType" + } + ] + } + } + ], + "type": { + "coding": [ + { + "code": "ASERU", + "display": "Serum", + "system": "http://terminology.hl7.org/CodeSystem/v2-0487" + }, + { + "code": "FUR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0487" + } + ], + "text": "Blood" + }, + "container": [ + { + "additiveCodeableConcept": { + "coding": [ + { + "code": "STUTM", + "display": "Stuart transport medium", + "system": "http://terminology.hl7.org/CodeSystem/v2-0371", + "version": "20" + }, + { + "code": "PHENOL", + "display": "Stool", + "system": "http://terminology.hl7.org/CodeSystem/v2-0371" + } + ] + }, + "type": { + "coding": [ + { + "code": "T-container", + "display": "ContainerType", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ABC" + } + ] + } + } + ], + "status": "available", + "condition": [ + { + "coding": [ + { + "code": "AUT", + "display": "Autolyzed", + "system": "http://terminology.hl7.org/CodeSystem/v2-0493" + }, + { + "code": "CLOT", + "display": "CLOT", + "system": "http://terminology.hl7.org/CodeSystem/v2-0493" + } + ] + }, + { + "coding": [ + { + "code": "HEM", + "display": "HEM", + "system": "http://terminology.hl7.org/CodeSystem/v2-0493" + } + ] + } + ], + "accessionIdentifier": { + "value": "AI-30", + "type": { + "coding": [ + { + "code": "PI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Patient internal identifier" + } + ] + }, + "system": "urn:oid:2.16.840.1.114222", + "assigner": { + "reference": "Organization/f210e7e3-f1e7-297a-9d54-9db2d312cb96" + } + }, + "note": [ + { + "text": "This is a specimen resource" + } + ], + "request": [ + { + "reference": "ServiceRequest/a003235d-4049-0bbd-9cac-d9dee4a90908" + } + ], + "parent": [ + { + "reference": "Specimen/0755f744-dafd-776b-bff7-2d023e54406e" + } + ] + }, + "request": { + "method": "PUT", + "url": "Specimen/5dccf96a-1490-c206-c930-bded2f3d05fe" + } + }, + { + "fullUrl": "urn:uuid:4355ddc5-5edc-38ea-65e6-cd3479bcd9f5", + "resource": { + "resourceType": "Observation", + "id": "4355ddc5-5edc-38ea-65e6-cd3479bcd9f5", + "status": "unknown", + "code": { + "coding": [ + { + "code": "8867-4", + "display": "Bacteria identified", + "system": "http://loinc.org", + "version": "2.33" + } + ], + "text": "result1" + }, + "component": [ + { + "code": { + "coding": [ + { + "code": "8867-4", + "display": "Bacteria identified", + "system": "http://loinc.org", + "version": "2.33" + } + ], + "text": "result1" + }, + "valueQuantity": { + "value": 27 + } + }, + { + "code": { + "coding": [ + { + "code": "8867-4", + "display": "Bacteria identified", + "system": "http://loinc.org", + "version": "2.33" + } + ], + "text": "result1" + }, + "valueQuantity": { + "value": 25 + } + } + ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "specimen": { + "reference": "Specimen/5dccf96a-1490-c206-c930-bded2f3d05fe" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "I", + "display": "In Process", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "In Process" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/4355ddc5-5edc-38ea-65e6-cd3479bcd9f5" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORM_O01/ORM-O01-01-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORM_O01/ORM-O01-01-expected.json new file mode 100644 index 000000000..26296caf2 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORM_O01/ORM-O01-01-expected.json @@ -0,0 +1,1362 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2021-10-20T14:41:00+05:30", + "identifier": { + "value": "MSG00018" + }, + "id": "4d03cb6d-610f-5d9e-b9ac-f14883a17462", + "entry": [ + { + "fullUrl": "urn:uuid:4f80efdd-5499-39ca-474f-6dca4b4f9a22", + "resource": { + "resourceType": "MessageHeader", + "id": "4f80efdd-5499-39ca-474f-6dca4b4f9a22", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "O01", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "ORM^O01^ORM_O01" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/4f80efdd-5499-39ca-474f-6dca4b4f9a22" + } + }, + { + "fullUrl": "urn:uuid:58988e57-a45e-285b-5942-4480980652df", + "resource": { + "resourceType": "Provenance", + "id": "58988e57-a45e-285b-5942-4480980652df", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:51:19.004Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ORM_O01.

" + }, + "occurredDateTime": "2021-10-20T14:41:00+05:30", + "recorded": "2021-10-20T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "ORM^O01^ORM_O01" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/ad64f1d1-3e5b-a041-c1b3-3e157882ed69" + } + } + ], + "target": [ + { + "reference": "Bundle/4d03cb6d-610f-5d9e-b9ac-f14883a17462" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/58988e57-a45e-285b-5942-4480980652df" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:ad64f1d1-3e5b-a041-c1b3-3e157882ed69", + "resource": { + "resourceType": "Device", + "id": "ad64f1d1-3e5b-a041-c1b3-3e157882ed69", + "identifier": [ + { + "value": "ORDApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/ad64f1d1-3e5b-a041-c1b3-3e157882ed69" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + } + ], + "contact": [ + { + "name": { + "family": "Doe", + "given": [ + "Rosallie" + ] + }, + "address": { + "line": [ + "115 MAINSTREET" + ], + "city": "GOODTOWN", + "state": "KY", + "postalCode": "42010", + "country": "USA" + }, + "telecom": [ + { + "value": "(608)271-9001", + "use": "work", + "system": "phone" + } + ], + "relationship": [ + { + "coding": [ + { + "code": "C", + "display": "Emergency Contact", + "system": "http://terminology.hl7.org/CodeSystem/v2-0131" + } + ] + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:d00df304-17fa-8d9a-bd02-3276b1781ea1", + "resource": { + "resourceType": "Practitioner", + "id": "d00df304-17fa-8d9a-bd02-3276b1781ea1", + "identifier": [ + { + "value": "0210" + } + ], + "name": [ + { + "family": "ATTEND", + "given": [ + "AARON", + "A" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/d00df304-17fa-8d9a-bd02-3276b1781ea1" + } + }, + { + "fullUrl": "urn:uuid:21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9", + "resource": { + "resourceType": "Practitioner", + "id": "21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9", + "identifier": [ + { + "value": "0310" + } + ], + "name": [ + { + "family": "REFER", + "given": [ + "LINDA", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9" + } + }, + { + "fullUrl": "urn:uuid:6c138e7c-e841-af07-8948-d01692bd2739", + "resource": { + "resourceType": "Practitioner", + "id": "6c138e7c-e841-af07-8948-d01692bd2739", + "identifier": [ + { + "value": "03410" + } + ], + "name": [ + { + "family": "ADMIT", + "given": [ + "LINDA", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/6c138e7c-e841-af07-8948-d01692bd2739" + } + }, + { + "fullUrl": "urn:uuid:b9b31f37-678e-aade-7d5d-1375a513f673", + "resource": { + "resourceType": "Location", + "id": "b9b31f37-678e-aade-7d5d-1375a513f673", + "name": "RADUnit01", + "mode": "instance", + "description": "RADUnit01--Room01--GHH", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/b9b31f37-678e-aade-7d5d-1375a513f673" + } + }, + { + "fullUrl": "urn:uuid:ee586d80-706a-5933-8500-a8026c48fb27", + "resource": { + "resourceType": "Location", + "id": "ee586d80-706a-5933-8500-a8026c48fb27", + "partOf": { + "reference": "Location/b9b31f37-678e-aade-7d5d-1375a513f673" + }, + "name": "Room01", + "mode": "instance", + "description": "RADUnit01--Room01--GHH", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/ee586d80-706a-5933-8500-a8026c48fb27" + } + }, + { + "fullUrl": "urn:uuid:3ffd504f-44ae-ce29-6fc0-6baf5bc0a821", + "resource": { + "resourceType": "Location", + "id": "3ffd504f-44ae-ce29-6fc0-6baf5bc0a821", + "name": "GHH", + "mode": "instance", + "description": "RADUnit01--Room01--GHH", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3ffd504f-44ae-ce29-6fc0-6baf5bc0a821" + } + }, + { + "fullUrl": "urn:uuid:5357a3e3-2c50-7c10-6b22-00b646c8b396", + "resource": { + "resourceType": "Location", + "id": "5357a3e3-2c50-7c10-6b22-00b646c8b396", + "name": "TraumaCentre", + "mode": "instance", + "description": "TraumaCentre--ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--GHH1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5357a3e3-2c50-7c10-6b22-00b646c8b396" + } + }, + { + "fullUrl": "urn:uuid:c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "resource": { + "resourceType": "Location", + "id": "c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "partOf": { + "reference": "Location/5357a3e3-2c50-7c10-6b22-00b646c8b396" + }, + "name": "ROOM1", + "identifier": [ + { + "value": "urn:oid:2.16.840.1.113883.4.642.1.1108", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "TraumaCentre--ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--GHH1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + } + }, + { + "fullUrl": "urn:uuid:e9bd830d-8f94-01b9-7562-854da22940d3", + "resource": { + "resourceType": "Location", + "id": "e9bd830d-8f94-01b9-7562-854da22940d3", + "name": "GHH1", + "mode": "instance", + "description": "TraumaCentre--ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--GHH1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/e9bd830d-8f94-01b9-7562-854da22940d3" + } + }, + { + "fullUrl": "urn:uuid:da6f322f-ef5e-4f2c-c1f8-6e38dffbf995", + "resource": { + "resourceType": "Encounter", + "id": "da6f322f-ef5e-4f2c-c1f8-6e38dffbf995", + "class": { + "code": "AMB", + "display": "ambulatory", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "in-progress", + "location": [ + { + "status": "active", + "location": { + "reference": "Location/b9b31f37-678e-aade-7d5d-1375a513f673" + } + }, + { + "status": "completed", + "location": { + "reference": "Location/5357a3e3-2c50-7c10-6b22-00b646c8b396" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/d00df304-17fa-8d9a-bd02-3276b1781ea1" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "ADM", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "admitter" + } + ], + "individual": { + "reference": "Practitioner/6c138e7c-e841-af07-8948-d01692bd2739" + } + } + ], + "identifier": [ + { + "value": "5001", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + } + ], + "period": { + "start": "2021-10-20T15:15:00+05:30" + }, + "text": { + "status": "generated", + "div": "

Visit Description:

" + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "diagnosis": [ + { + "condition": { + "reference": "Condition/97303ad2-9731-b8ac-465e-560ad9ac67ec" + }, + "use": { + "coding": [ + { + "code": "DD", + "display": "Discharge Diagnosis", + "system": "http://terminology.hl7.org/CodeSystem/diagnosis-role" + } + ] + }, + "rank": 1 + } + ] + }, + "request": { + "method": "PUT", + "url": "Encounter/da6f322f-ef5e-4f2c-c1f8-6e38dffbf995" + } + }, + { + "fullUrl": "urn:uuid:a0adcda8-0b28-d089-1955-c04308d5fe28", + "resource": { + "resourceType": "AllergyIntolerance", + "id": "a0adcda8-0b28-d089-1955-c04308d5fe28", + "category": [ + "environment" + ], + "type": "allergy", + "code": { + "coding": [ + { + "code": "P", + "display": "PENICILLIN", + "system": "http://terminology.hl7.org/CodeSystem/icd-o" + } + ] + }, + "reaction": [ + { + "manifestation": [ + { + "text": "CODE16" + } + ], + "onset": "2021-08-24" + } + ], + "criticality": "low", + "clinicalStatus": { + "coding": [ + { + "code": "active", + "display": "Active", + "system": "http://terminology.hl7.org/CodeSystem/allergyintolerance-clinical" + } + ] + }, + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "AllergyIntolerance/a0adcda8-0b28-d089-1955-c04308d5fe28" + } + }, + { + "fullUrl": "urn:uuid:3622230f-85a9-b313-e26b-eabfc755e34f", + "resource": { + "resourceType": "ServiceRequest", + "id": "3622230f-85a9-b313-e26b-eabfc755e34f", + "status": "active", + "intent": "order", + "identifier": [ + { + "value": "1101", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHHPlacer", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "1201", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHHFiller", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "authoredOn": "2021-10-20T14:41:00+05:30", + "locationCode": [ + { + "coding": [ + { + "code": "OF", + "display": "Outpatient facility", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "note": [ + { + "text": "Annotation text" + } + ], + "quantityQuantity": { + "value": 12, + "unit": "lb" + }, + "occurrenceTiming": { + "code": { + "coding": [ + { + "code": "BID" + } + ] + }, + "repeat": { + "durationUnit": "s", + "duration": 50, + "count": 21, + "timeOfDay": [ + "12:30:05" + ], + "boundsPeriod": { + "start": "2002-03-15", + "end": "2003-03-15" + } + } + }, + "code": { + "coding": [ + { + "code": "24725-4", + "display": "CT Head", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "requester": { + "reference": "PractitionerRole/d47a42cd-ee8d-858a-81ba-093cd6c2b737" + }, + "specimen": [ + { + "reference": "Specimen/5c78ccc8-7800-aa68-7da7-7985254fafc3" + } + ], + "reasonReference": [ + { + "reference": "Condition/97303ad2-9731-b8ac-465e-560ad9ac67ec" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/3622230f-85a9-b313-e26b-eabfc755e34f" + } + }, + { + "fullUrl": "urn:uuid:98f6382a-649f-0339-4fa8-982d9760cf42", + "resource": { + "resourceType": "Practitioner", + "id": "98f6382a-649f-0339-4fa8-982d9760cf42", + "identifier": [ + { + "value": "005454" + } + ], + "name": [ + { + "family": "RAD", + "given": [ + "ROBIN", + "B" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/98f6382a-649f-0339-4fa8-982d9760cf42" + } + }, + { + "fullUrl": "urn:uuid:d47a42cd-ee8d-858a-81ba-093cd6c2b737", + "resource": { + "resourceType": "PractitionerRole", + "id": "d47a42cd-ee8d-858a-81ba-093cd6c2b737", + "practitioner": { + "reference": "Practitioner/98f6382a-649f-0339-4fa8-982d9760cf42" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/d47a42cd-ee8d-858a-81ba-093cd6c2b737" + } + }, + { + "fullUrl": "urn:uuid:5c78ccc8-7800-aa68-7da7-7985254fafc3", + "resource": { + "resourceType": "Specimen", + "id": "5c78ccc8-7800-aa68-7da7-7985254fafc3", + "collection": { + "collectedDateTime": "2021-10-20T15:15:00+05:30" + } + }, + "request": { + "method": "PUT", + "url": "Specimen/5c78ccc8-7800-aa68-7da7-7985254fafc3" + } + }, + { + "fullUrl": "urn:uuid:97303ad2-9731-b8ac-465e-560ad9ac67ec", + "resource": { + "resourceType": "Condition", + "id": "97303ad2-9731-b8ac-465e-560ad9ac67ec", + "code": { + "coding": [ + { + "code": "S06.9", + "display": "TBI(traumatic brain injury", + "system": "http://hl7.org/fhir/sid/icd-10" + } + ], + "text": "Traumatic brain injury" + }, + "onsetDateTime": "2020-05-01T15:45:09+05:30", + "identifier": [ + { + "value": "DG1002" + } + ], + "asserter": { + "reference": "Practitioner/98f6382a-649f-0339-4fa8-982d9760cf42" + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/condition-assertedDate", + "valueDateTime": "2020-05-01T16:45:15+05:30" + } + ] + }, + "request": { + "method": "PUT", + "url": "Condition/97303ad2-9731-b8ac-465e-560ad9ac67ec" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORM_O01/ORM-O01-02-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORM_O01/ORM-O01-02-expected.json new file mode 100644 index 000000000..3071181fd --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORM_O01/ORM-O01-02-expected.json @@ -0,0 +1,2263 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2021-10-20T14:41:00+05:30", + "identifier": { + "value": "MSG00019" + }, + "id": "850fa16f-dec7-80c7-978f-7276e0f16e62", + "entry": [ + { + "fullUrl": "urn:uuid:85946184-5877-2309-6765-683c677d000d", + "resource": { + "resourceType": "MessageHeader", + "id": "85946184-5877-2309-6765-683c677d000d", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "O01", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "ORM^O01^ORM_O01" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/85946184-5877-2309-6765-683c677d000d" + } + }, + { + "fullUrl": "urn:uuid:58988e57-a45e-285b-5942-4480980652df", + "resource": { + "resourceType": "Provenance", + "id": "58988e57-a45e-285b-5942-4480980652df", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:51:39.847Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ORM_O01.

" + }, + "occurredDateTime": "2021-10-20T14:41:00+05:30", + "recorded": "2021-10-20T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "ORM^O01^ORM_O01" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/ad64f1d1-3e5b-a041-c1b3-3e157882ed69" + } + } + ], + "target": [ + { + "reference": "Bundle/850fa16f-dec7-80c7-978f-7276e0f16e62" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/58988e57-a45e-285b-5942-4480980652df" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:ad64f1d1-3e5b-a041-c1b3-3e157882ed69", + "resource": { + "resourceType": "Device", + "id": "ad64f1d1-3e5b-a041-c1b3-3e157882ed69", + "identifier": [ + { + "value": "ORDApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/ad64f1d1-3e5b-a041-c1b3-3e157882ed69" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + }, + { + "value": "Medicare-12345", + "type": { + "coding": [ + { + "code": "MC", + "display": "Patient's Medicare number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-medicare" + }, + { + "value": "MI-12345", + "type": { + "coding": [ + { + "code": "MI", + "display": "Military ID number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/identifier-military" + }, + { + "value": "MB-12345", + "type": { + "coding": [ + { + "code": "MB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Member Number" + } + ] + }, + "system": "urn:oid:2.16.840.1.113883.1.5" + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + } + ], + "contact": [ + { + "name": { + "family": "Abbot", + "given": [ + "Adam", + "A" + ], + "suffix": [ + "III", + "PHD" + ], + "prefix": [ + "DR" + ], + "use": "official" + }, + "address": { + "line": [ + "1000 Hospital Lane", + "Ste.123" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "use": "work" + }, + "telecom": [ + { + "value": "(626)555-1234", + "use": "work", + "system": "phone" + } + ], + "relationship": [ + { + "coding": [ + { + "code": "C", + "display": "Emergency Contact", + "system": "http://terminology.hl7.org/CodeSystem/v2-0131" + } + ] + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ], + "guarantor": [ + { + "party": { + "reference": "RelatedPerson/e42e5df9-fef2-9072-3b17-3f2475927f98" + }, + "onHold": false, + "period": { + "start": "2016-01-01" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:e42e5df9-fef2-9072-3b17-3f2475927f98", + "resource": { + "resourceType": "RelatedPerson", + "id": "e42e5df9-fef2-9072-3b17-3f2475927f98", + "identifier": [ + { + "value": "1516" + }, + { + "value": "19290207" + }, + { + "value": "2245367687", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MOT", + "display": "MOT" + } + ] + } + ], + "address": [ + { + "line": [ + "1619 SOUTH UNIVERSITY" + ], + "city": "MADISON", + "state": "WI", + "postalCode": "53703", + "country": "US" + } + ], + "telecom": [ + { + "value": "(608)251-7777", + "system": "phone", + "use": "home" + }, + { + "value": "(608)2517777", + "system": "phone", + "use": "work" + } + ], + "name": [ + { + "family": "RADIANT", + "given": [ + "LUCY" + ] + } + ], + "gender": "female", + "birthDate": "2001-04-12", + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/e42e5df9-fef2-9072-3b17-3f2475927f98" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:d00df304-17fa-8d9a-bd02-3276b1781ea1", + "resource": { + "resourceType": "Practitioner", + "id": "d00df304-17fa-8d9a-bd02-3276b1781ea1", + "identifier": [ + { + "value": "0210" + } + ], + "name": [ + { + "family": "ATTEND", + "given": [ + "AARON", + "A" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/d00df304-17fa-8d9a-bd02-3276b1781ea1" + } + }, + { + "fullUrl": "urn:uuid:21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9", + "resource": { + "resourceType": "Practitioner", + "id": "21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9", + "identifier": [ + { + "value": "0310" + } + ], + "name": [ + { + "family": "REFER", + "given": [ + "LINDA", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9" + } + }, + { + "fullUrl": "urn:uuid:6c138e7c-e841-af07-8948-d01692bd2739", + "resource": { + "resourceType": "Practitioner", + "id": "6c138e7c-e841-af07-8948-d01692bd2739", + "identifier": [ + { + "value": "03410" + } + ], + "name": [ + { + "family": "ADMIT", + "given": [ + "LINDA", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/6c138e7c-e841-af07-8948-d01692bd2739" + } + }, + { + "fullUrl": "urn:uuid:b9b31f37-678e-aade-7d5d-1375a513f673", + "resource": { + "resourceType": "Location", + "id": "b9b31f37-678e-aade-7d5d-1375a513f673", + "name": "RADUnit01", + "mode": "instance", + "description": "RADUnit01--Room01--GHH", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/b9b31f37-678e-aade-7d5d-1375a513f673" + } + }, + { + "fullUrl": "urn:uuid:ee586d80-706a-5933-8500-a8026c48fb27", + "resource": { + "resourceType": "Location", + "id": "ee586d80-706a-5933-8500-a8026c48fb27", + "partOf": { + "reference": "Location/b9b31f37-678e-aade-7d5d-1375a513f673" + }, + "name": "Room01", + "mode": "instance", + "description": "RADUnit01--Room01--GHH", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/ee586d80-706a-5933-8500-a8026c48fb27" + } + }, + { + "fullUrl": "urn:uuid:3ffd504f-44ae-ce29-6fc0-6baf5bc0a821", + "resource": { + "resourceType": "Location", + "id": "3ffd504f-44ae-ce29-6fc0-6baf5bc0a821", + "name": "GHH", + "mode": "instance", + "description": "RADUnit01--Room01--GHH", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3ffd504f-44ae-ce29-6fc0-6baf5bc0a821" + } + }, + { + "fullUrl": "urn:uuid:5357a3e3-2c50-7c10-6b22-00b646c8b396", + "resource": { + "resourceType": "Location", + "id": "5357a3e3-2c50-7c10-6b22-00b646c8b396", + "name": "TraumaCentre", + "mode": "instance", + "description": "TraumaCentre--ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--GHH1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5357a3e3-2c50-7c10-6b22-00b646c8b396" + } + }, + { + "fullUrl": "urn:uuid:c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "resource": { + "resourceType": "Location", + "id": "c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "partOf": { + "reference": "Location/5357a3e3-2c50-7c10-6b22-00b646c8b396" + }, + "name": "ROOM1", + "identifier": [ + { + "value": "urn:oid:2.16.840.1.113883.4.642.1.1108", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "TraumaCentre--ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--GHH1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + } + }, + { + "fullUrl": "urn:uuid:e9bd830d-8f94-01b9-7562-854da22940d3", + "resource": { + "resourceType": "Location", + "id": "e9bd830d-8f94-01b9-7562-854da22940d3", + "name": "GHH1", + "mode": "instance", + "description": "TraumaCentre--ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--GHH1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/e9bd830d-8f94-01b9-7562-854da22940d3" + } + }, + { + "fullUrl": "urn:uuid:da6f322f-ef5e-4f2c-c1f8-6e38dffbf995", + "resource": { + "resourceType": "Encounter", + "id": "da6f322f-ef5e-4f2c-c1f8-6e38dffbf995", + "class": { + "code": "AMB", + "display": "ambulatory", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "in-progress", + "location": [ + { + "status": "active", + "location": { + "reference": "Location/b9b31f37-678e-aade-7d5d-1375a513f673" + } + }, + { + "status": "completed", + "location": { + "reference": "Location/5357a3e3-2c50-7c10-6b22-00b646c8b396" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/d00df304-17fa-8d9a-bd02-3276b1781ea1" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "ADM", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "admitter" + } + ], + "individual": { + "reference": "Practitioner/6c138e7c-e841-af07-8948-d01692bd2739" + } + } + ], + "identifier": [ + { + "value": "5001", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + } + ], + "period": { + "start": "2021-10-20T15:15:00+05:30" + }, + "text": { + "status": "generated", + "div": "

Visit Description:

" + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "diagnosis": [ + { + "condition": { + "reference": "Condition/97303ad2-9731-b8ac-465e-560ad9ac67ec" + }, + "use": { + "coding": [ + { + "code": "DD", + "display": "Discharge Diagnosis", + "system": "http://terminology.hl7.org/CodeSystem/diagnosis-role" + } + ] + }, + "rank": 1 + } + ] + }, + "request": { + "method": "PUT", + "url": "Encounter/da6f322f-ef5e-4f2c-c1f8-6e38dffbf995" + } + }, + { + "fullUrl": "urn:uuid:dfab6985-a691-c4f5-d2b2-6481fdfd59e4", + "resource": { + "resourceType": "Coverage", + "id": "dfab6985-a691-c4f5-d2b2-6481fdfd59e4", + "class": [ + { + "value": "BAV", + "name": "Blue Advantage HMO", + "type": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/coverage-class", + "code": "plan", + "display": "Plan" + } + ] + } + }, + { + "value": "Grp-12345", + "name": "BCBS HMO", + "type": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/coverage-class", + "code": "group", + "display": "Group" + } + ] + } + } + ], + "network": "Blue Advantage HMO", + "period": { + "start": "1998-11-01" + }, + "type": { + "coding": [ + { + "code": "HMO", + "display": "health maintenance organization policy", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + } + ] + }, + "identifier": [ + { + "value": "548851236L", + "type": { + "coding": [ + { + "code": "PLN", + "display": "Policy Number", + "system": "http://example.com/CodeSystem/additional-identifier" + } + ] + }, + "system": "http://www.examplehealthplan.com/fhir/policyidentifier" + }, + { + "value": "Medicare-12345", + "type": { + "coding": [ + { + "code": "MC", + "display": "Patient's Medicare number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-medicare" + }, + { + "value": "MB-12345", + "type": { + "coding": [ + { + "code": "MB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Member Number" + } + ] + }, + "system": "urn:oid:2.16.840.1.113883.1.5" + } + ], + "costToBeneficiary": [ + { + "type": { + "coding": [ + { + "code": "DC", + "display": "direct unit cost", + "system": "http://terminology.hl7.org/CodeSystem/v2-0205" + } + ] + }, + "valueMoney": { + "value": 150, + "currency": "USD" + } + } + ], + "subscriberId": "HMO-12345", + "status": "active", + "beneficiary": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "payor": [ + { + "reference": "Organization/04a2a5f2-c971-1e42-e788-250ea487a889" + } + ], + "policyHolder": { + "reference": "Organization/0f21af2c-9880-54cb-14a5-5493a766da42" + }, + "subscriber": { + "reference": "RelatedPerson/fd1eed45-4ccb-bb7c-d157-58eb0366d777" + }, + "relationship": { + "coding": [ + { + "code": "spouse", + "display": "Spouse", + "system": "http://terminology.hl7.org/CodeSystem/subscriber-relationship" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Coverage/dfab6985-a691-c4f5-d2b2-6481fdfd59e4" + } + }, + { + "fullUrl": "urn:uuid:04a2a5f2-c971-1e42-e788-250ea487a889", + "resource": { + "resourceType": "Organization", + "id": "04a2a5f2-c971-1e42-e788-250ea487a889", + "address": [ + { + "line": [ + "1979 MILKY WAY" + ], + "city": "VERONA", + "state": "WI", + "postalCode": "53593", + "country": "US" + } + ], + "contact": [ + { + "name": { + "family": "Roger", + "given": [ + "Dann" + ] + } + } + ], + "telecom": [ + { + "value": "(555)555-5555", + "system": "phone" + } + ], + "identifier": [ + { + "value": "Org-12345", + "type": { + "coding": [ + { + "code": "NIIP", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "National Insurance Payor Identifier (Payor)" + } + ] + }, + "system": "urn:oid:2.16.840.1.113883.1.1" + } + ], + "name": "Blue Cross Blue Shield of Texas" + }, + "request": { + "method": "PUT", + "url": "Organization/04a2a5f2-c971-1e42-e788-250ea487a889" + } + }, + { + "fullUrl": "urn:uuid:0f21af2c-9880-54cb-14a5-5493a766da42", + "resource": { + "resourceType": "Organization", + "id": "0f21af2c-9880-54cb-14a5-5493a766da42", + "address": [ + { + "line": [ + "2000 MILKY WAY" + ], + "city": "VERONA", + "state": "WI", + "postalCode": "53593", + "country": "US" + } + ], + "identifier": [ + { + "value": "Tel-12345", + "type": { + "coding": [ + { + "code": "EN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Employer number" + } + ] + }, + "system": "urn:oid:2.16.840.1.113883.1.2" + } + ], + "name": "Telstra", + "contact": [ + { + "name": { + "family": "Richard", + "given": [ + "Paul" + ] + }, + "telecom": [ + { + "value": "(555)555-1234", + "system": "phone" + } + ] + } + ], + "telecom": [ + { + "value": "(555)123-5678", + "system": "phone" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/0f21af2c-9880-54cb-14a5-5493a766da42" + } + }, + { + "fullUrl": "urn:uuid:fd1eed45-4ccb-bb7c-d157-58eb0366d777", + "resource": { + "resourceType": "RelatedPerson", + "id": "fd1eed45-4ccb-bb7c-d157-58eb0366d777", + "identifier": [ + { + "value": "HMO-12345", + "type": { + "coding": [ + { + "code": "NI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "National unique individual identifier" + } + ] + }, + "system": "urn:oid:2.16.840.1.113883.1.3" + }, + { + "value": "EI-12345", + "type": { + "coding": [ + { + "code": "EI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Employee number" + } + ] + }, + "system": "urn:oid:2.16.840.1.113883.1.4" + }, + { + "value": "425-57-9745", + "type": { + "coding": [ + { + "code": "SS", + "display": "Social Security number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + } + ], + "relationship": [ + { + "coding": [ + { + "code": "SPS", + "display": "spouse", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "address": [ + { + "line": [ + "3857 Velvet Treasure Terrace" + ], + "city": "Midnight", + "state": "NC", + "postalCode": "27878", + "country": "US" + } + ], + "name": [ + { + "family": "Doe", + "given": [ + "Rosallie", + "John" + ], + "suffix": [ + "III", + "Bachelors" + ], + "prefix": [ + "Mrs." + ], + "use": "official" + } + ], + "gender": "female", + "birthDate": "1975-02-28", + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "telecom": [ + { + "value": "(555)123-1234", + "system": "phone" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "en", + "display": "English" + } + ] + }, + "preferred": true + } + ] + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/fd1eed45-4ccb-bb7c-d157-58eb0366d777" + } + }, + { + "fullUrl": "urn:uuid:094b7010-27ec-6a4f-5089-1b2433b7824d", + "resource": { + "resourceType": "AllergyIntolerance", + "id": "094b7010-27ec-6a4f-5089-1b2433b7824d", + "category": [ + "medication" + ], + "type": "allergy", + "code": { + "coding": [ + { + "code": "XYZallergen" + } + ] + }, + "reaction": [ + { + "manifestation": [ + { + "text": "moderate" + } + ], + "onset": "2021-01-21" + } + ], + "criticality": "low", + "clinicalStatus": { + "coding": [ + { + "code": "active", + "display": "Active", + "system": "http://terminology.hl7.org/CodeSystem/allergyintolerance-clinical" + } + ] + }, + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "AllergyIntolerance/094b7010-27ec-6a4f-5089-1b2433b7824d" + } + }, + { + "fullUrl": "urn:uuid:3622230f-85a9-b313-e26b-eabfc755e34f", + "resource": { + "resourceType": "ServiceRequest", + "id": "3622230f-85a9-b313-e26b-eabfc755e34f", + "status": "active", + "intent": "order", + "identifier": [ + { + "value": "1101", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHHPlacer", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "1201", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHHFiller", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "authoredOn": "2021-10-20T14:41:00+05:30", + "locationCode": [ + { + "coding": [ + { + "code": "OF", + "display": "Outpatient facility", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "quantityQuantity": { + "value": 1 + }, + "occurrenceTiming": { + "repeat": { + "boundsPeriod": { + "start": "2021-10-20T14:41:00+05:30" + } + } + }, + "code": { + "coding": [ + { + "code": "24725-4", + "display": "CT Head", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "requester": { + "reference": "PractitionerRole/d47a42cd-ee8d-858a-81ba-093cd6c2b737" + }, + "specimen": [ + { + "reference": "Specimen/c3574395-5ad6-bf2a-9907-c1a7caa8c850" + } + ], + "note": [ + { + "text": "CT Scan to be done urgent" + } + ], + "reasonReference": [ + { + "reference": "Condition/97303ad2-9731-b8ac-465e-560ad9ac67ec" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/3622230f-85a9-b313-e26b-eabfc755e34f" + } + }, + { + "fullUrl": "urn:uuid:98f6382a-649f-0339-4fa8-982d9760cf42", + "resource": { + "resourceType": "Practitioner", + "id": "98f6382a-649f-0339-4fa8-982d9760cf42", + "identifier": [ + { + "value": "005454" + } + ], + "name": [ + { + "family": "RAD", + "given": [ + "ROBIN", + "B" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/98f6382a-649f-0339-4fa8-982d9760cf42" + } + }, + { + "fullUrl": "urn:uuid:d47a42cd-ee8d-858a-81ba-093cd6c2b737", + "resource": { + "resourceType": "PractitionerRole", + "id": "d47a42cd-ee8d-858a-81ba-093cd6c2b737", + "practitioner": { + "reference": "Practitioner/98f6382a-649f-0339-4fa8-982d9760cf42" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/d47a42cd-ee8d-858a-81ba-093cd6c2b737" + } + }, + { + "fullUrl": "urn:uuid:c3574395-5ad6-bf2a-9907-c1a7caa8c850", + "resource": { + "resourceType": "Specimen", + "id": "c3574395-5ad6-bf2a-9907-c1a7caa8c850", + "collection": { + "collectedDateTime": "2021-10-20T15:15:00+05:30" + } + }, + "request": { + "method": "PUT", + "url": "Specimen/c3574395-5ad6-bf2a-9907-c1a7caa8c850" + } + }, + { + "fullUrl": "urn:uuid:97303ad2-9731-b8ac-465e-560ad9ac67ec", + "resource": { + "resourceType": "Condition", + "id": "97303ad2-9731-b8ac-465e-560ad9ac67ec", + "code": { + "coding": [ + { + "code": "S06.9", + "display": "TBI(traumatic brain injury", + "system": "http://hl7.org/fhir/sid/icd-10" + } + ], + "text": "Traumatic brain injury" + }, + "onsetDateTime": "2020-05-01T15:45:09+05:30", + "identifier": [ + { + "value": "DG1002" + } + ], + "asserter": { + "reference": "Practitioner/98f6382a-649f-0339-4fa8-982d9760cf42" + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/condition-assertedDate", + "valueDateTime": "2020-05-01T16:45:15+05:30" + } + ] + }, + "request": { + "method": "PUT", + "url": "Condition/97303ad2-9731-b8ac-465e-560ad9ac67ec" + } + }, + { + "fullUrl": "urn:uuid:e82402a9-b2d1-2a28-3250-c099d5a77bf7", + "resource": { + "resourceType": "Organization", + "id": "e82402a9-b2d1-2a28-3250-c099d5a77bf7", + "identifier": [ + { + "value": "PERSt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/e82402a9-b2d1-2a28-3250-c099d5a77bf7" + } + }, + { + "fullUrl": "urn:uuid:ce70e6c3-c190-121d-c251-e4bae5cde6a1", + "resource": { + "resourceType": "Practitioner", + "id": "ce70e6c3-c190-121d-c251-e4bae5cde6a1", + "identifier": [ + { + "value": "1134", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/e82402a9-b2d1-2a28-3250-c099d5a77bf7" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Aly", + "given": [ + "Zafar", + "Mahendra" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/ce70e6c3-c190-121d-c251-e4bae5cde6a1" + } + }, + { + "fullUrl": "urn:uuid:88a53755-c972-6904-b4ce-8884b84ddc2e", + "resource": { + "resourceType": "PractitionerRole", + "id": "88a53755-c972-6904-b4ce-8884b84ddc2e", + "code": [ + { + "coding": [ + { + "code": "ResponsibleObserver", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/ce70e6c3-c190-121d-c251-e4bae5cde6a1" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/88a53755-c972-6904-b4ce-8884b84ddc2e" + } + }, + { + "fullUrl": "urn:uuid:fe0adb86-ebe9-6479-0055-9db8dc1ff99a", + "resource": { + "resourceType": "Device", + "id": "fe0adb86-ebe9-6479-0055-9db8dc1ff99a", + "identifier": [ + { + "value": "EI12.3", + "system": "urn:uuid:UI2", + "type": { + "coding": [ + { + "code": "GUID", + "display": "Same as UUID.", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + }, + { + "system": "urn:oid:UI1", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/fe0adb86-ebe9-6479-0055-9db8dc1ff99a" + } + }, + { + "fullUrl": "urn:uuid:45f65e47-46c4-1a54-f9fb-1321258e79b2", + "resource": { + "resourceType": "Practitioner", + "id": "45f65e47-46c4-1a54-f9fb-1321258e79b2", + "identifier": [ + { + "type": { + "coding": [ + { + "code": "MD-25" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/45f65e47-46c4-1a54-f9fb-1321258e79b2" + } + }, + { + "fullUrl": "urn:uuid:090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3", + "resource": { + "resourceType": "PractitionerRole", + "id": "090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3", + "code": [ + { + "coding": [ + { + "code": "LabMedicalDirector", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/45f65e47-46c4-1a54-f9fb-1321258e79b2" + }, + "organization": { + "reference": "Organization/08c155be-912e-af06-d464-5b6bb63d660f" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3" + } + }, + { + "fullUrl": "urn:uuid:08c155be-912e-af06-d464-5b6bb63d660f", + "resource": { + "resourceType": "Organization", + "id": "08c155be-912e-af06-d464-5b6bb63d660f", + "name": "State Hygienic Laboratory", + "identifier": [ + { + "value": "16D0648109", + "type": { + "coding": [ + { + "code": "FI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "address": [ + { + "line": [ + "State Hygienic Laboratory", + "UI Research Park -Coralville" + ], + "city": "Iowa City", + "state": "IA", + "postalCode": "52242-5002", + "country": "USA", + "use": "work" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/08c155be-912e-af06-d464-5b6bb63d660f" + } + }, + { + "fullUrl": "urn:uuid:07fd2dd3-dbd6-5bb1-cfda-02226795d9a0", + "resource": { + "resourceType": "Observation", + "id": "07fd2dd3-dbd6-5bb1-cfda-02226795d9a0", + "identifier": [ + { + "value": "EI21", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-OII" + }, + { + "type": { + "coding": [ + { + "code": "FILL" + } + ] + } + } + ], + "status": "preliminary", + "code": { + "coding": [ + { + "code": "625-4", + "display": "Bacteria identified in Stool by Culture", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/XYZ", + "version": "2.33" + } + ], + "text": "result1" + }, + "basedOn": [ + { + "reference": "ServiceRequest/3622230f-85a9-b313-e26b-eabfc755e34f" + } + ], + "valueCodeableConcept": { + "coding": [ + { + "code": "27268008", + "display": "Salmonella", + "system": "http://snomed.info/sct", + "version": "20090731" + } + ], + "text": "Salmonella species" + }, + "referenceRange": [ + { + "text": "70-80" + } + ], + "effectiveDateTime": "2012-03-01", + "method": { + "text": "Bacterial Culture" + }, + "device": { + "reference": "Device/fe0adb86-ebe9-6479-0055-9db8dc1ff99a" + }, + "bodySite": { + "coding": [ + { + "code": "BU", + "display": "Observation site", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/E5" + } + ] + }, + "performer": [ + { + "reference": "PractitionerRole/88a53755-c972-6904-b4ce-8884b84ddc2e" + }, + { + "reference": "PractitionerRole/090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3" + } + ], + "interpretation": [ + { + "coding": [ + { + "code": "A", + "display": "Abnormal", + "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation", + "version": "2.5" + } + ] + } + ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "P", + "display": "Preliminary", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Preliminary" + } + } + ], + "note": [ + { + "text": "No Antibodies Detected", + "time": "2020-10-10T18:15:00+05:30", + "authorReference": { + "reference": "Practitioner/ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/07fd2dd3-dbd6-5bb1-cfda-02226795d9a0" + } + }, + { + "fullUrl": "urn:uuid:ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2", + "resource": { + "resourceType": "Practitioner", + "id": "ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2", + "identifier": [ + { + "value": "MLEE" + } + ], + "name": [ + { + "family": "ATTEND", + "given": [ + "AARON", + "A" + ], + "suffix": [ + "MD" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2" + } + }, + { + "fullUrl": "urn:uuid:257786a3-0c2e-44c7-69ea-3456e7152e68", + "resource": { + "resourceType": "DiagnosticReport", + "id": "257786a3-0c2e-44c7-69ea-3456e7152e68", + "code": { + "coding": [ + { + "code": "1063-7", + "display": "Serum or Plasma", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/XYZ", + "version": "2.33" + } + ], + "text": "result1" + }, + "basedOn": [ + { + "reference": "ServiceRequest/3622230f-85a9-b313-e26b-eabfc755e34f" + } + ], + "status": "unknown", + "presentedForm": [ + { + "contentType": "image/pict", + "url": "https://testurl.com" + } + ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "DiagnosticReport/257786a3-0c2e-44c7-69ea-3456e7152e68" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORM_O01/ORM-O01-03-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORM_O01/ORM-O01-03-expected.json new file mode 100644 index 000000000..6e56ae40a --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORM_O01/ORM-O01-03-expected.json @@ -0,0 +1,1369 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2021-10-20T14:41:00+05:30", + "identifier": { + "value": "MSG00018" + }, + "id": "4d03cb6d-610f-5d9e-b9ac-f14883a17462", + "entry": [ + { + "fullUrl": "urn:uuid:4f80efdd-5499-39ca-474f-6dca4b4f9a22", + "resource": { + "resourceType": "MessageHeader", + "id": "4f80efdd-5499-39ca-474f-6dca4b4f9a22", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "O01", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "ORM^O01^ORM_O01" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/4f80efdd-5499-39ca-474f-6dca4b4f9a22" + } + }, + { + "fullUrl": "urn:uuid:58988e57-a45e-285b-5942-4480980652df", + "resource": { + "resourceType": "Provenance", + "id": "58988e57-a45e-285b-5942-4480980652df", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:51:55.798Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ORM_O01.

" + }, + "occurredDateTime": "2021-10-20T14:41:00+05:30", + "recorded": "2021-10-20T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "ORM^O01^ORM_O01" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/ad64f1d1-3e5b-a041-c1b3-3e157882ed69" + } + } + ], + "target": [ + { + "reference": "Bundle/4d03cb6d-610f-5d9e-b9ac-f14883a17462" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/58988e57-a45e-285b-5942-4480980652df" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:ad64f1d1-3e5b-a041-c1b3-3e157882ed69", + "resource": { + "resourceType": "Device", + "id": "ad64f1d1-3e5b-a041-c1b3-3e157882ed69", + "identifier": [ + { + "value": "ORDApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/ad64f1d1-3e5b-a041-c1b3-3e157882ed69" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:d00df304-17fa-8d9a-bd02-3276b1781ea1", + "resource": { + "resourceType": "Practitioner", + "id": "d00df304-17fa-8d9a-bd02-3276b1781ea1", + "identifier": [ + { + "value": "0210" + } + ], + "name": [ + { + "family": "ATTEND", + "given": [ + "AARON", + "A" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/d00df304-17fa-8d9a-bd02-3276b1781ea1" + } + }, + { + "fullUrl": "urn:uuid:21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9", + "resource": { + "resourceType": "Practitioner", + "id": "21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9", + "identifier": [ + { + "value": "0310" + } + ], + "name": [ + { + "family": "REFER", + "given": [ + "LINDA", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9" + } + }, + { + "fullUrl": "urn:uuid:6c138e7c-e841-af07-8948-d01692bd2739", + "resource": { + "resourceType": "Practitioner", + "id": "6c138e7c-e841-af07-8948-d01692bd2739", + "identifier": [ + { + "value": "03410" + } + ], + "name": [ + { + "family": "ADMIT", + "given": [ + "LINDA", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/6c138e7c-e841-af07-8948-d01692bd2739" + } + }, + { + "fullUrl": "urn:uuid:b9b31f37-678e-aade-7d5d-1375a513f673", + "resource": { + "resourceType": "Location", + "id": "b9b31f37-678e-aade-7d5d-1375a513f673", + "name": "RADUnit01", + "mode": "instance", + "description": "RADUnit01--Room01--GHH", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/b9b31f37-678e-aade-7d5d-1375a513f673" + } + }, + { + "fullUrl": "urn:uuid:ee586d80-706a-5933-8500-a8026c48fb27", + "resource": { + "resourceType": "Location", + "id": "ee586d80-706a-5933-8500-a8026c48fb27", + "partOf": { + "reference": "Location/b9b31f37-678e-aade-7d5d-1375a513f673" + }, + "name": "Room01", + "mode": "instance", + "description": "RADUnit01--Room01--GHH", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/ee586d80-706a-5933-8500-a8026c48fb27" + } + }, + { + "fullUrl": "urn:uuid:3ffd504f-44ae-ce29-6fc0-6baf5bc0a821", + "resource": { + "resourceType": "Location", + "id": "3ffd504f-44ae-ce29-6fc0-6baf5bc0a821", + "name": "GHH", + "mode": "instance", + "description": "RADUnit01--Room01--GHH", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3ffd504f-44ae-ce29-6fc0-6baf5bc0a821" + } + }, + { + "fullUrl": "urn:uuid:5357a3e3-2c50-7c10-6b22-00b646c8b396", + "resource": { + "resourceType": "Location", + "id": "5357a3e3-2c50-7c10-6b22-00b646c8b396", + "name": "TraumaCentre", + "mode": "instance", + "description": "TraumaCentre--ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--GHH1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5357a3e3-2c50-7c10-6b22-00b646c8b396" + } + }, + { + "fullUrl": "urn:uuid:c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "resource": { + "resourceType": "Location", + "id": "c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "partOf": { + "reference": "Location/5357a3e3-2c50-7c10-6b22-00b646c8b396" + }, + "name": "ROOM1", + "identifier": [ + { + "value": "urn:oid:2.16.840.1.113883.4.642.1.1108", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "TraumaCentre--ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--GHH1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + } + }, + { + "fullUrl": "urn:uuid:e9bd830d-8f94-01b9-7562-854da22940d3", + "resource": { + "resourceType": "Location", + "id": "e9bd830d-8f94-01b9-7562-854da22940d3", + "name": "GHH1", + "mode": "instance", + "description": "TraumaCentre--ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--GHH1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/e9bd830d-8f94-01b9-7562-854da22940d3" + } + }, + { + "fullUrl": "urn:uuid:da6f322f-ef5e-4f2c-c1f8-6e38dffbf995", + "resource": { + "resourceType": "Encounter", + "id": "da6f322f-ef5e-4f2c-c1f8-6e38dffbf995", + "class": { + "code": "AMB", + "display": "ambulatory", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "in-progress", + "location": [ + { + "status": "active", + "location": { + "reference": "Location/b9b31f37-678e-aade-7d5d-1375a513f673" + } + }, + { + "status": "completed", + "location": { + "reference": "Location/5357a3e3-2c50-7c10-6b22-00b646c8b396" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/d00df304-17fa-8d9a-bd02-3276b1781ea1" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "ADM", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "admitter" + } + ], + "individual": { + "reference": "Practitioner/6c138e7c-e841-af07-8948-d01692bd2739" + } + } + ], + "identifier": [ + { + "value": "5001", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + } + ], + "period": { + "start": "2021-10-20T15:15:00+05:30" + }, + "text": { + "status": "generated", + "div": "

Visit Description:

" + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "diagnosis": [ + { + "condition": { + "reference": "Condition/97303ad2-9731-b8ac-465e-560ad9ac67ec" + }, + "use": { + "coding": [ + { + "code": "DD", + "display": "Discharge Diagnosis", + "system": "http://terminology.hl7.org/CodeSystem/diagnosis-role" + } + ] + }, + "rank": 1 + } + ] + }, + "request": { + "method": "PUT", + "url": "Encounter/da6f322f-ef5e-4f2c-c1f8-6e38dffbf995" + } + }, + { + "fullUrl": "urn:uuid:3622230f-85a9-b313-e26b-eabfc755e34f", + "resource": { + "resourceType": "ServiceRequest", + "id": "3622230f-85a9-b313-e26b-eabfc755e34f", + "status": "active", + "intent": "order", + "identifier": [ + { + "value": "1101", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHHPlacer", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "1201", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHHFiller", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "authoredOn": "2021-10-20T14:41:00+05:30", + "locationCode": [ + { + "coding": [ + { + "code": "OF", + "display": "Outpatient facility", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "quantityQuantity": { + "value": 1 + }, + "occurrenceTiming": { + "repeat": { + "boundsPeriod": { + "start": "2021-10-20T14:41:00+05:30" + } + } + }, + "code": { + "coding": [ + { + "code": "24725-4", + "display": "CT Head", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "requester": { + "reference": "PractitionerRole/d47a42cd-ee8d-858a-81ba-093cd6c2b737" + }, + "specimen": [ + { + "reference": "Specimen/c3574395-5ad6-bf2a-9907-c1a7caa8c850" + } + ], + "reasonReference": [ + { + "reference": "Condition/97303ad2-9731-b8ac-465e-560ad9ac67ec" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/3622230f-85a9-b313-e26b-eabfc755e34f" + } + }, + { + "fullUrl": "urn:uuid:98f6382a-649f-0339-4fa8-982d9760cf42", + "resource": { + "resourceType": "Practitioner", + "id": "98f6382a-649f-0339-4fa8-982d9760cf42", + "identifier": [ + { + "value": "005454" + } + ], + "name": [ + { + "family": "RAD", + "given": [ + "ROBIN", + "B" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/98f6382a-649f-0339-4fa8-982d9760cf42" + } + }, + { + "fullUrl": "urn:uuid:d47a42cd-ee8d-858a-81ba-093cd6c2b737", + "resource": { + "resourceType": "PractitionerRole", + "id": "d47a42cd-ee8d-858a-81ba-093cd6c2b737", + "practitioner": { + "reference": "Practitioner/98f6382a-649f-0339-4fa8-982d9760cf42" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/d47a42cd-ee8d-858a-81ba-093cd6c2b737" + } + }, + { + "fullUrl": "urn:uuid:c3574395-5ad6-bf2a-9907-c1a7caa8c850", + "resource": { + "resourceType": "Specimen", + "id": "c3574395-5ad6-bf2a-9907-c1a7caa8c850", + "collection": { + "collectedDateTime": "2021-10-20T15:15:00+05:30" + } + }, + "request": { + "method": "PUT", + "url": "Specimen/c3574395-5ad6-bf2a-9907-c1a7caa8c850" + } + }, + { + "fullUrl": "urn:uuid:97303ad2-9731-b8ac-465e-560ad9ac67ec", + "resource": { + "resourceType": "Condition", + "id": "97303ad2-9731-b8ac-465e-560ad9ac67ec", + "code": { + "coding": [ + { + "code": "S06.9", + "display": "TBI(traumatic brain injury", + "system": "http://hl7.org/fhir/sid/icd-10" + } + ], + "text": "Traumatic brain injury" + }, + "onsetDateTime": "2020-05-01T15:45:09+05:30", + "identifier": [ + { + "value": "DG1002" + } + ], + "asserter": { + "reference": "Practitioner/98f6382a-649f-0339-4fa8-982d9760cf42" + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/condition-assertedDate", + "valueDateTime": "2020-05-01T16:45:15+05:30" + } + ] + }, + "request": { + "method": "PUT", + "url": "Condition/97303ad2-9731-b8ac-465e-560ad9ac67ec" + } + }, + { + "fullUrl": "urn:uuid:a003235d-4049-0bbd-9cac-d9dee4a90908", + "resource": { + "resourceType": "ServiceRequest", + "id": "a003235d-4049-0bbd-9cac-d9dee4a90908", + "status": "active", + "intent": "order", + "identifier": [ + { + "value": "2203", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHHPlacer", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "2301", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHHFiller", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "authoredOn": "2021-10-20T14:41:00+05:30", + "basedOn": [ + { + "type": "ServiceRequest", + "identifier": { + "value": "PAI-291", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + } + ], + "locationCode": [ + { + "coding": [ + { + "code": "OF", + "display": "Outpatient facility", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "quantityQuantity": { + "value": 1 + }, + "occurrenceTiming": { + "repeat": { + "boundsPeriod": { + "start": "2021-10-20T16:15:00+05:30" + } + } + }, + "code": { + "coding": [ + { + "code": "24590-2", + "display": "MR Brain", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "requester": { + "reference": "PractitionerRole/d47a42cd-ee8d-858a-81ba-093cd6c2b737" + }, + "specimen": [ + { + "reference": "Specimen/8849ee55-3313-2d6a-bfbe-be22941a5a2a" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/a003235d-4049-0bbd-9cac-d9dee4a90908" + } + }, + { + "fullUrl": "urn:uuid:8849ee55-3313-2d6a-bfbe-be22941a5a2a", + "resource": { + "resourceType": "Specimen", + "id": "8849ee55-3313-2d6a-bfbe-be22941a5a2a", + "collection": { + "collectedDateTime": "2021-10-20T16:15:00+05:30" + } + }, + "request": { + "method": "PUT", + "url": "Specimen/8849ee55-3313-2d6a-bfbe-be22941a5a2a" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORU_R01/LAB-ORU-1-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORU_R01/LAB-ORU-1-expected.json index 3f1641946..66f1a3105 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORU_R01/LAB-ORU-1-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORU_R01/LAB-ORU-1-expected.json @@ -5,6 +5,7 @@ "identifier": { "value": "182" }, + "id": "4d7652e0-2e87-c4b4-72d8-614f50d75e88", "entry": [ { "fullUrl": "urn:uuid:f1f46d90-0473-6ea2-ae7f-b3165305d99f", @@ -54,6 +55,47 @@ "url": "MessageHeader/f1f46d90-0473-6ea2-ae7f-b3165305d99f" } }, + { + "fullUrl": "urn:uuid:9f79a1ce-a1d5-c6dd-a0d6-3bc75109716c", + "resource": { + "resourceType": "Provenance", + "id": "9f79a1ce-a1d5-c6dd-a0d6-3bc75109716c", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:49:16.824Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ORU_R01.

" + }, + "occurredDateTime": "2014-10-06T06:45:00", + "recorded": "2014-10-06T06:45:00", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + } + } + ], + "activity": { + "coding": [ + { + "display": "ORU^R01^" + } + ] + }, + "target": [ + { + "reference": "Bundle/4d7652e0-2e87-c4b4-72d8-614f50d75e88" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/9f79a1ce-a1d5-c6dd-a0d6-3bc75109716c" + } + }, { "fullUrl": "urn:uuid:bab5ca58-f272-4c06-4b3f-f9661e45a22b", "resource": { @@ -167,66 +209,6 @@ "url": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" } }, - { - "fullUrl": "urn:uuid:", - "resource": { - "resourceType": "Practitioner" - }, - "request": { - "method": "PUT", - "url": "Practitioner/" - } - }, - { - "fullUrl": "urn:uuid:", - "resource": { - "resourceType": "Location" - }, - "request": { - "method": "PUT", - "url": "Location/" - } - }, - { - "fullUrl": "urn:uuid:", - "resource": { - "resourceType": "Provenance", - "text": { - "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:58:01.423Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ORU_R01.

" - }, - "occurredDateTime": "2014-10-06T06:45:00", - "recorded": "2014-10-06T06:45:00", - "agent": [ - { - "type": { - "coding": [ - { - "code": "author", - "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" - } - ] - } - } - ], - "activity": { - "coding": [ - { - "display": "ORU^R01^" - } - ] - }, - "target": [ - { - "reference": "Bundle/" - } - ] - }, - "request": { - "method": "PUT", - "url": "Provenance/" - } - }, { "fullUrl": "urn:uuid:f70a39cb-cf13-6f75-885d-cf691752c711", "resource": { @@ -260,113 +242,44 @@ } }, { - "fullUrl": "urn:uuid:", - "resource": { - "resourceType": "Encounter", - "text": { - "status": "generated", - "div": "

Visit Description:

" - }, - "subject": { - "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" - } - }, - "request": { - "method": "PUT", - "url": "Encounter/" - } - }, - { - "fullUrl": "urn:uuid:da437276-fd7c-eb21-1885-4041aa59c483", - "resource": { - "resourceType": "Practitioner", - "id": "da437276-fd7c-eb21-1885-4041aa59c483" - }, - "request": { - "method": "PUT", - "url": "Practitioner/da437276-fd7c-eb21-1885-4041aa59c483" - } - }, - { - "fullUrl": "urn:uuid:abc9f629-6e71-5ca8-488e-283e73338943", + "fullUrl": "urn:uuid:f736fbb2-aafc-4e52-abb9-20d77d01d302", "resource": { - "resourceType": "DiagnosticReport", - "id": "abc9f629-6e71-5ca8-488e-283e73338943", - "identifier": [ - { - "type": { - "coding": [ - { - "code": "FILL", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203" - } - ] - } - }, - { - "value": "88502218" - }, - { - "value": "82503246" - } - ], + "resourceType": "Observation", + "id": "f736fbb2-aafc-4e52-abb9-20d77d01d302", + "status": "unknown", "code": { "coding": [ { - "code": "24317-0", - "display": "Hemogram and platelet count, automated", + "code": "11156-7", + "display": "LEUKOCYTES", "system": "http://loinc.org" } ] }, - "status": "final", - "specimen": [ - { - "reference": "Practitioner/da437276-fd7c-eb21-1885-4041aa59c483" - }, + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "extension": [ { - "reference": "Specimen/7c7cbbd6-4a47-b606-9d5b-dc2d6a03e663" + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "I", + "display": "In Process", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "In Process" + } } ], - "result": [ - { - "reference": "Observation/f736fbb2-aafc-4e52-abb9-20d77d01d302" - }, - { - "reference": "Observation/1ef60c39-1161-0129-a263-b693d23f90c3" - }, - { - "reference": "Observation/fa77427d-7606-99a5-ae91-f316de160668" - }, + "basedOn": [ { - "reference": "Observation/2f7b51cf-44f5-547d-2815-747fd4ec7a88" - }, - { - "reference": "Observation/73bdfe72-5f9f-31fc-ad22-90e1ccf2d7fe" + "reference": "ServiceRequest/0c653f12-916b-8b2a-511a-96b2fb03e3af" } ] }, - "request": { - "method": "PUT", - "url": "DiagnosticReport/abc9f629-6e71-5ca8-488e-283e73338943" - } - }, - { - "fullUrl": "urn:uuid:f736fbb2-aafc-4e52-abb9-20d77d01d302", - "resource": { - "resourceType": "Observation", - "id": "f736fbb2-aafc-4e52-abb9-20d77d01d302", - "status": "unknown", - "code": { - "coding": [ - { - "code": "11156-7", - "display": "LEUKOCYTES", - "system": "http://loinc.org" - } - ] - } - }, "request": { "method": "PUT", "url": "Observation/f736fbb2-aafc-4e52-abb9-20d77d01d302" @@ -402,6 +315,29 @@ } ] } + ], + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "P", + "display": "Preliminary", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Preliminary" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/0c653f12-916b-8b2a-511a-96b2fb03e3af" + } ] }, "request": { @@ -423,7 +359,30 @@ "system": "http://loinc.org" } ] - } + }, + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "I", + "display": "In Process", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "In Process" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/0c653f12-916b-8b2a-511a-96b2fb03e3af" + } + ] }, "request": { "method": "PUT", @@ -460,6 +419,29 @@ } ] } + ], + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "P", + "display": "Preliminary", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Preliminary" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/0c653f12-916b-8b2a-511a-96b2fb03e3af" + } ] }, "request": { @@ -497,6 +479,29 @@ } ] } + ], + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/0c653f12-916b-8b2a-511a-96b2fb03e3af" + } ] }, "request": { @@ -505,17 +510,15 @@ } }, { - "fullUrl": "urn:uuid:7c7cbbd6-4a47-b606-9d5b-dc2d6a03e663", + "fullUrl": "urn:uuid:0c653f12-916b-8b2a-511a-96b2fb03e3af", "resource": { - "resourceType": "Specimen", - "id": "7c7cbbd6-4a47-b606-9d5b-dc2d6a03e663", - "collection": { - "collectedDateTime": "2014-10-06T05:35:00" - }, - "receivedTime": "2014-10-06T08:21:00", + "resourceType": "ServiceRequest", + "id": "0c653f12-916b-8b2a-511a-96b2fb03e3af", + "status": "active", + "intent": "filler-order", "identifier": [ { - "value": "SpecimenID", + "value": "88502218", "type": { "coding": [ { @@ -524,83 +527,261 @@ } ] } - } - ], - "type": { - "coding": [ - { - "code": "BLD" - } - ] - }, - "status": "available" + }, + { + "value": "82503246", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "code": { + "coding": [ + { + "code": "24317-0", + "display": "Hemogram and platelet count, automated", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "requester": { + "reference": "PractitionerRole/907170a0-a8af-89c5-5a30-6b78cdb227c5" + }, + "specimen": [ + { + "reference": "Specimen/1385d82a-b545-84d8-803a-e65c038399c8" + } + ] }, "request": { "method": "PUT", - "url": "Specimen/7c7cbbd6-4a47-b606-9d5b-dc2d6a03e663" + "url": "ServiceRequest/0c653f12-916b-8b2a-511a-96b2fb03e3af" + } + }, + { + "fullUrl": "urn:uuid:15decf11-00dc-6867-9c35-ffd79977d5b9", + "resource": { + "resourceType": "Practitioner", + "id": "15decf11-00dc-6867-9c35-ffd79977d5b9", + "name": [ + { + "family": "URO", + "prefix": [ + "DR" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/15decf11-00dc-6867-9c35-ffd79977d5b9" + } + }, + { + "fullUrl": "urn:uuid:907170a0-a8af-89c5-5a30-6b78cdb227c5", + "resource": { + "resourceType": "PractitionerRole", + "id": "907170a0-a8af-89c5-5a30-6b78cdb227c5", + "practitioner": { + "reference": "Practitioner/15decf11-00dc-6867-9c35-ffd79977d5b9" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/907170a0-a8af-89c5-5a30-6b78cdb227c5" } }, { - "fullUrl": "urn:uuid:c3c41c66-630e-8d1b-2fad-cffb0957da29", + "fullUrl": "urn:uuid:6bb755e5-a74c-c3f0-e18b-a92b568c4b19", "resource": { "resourceType": "DiagnosticReport", - "id": "c3c41c66-630e-8d1b-2fad-cffb0957da29", + "id": "6bb755e5-a74c-c3f0-e18b-a92b568c4b19", "identifier": [ { + "value": "88502218", "type": { "coding": [ { - "code": "FILL", + "code": "PLAC", "system": "http://terminology.hl7.org/CodeSystem/v2-0203" } ] } }, { - "value": "855238581" - }, - { - "value": "890775544" + "value": "82503246", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } } ], "code": { "coding": [ { - "code": "26464-8", - "display": "Differential WBC Count, buffy coat", + "code": "24317-0", + "display": "Hemogram and platelet count, automated", "system": "http://loinc.org" } ] }, - "specimen": [ + "status": "final", + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "basedOn": [ { - "reference": "Practitioner/da437276-fd7c-eb21-1885-4041aa59c483" - }, + "reference": "ServiceRequest/0c653f12-916b-8b2a-511a-96b2fb03e3af" + } + ], + "specimen": [ { - "reference": "Specimen/7c7cbbd6-4a47-b606-9d5b-dc2d6a03e663" + "reference": "Specimen/1385d82a-b545-84d8-803a-e65c038399c8" } ], "result": [ { - "reference": "Observation/f3f13545-5a9c-5279-e1a3-6faff5d56778" + "reference": "Observation/f736fbb2-aafc-4e52-abb9-20d77d01d302" }, { - "reference": "Observation/690c7dfd-8d22-ac69-0f11-bf58da18db99" + "reference": "Observation/1ef60c39-1161-0129-a263-b693d23f90c3" }, { - "reference": "Observation/4bb79fc0-148e-6d5b-b111-6e09c39ec56e" + "reference": "Observation/fa77427d-7606-99a5-ae91-f316de160668" }, { - "reference": "Observation/5597ddac-19fb-6893-705d-65097d31b66b" + "reference": "Observation/2f7b51cf-44f5-547d-2815-747fd4ec7a88" }, { - "reference": "Observation/e4412677-d1c2-f97d-b765-5bdfb16cdac5" + "reference": "Observation/73bdfe72-5f9f-31fc-ad22-90e1ccf2d7fe" + } + ] + }, + "request": { + "method": "PUT", + "url": "DiagnosticReport/6bb755e5-a74c-c3f0-e18b-a92b568c4b19" + } + }, + { + "fullUrl": "urn:uuid:1385d82a-b545-84d8-803a-e65c038399c8", + "resource": { + "resourceType": "Specimen", + "id": "1385d82a-b545-84d8-803a-e65c038399c8", + "collection": { + "collector": { + "reference": "PractitionerRole/be571888-010e-9a32-e87f-f1ee1bd631a8" + } + }, + "identifier": [ + { + "value": "88502218", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "82503246", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Specimen/1385d82a-b545-84d8-803a-e65c038399c8" + } + }, + { + "fullUrl": "urn:uuid:da437276-fd7c-eb21-1885-4041aa59c483", + "resource": { + "resourceType": "Practitioner", + "id": "da437276-fd7c-eb21-1885-4041aa59c483", + "name": [ + { + "family": "COLLECT", + "given": [ + "JOHN" + ] } ] }, "request": { "method": "PUT", - "url": "DiagnosticReport/c3c41c66-630e-8d1b-2fad-cffb0957da29" + "url": "Practitioner/da437276-fd7c-eb21-1885-4041aa59c483" + } + }, + { + "fullUrl": "urn:uuid:be571888-010e-9a32-e87f-f1ee1bd631a8", + "resource": { + "resourceType": "PractitionerRole", + "id": "be571888-010e-9a32-e87f-f1ee1bd631a8", + "practitioner": { + "reference": "Practitioner/da437276-fd7c-eb21-1885-4041aa59c483" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/be571888-010e-9a32-e87f-f1ee1bd631a8" + } + }, + { + "fullUrl": "urn:uuid:7c7cbbd6-4a47-b606-9d5b-dc2d6a03e663", + "resource": { + "resourceType": "Specimen", + "id": "7c7cbbd6-4a47-b606-9d5b-dc2d6a03e663", + "collection": { + "collectedDateTime": "2014-10-06T05:35:00" + }, + "receivedTime": "2014-10-06T08:21:00", + "identifier": [ + { + "value": "SpecimenID", + "type": { + "coding": [ + { + "code": "PGN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "type": { + "coding": [ + { + "code": "BLD", + "system": "http://terminology.hl7.org/CodeSystem/v2-0487" + } + ] + }, + "status": "available" + }, + "request": { + "method": "PUT", + "url": "Specimen/7c7cbbd6-4a47-b606-9d5b-dc2d6a03e663" } }, { @@ -633,6 +814,32 @@ } ] } + ], + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "specimen": { + "reference": "Specimen/7c7cbbd6-4a47-b606-9d5b-dc2d6a03e663" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "P", + "display": "Preliminary", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Preliminary" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/99bb45ed-8d61-675b-dec1-6ee32bfa054a" + } ] }, "request": { @@ -670,6 +877,32 @@ } ] } + ], + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "specimen": { + "reference": "Specimen/7c7cbbd6-4a47-b606-9d5b-dc2d6a03e663" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "P", + "display": "Preliminary", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Preliminary" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/99bb45ed-8d61-675b-dec1-6ee32bfa054a" + } ] }, "request": { @@ -707,6 +940,32 @@ } ] } + ], + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "specimen": { + "reference": "Specimen/7c7cbbd6-4a47-b606-9d5b-dc2d6a03e663" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "P", + "display": "Preliminary", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Preliminary" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/99bb45ed-8d61-675b-dec1-6ee32bfa054a" + } ] }, "request": { @@ -744,6 +1003,32 @@ } ] } + ], + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "specimen": { + "reference": "Specimen/7c7cbbd6-4a47-b606-9d5b-dc2d6a03e663" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "P", + "display": "Preliminary", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Preliminary" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/99bb45ed-8d61-675b-dec1-6ee32bfa054a" + } ] }, "request": { @@ -781,12 +1066,210 @@ } ] } + ], + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "specimen": { + "reference": "Specimen/7c7cbbd6-4a47-b606-9d5b-dc2d6a03e663" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "P", + "display": "Preliminary", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Preliminary" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/99bb45ed-8d61-675b-dec1-6ee32bfa054a" + } ] }, "request": { "method": "PUT", "url": "Observation/e4412677-d1c2-f97d-b765-5bdfb16cdac5" } + }, + { + "fullUrl": "urn:uuid:99bb45ed-8d61-675b-dec1-6ee32bfa054a", + "resource": { + "resourceType": "ServiceRequest", + "id": "99bb45ed-8d61-675b-dec1-6ee32bfa054a", + "status": "active", + "intent": "filler-order", + "identifier": [ + { + "value": "855238581", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "890775544", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "code": { + "coding": [ + { + "code": "26464-8", + "display": "Differential WBC Count, buffy coat", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "requester": { + "reference": "PractitionerRole/907170a0-a8af-89c5-5a30-6b78cdb227c5" + }, + "specimen": [ + { + "reference": "Specimen/e8c2bedc-f247-6e63-2c6f-a58e26f24c33" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/99bb45ed-8d61-675b-dec1-6ee32bfa054a" + } + }, + { + "fullUrl": "urn:uuid:bd4fd761-3a3c-6084-6bb0-5b21c024b208", + "resource": { + "resourceType": "DiagnosticReport", + "id": "bd4fd761-3a3c-6084-6bb0-5b21c024b208", + "identifier": [ + { + "value": "855238581", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "890775544", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "code": { + "coding": [ + { + "code": "26464-8", + "display": "Differential WBC Count, buffy coat", + "system": "http://loinc.org" + } + ] + }, + "status": "unknown", + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "basedOn": [ + { + "reference": "ServiceRequest/99bb45ed-8d61-675b-dec1-6ee32bfa054a" + } + ], + "specimen": [ + { + "reference": "Specimen/e8c2bedc-f247-6e63-2c6f-a58e26f24c33" + } + ], + "result": [ + { + "reference": "Observation/f3f13545-5a9c-5279-e1a3-6faff5d56778" + }, + { + "reference": "Observation/690c7dfd-8d22-ac69-0f11-bf58da18db99" + }, + { + "reference": "Observation/4bb79fc0-148e-6d5b-b111-6e09c39ec56e" + }, + { + "reference": "Observation/5597ddac-19fb-6893-705d-65097d31b66b" + }, + { + "reference": "Observation/e4412677-d1c2-f97d-b765-5bdfb16cdac5" + } + ] + }, + "request": { + "method": "PUT", + "url": "DiagnosticReport/bd4fd761-3a3c-6084-6bb0-5b21c024b208" + } + }, + { + "fullUrl": "urn:uuid:e8c2bedc-f247-6e63-2c6f-a58e26f24c33", + "resource": { + "resourceType": "Specimen", + "id": "e8c2bedc-f247-6e63-2c6f-a58e26f24c33", + "collection": { + "collector": { + "reference": "PractitionerRole/be571888-010e-9a32-e87f-f1ee1bd631a8" + } + }, + "identifier": [ + { + "value": "855238581", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "890775544", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Specimen/e8c2bedc-f247-6e63-2c6f-a58e26f24c33" + } } ] } \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORU_R01/LAB-ORU-2-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORU_R01/LAB-ORU-2-expected.json index c82f2354d..e5adea959 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORU_R01/LAB-ORU-2-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORU_R01/LAB-ORU-2-expected.json @@ -5,6 +5,7 @@ "identifier": { "value": "ControlID" }, + "id": "1621d98e-0f06-6ff5-bfed-87e7a90a41b6", "entry": [ { "fullUrl": "urn:uuid:35c86567-5347-8c97-4810-b39dedb9f855", @@ -55,6 +56,47 @@ "url": "MessageHeader/35c86567-5347-8c97-4810-b39dedb9f855" } }, + { + "fullUrl": "urn:uuid:9f79a1ce-a1d5-c6dd-a0d6-3bc75109716c", + "resource": { + "resourceType": "Provenance", + "id": "9f79a1ce-a1d5-c6dd-a0d6-3bc75109716c", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:49:47.115Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ORU_R01.

" + }, + "occurredDateTime": "2014-10-06T09:31:00", + "recorded": "2014-10-06T09:31:00", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + } + } + ], + "activity": { + "coding": [ + { + "display": "ORU^R01^" + } + ] + }, + "target": [ + { + "reference": "Bundle/1621d98e-0f06-6ff5-bfed-87e7a90a41b6" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/9f79a1ce-a1d5-c6dd-a0d6-3bc75109716c" + } + }, { "fullUrl": "urn:uuid:bab5ca58-f272-4c06-4b3f-f9661e45a22b", "resource": { @@ -168,66 +210,6 @@ "url": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" } }, - { - "fullUrl": "urn:uuid:", - "resource": { - "resourceType": "Practitioner" - }, - "request": { - "method": "PUT", - "url": "Practitioner/" - } - }, - { - "fullUrl": "urn:uuid:", - "resource": { - "resourceType": "Location" - }, - "request": { - "method": "PUT", - "url": "Location/" - } - }, - { - "fullUrl": "urn:uuid:", - "resource": { - "resourceType": "Provenance", - "text": { - "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:58:35.885Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ORU_R01.

" - }, - "occurredDateTime": "2014-10-06T09:31:00", - "recorded": "2014-10-06T09:31:00", - "agent": [ - { - "type": { - "coding": [ - { - "code": "author", - "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" - } - ] - } - } - ], - "activity": { - "coding": [ - { - "display": "ORU^R01^" - } - ] - }, - "target": [ - { - "reference": "Bundle/" - } - ] - }, - "request": { - "method": "PUT", - "url": "Provenance/" - } - }, { "fullUrl": "urn:uuid:f70a39cb-cf13-6f75-885d-cf691752c711", "resource": { @@ -260,97 +242,6 @@ "url": "Account/f70a39cb-cf13-6f75-885d-cf691752c711" } }, - { - "fullUrl": "urn:uuid:", - "resource": { - "resourceType": "Encounter", - "text": { - "status": "generated", - "div": "

Visit Description:

" - }, - "subject": { - "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" - } - }, - "request": { - "method": "PUT", - "url": "Encounter/" - } - }, - { - "fullUrl": "urn:uuid:da437276-fd7c-eb21-1885-4041aa59c483", - "resource": { - "resourceType": "Practitioner", - "id": "da437276-fd7c-eb21-1885-4041aa59c483" - }, - "request": { - "method": "PUT", - "url": "Practitioner/da437276-fd7c-eb21-1885-4041aa59c483" - } - }, - { - "fullUrl": "urn:uuid:c3c41c66-630e-8d1b-2fad-cffb0957da29", - "resource": { - "resourceType": "DiagnosticReport", - "id": "c3c41c66-630e-8d1b-2fad-cffb0957da29", - "identifier": [ - { - "type": { - "coding": [ - { - "code": "FILL", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203" - } - ] - } - }, - { - "value": "855238581" - }, - { - "value": "890775544" - } - ], - "code": { - "coding": [ - { - "code": "26464-8", - "display": "Differential WBC Count, buffy coat", - "system": "http://loinc.org" - } - ] - }, - "specimen": [ - { - "reference": "Practitioner/da437276-fd7c-eb21-1885-4041aa59c483" - }, - { - "reference": "Specimen/6006d57e-e0a3-d90e-7d9b-546ed575c527" - } - ], - "result": [ - { - "reference": "Observation/24b96f9a-359e-fc62-bf8a-45e4f1b4c6e9" - }, - { - "reference": "Observation/1b81a0d2-b102-41aa-421b-ac645e962ce4" - }, - { - "reference": "Observation/26534e50-b8b4-2ec3-7f8d-c33d4c7792f1" - }, - { - "reference": "Observation/7878e0ad-8700-5b8b-47d9-7acff0e1eb34" - }, - { - "reference": "Observation/437fa03d-5559-9f37-42ed-482f65dd47ce" - } - ] - }, - "request": { - "method": "PUT", - "url": "DiagnosticReport/c3c41c66-630e-8d1b-2fad-cffb0957da29" - } - }, { "fullUrl": "urn:uuid:24b96f9a-359e-fc62-bf8a-45e4f1b4c6e9", "resource": { @@ -381,6 +272,29 @@ } ] } + ], + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/99bb45ed-8d61-675b-dec1-6ee32bfa054a" + } ] }, "request": { @@ -418,6 +332,29 @@ } ] } + ], + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/99bb45ed-8d61-675b-dec1-6ee32bfa054a" + } ] }, "request": { @@ -455,6 +392,29 @@ } ] } + ], + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/99bb45ed-8d61-675b-dec1-6ee32bfa054a" + } ] }, "request": { @@ -492,6 +452,29 @@ } ] } + ], + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/99bb45ed-8d61-675b-dec1-6ee32bfa054a" + } ] }, "request": { @@ -529,6 +512,29 @@ } ] } + ], + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/99bb45ed-8d61-675b-dec1-6ee32bfa054a" + } ] }, "request": { @@ -537,17 +543,15 @@ } }, { - "fullUrl": "urn:uuid:6006d57e-e0a3-d90e-7d9b-546ed575c527", + "fullUrl": "urn:uuid:99bb45ed-8d61-675b-dec1-6ee32bfa054a", "resource": { - "resourceType": "Specimen", - "id": "6006d57e-e0a3-d90e-7d9b-546ed575c527", - "collection": { - "collectedDateTime": "2014-10-06T05:35:00" - }, - "receivedTime": "2014-10-06T06:21:00", + "resourceType": "ServiceRequest", + "id": "99bb45ed-8d61-675b-dec1-6ee32bfa054a", + "status": "active", + "intent": "filler-order", "identifier": [ { - "value": "SpecimenID", + "value": "855238581", "type": { "coding": [ { @@ -556,83 +560,261 @@ } ] } + }, + { + "value": "890775544", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } } ], - "type": { + "code": { "coding": [ { - "code": "BLD" + "code": "26464-8", + "display": "Differential WBC Count, buffy coat", + "system": "http://loinc.org" } ] }, - "status": "available" + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "requester": { + "reference": "PractitionerRole/907170a0-a8af-89c5-5a30-6b78cdb227c5" + }, + "specimen": [ + { + "reference": "Specimen/e8c2bedc-f247-6e63-2c6f-a58e26f24c33" + } + ] }, "request": { "method": "PUT", - "url": "Specimen/6006d57e-e0a3-d90e-7d9b-546ed575c527" + "url": "ServiceRequest/99bb45ed-8d61-675b-dec1-6ee32bfa054a" + } + }, + { + "fullUrl": "urn:uuid:15decf11-00dc-6867-9c35-ffd79977d5b9", + "resource": { + "resourceType": "Practitioner", + "id": "15decf11-00dc-6867-9c35-ffd79977d5b9", + "name": [ + { + "family": "URO", + "prefix": [ + "DR" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/15decf11-00dc-6867-9c35-ffd79977d5b9" + } + }, + { + "fullUrl": "urn:uuid:907170a0-a8af-89c5-5a30-6b78cdb227c5", + "resource": { + "resourceType": "PractitionerRole", + "id": "907170a0-a8af-89c5-5a30-6b78cdb227c5", + "practitioner": { + "reference": "Practitioner/15decf11-00dc-6867-9c35-ffd79977d5b9" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/907170a0-a8af-89c5-5a30-6b78cdb227c5" } }, { - "fullUrl": "urn:uuid:5207c1fc-b68c-7398-6585-264869affbff", + "fullUrl": "urn:uuid:bd4fd761-3a3c-6084-6bb0-5b21c024b208", "resource": { "resourceType": "DiagnosticReport", - "id": "5207c1fc-b68c-7398-6585-264869affbff", + "id": "bd4fd761-3a3c-6084-6bb0-5b21c024b208", "identifier": [ { + "value": "855238581", "type": { "coding": [ { - "code": "FILL", + "code": "PLAC", "system": "http://terminology.hl7.org/CodeSystem/v2-0203" } ] } }, { - "value": "88502218" - }, - { - "value": "82503246" + "value": "890775544", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } } ], "code": { "coding": [ { - "code": "24317-0", - "display": "Hemogram and platelet count, automated", + "code": "26464-8", + "display": "Differential WBC Count, buffy coat", "system": "http://loinc.org" } ] }, - "specimen": [ + "status": "unknown", + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "basedOn": [ { - "reference": "Practitioner/da437276-fd7c-eb21-1885-4041aa59c483" - }, + "reference": "ServiceRequest/99bb45ed-8d61-675b-dec1-6ee32bfa054a" + } + ], + "specimen": [ { - "reference": "Specimen/6006d57e-e0a3-d90e-7d9b-546ed575c527" + "reference": "Specimen/e8c2bedc-f247-6e63-2c6f-a58e26f24c33" } ], "result": [ { - "reference": "Observation/8c207e70-3fd2-2bf4-df75-256240c60258" + "reference": "Observation/24b96f9a-359e-fc62-bf8a-45e4f1b4c6e9" }, { - "reference": "Observation/874ee31e-885c-d582-b76d-e145e99a2945" + "reference": "Observation/1b81a0d2-b102-41aa-421b-ac645e962ce4" }, { - "reference": "Observation/be4f90a2-a433-fb21-0f23-70e43de46be5" + "reference": "Observation/26534e50-b8b4-2ec3-7f8d-c33d4c7792f1" }, { - "reference": "Observation/146f1ba0-2940-de97-93af-6c0dc64e54b2" + "reference": "Observation/7878e0ad-8700-5b8b-47d9-7acff0e1eb34" }, { - "reference": "Observation/30282793-eed9-7f34-ea78-c9465ef05757" + "reference": "Observation/437fa03d-5559-9f37-42ed-482f65dd47ce" + } + ] + }, + "request": { + "method": "PUT", + "url": "DiagnosticReport/bd4fd761-3a3c-6084-6bb0-5b21c024b208" + } + }, + { + "fullUrl": "urn:uuid:e8c2bedc-f247-6e63-2c6f-a58e26f24c33", + "resource": { + "resourceType": "Specimen", + "id": "e8c2bedc-f247-6e63-2c6f-a58e26f24c33", + "collection": { + "collector": { + "reference": "PractitionerRole/be571888-010e-9a32-e87f-f1ee1bd631a8" + } + }, + "identifier": [ + { + "value": "855238581", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "890775544", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Specimen/e8c2bedc-f247-6e63-2c6f-a58e26f24c33" + } + }, + { + "fullUrl": "urn:uuid:da437276-fd7c-eb21-1885-4041aa59c483", + "resource": { + "resourceType": "Practitioner", + "id": "da437276-fd7c-eb21-1885-4041aa59c483", + "name": [ + { + "family": "COLLECT", + "given": [ + "JOHN" + ] } ] }, "request": { "method": "PUT", - "url": "DiagnosticReport/5207c1fc-b68c-7398-6585-264869affbff" + "url": "Practitioner/da437276-fd7c-eb21-1885-4041aa59c483" + } + }, + { + "fullUrl": "urn:uuid:be571888-010e-9a32-e87f-f1ee1bd631a8", + "resource": { + "resourceType": "PractitionerRole", + "id": "be571888-010e-9a32-e87f-f1ee1bd631a8", + "practitioner": { + "reference": "Practitioner/da437276-fd7c-eb21-1885-4041aa59c483" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/be571888-010e-9a32-e87f-f1ee1bd631a8" + } + }, + { + "fullUrl": "urn:uuid:6006d57e-e0a3-d90e-7d9b-546ed575c527", + "resource": { + "resourceType": "Specimen", + "id": "6006d57e-e0a3-d90e-7d9b-546ed575c527", + "collection": { + "collectedDateTime": "2014-10-06T05:35:00" + }, + "receivedTime": "2014-10-06T06:21:00", + "identifier": [ + { + "value": "SpecimenID", + "type": { + "coding": [ + { + "code": "PGN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "type": { + "coding": [ + { + "code": "BLD", + "system": "http://terminology.hl7.org/CodeSystem/v2-0487" + } + ] + }, + "status": "available" + }, + "request": { + "method": "PUT", + "url": "Specimen/6006d57e-e0a3-d90e-7d9b-546ed575c527" } }, { @@ -665,6 +847,32 @@ } ] } + ], + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "specimen": { + "reference": "Specimen/6006d57e-e0a3-d90e-7d9b-546ed575c527" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b1410115-e911-9d20-3570-fc3c1e5c347e" + } ] }, "request": { @@ -702,6 +910,32 @@ } ] } + ], + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "specimen": { + "reference": "Specimen/6006d57e-e0a3-d90e-7d9b-546ed575c527" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b1410115-e911-9d20-3570-fc3c1e5c347e" + } ] }, "request": { @@ -739,6 +973,32 @@ } ] } + ], + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "specimen": { + "reference": "Specimen/6006d57e-e0a3-d90e-7d9b-546ed575c527" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b1410115-e911-9d20-3570-fc3c1e5c347e" + } ] }, "request": { @@ -776,6 +1036,32 @@ } ] } + ], + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "specimen": { + "reference": "Specimen/6006d57e-e0a3-d90e-7d9b-546ed575c527" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b1410115-e911-9d20-3570-fc3c1e5c347e" + } ] }, "request": { @@ -813,12 +1099,210 @@ } ] } + ], + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "specimen": { + "reference": "Specimen/6006d57e-e0a3-d90e-7d9b-546ed575c527" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b1410115-e911-9d20-3570-fc3c1e5c347e" + } ] }, "request": { "method": "PUT", "url": "Observation/30282793-eed9-7f34-ea78-c9465ef05757" } + }, + { + "fullUrl": "urn:uuid:b1410115-e911-9d20-3570-fc3c1e5c347e", + "resource": { + "resourceType": "ServiceRequest", + "id": "b1410115-e911-9d20-3570-fc3c1e5c347e", + "status": "active", + "intent": "filler-order", + "identifier": [ + { + "value": "88502218", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "82503246", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "code": { + "coding": [ + { + "code": "24317-0", + "display": "Hemogram and platelet count, automated", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "requester": { + "reference": "PractitionerRole/907170a0-a8af-89c5-5a30-6b78cdb227c5" + }, + "specimen": [ + { + "reference": "Specimen/f59e2ae9-1b51-5e9f-9ef1-2f05d070db75" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/b1410115-e911-9d20-3570-fc3c1e5c347e" + } + }, + { + "fullUrl": "urn:uuid:43054c97-ac1f-e627-4559-c8ae945117bd", + "resource": { + "resourceType": "DiagnosticReport", + "id": "43054c97-ac1f-e627-4559-c8ae945117bd", + "identifier": [ + { + "value": "88502218", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "82503246", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "code": { + "coding": [ + { + "code": "24317-0", + "display": "Hemogram and platelet count, automated", + "system": "http://loinc.org" + } + ] + }, + "status": "unknown", + "subject": { + "reference": "Patient/bab5ca58-f272-4c06-4b3f-f9661e45a22b" + }, + "basedOn": [ + { + "reference": "ServiceRequest/b1410115-e911-9d20-3570-fc3c1e5c347e" + } + ], + "specimen": [ + { + "reference": "Specimen/f59e2ae9-1b51-5e9f-9ef1-2f05d070db75" + } + ], + "result": [ + { + "reference": "Observation/8c207e70-3fd2-2bf4-df75-256240c60258" + }, + { + "reference": "Observation/874ee31e-885c-d582-b76d-e145e99a2945" + }, + { + "reference": "Observation/be4f90a2-a433-fb21-0f23-70e43de46be5" + }, + { + "reference": "Observation/146f1ba0-2940-de97-93af-6c0dc64e54b2" + }, + { + "reference": "Observation/30282793-eed9-7f34-ea78-c9465ef05757" + } + ] + }, + "request": { + "method": "PUT", + "url": "DiagnosticReport/43054c97-ac1f-e627-4559-c8ae945117bd" + } + }, + { + "fullUrl": "urn:uuid:f59e2ae9-1b51-5e9f-9ef1-2f05d070db75", + "resource": { + "resourceType": "Specimen", + "id": "f59e2ae9-1b51-5e9f-9ef1-2f05d070db75", + "collection": { + "collector": { + "reference": "PractitionerRole/be571888-010e-9a32-e87f-f1ee1bd631a8" + } + }, + "identifier": [ + { + "value": "88502218", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "82503246", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Specimen/f59e2ae9-1b51-5e9f-9ef1-2f05d070db75" + } } ] } \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORU_R01/LRI_2.0-NG_CBC_Typ_Message-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORU_R01/LRI_2.0-NG_CBC_Typ_Message-expected.json index 82507ee8b..cba9fe7e0 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORU_R01/LRI_2.0-NG_CBC_Typ_Message-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORU_R01/LRI_2.0-NG_CBC_Typ_Message-expected.json @@ -5,6 +5,7 @@ "identifier": { "value": "NIST-LRI-NG-002.00" }, + "id": "7cbc05b1-9589-f624-6bb7-edea632acfeb", "entry": [ { "fullUrl": "urn:uuid:15cde54f-eadb-4bee-fe4c-0e8dbe4f4959", @@ -59,6 +60,84 @@ "url": "MessageHeader/15cde54f-eadb-4bee-fe4c-0e8dbe4f4959" } }, + { + "fullUrl": "urn:uuid:69d21cff-2d4e-b89f-1109-5fb744517c1f", + "resource": { + "resourceType": "Provenance", + "id": "69d21cff-2d4e-b89f-1109-5fb744517c1f", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:50:36.744Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ORU_R01.

" + }, + "occurredDateTime": "2011-06-01T00:35:51+05:30", + "recorded": "2011-06-01T00:35:51+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/aa0cf9ae-78b3-73ec-0ef7-234369f8a10c" + } + } + ], + "activity": { + "coding": [ + { + "display": "ORU^R01^ORU_R01" + } + ] + }, + "target": [ + { + "reference": "Bundle/7cbc05b1-9589-f624-6bb7-edea632acfeb" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/69d21cff-2d4e-b89f-1109-5fb744517c1f" + } + }, + { + "fullUrl": "urn:uuid:aa0cf9ae-78b3-73ec-0ef7-234369f8a10c", + "resource": { + "resourceType": "Organization", + "id": "aa0cf9ae-78b3-73ec-0ef7-234369f8a10c", + "identifier": [ + { + "value": "NIST Lab Facility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NIST-Lab-Facility" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/aa0cf9ae-78b3-73ec-0ef7-234369f8a10c" + } + }, + { + "fullUrl": "urn:uuid:c828b9d8-dc07-4b58-af67-705a38d1fa4d", + "resource": { + "resourceType": "Organization", + "id": "c828b9d8-dc07-4b58-af67-705a38d1fa4d", + "identifier": [ + { + "value": "NIST EHR Facility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NIST-EHR-Facility" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/c828b9d8-dc07-4b58-af67-705a38d1fa4d" + } + }, { "fullUrl": "urn:uuid:397de93b-65e0-b3b6-7a79-d7869d57a8aa", "resource": { @@ -116,310 +195,334 @@ } }, { - "fullUrl": "urn:uuid:", + "fullUrl": "urn:uuid:9f988649-6c25-7f5f-f25c-65f3042e23b6", "resource": { - "resourceType": "Practitioner" + "resourceType": "Practitioner", + "id": "9f988649-6c25-7f5f-f25c-65f3042e23b6", + "identifier": [ + { + "type": { + "coding": [ + { + "code": "2343242" + } + ] + } + } + ] }, "request": { "method": "PUT", - "url": "Practitioner/" + "url": "Practitioner/9f988649-6c25-7f5f-f25c-65f3042e23b6" } }, { - "fullUrl": "urn:uuid:", + "fullUrl": "urn:uuid:fbbaa96a-8a5d-f670-0fcf-838b21d4c6a8", "resource": { - "resourceType": "Location" + "resourceType": "PractitionerRole", + "id": "fbbaa96a-8a5d-f670-0fcf-838b21d4c6a8", + "code": [ + { + "coding": [ + { + "code": "LabMedicalDirector", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/9f988649-6c25-7f5f-f25c-65f3042e23b6" + }, + "organization": { + "reference": "Organization/c8cd57a5-13a6-54d1-7dcd-d0a6b637c660" + } }, "request": { "method": "PUT", - "url": "Location/" + "url": "PractitionerRole/fbbaa96a-8a5d-f670-0fcf-838b21d4c6a8" } }, { - "fullUrl": "urn:uuid:1f2725f5-0c29-68dd-b124-7e4f4eba2a32", + "fullUrl": "urn:uuid:c8cd57a5-13a6-54d1-7dcd-d0a6b637c660", "resource": { - "resourceType": "Provenance", - "id": "1f2725f5-0c29-68dd-b124-7e4f4eba2a32", - "text": { - "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:59:20.123Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ORU_R01.

" - }, - "occurredDateTime": "2011-06-01T00:35:51+05:30", - "recorded": "2011-06-01T00:35:51+05:30", - "agent": [ + "resourceType": "Organization", + "id": "c8cd57a5-13a6-54d1-7dcd-d0a6b637c660", + "name": "Century Hospital", + "identifier": [ { + "value": "987", "type": { "coding": [ { - "code": "author", - "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + "code": "XX", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" } ] - }, - "who": { - "reference": "Organization/aa0cf9ae-78b3-73ec-0ef7-234369f8a10c" } } ], - "activity": { - "coding": [ - { - "display": "ORU^R01^ORU_R01" - } - ] - }, - "target": [ + "address": [ { - "reference": "Bundle/" + "line": [ + "2070 Test Park" + ], + "city": "Los Angeles", + "state": "CA", + "postalCode": "90067", + "use": "work" } ] }, "request": { "method": "PUT", - "url": "Provenance/1f2725f5-0c29-68dd-b124-7e4f4eba2a32" + "url": "Organization/c8cd57a5-13a6-54d1-7dcd-d0a6b637c660" } }, { - "fullUrl": "urn:uuid:d89caeaa-3e83-1bc6-de48-869aade1d077", + "fullUrl": "urn:uuid:b9018883-1320-3dfb-e157-cb46bb7a6679", "resource": { - "resourceType": "Account", - "id": "d89caeaa-3e83-1bc6-de48-869aade1d077", - "status": "active", - "subject": [ + "resourceType": "Observation", + "id": "b9018883-1320-3dfb-e157-cb46bb7a6679", + "status": "final", + "code": { + "coding": [ + { + "code": "26453-1", + "display": "Erythrocytes [#/volume] in Blood", + "system": "http://loinc.org" + } + ], + "text": "Erythrocytes [#/volume] in Blood" + }, + "valueQuantity": { + "value": 4.41, + "code": "10*6/uL", + "unit": "million per microliter", + "system": "http://unitsofmeasure.org" + }, + "referenceRange": [ + { + "text": "4.3 to 6.2" + } + ], + "effectiveDateTime": "2011-01-04T04:04:28+05:30", + "performer": [ + { + "reference": "PractitionerRole/fbbaa96a-8a5d-f670-0fcf-838b21d4c6a8" + } + ], + "interpretation": [ + { + "coding": [ + { + "code": "N", + "display": "Normal", + "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation" + } + ] + } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ { - "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" } ] }, "request": { "method": "PUT", - "url": "Account/d89caeaa-3e83-1bc6-de48-869aade1d077" + "url": "Observation/b9018883-1320-3dfb-e157-cb46bb7a6679" } }, { - "fullUrl": "urn:uuid:", + "fullUrl": "urn:uuid:becb609f-f513-876c-973a-98f4a3e25295", "resource": { - "resourceType": "Encounter", - "text": { - "status": "generated", - "div": "

Visit Description:

" + "resourceType": "Observation", + "id": "becb609f-f513-876c-973a-98f4a3e25295", + "status": "final", + "code": { + "coding": [ + { + "code": "718-7", + "display": "Hemoglobin [Mass/volume] in Blood", + "system": "http://loinc.org" + } + ], + "text": "Hemoglobin [Mass/volume] in Blood" + }, + "valueQuantity": { + "value": 12.5, + "code": "g/mL", + "unit": "grams per milliliter", + "system": "http://unitsofmeasure.org" }, + "referenceRange": [ + { + "text": "13 to 18" + } + ], + "effectiveDateTime": "2011-01-04T04:04:28+05:30", + "performer": [ + { + "reference": "PractitionerRole/fbbaa96a-8a5d-f670-0fcf-838b21d4c6a8" + } + ], + "interpretation": [ + { + "coding": [ + { + "code": "L", + "display": "Low", + "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation" + } + ] + } + ], "subject": { "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" - } - }, - "request": { - "method": "PUT", - "url": "Encounter/" - } - }, - { - "fullUrl": "urn:uuid:e5528a59-da05-4148-e016-5b99bdb33924", - "resource": { - "resourceType": "DiagnosticReport", - "id": "e5528a59-da05-4148-e016-5b99bdb33924", - "identifier": [ + }, + "extension": [ { - "type": { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { "coding": [ { - "code": "FILL", - "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" } - ] + ], + "text": "Final" } - }, - { - "value": "ORD666555", - "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-NIST EHR" - }, - { - "value": "R-991133", - "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-NIST Lab Filler" } ], - "effectiveDateTime": "2011-01-04T04:04:28+05:30", + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/becb609f-f513-876c-973a-98f4a3e25295" + } + }, + { + "fullUrl": "urn:uuid:418e1d5b-7cf8-4f97-2f20-064f064073bf", + "resource": { + "resourceType": "Observation", + "id": "418e1d5b-7cf8-4f97-2f20-064f064073bf", + "status": "final", "code": { "coding": [ { - "code": "57021-8", - "display": "CBC W Auto Differential panel in Blood", + "code": "20570-8", + "display": "Hematocrit [Volume Fraction] of Blood", "system": "http://loinc.org" - }, - { - "code": "4456544", - "display": "CBC", - "system": "http://example.com/v2-to-fhir-converter/CodeSystem/99USI" } ], - "text": "CBC W Auto Differential panel in Blood" + "text": "Hematocrit [Volume Fraction] of Blood" }, - "issued": "2011-01-05T06:30:28+05:30", - "status": "final", - "result": [ - { - "reference": "Observation/b9018883-1320-3dfb-e157-cb46bb7a6679" - }, - { - "reference": "Observation/becb609f-f513-876c-973a-98f4a3e25295" - }, - { - "reference": "Observation/418e1d5b-7cf8-4f97-2f20-064f064073bf" - }, - { - "reference": "Observation/63ebf56e-13b3-032c-04f0-0b0ae2596154" - }, - { - "reference": "Observation/2fecfbb4-8bfc-33df-cc06-46079a214417" - }, - { - "reference": "Observation/d88298c6-5018-0e69-8bff-bb2e57479ede" - }, - { - "reference": "Observation/4f08fab4-ea01-aeb4-20a3-50d7c4df2d1e" - }, - { - "reference": "Observation/b1082ae5-5936-88dc-f6ab-906231b9c7f1" - }, - { - "reference": "Observation/61c65289-d3f6-bd40-9fa1-33856ad2288f" - }, - { - "reference": "Observation/69a93e5e-128e-1cd9-b510-a781f1af141a" - }, - { - "reference": "Observation/95277a83-6195-ad8c-9492-f3489b45732b" - }, - { - "reference": "Observation/4cd993fb-7522-ee9f-69de-3d12d06960a7" - }, - { - "reference": "Observation/15122490-e5b2-954f-3960-d7c8f3f62632" - }, - { - "reference": "Observation/612d5b88-0687-46f9-3ada-0fc9ba9b5fe0" - }, - { - "reference": "Observation/0f40b9a3-8c63-ca5d-cc60-859cfa8a6660" - }, - { - "reference": "Observation/d9a5816e-5c0e-15fe-cd9d-417f8abd7abb" - }, - { - "reference": "Observation/db00b811-6280-5dad-bf61-07314b205438" - }, - { - "reference": "Observation/0b77694d-87ce-5da4-90c4-4d451437d2d9" - }, - { - "reference": "Observation/4c96bb15-0280-fea1-1715-e3f424cf55cc" - }, - { - "reference": "Observation/19124803-ebc8-8a88-2acc-f5b890f8c5c5" - }, - { - "reference": "Observation/6074e0a6-0ba6-b905-c957-13b2899a4dbe" - }, - { - "reference": "Observation/700cce12-7f39-bbb0-94f3-689107732835" - }, - { - "reference": "Observation/d198666f-2eae-1c28-ee17-d525a7a3ec85" - }, - { - "reference": "Observation/db250a50-54ff-eacd-ef4f-8f05b79aecad" - }, - { - "reference": "Observation/90c2203d-56d6-be20-2be4-9b879d3647a5" - }, - { - "reference": "Observation/3260b2c2-a8f9-1a32-d09f-556192b37dcd" - }, + "valueQuantity": { + "value": 41, + "code": "%", + "unit": "percent", + "system": "http://unitsofmeasure.org" + }, + "referenceRange": [ { - "reference": "Observation/ff76c538-2861-d8cf-7fc6-418d7f0688ef" - }, + "text": "40 to 52" + } + ], + "effectiveDateTime": "2011-01-04T04:04:28+05:30", + "performer": [ { - "reference": "Observation/7cb9f3da-bf77-1317-12a2-d70c8577ca71" + "reference": "PractitionerRole/fbbaa96a-8a5d-f670-0fcf-838b21d4c6a8" } ], - "specimen": [ + "interpretation": [ { - "reference": "Specimen/a1b19bd0-91c3-dbfa-4f1e-fdeb0eeb6963" + "coding": [ + { + "code": "N", + "display": "Normal", + "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation" + } + ] } - ] - }, - "request": { - "method": "PUT", - "url": "DiagnosticReport/e5528a59-da05-4148-e016-5b99bdb33924" - } - }, - { - "fullUrl": "urn:uuid:c8cd57a5-13a6-54d1-7dcd-d0a6b637c660", - "resource": { - "resourceType": "Organization", - "id": "c8cd57a5-13a6-54d1-7dcd-d0a6b637c660", - "address": [ + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ { - "line": [ - "2070 Test Park" - ], - "city": "Los Angeles", - "state": "CA", - "postalCode": "90067", - "use": "work" - }, + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ { - "line": [ - "2070 Test Park" - ], - "city": "Los Angeles", - "state": "CA", - "postalCode": "90067", - "use": "work" + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" } ] }, "request": { "method": "PUT", - "url": "Organization/c8cd57a5-13a6-54d1-7dcd-d0a6b637c660" - } - }, - { - "fullUrl": "urn:uuid:fbbaa96a-8a5d-f670-0fcf-838b21d4c6a8", - "resource": { - "resourceType": "PractitionerRole", - "id": "fbbaa96a-8a5d-f670-0fcf-838b21d4c6a8" - }, - "request": { - "method": "PUT", - "url": "PractitionerRole/fbbaa96a-8a5d-f670-0fcf-838b21d4c6a8" + "url": "Observation/418e1d5b-7cf8-4f97-2f20-064f064073bf" } }, { - "fullUrl": "urn:uuid:b9018883-1320-3dfb-e157-cb46bb7a6679", + "fullUrl": "urn:uuid:63ebf56e-13b3-032c-04f0-0b0ae2596154", "resource": { "resourceType": "Observation", - "id": "b9018883-1320-3dfb-e157-cb46bb7a6679", + "id": "63ebf56e-13b3-032c-04f0-0b0ae2596154", "status": "final", "code": { "coding": [ { - "code": "26453-1", - "display": "Erythrocytes [#/volume] in Blood", + "code": "26464-8", + "display": "Leukocytes [#/volume] in Blood", "system": "http://loinc.org" } ], - "text": "Erythrocytes [#/volume] in Blood" + "text": "Leukocytes [#/volume] in Blood" }, "valueQuantity": { - "value": 4.41, - "code": "10*6/uL", - "unit": "million per microliter", + "value": 105600, + "code": "{cells}/uL", + "unit": "cells per microliter", "system": "http://unitsofmeasure.org" }, "referenceRange": [ { - "text": "4.3 to 6.2" + "text": "4300 to 10800" } ], "effectiveDateTime": "2011-01-04T04:04:28+05:30", @@ -432,44 +535,67 @@ { "coding": [ { - "code": "N", - "display": "Normal", + "code": "HH", + "display": "Critical high", "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation" } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { "method": "PUT", - "url": "Observation/b9018883-1320-3dfb-e157-cb46bb7a6679" + "url": "Observation/63ebf56e-13b3-032c-04f0-0b0ae2596154" } }, { - "fullUrl": "urn:uuid:becb609f-f513-876c-973a-98f4a3e25295", + "fullUrl": "urn:uuid:2fecfbb4-8bfc-33df-cc06-46079a214417", "resource": { "resourceType": "Observation", - "id": "becb609f-f513-876c-973a-98f4a3e25295", + "id": "2fecfbb4-8bfc-33df-cc06-46079a214417", "status": "final", "code": { "coding": [ { - "code": "718-7", - "display": "Hemoglobin [Mass/volume] in Blood", + "code": "26515-7", + "display": "Platelets [#/volume] in Blood", "system": "http://loinc.org" } ], - "text": "Hemoglobin [Mass/volume] in Blood" + "text": "Platelets [#/volume] in Blood" }, "valueQuantity": { - "value": 12.5, - "code": "g/mL", - "unit": "grams per milliliter", + "value": 210000, + "code": "{cells}/uL", + "unit": "cells per microliter", "system": "http://unitsofmeasure.org" }, "referenceRange": [ { - "text": "13 to 18" + "text": "150000 to 350000" } ], "effectiveDateTime": "2011-01-04T04:04:28+05:30", @@ -482,44 +608,67 @@ { "coding": [ { - "code": "L", - "display": "Low", + "code": "N", + "display": "Normal", "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation" } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { "method": "PUT", - "url": "Observation/becb609f-f513-876c-973a-98f4a3e25295" + "url": "Observation/2fecfbb4-8bfc-33df-cc06-46079a214417" } }, { - "fullUrl": "urn:uuid:418e1d5b-7cf8-4f97-2f20-064f064073bf", + "fullUrl": "urn:uuid:d88298c6-5018-0e69-8bff-bb2e57479ede", "resource": { "resourceType": "Observation", - "id": "418e1d5b-7cf8-4f97-2f20-064f064073bf", + "id": "d88298c6-5018-0e69-8bff-bb2e57479ede", "status": "final", "code": { "coding": [ { - "code": "20570-8", - "display": "Hematocrit [Volume Fraction] of Blood", + "code": "30428-7", + "display": "Erythrocyte mean corpuscular volume [Entitic volume]", "system": "http://loinc.org" } ], - "text": "Hematocrit [Volume Fraction] of Blood" + "text": "Erythrocyte mean corpuscular volume [Entitic volume]" }, "valueQuantity": { - "value": 41, - "code": "%", - "unit": "percent", - "system": "http://unitsofmeasure.org" + "value": 91, + "code": "fL", + "unit": "femtoliter", + "system": "http://unitsofmeasure.org" }, "referenceRange": [ { - "text": "40 to 52" + "text": "80 to 95" } ], "effectiveDateTime": "2011-01-04T04:04:28+05:30", @@ -538,155 +687,28 @@ } ] } - ] - }, - "request": { - "method": "PUT", - "url": "Observation/418e1d5b-7cf8-4f97-2f20-064f064073bf" - } - }, - { - "fullUrl": "urn:uuid:63ebf56e-13b3-032c-04f0-0b0ae2596154", - "resource": { - "resourceType": "Observation", - "id": "63ebf56e-13b3-032c-04f0-0b0ae2596154", - "status": "final", - "code": { - "coding": [ - { - "code": "26464-8", - "display": "Leukocytes [#/volume] in Blood", - "system": "http://loinc.org" - } - ], - "text": "Leukocytes [#/volume] in Blood" - }, - "valueQuantity": { - "value": 105600, - "code": "{cells}/uL", - "unit": "cells per microliter", - "system": "http://unitsofmeasure.org" - }, - "referenceRange": [ - { - "text": "4300 to 10800" - } - ], - "effectiveDateTime": "2011-01-04T04:04:28+05:30", - "performer": [ - { - "reference": "PractitionerRole/fbbaa96a-8a5d-f670-0fcf-838b21d4c6a8" - } ], - "interpretation": [ - { - "coding": [ - { - "code": "HH", - "display": "Critical high", - "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation" - } - ] - } - ] - }, - "request": { - "method": "PUT", - "url": "Observation/63ebf56e-13b3-032c-04f0-0b0ae2596154" - } - }, - { - "fullUrl": "urn:uuid:2fecfbb4-8bfc-33df-cc06-46079a214417", - "resource": { - "resourceType": "Observation", - "id": "2fecfbb4-8bfc-33df-cc06-46079a214417", - "status": "final", - "code": { - "coding": [ - { - "code": "26515-7", - "display": "Platelets [#/volume] in Blood", - "system": "http://loinc.org" - } - ], - "text": "Platelets [#/volume] in Blood" - }, - "valueQuantity": { - "value": 210000, - "code": "{cells}/uL", - "unit": "cells per microliter", - "system": "http://unitsofmeasure.org" + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" }, - "referenceRange": [ - { - "text": "150000 to 350000" - } - ], - "effectiveDateTime": "2011-01-04T04:04:28+05:30", - "performer": [ - { - "reference": "PractitionerRole/fbbaa96a-8a5d-f670-0fcf-838b21d4c6a8" - } - ], - "interpretation": [ + "extension": [ { - "coding": [ - { - "code": "N", - "display": "Normal", - "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation" - } - ] - } - ] - }, - "request": { - "method": "PUT", - "url": "Observation/2fecfbb4-8bfc-33df-cc06-46079a214417" - } - }, - { - "fullUrl": "urn:uuid:d88298c6-5018-0e69-8bff-bb2e57479ede", - "resource": { - "resourceType": "Observation", - "id": "d88298c6-5018-0e69-8bff-bb2e57479ede", - "status": "final", - "code": { - "coding": [ - { - "code": "30428-7", - "display": "Erythrocyte mean corpuscular volume [Entitic volume]", - "system": "http://loinc.org" + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" } - ], - "text": "Erythrocyte mean corpuscular volume [Entitic volume]" - }, - "valueQuantity": { - "value": 91, - "code": "fL", - "unit": "femtoliter", - "system": "http://unitsofmeasure.org" - }, - "referenceRange": [ - { - "text": "80 to 95" - } - ], - "effectiveDateTime": "2011-01-04T04:04:28+05:30", - "performer": [ - { - "reference": "PractitionerRole/fbbaa96a-8a5d-f670-0fcf-838b21d4c6a8" } ], - "interpretation": [ + "basedOn": [ { - "coding": [ - { - "code": "N", - "display": "Normal", - "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation" - } - ] + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" } ] }, @@ -738,6 +760,29 @@ } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { @@ -788,6 +833,29 @@ } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { @@ -838,6 +906,29 @@ } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { @@ -888,6 +979,29 @@ } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { @@ -938,6 +1052,29 @@ } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { @@ -988,6 +1125,29 @@ } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { @@ -1038,6 +1198,29 @@ } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { @@ -1088,10 +1271,33 @@ } ] } - ] - }, - "request": { - "method": "PUT", + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } + ] + }, + "request": { + "method": "PUT", "url": "Observation/612d5b88-0687-46f9-3ada-0fc9ba9b5fe0" } }, @@ -1138,6 +1344,29 @@ } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { @@ -1188,6 +1417,29 @@ } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { @@ -1238,6 +1490,29 @@ } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { @@ -1288,6 +1563,29 @@ } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { @@ -1338,6 +1636,29 @@ } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { @@ -1387,6 +1708,29 @@ } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { @@ -1436,6 +1780,29 @@ } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { @@ -1485,6 +1852,29 @@ } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { @@ -1534,6 +1924,29 @@ } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { @@ -1583,6 +1996,29 @@ } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { @@ -1632,6 +2068,29 @@ } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { @@ -1672,6 +2131,29 @@ } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { @@ -1712,6 +2194,29 @@ } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { @@ -1752,6 +2257,29 @@ } ] } + ], + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } ] }, "request": { @@ -1759,6 +2287,338 @@ "url": "Observation/7cb9f3da-bf77-1317-12a2-d70c8577ca71" } }, + { + "fullUrl": "urn:uuid:b0ecf708-4aeb-a32d-0074-a3ea5b591203", + "resource": { + "resourceType": "ServiceRequest", + "id": "b0ecf708-4aeb-a32d-0074-a3ea5b591203", + "status": "active", + "intent": "filler-order", + "identifier": [ + { + "value": "ORD666555", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-NIST-EHR", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "R-991133", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-NIST-Lab-Filler", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "GORD874233", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-NIST-EHR", + "type": { + "coding": [ + { + "code": "PGN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "code": { + "coding": [ + { + "code": "57021-8", + "display": "CBC W Auto Differential panel in Blood", + "system": "http://loinc.org" + }, + { + "code": "4456544", + "display": "CBC", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/99USI" + } + ], + "text": "CBC W Auto Differential panel in Blood" + }, + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "requester": { + "reference": "PractitionerRole/3abddc6b-7cdf-a483-2997-914e226aa033" + }, + "specimen": [ + { + "reference": "Specimen/aa90eecf-8084-cda9-f937-6932c6bb4f79" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } + }, + { + "fullUrl": "urn:uuid:cdc6a323-66a4-19cb-ff4e-a5c9a5f5fd1b", + "resource": { + "resourceType": "Practitioner", + "id": "cdc6a323-66a4-19cb-ff4e-a5c9a5f5fd1b", + "identifier": [ + { + "value": "57422", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NIST-AA-1", + "type": { + "coding": [ + { + "code": "NPI", + "display": "National provider identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Radon", + "given": [ + "Nicholas" + ], + "use": "official" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/cdc6a323-66a4-19cb-ff4e-a5c9a5f5fd1b" + } + }, + { + "fullUrl": "urn:uuid:3abddc6b-7cdf-a483-2997-914e226aa033", + "resource": { + "resourceType": "PractitionerRole", + "id": "3abddc6b-7cdf-a483-2997-914e226aa033", + "practitioner": { + "reference": "Practitioner/cdc6a323-66a4-19cb-ff4e-a5c9a5f5fd1b" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/3abddc6b-7cdf-a483-2997-914e226aa033" + } + }, + { + "fullUrl": "urn:uuid:617a0645-a45a-07a5-77e4-f40de55f8c42", + "resource": { + "resourceType": "DiagnosticReport", + "id": "617a0645-a45a-07a5-77e4-f40de55f8c42", + "identifier": [ + { + "value": "ORD666555", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-NIST-EHR", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "R-991133", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-NIST-Lab-Filler", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "GORD874233", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-NIST-EHR", + "type": { + "coding": [ + { + "code": "PGN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "effectiveDateTime": "2011-01-04T04:04:28+05:30", + "code": { + "coding": [ + { + "code": "57021-8", + "display": "CBC W Auto Differential panel in Blood", + "system": "http://loinc.org" + }, + { + "code": "4456544", + "display": "CBC", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/99USI" + } + ], + "text": "CBC W Auto Differential panel in Blood" + }, + "issued": "2011-01-05T06:30:28+05:30", + "status": "final", + "subject": { + "reference": "Patient/397de93b-65e0-b3b6-7a79-d7869d57a8aa" + }, + "basedOn": [ + { + "reference": "ServiceRequest/b0ecf708-4aeb-a32d-0074-a3ea5b591203" + } + ], + "specimen": [ + { + "reference": "Specimen/aa90eecf-8084-cda9-f937-6932c6bb4f79" + } + ], + "result": [ + { + "reference": "Observation/b9018883-1320-3dfb-e157-cb46bb7a6679" + }, + { + "reference": "Observation/becb609f-f513-876c-973a-98f4a3e25295" + }, + { + "reference": "Observation/418e1d5b-7cf8-4f97-2f20-064f064073bf" + }, + { + "reference": "Observation/63ebf56e-13b3-032c-04f0-0b0ae2596154" + }, + { + "reference": "Observation/2fecfbb4-8bfc-33df-cc06-46079a214417" + }, + { + "reference": "Observation/d88298c6-5018-0e69-8bff-bb2e57479ede" + }, + { + "reference": "Observation/4f08fab4-ea01-aeb4-20a3-50d7c4df2d1e" + }, + { + "reference": "Observation/b1082ae5-5936-88dc-f6ab-906231b9c7f1" + }, + { + "reference": "Observation/61c65289-d3f6-bd40-9fa1-33856ad2288f" + }, + { + "reference": "Observation/69a93e5e-128e-1cd9-b510-a781f1af141a" + }, + { + "reference": "Observation/95277a83-6195-ad8c-9492-f3489b45732b" + }, + { + "reference": "Observation/4cd993fb-7522-ee9f-69de-3d12d06960a7" + }, + { + "reference": "Observation/15122490-e5b2-954f-3960-d7c8f3f62632" + }, + { + "reference": "Observation/612d5b88-0687-46f9-3ada-0fc9ba9b5fe0" + }, + { + "reference": "Observation/0f40b9a3-8c63-ca5d-cc60-859cfa8a6660" + }, + { + "reference": "Observation/d9a5816e-5c0e-15fe-cd9d-417f8abd7abb" + }, + { + "reference": "Observation/db00b811-6280-5dad-bf61-07314b205438" + }, + { + "reference": "Observation/0b77694d-87ce-5da4-90c4-4d451437d2d9" + }, + { + "reference": "Observation/4c96bb15-0280-fea1-1715-e3f424cf55cc" + }, + { + "reference": "Observation/19124803-ebc8-8a88-2acc-f5b890f8c5c5" + }, + { + "reference": "Observation/6074e0a6-0ba6-b905-c957-13b2899a4dbe" + }, + { + "reference": "Observation/700cce12-7f39-bbb0-94f3-689107732835" + }, + { + "reference": "Observation/d198666f-2eae-1c28-ee17-d525a7a3ec85" + }, + { + "reference": "Observation/db250a50-54ff-eacd-ef4f-8f05b79aecad" + }, + { + "reference": "Observation/90c2203d-56d6-be20-2be4-9b879d3647a5" + }, + { + "reference": "Observation/3260b2c2-a8f9-1a32-d09f-556192b37dcd" + }, + { + "reference": "Observation/ff76c538-2861-d8cf-7fc6-418d7f0688ef" + }, + { + "reference": "Observation/7cb9f3da-bf77-1317-12a2-d70c8577ca71" + } + ] + }, + "request": { + "method": "PUT", + "url": "DiagnosticReport/617a0645-a45a-07a5-77e4-f40de55f8c42" + } + }, + { + "fullUrl": "urn:uuid:aa90eecf-8084-cda9-f937-6932c6bb4f79", + "resource": { + "resourceType": "Specimen", + "id": "aa90eecf-8084-cda9-f937-6932c6bb4f79", + "collection": { + "collectedDateTime": "2011-01-04T04:04:28+05:30" + }, + "identifier": [ + { + "value": "ORD666555", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-NIST-EHR", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "R-991133", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-NIST-Lab-Filler", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Specimen/aa90eecf-8084-cda9-f937-6932c6bb4f79" + } + }, { "fullUrl": "urn:uuid:a1b19bd0-91c3-dbfa-4f1e-fdeb0eeb6963", "resource": { @@ -1772,7 +2632,7 @@ { "code": "119297000", "display": "BLD", - "system": "http://snomed.info/sct" + "system": "http://terminology.hl7.org/CodeSystem/v2-0487" } ], "text": "Blood" diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORU_R01/ORU-R01-01-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORU_R01/ORU-R01-01-expected.json new file mode 100644 index 000000000..fade60740 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORU_R01/ORU-R01-01-expected.json @@ -0,0 +1,2602 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2012-03-14T20:44:00+05:30", + "identifier": { + "value": "2.16.840.1.114222.4.3.3.5.1.2-20120314235954.325" + }, + "id": "3294d4fe-4d33-61e3-310f-3078b6bb0264", + "entry": [ + { + "fullUrl": "urn:uuid:bb2c62d5-a5ee-37cf-332d-bd928e8586f4", + "resource": { + "resourceType": "MessageHeader", + "id": "bb2c62d5-a5ee-37cf-332d-bd928e8586f4", + "source": { + "name": "IA PHIMS Stage", + "endpoint": "urn:oid:2.16.840.1.114222.4.3.3.5.1.2", + "version": "2.4.3.52854", + "software": "Rhapsody" + }, + "destination": [ + { + "name": "IA.DOH.IDSS", + "endpoint": "urn:oid:2.16.840.1.114222.4.3.3.19", + "receiver": { + "reference": "Organization/6930f42d-f2d4-5b0d-9cf8-a2108c0a4811" + } + } + ], + "meta": { + "tag": [ + { + "code": "T", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "R01", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "ORU^R01^ORU_R01" + }, + "sender": { + "reference": "Organization/353c3718-dc57-7a15-8660-7aeed24b4f7e" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/bb2c62d5-a5ee-37cf-332d-bd928e8586f4" + } + }, + { + "fullUrl": "urn:uuid:4b8e3786-de8b-c12f-345b-3c83fc1c4a0d", + "resource": { + "resourceType": "Provenance", + "id": "4b8e3786-de8b-c12f-345b-3c83fc1c4a0d", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:48:50.118Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ORU_R01.

" + }, + "occurredDateTime": "2012-03-14T20:44:00+05:30", + "recorded": "2012-03-14T20:44:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/353c3718-dc57-7a15-8660-7aeed24b4f7e" + } + } + ], + "activity": { + "coding": [ + { + "display": "ORU^R01^ORU_R01" + } + ] + }, + "target": [ + { + "reference": "Bundle/3294d4fe-4d33-61e3-310f-3078b6bb0264" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/4b8e3786-de8b-c12f-345b-3c83fc1c4a0d" + } + }, + { + "fullUrl": "urn:uuid:353c3718-dc57-7a15-8660-7aeed24b4f7e", + "resource": { + "resourceType": "Organization", + "id": "353c3718-dc57-7a15-8660-7aeed24b4f7e", + "identifier": [ + { + "value": "IA Public Health Lab", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-IA-Public-Health-Lab" + }, + { + "value": "urn:oid:2.16.840.1.114222.4.1.10411", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/353c3718-dc57-7a15-8660-7aeed24b4f7e" + } + }, + { + "fullUrl": "urn:uuid:6930f42d-f2d4-5b0d-9cf8-a2108c0a4811", + "resource": { + "resourceType": "Organization", + "id": "6930f42d-f2d4-5b0d-9cf8-a2108c0a4811", + "identifier": [ + { + "value": "IA DOH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-IA-DOH" + }, + { + "value": "urn:oid:2.16.840.1.114222.4.1.3650", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/6930f42d-f2d4-5b0d-9cf8-a2108c0a4811" + } + }, + { + "fullUrl": "urn:uuid:4b549918-a84d-cdaf-e150-c773a5d306e5", + "resource": { + "resourceType": "Device", + "id": "4b549918-a84d-cdaf-e150-c773a5d306e5", + "manufacturer": "Orion Health", + "deviceName": [ + { + "name": "Rhapsody", + "type": "manufacturer-name" + } + ], + "version": [ + { + "value": "2.4.3.52854" + } + ], + "modelNumber": "2.4.3.52854" + }, + "request": { + "method": "PUT", + "url": "Device/4b549918-a84d-cdaf-e150-c773a5d306e5" + } + }, + { + "fullUrl": "urn:uuid:389b3d01-dc6f-2c15-38c5-8c4e86a515c8", + "resource": { + "resourceType": "Patient", + "id": "389b3d01-dc6f-2c15-38c5-8c4e86a515c8", + "identifier": [ + { + "value": "14", + "type": { + "coding": [ + { + "code": "PI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Patient internal identifier" + } + ] + }, + "system": "urn:oid:2.16.840.1.114222.4.3.3.5.1.2", + "assigner": { + "reference": "Organization/5263bd4f-69ed-d465-3e10-e79f2010bf12" + } + } + ], + "name": [ + { + "family": "Finn", + "given": [ + "Huckleberry" + ], + "use": "official" + } + ], + "birthDate": "1963-08-15", + "gender": "male", + "address": [ + { + "line": [ + "721 SPRING STREET" + ], + "city": "GRINNELL", + "state": "IA", + "postalCode": "50112", + "country": "USA", + "use": "home" + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus", + "version": "2.5.1" + } + ] + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238", + "version": "04/24/2007" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "1002-5", + "display": "American Indian or Alaska Native", + "system": "urn:oid:2.16.840.1.113883.6.238", + "version": "04/24/2007" + } + }, + { + "url": "text", + "valueString": "White+American Indian or Alaska Native" + } + ] + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2135-2", + "display": "Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238", + "version": "2.5.1" + } + }, + { + "url": "text", + "valueString": "Hispanic or Latino" + } + ] + } + ], + "contact": [ + { + "name": { + "family": "Doe", + "given": [ + "Rosallie" + ] + }, + "address": { + "line": [ + "115 MAINSTREET" + ], + "city": "GOODTOWN", + "state": "KY", + "postalCode": "42010", + "country": "USA" + }, + "telecom": [ + { + "value": "(608)271-9001", + "use": "work", + "system": "phone" + } + ], + "relationship": [ + { + "coding": [ + { + "code": "C", + "display": "Emergency Contact", + "system": "http://terminology.hl7.org/CodeSystem/v2-0131" + } + ] + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/389b3d01-dc6f-2c15-38c5-8c4e86a515c8" + } + }, + { + "fullUrl": "urn:uuid:5263bd4f-69ed-d465-3e10-e79f2010bf12", + "resource": { + "resourceType": "Organization", + "id": "5263bd4f-69ed-d465-3e10-e79f2010bf12", + "identifier": [ + { + "value": "IA PHIMS Stage", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-IA-PHIMS-Stage" + }, + { + "value": "urn:oid:2.16.840.1.114222.4.3.3.5.1.2", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/5263bd4f-69ed-d465-3e10-e79f2010bf12" + } + }, + { + "fullUrl": "urn:uuid:2110f421-a2a2-e702-115a-490a55c8ce3f", + "resource": { + "resourceType": "Practitioner", + "id": "2110f421-a2a2-e702-115a-490a55c8ce3f", + "identifier": [ + { + "value": "1111", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERLt", + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "given": [ + "Zafar", + "Mahen" + ], + "suffix": [ + "JR", + "MD" + ], + "prefix": [ + "Dr." + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/2110f421-a2a2-e702-115a-490a55c8ce3f" + } + }, + { + "fullUrl": "urn:uuid:505c291e-5ae6-8346-bfe0-2587065e410e", + "resource": { + "resourceType": "PractitionerRole", + "id": "505c291e-5ae6-8346-bfe0-2587065e410e", + "code": [ + { + "coding": [ + { + "code": "ResponsibleObserver", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/2110f421-a2a2-e702-115a-490a55c8ce3f" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/505c291e-5ae6-8346-bfe0-2587065e410e" + } + }, + { + "fullUrl": "urn:uuid:e2f9615a-8a86-7a34-07b8-e75842da37f0", + "resource": { + "resourceType": "Organization", + "id": "e2f9615a-8a86-7a34-07b8-e75842da37f0", + "name": "ABC Hospital", + "address": [ + { + "line": [ + "A city", + "Florida" + ], + "city": "VA", + "state": "22031", + "postalCode": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/e2f9615a-8a86-7a34-07b8-e75842da37f0" + } + }, + { + "fullUrl": "urn:uuid:c4c46dc5-e54b-dccd-4e40-c3c13c4a537b", + "resource": { + "resourceType": "DiagnosticReport", + "id": "c4c46dc5-e54b-dccd-4e40-c3c13c4a537b", + "identifier": [ + { + "value": "EI21obx1", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-OII" + }, + { + "type": { + "coding": [ + { + "code": "FILL" + } + ] + } + } + ], + "code": { + "coding": [ + { + "code": "8867-4", + "display": "heartrate", + "system": "http://loinc.org" + } + ] + }, + "effectiveDateTime": "1999-07-02", + "status": "unknown", + "performer": [ + { + "reference": "PractitionerRole/505c291e-5ae6-8346-bfe0-2587065e410e" + }, + { + "reference": "Organization/e2f9615a-8a86-7a34-07b8-e75842da37f0" + } + ], + "presentedForm": [ + { + "contentType": "image/pict", + "url": "https://testurl.com" + } + ], + "subject": { + "reference": "Patient/389b3d01-dc6f-2c15-38c5-8c4e86a515c8" + } + }, + "request": { + "method": "PUT", + "url": "DiagnosticReport/c4c46dc5-e54b-dccd-4e40-c3c13c4a537b" + } + }, + { + "fullUrl": "urn:uuid:c9562bfa-117f-9b25-6657-9b7cff7e1674", + "resource": { + "resourceType": "DocumentReference", + "id": "c9562bfa-117f-9b25-6657-9b7cff7e1674", + "type": { + "coding": [ + { + "code": "DIS" + } + ] + }, + "context": { + "period": { + "start": "2010-11-10T21:33:00+05:30" + }, + "related": [ + { + "reference": "Practitioner/947f0d75-9af8-89a8-95bd-ff52ff01c0ca" + } + ] + }, + "content": [ + { + "attachment": { + "creation": "2010-11-03T03:15:00+05:30", + "contentType": "image/jpeg" + } + } + ], + "meta": { + "lastUpdated": "2010-11-03T17:01:00+05:30" + }, + "author": [ + { + "reference": "PractitionerRole/ad4f4bb2-0d02-6ca5-aa3b-ec7536350534" + } + ], + "authenticator": { + "reference": "PractitionerRole/d584ea61-be76-cc13-dd34-14aacfeec6ce" + }, + "masterIdentifier": { + "value": "018840" + }, + "identifier": [ + { + "value": "54302-DEX", + "type": { + "coding": [ + { + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-identifertype", + "code": "DOCI", + "display": "Document unique identifier" + } + ], + "text": "Document unique file name" + } + } + ], + "relatesTo": [ + { + "code": "appends", + "target": { + "identifier": { + "value": "1307506", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-test" + } + } + } + ], + "docStatus": "preliminary", + "securityLabel": [ + { + "coding": [ + { + "code": "R", + "system": "http://terminology.hl7.org/CodeSystem/v3-Confidentiality" + } + ] + } + ], + "status": "current", + "category": [ + { + "coding": [ + { + "code": "radiology report" + } + ] + } + ], + "description": "string ofCharacters" + }, + "request": { + "method": "PUT", + "url": "DocumentReference/c9562bfa-117f-9b25-6657-9b7cff7e1674" + } + }, + { + "fullUrl": "urn:uuid:947f0d75-9af8-89a8-95bd-ff52ff01c0ca", + "resource": { + "resourceType": "Practitioner", + "id": "947f0d75-9af8-89a8-95bd-ff52ff01c0ca", + "identifier": [ + { + "value": "John Smith" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/947f0d75-9af8-89a8-95bd-ff52ff01c0ca" + } + }, + { + "fullUrl": "urn:uuid:a0aa5af5-861a-b4eb-7cdf-7e307438caac", + "resource": { + "resourceType": "Practitioner", + "id": "a0aa5af5-861a-b4eb-7cdf-7e307438caac", + "identifier": [ + { + "value": "Chris Rock" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/a0aa5af5-861a-b4eb-7cdf-7e307438caac" + } + }, + { + "fullUrl": "urn:uuid:ad4f4bb2-0d02-6ca5-aa3b-ec7536350534", + "resource": { + "resourceType": "PractitionerRole", + "id": "ad4f4bb2-0d02-6ca5-aa3b-ec7536350534", + "practitioner": { + "reference": "Practitioner/a0aa5af5-861a-b4eb-7cdf-7e307438caac" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/ad4f4bb2-0d02-6ca5-aa3b-ec7536350534" + } + }, + { + "fullUrl": "urn:uuid:d7921b9f-42a0-6e35-cc6e-ca15c5af36bb", + "resource": { + "resourceType": "Practitioner", + "id": "d7921b9f-42a0-6e35-cc6e-ca15c5af36bb", + "identifier": [ + { + "value": "Emma Watson" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/d7921b9f-42a0-6e35-cc6e-ca15c5af36bb" + } + }, + { + "fullUrl": "urn:uuid:d584ea61-be76-cc13-dd34-14aacfeec6ce", + "resource": { + "resourceType": "PractitionerRole", + "id": "d584ea61-be76-cc13-dd34-14aacfeec6ce", + "practitioner": { + "reference": "Practitioner/d7921b9f-42a0-6e35-cc6e-ca15c5af36bb" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/d584ea61-be76-cc13-dd34-14aacfeec6ce" + } + }, + { + "fullUrl": "urn:uuid:8877e882-e573-a85d-7172-b48e78842771", + "resource": { + "resourceType": "ServiceRequest", + "id": "8877e882-e573-a85d-7172-b48e78842771", + "identifier": [ + { + "value": "PAI-8.1", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "FAI-8.2", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "type": { + "coding": [ + { + "code": "PUSI", + "display": "parent Identifier", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/AR" + } + ] + } + } + ], + "status": "completed", + "intent": "filler-order", + "subject": { + "reference": "Patient/389b3d01-dc6f-2c15-38c5-8c4e86a515c8" + } + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/8877e882-e573-a85d-7172-b48e78842771" + } + }, + { + "fullUrl": "urn:uuid:e3f8a0a0-4237-82ce-d31d-1529c13ad523", + "resource": { + "resourceType": "ServiceRequest", + "id": "e3f8a0a0-4237-82ce-d31d-1529c13ad523", + "status": "completed", + "intent": "filler-order", + "orderDetail": [ + { + "coding": [ + { + "code": "PSS-46", + "display": "Placer service", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + }, + { + "coding": [ + { + "code": "FSS-47", + "display": "Filler service", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "identifier": [ + { + "value": "845439", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHH-OE", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "986", + "system": "urn:oid:2.16.840.1.114222.4.3.3.5.1.2", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "PGN-04", + "type": { + "coding": [ + { + "code": "PGN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "APON-53", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "authoredOn": "2020-09-10T20:15:00+05:30", + "basedOn": [ + { + "reference": "ServiceRequest/8877e882-e573-a85d-7172-b48e78842771" + } + ], + "locationCode": [ + { + "coding": [ + { + "code": "BLB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + } + ] + }, + { + "coding": [ + { + "code": "OF", + "display": "Outpatient facility", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "note": [ + { + "text": "Placer 1", + "authorString": "Placer Field 1" + }, + { + "text": "Placer 2", + "authorString": "Placer Field 2" + }, + { + "text": "Filler 1", + "authorString": "Filler Field 1" + }, + { + "text": "Filler 2", + "authorString": "Filler Field 2" + }, + { + "text": "Enteric culture includes testing for Salmonella, Shigella, Campylobacter, Yersinia, E.coli O157:H7 & other STECs, and Aeromonas" + }, + { + "text": "Allergy to peanuts observed.", + "time": "2020-10-10T19:15:00+05:30", + "authorReference": { + "reference": "Practitioner/6c9ea0f5-1b45-04f9-e07d-bae5096b7a4a" + } + }, + { + "text": "Please follow the text instructions" + } + ], + "priority": "asap", + "code": { + "coding": [ + { + "code": "625-4", + "display": "Bacteria identified in Stool by Culture", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/XYZ", + "version": "2.33" + } + ], + "text": "Enteric Culture" + }, + "reasonCode": [ + { + "coding": [ + { + "code": "444", + "display": "Reason for study", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L", + "version": "MD" + } + ] + } + ], + "subject": { + "reference": "Patient/389b3d01-dc6f-2c15-38c5-8c4e86a515c8" + }, + "reasonReference": [ + { + "reference": "DocumentReference/c9562bfa-117f-9b25-6657-9b7cff7e1674" + } + ], + "requester": { + "reference": "PractitionerRole/beeb9a6e-29ec-7926-4f50-287c7ce3a1f5" + }, + "specimen": [ + { + "reference": "Specimen/95c9f253-3bac-cf73-202b-907e4e997489" + } + ], + "asNeededCodeableConcept": { + "text": "This is condition text" + }, + "quantityQuantity": { + "value": 54, + "unit": "lbs" + }, + "occurrenceTiming": { + "code": { + "coding": [ + { + "code": "ACM", + "display": "Before Breakfast", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/HL7xxx" + } + ] + }, + "repeat": { + "period": 12, + "periodUnit": "min", + "when": [ + "ACM" + ], + "offset": 2, + "boundsPeriod": { + "start": "2021-10-10T05:30:00+05:30", + "end": "2021-11-10T05:30:00+05:30" + }, + "duration": 2, + "durationUnit": "h", + "count": 5 + } + } + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/e3f8a0a0-4237-82ce-d31d-1529c13ad523" + } + }, + { + "fullUrl": "urn:uuid:58e7269f-6c76-d387-8454-ff4b18a7fccd", + "resource": { + "resourceType": "Organization", + "id": "58e7269f-6c76-d387-8454-ff4b18a7fccd", + "name": "MISSOURI DEPARTMENT OF HEALTH LABORATORY - MISSOURI DEPARTMENT OF HEALTH LABORATORY", + "address": [ + { + "line": [ + "307 W MCCARTY ST" + ], + "city": "JEFFERSON CITY", + "state": "MO", + "postalCode": "65101", + "country": "USA", + "use": "work" + } + ], + "contact": [ + { + "telecom": [ + { + "use": "work", + "system": "phone" + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/58e7269f-6c76-d387-8454-ff4b18a7fccd" + } + }, + { + "fullUrl": "urn:uuid:beeb9a6e-29ec-7926-4f50-287c7ce3a1f5", + "resource": { + "resourceType": "PractitionerRole", + "id": "beeb9a6e-29ec-7926-4f50-287c7ce3a1f5", + "organization": { + "reference": "Organization/58e7269f-6c76-d387-8454-ff4b18a7fccd" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/beeb9a6e-29ec-7926-4f50-287c7ce3a1f5" + } + }, + { + "fullUrl": "urn:uuid:df03b003-6818-1abd-209e-0889025aad16", + "resource": { + "resourceType": "Organization", + "id": "df03b003-6818-1abd-209e-0889025aad16", + "identifier": [ + { + "value": "NPIID", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NPIID" + }, + { + "value": "urn:oid:2.16.840.1.113883.4.6", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/df03b003-6818-1abd-209e-0889025aad16" + } + }, + { + "fullUrl": "urn:uuid:6c9ea0f5-1b45-04f9-e07d-bae5096b7a4a", + "resource": { + "resourceType": "Practitioner", + "id": "6c9ea0f5-1b45-04f9-e07d-bae5096b7a4a", + "identifier": [ + { + "value": "9941339108", + "system": "urn:oid:2.16.840.1.113883.4.6", + "assigner": { + "reference": "Organization/df03b003-6818-1abd-209e-0889025aad16" + }, + "type": { + "coding": [ + { + "code": "NPI", + "display": "National provider identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Smith", + "given": [ + "Adam", + "Mellie" + ], + "suffix": [ + "Jr", + "MD", + "GP" + ], + "prefix": [ + "Dr" + ], + "use": "official", + "period": { + "start": "2010-01-15", + "end": "2020-01-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/6c9ea0f5-1b45-04f9-e07d-bae5096b7a4a" + } + }, + { + "fullUrl": "urn:uuid:dbcb1b2a-6b6c-3b26-2bd9-20dde24f9cdb", + "resource": { + "resourceType": "Practitioner", + "id": "dbcb1b2a-6b6c-3b26-2bd9-20dde24f9cdb", + "identifier": [ + { + "value": "Harry" + } + ], + "name": [ + { + "family": "Raud", + "given": [ + "Geny" + ], + "suffix": [ + "Mr." + ], + "prefix": [ + "Dr." + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/dbcb1b2a-6b6c-3b26-2bd9-20dde24f9cdb" + } + }, + { + "fullUrl": "urn:uuid:8182cb21-0236-09c6-937c-c04615216e29", + "resource": { + "resourceType": "PractitionerRole", + "id": "8182cb21-0236-09c6-937c-c04615216e29", + "location": [ + { + "reference": "Location/f120dcaf-8a79-00e0-4045-9383d82935b6" + } + ], + "practitioner": { + "reference": "Practitioner/dbcb1b2a-6b6c-3b26-2bd9-20dde24f9cdb" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/8182cb21-0236-09c6-937c-c04615216e29" + } + }, + { + "fullUrl": "urn:uuid:f120dcaf-8a79-00e0-4045-9383d82935b6", + "resource": { + "resourceType": "Location", + "id": "f120dcaf-8a79-00e0-4045-9383d82935b6", + "partOf": { + "reference": "Location/f7028223-0ee3-7152-e027-07bb5b0224ac" + }, + "name": "Poc-32", + "mode": "instance", + "description": "Harry--Raud--Geny--Mr.--Dr.--Poc-32--Room-4--Bed3--Facility-3--1.2--ISO--Building-4--FL-2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/f120dcaf-8a79-00e0-4045-9383d82935b6" + } + }, + { + "fullUrl": "urn:uuid:2732e881-cd1e-fe71-a03e-521f112a1e7d", + "resource": { + "resourceType": "Location", + "id": "2732e881-cd1e-fe71-a03e-521f112a1e7d", + "partOf": { + "reference": "Location/f120dcaf-8a79-00e0-4045-9383d82935b6" + }, + "name": "Room-4", + "mode": "instance", + "description": "Harry--Raud--Geny--Mr.--Dr.--Poc-32--Room-4--Bed3--Facility-3--1.2--ISO--Building-4--FL-2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/2732e881-cd1e-fe71-a03e-521f112a1e7d" + } + }, + { + "fullUrl": "urn:uuid:faa87bc6-7206-7406-fe54-24bab9877eb3", + "resource": { + "resourceType": "Location", + "id": "faa87bc6-7206-7406-fe54-24bab9877eb3", + "partOf": { + "reference": "Location/2732e881-cd1e-fe71-a03e-521f112a1e7d" + }, + "name": "Bed3", + "mode": "instance", + "description": "Harry--Raud--Geny--Mr.--Dr.--Poc-32--Room-4--Bed3--Facility-3--1.2--ISO--Building-4--FL-2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/faa87bc6-7206-7406-fe54-24bab9877eb3" + } + }, + { + "fullUrl": "urn:uuid:739b2979-f712-b0f4-daad-acefae9b4feb", + "resource": { + "resourceType": "Location", + "id": "739b2979-f712-b0f4-daad-acefae9b4feb", + "name": "Facility-3", + "identifier": [ + { + "value": "urn:oid:1.2", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "Harry--Raud--Geny--Mr.--Dr.--Poc-32--Room-4--Bed3--Facility-3--1.2--ISO--Building-4--FL-2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/739b2979-f712-b0f4-daad-acefae9b4feb" + } + }, + { + "fullUrl": "urn:uuid:8f787230-6d25-6e0e-db3d-96fd13a2d66c", + "resource": { + "resourceType": "Location", + "id": "8f787230-6d25-6e0e-db3d-96fd13a2d66c", + "partOf": { + "reference": "Location/739b2979-f712-b0f4-daad-acefae9b4feb" + }, + "name": "Building-4", + "mode": "instance", + "description": "Harry--Raud--Geny--Mr.--Dr.--Poc-32--Room-4--Bed3--Facility-3--1.2--ISO--Building-4--FL-2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/8f787230-6d25-6e0e-db3d-96fd13a2d66c" + } + }, + { + "fullUrl": "urn:uuid:f7028223-0ee3-7152-e027-07bb5b0224ac", + "resource": { + "resourceType": "Location", + "id": "f7028223-0ee3-7152-e027-07bb5b0224ac", + "partOf": { + "reference": "Location/8f787230-6d25-6e0e-db3d-96fd13a2d66c" + }, + "name": "FL-2", + "mode": "instance", + "description": "Harry--Raud--Geny--Mr.--Dr.--Poc-32--Room-4--Bed3--Facility-3--1.2--ISO--Building-4--FL-2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/f7028223-0ee3-7152-e027-07bb5b0224ac" + } + }, + { + "resource": { + "resourceType": "DiagnosticReport", + "id": "3c202c0c-e3eb-2262-23c1-e1f328a0bbe4", + "resultsInterpreter": [ + { + "reference": "PractitionerRole/8182cb21-0236-09c6-937c-c04615216e29" + } + ], + "identifier": [ + { + "value": "845439", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHH-OE", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "986", + "system": "urn:oid:2.16.840.1.114222.4.3.3.5.1.2", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "PGN-04", + "type": { + "coding": [ + { + "code": "PGN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "effectiveDateTime": "2002-02-15T10:45:00+05:30", + "code": { + "coding": [ + { + "code": "625-4", + "display": "Bacteria identified in Stool by Culture", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/XYZ", + "version": "2.33" + } + ], + "text": "Enteric Culture" + }, + "issued": "2002-03-15T10:45:00+05:30", + "category": [ + { + "coding": [ + { + "code": "BLB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0074" + } + ] + } + ], + "status": "final", + "performer": [ + { + "reference": "PractitionerRole/6f4104a9-6928-bcaf-7719-2fb47f0c2df5" + }, + { + "reference": "PractitionerRole/f035eb01-dd52-98c8-42f4-08d3a63e5aa2" + } + ], + "subject": { + "reference": "Patient/389b3d01-dc6f-2c15-38c5-8c4e86a515c8" + }, + "basedOn": [ + { + "reference": "ServiceRequest/e3f8a0a0-4237-82ce-d31d-1529c13ad523" + } + ], + "specimen": [ + { + "reference": "Specimen/95c9f253-3bac-cf73-202b-907e4e997489" + } + ], + "result": [ + { + "reference": "Observation/700b7d4e-2516-cae2-2f83-a0a85eab1025" + } + ] + }, + "fullUrl": "urn:uuid:3c202c0c-e3eb-2262-23c1-e1f328a0bbe4", + "request": { + "method": "PUT", + "url": "DiagnosticReport/3c202c0c-e3eb-2262-23c1-e1f328a0bbe4" + } + }, + { + "fullUrl": "urn:uuid:8c441677-2d13-b04b-260c-45f02d79bc0e", + "resource": { + "resourceType": "Practitioner", + "id": "8c441677-2d13-b04b-260c-45f02d79bc0e", + "identifier": [ + { + "value": "Richa" + } + ], + "name": [ + { + "suffix": [ + "Mr." + ], + "prefix": [ + "Md." + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/8c441677-2d13-b04b-260c-45f02d79bc0e" + } + }, + { + "fullUrl": "urn:uuid:6f4104a9-6928-bcaf-7719-2fb47f0c2df5", + "resource": { + "resourceType": "PractitionerRole", + "id": "6f4104a9-6928-bcaf-7719-2fb47f0c2df5", + "code": [ + { + "coding": [ + { + "code": "TECH" + } + ] + } + ], + "location": [ + { + "reference": "Location/59b00d6f-7e90-a8a3-eec1-19d7f88514ea" + } + ], + "practitioner": { + "reference": "Practitioner/8c441677-2d13-b04b-260c-45f02d79bc0e" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/6f4104a9-6928-bcaf-7719-2fb47f0c2df5" + } + }, + { + "fullUrl": "urn:uuid:59b00d6f-7e90-a8a3-eec1-19d7f88514ea", + "resource": { + "resourceType": "Location", + "id": "59b00d6f-7e90-a8a3-eec1-19d7f88514ea", + "partOf": { + "reference": "Location/419f9823-93d6-9783-fc89-e37418b9f4cb" + }, + "name": "Poc-34", + "mode": "instance", + "description": "Richa--Mr.--Md.--Poc-34--Rm-4--Bed2--Facility-4--1.22--ISO--Building-3--FL-3", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/59b00d6f-7e90-a8a3-eec1-19d7f88514ea" + } + }, + { + "fullUrl": "urn:uuid:c5fb4a94-3953-175e-8c5f-af620ce4dab3", + "resource": { + "resourceType": "Location", + "id": "c5fb4a94-3953-175e-8c5f-af620ce4dab3", + "partOf": { + "reference": "Location/59b00d6f-7e90-a8a3-eec1-19d7f88514ea" + }, + "name": "Rm-4", + "mode": "instance", + "description": "Richa--Mr.--Md.--Poc-34--Rm-4--Bed2--Facility-4--1.22--ISO--Building-3--FL-3", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c5fb4a94-3953-175e-8c5f-af620ce4dab3" + } + }, + { + "fullUrl": "urn:uuid:a66a65b5-fb3e-d5cc-deaa-2c7dd809fedb", + "resource": { + "resourceType": "Location", + "id": "a66a65b5-fb3e-d5cc-deaa-2c7dd809fedb", + "partOf": { + "reference": "Location/c5fb4a94-3953-175e-8c5f-af620ce4dab3" + }, + "name": "Bed2", + "mode": "instance", + "description": "Richa--Mr.--Md.--Poc-34--Rm-4--Bed2--Facility-4--1.22--ISO--Building-3--FL-3", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bd" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/a66a65b5-fb3e-d5cc-deaa-2c7dd809fedb" + } + }, + { + "fullUrl": "urn:uuid:6bfb18a9-f219-312a-ee80-9e291ef76221", + "resource": { + "resourceType": "Location", + "id": "6bfb18a9-f219-312a-ee80-9e291ef76221", + "name": "Facility-4", + "identifier": [ + { + "value": "urn:oid:1.22", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "Richa--Mr.--Md.--Poc-34--Rm-4--Bed2--Facility-4--1.22--ISO--Building-3--FL-3", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/6bfb18a9-f219-312a-ee80-9e291ef76221" + } + }, + { + "fullUrl": "urn:uuid:0d82ce59-bb51-650a-f3fa-c6497491502f", + "resource": { + "resourceType": "Location", + "id": "0d82ce59-bb51-650a-f3fa-c6497491502f", + "partOf": { + "reference": "Location/6bfb18a9-f219-312a-ee80-9e291ef76221" + }, + "name": "Building-3", + "mode": "instance", + "description": "Richa--Mr.--Md.--Poc-34--Rm-4--Bed2--Facility-4--1.22--ISO--Building-3--FL-3", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d82ce59-bb51-650a-f3fa-c6497491502f" + } + }, + { + "fullUrl": "urn:uuid:419f9823-93d6-9783-fc89-e37418b9f4cb", + "resource": { + "resourceType": "Location", + "id": "419f9823-93d6-9783-fc89-e37418b9f4cb", + "partOf": { + "reference": "Location/0d82ce59-bb51-650a-f3fa-c6497491502f" + }, + "name": "FL-3", + "mode": "instance", + "description": "Richa--Mr.--Md.--Poc-34--Rm-4--Bed2--Facility-4--1.22--ISO--Building-3--FL-3", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/419f9823-93d6-9783-fc89-e37418b9f4cb" + } + }, + { + "fullUrl": "urn:uuid:c6073275-8b6b-8315-211c-f96e9700b6ae", + "resource": { + "resourceType": "Practitioner", + "id": "c6073275-8b6b-8315-211c-f96e9700b6ae", + "identifier": [ + { + "value": "35" + } + ], + "name": [ + { + "family": "Samuel" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/c6073275-8b6b-8315-211c-f96e9700b6ae" + } + }, + { + "fullUrl": "urn:uuid:f035eb01-dd52-98c8-42f4-08d3a63e5aa2", + "resource": { + "resourceType": "PractitionerRole", + "id": "f035eb01-dd52-98c8-42f4-08d3a63e5aa2", + "code": [ + { + "coding": [ + { + "code": "TRANS" + } + ] + } + ], + "period": { + "start": "2002-11-11", + "end": "2002-11-12" + }, + "location": [ + { + "reference": "Location/ce40a46d-eaed-b5a4-ef6e-463cae637157" + } + ], + "practitioner": { + "reference": "Practitioner/c6073275-8b6b-8315-211c-f96e9700b6ae" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/f035eb01-dd52-98c8-42f4-08d3a63e5aa2" + } + }, + { + "fullUrl": "urn:uuid:ce40a46d-eaed-b5a4-ef6e-463cae637157", + "resource": { + "resourceType": "Location", + "id": "ce40a46d-eaed-b5a4-ef6e-463cae637157", + "name": "Area23", + "mode": "instance", + "description": "35--Samuel--20021111--20021112--Area23", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/ce40a46d-eaed-b5a4-ef6e-463cae637157" + } + }, + { + "fullUrl": "urn:uuid:95c9f253-3bac-cf73-202b-907e4e997489", + "resource": { + "resourceType": "Specimen", + "id": "95c9f253-3bac-cf73-202b-907e4e997489", + "collection": { + "quantity": { + "value": 150, + "unit": "lb" + }, + "collector": { + "reference": "PractitionerRole/9f64bd3b-d5e9-678b-2f14-b0d756a4e7f1" + }, + "bodySite": { + "coding": [ + { + "code": "BN", + "display": "223.3", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + }, + "method": { + "text": "Collection Method" + }, + "collectedDateTime": "2002-02-15T10:45:00+05:30" + }, + "receivedTime": "2002-02-12T10:45:00+05:30", + "identifier": [ + { + "value": "845439", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHH-OE", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "986", + "system": "urn:oid:2.16.840.1.114222.4.3.3.5.1.2", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "APON-53", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "type": { + "coding": [ + { + "code": "SP15", + "display": "1.2", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + }, + "container": [ + { + "additiveCodeableConcept": { + "coding": [ + { + "code": "ACDA" + } + ] + } + } + ], + "note": [ + { + "text": "Collector's comment" + } + ] + }, + "request": { + "method": "PUT", + "url": "Specimen/95c9f253-3bac-cf73-202b-907e4e997489" + } + }, + { + "fullUrl": "urn:uuid:ae62dffe-1a0f-c68b-e7a3-e33cfce7761e", + "resource": { + "resourceType": "Practitioner", + "id": "ae62dffe-1a0f-c68b-e7a3-e33cfce7761e", + "identifier": [ + { + "value": "10535", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-L", + "type": { + "coding": [ + { + "code": "MR", + "display": "Medical record number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "van Beethoven", + "given": [ + "Ludwig", + "A" + ], + "suffix": [ + "III", + "PHD" + ], + "prefix": [ + "Dr" + ], + "use": "official" + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/ae62dffe-1a0f-c68b-e7a3-e33cfce7761e" + } + }, + { + "fullUrl": "urn:uuid:9f64bd3b-d5e9-678b-2f14-b0d756a4e7f1", + "resource": { + "resourceType": "PractitionerRole", + "id": "9f64bd3b-d5e9-678b-2f14-b0d756a4e7f1", + "practitioner": { + "reference": "Practitioner/ae62dffe-1a0f-c68b-e7a3-e33cfce7761e" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/9f64bd3b-d5e9-678b-2f14-b0d756a4e7f1" + } + }, + { + "fullUrl": "urn:uuid:e82402a9-b2d1-2a28-3250-c099d5a77bf7", + "resource": { + "resourceType": "Organization", + "id": "e82402a9-b2d1-2a28-3250-c099d5a77bf7", + "identifier": [ + { + "value": "PERSt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/e82402a9-b2d1-2a28-3250-c099d5a77bf7" + } + }, + { + "fullUrl": "urn:uuid:ce70e6c3-c190-121d-c251-e4bae5cde6a1", + "resource": { + "resourceType": "Practitioner", + "id": "ce70e6c3-c190-121d-c251-e4bae5cde6a1", + "identifier": [ + { + "value": "1134", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/e82402a9-b2d1-2a28-3250-c099d5a77bf7" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Aly", + "given": [ + "Zafar", + "Mahendra" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/ce70e6c3-c190-121d-c251-e4bae5cde6a1" + } + }, + { + "fullUrl": "urn:uuid:88a53755-c972-6904-b4ce-8884b84ddc2e", + "resource": { + "resourceType": "PractitionerRole", + "id": "88a53755-c972-6904-b4ce-8884b84ddc2e", + "code": [ + { + "coding": [ + { + "code": "ResponsibleObserver", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/ce70e6c3-c190-121d-c251-e4bae5cde6a1" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/88a53755-c972-6904-b4ce-8884b84ddc2e" + } + }, + { + "fullUrl": "urn:uuid:fe0adb86-ebe9-6479-0055-9db8dc1ff99a", + "resource": { + "resourceType": "Device", + "id": "fe0adb86-ebe9-6479-0055-9db8dc1ff99a", + "identifier": [ + { + "value": "EI12.3", + "system": "urn:uuid:UI2", + "type": { + "coding": [ + { + "code": "GUID", + "display": "Same as UUID.", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + }, + { + "system": "urn:oid:UI1", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/fe0adb86-ebe9-6479-0055-9db8dc1ff99a" + } + }, + { + "fullUrl": "urn:uuid:45f65e47-46c4-1a54-f9fb-1321258e79b2", + "resource": { + "resourceType": "Practitioner", + "id": "45f65e47-46c4-1a54-f9fb-1321258e79b2", + "identifier": [ + { + "type": { + "coding": [ + { + "code": "MD-25" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/45f65e47-46c4-1a54-f9fb-1321258e79b2" + } + }, + { + "fullUrl": "urn:uuid:090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3", + "resource": { + "resourceType": "PractitionerRole", + "id": "090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3", + "code": [ + { + "coding": [ + { + "code": "LabMedicalDirector", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/45f65e47-46c4-1a54-f9fb-1321258e79b2" + }, + "organization": { + "reference": "Organization/08c155be-912e-af06-d464-5b6bb63d660f" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3" + } + }, + { + "fullUrl": "urn:uuid:08c155be-912e-af06-d464-5b6bb63d660f", + "resource": { + "resourceType": "Organization", + "id": "08c155be-912e-af06-d464-5b6bb63d660f", + "name": "State Hygienic Laboratory", + "identifier": [ + { + "value": "16D0648109", + "type": { + "coding": [ + { + "code": "FI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "address": [ + { + "line": [ + "State Hygienic Laboratory", + "UI Research Park -Coralville" + ], + "city": "Iowa City", + "state": "IA", + "postalCode": "52242-5002", + "country": "USA", + "use": "work" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/08c155be-912e-af06-d464-5b6bb63d660f" + } + }, + { + "fullUrl": "urn:uuid:700b7d4e-2516-cae2-2f83-a0a85eab1025", + "resource": { + "resourceType": "Observation", + "id": "700b7d4e-2516-cae2-2f83-a0a85eab1025", + "identifier": [ + { + "value": "EI21", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-OII" + }, + { + "type": { + "coding": [ + { + "code": "FILL" + } + ] + } + } + ], + "status": "preliminary", + "code": { + "coding": [ + { + "code": "625-4", + "display": "Bacteria identified in Stool by Culture", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/XYZ", + "version": "2.33" + } + ], + "text": "result1" + }, + "valueCodeableConcept": { + "coding": [ + { + "code": "27268008", + "display": "Salmonella", + "system": "http://snomed.info/sct", + "version": "20090731" + } + ], + "text": "Salmonella species" + }, + "referenceRange": [ + { + "text": "70-80" + } + ], + "effectiveDateTime": "2012-03-01", + "method": { + "text": "Bacterial Culture" + }, + "device": { + "reference": "Device/fe0adb86-ebe9-6479-0055-9db8dc1ff99a" + }, + "bodySite": { + "coding": [ + { + "code": "BU", + "display": "Observation site", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/E5" + } + ] + }, + "performer": [ + { + "reference": "PractitionerRole/88a53755-c972-6904-b4ce-8884b84ddc2e" + }, + { + "reference": "PractitionerRole/090ea2e4-0a3a-eb7f-8f9f-16dd7d13f7f3" + } + ], + "interpretation": [ + { + "coding": [ + { + "code": "A", + "display": "Abnormal", + "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation", + "version": "2.5" + } + ] + } + ], + "subject": { + "reference": "Patient/389b3d01-dc6f-2c15-38c5-8c4e86a515c8" + }, + "basedOn": [ + { + "reference": "ServiceRequest/e3f8a0a0-4237-82ce-d31d-1529c13ad523" + } + ], + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "P", + "display": "Preliminary", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Preliminary" + } + } + ], + "note": [ + { + "text": "Submission of serum", + "time": "2020-10-10T19:15:00+05:30", + "authorReference": { + "reference": "Practitioner/ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2" + } + }, + { + "text": "No Antibodies Detected", + "time": "2020-10-10T18:15:00+05:30", + "authorReference": { + "reference": "Practitioner/ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/700b7d4e-2516-cae2-2f83-a0a85eab1025" + } + }, + { + "fullUrl": "urn:uuid:ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2", + "resource": { + "resourceType": "Practitioner", + "id": "ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2", + "identifier": [ + { + "value": "MLEE" + } + ], + "name": [ + { + "family": "ATTEND", + "given": [ + "AARON", + "A" + ], + "suffix": [ + "MD" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/ca6d10cc-e8a7-9d21-bd61-ec6d1db557c2" + } + }, + { + "fullUrl": "urn:uuid:ea6d5bd5-5c2e-227c-c792-f3f8eb46691b", + "resource": { + "resourceType": "Specimen", + "id": "ea6d5bd5-5c2e-227c-c792-f3f8eb46691b", + "collection": { + "quantity": { + "value": 40, + "unit": "lbs" + }, + "bodySite": { + "coding": [ + { + "code": "BAP", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/HL70488" + } + ], + "text": "Specimen source site" + }, + "method": { + "coding": [ + { + "code": "BCAE", + "system": "http://terminology.hl7.org/CodeSystem/v2-0488" + } + ] + }, + "collectedPeriod": { + "start": "2011-01-04T04:04:28+05:30", + "end": "2011-11-04T04:04:28+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/specimen-specialHandling", + "valueCodeableConcept": { + "coding": [ + { + "code": "AMB", + "display": "Ambient Temperature", + "system": "http://terminology.hl7.org/CodeSystem/v2-0376" + }, + { + "code": "DRY", + "display": "dry", + "system": "http://terminology.hl7.org/CodeSystem/v2-0376" + } + ] + } + } + ] + }, + "receivedTime": "2012-03-01", + "identifier": [ + { + "value": "2012545", + "type": { + "coding": [ + { + "code": "PGN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "2012999999", + "type": { + "coding": [ + { + "code": "FGN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "OSI-31", + "type": { + "coding": [ + { + "code": "PI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Patient internal identifier" + } + ] + }, + "system": "urn:uuid:2.16.840.1.114222", + "assigner": { + "reference": "Organization/322ca8cf-e43e-973c-3149-9e499675ddca" + } + }, + { + "value": "ShipID-32", + "system": "urn:oid:SID-32", + "type": { + "coding": [ + { + "code": "SHIP", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-identifierType" + } + ] + } + } + ], + "type": { + "coding": [ + { + "code": "ASERU", + "display": "Serum", + "system": "http://terminology.hl7.org/CodeSystem/v2-0487" + }, + { + "code": "FUR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0487" + } + ], + "text": "Blood" + }, + "container": [ + { + "additiveCodeableConcept": { + "coding": [ + { + "code": "STUTM", + "display": "Stuart transport medium", + "system": "http://terminology.hl7.org/CodeSystem/v2-0371", + "version": "20" + }, + { + "code": "PHENOL", + "display": "Stool", + "system": "http://terminology.hl7.org/CodeSystem/v2-0371" + } + ] + }, + "type": { + "coding": [ + { + "code": "T-container", + "display": "ContainerType", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/ABC" + } + ] + } + } + ], + "status": "available", + "condition": [ + { + "coding": [ + { + "code": "AUT", + "display": "Autolyzed", + "system": "http://terminology.hl7.org/CodeSystem/v2-0493" + }, + { + "code": "CLOT", + "display": "CLOT", + "system": "http://terminology.hl7.org/CodeSystem/v2-0493" + } + ] + }, + { + "coding": [ + { + "code": "HEM", + "display": "HEM", + "system": "http://terminology.hl7.org/CodeSystem/v2-0493" + } + ] + } + ], + "accessionIdentifier": { + "value": "AI-30", + "type": { + "coding": [ + { + "code": "PI", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Patient internal identifier" + } + ] + }, + "system": "urn:oid:2.16.840.1.114222", + "assigner": { + "reference": "Organization/f210e7e3-f1e7-297a-9d54-9db2d312cb96" + } + }, + "note": [ + { + "text": "This is a specimen resource" + } + ], + "parent": [ + { + "reference": "Specimen/0755f744-dafd-776b-bff7-2d023e54406e" + } + ] + }, + "request": { + "method": "PUT", + "url": "Specimen/ea6d5bd5-5c2e-227c-c792-f3f8eb46691b" + } + }, + { + "fullUrl": "urn:uuid:0755f744-dafd-776b-bff7-2d023e54406e", + "resource": { + "resourceType": "Specimen", + "id": "0755f744-dafd-776b-bff7-2d023e54406e", + "identifier": [ + { + "value": "PAI12", + "type": { + "coding": [ + { + "code": "PGN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Specimen/0755f744-dafd-776b-bff7-2d023e54406e" + } + }, + { + "fullUrl": "urn:uuid:f210e7e3-f1e7-297a-9d54-9db2d312cb96", + "resource": { + "resourceType": "Organization", + "id": "f210e7e3-f1e7-297a-9d54-9db2d312cb96", + "identifier": [ + { + "value": "IA PHIMS Stage", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-IA-PHIMS-Stage" + }, + { + "value": "urn:oid:2.16.840.1.114222", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f210e7e3-f1e7-297a-9d54-9db2d312cb96" + } + }, + { + "fullUrl": "urn:uuid:322ca8cf-e43e-973c-3149-9e499675ddca", + "resource": { + "resourceType": "Organization", + "id": "322ca8cf-e43e-973c-3149-9e499675ddca", + "identifier": [ + { + "value": "IPHIMS Stage", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-IPHIMS-Stage" + }, + { + "value": "urn:uuid:2.16.840.1.114222", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "GUID", + "display": "Same as UUID.", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/322ca8cf-e43e-973c-3149-9e499675ddca" + } + }, + { + "fullUrl": "urn:uuid:257786a3-0c2e-44c7-69ea-3456e7152e68", + "resource": { + "resourceType": "DiagnosticReport", + "id": "257786a3-0c2e-44c7-69ea-3456e7152e68", + "code": { + "coding": [ + { + "code": "1063-7", + "display": "Serum or Plasma", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/XYZ", + "version": "2.33" + } + ], + "text": "result1" + }, + "status": "unknown", + "presentedForm": [ + { + "contentType": "image/pict", + "url": "https://testurl.com" + } + ], + "subject": { + "reference": "Patient/389b3d01-dc6f-2c15-38c5-8c4e86a515c8" + }, + "specimen": [ + { + "reference": "Specimen/ea6d5bd5-5c2e-227c-c792-f3f8eb46691b" + } + ] + }, + "request": { + "method": "PUT", + "url": "DiagnosticReport/257786a3-0c2e-44c7-69ea-3456e7152e68" + } + }, + { + "fullUrl": "urn:uuid:9d7eed34-b8fe-1a79-d3da-092a4d5f8775", + "resource": { + "resourceType": "Observation", + "id": "9d7eed34-b8fe-1a79-d3da-092a4d5f8775", + "status": "unknown", + "code": { + "coding": [ + { + "code": "8867-4", + "display": "Bacteria identified", + "system": "http://loinc.org", + "version": "2.33" + } + ], + "text": "result1" + }, + "component": [ + { + "code": { + "coding": [ + { + "code": "8867-4", + "display": "Bacteria identified", + "system": "http://loinc.org", + "version": "2.33" + } + ], + "text": "result1" + }, + "valueQuantity": { + "value": 27 + } + }, + { + "code": { + "coding": [ + { + "code": "8867-4", + "display": "Bacteria identified", + "system": "http://loinc.org", + "version": "2.33" + } + ], + "text": "result1" + }, + "valueQuantity": { + "value": 25 + } + } + ], + "subject": { + "reference": "Patient/389b3d01-dc6f-2c15-38c5-8c4e86a515c8" + }, + "specimen": { + "reference": "Specimen/ea6d5bd5-5c2e-227c-c792-f3f8eb46691b" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "I", + "display": "In Process", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "In Process" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/9d7eed34-b8fe-1a79-d3da-092a4d5f8775" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORU_R01/ORU-R01-RMGEAD-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORU_R01/ORU-R01-RMGEAD-expected.json index 84516178e..b38b0f206 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORU_R01/ORU-R01-RMGEAD-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/ORU_R01/ORU-R01-RMGEAD-expected.json @@ -5,6 +5,7 @@ "identifier": { "value": "CNTRL-3456" }, + "id": "f4c2fce1-9221-9f62-2d08-4a865f73b29c", "entry": [ { "fullUrl": "urn:uuid:59137ac2-b595-49c0-863e-df25b62bf2cd", @@ -60,6 +61,84 @@ "url": "MessageHeader/59137ac2-b595-49c0-863e-df25b62bf2cd" } }, + { + "fullUrl": "urn:uuid:1af3c547-cdab-c300-08bf-cc3836b6381a", + "resource": { + "resourceType": "Provenance", + "id": "1af3c547-cdab-c300-08bf-cc3836b6381a", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:50:13.765Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ORU_R01.

" + }, + "occurredDateTime": "2002-02-15T09:30:00", + "recorded": "2002-02-15T09:30:00", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/6ab73577-5e9f-5084-a3aa-5402773d5fbd" + } + } + ], + "activity": { + "coding": [ + { + "display": "ORU^R01^" + } + ] + }, + "target": [ + { + "reference": "Bundle/f4c2fce1-9221-9f62-2d08-4a865f73b29c" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/1af3c547-cdab-c300-08bf-cc3836b6381a" + } + }, + { + "fullUrl": "urn:uuid:6ab73577-5e9f-5084-a3aa-5402773d5fbd", + "resource": { + "resourceType": "Organization", + "id": "6ab73577-5e9f-5084-a3aa-5402773d5fbd", + "identifier": [ + { + "value": "ELAB-3", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-ELAB-3" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/6ab73577-5e9f-5084-a3aa-5402773d5fbd" + } + }, + { + "fullUrl": "urn:uuid:fe717593-882d-d154-271e-e93d5b114a0d", + "resource": { + "resourceType": "Organization", + "id": "fe717593-882d-d154-271e-e93d5b114a0d", + "identifier": [ + { + "value": "BLDG4", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-BLDG4" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/fe717593-882d-d154-271e-e93d5b114a0d" + } + }, { "fullUrl": "urn:uuid:92bee074-a5c5-3c79-1905-2ed380528150", "resource": { @@ -129,131 +208,231 @@ } }, { - "fullUrl": "urn:uuid:", + "fullUrl": "urn:uuid:4af7a7fb-e594-e5b3-43b9-969188e0c692", "resource": { - "resourceType": "Practitioner" + "resourceType": "Account", + "id": "4af7a7fb-e594-e5b3-43b9-969188e0c692", + "identifier": [ + { + "value": "AC555444444" + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/92bee074-a5c5-3c79-1905-2ed380528150" + } + ] }, "request": { "method": "PUT", - "url": "Practitioner/" + "url": "Account/4af7a7fb-e594-e5b3-43b9-969188e0c692" } }, { - "fullUrl": "urn:uuid:", + "fullUrl": "urn:uuid:209c8566-dafa-22b6-31f6-e4c00e649c61", "resource": { - "resourceType": "Location" + "resourceType": "Observation", + "id": "209c8566-dafa-22b6-31f6-e4c00e649c61", + "status": "final", + "code": { + "coding": [ + { + "code": "1554-5", + "display": "GLUCOSE", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/POST-12H-CFST:MCNC:PT:SER/PLAS:QN" + } + ] + }, + "valueQuantity": { + "value": 182, + "unit": "mg/dl" + }, + "referenceRange": [ + { + "text": "70_105" + } + ], + "interpretation": [ + { + "coding": [ + { + "code": "H", + "display": "High", + "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation" + } + ] + } + ], + "subject": { + "reference": "Patient/92bee074-a5c5-3c79-1905-2ed380528150" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/0cb8d4a6-2451-4d5c-b48f-1f7ca62b5369" + } + ] }, "request": { "method": "PUT", - "url": "Location/" + "url": "Observation/209c8566-dafa-22b6-31f6-e4c00e649c61" } }, { - "fullUrl": "urn:uuid:98cfa049-8565-6edd-d53e-b98ee8bcf59d", + "fullUrl": "urn:uuid:0cb8d4a6-2451-4d5c-b48f-1f7ca62b5369", "resource": { - "resourceType": "Provenance", - "id": "98cfa049-8565-6edd-d53e-b98ee8bcf59d", - "text": { - "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T13:59:56.336Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: ORU_R01.

" - }, - "occurredDateTime": "2002-02-15T09:30:00", - "recorded": "2002-02-15T09:30:00", - "agent": [ + "resourceType": "ServiceRequest", + "id": "0cb8d4a6-2451-4d5c-b48f-1f7ca62b5369", + "status": "active", + "intent": "filler-order", + "identifier": [ { + "value": "845439", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHH-OE", "type": { "coding": [ { - "code": "author", - "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "1045813", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHH-LAB", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" } ] - }, - "who": { - "reference": "Organization/6ab73577-5e9f-5084-a3aa-5402773d5fbd" } } ], - "activity": { + "code": { "coding": [ { - "display": "ORU^R01^" + "code": "15545", + "display": "GLUCOSE" } ] }, - "target": [ + "reasonCode": [ { - "reference": "Bundle/" + "coding": [ + { + "code": "444-44-4444", + "display": "HIPPOCRATES", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/HOWARD-H", + "version": "MD" + } + ] + } + ], + "subject": { + "reference": "Patient/92bee074-a5c5-3c79-1905-2ed380528150" + }, + "requester": { + "reference": "PractitionerRole/4fe9acb3-89ca-75f6-471d-59fdad148a9d" + }, + "specimen": [ + { + "reference": "Specimen/03cf7725-1dd2-d3e3-65da-f7aa7b36e632" } ] }, "request": { "method": "PUT", - "url": "Provenance/98cfa049-8565-6edd-d53e-b98ee8bcf59d" + "url": "ServiceRequest/0cb8d4a6-2451-4d5c-b48f-1f7ca62b5369" } }, { - "fullUrl": "urn:uuid:4af7a7fb-e594-e5b3-43b9-969188e0c692", + "fullUrl": "urn:uuid:cb12815d-2663-5dcf-5f10-0f9e57083be1", "resource": { - "resourceType": "Account", - "id": "4af7a7fb-e594-e5b3-43b9-969188e0c692", + "resourceType": "Practitioner", + "id": "cb12815d-2663-5dcf-5f10-0f9e57083be1", "identifier": [ { - "value": "AC555444444" + "value": "555-55-5555" } ], - "status": "active", - "subject": [ + "name": [ { - "reference": "Patient/92bee074-a5c5-3c79-1905-2ed380528150" + "family": "PRIMARY", + "given": [ + "PATRICIA P" + ], + "suffix": [ + "MD" + ] } ] }, "request": { "method": "PUT", - "url": "Account/4af7a7fb-e594-e5b3-43b9-969188e0c692" + "url": "Practitioner/cb12815d-2663-5dcf-5f10-0f9e57083be1" } }, { - "fullUrl": "urn:uuid:", + "fullUrl": "urn:uuid:4fe9acb3-89ca-75f6-471d-59fdad148a9d", "resource": { - "resourceType": "Encounter", - "text": { - "status": "generated", - "div": "

Visit Description:

" - }, - "subject": { - "reference": "Patient/92bee074-a5c5-3c79-1905-2ed380528150" + "resourceType": "PractitionerRole", + "id": "4fe9acb3-89ca-75f6-471d-59fdad148a9d", + "practitioner": { + "reference": "Practitioner/cb12815d-2663-5dcf-5f10-0f9e57083be1" } }, "request": { "method": "PUT", - "url": "Encounter/" + "url": "PractitionerRole/4fe9acb3-89ca-75f6-471d-59fdad148a9d" } }, { - "fullUrl": "urn:uuid:0ca81c8f-6cb0-10b0-91e8-7528b98f5691", + "fullUrl": "urn:uuid:3c202c0c-e3eb-2262-23c1-e1f328a0bbe4", "resource": { "resourceType": "DiagnosticReport", - "id": "0ca81c8f-6cb0-10b0-91e8-7528b98f5691", + "id": "3c202c0c-e3eb-2262-23c1-e1f328a0bbe4", "identifier": [ { + "value": "845439", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHH-OE", "type": { "coding": [ { - "code": "FILL", + "code": "PLAC", "system": "http://terminology.hl7.org/CodeSystem/v2-0203" } ] } }, - { - "value": "845439", - "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHH OE" - }, { "value": "1045813", - "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHH LAB" + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHH-LAB", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } } ], "effectiveDateTime": "2002-02-15T07:30:00", @@ -266,6 +445,19 @@ ] }, "status": "final", + "subject": { + "reference": "Patient/92bee074-a5c5-3c79-1905-2ed380528150" + }, + "basedOn": [ + { + "reference": "ServiceRequest/0cb8d4a6-2451-4d5c-b48f-1f7ca62b5369" + } + ], + "specimen": [ + { + "reference": "Specimen/03cf7725-1dd2-d3e3-65da-f7aa7b36e632" + } + ], "result": [ { "reference": "Observation/209c8566-dafa-22b6-31f6-e4c00e649c61" @@ -274,48 +466,47 @@ }, "request": { "method": "PUT", - "url": "DiagnosticReport/0ca81c8f-6cb0-10b0-91e8-7528b98f5691" + "url": "DiagnosticReport/3c202c0c-e3eb-2262-23c1-e1f328a0bbe4" } }, { - "fullUrl": "urn:uuid:209c8566-dafa-22b6-31f6-e4c00e649c61", + "fullUrl": "urn:uuid:03cf7725-1dd2-d3e3-65da-f7aa7b36e632", "resource": { - "resourceType": "Observation", - "id": "209c8566-dafa-22b6-31f6-e4c00e649c61", - "status": "final", - "code": { - "coding": [ - { - "code": "1554-5", - "display": "GLUCOSE", - "system": "http://example.com/v2-to-fhir-converter/CodeSystem/POST 12H CFST:MCNC:PT:SER/PLAS:QN" - } - ] - }, - "valueQuantity": { - "value": 182, - "unit": "mg/dl" + "resourceType": "Specimen", + "id": "03cf7725-1dd2-d3e3-65da-f7aa7b36e632", + "collection": { + "collectedDateTime": "2002-02-15T07:30:00" }, - "referenceRange": [ + "identifier": [ { - "text": "70_105" - } - ], - "interpretation": [ + "value": "845439", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHH-OE", + "type": { + "coding": [ + { + "code": "PLAC", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, { - "coding": [ - { - "code": "H", - "display": "High", - "system": "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation" - } - ] + "value": "1045813", + "system": "http://example.com/v2-to-fhir-converter/local-entity-identifier-GHH-LAB", + "type": { + "coding": [ + { + "code": "FILL", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } } ] }, "request": { "method": "PUT", - "url": "Observation/209c8566-dafa-22b6-31f6-e4c00e649c61" + "url": "Specimen/03cf7725-1dd2-d3e3-65da-f7aa7b36e632" } } ] diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S12/SIU-S12-01-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S12/SIU-S12-01-expected.json new file mode 100644 index 000000000..006c08e55 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S12/SIU-S12-01-expected.json @@ -0,0 +1,2077 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2021-09-14T14:35:00+05:30", + "identifier": { + "value": "MSG00012" + }, + "id": "40a1916e-f6ff-36b1-dc5f-f94ad8ccb715", + "entry": [ + { + "fullUrl": "urn:uuid:84fede5c-45a5-87f6-e613-122c708147b1", + "resource": { + "resourceType": "MessageHeader", + "id": "84fede5c-45a5-87f6-e613-122c708147b1", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "S12", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "SIU^S12^SIU_S12" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/84fede5c-45a5-87f6-e613-122c708147b1" + } + }, + { + "fullUrl": "urn:uuid:09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "resource": { + "resourceType": "Provenance", + "id": "09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:39:05.598Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: SIU_S12.

" + }, + "occurredDateTime": "2021-09-14T14:35:00+05:30", + "recorded": "2021-09-14T14:35:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "SIU^S12^SIU_S12" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/12428005-5692-7537-f572-e47a16418f26" + } + } + ], + "target": [ + { + "reference": "Bundle/40a1916e-f6ff-36b1-dc5f-f94ad8ccb715" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/09e54df1-8856-96ca-cdbf-4bdbd94a26a3" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:12428005-5692-7537-f572-e47a16418f26", + "resource": { + "resourceType": "Device", + "id": "12428005-5692-7537-f572-e47a16418f26", + "identifier": [ + { + "value": "SCHApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/12428005-5692-7537-f572-e47a16418f26" + } + }, + { + "fullUrl": "urn:uuid:b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "resource": { + "resourceType": "Appointment", + "id": "b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "identifier": [ + { + "value": "12345", + "type": { + "coding": [ + { + "code": "PLAC", + "display": "Placer Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "36996", + "type": { + "coding": [ + { + "code": "FILL", + "display": "Filler Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "appointmentType": { + "coding": [ + { + "code": "EMERGENCY", + "display": "Emergency appointment", + "system": "http://terminology.hl7.org/CodeSystem/v2-0276" + } + ] + }, + "priority": 2, + "start": "2021-09-24T12:45:00+05:30", + "end": "2021-09-24T13:35:00+05:30", + "minutesDuration": 1, + "status": "booked", + "supportingInformation": [ + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + ], + "comment": "Appointment booked for emergency procedure", + "participant": [ + { + "actor": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "status": "accepted" + }, + { + "actor": { + "reference": "Device/0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00" + }, + "type": [ + { + "coding": [ + { + "code": "101", + "display": "Equipment", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "period": { + "start": "2021-09-24T12:45:00+05:30" + }, + "status": "accepted" + }, + { + "actor": { + "reference": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + }, + "period": { + "start": "2021-09-24T12:45:00+05:30" + }, + "status": "accepted" + }, + { + "actor": { + "reference": "Practitioner/cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb" + }, + "type": [ + { + "coding": [ + { + "code": "010", + "display": "Gastroenterologist", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "period": { + "start": "2021-09-24T12:45:00+05:30" + }, + "status": "accepted" + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/377d8e6d-3ee4-7509-6f8b-6279da04eb6b" + } + ] + }, + "request": { + "method": "PUT", + "url": "Appointment/b7121f46-cf50-5cec-7cfb-5de8e42b82d2" + } + }, + { + "fullUrl": "urn:uuid:df03b003-6818-1abd-209e-0889025aad16", + "resource": { + "resourceType": "Organization", + "id": "df03b003-6818-1abd-209e-0889025aad16", + "identifier": [ + { + "value": "NPIID", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NPIID" + }, + { + "value": "urn:oid:2.16.840.1.113883.4.6", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/df03b003-6818-1abd-209e-0889025aad16" + } + }, + { + "fullUrl": "urn:uuid:6f540060-4f9a-5d13-45b3-da6a76e207a7", + "resource": { + "resourceType": "Practitioner", + "id": "6f540060-4f9a-5d13-45b3-da6a76e207a7", + "address": [ + { + "line": [ + "115 MAINSTREET" + ], + "city": "GOODTOWN", + "state": "KY", + "postalCode": "42010", + "country": "USA" + } + ], + "telecom": [ + { + "value": "(608)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9941339109", + "system": "urn:oid:2.16.840.1.113883.4.6", + "assigner": { + "reference": "Organization/df03b003-6818-1abd-209e-0889025aad16" + }, + "type": { + "coding": [ + { + "code": "NPI", + "display": "National provider identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Smith", + "given": [ + "Adam", + "Mellie" + ], + "suffix": [ + "Jr", + "MD", + "GP" + ], + "prefix": [ + "Dr" + ], + "use": "official", + "period": { + "start": "2010-01-15", + "end": "2020-01-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + { + "fullUrl": "urn:uuid:36effb10-f605-f388-c06c-90d22b315bd0", + "resource": { + "resourceType": "PractitionerRole", + "id": "36effb10-f605-f388-c06c-90d22b315bd0", + "code": [ + { + "coding": [ + { + "code": "placer-contact", + "display": "Placer Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + }, + { + "coding": [ + { + "code": "filler-contact", + "display": "Filler Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + ], + "practitioner": { + "reference": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + } + }, + { + "fullUrl": "urn:uuid:92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "resource": { + "resourceType": "Location", + "id": "92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "name": "FACILITY2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + }, + { + "fullUrl": "urn:uuid:4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "resource": { + "resourceType": "Location", + "id": "4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "partOf": { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + }, + "name": "BUILDING2", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + } + }, + { + "fullUrl": "urn:uuid:81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "resource": { + "resourceType": "Location", + "id": "81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf" + } + }, + { + "fullUrl": "urn:uuid:fb95e0b1-227c-8068-3e51-86c2df312f25", + "resource": { + "resourceType": "Practitioner", + "id": "fb95e0b1-227c-8068-3e51-86c2df312f25", + "telecom": [ + { + "value": "(610)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9" + } + ], + "name": [ + { + "family": "DENT", + "given": [ + "COREY" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + { + "fullUrl": "urn:uuid:f3c93626-c639-1507-76f0-945d762c11a8", + "resource": { + "resourceType": "PractitionerRole", + "id": "f3c93626-c639-1507-76f0-945d762c11a8", + "code": [ + { + "coding": [ + { + "code": "enterer", + "display": "Enterer", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + ], + "practitioner": { + "reference": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + }, + { + "fullUrl": "urn:uuid:5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "resource": { + "resourceType": "Location", + "id": "5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "name": "FACILITY3", + "identifier": [ + { + "value": "urn:oid:1.23", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:d00df304-17fa-8d9a-bd02-3276b1781ea1", + "resource": { + "resourceType": "Practitioner", + "id": "d00df304-17fa-8d9a-bd02-3276b1781ea1", + "identifier": [ + { + "value": "0210" + } + ], + "name": [ + { + "family": "ATTEND", + "given": [ + "AARON", + "A" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/d00df304-17fa-8d9a-bd02-3276b1781ea1" + } + }, + { + "fullUrl": "urn:uuid:21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9", + "resource": { + "resourceType": "Practitioner", + "id": "21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9", + "identifier": [ + { + "value": "0310" + } + ], + "name": [ + { + "family": "REFER", + "given": [ + "LINDA", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9" + } + }, + { + "fullUrl": "urn:uuid:6c138e7c-e841-af07-8948-d01692bd2739", + "resource": { + "resourceType": "Practitioner", + "id": "6c138e7c-e841-af07-8948-d01692bd2739", + "identifier": [ + { + "value": "03410" + } + ], + "name": [ + { + "family": "ADMIT", + "given": [ + "LINDA", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/6c138e7c-e841-af07-8948-d01692bd2739" + } + }, + { + "fullUrl": "urn:uuid:b13417bd-d0fb-e50f-b65a-cd07396a0608", + "resource": { + "resourceType": "Location", + "id": "b13417bd-d0fb-e50f-b65a-cd07396a0608", + "name": "055", + "mode": "instance", + "description": "055--Room01--GH Clinic", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "type": [ + { + "coding": [ + { + "code": "C", + "display": "Clinic", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + } + ] + } + ], + "alias": [ + "Location ready and disinfected before procedure" + ] + }, + "request": { + "method": "PUT", + "url": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + } + }, + { + "fullUrl": "urn:uuid:ee586d80-706a-5933-8500-a8026c48fb27", + "resource": { + "resourceType": "Location", + "id": "ee586d80-706a-5933-8500-a8026c48fb27", + "partOf": { + "reference": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + }, + "name": "Room01", + "mode": "instance", + "description": "055--Room01--GH Clinic", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "type": [ + { + "coding": [ + { + "code": "C", + "display": "Clinic", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + } + ] + } + ], + "alias": [ + "Location ready and disinfected before procedure" + ] + }, + "request": { + "method": "PUT", + "url": "Location/ee586d80-706a-5933-8500-a8026c48fb27" + } + }, + { + "fullUrl": "urn:uuid:4b6f7358-191b-8623-f2f4-806a8a0babcf", + "resource": { + "resourceType": "Location", + "id": "4b6f7358-191b-8623-f2f4-806a8a0babcf", + "name": "GH Clinic", + "mode": "instance", + "description": "055--Room01--GH Clinic", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + }, + "type": [ + { + "coding": [ + { + "code": "C", + "display": "Clinic", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + } + ] + } + ], + "alias": [ + "Location ready and disinfected before procedure" + ] + }, + "request": { + "method": "PUT", + "url": "Location/4b6f7358-191b-8623-f2f4-806a8a0babcf" + } + }, + { + "fullUrl": "urn:uuid:919b83dc-2853-4a8d-c96a-bdecb51f1fcc", + "resource": { + "resourceType": "Location", + "id": "919b83dc-2853-4a8d-c96a-bdecb51f1fcc", + "name": "GENOPD", + "mode": "instance", + "description": "GENOPD--ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--FACILITY1--BUILDING1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/919b83dc-2853-4a8d-c96a-bdecb51f1fcc" + } + }, + { + "fullUrl": "urn:uuid:c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "resource": { + "resourceType": "Location", + "id": "c7f1b9ec-ffd8-321e-ad87-abafc1c1a333", + "partOf": { + "reference": "Location/919b83dc-2853-4a8d-c96a-bdecb51f1fcc" + }, + "name": "ROOM1", + "identifier": [ + { + "value": "urn:oid:2.16.840.1.113883.4.642.1.1108", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "GENOPD--ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--FACILITY1--BUILDING1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/c7f1b9ec-ffd8-321e-ad87-abafc1c1a333" + } + }, + { + "fullUrl": "urn:uuid:4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "resource": { + "resourceType": "Location", + "id": "4bca6ba2-be65-ef37-3911-03b70a00a3a6", + "name": "FACILITY1", + "mode": "instance", + "description": "GENOPD--ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--FACILITY1--BUILDING1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + } + }, + { + "fullUrl": "urn:uuid:3b0911cb-4361-cd8d-b188-463af033c699", + "resource": { + "resourceType": "Location", + "id": "3b0911cb-4361-cd8d-b188-463af033c699", + "partOf": { + "reference": "Location/4bca6ba2-be65-ef37-3911-03b70a00a3a6" + }, + "name": "BUILDING1", + "mode": "instance", + "description": "GENOPD--ROOM1--2.16.840.1.113883.4.642.1.1108--ISO--FACILITY1--BUILDING1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/3b0911cb-4361-cd8d-b188-463af033c699" + } + }, + { + "fullUrl": "urn:uuid:da6f322f-ef5e-4f2c-c1f8-6e38dffbf995", + "resource": { + "resourceType": "Encounter", + "id": "da6f322f-ef5e-4f2c-c1f8-6e38dffbf995", + "class": { + "code": "AMB", + "display": "ambulatory", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode" + }, + "status": "in-progress", + "location": [ + { + "status": "active", + "location": { + "reference": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + } + }, + { + "status": "completed", + "location": { + "reference": "Location/919b83dc-2853-4a8d-c96a-bdecb51f1fcc" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/uv/v2mappings/StructureDefinition/temporary-location", + "valueBoolean": false + } + ] + } + ], + "participant": [ + { + "type": [ + { + "coding": [ + { + "code": "ATND", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType", + "display": "attender" + } + ] + } + ], + "individual": { + "reference": "Practitioner/d00df304-17fa-8d9a-bd02-3276b1781ea1" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "REF", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "referrer" + } + ], + "individual": { + "reference": "Practitioner/21d5ab8b-8f3d-4fd9-f1c4-6f32568b0ae9" + } + }, + { + "type": [ + { + "coding": [ + { + "code": "ADM", + "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType" + } + ], + "text": "admitter" + } + ], + "individual": { + "reference": "Practitioner/6c138e7c-e841-af07-8948-d01692bd2739" + } + } + ], + "identifier": [ + { + "value": "5001", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ], + "text": "visit number" + } + } + ], + "period": { + "start": "2021-01-15T19:15:10+05:30" + }, + "reasonCode": [ + { + "coding": [ + { + "code": "116290004", + "display": "Acute abdominal pain", + "system": "http://snomed.info/sct" + } + ] + } + ], + "text": { + "status": "generated", + "div": "

Visit Description:

" + }, + "priority": { + "coding": [ + { + "code": "UR", + "display": "urgent", + "system": "http://terminology.hl7.org/CodeSystem/v3-ActPriority" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/encounter-modeOfArrival", + "valueCoding": { + "code": "A", + "display": "Ambulance", + "system": "http://terminology.hl7.org/CodeSystem/v2-0430" + } + } + ], + "diagnosis": [ + { + "condition": { + "reference": "Condition/ac4c8e5d-ba4c-33b6-28f4-2f60bf978cfb" + }, + "use": { + "coding": [ + { + "code": "AD", + "display": "Admission Diagnosis", + "system": "http://terminology.hl7.org/CodeSystem/diagnosis-role" + } + ] + }, + "rank": 1 + } + ] + }, + "request": { + "method": "PUT", + "url": "Encounter/da6f322f-ef5e-4f2c-c1f8-6e38dffbf995" + } + }, + { + "fullUrl": "urn:uuid:e82402a9-b2d1-2a28-3250-c099d5a77bf7", + "resource": { + "resourceType": "Organization", + "id": "e82402a9-b2d1-2a28-3250-c099d5a77bf7", + "identifier": [ + { + "value": "PERSt", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-PERSt" + }, + { + "value": "1.23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/e82402a9-b2d1-2a28-3250-c099d5a77bf7" + } + }, + { + "fullUrl": "urn:uuid:ce70e6c3-c190-121d-c251-e4bae5cde6a1", + "resource": { + "resourceType": "Practitioner", + "id": "ce70e6c3-c190-121d-c251-e4bae5cde6a1", + "identifier": [ + { + "value": "1134", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/e82402a9-b2d1-2a28-3250-c099d5a77bf7" + }, + "type": { + "coding": [ + { + "code": "BR", + "display": "Birth registry number", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Aly", + "given": [ + "Zafar", + "Mahendra" + ], + "suffix": [ + "JR", + "MD", + "Al" + ], + "prefix": [ + "Dr." + ], + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/ce70e6c3-c190-121d-c251-e4bae5cde6a1" + } + }, + { + "fullUrl": "urn:uuid:88a53755-c972-6904-b4ce-8884b84ddc2e", + "resource": { + "resourceType": "PractitionerRole", + "id": "88a53755-c972-6904-b4ce-8884b84ddc2e", + "code": [ + { + "coding": [ + { + "code": "ResponsibleObserver", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/ce70e6c3-c190-121d-c251-e4bae5cde6a1" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/88a53755-c972-6904-b4ce-8884b84ddc2e" + } + }, + { + "fullUrl": "urn:uuid:3e0952c6-eea0-8938-96f8-07c224bf1577", + "resource": { + "resourceType": "Practitioner", + "id": "3e0952c6-eea0-8938-96f8-07c224bf1577", + "identifier": [ + { + "value": "2234" + } + ], + "name": [ + { + "family": "Pauly", + "given": [ + "Berrie", + "Raud" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/3e0952c6-eea0-8938-96f8-07c224bf1577" + } + }, + { + "fullUrl": "urn:uuid:bc78e290-ec67-c238-1e05-aefb6b252b0c", + "resource": { + "resourceType": "PractitionerRole", + "id": "bc78e290-ec67-c238-1e05-aefb6b252b0c", + "code": [ + { + "coding": [ + { + "code": "ResponsibleObserver", + "system": "http://example.com/v2-to-fhir-converter/PractitionerRole" + } + ] + } + ], + "practitioner": { + "reference": "Practitioner/3e0952c6-eea0-8938-96f8-07c224bf1577" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/bc78e290-ec67-c238-1e05-aefb6b252b0c" + } + }, + { + "fullUrl": "urn:uuid:053a101a-4c1b-a99a-7a2b-2adf7dd1b55e", + "resource": { + "resourceType": "Observation", + "id": "053a101a-4c1b-a99a-7a2b-2adf7dd1b55e", + "status": "final", + "code": { + "coding": [ + { + "code": "8867-4", + "display": "Heart rate", + "system": "http://loinc.org" + } + ] + }, + "valueQuantity": { + "value": 72, + "code": "beats/min", + "unit": "beats/min", + "system": "urn:iso:std:iso:3986" + }, + "referenceRange": [ + { + "text": "60-120" + } + ], + "effectiveDateTime": "2021-09-14", + "performer": [ + { + "reference": "PractitionerRole/88a53755-c972-6904-b4ce-8884b84ddc2e" + }, + { + "reference": "PractitionerRole/bc78e290-ec67-c238-1e05-aefb6b252b0c" + } + ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://example.com/v2-to-fhir-converter/Observation_Status", + "valueCodeableConcept": { + "coding": [ + { + "code": "F", + "display": "Final", + "system": "http://terminology.hl7.org/CodeSystem/v2-0085" + } + ], + "text": "Final" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Observation/053a101a-4c1b-a99a-7a2b-2adf7dd1b55e" + } + }, + { + "fullUrl": "urn:uuid:14493a95-7780-ead5-89cc-ad6c3bc31d51", + "resource": { + "resourceType": "Practitioner", + "id": "14493a95-7780-ead5-89cc-ad6c3bc31d51", + "identifier": [ + { + "value": "005454" + } + ], + "name": [ + { + "family": "DIAG", + "given": [ + "ROBIN", + "B" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/14493a95-7780-ead5-89cc-ad6c3bc31d51" + } + }, + { + "fullUrl": "urn:uuid:ac4c8e5d-ba4c-33b6-28f4-2f60bf978cfb", + "resource": { + "resourceType": "Condition", + "id": "ac4c8e5d-ba4c-33b6-28f4-2f60bf978cfb", + "code": { + "coding": [ + { + "code": "64766004", + "display": "Ulcerative colitis(disorder)", + "system": "http://snomed.info/sct" + } + ], + "text": "Ulcerative Colitis" + }, + "onsetDateTime": "2021-08-25T12:50:25+05:30", + "identifier": [ + { + "value": "DI20", + "system": "urn:oid:DTUI", + "type": { + "coding": [ + { + "code": "CLIP", + "display": "Clinical laboratory Improvement Program. Allows for the ability to designate organization identifier as a “CLIP” assigned number (for labs). Used by US Department of Defense.", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "asserter": { + "reference": "Practitioner/14493a95-7780-ead5-89cc-ad6c3bc31d51" + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/condition-assertedDate", + "valueDateTime": "2020-05-01T16:45:15+05:30" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/condition-dueTo", + "valueReference": { + "reference": "Condition/98e2ecfc-6e04-bc30-6624-4f3686214b22" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Condition/ac4c8e5d-ba4c-33b6-28f4-2f60bf978cfb" + } + }, + { + "fullUrl": "urn:uuid:98e2ecfc-6e04-bc30-6624-4f3686214b22", + "resource": { + "resourceType": "Condition", + "id": "98e2ecfc-6e04-bc30-6624-4f3686214b22", + "identifier": [ + { + "system": "urn:oid:UI", + "type": { + "coding": [ + { + "code": "CLIP", + "display": "Clinical laboratory Improvement Program. Allows for the ability to designate organization identifier as a “CLIP” assigned number (for labs). Used by US Department of Defense.", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "Condition/98e2ecfc-6e04-bc30-6624-4f3686214b22" + } + }, + { + "fullUrl": "urn:uuid:377d8e6d-3ee4-7509-6f8b-6279da04eb6b", + "resource": { + "resourceType": "ServiceRequest", + "id": "377d8e6d-3ee4-7509-6f8b-6279da04eb6b", + "status": "active", + "intent": "filler-order", + "orderDetail": [ + { + "coding": [ + { + "code": "5001", + "display": "EVIS X12 Video Colonoscope", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + }, + { + "coding": [ + { + "code": "5001", + "display": "EVIS X12 Video Colonoscope", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "occurrencePeriod": { + "start": "2021-09-24T12:45:00+05:30" + }, + "code": { + "coding": [ + { + "code": "76164006", + "display": "Biopsy of colon (procedure)", + "system": "http://snomed.info/sct" + }, + { + "code": "1212", + "display": "Biopsy" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "encounter": { + "reference": "Encounter/da6f322f-ef5e-4f2c-c1f8-6e38dffbf995" + }, + "note": [ + { + "text": "Nursing staff instructions - Patient bowel preparation for the procedure" + }, + { + "text": "Patient instructions - light meal or liquid diet a day before procedure" + } + ], + "performer": [ + { + "reference": "Device/0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00" + }, + { + "reference": "Practitioner/cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb" + } + ], + "locationReference": [ + { + "reference": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/377d8e6d-3ee4-7509-6f8b-6279da04eb6b" + } + }, + { + "fullUrl": "urn:uuid:0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00", + "resource": { + "resourceType": "Device", + "id": "0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00", + "identifier": [ + { + "value": "5001", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + }, + { + "value": "5002" + } + ], + "deviceName": [ + { + "name": "EVIS X12 Video Colonoscope", + "type": "model-name" + } + ], + "status": "active", + "note": [ + { + "text": "Check if this particular equipment is available" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00" + } + }, + { + "fullUrl": "urn:uuid:cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb", + "resource": { + "resourceType": "Practitioner", + "id": "cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb", + "identifier": [ + { + "value": "1210" + } + ], + "name": [ + { + "family": "GE", + "given": [ + "Robert", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S12/SIU-S12-02-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S12/SIU-S12-02-expected.json new file mode 100644 index 000000000..1557678d8 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S12/SIU-S12-02-expected.json @@ -0,0 +1,1639 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2021-08-10T14:45:00+05:30", + "identifier": { + "value": "MSG00012" + }, + "id": "40a1916e-f6ff-36b1-dc5f-f94ad8ccb715", + "entry": [ + { + "fullUrl": "urn:uuid:84fede5c-45a5-87f6-e613-122c708147b1", + "resource": { + "resourceType": "MessageHeader", + "id": "84fede5c-45a5-87f6-e613-122c708147b1", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "S12", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "SIU^S12^SIU_S12" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/84fede5c-45a5-87f6-e613-122c708147b1" + } + }, + { + "fullUrl": "urn:uuid:09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "resource": { + "resourceType": "Provenance", + "id": "09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:39:40.333Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: SIU_S12.

" + }, + "occurredDateTime": "2021-08-10T14:45:00+05:30", + "recorded": "2021-08-10T14:45:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "SIU^S12^SIU_S12" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/12428005-5692-7537-f572-e47a16418f26" + } + } + ], + "target": [ + { + "reference": "Bundle/40a1916e-f6ff-36b1-dc5f-f94ad8ccb715" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/09e54df1-8856-96ca-cdbf-4bdbd94a26a3" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:12428005-5692-7537-f572-e47a16418f26", + "resource": { + "resourceType": "Device", + "id": "12428005-5692-7537-f572-e47a16418f26", + "identifier": [ + { + "value": "SCHApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/12428005-5692-7537-f572-e47a16418f26" + } + }, + { + "fullUrl": "urn:uuid:b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "resource": { + "resourceType": "Appointment", + "id": "b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "identifier": [ + { + "value": "12345", + "type": { + "coding": [ + { + "code": "PLAC", + "display": "Placer Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "36996", + "type": { + "coding": [ + { + "code": "FILL", + "display": "Filler Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "appointmentType": { + "coding": [ + { + "code": "CHECKUP", + "display": "A routine check-up, such as an annual physical", + "system": "http://terminology.hl7.org/CodeSystem/v2-0276" + } + ] + }, + "priority": 2, + "start": "2021-08-18T14:45:00+05:30", + "end": "2021-08-18T15:45:00+05:30", + "minutesDuration": 70, + "status": "booked", + "supportingInformation": [ + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + ], + "comment": "Appointment for annual checkup", + "participant": [ + { + "actor": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "status": "accepted" + }, + { + "actor": { + "reference": "Device/dd77839c-6623-a021-29ef-c04fd35460ca" + }, + "type": [ + { + "coding": [ + { + "code": "011", + "display": "Lab Equipment", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + }, + "status": "tentative" + }, + { + "actor": { + "reference": "Practitioner/9d928c63-6d1e-7fb7-fed9-b97b625dc5f8" + }, + "type": [ + { + "coding": [ + { + "code": "019", + "display": "Phlebotomist", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Device/d8709d49-8f55-d198-44e8-2cf5ee983e90" + }, + "type": [ + { + "coding": [ + { + "code": "015", + "display": "Imaging Equipment", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + }, + "status": "tentative" + }, + { + "actor": { + "reference": "Practitioner/89f153f4-91d2-b658-0242-612129d35f06" + }, + "type": [ + { + "coding": [ + { + "code": "021", + "display": "Radiology Technician", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Location/82709fdd-4012-9faa-5ec3-cf75fd57a34c" + }, + "status": "tentative" + }, + { + "actor": { + "reference": "Practitioner/a4177c1c-eb53-edd4-a0ee-1a55b986ea3b" + }, + "type": [ + { + "coding": [ + { + "code": "011", + "display": "General Practitioner", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/8ad3476e-03c9-158e-12d8-20de3070fce5" + }, + { + "reference": "ServiceRequest/2b1743c0-089d-d354-0cbe-e548478fd580" + } + ] + }, + "request": { + "method": "PUT", + "url": "Appointment/b7121f46-cf50-5cec-7cfb-5de8e42b82d2" + } + }, + { + "fullUrl": "urn:uuid:df03b003-6818-1abd-209e-0889025aad16", + "resource": { + "resourceType": "Organization", + "id": "df03b003-6818-1abd-209e-0889025aad16", + "identifier": [ + { + "value": "NPIID", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NPIID" + }, + { + "value": "urn:oid:2.16.840.1.113883.4.6", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/df03b003-6818-1abd-209e-0889025aad16" + } + }, + { + "fullUrl": "urn:uuid:6f540060-4f9a-5d13-45b3-da6a76e207a7", + "resource": { + "resourceType": "Practitioner", + "id": "6f540060-4f9a-5d13-45b3-da6a76e207a7", + "address": [ + { + "line": [ + "115 MAINSTREET" + ], + "city": "GOODTOWN", + "state": "KY", + "postalCode": "42010", + "country": "USA" + } + ], + "telecom": [ + { + "value": "(608)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9941339109", + "system": "urn:oid:2.16.840.1.113883.4.6", + "assigner": { + "reference": "Organization/df03b003-6818-1abd-209e-0889025aad16" + }, + "type": { + "coding": [ + { + "code": "NPI", + "display": "National provider identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Smith", + "given": [ + "Adam", + "Mellie" + ], + "suffix": [ + "Jr", + "MD", + "GP" + ], + "prefix": [ + "Dr" + ], + "use": "official", + "period": { + "start": "2010-01-15", + "end": "2020-01-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + { + "fullUrl": "urn:uuid:36effb10-f605-f388-c06c-90d22b315bd0", + "resource": { + "resourceType": "PractitionerRole", + "id": "36effb10-f605-f388-c06c-90d22b315bd0", + "code": [ + { + "coding": [ + { + "code": "placer-contact", + "display": "Placer Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + }, + { + "coding": [ + { + "code": "filler-contact", + "display": "Filler Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + ], + "practitioner": { + "reference": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + } + }, + { + "fullUrl": "urn:uuid:92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "resource": { + "resourceType": "Location", + "id": "92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "name": "FACILITY2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + }, + { + "fullUrl": "urn:uuid:4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "resource": { + "resourceType": "Location", + "id": "4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "partOf": { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + }, + "name": "BUILDING2", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + } + }, + { + "fullUrl": "urn:uuid:81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "resource": { + "resourceType": "Location", + "id": "81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf" + } + }, + { + "fullUrl": "urn:uuid:fb95e0b1-227c-8068-3e51-86c2df312f25", + "resource": { + "resourceType": "Practitioner", + "id": "fb95e0b1-227c-8068-3e51-86c2df312f25", + "telecom": [ + { + "value": "(610)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9" + } + ], + "name": [ + { + "family": "DENT", + "given": [ + "COREY" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + { + "fullUrl": "urn:uuid:f3c93626-c639-1507-76f0-945d762c11a8", + "resource": { + "resourceType": "PractitionerRole", + "id": "f3c93626-c639-1507-76f0-945d762c11a8", + "code": [ + { + "coding": [ + { + "code": "enterer", + "display": "Enterer", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + ], + "practitioner": { + "reference": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + }, + { + "fullUrl": "urn:uuid:5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "resource": { + "resourceType": "Location", + "id": "5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "name": "FACILITY3", + "identifier": [ + { + "value": "urn:oid:1.23", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:8ad3476e-03c9-158e-12d8-20de3070fce5", + "resource": { + "resourceType": "ServiceRequest", + "id": "8ad3476e-03c9-158e-12d8-20de3070fce5", + "status": "active", + "intent": "filler-order", + "code": { + "coding": [ + { + "code": "58410-2", + "display": "CBC Panel-Blood by Automated Count", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "note": [ + { + "text": "Fasting for Blood sugar before appointment" + } + ], + "performer": [ + { + "reference": "Device/dd77839c-6623-a021-29ef-c04fd35460ca" + }, + { + "reference": "Practitioner/9d928c63-6d1e-7fb7-fed9-b97b625dc5f8" + } + ], + "locationReference": [ + { + "reference": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/8ad3476e-03c9-158e-12d8-20de3070fce5" + } + }, + { + "fullUrl": "urn:uuid:dd77839c-6623-a021-29ef-c04fd35460ca", + "resource": { + "resourceType": "Device", + "id": "dd77839c-6623-a021-29ef-c04fd35460ca", + "identifier": [ + { + "value": "123", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ], + "deviceName": [ + { + "name": "ABC Cell Counter", + "type": "model-name" + } + ], + "note": [ + { + "text": "Equipment booked for lab test" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/dd77839c-6623-a021-29ef-c04fd35460ca" + } + }, + { + "fullUrl": "urn:uuid:bc5a0b18-cce5-ddbc-8e45-a09c736af725", + "resource": { + "resourceType": "Location", + "id": "bc5a0b18-cce5-ddbc-8e45-a09c736af725", + "name": "LabUnit101", + "mode": "instance", + "description": "LabUnit101--Lab Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for lab test" + ] + }, + "request": { + "method": "PUT", + "url": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + } + }, + { + "fullUrl": "urn:uuid:a86368de-48ac-12e3-05e4-6b2da7fa4853", + "resource": { + "resourceType": "Location", + "id": "a86368de-48ac-12e3-05e4-6b2da7fa4853", + "partOf": { + "reference": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + }, + "name": "Lab Room 01", + "mode": "instance", + "description": "LabUnit101--Lab Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for lab test" + ] + }, + "request": { + "method": "PUT", + "url": "Location/a86368de-48ac-12e3-05e4-6b2da7fa4853" + } + }, + { + "fullUrl": "urn:uuid:9d04f983-a391-647a-07a8-e8bf59f77de8", + "resource": { + "resourceType": "Location", + "id": "9d04f983-a391-647a-07a8-e8bf59f77de8", + "name": "GHH Hospital", + "mode": "instance", + "description": "OPD12--Room 55--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + }, + "alias": [ + "Location available for lab test", + "Location available for imaging", + "Location available for checkup" + ] + }, + "request": { + "method": "PUT", + "url": "Location/9d04f983-a391-647a-07a8-e8bf59f77de8" + } + }, + { + "fullUrl": "urn:uuid:9d928c63-6d1e-7fb7-fed9-b97b625dc5f8", + "resource": { + "resourceType": "Practitioner", + "id": "9d928c63-6d1e-7fb7-fed9-b97b625dc5f8", + "identifier": [ + { + "value": "400" + } + ], + "name": [ + { + "family": "PB", + "given": [ + "Tim", + "G" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/9d928c63-6d1e-7fb7-fed9-b97b625dc5f8" + } + }, + { + "fullUrl": "urn:uuid:2b1743c0-089d-d354-0cbe-e548478fd580", + "resource": { + "resourceType": "ServiceRequest", + "id": "2b1743c0-089d-d354-0cbe-e548478fd580", + "status": "active", + "intent": "filler-order", + "code": { + "coding": [ + { + "code": "42272-5", + "display": "XR Chest PA and Lateral", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "note": [ + { + "text": "Patient Instructions - wear loose comfortable clothes,keep metallic objects away and leave jewellery at home" + } + ], + "performer": [ + { + "reference": "Device/d8709d49-8f55-d198-44e8-2cf5ee983e90" + }, + { + "reference": "Practitioner/89f153f4-91d2-b658-0242-612129d35f06" + } + ], + "locationReference": [ + { + "reference": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/2b1743c0-089d-d354-0cbe-e548478fd580" + } + }, + { + "fullUrl": "urn:uuid:d8709d49-8f55-d198-44e8-2cf5ee983e90", + "resource": { + "resourceType": "Device", + "id": "d8709d49-8f55-d198-44e8-2cf5ee983e90", + "identifier": [ + { + "value": "1001", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ], + "deviceName": [ + { + "name": "XYZ X-Ray Machine", + "type": "model-name" + } + ], + "note": [ + { + "text": "Equipment booked for imaging" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/d8709d49-8f55-d198-44e8-2cf5ee983e90" + } + }, + { + "fullUrl": "urn:uuid:2b9be76c-a0f5-72ea-b684-51adaf2d95f6", + "resource": { + "resourceType": "Location", + "id": "2b9be76c-a0f5-72ea-b684-51adaf2d95f6", + "name": "DiagnosticUnit201", + "mode": "instance", + "description": "DiagnosticUnit201--Imaging Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for imaging" + ] + }, + "request": { + "method": "PUT", + "url": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + } + }, + { + "fullUrl": "urn:uuid:e36c1c9d-9008-4267-0e0f-e8b36ec2f208", + "resource": { + "resourceType": "Location", + "id": "e36c1c9d-9008-4267-0e0f-e8b36ec2f208", + "partOf": { + "reference": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + }, + "name": "Imaging Room 01", + "mode": "instance", + "description": "DiagnosticUnit201--Imaging Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for imaging" + ] + }, + "request": { + "method": "PUT", + "url": "Location/e36c1c9d-9008-4267-0e0f-e8b36ec2f208" + } + }, + { + "fullUrl": "urn:uuid:89f153f4-91d2-b658-0242-612129d35f06", + "resource": { + "resourceType": "Practitioner", + "id": "89f153f4-91d2-b658-0242-612129d35f06", + "identifier": [ + { + "value": "500" + } + ], + "name": [ + { + "family": "RT", + "given": [ + "Robert", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/89f153f4-91d2-b658-0242-612129d35f06" + } + }, + { + "fullUrl": "urn:uuid:82709fdd-4012-9faa-5ec3-cf75fd57a34c", + "resource": { + "resourceType": "Location", + "id": "82709fdd-4012-9faa-5ec3-cf75fd57a34c", + "name": "OPD12", + "mode": "instance", + "description": "OPD12--Room 55--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for checkup" + ] + }, + "request": { + "method": "PUT", + "url": "Location/82709fdd-4012-9faa-5ec3-cf75fd57a34c" + } + }, + { + "fullUrl": "urn:uuid:928bc54e-abd5-e128-504a-f02faf5598e6", + "resource": { + "resourceType": "Location", + "id": "928bc54e-abd5-e128-504a-f02faf5598e6", + "partOf": { + "reference": "Location/82709fdd-4012-9faa-5ec3-cf75fd57a34c" + }, + "name": "Room 55", + "mode": "instance", + "description": "OPD12--Room 55--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for checkup" + ] + }, + "request": { + "method": "PUT", + "url": "Location/928bc54e-abd5-e128-504a-f02faf5598e6" + } + }, + { + "fullUrl": "urn:uuid:a4177c1c-eb53-edd4-a0ee-1a55b986ea3b", + "resource": { + "resourceType": "Practitioner", + "id": "a4177c1c-eb53-edd4-a0ee-1a55b986ea3b", + "identifier": [ + { + "value": "600" + } + ], + "name": [ + { + "family": "GP", + "given": [ + "Linda", + "R" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/a4177c1c-eb53-edd4-a0ee-1a55b986ea3b" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S13/SIU-S13-01-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S13/SIU-S13-01-expected.json new file mode 100644 index 000000000..af3fa2275 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S13/SIU-S13-01-expected.json @@ -0,0 +1,1419 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2021-09-20T14:41:00+05:30", + "identifier": { + "value": "MSG00013" + }, + "id": "3fa01fde-f1f9-271b-cd78-622b69fcca15", + "entry": [ + { + "fullUrl": "urn:uuid:6075682b-c1ce-410b-b538-cb7bf0d16c6c", + "resource": { + "resourceType": "MessageHeader", + "id": "6075682b-c1ce-410b-b538-cb7bf0d16c6c", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "S13", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "SIU^S13^SIU_S13" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/6075682b-c1ce-410b-b538-cb7bf0d16c6c" + } + }, + { + "fullUrl": "urn:uuid:09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "resource": { + "resourceType": "Provenance", + "id": "09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:40:21.421Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: SIU_S13.

" + }, + "occurredDateTime": "2021-09-20T14:41:00+05:30", + "recorded": "2021-09-20T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "SIU^S13^SIU_S13" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/12428005-5692-7537-f572-e47a16418f26" + } + } + ], + "target": [ + { + "reference": "Bundle/3fa01fde-f1f9-271b-cd78-622b69fcca15" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/09e54df1-8856-96ca-cdbf-4bdbd94a26a3" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:12428005-5692-7537-f572-e47a16418f26", + "resource": { + "resourceType": "Device", + "id": "12428005-5692-7537-f572-e47a16418f26", + "identifier": [ + { + "value": "SCHApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/12428005-5692-7537-f572-e47a16418f26" + } + }, + { + "fullUrl": "urn:uuid:b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "resource": { + "resourceType": "Appointment", + "id": "b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "identifier": [ + { + "value": "12345", + "type": { + "coding": [ + { + "code": "PLAC", + "display": "Placer Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "36996", + "type": { + "coding": [ + { + "code": "FILL", + "display": "Filler Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "appointmentType": { + "coding": [ + { + "code": "EMERGENCY", + "display": "Emergency appointment", + "system": "http://terminology.hl7.org/CodeSystem/v2-0276" + } + ] + }, + "priority": 2, + "start": "2021-09-24T12:45:00+05:30", + "end": "2021-09-24T13:35:00+05:30", + "minutesDuration": 1, + "status": "booked", + "supportingInformation": [ + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + ], + "participant": [ + { + "actor": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "status": "accepted" + }, + { + "actor": { + "reference": "Device/0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00" + }, + "type": [ + { + "coding": [ + { + "code": "101", + "display": "Equipment", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "period": { + "start": "2021-09-24T12:45:00+05:30" + }, + "status": "accepted" + }, + { + "actor": { + "reference": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + }, + "period": { + "start": "2021-09-24T12:45:00+05:30" + }, + "status": "accepted" + }, + { + "actor": { + "reference": "Practitioner/cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb" + }, + "type": [ + { + "coding": [ + { + "code": "010", + "display": "Gastroenterologist", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "period": { + "start": "2021-09-24T12:45:00+05:30" + }, + "status": "accepted" + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/377d8e6d-3ee4-7509-6f8b-6279da04eb6b" + } + ] + }, + "request": { + "method": "PUT", + "url": "Appointment/b7121f46-cf50-5cec-7cfb-5de8e42b82d2" + } + }, + { + "fullUrl": "urn:uuid:df03b003-6818-1abd-209e-0889025aad16", + "resource": { + "resourceType": "Organization", + "id": "df03b003-6818-1abd-209e-0889025aad16", + "identifier": [ + { + "value": "NPIID", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NPIID" + }, + { + "value": "urn:oid:2.16.840.1.113883.4.6", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/df03b003-6818-1abd-209e-0889025aad16" + } + }, + { + "fullUrl": "urn:uuid:6f540060-4f9a-5d13-45b3-da6a76e207a7", + "resource": { + "resourceType": "Practitioner", + "id": "6f540060-4f9a-5d13-45b3-da6a76e207a7", + "address": [ + { + "line": [ + "115 MAINSTREET" + ], + "city": "GOODTOWN", + "state": "KY", + "postalCode": "42010", + "country": "USA" + } + ], + "telecom": [ + { + "value": "(608)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9941339109", + "system": "urn:oid:2.16.840.1.113883.4.6", + "assigner": { + "reference": "Organization/df03b003-6818-1abd-209e-0889025aad16" + }, + "type": { + "coding": [ + { + "code": "NPI", + "display": "National provider identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Smith", + "given": [ + "Adam", + "Mellie" + ], + "suffix": [ + "Jr", + "MD", + "GP" + ], + "prefix": [ + "Dr" + ], + "use": "official", + "period": { + "start": "2010-01-15", + "end": "2020-01-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + { + "fullUrl": "urn:uuid:36effb10-f605-f388-c06c-90d22b315bd0", + "resource": { + "resourceType": "PractitionerRole", + "id": "36effb10-f605-f388-c06c-90d22b315bd0", + "code": [ + { + "coding": [ + { + "code": "placer-contact", + "display": "Placer Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + }, + { + "coding": [ + { + "code": "filler-contact", + "display": "Filler Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + ], + "practitioner": { + "reference": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + } + }, + { + "fullUrl": "urn:uuid:92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "resource": { + "resourceType": "Location", + "id": "92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "name": "FACILITY2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + }, + { + "fullUrl": "urn:uuid:4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "resource": { + "resourceType": "Location", + "id": "4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "partOf": { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + }, + "name": "BUILDING2", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + } + }, + { + "fullUrl": "urn:uuid:81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "resource": { + "resourceType": "Location", + "id": "81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf" + } + }, + { + "fullUrl": "urn:uuid:fb95e0b1-227c-8068-3e51-86c2df312f25", + "resource": { + "resourceType": "Practitioner", + "id": "fb95e0b1-227c-8068-3e51-86c2df312f25", + "telecom": [ + { + "value": "(610)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9" + } + ], + "name": [ + { + "family": "DENT", + "given": [ + "COREY" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + { + "fullUrl": "urn:uuid:f3c93626-c639-1507-76f0-945d762c11a8", + "resource": { + "resourceType": "PractitionerRole", + "id": "f3c93626-c639-1507-76f0-945d762c11a8", + "code": [ + { + "coding": [ + { + "code": "enterer", + "display": "Enterer", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + ], + "practitioner": { + "reference": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + }, + { + "fullUrl": "urn:uuid:5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "resource": { + "resourceType": "Location", + "id": "5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "name": "FACILITY3", + "identifier": [ + { + "value": "urn:oid:1.23", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:377d8e6d-3ee4-7509-6f8b-6279da04eb6b", + "resource": { + "resourceType": "ServiceRequest", + "id": "377d8e6d-3ee4-7509-6f8b-6279da04eb6b", + "status": "active", + "intent": "filler-order", + "orderDetail": [ + { + "coding": [ + { + "code": "5001", + "display": "EVIS X12 Video Colonoscope", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + }, + { + "coding": [ + { + "code": "5001", + "display": "EVIS X12 Video Colonoscope", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "occurrencePeriod": { + "start": "2021-09-24T12:45:00+05:30" + }, + "code": { + "coding": [ + { + "code": "76164006", + "display": "Biopsy of colon (procedure)", + "system": "http://snomed.info/sct" + }, + { + "code": "1212", + "display": "Biopsy" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "note": [ + { + "text": "Nursing staff instructions - Patient bowel preparation for the procedure" + }, + { + "text": "Patient instructions - light meal or liquid diet a day before procedure" + } + ], + "performer": [ + { + "reference": "Device/0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00" + }, + { + "reference": "Practitioner/cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb" + } + ], + "locationReference": [ + { + "reference": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/377d8e6d-3ee4-7509-6f8b-6279da04eb6b" + } + }, + { + "fullUrl": "urn:uuid:0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00", + "resource": { + "resourceType": "Device", + "id": "0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00", + "identifier": [ + { + "value": "5001", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + }, + { + "value": "5002" + } + ], + "deviceName": [ + { + "name": "EVIS X12 Video Colonoscope", + "type": "model-name" + } + ], + "status": "active", + "note": [ + { + "text": "Check if this particular equipment is available" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00" + } + }, + { + "fullUrl": "urn:uuid:b13417bd-d0fb-e50f-b65a-cd07396a0608", + "resource": { + "resourceType": "Location", + "id": "b13417bd-d0fb-e50f-b65a-cd07396a0608", + "name": "055", + "mode": "instance", + "description": "055--Room01--GH Clinic", + "type": [ + { + "coding": [ + { + "code": "C", + "display": "Clinic", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + } + ] + } + ], + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location ready and disinfected before procedure" + ] + }, + "request": { + "method": "PUT", + "url": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + } + }, + { + "fullUrl": "urn:uuid:ee586d80-706a-5933-8500-a8026c48fb27", + "resource": { + "resourceType": "Location", + "id": "ee586d80-706a-5933-8500-a8026c48fb27", + "partOf": { + "reference": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + }, + "name": "Room01", + "mode": "instance", + "description": "055--Room01--GH Clinic", + "type": [ + { + "coding": [ + { + "code": "C", + "display": "Clinic", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + } + ] + } + ], + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location ready and disinfected before procedure" + ] + }, + "request": { + "method": "PUT", + "url": "Location/ee586d80-706a-5933-8500-a8026c48fb27" + } + }, + { + "fullUrl": "urn:uuid:4b6f7358-191b-8623-f2f4-806a8a0babcf", + "resource": { + "resourceType": "Location", + "id": "4b6f7358-191b-8623-f2f4-806a8a0babcf", + "name": "GH Clinic", + "mode": "instance", + "description": "055--Room01--GH Clinic", + "type": [ + { + "coding": [ + { + "code": "C", + "display": "Clinic", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + } + ] + } + ], + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + }, + "alias": [ + "Location ready and disinfected before procedure" + ] + }, + "request": { + "method": "PUT", + "url": "Location/4b6f7358-191b-8623-f2f4-806a8a0babcf" + } + }, + { + "fullUrl": "urn:uuid:cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb", + "resource": { + "resourceType": "Practitioner", + "id": "cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb", + "identifier": [ + { + "value": "1210" + } + ], + "name": [ + { + "family": "GE", + "given": [ + "Robert", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S13/SIU-S13-02-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S13/SIU-S13-02-expected.json new file mode 100644 index 000000000..dd38f2c02 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S13/SIU-S13-02-expected.json @@ -0,0 +1,1639 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2021-08-18T14:45:00+05:30", + "identifier": { + "value": "MSG00013" + }, + "id": "3fa01fde-f1f9-271b-cd78-622b69fcca15", + "entry": [ + { + "fullUrl": "urn:uuid:6075682b-c1ce-410b-b538-cb7bf0d16c6c", + "resource": { + "resourceType": "MessageHeader", + "id": "6075682b-c1ce-410b-b538-cb7bf0d16c6c", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "S13", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "SIU^S13^SIU_S13" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/6075682b-c1ce-410b-b538-cb7bf0d16c6c" + } + }, + { + "fullUrl": "urn:uuid:09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "resource": { + "resourceType": "Provenance", + "id": "09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:40:48.961Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: SIU_S13.

" + }, + "occurredDateTime": "2021-08-18T14:45:00+05:30", + "recorded": "2021-08-18T14:45:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "SIU^S13^SIU_S13" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/12428005-5692-7537-f572-e47a16418f26" + } + } + ], + "target": [ + { + "reference": "Bundle/3fa01fde-f1f9-271b-cd78-622b69fcca15" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/09e54df1-8856-96ca-cdbf-4bdbd94a26a3" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:12428005-5692-7537-f572-e47a16418f26", + "resource": { + "resourceType": "Device", + "id": "12428005-5692-7537-f572-e47a16418f26", + "identifier": [ + { + "value": "SCHApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/12428005-5692-7537-f572-e47a16418f26" + } + }, + { + "fullUrl": "urn:uuid:b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "resource": { + "resourceType": "Appointment", + "id": "b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "identifier": [ + { + "value": "12345", + "type": { + "coding": [ + { + "code": "PLAC", + "display": "Placer Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "36996", + "type": { + "coding": [ + { + "code": "FILL", + "display": "Filler Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "appointmentType": { + "coding": [ + { + "code": "CHECKUP", + "display": "A routine check-up, such as an annual physical", + "system": "http://terminology.hl7.org/CodeSystem/v2-0276" + } + ] + }, + "priority": 2, + "start": "2021-08-20T14:45:00+05:30", + "end": "2021-08-20T15:45:00+05:30", + "minutesDuration": 70, + "status": "booked", + "supportingInformation": [ + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + ], + "comment": "Appointment rescheduled for annual checkup on Aug 20 instead of Aug 18 as per patient's request.", + "participant": [ + { + "actor": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "status": "accepted" + }, + { + "actor": { + "reference": "Device/dd77839c-6623-a021-29ef-c04fd35460ca" + }, + "type": [ + { + "coding": [ + { + "code": "011", + "display": "Lab Equipment", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + }, + "status": "tentative" + }, + { + "actor": { + "reference": "Practitioner/9d928c63-6d1e-7fb7-fed9-b97b625dc5f8" + }, + "type": [ + { + "coding": [ + { + "code": "019", + "display": "Phlebotomist", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Device/d8709d49-8f55-d198-44e8-2cf5ee983e90" + }, + "type": [ + { + "coding": [ + { + "code": "015", + "display": "Imaging Equipment", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + }, + "status": "tentative" + }, + { + "actor": { + "reference": "Practitioner/89f153f4-91d2-b658-0242-612129d35f06" + }, + "type": [ + { + "coding": [ + { + "code": "021", + "display": "Radiology Technician", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Location/82709fdd-4012-9faa-5ec3-cf75fd57a34c" + }, + "status": "tentative" + }, + { + "actor": { + "reference": "Practitioner/a4177c1c-eb53-edd4-a0ee-1a55b986ea3b" + }, + "type": [ + { + "coding": [ + { + "code": "011", + "display": "General Practitioner", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/8ad3476e-03c9-158e-12d8-20de3070fce5" + }, + { + "reference": "ServiceRequest/2b1743c0-089d-d354-0cbe-e548478fd580" + } + ] + }, + "request": { + "method": "PUT", + "url": "Appointment/b7121f46-cf50-5cec-7cfb-5de8e42b82d2" + } + }, + { + "fullUrl": "urn:uuid:df03b003-6818-1abd-209e-0889025aad16", + "resource": { + "resourceType": "Organization", + "id": "df03b003-6818-1abd-209e-0889025aad16", + "identifier": [ + { + "value": "NPIID", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NPIID" + }, + { + "value": "urn:oid:2.16.840.1.113883.4.6", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/df03b003-6818-1abd-209e-0889025aad16" + } + }, + { + "fullUrl": "urn:uuid:6f540060-4f9a-5d13-45b3-da6a76e207a7", + "resource": { + "resourceType": "Practitioner", + "id": "6f540060-4f9a-5d13-45b3-da6a76e207a7", + "address": [ + { + "line": [ + "115 MAINSTREET" + ], + "city": "GOODTOWN", + "state": "KY", + "postalCode": "42010", + "country": "USA" + } + ], + "telecom": [ + { + "value": "(608)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9941339109", + "system": "urn:oid:2.16.840.1.113883.4.6", + "assigner": { + "reference": "Organization/df03b003-6818-1abd-209e-0889025aad16" + }, + "type": { + "coding": [ + { + "code": "NPI", + "display": "National provider identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Smith", + "given": [ + "Adam", + "Mellie" + ], + "suffix": [ + "Jr", + "MD", + "GP" + ], + "prefix": [ + "Dr" + ], + "use": "official", + "period": { + "start": "2010-01-15", + "end": "2020-01-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + { + "fullUrl": "urn:uuid:36effb10-f605-f388-c06c-90d22b315bd0", + "resource": { + "resourceType": "PractitionerRole", + "id": "36effb10-f605-f388-c06c-90d22b315bd0", + "code": [ + { + "coding": [ + { + "code": "placer-contact", + "display": "Placer Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + }, + { + "coding": [ + { + "code": "filler-contact", + "display": "Filler Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + ], + "practitioner": { + "reference": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + } + }, + { + "fullUrl": "urn:uuid:92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "resource": { + "resourceType": "Location", + "id": "92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "name": "FACILITY2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + }, + { + "fullUrl": "urn:uuid:4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "resource": { + "resourceType": "Location", + "id": "4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "partOf": { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + }, + "name": "BUILDING2", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + } + }, + { + "fullUrl": "urn:uuid:81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "resource": { + "resourceType": "Location", + "id": "81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf" + } + }, + { + "fullUrl": "urn:uuid:fb95e0b1-227c-8068-3e51-86c2df312f25", + "resource": { + "resourceType": "Practitioner", + "id": "fb95e0b1-227c-8068-3e51-86c2df312f25", + "telecom": [ + { + "value": "(610)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9" + } + ], + "name": [ + { + "family": "DENT", + "given": [ + "COREY" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + { + "fullUrl": "urn:uuid:f3c93626-c639-1507-76f0-945d762c11a8", + "resource": { + "resourceType": "PractitionerRole", + "id": "f3c93626-c639-1507-76f0-945d762c11a8", + "code": [ + { + "coding": [ + { + "code": "enterer", + "display": "Enterer", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + ], + "practitioner": { + "reference": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + }, + { + "fullUrl": "urn:uuid:5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "resource": { + "resourceType": "Location", + "id": "5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "name": "FACILITY3", + "identifier": [ + { + "value": "urn:oid:1.23", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:8ad3476e-03c9-158e-12d8-20de3070fce5", + "resource": { + "resourceType": "ServiceRequest", + "id": "8ad3476e-03c9-158e-12d8-20de3070fce5", + "status": "active", + "intent": "filler-order", + "code": { + "coding": [ + { + "code": "58410-2", + "display": "CBC Panel-Blood by Automated Count", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "note": [ + { + "text": "Fasting for Blood sugar before appointment" + } + ], + "performer": [ + { + "reference": "Device/dd77839c-6623-a021-29ef-c04fd35460ca" + }, + { + "reference": "Practitioner/9d928c63-6d1e-7fb7-fed9-b97b625dc5f8" + } + ], + "locationReference": [ + { + "reference": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/8ad3476e-03c9-158e-12d8-20de3070fce5" + } + }, + { + "fullUrl": "urn:uuid:dd77839c-6623-a021-29ef-c04fd35460ca", + "resource": { + "resourceType": "Device", + "id": "dd77839c-6623-a021-29ef-c04fd35460ca", + "identifier": [ + { + "value": "123", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ], + "deviceName": [ + { + "name": "ABC Cell Counter", + "type": "model-name" + } + ], + "note": [ + { + "text": "Equipment booked for lab test" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/dd77839c-6623-a021-29ef-c04fd35460ca" + } + }, + { + "fullUrl": "urn:uuid:bc5a0b18-cce5-ddbc-8e45-a09c736af725", + "resource": { + "resourceType": "Location", + "id": "bc5a0b18-cce5-ddbc-8e45-a09c736af725", + "name": "LabUnit101", + "mode": "instance", + "description": "LabUnit101--Lab Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for lab test" + ] + }, + "request": { + "method": "PUT", + "url": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + } + }, + { + "fullUrl": "urn:uuid:a86368de-48ac-12e3-05e4-6b2da7fa4853", + "resource": { + "resourceType": "Location", + "id": "a86368de-48ac-12e3-05e4-6b2da7fa4853", + "partOf": { + "reference": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + }, + "name": "Lab Room 01", + "mode": "instance", + "description": "LabUnit101--Lab Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for lab test" + ] + }, + "request": { + "method": "PUT", + "url": "Location/a86368de-48ac-12e3-05e4-6b2da7fa4853" + } + }, + { + "fullUrl": "urn:uuid:9d04f983-a391-647a-07a8-e8bf59f77de8", + "resource": { + "resourceType": "Location", + "id": "9d04f983-a391-647a-07a8-e8bf59f77de8", + "name": "GHH Hospital", + "mode": "instance", + "description": "OPD12--Room 55--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + }, + "alias": [ + "Location available for lab test", + "Location available for imaging", + "Location available for checkup" + ] + }, + "request": { + "method": "PUT", + "url": "Location/9d04f983-a391-647a-07a8-e8bf59f77de8" + } + }, + { + "fullUrl": "urn:uuid:9d928c63-6d1e-7fb7-fed9-b97b625dc5f8", + "resource": { + "resourceType": "Practitioner", + "id": "9d928c63-6d1e-7fb7-fed9-b97b625dc5f8", + "identifier": [ + { + "value": "400" + } + ], + "name": [ + { + "family": "PB", + "given": [ + "Tim", + "G" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/9d928c63-6d1e-7fb7-fed9-b97b625dc5f8" + } + }, + { + "fullUrl": "urn:uuid:2b1743c0-089d-d354-0cbe-e548478fd580", + "resource": { + "resourceType": "ServiceRequest", + "id": "2b1743c0-089d-d354-0cbe-e548478fd580", + "status": "active", + "intent": "filler-order", + "code": { + "coding": [ + { + "code": "42272-5", + "display": "XR Chest PA and Lateral", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "note": [ + { + "text": "Patient Instructions - wear loose comfortable clothes,keep metallic objects away and leave jewellery at home" + } + ], + "performer": [ + { + "reference": "Device/d8709d49-8f55-d198-44e8-2cf5ee983e90" + }, + { + "reference": "Practitioner/89f153f4-91d2-b658-0242-612129d35f06" + } + ], + "locationReference": [ + { + "reference": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/2b1743c0-089d-d354-0cbe-e548478fd580" + } + }, + { + "fullUrl": "urn:uuid:d8709d49-8f55-d198-44e8-2cf5ee983e90", + "resource": { + "resourceType": "Device", + "id": "d8709d49-8f55-d198-44e8-2cf5ee983e90", + "identifier": [ + { + "value": "1001", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ], + "deviceName": [ + { + "name": "XYZ X-Ray Machine", + "type": "model-name" + } + ], + "note": [ + { + "text": "Equipment booked for imaging" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/d8709d49-8f55-d198-44e8-2cf5ee983e90" + } + }, + { + "fullUrl": "urn:uuid:2b9be76c-a0f5-72ea-b684-51adaf2d95f6", + "resource": { + "resourceType": "Location", + "id": "2b9be76c-a0f5-72ea-b684-51adaf2d95f6", + "name": "DiagnosticUnit201", + "mode": "instance", + "description": "DiagnosticUnit201--Imaging Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for imaging" + ] + }, + "request": { + "method": "PUT", + "url": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + } + }, + { + "fullUrl": "urn:uuid:e36c1c9d-9008-4267-0e0f-e8b36ec2f208", + "resource": { + "resourceType": "Location", + "id": "e36c1c9d-9008-4267-0e0f-e8b36ec2f208", + "partOf": { + "reference": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + }, + "name": "Imaging Room 01", + "mode": "instance", + "description": "DiagnosticUnit201--Imaging Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for imaging" + ] + }, + "request": { + "method": "PUT", + "url": "Location/e36c1c9d-9008-4267-0e0f-e8b36ec2f208" + } + }, + { + "fullUrl": "urn:uuid:89f153f4-91d2-b658-0242-612129d35f06", + "resource": { + "resourceType": "Practitioner", + "id": "89f153f4-91d2-b658-0242-612129d35f06", + "identifier": [ + { + "value": "500" + } + ], + "name": [ + { + "family": "RT", + "given": [ + "Robert", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/89f153f4-91d2-b658-0242-612129d35f06" + } + }, + { + "fullUrl": "urn:uuid:82709fdd-4012-9faa-5ec3-cf75fd57a34c", + "resource": { + "resourceType": "Location", + "id": "82709fdd-4012-9faa-5ec3-cf75fd57a34c", + "name": "OPD12", + "mode": "instance", + "description": "OPD12--Room 55--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for checkup" + ] + }, + "request": { + "method": "PUT", + "url": "Location/82709fdd-4012-9faa-5ec3-cf75fd57a34c" + } + }, + { + "fullUrl": "urn:uuid:928bc54e-abd5-e128-504a-f02faf5598e6", + "resource": { + "resourceType": "Location", + "id": "928bc54e-abd5-e128-504a-f02faf5598e6", + "partOf": { + "reference": "Location/82709fdd-4012-9faa-5ec3-cf75fd57a34c" + }, + "name": "Room 55", + "mode": "instance", + "description": "OPD12--Room 55--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for checkup" + ] + }, + "request": { + "method": "PUT", + "url": "Location/928bc54e-abd5-e128-504a-f02faf5598e6" + } + }, + { + "fullUrl": "urn:uuid:a4177c1c-eb53-edd4-a0ee-1a55b986ea3b", + "resource": { + "resourceType": "Practitioner", + "id": "a4177c1c-eb53-edd4-a0ee-1a55b986ea3b", + "identifier": [ + { + "value": "600" + } + ], + "name": [ + { + "family": "GP", + "given": [ + "Linda", + "R" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/a4177c1c-eb53-edd4-a0ee-1a55b986ea3b" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S14/SIU-S14-01-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S14/SIU-S14-01-expected.json new file mode 100644 index 000000000..f73d594e6 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S14/SIU-S14-01-expected.json @@ -0,0 +1,1419 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2021-09-20T14:41:00+05:30", + "identifier": { + "value": "MSG00014" + }, + "id": "9ded1d35-26d3-a326-1f41-9ed7b458bc51", + "entry": [ + { + "fullUrl": "urn:uuid:77ae10cf-00a1-f576-c389-7388a8cf6cf4", + "resource": { + "resourceType": "MessageHeader", + "id": "77ae10cf-00a1-f576-c389-7388a8cf6cf4", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "S14", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "SIU^S14^SIU_S14" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/77ae10cf-00a1-f576-c389-7388a8cf6cf4" + } + }, + { + "fullUrl": "urn:uuid:09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "resource": { + "resourceType": "Provenance", + "id": "09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:41:34.023Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: SIU_S14.

" + }, + "occurredDateTime": "2021-09-20T14:41:00+05:30", + "recorded": "2021-09-20T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "SIU^S14^SIU_S14" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/12428005-5692-7537-f572-e47a16418f26" + } + } + ], + "target": [ + { + "reference": "Bundle/9ded1d35-26d3-a326-1f41-9ed7b458bc51" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/09e54df1-8856-96ca-cdbf-4bdbd94a26a3" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:12428005-5692-7537-f572-e47a16418f26", + "resource": { + "resourceType": "Device", + "id": "12428005-5692-7537-f572-e47a16418f26", + "identifier": [ + { + "value": "SCHApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/12428005-5692-7537-f572-e47a16418f26" + } + }, + { + "fullUrl": "urn:uuid:b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "resource": { + "resourceType": "Appointment", + "id": "b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "identifier": [ + { + "value": "12345", + "type": { + "coding": [ + { + "code": "PLAC", + "display": "Placer Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "36996", + "type": { + "coding": [ + { + "code": "FILL", + "display": "Filler Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "appointmentType": { + "coding": [ + { + "code": "EMERGENCY", + "display": "Emergency appointment", + "system": "http://terminology.hl7.org/CodeSystem/v2-0276" + } + ] + }, + "priority": 2, + "start": "2021-09-24T12:45:00+05:30", + "end": "2021-09-24T13:35:00+05:30", + "minutesDuration": 1, + "status": "booked", + "supportingInformation": [ + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + ], + "participant": [ + { + "actor": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "status": "accepted" + }, + { + "actor": { + "reference": "Device/0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00" + }, + "type": [ + { + "coding": [ + { + "code": "101", + "display": "Equipment", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "period": { + "start": "2021-09-24T12:45:00+05:30" + }, + "status": "accepted" + }, + { + "actor": { + "reference": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + }, + "period": { + "start": "2021-09-24T12:45:00+05:30" + }, + "status": "accepted" + }, + { + "actor": { + "reference": "Practitioner/cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb" + }, + "type": [ + { + "coding": [ + { + "code": "010", + "display": "Gastroenterologist", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "period": { + "start": "2021-09-24T12:45:00+05:30" + }, + "status": "accepted" + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/377d8e6d-3ee4-7509-6f8b-6279da04eb6b" + } + ] + }, + "request": { + "method": "PUT", + "url": "Appointment/b7121f46-cf50-5cec-7cfb-5de8e42b82d2" + } + }, + { + "fullUrl": "urn:uuid:df03b003-6818-1abd-209e-0889025aad16", + "resource": { + "resourceType": "Organization", + "id": "df03b003-6818-1abd-209e-0889025aad16", + "identifier": [ + { + "value": "NPIID", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NPIID" + }, + { + "value": "urn:oid:2.16.840.1.113883.4.6", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/df03b003-6818-1abd-209e-0889025aad16" + } + }, + { + "fullUrl": "urn:uuid:6f540060-4f9a-5d13-45b3-da6a76e207a7", + "resource": { + "resourceType": "Practitioner", + "id": "6f540060-4f9a-5d13-45b3-da6a76e207a7", + "address": [ + { + "line": [ + "115 MAINSTREET" + ], + "city": "GOODTOWN", + "state": "KY", + "postalCode": "42010", + "country": "USA" + } + ], + "telecom": [ + { + "value": "(608)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9941339109", + "system": "urn:oid:2.16.840.1.113883.4.6", + "assigner": { + "reference": "Organization/df03b003-6818-1abd-209e-0889025aad16" + }, + "type": { + "coding": [ + { + "code": "NPI", + "display": "National provider identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Smith", + "given": [ + "Adam", + "Mellie" + ], + "suffix": [ + "Jr", + "MD", + "GP" + ], + "prefix": [ + "Dr" + ], + "use": "official", + "period": { + "start": "2010-01-15", + "end": "2020-01-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + { + "fullUrl": "urn:uuid:36effb10-f605-f388-c06c-90d22b315bd0", + "resource": { + "resourceType": "PractitionerRole", + "id": "36effb10-f605-f388-c06c-90d22b315bd0", + "code": [ + { + "coding": [ + { + "code": "placer-contact", + "display": "Placer Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + }, + { + "coding": [ + { + "code": "filler-contact", + "display": "Filler Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + ], + "practitioner": { + "reference": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + } + }, + { + "fullUrl": "urn:uuid:92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "resource": { + "resourceType": "Location", + "id": "92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "name": "FACILITY2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + }, + { + "fullUrl": "urn:uuid:4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "resource": { + "resourceType": "Location", + "id": "4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "partOf": { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + }, + "name": "BUILDING2", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + } + }, + { + "fullUrl": "urn:uuid:81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "resource": { + "resourceType": "Location", + "id": "81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf" + } + }, + { + "fullUrl": "urn:uuid:fb95e0b1-227c-8068-3e51-86c2df312f25", + "resource": { + "resourceType": "Practitioner", + "id": "fb95e0b1-227c-8068-3e51-86c2df312f25", + "telecom": [ + { + "value": "(610)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9" + } + ], + "name": [ + { + "family": "DENT", + "given": [ + "COREY" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + { + "fullUrl": "urn:uuid:f3c93626-c639-1507-76f0-945d762c11a8", + "resource": { + "resourceType": "PractitionerRole", + "id": "f3c93626-c639-1507-76f0-945d762c11a8", + "code": [ + { + "coding": [ + { + "code": "enterer", + "display": "Enterer", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + ], + "practitioner": { + "reference": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + }, + { + "fullUrl": "urn:uuid:5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "resource": { + "resourceType": "Location", + "id": "5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "name": "FACILITY3", + "identifier": [ + { + "value": "urn:oid:1.23", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:377d8e6d-3ee4-7509-6f8b-6279da04eb6b", + "resource": { + "resourceType": "ServiceRequest", + "id": "377d8e6d-3ee4-7509-6f8b-6279da04eb6b", + "status": "active", + "intent": "filler-order", + "orderDetail": [ + { + "coding": [ + { + "code": "5001", + "display": "EVIS X12 Video Colonoscope", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + }, + { + "coding": [ + { + "code": "5001", + "display": "EVIS X12 Video Colonoscope", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "occurrencePeriod": { + "start": "2021-09-24T12:45:00+05:30" + }, + "code": { + "coding": [ + { + "code": "76164006", + "display": "Biopsy of colon (procedure)", + "system": "http://snomed.info/sct" + }, + { + "code": "1212", + "display": "Biopsy" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "note": [ + { + "text": "Nursing staff instructions - Patient bowel preparation for the procedure" + }, + { + "text": "Patient instructions - light meal or liquid diet a day before procedure" + } + ], + "performer": [ + { + "reference": "Device/0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00" + }, + { + "reference": "Practitioner/cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb" + } + ], + "locationReference": [ + { + "reference": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/377d8e6d-3ee4-7509-6f8b-6279da04eb6b" + } + }, + { + "fullUrl": "urn:uuid:0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00", + "resource": { + "resourceType": "Device", + "id": "0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00", + "identifier": [ + { + "value": "5001", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + }, + { + "value": "5002" + } + ], + "deviceName": [ + { + "name": "EVIS X12 Video Colonoscope", + "type": "model-name" + } + ], + "status": "active", + "note": [ + { + "text": "Check if this particular equipment is available" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00" + } + }, + { + "fullUrl": "urn:uuid:b13417bd-d0fb-e50f-b65a-cd07396a0608", + "resource": { + "resourceType": "Location", + "id": "b13417bd-d0fb-e50f-b65a-cd07396a0608", + "name": "055", + "mode": "instance", + "description": "055--Room02--GH Clinic", + "type": [ + { + "coding": [ + { + "code": "C", + "display": "Clinic", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + } + ] + } + ], + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location ready and disinfected before procedure" + ] + }, + "request": { + "method": "PUT", + "url": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + } + }, + { + "fullUrl": "urn:uuid:d60a0eea-ecdf-5600-5240-cea2c87a23ba", + "resource": { + "resourceType": "Location", + "id": "d60a0eea-ecdf-5600-5240-cea2c87a23ba", + "partOf": { + "reference": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + }, + "name": "Room02", + "mode": "instance", + "description": "055--Room02--GH Clinic", + "type": [ + { + "coding": [ + { + "code": "C", + "display": "Clinic", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + } + ] + } + ], + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location ready and disinfected before procedure" + ] + }, + "request": { + "method": "PUT", + "url": "Location/d60a0eea-ecdf-5600-5240-cea2c87a23ba" + } + }, + { + "fullUrl": "urn:uuid:4b6f7358-191b-8623-f2f4-806a8a0babcf", + "resource": { + "resourceType": "Location", + "id": "4b6f7358-191b-8623-f2f4-806a8a0babcf", + "name": "GH Clinic", + "mode": "instance", + "description": "055--Room02--GH Clinic", + "type": [ + { + "coding": [ + { + "code": "C", + "display": "Clinic", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + } + ] + } + ], + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + }, + "alias": [ + "Location ready and disinfected before procedure" + ] + }, + "request": { + "method": "PUT", + "url": "Location/4b6f7358-191b-8623-f2f4-806a8a0babcf" + } + }, + { + "fullUrl": "urn:uuid:cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb", + "resource": { + "resourceType": "Practitioner", + "id": "cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb", + "identifier": [ + { + "value": "1210" + } + ], + "name": [ + { + "family": "GE", + "given": [ + "Robert", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S14/SIU-S14-02-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S14/SIU-S14-02-expected.json new file mode 100644 index 000000000..ad49d45a4 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S14/SIU-S14-02-expected.json @@ -0,0 +1,1639 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2021-08-17T14:45:00+05:30", + "identifier": { + "value": "MSG00014" + }, + "id": "9ded1d35-26d3-a326-1f41-9ed7b458bc51", + "entry": [ + { + "fullUrl": "urn:uuid:77ae10cf-00a1-f576-c389-7388a8cf6cf4", + "resource": { + "resourceType": "MessageHeader", + "id": "77ae10cf-00a1-f576-c389-7388a8cf6cf4", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "S14", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "SIU^S14^SIU_S14" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/77ae10cf-00a1-f576-c389-7388a8cf6cf4" + } + }, + { + "fullUrl": "urn:uuid:09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "resource": { + "resourceType": "Provenance", + "id": "09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:42:05.307Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: SIU_S14.

" + }, + "occurredDateTime": "2021-08-17T14:45:00+05:30", + "recorded": "2021-08-17T14:45:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "SIU^S14^SIU_S14" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/12428005-5692-7537-f572-e47a16418f26" + } + } + ], + "target": [ + { + "reference": "Bundle/9ded1d35-26d3-a326-1f41-9ed7b458bc51" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/09e54df1-8856-96ca-cdbf-4bdbd94a26a3" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:12428005-5692-7537-f572-e47a16418f26", + "resource": { + "resourceType": "Device", + "id": "12428005-5692-7537-f572-e47a16418f26", + "identifier": [ + { + "value": "SCHApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/12428005-5692-7537-f572-e47a16418f26" + } + }, + { + "fullUrl": "urn:uuid:b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "resource": { + "resourceType": "Appointment", + "id": "b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "identifier": [ + { + "value": "12345", + "type": { + "coding": [ + { + "code": "PLAC", + "display": "Placer Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "36996", + "type": { + "coding": [ + { + "code": "FILL", + "display": "Filler Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "appointmentType": { + "coding": [ + { + "code": "CHECKUP", + "display": "A routine check-up, such as an annual physical", + "system": "http://terminology.hl7.org/CodeSystem/v2-0276" + } + ] + }, + "priority": 2, + "start": "2021-08-18T14:45:00+05:30", + "end": "2021-08-18T15:45:00+05:30", + "minutesDuration": 70, + "status": "booked", + "supportingInformation": [ + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + ], + "comment": "Appointment for annual checkup modified by filler application for change in location from LabUnit101 to LabUnit102", + "participant": [ + { + "actor": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "status": "accepted" + }, + { + "actor": { + "reference": "Device/dd77839c-6623-a021-29ef-c04fd35460ca" + }, + "type": [ + { + "coding": [ + { + "code": "011", + "display": "Lab Equipment", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Location/49df5da3-db7b-385e-1b05-81bb68f542e3" + }, + "status": "tentative" + }, + { + "actor": { + "reference": "Practitioner/9d928c63-6d1e-7fb7-fed9-b97b625dc5f8" + }, + "type": [ + { + "coding": [ + { + "code": "019", + "display": "Phlebotomist", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Device/d8709d49-8f55-d198-44e8-2cf5ee983e90" + }, + "type": [ + { + "coding": [ + { + "code": "015", + "display": "Imaging Equipment", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + }, + "status": "tentative" + }, + { + "actor": { + "reference": "Practitioner/89f153f4-91d2-b658-0242-612129d35f06" + }, + "type": [ + { + "coding": [ + { + "code": "021", + "display": "Radiology Technician", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Location/82709fdd-4012-9faa-5ec3-cf75fd57a34c" + }, + "status": "tentative" + }, + { + "actor": { + "reference": "Practitioner/a4177c1c-eb53-edd4-a0ee-1a55b986ea3b" + }, + "type": [ + { + "coding": [ + { + "code": "011", + "display": "General Practitioner", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/8ad3476e-03c9-158e-12d8-20de3070fce5" + }, + { + "reference": "ServiceRequest/2b1743c0-089d-d354-0cbe-e548478fd580" + } + ] + }, + "request": { + "method": "PUT", + "url": "Appointment/b7121f46-cf50-5cec-7cfb-5de8e42b82d2" + } + }, + { + "fullUrl": "urn:uuid:df03b003-6818-1abd-209e-0889025aad16", + "resource": { + "resourceType": "Organization", + "id": "df03b003-6818-1abd-209e-0889025aad16", + "identifier": [ + { + "value": "NPIID", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NPIID" + }, + { + "value": "urn:oid:2.16.840.1.113883.4.6", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/df03b003-6818-1abd-209e-0889025aad16" + } + }, + { + "fullUrl": "urn:uuid:6f540060-4f9a-5d13-45b3-da6a76e207a7", + "resource": { + "resourceType": "Practitioner", + "id": "6f540060-4f9a-5d13-45b3-da6a76e207a7", + "address": [ + { + "line": [ + "115 MAINSTREET" + ], + "city": "GOODTOWN", + "state": "KY", + "postalCode": "42010", + "country": "USA" + } + ], + "telecom": [ + { + "value": "(608)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9941339109", + "system": "urn:oid:2.16.840.1.113883.4.6", + "assigner": { + "reference": "Organization/df03b003-6818-1abd-209e-0889025aad16" + }, + "type": { + "coding": [ + { + "code": "NPI", + "display": "National provider identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Smith", + "given": [ + "Adam", + "Mellie" + ], + "suffix": [ + "Jr", + "MD", + "GP" + ], + "prefix": [ + "Dr" + ], + "use": "official", + "period": { + "start": "2010-01-15", + "end": "2020-01-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + { + "fullUrl": "urn:uuid:36effb10-f605-f388-c06c-90d22b315bd0", + "resource": { + "resourceType": "PractitionerRole", + "id": "36effb10-f605-f388-c06c-90d22b315bd0", + "code": [ + { + "coding": [ + { + "code": "placer-contact", + "display": "Placer Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + }, + { + "coding": [ + { + "code": "filler-contact", + "display": "Filler Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + ], + "practitioner": { + "reference": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + } + }, + { + "fullUrl": "urn:uuid:92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "resource": { + "resourceType": "Location", + "id": "92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "name": "FACILITY2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + }, + { + "fullUrl": "urn:uuid:4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "resource": { + "resourceType": "Location", + "id": "4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "partOf": { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + }, + "name": "BUILDING2", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + } + }, + { + "fullUrl": "urn:uuid:81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "resource": { + "resourceType": "Location", + "id": "81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf" + } + }, + { + "fullUrl": "urn:uuid:fb95e0b1-227c-8068-3e51-86c2df312f25", + "resource": { + "resourceType": "Practitioner", + "id": "fb95e0b1-227c-8068-3e51-86c2df312f25", + "telecom": [ + { + "value": "(610)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9" + } + ], + "name": [ + { + "family": "DENT", + "given": [ + "COREY" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + { + "fullUrl": "urn:uuid:f3c93626-c639-1507-76f0-945d762c11a8", + "resource": { + "resourceType": "PractitionerRole", + "id": "f3c93626-c639-1507-76f0-945d762c11a8", + "code": [ + { + "coding": [ + { + "code": "enterer", + "display": "Enterer", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + ], + "practitioner": { + "reference": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + }, + { + "fullUrl": "urn:uuid:5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "resource": { + "resourceType": "Location", + "id": "5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "name": "FACILITY3", + "identifier": [ + { + "value": "urn:oid:1.23", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:8ad3476e-03c9-158e-12d8-20de3070fce5", + "resource": { + "resourceType": "ServiceRequest", + "id": "8ad3476e-03c9-158e-12d8-20de3070fce5", + "status": "active", + "intent": "filler-order", + "code": { + "coding": [ + { + "code": "58410-2", + "display": "CBC Panel-Blood by Automated Count", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "note": [ + { + "text": "Fasting for Blood sugar before appointment" + } + ], + "performer": [ + { + "reference": "Device/dd77839c-6623-a021-29ef-c04fd35460ca" + }, + { + "reference": "Practitioner/9d928c63-6d1e-7fb7-fed9-b97b625dc5f8" + } + ], + "locationReference": [ + { + "reference": "Location/49df5da3-db7b-385e-1b05-81bb68f542e3" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/8ad3476e-03c9-158e-12d8-20de3070fce5" + } + }, + { + "fullUrl": "urn:uuid:dd77839c-6623-a021-29ef-c04fd35460ca", + "resource": { + "resourceType": "Device", + "id": "dd77839c-6623-a021-29ef-c04fd35460ca", + "identifier": [ + { + "value": "123", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ], + "deviceName": [ + { + "name": "ABC Cell Counter", + "type": "model-name" + } + ], + "note": [ + { + "text": "Equipment booked for lab test" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/dd77839c-6623-a021-29ef-c04fd35460ca" + } + }, + { + "fullUrl": "urn:uuid:49df5da3-db7b-385e-1b05-81bb68f542e3", + "resource": { + "resourceType": "Location", + "id": "49df5da3-db7b-385e-1b05-81bb68f542e3", + "name": "LabUnit102", + "mode": "instance", + "description": "LabUnit102--Lab Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for lab test" + ] + }, + "request": { + "method": "PUT", + "url": "Location/49df5da3-db7b-385e-1b05-81bb68f542e3" + } + }, + { + "fullUrl": "urn:uuid:a86368de-48ac-12e3-05e4-6b2da7fa4853", + "resource": { + "resourceType": "Location", + "id": "a86368de-48ac-12e3-05e4-6b2da7fa4853", + "partOf": { + "reference": "Location/49df5da3-db7b-385e-1b05-81bb68f542e3" + }, + "name": "Lab Room 01", + "mode": "instance", + "description": "LabUnit102--Lab Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for lab test" + ] + }, + "request": { + "method": "PUT", + "url": "Location/a86368de-48ac-12e3-05e4-6b2da7fa4853" + } + }, + { + "fullUrl": "urn:uuid:9d04f983-a391-647a-07a8-e8bf59f77de8", + "resource": { + "resourceType": "Location", + "id": "9d04f983-a391-647a-07a8-e8bf59f77de8", + "name": "GHH Hospital", + "mode": "instance", + "description": "OPD12--Room 55--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + }, + "alias": [ + "Location available for lab test", + "Location available for imaging", + "Location available for checkup" + ] + }, + "request": { + "method": "PUT", + "url": "Location/9d04f983-a391-647a-07a8-e8bf59f77de8" + } + }, + { + "fullUrl": "urn:uuid:9d928c63-6d1e-7fb7-fed9-b97b625dc5f8", + "resource": { + "resourceType": "Practitioner", + "id": "9d928c63-6d1e-7fb7-fed9-b97b625dc5f8", + "identifier": [ + { + "value": "400" + } + ], + "name": [ + { + "family": "PB", + "given": [ + "Tim", + "G" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/9d928c63-6d1e-7fb7-fed9-b97b625dc5f8" + } + }, + { + "fullUrl": "urn:uuid:2b1743c0-089d-d354-0cbe-e548478fd580", + "resource": { + "resourceType": "ServiceRequest", + "id": "2b1743c0-089d-d354-0cbe-e548478fd580", + "status": "active", + "intent": "filler-order", + "code": { + "coding": [ + { + "code": "42272-5", + "display": "XR Chest PA and Lateral", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "note": [ + { + "text": "Patient Instructions - wear loose comfortable clothes,keep metallic objects away and leave jewellery at home" + } + ], + "performer": [ + { + "reference": "Device/d8709d49-8f55-d198-44e8-2cf5ee983e90" + }, + { + "reference": "Practitioner/89f153f4-91d2-b658-0242-612129d35f06" + } + ], + "locationReference": [ + { + "reference": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/2b1743c0-089d-d354-0cbe-e548478fd580" + } + }, + { + "fullUrl": "urn:uuid:d8709d49-8f55-d198-44e8-2cf5ee983e90", + "resource": { + "resourceType": "Device", + "id": "d8709d49-8f55-d198-44e8-2cf5ee983e90", + "identifier": [ + { + "value": "1001", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ], + "deviceName": [ + { + "name": "XYZ X-Ray Machine", + "type": "model-name" + } + ], + "note": [ + { + "text": "Equipment booked for imaging" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/d8709d49-8f55-d198-44e8-2cf5ee983e90" + } + }, + { + "fullUrl": "urn:uuid:2b9be76c-a0f5-72ea-b684-51adaf2d95f6", + "resource": { + "resourceType": "Location", + "id": "2b9be76c-a0f5-72ea-b684-51adaf2d95f6", + "name": "DiagnosticUnit201", + "mode": "instance", + "description": "DiagnosticUnit201--Imaging Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for imaging" + ] + }, + "request": { + "method": "PUT", + "url": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + } + }, + { + "fullUrl": "urn:uuid:e36c1c9d-9008-4267-0e0f-e8b36ec2f208", + "resource": { + "resourceType": "Location", + "id": "e36c1c9d-9008-4267-0e0f-e8b36ec2f208", + "partOf": { + "reference": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + }, + "name": "Imaging Room 01", + "mode": "instance", + "description": "DiagnosticUnit201--Imaging Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for imaging" + ] + }, + "request": { + "method": "PUT", + "url": "Location/e36c1c9d-9008-4267-0e0f-e8b36ec2f208" + } + }, + { + "fullUrl": "urn:uuid:89f153f4-91d2-b658-0242-612129d35f06", + "resource": { + "resourceType": "Practitioner", + "id": "89f153f4-91d2-b658-0242-612129d35f06", + "identifier": [ + { + "value": "500" + } + ], + "name": [ + { + "family": "RT", + "given": [ + "Robert", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/89f153f4-91d2-b658-0242-612129d35f06" + } + }, + { + "fullUrl": "urn:uuid:82709fdd-4012-9faa-5ec3-cf75fd57a34c", + "resource": { + "resourceType": "Location", + "id": "82709fdd-4012-9faa-5ec3-cf75fd57a34c", + "name": "OPD12", + "mode": "instance", + "description": "OPD12--Room 55--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for checkup" + ] + }, + "request": { + "method": "PUT", + "url": "Location/82709fdd-4012-9faa-5ec3-cf75fd57a34c" + } + }, + { + "fullUrl": "urn:uuid:928bc54e-abd5-e128-504a-f02faf5598e6", + "resource": { + "resourceType": "Location", + "id": "928bc54e-abd5-e128-504a-f02faf5598e6", + "partOf": { + "reference": "Location/82709fdd-4012-9faa-5ec3-cf75fd57a34c" + }, + "name": "Room 55", + "mode": "instance", + "description": "OPD12--Room 55--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for checkup" + ] + }, + "request": { + "method": "PUT", + "url": "Location/928bc54e-abd5-e128-504a-f02faf5598e6" + } + }, + { + "fullUrl": "urn:uuid:a4177c1c-eb53-edd4-a0ee-1a55b986ea3b", + "resource": { + "resourceType": "Practitioner", + "id": "a4177c1c-eb53-edd4-a0ee-1a55b986ea3b", + "identifier": [ + { + "value": "600" + } + ], + "name": [ + { + "family": "GP", + "given": [ + "Linda", + "R" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/a4177c1c-eb53-edd4-a0ee-1a55b986ea3b" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S15/SIU-S15-01-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S15/SIU-S15-01-expected.json new file mode 100644 index 000000000..921264796 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S15/SIU-S15-01-expected.json @@ -0,0 +1,1419 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2021-09-23T14:41:00+05:30", + "identifier": { + "value": "MSG00015" + }, + "id": "d7447df6-4738-6328-ce18-4b3764840611", + "entry": [ + { + "fullUrl": "urn:uuid:9c92bbf4-5a47-76e9-3773-94cf525eaf67", + "resource": { + "resourceType": "MessageHeader", + "id": "9c92bbf4-5a47-76e9-3773-94cf525eaf67", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "S15", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "SIU^S15^SIU_S15" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/9c92bbf4-5a47-76e9-3773-94cf525eaf67" + } + }, + { + "fullUrl": "urn:uuid:09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "resource": { + "resourceType": "Provenance", + "id": "09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:42:52.655Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: SIU_S15.

" + }, + "occurredDateTime": "2021-09-23T14:41:00+05:30", + "recorded": "2021-09-23T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "SIU^S15^SIU_S15" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/12428005-5692-7537-f572-e47a16418f26" + } + } + ], + "target": [ + { + "reference": "Bundle/d7447df6-4738-6328-ce18-4b3764840611" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/09e54df1-8856-96ca-cdbf-4bdbd94a26a3" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:12428005-5692-7537-f572-e47a16418f26", + "resource": { + "resourceType": "Device", + "id": "12428005-5692-7537-f572-e47a16418f26", + "identifier": [ + { + "value": "SCHApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/12428005-5692-7537-f572-e47a16418f26" + } + }, + { + "fullUrl": "urn:uuid:b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "resource": { + "resourceType": "Appointment", + "id": "b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "identifier": [ + { + "value": "12345", + "type": { + "coding": [ + { + "code": "PLAC", + "display": "Placer Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "36996", + "type": { + "coding": [ + { + "code": "FILL", + "display": "Filler Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "appointmentType": { + "coding": [ + { + "code": "EMERGENCY", + "display": "Emergency appointment", + "system": "http://terminology.hl7.org/CodeSystem/v2-0276" + } + ] + }, + "priority": 2, + "start": "2021-09-24T12:45:00+05:30", + "end": "2021-09-24T13:35:00+05:30", + "minutesDuration": 1, + "status": "cancelled", + "supportingInformation": [ + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + ], + "participant": [ + { + "actor": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "status": "accepted" + }, + { + "actor": { + "reference": "Device/0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00" + }, + "type": [ + { + "coding": [ + { + "code": "101", + "display": "Equipment", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "period": { + "start": "2021-09-24T12:45:00+05:30" + }, + "status": "declined" + }, + { + "actor": { + "reference": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + }, + "period": { + "start": "2021-09-24T12:45:00+05:30" + }, + "status": "declined" + }, + { + "actor": { + "reference": "Practitioner/cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb" + }, + "type": [ + { + "coding": [ + { + "code": "010", + "display": "Gastroenterologist", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "period": { + "start": "2021-09-24T12:45:00+05:30" + }, + "status": "declined" + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/377d8e6d-3ee4-7509-6f8b-6279da04eb6b" + } + ] + }, + "request": { + "method": "PUT", + "url": "Appointment/b7121f46-cf50-5cec-7cfb-5de8e42b82d2" + } + }, + { + "fullUrl": "urn:uuid:df03b003-6818-1abd-209e-0889025aad16", + "resource": { + "resourceType": "Organization", + "id": "df03b003-6818-1abd-209e-0889025aad16", + "identifier": [ + { + "value": "NPIID", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NPIID" + }, + { + "value": "urn:oid:2.16.840.1.113883.4.6", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/df03b003-6818-1abd-209e-0889025aad16" + } + }, + { + "fullUrl": "urn:uuid:6f540060-4f9a-5d13-45b3-da6a76e207a7", + "resource": { + "resourceType": "Practitioner", + "id": "6f540060-4f9a-5d13-45b3-da6a76e207a7", + "address": [ + { + "line": [ + "115 MAINSTREET" + ], + "city": "GOODTOWN", + "state": "KY", + "postalCode": "42010", + "country": "USA" + } + ], + "telecom": [ + { + "value": "(608)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9941339109", + "system": "urn:oid:2.16.840.1.113883.4.6", + "assigner": { + "reference": "Organization/df03b003-6818-1abd-209e-0889025aad16" + }, + "type": { + "coding": [ + { + "code": "NPI", + "display": "National provider identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Smith", + "given": [ + "Adam", + "Mellie" + ], + "suffix": [ + "Jr", + "MD", + "GP" + ], + "prefix": [ + "Dr" + ], + "use": "official", + "period": { + "start": "2010-01-15", + "end": "2020-01-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + { + "fullUrl": "urn:uuid:36effb10-f605-f388-c06c-90d22b315bd0", + "resource": { + "resourceType": "PractitionerRole", + "id": "36effb10-f605-f388-c06c-90d22b315bd0", + "code": [ + { + "coding": [ + { + "code": "placer-contact", + "display": "Placer Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + }, + { + "coding": [ + { + "code": "filler-contact", + "display": "Filler Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + ], + "practitioner": { + "reference": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + } + }, + { + "fullUrl": "urn:uuid:92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "resource": { + "resourceType": "Location", + "id": "92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "name": "FACILITY2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + }, + { + "fullUrl": "urn:uuid:4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "resource": { + "resourceType": "Location", + "id": "4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "partOf": { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + }, + "name": "BUILDING2", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + } + }, + { + "fullUrl": "urn:uuid:81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "resource": { + "resourceType": "Location", + "id": "81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf" + } + }, + { + "fullUrl": "urn:uuid:fb95e0b1-227c-8068-3e51-86c2df312f25", + "resource": { + "resourceType": "Practitioner", + "id": "fb95e0b1-227c-8068-3e51-86c2df312f25", + "telecom": [ + { + "value": "(610)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9" + } + ], + "name": [ + { + "family": "DENT", + "given": [ + "COREY" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + { + "fullUrl": "urn:uuid:f3c93626-c639-1507-76f0-945d762c11a8", + "resource": { + "resourceType": "PractitionerRole", + "id": "f3c93626-c639-1507-76f0-945d762c11a8", + "code": [ + { + "coding": [ + { + "code": "enterer", + "display": "Enterer", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + ], + "practitioner": { + "reference": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + }, + { + "fullUrl": "urn:uuid:5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "resource": { + "resourceType": "Location", + "id": "5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "name": "FACILITY3", + "identifier": [ + { + "value": "urn:oid:1.23", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:377d8e6d-3ee4-7509-6f8b-6279da04eb6b", + "resource": { + "resourceType": "ServiceRequest", + "id": "377d8e6d-3ee4-7509-6f8b-6279da04eb6b", + "status": "revoked", + "intent": "filler-order", + "orderDetail": [ + { + "coding": [ + { + "code": "5001", + "display": "EVIS X12 Video Colonoscope", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + }, + { + "coding": [ + { + "code": "5001", + "display": "EVIS X12 Video Colonoscope", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "occurrencePeriod": { + "start": "2021-09-24T12:45:00+05:30" + }, + "code": { + "coding": [ + { + "code": "76164006", + "display": "Biopsy of colon (procedure)", + "system": "http://snomed.info/sct" + }, + { + "code": "1212", + "display": "Biopsy" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "note": [ + { + "text": "Nursing staff instructions - Appointment cancelled" + }, + { + "text": "Patient instructions - Appointment cancelled" + } + ], + "performer": [ + { + "reference": "Device/0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00" + }, + { + "reference": "Practitioner/cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb" + } + ], + "locationReference": [ + { + "reference": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/377d8e6d-3ee4-7509-6f8b-6279da04eb6b" + } + }, + { + "fullUrl": "urn:uuid:0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00", + "resource": { + "resourceType": "Device", + "id": "0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00", + "identifier": [ + { + "value": "5001", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + }, + { + "value": "5002" + } + ], + "deviceName": [ + { + "name": "EVIS X12 Video Colonoscope", + "type": "model-name" + } + ], + "status": "active", + "note": [ + { + "text": "Equipment is available for other Practitioner as the appointment is cancelled" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00" + } + }, + { + "fullUrl": "urn:uuid:b13417bd-d0fb-e50f-b65a-cd07396a0608", + "resource": { + "resourceType": "Location", + "id": "b13417bd-d0fb-e50f-b65a-cd07396a0608", + "name": "055", + "mode": "instance", + "description": "055--Room01--GH Clinic", + "type": [ + { + "coding": [ + { + "code": "C", + "display": "Clinic", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + } + ] + } + ], + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available as appointment is cancelled" + ] + }, + "request": { + "method": "PUT", + "url": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + } + }, + { + "fullUrl": "urn:uuid:ee586d80-706a-5933-8500-a8026c48fb27", + "resource": { + "resourceType": "Location", + "id": "ee586d80-706a-5933-8500-a8026c48fb27", + "partOf": { + "reference": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + }, + "name": "Room01", + "mode": "instance", + "description": "055--Room01--GH Clinic", + "type": [ + { + "coding": [ + { + "code": "C", + "display": "Clinic", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + } + ] + } + ], + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available as appointment is cancelled" + ] + }, + "request": { + "method": "PUT", + "url": "Location/ee586d80-706a-5933-8500-a8026c48fb27" + } + }, + { + "fullUrl": "urn:uuid:4b6f7358-191b-8623-f2f4-806a8a0babcf", + "resource": { + "resourceType": "Location", + "id": "4b6f7358-191b-8623-f2f4-806a8a0babcf", + "name": "GH Clinic", + "mode": "instance", + "description": "055--Room01--GH Clinic", + "type": [ + { + "coding": [ + { + "code": "C", + "display": "Clinic", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + } + ] + } + ], + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + }, + "alias": [ + "Location available as appointment is cancelled" + ] + }, + "request": { + "method": "PUT", + "url": "Location/4b6f7358-191b-8623-f2f4-806a8a0babcf" + } + }, + { + "fullUrl": "urn:uuid:cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb", + "resource": { + "resourceType": "Practitioner", + "id": "cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb", + "identifier": [ + { + "value": "1210" + } + ], + "name": [ + { + "family": "GE", + "given": [ + "Robert", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S15/SIU-S15-02-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S15/SIU-S15-02-expected.json new file mode 100644 index 000000000..1b4e075bf --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S15/SIU-S15-02-expected.json @@ -0,0 +1,1639 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2021-08-18T13:45:00+05:30", + "identifier": { + "value": "MSG00015" + }, + "id": "d7447df6-4738-6328-ce18-4b3764840611", + "entry": [ + { + "fullUrl": "urn:uuid:9c92bbf4-5a47-76e9-3773-94cf525eaf67", + "resource": { + "resourceType": "MessageHeader", + "id": "9c92bbf4-5a47-76e9-3773-94cf525eaf67", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "S15", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "SIU^S15^SIU_S15" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/9c92bbf4-5a47-76e9-3773-94cf525eaf67" + } + }, + { + "fullUrl": "urn:uuid:09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "resource": { + "resourceType": "Provenance", + "id": "09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:43:28.077Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: SIU_S15.

" + }, + "occurredDateTime": "2021-08-18T13:45:00+05:30", + "recorded": "2021-08-18T13:45:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "SIU^S15^SIU_S15" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/12428005-5692-7537-f572-e47a16418f26" + } + } + ], + "target": [ + { + "reference": "Bundle/d7447df6-4738-6328-ce18-4b3764840611" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/09e54df1-8856-96ca-cdbf-4bdbd94a26a3" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:12428005-5692-7537-f572-e47a16418f26", + "resource": { + "resourceType": "Device", + "id": "12428005-5692-7537-f572-e47a16418f26", + "identifier": [ + { + "value": "SCHApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/12428005-5692-7537-f572-e47a16418f26" + } + }, + { + "fullUrl": "urn:uuid:b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "resource": { + "resourceType": "Appointment", + "id": "b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "identifier": [ + { + "value": "12345", + "type": { + "coding": [ + { + "code": "PLAC", + "display": "Placer Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "36996", + "type": { + "coding": [ + { + "code": "FILL", + "display": "Filler Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "appointmentType": { + "coding": [ + { + "code": "CHECKUP", + "display": "A routine check-up, such as an annual physical", + "system": "http://terminology.hl7.org/CodeSystem/v2-0276" + } + ] + }, + "priority": 2, + "start": "2021-08-18T14:45:00+05:30", + "end": "2021-08-18T15:45:00+05:30", + "minutesDuration": 70, + "status": "cancelled", + "supportingInformation": [ + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + ], + "comment": "Appointment for annual checkup cancelled as GP is not available on Aug 18.", + "participant": [ + { + "actor": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "status": "accepted" + }, + { + "actor": { + "reference": "Device/dd77839c-6623-a021-29ef-c04fd35460ca" + }, + "type": [ + { + "coding": [ + { + "code": "011", + "display": "Lab Equipment", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + }, + "status": "tentative" + }, + { + "actor": { + "reference": "Practitioner/9d928c63-6d1e-7fb7-fed9-b97b625dc5f8" + }, + "type": [ + { + "coding": [ + { + "code": "019", + "display": "Phlebotomist", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Device/d8709d49-8f55-d198-44e8-2cf5ee983e90" + }, + "type": [ + { + "coding": [ + { + "code": "015", + "display": "Imaging Equipment", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + }, + "status": "tentative" + }, + { + "actor": { + "reference": "Practitioner/89f153f4-91d2-b658-0242-612129d35f06" + }, + "type": [ + { + "coding": [ + { + "code": "021", + "display": "Radiology Technician", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Location/82709fdd-4012-9faa-5ec3-cf75fd57a34c" + }, + "status": "tentative" + }, + { + "actor": { + "reference": "Practitioner/a4177c1c-eb53-edd4-a0ee-1a55b986ea3b" + }, + "type": [ + { + "coding": [ + { + "code": "011", + "display": "General Practitioner", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/8ad3476e-03c9-158e-12d8-20de3070fce5" + }, + { + "reference": "ServiceRequest/2b1743c0-089d-d354-0cbe-e548478fd580" + } + ] + }, + "request": { + "method": "PUT", + "url": "Appointment/b7121f46-cf50-5cec-7cfb-5de8e42b82d2" + } + }, + { + "fullUrl": "urn:uuid:df03b003-6818-1abd-209e-0889025aad16", + "resource": { + "resourceType": "Organization", + "id": "df03b003-6818-1abd-209e-0889025aad16", + "identifier": [ + { + "value": "NPIID", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NPIID" + }, + { + "value": "urn:oid:2.16.840.1.113883.4.6", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/df03b003-6818-1abd-209e-0889025aad16" + } + }, + { + "fullUrl": "urn:uuid:6f540060-4f9a-5d13-45b3-da6a76e207a7", + "resource": { + "resourceType": "Practitioner", + "id": "6f540060-4f9a-5d13-45b3-da6a76e207a7", + "address": [ + { + "line": [ + "115 MAINSTREET" + ], + "city": "GOODTOWN", + "state": "KY", + "postalCode": "42010", + "country": "USA" + } + ], + "telecom": [ + { + "value": "(608)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9941339109", + "system": "urn:oid:2.16.840.1.113883.4.6", + "assigner": { + "reference": "Organization/df03b003-6818-1abd-209e-0889025aad16" + }, + "type": { + "coding": [ + { + "code": "NPI", + "display": "National provider identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Smith", + "given": [ + "Adam", + "Mellie" + ], + "suffix": [ + "Jr", + "MD", + "GP" + ], + "prefix": [ + "Dr" + ], + "use": "official", + "period": { + "start": "2010-01-15", + "end": "2020-01-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + { + "fullUrl": "urn:uuid:36effb10-f605-f388-c06c-90d22b315bd0", + "resource": { + "resourceType": "PractitionerRole", + "id": "36effb10-f605-f388-c06c-90d22b315bd0", + "code": [ + { + "coding": [ + { + "code": "placer-contact", + "display": "Placer Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + }, + { + "coding": [ + { + "code": "filler-contact", + "display": "Filler Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + ], + "practitioner": { + "reference": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + } + }, + { + "fullUrl": "urn:uuid:92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "resource": { + "resourceType": "Location", + "id": "92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "name": "FACILITY2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + }, + { + "fullUrl": "urn:uuid:4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "resource": { + "resourceType": "Location", + "id": "4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "partOf": { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + }, + "name": "BUILDING2", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + } + }, + { + "fullUrl": "urn:uuid:81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "resource": { + "resourceType": "Location", + "id": "81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf" + } + }, + { + "fullUrl": "urn:uuid:fb95e0b1-227c-8068-3e51-86c2df312f25", + "resource": { + "resourceType": "Practitioner", + "id": "fb95e0b1-227c-8068-3e51-86c2df312f25", + "telecom": [ + { + "value": "(610)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9" + } + ], + "name": [ + { + "family": "DENT", + "given": [ + "COREY" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + { + "fullUrl": "urn:uuid:f3c93626-c639-1507-76f0-945d762c11a8", + "resource": { + "resourceType": "PractitionerRole", + "id": "f3c93626-c639-1507-76f0-945d762c11a8", + "code": [ + { + "coding": [ + { + "code": "enterer", + "display": "Enterer", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + ], + "practitioner": { + "reference": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + }, + { + "fullUrl": "urn:uuid:5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "resource": { + "resourceType": "Location", + "id": "5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "name": "FACILITY3", + "identifier": [ + { + "value": "urn:oid:1.23", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:8ad3476e-03c9-158e-12d8-20de3070fce5", + "resource": { + "resourceType": "ServiceRequest", + "id": "8ad3476e-03c9-158e-12d8-20de3070fce5", + "status": "draft", + "intent": "filler-order", + "code": { + "coding": [ + { + "code": "58410-2", + "display": "CBC Panel-Blood by Automated Count", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "note": [ + { + "text": "Fasting for Blood sugar before appointment" + } + ], + "performer": [ + { + "reference": "Device/dd77839c-6623-a021-29ef-c04fd35460ca" + }, + { + "reference": "Practitioner/9d928c63-6d1e-7fb7-fed9-b97b625dc5f8" + } + ], + "locationReference": [ + { + "reference": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/8ad3476e-03c9-158e-12d8-20de3070fce5" + } + }, + { + "fullUrl": "urn:uuid:dd77839c-6623-a021-29ef-c04fd35460ca", + "resource": { + "resourceType": "Device", + "id": "dd77839c-6623-a021-29ef-c04fd35460ca", + "identifier": [ + { + "value": "123", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ], + "deviceName": [ + { + "name": "ABC Cell Counter", + "type": "model-name" + } + ], + "note": [ + { + "text": "Equipment booked for lab test" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/dd77839c-6623-a021-29ef-c04fd35460ca" + } + }, + { + "fullUrl": "urn:uuid:bc5a0b18-cce5-ddbc-8e45-a09c736af725", + "resource": { + "resourceType": "Location", + "id": "bc5a0b18-cce5-ddbc-8e45-a09c736af725", + "name": "LabUnit101", + "mode": "instance", + "description": "LabUnit101--Lab Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for lab test" + ] + }, + "request": { + "method": "PUT", + "url": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + } + }, + { + "fullUrl": "urn:uuid:a86368de-48ac-12e3-05e4-6b2da7fa4853", + "resource": { + "resourceType": "Location", + "id": "a86368de-48ac-12e3-05e4-6b2da7fa4853", + "partOf": { + "reference": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + }, + "name": "Lab Room 01", + "mode": "instance", + "description": "LabUnit101--Lab Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for lab test" + ] + }, + "request": { + "method": "PUT", + "url": "Location/a86368de-48ac-12e3-05e4-6b2da7fa4853" + } + }, + { + "fullUrl": "urn:uuid:9d04f983-a391-647a-07a8-e8bf59f77de8", + "resource": { + "resourceType": "Location", + "id": "9d04f983-a391-647a-07a8-e8bf59f77de8", + "name": "GHH Hospital", + "mode": "instance", + "description": "OPD12--Room 55--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + }, + "alias": [ + "Location available for lab test", + "Location available for imaging", + "Location available for checkup" + ] + }, + "request": { + "method": "PUT", + "url": "Location/9d04f983-a391-647a-07a8-e8bf59f77de8" + } + }, + { + "fullUrl": "urn:uuid:9d928c63-6d1e-7fb7-fed9-b97b625dc5f8", + "resource": { + "resourceType": "Practitioner", + "id": "9d928c63-6d1e-7fb7-fed9-b97b625dc5f8", + "identifier": [ + { + "value": "400" + } + ], + "name": [ + { + "family": "PB", + "given": [ + "Tim", + "G" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/9d928c63-6d1e-7fb7-fed9-b97b625dc5f8" + } + }, + { + "fullUrl": "urn:uuid:2b1743c0-089d-d354-0cbe-e548478fd580", + "resource": { + "resourceType": "ServiceRequest", + "id": "2b1743c0-089d-d354-0cbe-e548478fd580", + "status": "draft", + "intent": "filler-order", + "code": { + "coding": [ + { + "code": "42272-5", + "display": "XR Chest PA and Lateral", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "note": [ + { + "text": "Patient Instructions - wear loose comfortable clothes,keep metallic objects away and leave jewellery at home" + } + ], + "performer": [ + { + "reference": "Device/d8709d49-8f55-d198-44e8-2cf5ee983e90" + }, + { + "reference": "Practitioner/89f153f4-91d2-b658-0242-612129d35f06" + } + ], + "locationReference": [ + { + "reference": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/2b1743c0-089d-d354-0cbe-e548478fd580" + } + }, + { + "fullUrl": "urn:uuid:d8709d49-8f55-d198-44e8-2cf5ee983e90", + "resource": { + "resourceType": "Device", + "id": "d8709d49-8f55-d198-44e8-2cf5ee983e90", + "identifier": [ + { + "value": "1001", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ], + "deviceName": [ + { + "name": "XYZ X-Ray Machine", + "type": "model-name" + } + ], + "note": [ + { + "text": "Equipment booked for imaging" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/d8709d49-8f55-d198-44e8-2cf5ee983e90" + } + }, + { + "fullUrl": "urn:uuid:2b9be76c-a0f5-72ea-b684-51adaf2d95f6", + "resource": { + "resourceType": "Location", + "id": "2b9be76c-a0f5-72ea-b684-51adaf2d95f6", + "name": "DiagnosticUnit201", + "mode": "instance", + "description": "DiagnosticUnit201--Imaging Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for imaging" + ] + }, + "request": { + "method": "PUT", + "url": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + } + }, + { + "fullUrl": "urn:uuid:e36c1c9d-9008-4267-0e0f-e8b36ec2f208", + "resource": { + "resourceType": "Location", + "id": "e36c1c9d-9008-4267-0e0f-e8b36ec2f208", + "partOf": { + "reference": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + }, + "name": "Imaging Room 01", + "mode": "instance", + "description": "DiagnosticUnit201--Imaging Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for imaging" + ] + }, + "request": { + "method": "PUT", + "url": "Location/e36c1c9d-9008-4267-0e0f-e8b36ec2f208" + } + }, + { + "fullUrl": "urn:uuid:89f153f4-91d2-b658-0242-612129d35f06", + "resource": { + "resourceType": "Practitioner", + "id": "89f153f4-91d2-b658-0242-612129d35f06", + "identifier": [ + { + "value": "500" + } + ], + "name": [ + { + "family": "RT", + "given": [ + "Robert", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/89f153f4-91d2-b658-0242-612129d35f06" + } + }, + { + "fullUrl": "urn:uuid:82709fdd-4012-9faa-5ec3-cf75fd57a34c", + "resource": { + "resourceType": "Location", + "id": "82709fdd-4012-9faa-5ec3-cf75fd57a34c", + "name": "OPD12", + "mode": "instance", + "description": "OPD12--Room 55--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for checkup" + ] + }, + "request": { + "method": "PUT", + "url": "Location/82709fdd-4012-9faa-5ec3-cf75fd57a34c" + } + }, + { + "fullUrl": "urn:uuid:928bc54e-abd5-e128-504a-f02faf5598e6", + "resource": { + "resourceType": "Location", + "id": "928bc54e-abd5-e128-504a-f02faf5598e6", + "partOf": { + "reference": "Location/82709fdd-4012-9faa-5ec3-cf75fd57a34c" + }, + "name": "Room 55", + "mode": "instance", + "description": "OPD12--Room 55--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for checkup" + ] + }, + "request": { + "method": "PUT", + "url": "Location/928bc54e-abd5-e128-504a-f02faf5598e6" + } + }, + { + "fullUrl": "urn:uuid:a4177c1c-eb53-edd4-a0ee-1a55b986ea3b", + "resource": { + "resourceType": "Practitioner", + "id": "a4177c1c-eb53-edd4-a0ee-1a55b986ea3b", + "identifier": [ + { + "value": "600" + } + ], + "name": [ + { + "family": "GP", + "given": [ + "Linda", + "R" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/a4177c1c-eb53-edd4-a0ee-1a55b986ea3b" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S16/SIU-S16-01-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S16/SIU-S16-01-expected.json new file mode 100644 index 000000000..3e41b68fb --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S16/SIU-S16-01-expected.json @@ -0,0 +1,1419 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "1989-08-18T14:41:00+05:30", + "identifier": { + "value": "MSG00016" + }, + "id": "30435f80-02b6-8e6a-011f-03792aa30b3e", + "entry": [ + { + "fullUrl": "urn:uuid:01f8408f-d203-67a6-59cb-836f0c2f0114", + "resource": { + "resourceType": "MessageHeader", + "id": "01f8408f-d203-67a6-59cb-836f0c2f0114", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "S16", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "SIU^S16^SIU_S16" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/01f8408f-d203-67a6-59cb-836f0c2f0114" + } + }, + { + "fullUrl": "urn:uuid:09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "resource": { + "resourceType": "Provenance", + "id": "09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:44:06.903Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: SIU_S16.

" + }, + "occurredDateTime": "1989-08-18T14:41:00+05:30", + "recorded": "1989-08-18T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "SIU^S16^SIU_S16" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/12428005-5692-7537-f572-e47a16418f26" + } + } + ], + "target": [ + { + "reference": "Bundle/30435f80-02b6-8e6a-011f-03792aa30b3e" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/09e54df1-8856-96ca-cdbf-4bdbd94a26a3" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:12428005-5692-7537-f572-e47a16418f26", + "resource": { + "resourceType": "Device", + "id": "12428005-5692-7537-f572-e47a16418f26", + "identifier": [ + { + "value": "SCHApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/12428005-5692-7537-f572-e47a16418f26" + } + }, + { + "fullUrl": "urn:uuid:b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "resource": { + "resourceType": "Appointment", + "id": "b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "identifier": [ + { + "value": "12345", + "type": { + "coding": [ + { + "code": "PLAC", + "display": "Placer Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "36996", + "type": { + "coding": [ + { + "code": "FILL", + "display": "Filler Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "appointmentType": { + "coding": [ + { + "code": "EMERGENCY", + "display": "Emergency appointment", + "system": "http://terminology.hl7.org/CodeSystem/v2-0276" + } + ] + }, + "priority": 2, + "start": "2021-09-24T12:45:00+05:30", + "end": "2021-09-24T13:35:00+05:30", + "minutesDuration": 1, + "status": "cancelled", + "supportingInformation": [ + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + ], + "participant": [ + { + "actor": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "status": "accepted" + }, + { + "actor": { + "reference": "Device/0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00" + }, + "type": [ + { + "coding": [ + { + "code": "101", + "display": "Equipment", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "period": { + "start": "2021-09-24T12:45:00+05:30" + }, + "status": "declined" + }, + { + "actor": { + "reference": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + }, + "period": { + "start": "2021-09-24T12:45:00+05:30" + }, + "status": "declined" + }, + { + "actor": { + "reference": "Practitioner/cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb" + }, + "type": [ + { + "coding": [ + { + "code": "010", + "display": "Gastroenterologist", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "period": { + "start": "2021-09-24T12:45:00+05:30" + }, + "status": "declined" + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/377d8e6d-3ee4-7509-6f8b-6279da04eb6b" + } + ] + }, + "request": { + "method": "PUT", + "url": "Appointment/b7121f46-cf50-5cec-7cfb-5de8e42b82d2" + } + }, + { + "fullUrl": "urn:uuid:df03b003-6818-1abd-209e-0889025aad16", + "resource": { + "resourceType": "Organization", + "id": "df03b003-6818-1abd-209e-0889025aad16", + "identifier": [ + { + "value": "NPIID", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NPIID" + }, + { + "value": "urn:oid:2.16.840.1.113883.4.6", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/df03b003-6818-1abd-209e-0889025aad16" + } + }, + { + "fullUrl": "urn:uuid:6f540060-4f9a-5d13-45b3-da6a76e207a7", + "resource": { + "resourceType": "Practitioner", + "id": "6f540060-4f9a-5d13-45b3-da6a76e207a7", + "address": [ + { + "line": [ + "115 MAINSTREET" + ], + "city": "GOODTOWN", + "state": "KY", + "postalCode": "42010", + "country": "USA" + } + ], + "telecom": [ + { + "value": "(608)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9941339109", + "system": "urn:oid:2.16.840.1.113883.4.6", + "assigner": { + "reference": "Organization/df03b003-6818-1abd-209e-0889025aad16" + }, + "type": { + "coding": [ + { + "code": "NPI", + "display": "National provider identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Smith", + "given": [ + "Adam", + "Mellie" + ], + "suffix": [ + "Jr", + "MD", + "GP" + ], + "prefix": [ + "Dr" + ], + "use": "official", + "period": { + "start": "2010-01-15", + "end": "2020-01-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + { + "fullUrl": "urn:uuid:36effb10-f605-f388-c06c-90d22b315bd0", + "resource": { + "resourceType": "PractitionerRole", + "id": "36effb10-f605-f388-c06c-90d22b315bd0", + "code": [ + { + "coding": [ + { + "code": "placer-contact", + "display": "Placer Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + }, + { + "coding": [ + { + "code": "filler-contact", + "display": "Filler Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + ], + "practitioner": { + "reference": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + } + }, + { + "fullUrl": "urn:uuid:92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "resource": { + "resourceType": "Location", + "id": "92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "name": "FACILITY2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + }, + { + "fullUrl": "urn:uuid:4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "resource": { + "resourceType": "Location", + "id": "4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "partOf": { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + }, + "name": "BUILDING2", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + } + }, + { + "fullUrl": "urn:uuid:81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "resource": { + "resourceType": "Location", + "id": "81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf" + } + }, + { + "fullUrl": "urn:uuid:fb95e0b1-227c-8068-3e51-86c2df312f25", + "resource": { + "resourceType": "Practitioner", + "id": "fb95e0b1-227c-8068-3e51-86c2df312f25", + "telecom": [ + { + "value": "(610)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9" + } + ], + "name": [ + { + "family": "DENT", + "given": [ + "COREY" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + { + "fullUrl": "urn:uuid:f3c93626-c639-1507-76f0-945d762c11a8", + "resource": { + "resourceType": "PractitionerRole", + "id": "f3c93626-c639-1507-76f0-945d762c11a8", + "code": [ + { + "coding": [ + { + "code": "enterer", + "display": "Enterer", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + ], + "practitioner": { + "reference": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + }, + { + "fullUrl": "urn:uuid:5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "resource": { + "resourceType": "Location", + "id": "5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "name": "FACILITY3", + "identifier": [ + { + "value": "urn:oid:1.23", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:377d8e6d-3ee4-7509-6f8b-6279da04eb6b", + "resource": { + "resourceType": "ServiceRequest", + "id": "377d8e6d-3ee4-7509-6f8b-6279da04eb6b", + "status": "revoked", + "intent": "filler-order", + "orderDetail": [ + { + "coding": [ + { + "code": "5001", + "display": "EVIS X12 Video Colonoscope", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + }, + { + "coding": [ + { + "code": "5001", + "display": "EVIS X12 Video Colonoscope", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "occurrencePeriod": { + "start": "2021-09-24T12:45:00+05:30" + }, + "code": { + "coding": [ + { + "code": "76164006", + "display": "Biopsy of colon (procedure)", + "system": "http://snomed.info/sct" + }, + { + "code": "1212", + "display": "Biopsy" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "note": [ + { + "text": "Nursing staff instructions - Appointment discontinued due to equipment malfunction" + }, + { + "text": "Patient instructions - Appointment discontinued due to equipment malfunction" + } + ], + "performer": [ + { + "reference": "Device/0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00" + }, + { + "reference": "Practitioner/cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb" + } + ], + "locationReference": [ + { + "reference": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/377d8e6d-3ee4-7509-6f8b-6279da04eb6b" + } + }, + { + "fullUrl": "urn:uuid:0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00", + "resource": { + "resourceType": "Device", + "id": "0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00", + "identifier": [ + { + "value": "5001", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + }, + { + "value": "5002" + } + ], + "deviceName": [ + { + "name": "EVIS X12 Video Colonoscope", + "type": "model-name" + } + ], + "status": "active", + "note": [ + { + "text": "Equipment malfunction" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00" + } + }, + { + "fullUrl": "urn:uuid:b13417bd-d0fb-e50f-b65a-cd07396a0608", + "resource": { + "resourceType": "Location", + "id": "b13417bd-d0fb-e50f-b65a-cd07396a0608", + "name": "055", + "mode": "instance", + "description": "055--Room01--GH Clinic", + "type": [ + { + "coding": [ + { + "code": "C", + "display": "Clinic", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + } + ] + } + ], + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for next slot as appointment is discontinued" + ] + }, + "request": { + "method": "PUT", + "url": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + } + }, + { + "fullUrl": "urn:uuid:ee586d80-706a-5933-8500-a8026c48fb27", + "resource": { + "resourceType": "Location", + "id": "ee586d80-706a-5933-8500-a8026c48fb27", + "partOf": { + "reference": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + }, + "name": "Room01", + "mode": "instance", + "description": "055--Room01--GH Clinic", + "type": [ + { + "coding": [ + { + "code": "C", + "display": "Clinic", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + } + ] + } + ], + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for next slot as appointment is discontinued" + ] + }, + "request": { + "method": "PUT", + "url": "Location/ee586d80-706a-5933-8500-a8026c48fb27" + } + }, + { + "fullUrl": "urn:uuid:4b6f7358-191b-8623-f2f4-806a8a0babcf", + "resource": { + "resourceType": "Location", + "id": "4b6f7358-191b-8623-f2f4-806a8a0babcf", + "name": "GH Clinic", + "mode": "instance", + "description": "055--Room01--GH Clinic", + "type": [ + { + "coding": [ + { + "code": "C", + "display": "Clinic", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + } + ] + } + ], + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + }, + "alias": [ + "Location available for next slot as appointment is discontinued" + ] + }, + "request": { + "method": "PUT", + "url": "Location/4b6f7358-191b-8623-f2f4-806a8a0babcf" + } + }, + { + "fullUrl": "urn:uuid:cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb", + "resource": { + "resourceType": "Practitioner", + "id": "cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb", + "identifier": [ + { + "value": "1210" + } + ], + "name": [ + { + "family": "GE", + "given": [ + "Robert", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S16/SIU-S16-02-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S16/SIU-S16-02-expected.json new file mode 100644 index 000000000..3ebd03c82 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S16/SIU-S16-02-expected.json @@ -0,0 +1,1639 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2021-08-10T15:15:00+05:30", + "identifier": { + "value": "MSG00016" + }, + "id": "30435f80-02b6-8e6a-011f-03792aa30b3e", + "entry": [ + { + "fullUrl": "urn:uuid:01f8408f-d203-67a6-59cb-836f0c2f0114", + "resource": { + "resourceType": "MessageHeader", + "id": "01f8408f-d203-67a6-59cb-836f0c2f0114", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "S16", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "SIU^S16^SIU_S16" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/01f8408f-d203-67a6-59cb-836f0c2f0114" + } + }, + { + "fullUrl": "urn:uuid:09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "resource": { + "resourceType": "Provenance", + "id": "09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:44:32.016Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: SIU_S16.

" + }, + "occurredDateTime": "2021-08-10T15:15:00+05:30", + "recorded": "2021-08-10T15:15:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "SIU^S16^SIU_S16" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/12428005-5692-7537-f572-e47a16418f26" + } + } + ], + "target": [ + { + "reference": "Bundle/30435f80-02b6-8e6a-011f-03792aa30b3e" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/09e54df1-8856-96ca-cdbf-4bdbd94a26a3" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:12428005-5692-7537-f572-e47a16418f26", + "resource": { + "resourceType": "Device", + "id": "12428005-5692-7537-f572-e47a16418f26", + "identifier": [ + { + "value": "SCHApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/12428005-5692-7537-f572-e47a16418f26" + } + }, + { + "fullUrl": "urn:uuid:b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "resource": { + "resourceType": "Appointment", + "id": "b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "identifier": [ + { + "value": "12345", + "type": { + "coding": [ + { + "code": "PLAC", + "display": "Placer Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "36996", + "type": { + "coding": [ + { + "code": "FILL", + "display": "Filler Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "appointmentType": { + "coding": [ + { + "code": "CHECKUP", + "display": "A routine check-up, such as an annual physical", + "system": "http://terminology.hl7.org/CodeSystem/v2-0276" + } + ] + }, + "priority": 2, + "start": "2021-08-18T14:45:00+05:30", + "end": "2021-08-18T15:45:00+05:30", + "minutesDuration": 70, + "status": "cancelled", + "supportingInformation": [ + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + ], + "comment": "Appointment for annual checkup discontinued due to power failure at the facility.", + "participant": [ + { + "actor": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "status": "accepted" + }, + { + "actor": { + "reference": "Device/dd77839c-6623-a021-29ef-c04fd35460ca" + }, + "type": [ + { + "coding": [ + { + "code": "011", + "display": "Lab Equipment", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + }, + "status": "tentative" + }, + { + "actor": { + "reference": "Practitioner/9d928c63-6d1e-7fb7-fed9-b97b625dc5f8" + }, + "type": [ + { + "coding": [ + { + "code": "019", + "display": "Phlebotomist", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Device/d8709d49-8f55-d198-44e8-2cf5ee983e90" + }, + "type": [ + { + "coding": [ + { + "code": "015", + "display": "Imaging Equipment", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + }, + "status": "tentative" + }, + { + "actor": { + "reference": "Practitioner/89f153f4-91d2-b658-0242-612129d35f06" + }, + "type": [ + { + "coding": [ + { + "code": "021", + "display": "Radiology Technician", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Location/82709fdd-4012-9faa-5ec3-cf75fd57a34c" + }, + "status": "tentative" + }, + { + "actor": { + "reference": "Practitioner/a4177c1c-eb53-edd4-a0ee-1a55b986ea3b" + }, + "type": [ + { + "coding": [ + { + "code": "011", + "display": "General Practitioner", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/8ad3476e-03c9-158e-12d8-20de3070fce5" + }, + { + "reference": "ServiceRequest/2b1743c0-089d-d354-0cbe-e548478fd580" + } + ] + }, + "request": { + "method": "PUT", + "url": "Appointment/b7121f46-cf50-5cec-7cfb-5de8e42b82d2" + } + }, + { + "fullUrl": "urn:uuid:df03b003-6818-1abd-209e-0889025aad16", + "resource": { + "resourceType": "Organization", + "id": "df03b003-6818-1abd-209e-0889025aad16", + "identifier": [ + { + "value": "NPIID", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NPIID" + }, + { + "value": "urn:oid:2.16.840.1.113883.4.6", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/df03b003-6818-1abd-209e-0889025aad16" + } + }, + { + "fullUrl": "urn:uuid:6f540060-4f9a-5d13-45b3-da6a76e207a7", + "resource": { + "resourceType": "Practitioner", + "id": "6f540060-4f9a-5d13-45b3-da6a76e207a7", + "address": [ + { + "line": [ + "115 MAINSTREET" + ], + "city": "GOODTOWN", + "state": "KY", + "postalCode": "42010", + "country": "USA" + } + ], + "telecom": [ + { + "value": "(608)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9941339109", + "system": "urn:oid:2.16.840.1.113883.4.6", + "assigner": { + "reference": "Organization/df03b003-6818-1abd-209e-0889025aad16" + }, + "type": { + "coding": [ + { + "code": "NPI", + "display": "National provider identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Smith", + "given": [ + "Adam", + "Mellie" + ], + "suffix": [ + "Jr", + "MD", + "GP" + ], + "prefix": [ + "Dr" + ], + "use": "official", + "period": { + "start": "2010-01-15", + "end": "2020-01-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + { + "fullUrl": "urn:uuid:36effb10-f605-f388-c06c-90d22b315bd0", + "resource": { + "resourceType": "PractitionerRole", + "id": "36effb10-f605-f388-c06c-90d22b315bd0", + "code": [ + { + "coding": [ + { + "code": "placer-contact", + "display": "Placer Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + }, + { + "coding": [ + { + "code": "filler-contact", + "display": "Filler Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + ], + "practitioner": { + "reference": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + } + }, + { + "fullUrl": "urn:uuid:92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "resource": { + "resourceType": "Location", + "id": "92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "name": "FACILITY2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + }, + { + "fullUrl": "urn:uuid:4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "resource": { + "resourceType": "Location", + "id": "4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "partOf": { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + }, + "name": "BUILDING2", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + } + }, + { + "fullUrl": "urn:uuid:81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "resource": { + "resourceType": "Location", + "id": "81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf" + } + }, + { + "fullUrl": "urn:uuid:fb95e0b1-227c-8068-3e51-86c2df312f25", + "resource": { + "resourceType": "Practitioner", + "id": "fb95e0b1-227c-8068-3e51-86c2df312f25", + "telecom": [ + { + "value": "(610)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9" + } + ], + "name": [ + { + "family": "DENT", + "given": [ + "COREY" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + { + "fullUrl": "urn:uuid:f3c93626-c639-1507-76f0-945d762c11a8", + "resource": { + "resourceType": "PractitionerRole", + "id": "f3c93626-c639-1507-76f0-945d762c11a8", + "code": [ + { + "coding": [ + { + "code": "enterer", + "display": "Enterer", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + ], + "practitioner": { + "reference": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + }, + { + "fullUrl": "urn:uuid:5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "resource": { + "resourceType": "Location", + "id": "5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "name": "FACILITY3", + "identifier": [ + { + "value": "urn:oid:1.23", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:8ad3476e-03c9-158e-12d8-20de3070fce5", + "resource": { + "resourceType": "ServiceRequest", + "id": "8ad3476e-03c9-158e-12d8-20de3070fce5", + "status": "revoked", + "intent": "filler-order", + "code": { + "coding": [ + { + "code": "58410-2", + "display": "CBC Panel-Blood by Automated Count", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "note": [ + { + "text": "Fasting for Blood sugar before appointment" + } + ], + "performer": [ + { + "reference": "Device/dd77839c-6623-a021-29ef-c04fd35460ca" + }, + { + "reference": "Practitioner/9d928c63-6d1e-7fb7-fed9-b97b625dc5f8" + } + ], + "locationReference": [ + { + "reference": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/8ad3476e-03c9-158e-12d8-20de3070fce5" + } + }, + { + "fullUrl": "urn:uuid:dd77839c-6623-a021-29ef-c04fd35460ca", + "resource": { + "resourceType": "Device", + "id": "dd77839c-6623-a021-29ef-c04fd35460ca", + "identifier": [ + { + "value": "123", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ], + "deviceName": [ + { + "name": "ABC Cell Counter", + "type": "model-name" + } + ], + "note": [ + { + "text": "Equipment booked for lab test" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/dd77839c-6623-a021-29ef-c04fd35460ca" + } + }, + { + "fullUrl": "urn:uuid:bc5a0b18-cce5-ddbc-8e45-a09c736af725", + "resource": { + "resourceType": "Location", + "id": "bc5a0b18-cce5-ddbc-8e45-a09c736af725", + "name": "LabUnit101", + "mode": "instance", + "description": "LabUnit101--Lab Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for lab test" + ] + }, + "request": { + "method": "PUT", + "url": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + } + }, + { + "fullUrl": "urn:uuid:a86368de-48ac-12e3-05e4-6b2da7fa4853", + "resource": { + "resourceType": "Location", + "id": "a86368de-48ac-12e3-05e4-6b2da7fa4853", + "partOf": { + "reference": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + }, + "name": "Lab Room 01", + "mode": "instance", + "description": "LabUnit101--Lab Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for lab test" + ] + }, + "request": { + "method": "PUT", + "url": "Location/a86368de-48ac-12e3-05e4-6b2da7fa4853" + } + }, + { + "fullUrl": "urn:uuid:9d04f983-a391-647a-07a8-e8bf59f77de8", + "resource": { + "resourceType": "Location", + "id": "9d04f983-a391-647a-07a8-e8bf59f77de8", + "name": "GHH Hospital", + "mode": "instance", + "description": "OPD12--Room 55--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + }, + "alias": [ + "Location available for lab test", + "Location available for imaging", + "Location available for checkup" + ] + }, + "request": { + "method": "PUT", + "url": "Location/9d04f983-a391-647a-07a8-e8bf59f77de8" + } + }, + { + "fullUrl": "urn:uuid:9d928c63-6d1e-7fb7-fed9-b97b625dc5f8", + "resource": { + "resourceType": "Practitioner", + "id": "9d928c63-6d1e-7fb7-fed9-b97b625dc5f8", + "identifier": [ + { + "value": "400" + } + ], + "name": [ + { + "family": "PB", + "given": [ + "Tim", + "G" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/9d928c63-6d1e-7fb7-fed9-b97b625dc5f8" + } + }, + { + "fullUrl": "urn:uuid:2b1743c0-089d-d354-0cbe-e548478fd580", + "resource": { + "resourceType": "ServiceRequest", + "id": "2b1743c0-089d-d354-0cbe-e548478fd580", + "status": "revoked", + "intent": "filler-order", + "code": { + "coding": [ + { + "code": "42272-5", + "display": "XR Chest PA and Lateral", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "note": [ + { + "text": "Patient Instructions - wear loose comfortable clothes,keep metallic objects away and leave jewellery at home" + } + ], + "performer": [ + { + "reference": "Device/d8709d49-8f55-d198-44e8-2cf5ee983e90" + }, + { + "reference": "Practitioner/89f153f4-91d2-b658-0242-612129d35f06" + } + ], + "locationReference": [ + { + "reference": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/2b1743c0-089d-d354-0cbe-e548478fd580" + } + }, + { + "fullUrl": "urn:uuid:d8709d49-8f55-d198-44e8-2cf5ee983e90", + "resource": { + "resourceType": "Device", + "id": "d8709d49-8f55-d198-44e8-2cf5ee983e90", + "identifier": [ + { + "value": "1001", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ], + "deviceName": [ + { + "name": "XYZ X-Ray Machine", + "type": "model-name" + } + ], + "note": [ + { + "text": "Equipment booked for imaging" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/d8709d49-8f55-d198-44e8-2cf5ee983e90" + } + }, + { + "fullUrl": "urn:uuid:2b9be76c-a0f5-72ea-b684-51adaf2d95f6", + "resource": { + "resourceType": "Location", + "id": "2b9be76c-a0f5-72ea-b684-51adaf2d95f6", + "name": "DiagnosticUnit201", + "mode": "instance", + "description": "DiagnosticUnit201--Imaging Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for imaging" + ] + }, + "request": { + "method": "PUT", + "url": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + } + }, + { + "fullUrl": "urn:uuid:e36c1c9d-9008-4267-0e0f-e8b36ec2f208", + "resource": { + "resourceType": "Location", + "id": "e36c1c9d-9008-4267-0e0f-e8b36ec2f208", + "partOf": { + "reference": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + }, + "name": "Imaging Room 01", + "mode": "instance", + "description": "DiagnosticUnit201--Imaging Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for imaging" + ] + }, + "request": { + "method": "PUT", + "url": "Location/e36c1c9d-9008-4267-0e0f-e8b36ec2f208" + } + }, + { + "fullUrl": "urn:uuid:89f153f4-91d2-b658-0242-612129d35f06", + "resource": { + "resourceType": "Practitioner", + "id": "89f153f4-91d2-b658-0242-612129d35f06", + "identifier": [ + { + "value": "500" + } + ], + "name": [ + { + "family": "RT", + "given": [ + "Robert", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/89f153f4-91d2-b658-0242-612129d35f06" + } + }, + { + "fullUrl": "urn:uuid:82709fdd-4012-9faa-5ec3-cf75fd57a34c", + "resource": { + "resourceType": "Location", + "id": "82709fdd-4012-9faa-5ec3-cf75fd57a34c", + "name": "OPD12", + "mode": "instance", + "description": "OPD12--Room 55--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for checkup" + ] + }, + "request": { + "method": "PUT", + "url": "Location/82709fdd-4012-9faa-5ec3-cf75fd57a34c" + } + }, + { + "fullUrl": "urn:uuid:928bc54e-abd5-e128-504a-f02faf5598e6", + "resource": { + "resourceType": "Location", + "id": "928bc54e-abd5-e128-504a-f02faf5598e6", + "partOf": { + "reference": "Location/82709fdd-4012-9faa-5ec3-cf75fd57a34c" + }, + "name": "Room 55", + "mode": "instance", + "description": "OPD12--Room 55--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for checkup" + ] + }, + "request": { + "method": "PUT", + "url": "Location/928bc54e-abd5-e128-504a-f02faf5598e6" + } + }, + { + "fullUrl": "urn:uuid:a4177c1c-eb53-edd4-a0ee-1a55b986ea3b", + "resource": { + "resourceType": "Practitioner", + "id": "a4177c1c-eb53-edd4-a0ee-1a55b986ea3b", + "identifier": [ + { + "value": "600" + } + ], + "name": [ + { + "family": "GP", + "given": [ + "Linda", + "R" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/a4177c1c-eb53-edd4-a0ee-1a55b986ea3b" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S17/SIU-S17-01-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S17/SIU-S17-01-expected.json new file mode 100644 index 000000000..5404fa40b --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S17/SIU-S17-01-expected.json @@ -0,0 +1,1419 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2021-09-23T14:41:00+05:30", + "identifier": { + "value": "MSG00017" + }, + "id": "93cae168-bbbd-0e21-74a8-0ae7f1136194", + "entry": [ + { + "fullUrl": "urn:uuid:7f71e432-b4da-bdfa-b9c5-d85ff83c74e7", + "resource": { + "resourceType": "MessageHeader", + "id": "7f71e432-b4da-bdfa-b9c5-d85ff83c74e7", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "S17", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "SIU^S17^SIU_S17" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/7f71e432-b4da-bdfa-b9c5-d85ff83c74e7" + } + }, + { + "fullUrl": "urn:uuid:09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "resource": { + "resourceType": "Provenance", + "id": "09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:45:32.192Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: SIU_S17.

" + }, + "occurredDateTime": "2021-09-23T14:41:00+05:30", + "recorded": "2021-09-23T14:41:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "SIU^S17^SIU_S17" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/12428005-5692-7537-f572-e47a16418f26" + } + } + ], + "target": [ + { + "reference": "Bundle/93cae168-bbbd-0e21-74a8-0ae7f1136194" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/09e54df1-8856-96ca-cdbf-4bdbd94a26a3" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:12428005-5692-7537-f572-e47a16418f26", + "resource": { + "resourceType": "Device", + "id": "12428005-5692-7537-f572-e47a16418f26", + "identifier": [ + { + "value": "SCHApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/12428005-5692-7537-f572-e47a16418f26" + } + }, + { + "fullUrl": "urn:uuid:b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "resource": { + "resourceType": "Appointment", + "id": "b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "identifier": [ + { + "value": "12345", + "type": { + "coding": [ + { + "code": "PLAC", + "display": "Placer Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "36996", + "type": { + "coding": [ + { + "code": "FILL", + "display": "Filler Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "appointmentType": { + "coding": [ + { + "code": "EMERGENCY", + "display": "Emergency appointment", + "system": "http://terminology.hl7.org/CodeSystem/v2-0276" + } + ] + }, + "priority": 2, + "start": "2021-09-24T12:45:00+05:30", + "end": "2021-09-24T13:35:00+05:30", + "minutesDuration": 1, + "status": "entered-in-error", + "supportingInformation": [ + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + ], + "participant": [ + { + "actor": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "status": "accepted" + }, + { + "actor": { + "reference": "Device/0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00" + }, + "type": [ + { + "coding": [ + { + "code": "101", + "display": "Equipment", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "period": { + "start": "2021-09-24T12:45:00+05:30" + }, + "status": "declined" + }, + { + "actor": { + "reference": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + }, + "period": { + "start": "2021-09-24T12:45:00+05:30" + }, + "status": "declined" + }, + { + "actor": { + "reference": "Practitioner/cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb" + }, + "type": [ + { + "coding": [ + { + "code": "010", + "display": "Gastroenterologist", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "period": { + "start": "2021-09-24T12:45:00+05:30" + }, + "status": "declined" + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/377d8e6d-3ee4-7509-6f8b-6279da04eb6b" + } + ] + }, + "request": { + "method": "PUT", + "url": "Appointment/b7121f46-cf50-5cec-7cfb-5de8e42b82d2" + } + }, + { + "fullUrl": "urn:uuid:df03b003-6818-1abd-209e-0889025aad16", + "resource": { + "resourceType": "Organization", + "id": "df03b003-6818-1abd-209e-0889025aad16", + "identifier": [ + { + "value": "NPIID", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NPIID" + }, + { + "value": "urn:oid:2.16.840.1.113883.4.6", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/df03b003-6818-1abd-209e-0889025aad16" + } + }, + { + "fullUrl": "urn:uuid:6f540060-4f9a-5d13-45b3-da6a76e207a7", + "resource": { + "resourceType": "Practitioner", + "id": "6f540060-4f9a-5d13-45b3-da6a76e207a7", + "address": [ + { + "line": [ + "115 MAINSTREET" + ], + "city": "GOODTOWN", + "state": "KY", + "postalCode": "42010", + "country": "USA" + } + ], + "telecom": [ + { + "value": "(608)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9941339109", + "system": "urn:oid:2.16.840.1.113883.4.6", + "assigner": { + "reference": "Organization/df03b003-6818-1abd-209e-0889025aad16" + }, + "type": { + "coding": [ + { + "code": "NPI", + "display": "National provider identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Smith", + "given": [ + "Adam", + "Mellie" + ], + "suffix": [ + "Jr", + "MD", + "GP" + ], + "prefix": [ + "Dr" + ], + "use": "official", + "period": { + "start": "2010-01-15", + "end": "2020-01-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + { + "fullUrl": "urn:uuid:36effb10-f605-f388-c06c-90d22b315bd0", + "resource": { + "resourceType": "PractitionerRole", + "id": "36effb10-f605-f388-c06c-90d22b315bd0", + "code": [ + { + "coding": [ + { + "code": "placer-contact", + "display": "Placer Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + }, + { + "coding": [ + { + "code": "filler-contact", + "display": "Filler Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + ], + "practitioner": { + "reference": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + } + }, + { + "fullUrl": "urn:uuid:92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "resource": { + "resourceType": "Location", + "id": "92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "name": "FACILITY2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + }, + { + "fullUrl": "urn:uuid:4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "resource": { + "resourceType": "Location", + "id": "4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "partOf": { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + }, + "name": "BUILDING2", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + } + }, + { + "fullUrl": "urn:uuid:81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "resource": { + "resourceType": "Location", + "id": "81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf" + } + }, + { + "fullUrl": "urn:uuid:fb95e0b1-227c-8068-3e51-86c2df312f25", + "resource": { + "resourceType": "Practitioner", + "id": "fb95e0b1-227c-8068-3e51-86c2df312f25", + "telecom": [ + { + "value": "(610)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9" + } + ], + "name": [ + { + "family": "DENT", + "given": [ + "COREY" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + { + "fullUrl": "urn:uuid:f3c93626-c639-1507-76f0-945d762c11a8", + "resource": { + "resourceType": "PractitionerRole", + "id": "f3c93626-c639-1507-76f0-945d762c11a8", + "code": [ + { + "coding": [ + { + "code": "enterer", + "display": "Enterer", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + ], + "practitioner": { + "reference": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + }, + { + "fullUrl": "urn:uuid:5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "resource": { + "resourceType": "Location", + "id": "5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "name": "FACILITY3", + "identifier": [ + { + "value": "urn:oid:1.23", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:377d8e6d-3ee4-7509-6f8b-6279da04eb6b", + "resource": { + "resourceType": "ServiceRequest", + "id": "377d8e6d-3ee4-7509-6f8b-6279da04eb6b", + "status": "entered-in-error", + "intent": "filler-order", + "orderDetail": [ + { + "coding": [ + { + "code": "5001", + "display": "EVIS X12 Video Colonoscope", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + }, + { + "coding": [ + { + "code": "5001", + "display": "EVIS X12 Video Colonoscope", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "occurrencePeriod": { + "start": "2021-09-24T12:45:00+05:30" + }, + "code": { + "coding": [ + { + "code": "76164006", + "display": "Biopsy of colon (procedure)", + "system": "http://snomed.info/sct" + }, + { + "code": "1212", + "display": "Biopsy" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "note": [ + { + "text": "Nursing staff instructions - Appointment deleted" + }, + { + "text": "Patient instructions - Appointment deleted" + } + ], + "performer": [ + { + "reference": "Device/0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00" + }, + { + "reference": "Practitioner/cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb" + } + ], + "locationReference": [ + { + "reference": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/377d8e6d-3ee4-7509-6f8b-6279da04eb6b" + } + }, + { + "fullUrl": "urn:uuid:0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00", + "resource": { + "resourceType": "Device", + "id": "0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00", + "identifier": [ + { + "value": "5001", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + }, + { + "value": "5002" + } + ], + "deviceName": [ + { + "name": "EVIS X12 Video Colonoscope", + "type": "model-name" + } + ], + "status": "active", + "note": [ + { + "text": "Equipment available" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00" + } + }, + { + "fullUrl": "urn:uuid:b13417bd-d0fb-e50f-b65a-cd07396a0608", + "resource": { + "resourceType": "Location", + "id": "b13417bd-d0fb-e50f-b65a-cd07396a0608", + "name": "055", + "mode": "instance", + "description": "055--Room01--GH Clinic", + "type": [ + { + "coding": [ + { + "code": "C", + "display": "Clinic", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + } + ] + } + ], + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for next slot as appointment is deleted" + ] + }, + "request": { + "method": "PUT", + "url": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + } + }, + { + "fullUrl": "urn:uuid:ee586d80-706a-5933-8500-a8026c48fb27", + "resource": { + "resourceType": "Location", + "id": "ee586d80-706a-5933-8500-a8026c48fb27", + "partOf": { + "reference": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + }, + "name": "Room01", + "mode": "instance", + "description": "055--Room01--GH Clinic", + "type": [ + { + "coding": [ + { + "code": "C", + "display": "Clinic", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + } + ] + } + ], + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for next slot as appointment is deleted" + ] + }, + "request": { + "method": "PUT", + "url": "Location/ee586d80-706a-5933-8500-a8026c48fb27" + } + }, + { + "fullUrl": "urn:uuid:4b6f7358-191b-8623-f2f4-806a8a0babcf", + "resource": { + "resourceType": "Location", + "id": "4b6f7358-191b-8623-f2f4-806a8a0babcf", + "name": "GH Clinic", + "mode": "instance", + "description": "055--Room01--GH Clinic", + "type": [ + { + "coding": [ + { + "code": "C", + "display": "Clinic", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + } + ] + } + ], + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + }, + "alias": [ + "Location available for next slot as appointment is deleted" + ] + }, + "request": { + "method": "PUT", + "url": "Location/4b6f7358-191b-8623-f2f4-806a8a0babcf" + } + }, + { + "fullUrl": "urn:uuid:cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb", + "resource": { + "resourceType": "Practitioner", + "id": "cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb", + "identifier": [ + { + "value": "1210" + } + ], + "name": [ + { + "family": "GE", + "given": [ + "Robert", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S17/SIU-S17-02-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S17/SIU-S17-02-expected.json new file mode 100644 index 000000000..28bb2671c --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S17/SIU-S17-02-expected.json @@ -0,0 +1,1639 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2021-08-10T13:45:00+05:30", + "identifier": { + "value": "MSG00017" + }, + "id": "93cae168-bbbd-0e21-74a8-0ae7f1136194", + "entry": [ + { + "fullUrl": "urn:uuid:7f71e432-b4da-bdfa-b9c5-d85ff83c74e7", + "resource": { + "resourceType": "MessageHeader", + "id": "7f71e432-b4da-bdfa-b9c5-d85ff83c74e7", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "S17", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "SIU^S17^SIU_S17" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/7f71e432-b4da-bdfa-b9c5-d85ff83c74e7" + } + }, + { + "fullUrl": "urn:uuid:09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "resource": { + "resourceType": "Provenance", + "id": "09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:45:54.523Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: SIU_S17.

" + }, + "occurredDateTime": "2021-08-10T13:45:00+05:30", + "recorded": "2021-08-10T13:45:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "SIU^S17^SIU_S17" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/12428005-5692-7537-f572-e47a16418f26" + } + } + ], + "target": [ + { + "reference": "Bundle/93cae168-bbbd-0e21-74a8-0ae7f1136194" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/09e54df1-8856-96ca-cdbf-4bdbd94a26a3" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:12428005-5692-7537-f572-e47a16418f26", + "resource": { + "resourceType": "Device", + "id": "12428005-5692-7537-f572-e47a16418f26", + "identifier": [ + { + "value": "SCHApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/12428005-5692-7537-f572-e47a16418f26" + } + }, + { + "fullUrl": "urn:uuid:b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "resource": { + "resourceType": "Appointment", + "id": "b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "identifier": [ + { + "value": "12345", + "type": { + "coding": [ + { + "code": "PLAC", + "display": "Placer Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "36996", + "type": { + "coding": [ + { + "code": "FILL", + "display": "Filler Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "appointmentType": { + "coding": [ + { + "code": "CHECKUP", + "display": "A routine check-up, such as an annual physical", + "system": "http://terminology.hl7.org/CodeSystem/v2-0276" + } + ] + }, + "priority": 2, + "start": "2021-08-18T14:45:00+05:30", + "end": "2021-08-18T15:45:00+05:30", + "minutesDuration": 70, + "status": "entered-in-error", + "supportingInformation": [ + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + ], + "comment": "Appointment for annual checkup deleted as it was assigned to wrong patient.", + "participant": [ + { + "actor": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "status": "accepted" + }, + { + "actor": { + "reference": "Device/dd77839c-6623-a021-29ef-c04fd35460ca" + }, + "type": [ + { + "coding": [ + { + "code": "011", + "display": "Lab Equipment", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + }, + "status": "tentative" + }, + { + "actor": { + "reference": "Practitioner/9d928c63-6d1e-7fb7-fed9-b97b625dc5f8" + }, + "type": [ + { + "coding": [ + { + "code": "019", + "display": "Phlebotomist", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Device/d8709d49-8f55-d198-44e8-2cf5ee983e90" + }, + "type": [ + { + "coding": [ + { + "code": "015", + "display": "Imaging Equipment", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + }, + "status": "tentative" + }, + { + "actor": { + "reference": "Practitioner/89f153f4-91d2-b658-0242-612129d35f06" + }, + "type": [ + { + "coding": [ + { + "code": "021", + "display": "Radiology Technician", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Location/82709fdd-4012-9faa-5ec3-cf75fd57a34c" + }, + "status": "tentative" + }, + { + "actor": { + "reference": "Practitioner/a4177c1c-eb53-edd4-a0ee-1a55b986ea3b" + }, + "type": [ + { + "coding": [ + { + "code": "011", + "display": "General Practitioner", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/8ad3476e-03c9-158e-12d8-20de3070fce5" + }, + { + "reference": "ServiceRequest/2b1743c0-089d-d354-0cbe-e548478fd580" + } + ] + }, + "request": { + "method": "PUT", + "url": "Appointment/b7121f46-cf50-5cec-7cfb-5de8e42b82d2" + } + }, + { + "fullUrl": "urn:uuid:df03b003-6818-1abd-209e-0889025aad16", + "resource": { + "resourceType": "Organization", + "id": "df03b003-6818-1abd-209e-0889025aad16", + "identifier": [ + { + "value": "NPIID", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NPIID" + }, + { + "value": "urn:oid:2.16.840.1.113883.4.6", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/df03b003-6818-1abd-209e-0889025aad16" + } + }, + { + "fullUrl": "urn:uuid:6f540060-4f9a-5d13-45b3-da6a76e207a7", + "resource": { + "resourceType": "Practitioner", + "id": "6f540060-4f9a-5d13-45b3-da6a76e207a7", + "address": [ + { + "line": [ + "115 MAINSTREET" + ], + "city": "GOODTOWN", + "state": "KY", + "postalCode": "42010", + "country": "USA" + } + ], + "telecom": [ + { + "value": "(608)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9941339109", + "system": "urn:oid:2.16.840.1.113883.4.6", + "assigner": { + "reference": "Organization/df03b003-6818-1abd-209e-0889025aad16" + }, + "type": { + "coding": [ + { + "code": "NPI", + "display": "National provider identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Smith", + "given": [ + "Adam", + "Mellie" + ], + "suffix": [ + "Jr", + "MD", + "GP" + ], + "prefix": [ + "Dr" + ], + "use": "official", + "period": { + "start": "2010-01-15", + "end": "2020-01-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + { + "fullUrl": "urn:uuid:36effb10-f605-f388-c06c-90d22b315bd0", + "resource": { + "resourceType": "PractitionerRole", + "id": "36effb10-f605-f388-c06c-90d22b315bd0", + "code": [ + { + "coding": [ + { + "code": "placer-contact", + "display": "Placer Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + }, + { + "coding": [ + { + "code": "filler-contact", + "display": "Filler Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + ], + "practitioner": { + "reference": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + } + }, + { + "fullUrl": "urn:uuid:92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "resource": { + "resourceType": "Location", + "id": "92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "name": "FACILITY2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + }, + { + "fullUrl": "urn:uuid:4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "resource": { + "resourceType": "Location", + "id": "4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "partOf": { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + }, + "name": "BUILDING2", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + } + }, + { + "fullUrl": "urn:uuid:81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "resource": { + "resourceType": "Location", + "id": "81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf" + } + }, + { + "fullUrl": "urn:uuid:fb95e0b1-227c-8068-3e51-86c2df312f25", + "resource": { + "resourceType": "Practitioner", + "id": "fb95e0b1-227c-8068-3e51-86c2df312f25", + "telecom": [ + { + "value": "(610)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9" + } + ], + "name": [ + { + "family": "DENT", + "given": [ + "COREY" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + { + "fullUrl": "urn:uuid:f3c93626-c639-1507-76f0-945d762c11a8", + "resource": { + "resourceType": "PractitionerRole", + "id": "f3c93626-c639-1507-76f0-945d762c11a8", + "code": [ + { + "coding": [ + { + "code": "enterer", + "display": "Enterer", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + ], + "practitioner": { + "reference": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + }, + { + "fullUrl": "urn:uuid:5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "resource": { + "resourceType": "Location", + "id": "5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "name": "FACILITY3", + "identifier": [ + { + "value": "urn:oid:1.23", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID566", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:8ad3476e-03c9-158e-12d8-20de3070fce5", + "resource": { + "resourceType": "ServiceRequest", + "id": "8ad3476e-03c9-158e-12d8-20de3070fce5", + "status": "entered-in-error", + "intent": "filler-order", + "code": { + "coding": [ + { + "code": "58410-2", + "display": "CBC Panel-Blood by Automated Count", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "note": [ + { + "text": "Fasting for Blood sugar before appointment" + } + ], + "performer": [ + { + "reference": "Device/dd77839c-6623-a021-29ef-c04fd35460ca" + }, + { + "reference": "Practitioner/9d928c63-6d1e-7fb7-fed9-b97b625dc5f8" + } + ], + "locationReference": [ + { + "reference": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/8ad3476e-03c9-158e-12d8-20de3070fce5" + } + }, + { + "fullUrl": "urn:uuid:dd77839c-6623-a021-29ef-c04fd35460ca", + "resource": { + "resourceType": "Device", + "id": "dd77839c-6623-a021-29ef-c04fd35460ca", + "identifier": [ + { + "value": "123", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ], + "deviceName": [ + { + "name": "ABC Cell Counter", + "type": "model-name" + } + ], + "note": [ + { + "text": "Equipment booked for lab test" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/dd77839c-6623-a021-29ef-c04fd35460ca" + } + }, + { + "fullUrl": "urn:uuid:bc5a0b18-cce5-ddbc-8e45-a09c736af725", + "resource": { + "resourceType": "Location", + "id": "bc5a0b18-cce5-ddbc-8e45-a09c736af725", + "name": "LabUnit101", + "mode": "instance", + "description": "LabUnit101--Lab Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for lab test" + ] + }, + "request": { + "method": "PUT", + "url": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + } + }, + { + "fullUrl": "urn:uuid:a86368de-48ac-12e3-05e4-6b2da7fa4853", + "resource": { + "resourceType": "Location", + "id": "a86368de-48ac-12e3-05e4-6b2da7fa4853", + "partOf": { + "reference": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + }, + "name": "Lab Room 01", + "mode": "instance", + "description": "LabUnit101--Lab Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for lab test" + ] + }, + "request": { + "method": "PUT", + "url": "Location/a86368de-48ac-12e3-05e4-6b2da7fa4853" + } + }, + { + "fullUrl": "urn:uuid:9d04f983-a391-647a-07a8-e8bf59f77de8", + "resource": { + "resourceType": "Location", + "id": "9d04f983-a391-647a-07a8-e8bf59f77de8", + "name": "GHH Hospital", + "mode": "instance", + "description": "OPD12--Room 55--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + }, + "alias": [ + "Location available for lab test", + "Location available for imaging", + "Location available for checkup" + ] + }, + "request": { + "method": "PUT", + "url": "Location/9d04f983-a391-647a-07a8-e8bf59f77de8" + } + }, + { + "fullUrl": "urn:uuid:9d928c63-6d1e-7fb7-fed9-b97b625dc5f8", + "resource": { + "resourceType": "Practitioner", + "id": "9d928c63-6d1e-7fb7-fed9-b97b625dc5f8", + "identifier": [ + { + "value": "400" + } + ], + "name": [ + { + "family": "PB", + "given": [ + "Tim", + "G" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/9d928c63-6d1e-7fb7-fed9-b97b625dc5f8" + } + }, + { + "fullUrl": "urn:uuid:2b1743c0-089d-d354-0cbe-e548478fd580", + "resource": { + "resourceType": "ServiceRequest", + "id": "2b1743c0-089d-d354-0cbe-e548478fd580", + "status": "entered-in-error", + "intent": "filler-order", + "code": { + "coding": [ + { + "code": "42272-5", + "display": "XR Chest PA and Lateral", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "note": [ + { + "text": "Patient Instructions - wear loose comfortable clothes,keep metallic objects away and leave jewellery at home" + } + ], + "performer": [ + { + "reference": "Device/d8709d49-8f55-d198-44e8-2cf5ee983e90" + }, + { + "reference": "Practitioner/89f153f4-91d2-b658-0242-612129d35f06" + } + ], + "locationReference": [ + { + "reference": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/2b1743c0-089d-d354-0cbe-e548478fd580" + } + }, + { + "fullUrl": "urn:uuid:d8709d49-8f55-d198-44e8-2cf5ee983e90", + "resource": { + "resourceType": "Device", + "id": "d8709d49-8f55-d198-44e8-2cf5ee983e90", + "identifier": [ + { + "value": "1001", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ], + "deviceName": [ + { + "name": "XYZ X-Ray Machine", + "type": "model-name" + } + ], + "note": [ + { + "text": "Equipment booked for imaging" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/d8709d49-8f55-d198-44e8-2cf5ee983e90" + } + }, + { + "fullUrl": "urn:uuid:2b9be76c-a0f5-72ea-b684-51adaf2d95f6", + "resource": { + "resourceType": "Location", + "id": "2b9be76c-a0f5-72ea-b684-51adaf2d95f6", + "name": "DiagnosticUnit201", + "mode": "instance", + "description": "DiagnosticUnit201--Imaging Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for imaging" + ] + }, + "request": { + "method": "PUT", + "url": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + } + }, + { + "fullUrl": "urn:uuid:e36c1c9d-9008-4267-0e0f-e8b36ec2f208", + "resource": { + "resourceType": "Location", + "id": "e36c1c9d-9008-4267-0e0f-e8b36ec2f208", + "partOf": { + "reference": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + }, + "name": "Imaging Room 01", + "mode": "instance", + "description": "DiagnosticUnit201--Imaging Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for imaging" + ] + }, + "request": { + "method": "PUT", + "url": "Location/e36c1c9d-9008-4267-0e0f-e8b36ec2f208" + } + }, + { + "fullUrl": "urn:uuid:89f153f4-91d2-b658-0242-612129d35f06", + "resource": { + "resourceType": "Practitioner", + "id": "89f153f4-91d2-b658-0242-612129d35f06", + "identifier": [ + { + "value": "500" + } + ], + "name": [ + { + "family": "RT", + "given": [ + "Robert", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/89f153f4-91d2-b658-0242-612129d35f06" + } + }, + { + "fullUrl": "urn:uuid:82709fdd-4012-9faa-5ec3-cf75fd57a34c", + "resource": { + "resourceType": "Location", + "id": "82709fdd-4012-9faa-5ec3-cf75fd57a34c", + "name": "OPD12", + "mode": "instance", + "description": "OPD12--Room 55--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for checkup" + ] + }, + "request": { + "method": "PUT", + "url": "Location/82709fdd-4012-9faa-5ec3-cf75fd57a34c" + } + }, + { + "fullUrl": "urn:uuid:928bc54e-abd5-e128-504a-f02faf5598e6", + "resource": { + "resourceType": "Location", + "id": "928bc54e-abd5-e128-504a-f02faf5598e6", + "partOf": { + "reference": "Location/82709fdd-4012-9faa-5ec3-cf75fd57a34c" + }, + "name": "Room 55", + "mode": "instance", + "description": "OPD12--Room 55--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for checkup" + ] + }, + "request": { + "method": "PUT", + "url": "Location/928bc54e-abd5-e128-504a-f02faf5598e6" + } + }, + { + "fullUrl": "urn:uuid:a4177c1c-eb53-edd4-a0ee-1a55b986ea3b", + "resource": { + "resourceType": "Practitioner", + "id": "a4177c1c-eb53-edd4-a0ee-1a55b986ea3b", + "identifier": [ + { + "value": "600" + } + ], + "name": [ + { + "family": "GP", + "given": [ + "Linda", + "R" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/a4177c1c-eb53-edd4-a0ee-1a55b986ea3b" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S26/SIU-S26-01-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S26/SIU-S26-01-expected.json new file mode 100644 index 000000000..5cb07b512 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S26/SIU-S26-01-expected.json @@ -0,0 +1,1416 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2021-09-24T13:15:00+05:30", + "identifier": { + "value": "MSG00026" + }, + "id": "6ce25f29-49da-3ad9-7d58-d4983ccbe1a5", + "entry": [ + { + "fullUrl": "urn:uuid:cc96c578-5ef7-dd2d-a102-7f7a843c3ee9", + "resource": { + "resourceType": "MessageHeader", + "id": "cc96c578-5ef7-dd2d-a102-7f7a843c3ee9", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "S26", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "SIU^S26^SIU_S26" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/cc96c578-5ef7-dd2d-a102-7f7a843c3ee9" + } + }, + { + "fullUrl": "urn:uuid:09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "resource": { + "resourceType": "Provenance", + "id": "09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:46:35.241Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: SIU_S26.

" + }, + "occurredDateTime": "2021-09-24T13:15:00+05:30", + "recorded": "2021-09-24T13:15:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "SIU^S26^SIU_S26" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/12428005-5692-7537-f572-e47a16418f26" + } + } + ], + "target": [ + { + "reference": "Bundle/6ce25f29-49da-3ad9-7d58-d4983ccbe1a5" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/09e54df1-8856-96ca-cdbf-4bdbd94a26a3" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:12428005-5692-7537-f572-e47a16418f26", + "resource": { + "resourceType": "Device", + "id": "12428005-5692-7537-f572-e47a16418f26", + "identifier": [ + { + "value": "SCHApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/12428005-5692-7537-f572-e47a16418f26" + } + }, + { + "fullUrl": "urn:uuid:b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "resource": { + "resourceType": "Appointment", + "id": "b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "identifier": [ + { + "value": "12345", + "type": { + "coding": [ + { + "code": "PLAC", + "display": "Placer Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "36996", + "type": { + "coding": [ + { + "code": "FILL", + "display": "Filler Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "appointmentType": { + "coding": [ + { + "code": "EMERGENCY", + "display": "Emergency appointment", + "system": "http://terminology.hl7.org/CodeSystem/v2-0276" + } + ] + }, + "priority": 2, + "start": "2021-09-24T12:45:00+05:30", + "end": "2021-09-24T13:35:00+05:30", + "minutesDuration": 1, + "status": "noshow", + "supportingInformation": [ + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + ], + "participant": [ + { + "actor": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "status": "accepted" + }, + { + "actor": { + "reference": "Device/0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00" + }, + "type": [ + { + "coding": [ + { + "code": "101", + "display": "Equipment", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "period": { + "start": "2021-09-24T12:45:00+05:30" + }, + "status": "declined" + }, + { + "actor": { + "reference": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + }, + "period": { + "start": "2021-09-24T12:45:00+05:30" + }, + "status": "declined" + }, + { + "actor": { + "reference": "Practitioner/cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb" + }, + "type": [ + { + "coding": [ + { + "code": "010", + "display": "Gastroenterologist", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "period": { + "start": "2021-09-24T12:45:00+05:30" + }, + "status": "declined" + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/377d8e6d-3ee4-7509-6f8b-6279da04eb6b" + } + ] + }, + "request": { + "method": "PUT", + "url": "Appointment/b7121f46-cf50-5cec-7cfb-5de8e42b82d2" + } + }, + { + "fullUrl": "urn:uuid:df03b003-6818-1abd-209e-0889025aad16", + "resource": { + "resourceType": "Organization", + "id": "df03b003-6818-1abd-209e-0889025aad16", + "identifier": [ + { + "value": "NPIID", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NPIID" + }, + { + "value": "urn:oid:2.16.840.1.113883.4.6", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/df03b003-6818-1abd-209e-0889025aad16" + } + }, + { + "fullUrl": "urn:uuid:6f540060-4f9a-5d13-45b3-da6a76e207a7", + "resource": { + "resourceType": "Practitioner", + "id": "6f540060-4f9a-5d13-45b3-da6a76e207a7", + "address": [ + { + "line": [ + "115 MAINSTREET" + ], + "city": "GOODTOWN", + "state": "KY", + "postalCode": "42010", + "country": "USA" + } + ], + "telecom": [ + { + "value": "(608)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9941339109", + "system": "urn:oid:2.16.840.1.113883.4.6", + "assigner": { + "reference": "Organization/df03b003-6818-1abd-209e-0889025aad16" + }, + "type": { + "coding": [ + { + "code": "NPI", + "display": "National provider identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Smith", + "given": [ + "Adam", + "Mellie" + ], + "suffix": [ + "Jr", + "MD", + "GP" + ], + "prefix": [ + "Dr" + ], + "use": "official", + "period": { + "start": "2010-01-15", + "end": "2020-01-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + { + "fullUrl": "urn:uuid:36effb10-f605-f388-c06c-90d22b315bd0", + "resource": { + "resourceType": "PractitionerRole", + "id": "36effb10-f605-f388-c06c-90d22b315bd0", + "code": [ + { + "coding": [ + { + "code": "placer-contact", + "display": "Placer Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + }, + { + "coding": [ + { + "code": "filler-contact", + "display": "Filler Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + ], + "practitioner": { + "reference": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + } + }, + { + "fullUrl": "urn:uuid:92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "resource": { + "resourceType": "Location", + "id": "92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "name": "FACILITY2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + }, + { + "fullUrl": "urn:uuid:4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "resource": { + "resourceType": "Location", + "id": "4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "partOf": { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + }, + "name": "BUILDING2", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + } + }, + { + "fullUrl": "urn:uuid:81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "resource": { + "resourceType": "Location", + "id": "81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf" + } + }, + { + "fullUrl": "urn:uuid:fb95e0b1-227c-8068-3e51-86c2df312f25", + "resource": { + "resourceType": "Practitioner", + "id": "fb95e0b1-227c-8068-3e51-86c2df312f25", + "telecom": [ + { + "value": "(610)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9" + } + ], + "name": [ + { + "family": "DENT", + "given": [ + "COREY" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + { + "fullUrl": "urn:uuid:f3c93626-c639-1507-76f0-945d762c11a8", + "resource": { + "resourceType": "PractitionerRole", + "id": "f3c93626-c639-1507-76f0-945d762c11a8", + "code": [ + { + "coding": [ + { + "code": "enterer", + "display": "Enterer", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + ], + "practitioner": { + "reference": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + }, + { + "fullUrl": "urn:uuid:5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "resource": { + "resourceType": "Location", + "id": "5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "name": "FACILITY3", + "identifier": [ + { + "value": "urn:oid:1.23", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:377d8e6d-3ee4-7509-6f8b-6279da04eb6b", + "resource": { + "resourceType": "ServiceRequest", + "id": "377d8e6d-3ee4-7509-6f8b-6279da04eb6b", + "status": "revoked", + "intent": "filler-order", + "orderDetail": [ + { + "coding": [ + { + "code": "5001", + "display": "EVIS X12 Video Colonoscope", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + }, + { + "coding": [ + { + "code": "5001", + "display": "EVIS X12 Video Colonoscope", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "occurrencePeriod": { + "start": "2021-09-24T12:45:00+05:30" + }, + "code": { + "coding": [ + { + "code": "76164006", + "display": "Biopsy of colon (procedure)", + "system": "http://snomed.info/sct" + }, + { + "code": "1212", + "display": "Biopsy" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "note": [ + { + "text": "Nursing staff instructions - Patient did not show up for the appointment" + } + ], + "performer": [ + { + "reference": "Device/0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00" + }, + { + "reference": "Practitioner/cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb" + } + ], + "locationReference": [ + { + "reference": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/377d8e6d-3ee4-7509-6f8b-6279da04eb6b" + } + }, + { + "fullUrl": "urn:uuid:0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00", + "resource": { + "resourceType": "Device", + "id": "0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00", + "identifier": [ + { + "value": "5001", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + }, + { + "value": "5002" + } + ], + "deviceName": [ + { + "name": "EVIS X12 Video Colonoscope", + "type": "model-name" + } + ], + "status": "active", + "note": [ + { + "text": "Equipment available" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/0434a8f4-6ef0-5dc7-d1a1-91ad4b080b00" + } + }, + { + "fullUrl": "urn:uuid:b13417bd-d0fb-e50f-b65a-cd07396a0608", + "resource": { + "resourceType": "Location", + "id": "b13417bd-d0fb-e50f-b65a-cd07396a0608", + "name": "055", + "mode": "instance", + "description": "055--Room01--GH Clinic", + "type": [ + { + "coding": [ + { + "code": "C", + "display": "Clinic", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + } + ] + } + ], + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available as patient did not show up" + ] + }, + "request": { + "method": "PUT", + "url": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + } + }, + { + "fullUrl": "urn:uuid:ee586d80-706a-5933-8500-a8026c48fb27", + "resource": { + "resourceType": "Location", + "id": "ee586d80-706a-5933-8500-a8026c48fb27", + "partOf": { + "reference": "Location/b13417bd-d0fb-e50f-b65a-cd07396a0608" + }, + "name": "Room01", + "mode": "instance", + "description": "055--Room01--GH Clinic", + "type": [ + { + "coding": [ + { + "code": "C", + "display": "Clinic", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + } + ] + } + ], + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available as patient did not show up" + ] + }, + "request": { + "method": "PUT", + "url": "Location/ee586d80-706a-5933-8500-a8026c48fb27" + } + }, + { + "fullUrl": "urn:uuid:4b6f7358-191b-8623-f2f4-806a8a0babcf", + "resource": { + "resourceType": "Location", + "id": "4b6f7358-191b-8623-f2f4-806a8a0babcf", + "name": "GH Clinic", + "mode": "instance", + "description": "055--Room01--GH Clinic", + "type": [ + { + "coding": [ + { + "code": "C", + "display": "Clinic", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-LocationRoleType" + } + ] + } + ], + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + }, + "alias": [ + "Location available as patient did not show up" + ] + }, + "request": { + "method": "PUT", + "url": "Location/4b6f7358-191b-8623-f2f4-806a8a0babcf" + } + }, + { + "fullUrl": "urn:uuid:cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb", + "resource": { + "resourceType": "Practitioner", + "id": "cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb", + "identifier": [ + { + "value": "1210" + } + ], + "name": [ + { + "family": "GE", + "given": [ + "Robert", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/cf8dbd4d-8d1c-57fc-1609-c069ee81b4cb" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S26/SIU-S26-02-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S26/SIU-S26-02-expected.json new file mode 100644 index 000000000..9a6378ef3 --- /dev/null +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/SIU_S26/SIU-S26-02-expected.json @@ -0,0 +1,1639 @@ +{ + "resourceType": "Bundle", + "type": "batch", + "timestamp": "2021-08-18T14:45:00+05:30", + "identifier": { + "value": "MSG00026" + }, + "id": "6ce25f29-49da-3ad9-7d58-d4983ccbe1a5", + "entry": [ + { + "fullUrl": "urn:uuid:cc96c578-5ef7-dd2d-a102-7f7a843c3ee9", + "resource": { + "resourceType": "MessageHeader", + "id": "cc96c578-5ef7-dd2d-a102-7f7a843c3ee9", + "source": { + "name": "24GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.20" + }, + "destination": [ + { + "name": "25GHH", + "endpoint": "urn:oid:2.16.840.1.114884.10.23", + "receiver": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + } + ], + "meta": { + "security": [ + { + "display": "SECURITY", + "system": "http://example.com/v2-to-fhirconverter/security-label" + } + ], + "tag": [ + { + "code": "P", + "system": "http://terminology.hl7.org/CodeSystem/v2-0103" + } + ] + }, + "eventCoding": { + "code": "S26", + "system": "http://terminology.hl7.org/CodeSystem/v2-0003", + "display": "SIU^S26^SIU_S26" + }, + "language": "en-US", + "sender": { + "reference": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + }, + "responsible": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + "request": { + "method": "PUT", + "url": "MessageHeader/cc96c578-5ef7-dd2d-a102-7f7a843c3ee9" + } + }, + { + "fullUrl": "urn:uuid:09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "resource": { + "resourceType": "Provenance", + "id": "09e54df1-8856-96ca-cdbf-4bdbd94a26a3", + "text": { + "status": "generated", + "div": "

Resource bundle generated on 2021-10-29T08:46:53.449Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: SIU_S26.

" + }, + "occurredDateTime": "2021-08-18T14:45:00+05:30", + "recorded": "2021-08-18T14:45:00+05:30", + "agent": [ + { + "type": { + "coding": [ + { + "code": "author", + "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type" + } + ] + }, + "who": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + } + ], + "activity": { + "coding": [ + { + "display": "SIU^S26^SIU_S26" + } + ] + }, + "entity": [ + { + "role": "source", + "what": { + "reference": "Device/12428005-5692-7537-f572-e47a16418f26" + } + } + ], + "target": [ + { + "reference": "Bundle/6ce25f29-49da-3ad9-7d58-d4983ccbe1a5" + } + ] + }, + "request": { + "method": "PUT", + "url": "Provenance/09e54df1-8856-96ca-cdbf-4bdbd94a26a3" + } + }, + { + "fullUrl": "urn:uuid:4356fb81-6ecd-2d70-57b1-47812638e785", + "resource": { + "resourceType": "Organization", + "id": "4356fb81-6ecd-2d70-57b1-47812638e785", + "identifier": [ + { + "value": "GHHSFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHSFacility" + }, + { + "value": "urn:oid:2.16.840.1.122848.1.30", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/4356fb81-6ecd-2d70-57b1-47812638e785" + } + }, + { + "fullUrl": "urn:uuid:62781ad6-3896-cb63-0178-ead0c4a432b5", + "resource": { + "resourceType": "Organization", + "id": "62781ad6-3896-cb63-0178-ead0c4a432b5", + "identifier": [ + { + "value": "GHHRFacility", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-GHHRFacility" + }, + { + "value": "urn:oid:2.16.840.1.1122848.1.32", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ], + "partOf": { + "reference": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + }, + "address": [ + { + "country": "USA" + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/62781ad6-3896-cb63-0178-ead0c4a432b5" + } + }, + { + "fullUrl": "urn:uuid:33532a82-d220-4c0d-1abe-53e48951c201", + "resource": { + "resourceType": "Organization", + "id": "33532a82-d220-4c0d-1abe-53e48951c201", + "name": "22 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/33532a82-d220-4c0d-1abe-53e48951c201" + } + }, + { + "fullUrl": "urn:uuid:527280c1-34d1-c639-e9ba-61986d28e266", + "resource": { + "resourceType": "Organization", + "id": "527280c1-34d1-c639-e9ba-61986d28e266", + "name": "23 GHH Inc." + }, + "request": { + "method": "PUT", + "url": "Organization/527280c1-34d1-c639-e9ba-61986d28e266" + } + }, + { + "fullUrl": "urn:uuid:12428005-5692-7537-f572-e47a16418f26", + "resource": { + "resourceType": "Device", + "id": "12428005-5692-7537-f572-e47a16418f26", + "identifier": [ + { + "value": "SCHApp" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/12428005-5692-7537-f572-e47a16418f26" + } + }, + { + "fullUrl": "urn:uuid:b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "resource": { + "resourceType": "Appointment", + "id": "b7121f46-cf50-5cec-7cfb-5de8e42b82d2", + "identifier": [ + { + "value": "12345", + "type": { + "coding": [ + { + "code": "PLAC", + "display": "Placer Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + }, + { + "value": "36996", + "type": { + "coding": [ + { + "code": "FILL", + "display": "Filler Identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "appointmentType": { + "coding": [ + { + "code": "CHECKUP", + "display": "A routine check-up, such as an annual physical", + "system": "http://terminology.hl7.org/CodeSystem/v2-0276" + } + ] + }, + "priority": 2, + "start": "2021-08-18T14:45:00+05:30", + "end": "2021-08-18T15:45:00+05:30", + "minutesDuration": 70, + "status": "noshow", + "supportingInformation": [ + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + }, + { + "reference": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + ], + "comment": "Patient did not show up for the annual checkup ", + "participant": [ + { + "actor": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "status": "accepted" + }, + { + "actor": { + "reference": "Device/dd77839c-6623-a021-29ef-c04fd35460ca" + }, + "type": [ + { + "coding": [ + { + "code": "011", + "display": "Lab Equipment", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + }, + "status": "tentative" + }, + { + "actor": { + "reference": "Practitioner/9d928c63-6d1e-7fb7-fed9-b97b625dc5f8" + }, + "type": [ + { + "coding": [ + { + "code": "019", + "display": "Phlebotomist", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Device/d8709d49-8f55-d198-44e8-2cf5ee983e90" + }, + "type": [ + { + "coding": [ + { + "code": "015", + "display": "Imaging Equipment", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + }, + "status": "tentative" + }, + { + "actor": { + "reference": "Practitioner/89f153f4-91d2-b658-0242-612129d35f06" + }, + "type": [ + { + "coding": [ + { + "code": "021", + "display": "Radiology Technician", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + }, + { + "actor": { + "reference": "Location/82709fdd-4012-9faa-5ec3-cf75fd57a34c" + }, + "status": "tentative" + }, + { + "actor": { + "reference": "Practitioner/a4177c1c-eb53-edd4-a0ee-1a55b986ea3b" + }, + "type": [ + { + "coding": [ + { + "code": "011", + "display": "General Practitioner", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ] + } + ], + "status": "tentative" + } + ], + "basedOn": [ + { + "reference": "ServiceRequest/8ad3476e-03c9-158e-12d8-20de3070fce5" + }, + { + "reference": "ServiceRequest/2b1743c0-089d-d354-0cbe-e548478fd580" + } + ] + }, + "request": { + "method": "PUT", + "url": "Appointment/b7121f46-cf50-5cec-7cfb-5de8e42b82d2" + } + }, + { + "fullUrl": "urn:uuid:df03b003-6818-1abd-209e-0889025aad16", + "resource": { + "resourceType": "Organization", + "id": "df03b003-6818-1abd-209e-0889025aad16", + "identifier": [ + { + "value": "NPIID", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NPIID" + }, + { + "value": "urn:oid:2.16.840.1.113883.4.6", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/df03b003-6818-1abd-209e-0889025aad16" + } + }, + { + "fullUrl": "urn:uuid:6f540060-4f9a-5d13-45b3-da6a76e207a7", + "resource": { + "resourceType": "Practitioner", + "id": "6f540060-4f9a-5d13-45b3-da6a76e207a7", + "address": [ + { + "line": [ + "115 MAINSTREET" + ], + "city": "GOODTOWN", + "state": "KY", + "postalCode": "42010", + "country": "USA" + } + ], + "telecom": [ + { + "value": "(608)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9941339109", + "system": "urn:oid:2.16.840.1.113883.4.6", + "assigner": { + "reference": "Organization/df03b003-6818-1abd-209e-0889025aad16" + }, + "type": { + "coding": [ + { + "code": "NPI", + "display": "National provider identifier", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + } + } + ], + "name": [ + { + "family": "Smith", + "given": [ + "Adam", + "Mellie" + ], + "suffix": [ + "Jr", + "MD", + "GP" + ], + "prefix": [ + "Dr" + ], + "use": "official", + "period": { + "start": "2010-01-15", + "end": "2020-01-15" + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + { + "fullUrl": "urn:uuid:36effb10-f605-f388-c06c-90d22b315bd0", + "resource": { + "resourceType": "PractitionerRole", + "id": "36effb10-f605-f388-c06c-90d22b315bd0", + "code": [ + { + "coding": [ + { + "code": "placer-contact", + "display": "Placer Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + }, + { + "coding": [ + { + "code": "filler-contact", + "display": "Filler Contact", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + ], + "practitioner": { + "reference": "Practitioner/6f540060-4f9a-5d13-45b3-da6a76e207a7" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/36effb10-f605-f388-c06c-90d22b315bd0" + } + }, + { + "fullUrl": "urn:uuid:92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "resource": { + "resourceType": "Location", + "id": "92a004c0-d02e-68e3-bde6-bc78f980b3bb", + "name": "FACILITY2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/92a004c0-d02e-68e3-bde6-bc78f980b3bb" + } + }, + { + "fullUrl": "urn:uuid:4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "resource": { + "resourceType": "Location", + "id": "4204399b-1a0b-7fb2-91ec-9705ef5886e3", + "partOf": { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + }, + "name": "BUILDING2", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "bu" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + } + }, + { + "fullUrl": "urn:uuid:81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "resource": { + "resourceType": "Location", + "id": "81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR2", + "mode": "instance", + "description": "FACILITY2--BUILDING2--FLOOR2", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/81e28943-22c3-d0f9-8b2b-9fd4a3c86cdf" + } + }, + { + "fullUrl": "urn:uuid:fb95e0b1-227c-8068-3e51-86c2df312f25", + "resource": { + "resourceType": "Practitioner", + "id": "fb95e0b1-227c-8068-3e51-86c2df312f25", + "telecom": [ + { + "value": "(610)271-9000", + "system": "phone" + } + ], + "identifier": [ + { + "value": "9" + } + ], + "name": [ + { + "family": "DENT", + "given": [ + "COREY" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + { + "fullUrl": "urn:uuid:f3c93626-c639-1507-76f0-945d762c11a8", + "resource": { + "resourceType": "PractitionerRole", + "id": "f3c93626-c639-1507-76f0-945d762c11a8", + "code": [ + { + "coding": [ + { + "code": "enterer", + "display": "Enterer", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/additional-practitioner-role" + } + ] + } + ], + "location": [ + { + "reference": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + ], + "practitioner": { + "reference": "Practitioner/fb95e0b1-227c-8068-3e51-86c2df312f25" + } + }, + "request": { + "method": "PUT", + "url": "PractitionerRole/f3c93626-c639-1507-76f0-945d762c11a8" + } + }, + { + "fullUrl": "urn:uuid:5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "resource": { + "resourceType": "Location", + "id": "5c36a4d3-74e3-6ef9-4be8-215a47dd229e", + "name": "FACILITY3", + "identifier": [ + { + "value": "urn:oid:1.23", + "system": "urn:ietf:rfc:3986" + } + ], + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/5c36a4d3-74e3-6ef9-4be8-215a47dd229e" + } + }, + { + "fullUrl": "urn:uuid:0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "resource": { + "resourceType": "Location", + "id": "0d9c3424-329f-4c95-ee30-ac2da4a35bff", + "partOf": { + "reference": "Location/4204399b-1a0b-7fb2-91ec-9705ef5886e3" + }, + "name": "FLOOR1", + "mode": "instance", + "description": "FACILITY3--1.23--ISO--BUILDING2--FLOOR1", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + } + }, + "request": { + "method": "PUT", + "url": "Location/0d9c3424-329f-4c95-ee30-ac2da4a35bff" + } + }, + { + "fullUrl": "urn:uuid:9e909e52-61a1-be50-1878-a12ef8c36346", + "resource": { + "resourceType": "Patient", + "id": "9e909e52-61a1-be50-1878-a12ef8c36346", + "identifier": [ + { + "value": "1234567", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test", + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + }, + { + "value": "PATID1234", + "type": { + "coding": [ + { + "code": "MR", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Medical record number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "value": "123456789", + "type": { + "coding": [ + { + "code": "SS", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Social Security number" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-USSSA" + }, + { + "value": "PATID567", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test2" + }, + { + "value": "PSSN123121234", + "type": { + "coding": [ + { + "code": "SB", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203" + } + ] + }, + "system": "http://hl7.org/fhir/sid/us-ssn" + }, + { + "value": "DLN-123", + "type": { + "coding": [ + { + "code": "DL" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/US", + "period": { + "end": "2001-01-23" + } + } + ], + "name": [ + { + "family": "EVERYMAN", + "given": [ + "ADAM", + "A", + "Addsm" + ], + "suffix": [ + "III", + "MD", + "PF" + ], + "prefix": [ + "Dr." + ], + "use": "usual", + "period": { + "start": "1924-10-12" + } + }, + { + "family": "Josh", + "given": [ + "stanley" + ], + "use": "official", + "period": { + "start": "1924-10-10", + "end": "1924-10-15" + } + }, + { + "family": "elbert", + "given": [ + "Son" + ] + } + ], + "birthDate": "1988-08-18", + "_birthDate": { + "extension": [ + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthTime", + "valueDateTime": "1988-08-18T14:41:00+05:30" + } + ] + }, + "gender": "male", + "address": [ + { + "line": [ + "1000", + "Hospital Lane", + "Ste. 123", + "Near Highway" + ], + "city": "Ann Arbor ", + "state": "MI", + "postalCode": "99999", + "country": "USA", + "type": "postal", + "district": "W", + "period": { + "start": "2000-01-10", + "end": "2000-01-20" + } + } + ], + "telecom": [ + { + "value": "2222", + "system": "phone", + "period": { + "start": "2001-01-10", + "end": "2002-01-10" + }, + "rank": 18, + "use": "home" + }, + { + "value": "12121212", + "system": "phone", + "use": "home" + }, + { + "value": "7777", + "system": "phone", + "use": "work" + }, + { + "value": "1111", + "system": "other", + "use": "work" + }, + { + "value": "89898989", + "use": "work", + "system": "email" + } + ], + "communication": [ + { + "language": { + "coding": [ + { + "code": "ar", + "display": "Arabic", + "system": "urn:ietf:bcp:47", + "version": "v2" + }, + { + "code": "en", + "display": "English", + "system": "urn:ietf:bcp:47", + "version": "v2.1" + } + ], + "text": "TextInEnglish" + }, + "preferred": true + } + ], + "maritalStatus": { + "coding": [ + { + "code": "M", + "display": "Married", + "system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus" + } + ] + }, + "multipleBirthInteger": 2, + "deceasedDateTime": "2008-08-25T15:31:30+05:30", + "meta": { + "lastUpdated": "2005-01-10T04:05:14+05:30" + }, + "extension": [ + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-race", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2106-3", + "display": "White", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "ombCategory", + "valueCoding": { + "code": "2028-9", + "display": "Asian", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "White+Asian" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName", + "valueString": "SMITH--Angela--L" + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-birthPlace", + "valueAddress": { + "text": "St. Francis Community Hospital of Lower South Side" + } + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-religion", + "valueCodeableConcept": { + "coding": [ + { + "code": "1002", + "display": "African Religions", + "system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation" + } + ] + } + }, + { + "url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity", + "extension": [ + { + "url": "ombCategory", + "valueCoding": { + "code": "2186-5", + "display": "Non Hispanic or Latino", + "system": "urn:oid:2.16.840.1.113883.6.238" + } + }, + { + "url": "text", + "valueString": "Non Hispanic or Latino" + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "US", + "display": "United States of America", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "United States of America" + } + } + ] + }, + { + "url": "http://hl7.org/fhir/StructureDefinition/patient-citizenship", + "extension": [ + { + "url": "code", + "valueCodeableConcept": { + "coding": [ + { + "code": "CA", + "display": "Canada", + "system": "urn:iso:std:iso:3166" + } + ], + "text": "Canada" + } + } + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + { + "fullUrl": "urn:uuid:78295402-9b84-4829-b945-502ab3402de5", + "resource": { + "resourceType": "Account", + "id": "78295402-9b84-4829-b945-502ab3402de5", + "identifier": [ + { + "value": "4000776", + "type": { + "coding": [ + { + "code": "VN", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Visit number" + } + ] + }, + "system": "urn:oid:2.4", + "assigner": { + "reference": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "status": "active", + "subject": [ + { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + ] + }, + "request": { + "method": "PUT", + "url": "Account/78295402-9b84-4829-b945-502ab3402de5" + } + }, + { + "fullUrl": "urn:uuid:9d4c8327-8a28-8152-1898-8251baa707b7", + "resource": { + "resourceType": "Organization", + "id": "9d4c8327-8a28-8152-1898-8251baa707b7", + "identifier": [ + { + "value": "AccMgr", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-AccMgr" + }, + { + "value": "urn:oid:2.4", + "system": "urn:ietf:rfc:3986", + "type": { + "coding": [ + { + "code": "ISO", + "display": "An International Standards Organization Object Identifier (OID), in accordance with ISO/IEC 8824. Formatted as decimal digits separated by periods; recommended limit of 64 characters", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/9d4c8327-8a28-8152-1898-8251baa707b7" + } + }, + { + "fullUrl": "urn:uuid:b3ad3a9f-d4f6-4638-0a09-2da771733488", + "resource": { + "resourceType": "Organization", + "id": "b3ad3a9f-d4f6-4638-0a09-2da771733488", + "identifier": [ + { + "value": "test1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-test1" + }, + { + "value": "2.16.1", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/b3ad3a9f-d4f6-4638-0a09-2da771733488" + } + }, + { + "fullUrl": "urn:uuid:f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "resource": { + "resourceType": "Organization", + "id": "f3954ae4-dec6-f114-1b9e-3a8a85d93f99", + "identifier": [ + { + "value": "NTH", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-local-system-NTH" + }, + { + "value": "rt23", + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "type": { + "coding": [ + { + "code": "HCD", + "display": "The CEN Healthcare Coding Scheme Designator", + "system": "http://terminology.hl7.org/CodeSystem/v2-0301" + } + ] + } + } + ] + }, + "request": { + "method": "PUT", + "url": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + } + }, + { + "fullUrl": "urn:uuid:62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "resource": { + "resourceType": "RelatedPerson", + "id": "62b2e1ee-a272-4ffe-692e-a1fbfd49af6a", + "identifier": [ + { + "value": "1212121", + "type": { + "coding": [ + { + "code": "AND", + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "display": "Account number debitor" + } + ] + }, + "system": "http://example.com/v2-to-fhir-converter/assigning-authority-universal-system-HCD", + "assigner": { + "reference": "Organization/f3954ae4-dec6-f114-1b9e-3a8a85d93f99" + }, + "period": { + "start": "1924-10-11", + "end": "1924-10-12" + } + } + ], + "relationship": [ + { + "coding": [ + { + "code": "MTH", + "system": "http://terminology.hl7.org/CodeSystem/v3-RoleCode" + } + ] + } + ], + "patient": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + } + }, + "request": { + "method": "PUT", + "url": "RelatedPerson/62b2e1ee-a272-4ffe-692e-a1fbfd49af6a" + } + }, + { + "fullUrl": "urn:uuid:8ad3476e-03c9-158e-12d8-20de3070fce5", + "resource": { + "resourceType": "ServiceRequest", + "id": "8ad3476e-03c9-158e-12d8-20de3070fce5", + "status": "revoked", + "intent": "filler-order", + "code": { + "coding": [ + { + "code": "58410-2", + "display": "CBC Panel-Blood by Automated Count", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "note": [ + { + "text": "Lab Staff Instructions - Patient did not show up" + } + ], + "performer": [ + { + "reference": "Device/dd77839c-6623-a021-29ef-c04fd35460ca" + }, + { + "reference": "Practitioner/9d928c63-6d1e-7fb7-fed9-b97b625dc5f8" + } + ], + "locationReference": [ + { + "reference": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/8ad3476e-03c9-158e-12d8-20de3070fce5" + } + }, + { + "fullUrl": "urn:uuid:dd77839c-6623-a021-29ef-c04fd35460ca", + "resource": { + "resourceType": "Device", + "id": "dd77839c-6623-a021-29ef-c04fd35460ca", + "identifier": [ + { + "value": "123", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ], + "deviceName": [ + { + "name": "ABC Cell Counter", + "type": "model-name" + } + ], + "note": [ + { + "text": "Equipment available for lab test" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/dd77839c-6623-a021-29ef-c04fd35460ca" + } + }, + { + "fullUrl": "urn:uuid:bc5a0b18-cce5-ddbc-8e45-a09c736af725", + "resource": { + "resourceType": "Location", + "id": "bc5a0b18-cce5-ddbc-8e45-a09c736af725", + "name": "LabUnit101", + "mode": "instance", + "description": "LabUnit101--Lab Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for lab test" + ] + }, + "request": { + "method": "PUT", + "url": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + } + }, + { + "fullUrl": "urn:uuid:a86368de-48ac-12e3-05e4-6b2da7fa4853", + "resource": { + "resourceType": "Location", + "id": "a86368de-48ac-12e3-05e4-6b2da7fa4853", + "partOf": { + "reference": "Location/bc5a0b18-cce5-ddbc-8e45-a09c736af725" + }, + "name": "Lab Room 01", + "mode": "instance", + "description": "LabUnit101--Lab Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for lab test" + ] + }, + "request": { + "method": "PUT", + "url": "Location/a86368de-48ac-12e3-05e4-6b2da7fa4853" + } + }, + { + "fullUrl": "urn:uuid:9d04f983-a391-647a-07a8-e8bf59f77de8", + "resource": { + "resourceType": "Location", + "id": "9d04f983-a391-647a-07a8-e8bf59f77de8", + "name": "GHH Hospital", + "mode": "instance", + "description": "OPD12--Room 55--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "si" + } + ] + }, + "alias": [ + "Location available for lab test", + "Location available for imaging", + "Location available for checkup" + ] + }, + "request": { + "method": "PUT", + "url": "Location/9d04f983-a391-647a-07a8-e8bf59f77de8" + } + }, + { + "fullUrl": "urn:uuid:9d928c63-6d1e-7fb7-fed9-b97b625dc5f8", + "resource": { + "resourceType": "Practitioner", + "id": "9d928c63-6d1e-7fb7-fed9-b97b625dc5f8", + "identifier": [ + { + "value": "400" + } + ], + "name": [ + { + "family": "PB", + "given": [ + "Tim", + "G" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/9d928c63-6d1e-7fb7-fed9-b97b625dc5f8" + } + }, + { + "fullUrl": "urn:uuid:2b1743c0-089d-d354-0cbe-e548478fd580", + "resource": { + "resourceType": "ServiceRequest", + "id": "2b1743c0-089d-d354-0cbe-e548478fd580", + "status": "revoked", + "intent": "filler-order", + "code": { + "coding": [ + { + "code": "42272-5", + "display": "XR Chest PA and Lateral", + "system": "http://loinc.org" + } + ] + }, + "subject": { + "reference": "Patient/9e909e52-61a1-be50-1878-a12ef8c36346" + }, + "note": [ + { + "text": "Radiology Staff Instructions - Patient did not show up" + } + ], + "performer": [ + { + "reference": "Device/d8709d49-8f55-d198-44e8-2cf5ee983e90" + }, + { + "reference": "Practitioner/89f153f4-91d2-b658-0242-612129d35f06" + } + ], + "locationReference": [ + { + "reference": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + } + ] + }, + "request": { + "method": "PUT", + "url": "ServiceRequest/2b1743c0-089d-d354-0cbe-e548478fd580" + } + }, + { + "fullUrl": "urn:uuid:d8709d49-8f55-d198-44e8-2cf5ee983e90", + "resource": { + "resourceType": "Device", + "id": "d8709d49-8f55-d198-44e8-2cf5ee983e90", + "identifier": [ + { + "value": "1001", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/L" + } + ], + "deviceName": [ + { + "name": "XYZ X-Ray Machine", + "type": "model-name" + } + ], + "note": [ + { + "text": "Equipment available for imaging" + } + ] + }, + "request": { + "method": "PUT", + "url": "Device/d8709d49-8f55-d198-44e8-2cf5ee983e90" + } + }, + { + "fullUrl": "urn:uuid:2b9be76c-a0f5-72ea-b684-51adaf2d95f6", + "resource": { + "resourceType": "Location", + "id": "2b9be76c-a0f5-72ea-b684-51adaf2d95f6", + "name": "DiagnosticUnit201", + "mode": "instance", + "description": "DiagnosticUnit201--Imaging Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for imaging" + ] + }, + "request": { + "method": "PUT", + "url": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + } + }, + { + "fullUrl": "urn:uuid:e36c1c9d-9008-4267-0e0f-e8b36ec2f208", + "resource": { + "resourceType": "Location", + "id": "e36c1c9d-9008-4267-0e0f-e8b36ec2f208", + "partOf": { + "reference": "Location/2b9be76c-a0f5-72ea-b684-51adaf2d95f6" + }, + "name": "Imaging Room 01", + "mode": "instance", + "description": "DiagnosticUnit201--Imaging Room 01--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for imaging" + ] + }, + "request": { + "method": "PUT", + "url": "Location/e36c1c9d-9008-4267-0e0f-e8b36ec2f208" + } + }, + { + "fullUrl": "urn:uuid:89f153f4-91d2-b658-0242-612129d35f06", + "resource": { + "resourceType": "Practitioner", + "id": "89f153f4-91d2-b658-0242-612129d35f06", + "identifier": [ + { + "value": "500" + } + ], + "name": [ + { + "family": "RT", + "given": [ + "Robert", + "C" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/89f153f4-91d2-b658-0242-612129d35f06" + } + }, + { + "fullUrl": "urn:uuid:82709fdd-4012-9faa-5ec3-cf75fd57a34c", + "resource": { + "resourceType": "Location", + "id": "82709fdd-4012-9faa-5ec3-cf75fd57a34c", + "name": "OPD12", + "mode": "instance", + "description": "OPD12--Room 55--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "lvl" + } + ] + }, + "alias": [ + "Location available for checkup" + ] + }, + "request": { + "method": "PUT", + "url": "Location/82709fdd-4012-9faa-5ec3-cf75fd57a34c" + } + }, + { + "fullUrl": "urn:uuid:928bc54e-abd5-e128-504a-f02faf5598e6", + "resource": { + "resourceType": "Location", + "id": "928bc54e-abd5-e128-504a-f02faf5598e6", + "partOf": { + "reference": "Location/82709fdd-4012-9faa-5ec3-cf75fd57a34c" + }, + "name": "Room 55", + "mode": "instance", + "description": "OPD12--Room 55--GHH Hospital", + "physicalType": { + "coding": [ + { + "system": "http://terminology.hl7.org/CodeSystem/location-physical-type", + "code": "ro" + } + ] + }, + "alias": [ + "Location available for checkup" + ] + }, + "request": { + "method": "PUT", + "url": "Location/928bc54e-abd5-e128-504a-f02faf5598e6" + } + }, + { + "fullUrl": "urn:uuid:a4177c1c-eb53-edd4-a0ee-1a55b986ea3b", + "resource": { + "resourceType": "Practitioner", + "id": "a4177c1c-eb53-edd4-a0ee-1a55b986ea3b", + "identifier": [ + { + "value": "600" + } + ], + "name": [ + { + "family": "GP", + "given": [ + "Linda", + "R" + ] + } + ] + }, + "request": { + "method": "PUT", + "url": "Practitioner/a4177c1c-eb53-edd4-a0ee-1a55b986ea3b" + } + } + ] +} \ No newline at end of file diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/VXU_V04/IZ_1_1.1_Admin_Child_Max_Message-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/VXU_V04/IZ_1_1.1_Admin_Child_Max_Message-expected.json index 11110fa16..f88f4571b 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/VXU_V04/IZ_1_1.1_Admin_Child_Max_Message-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/VXU_V04/IZ_1_1.1_Admin_Child_Max_Message-expected.json @@ -138,7 +138,8 @@ "url": "ombCategory", "valueCoding": { "code": "2186-5", - "display": "2186-5" + "display": "non Hispanic or Latino", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/CDCREC" } }, { @@ -268,13 +269,13 @@ } }, { - "fullUrl": "urn:uuid:6f2bb641-ec94-319f-da95-e6ed7262b018", + "fullUrl": "urn:uuid:cab498e7-22e3-614e-b9ff-079c8535c9d8", "resource": { "resourceType": "Provenance", - "id": "6f2bb641-ec94-319f-da95-e6ed7262b018", + "id": "cab498e7-22e3-614e-b9ff-079c8535c9d8", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T14:01:13.556Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: VXU_V04.

" + "div": "

Resource bundle generated on 2021-10-29T08:47:48.697Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: VXU_V04.

" }, "occurredDateTime": "2012-07-01T08:22:00", "recorded": "2012-07-01T08:22:00", @@ -308,7 +309,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/6f2bb641-ec94-319f-da95-e6ed7262b018" + "url": "Provenance/cab498e7-22e3-614e-b9ff-079c8535c9d8" } }, { @@ -556,6 +557,9 @@ } ] }, + "subject": { + "reference": "Patient/1b2dce0f-93ae-fae4-cc64-b90257c96f1b" + }, "partOf": [ { "reference": "Immunization/9d7483ec-3273-a9d9-0d6c-da4895472607" @@ -591,6 +595,9 @@ } ] }, + "subject": { + "reference": "Patient/1b2dce0f-93ae-fae4-cc64-b90257c96f1b" + }, "partOf": [ { "reference": "Immunization/9d7483ec-3273-a9d9-0d6c-da4895472607" @@ -617,6 +624,9 @@ } ] }, + "subject": { + "reference": "Patient/1b2dce0f-93ae-fae4-cc64-b90257c96f1b" + }, "partOf": [ { "reference": "Immunization/9d7483ec-3273-a9d9-0d6c-da4895472607" @@ -643,6 +653,9 @@ } ] }, + "subject": { + "reference": "Patient/1b2dce0f-93ae-fae4-cc64-b90257c96f1b" + }, "partOf": [ { "reference": "Immunization/9d7483ec-3273-a9d9-0d6c-da4895472607" diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/VXU_V04/VXU-expected.json b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/VXU_V04/VXU-expected.json index cbcee7948..78b45d002 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/VXU_V04/VXU-expected.json +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.FunctionalTests/TestData/Expected/Hl7v2/VXU_V04/VXU-expected.json @@ -139,7 +139,8 @@ "url": "ombCategory", "valueCoding": { "code": "2186-5", - "display": "2186-5" + "display": "Not Hispanic or Latino", + "system": "http://example.com/v2-to-fhir-converter/CodeSystem/CDCREC" } }, { @@ -315,13 +316,13 @@ } }, { - "fullUrl": "urn:uuid:e07c0451-5793-a1b1-e817-578764a7cc5b", + "fullUrl": "urn:uuid:87847f45-4a99-9d88-c439-65574d8fd20b", "resource": { "resourceType": "Provenance", - "id": "e07c0451-5793-a1b1-e817-578764a7cc5b", + "id": "87847f45-4a99-9d88-c439-65574d8fd20b", "text": { "status": "generated", - "div": "

Resource bundle generated on 2021-10-07T14:01:51.579Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: VXU_V04.

" + "div": "

Resource bundle generated on 2021-10-29T08:47:17.095Z using Microsoft FHIR Converter.Template Version: TEMPLATE_VERSION_PLACEHOLDER.Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.Root template: VXU_V04.

" }, "occurredDateTime": "2015-06-24T19:17:27.655+05:30", "recorded": "2015-06-24T19:17:27.655+05:30", @@ -355,7 +356,7 @@ }, "request": { "method": "PUT", - "url": "Provenance/e07c0451-5793-a1b1-e817-578764a7cc5b" + "url": "Provenance/87847f45-4a99-9d88-c439-65574d8fd20b" } }, { @@ -519,6 +520,9 @@ ] }, "effectiveDateTime": "2015-06-24", + "subject": { + "reference": "Patient/8dc947ee-0db3-5fa2-04bb-16fd7680cfbe" + }, "partOf": [ { "reference": "Immunization/c0f2ddcb-f061-279f-d5e1-7b54b437e9db" @@ -564,6 +568,9 @@ } ] }, + "subject": { + "reference": "Patient/8dc947ee-0db3-5fa2-04bb-16fd7680cfbe" + }, "partOf": [ { "reference": "Immunization/c0f2ddcb-f061-279f-d5e1-7b54b437e9db" @@ -600,6 +607,9 @@ ] }, "effectiveDateTime": "2015-06-24", + "subject": { + "reference": "Patient/8dc947ee-0db3-5fa2-04bb-16fd7680cfbe" + }, "partOf": [ { "reference": "Immunization/c0f2ddcb-f061-279f-d5e1-7b54b437e9db" @@ -628,6 +638,9 @@ }, "valueDateTime": "2015-06-24", "effectiveDateTime": "2015-06-24", + "subject": { + "reference": "Patient/8dc947ee-0db3-5fa2-04bb-16fd7680cfbe" + }, "partOf": [ { "reference": "Immunization/c0f2ddcb-f061-279f-d5e1-7b54b437e9db" diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.UnitTests/Filters/DateFiltersTests.cs b/src/Microsoft.Health.Fhir.Liquid.Converter.UnitTests/Filters/DateFiltersTests.cs index cdb5d195a..8f2013466 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.UnitTests/Filters/DateFiltersTests.cs +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.UnitTests/Filters/DateFiltersTests.cs @@ -15,12 +15,45 @@ public class DateFiltersTests { public static IEnumerable GetValidDataForAddHyphensDate() { - yield return new object[] { null, null }; - yield return new object[] { string.Empty, string.Empty }; - yield return new object[] { @"2001", @"2001" }; - yield return new object[] { @"200101", @"2001-01" }; - yield return new object[] { @"19241010", @"1924-10-10" }; - yield return new object[] { @"19850101000000", @"1985-01-01" }; + yield return new object[] { null, "local", null }; + yield return new object[] { string.Empty, "local", string.Empty }; + yield return new object[] { @"2001", "preserve", @"2001" }; + yield return new object[] { @"200101", "preserve", @"2001-01" }; + yield return new object[] { @"19241010", "local", @"1924-10-10" }; + yield return new object[] { @"19850101000000", "local", @"1985-01-01" }; + } + + // We assume the local timezone is +08:00. + public static IEnumerable GetValidDataWithoutTimeZoneForAddHyphensDateWithUtcTimeZoneHandling() + { + yield return new object[] { @"200101", "utc", @"2000-12" }; + yield return new object[] { @"20010102", "utc", @"2001-01-01" }; + yield return new object[] { @"19850101000000", "utc", @"1984-12-31" }; + } + + public static IEnumerable GetValidDataForAddSeconds() + { + yield return new object[] { null, 60, "local", null }; + yield return new object[] { string.Empty, 60, "local", string.Empty }; + + yield return new object[] { @"1970-01-01T00:01:00.000+10:00", -60, "utc", @"1969-12-31T14:00:00.000Z" }; + + yield return new object[] { @"1970-01-01T00:01:00Z", 60.123, "preserve", @"1970-01-01T00:02:00.123Z" }; + yield return new object[] { @"1970-01-01T00:01:00+06:00", 60.000, "preserve", @"1970-01-01T00:02:00+06:00" }; + yield return new object[] { @"2001-01", 60, "preserve", @"2001-01-01T00:01:00" }; + yield return new object[] { @"1970-01-01T00:01:00+14:00", 60, "utc", @"1969-12-31T10:02:00Z" }; + + // Skip this test in pipeline, as the local time zone is different + // yield return new object[] { @"1924-10-10", 60000, "utc", @"1924-10-10T08:40:00Z" }; + // yield return new object[] { @"1970-01-01T00:01:00+06:00", 60, "local", @"1970-01-01T02:02:00+08:00" }; + // yield return new object[] { @"1924-10-10", 60000, "local", @"1924-10-10T16:40:00" }; + } + + // We assume the local timezone is +08:00. + public static IEnumerable GetValidDataWithoutTimeZoneForAddSecondsWithUtcTimeZoneHandling() + { + yield return new object[] { @"1924-10-10", 60000, "utc", @"1924-10-10T08:40:00Z" }; + yield return new object[] { @"1970-01-01", 60, "utc", @"1969-12-31T16:01:00Z" }; } public static IEnumerable GetValidDataForFormatAsDateTime() @@ -33,10 +66,8 @@ public static IEnumerable GetValidDataForFormatAsDateTime() yield return new object[] { string.Empty, "utc", string.Empty }; yield return new object[] { string.Empty, "local", string.Empty }; yield return new object[] { @"2001", "preserve", @"2001" }; - yield return new object[] { @"2001", "utc", @"2001" }; yield return new object[] { @"2001", "local", @"2001" }; yield return new object[] { @"200101", "preserve", @"2001-01" }; - yield return new object[] { @"200101", "utc", @"2001-01" }; yield return new object[] { @"200101", "local", @"2001-01" }; // If no time zone provided, it is treated as local @@ -50,11 +81,21 @@ public static IEnumerable GetValidDataForFormatAsDateTime() yield return new object[] { @"19701231115959+0600", "utc", @"1970-12-31T05:59:59Z" }; // Skip this test in pipeline, as the local time zone is different + // yield return new object[] { @"2001", "utc", @"2000" }; // yield return new object[] { @"20050110045253", "utc", @"2005-01-09T20:52:53Z" }; // yield return new object[] { @"20110103143428-0800", "local", @"2011-01-04T06:34:28+08:00" }; // yield return new object[] { @"19701231115959+0600", "local", @"1970-12-31T13:59:59+08:00" }; } + // We assume the local timezone is +08:00. + public static IEnumerable GetValidDataWithoutTimeZoneForFormatAsDateTimeWithUtcTimeZoneHandling() + { + yield return new object[] { @"200101", "utc", @"2000-12" }; + yield return new object[] { @"20050110045253", "utc", @"2005-01-09T20:52:53Z" }; + yield return new object[] { @"20110103143428", "utc", @"2011-01-03T06:34:28Z" }; + yield return new object[] { @"19701231115959", "utc", @"1970-12-31T03:59:59Z" }; + } + public static IEnumerable GetInvalidDataForAddHyphensDate() { yield return new object[] { @"20badInput" }; @@ -90,22 +131,84 @@ public static IEnumerable GetInvalidTimeZoneHandling() yield return new object[] { @"19701231115959+0600", "abc" }; } + public static IEnumerable GetInvalidDataForAddSeconds() + { + yield return new object[] { @"20badInput" }; + yield return new object[] { @"20140130080051--0500" }; + yield return new object[] { @"2014.051-0500" }; + yield return new object[] { @"20140130080051123+0500" }; + yield return new object[] { @"20201" }; + yield return new object[] { @"2020060" }; + yield return new object[] { @"1970-01-01T00:01:00" }; + yield return new object[] { @"1970-01-01T00:01" }; + yield return new object[] { @"2001-01T" }; + } + + [Theory] + [MemberData(nameof(GetValidDataForAddSeconds))] + public void GivenSeconds_WhenAddOnValidDateTime_CorrectDateTimeStringShouldBeReturned(string originalDateTime, double seconds, string timeZoneHandling, string expectedDateTime) + { + var result = Filters.AddSeconds(originalDateTime, seconds, timeZoneHandling); + Assert.Equal(expectedDateTime, result); + } + + [Theory] + [MemberData(nameof(GetValidDataWithoutTimeZoneForAddSecondsWithUtcTimeZoneHandling))] + public void GivenSeconds_WhenAddOnValidDataWithoutTimeZone_CorrectDateTimeShouldBeReturned(string originalDateTime, double seconds, string timeZoneHandling, string expectedDateTime) + { + var result = Filters.AddSeconds(originalDateTime, seconds, timeZoneHandling); + var dateTimeOffset = DateTimeOffset.Parse(result); + dateTimeOffset = dateTimeOffset.AddHours(TimeZoneInfo.Local.GetUtcOffset(DateTime.Now).Hours - 8); + var dateTimeString = dateTimeOffset.ToString("yyyy-MM-ddTHH:mm:ssZ"); + Assert.Equal(expectedDateTime, dateTimeString); + } + + [Theory] + [MemberData(nameof(GetInvalidDataForAddSeconds))] + public void GivenSeconds_WhenAddOnInvalidDateTime_ExceptionShouldBeThrow(string originalDateTime) + { + var exception = Assert.Throws(() => Filters.AddSeconds(originalDateTime, 0)); + Assert.Equal(FhirConverterErrorCode.InvalidDateTimeFormat, exception.FhirConverterErrorCode); + } + [Theory] [MemberData(nameof(GetValidDataForAddHyphensDate))] - public void GivenADate_WhenAddHyphensDate_ConvertedDateShouldBeReturned(string input, string expected) + public void GivenADate_WhenAddHyphensDate_ConvertedDateShouldBeReturned(string input, string timeZoneHandling, string expected) { - var result = Filters.AddHyphensDate(input); + var result = Filters.AddHyphensDate(input, timeZoneHandling); Assert.Equal(expected, result); } + [Theory] + [MemberData(nameof(GetValidDataWithoutTimeZoneForAddHyphensDateWithUtcTimeZoneHandling))] + public void GivenAValidDataWithoutTimeZone_WhenAddHyphensDate_CorrectDateTimeShouldBeReturned(string input, string timeZoneHandling, string expected) + { + var result = Filters.AddHyphensDate(input, timeZoneHandling); + var dateTimeOffset = DateTimeOffset.Parse(result); + dateTimeOffset = dateTimeOffset.AddHours(TimeZoneInfo.Local.GetUtcOffset(DateTime.Now).Hours - 8); + var dateTimeString = dateTimeOffset.ToString("yyyy-MM-dd"); + Assert.Contains(expected, dateTimeString); + } + [Theory] [MemberData(nameof(GetValidDataForFormatAsDateTime))] - public void GivenADateTime_WhenFormatAsDateTime_ConvertedDateShouldBeReturned(string input, string timeZoneHandling, string expected) + public void GivenADateTime_WhenFormatAsDateTime_ConvertedDateTimeStringShouldBeReturned(string input, string timeZoneHandling, string expected) { var result = Filters.FormatAsDateTime(input, timeZoneHandling); Assert.Equal(expected, result); } + [Theory] + [MemberData(nameof(GetValidDataWithoutTimeZoneForFormatAsDateTimeWithUtcTimeZoneHandling))] + public void GivenAValidDataWithoutTimeZone_WhenFormatAsDateTime_ConvertedDateTimeShouldBeReturned(string input, string timeZoneHandling, string expectedDateTime) + { + var result = Filters.FormatAsDateTime(input, timeZoneHandling); + var dateTimeOffset = DateTimeOffset.Parse(result); + dateTimeOffset = dateTimeOffset.AddHours(TimeZoneInfo.Local.GetUtcOffset(DateTime.Now).Hours - 8); + var dateTimeString = dateTimeOffset.ToString("yyyy-MM-ddTHH:mm:ssZ"); + Assert.Contains(expectedDateTime, dateTimeString); + } + [Theory] [MemberData(nameof(GetInvalidDataForAddHyphensDate))] public void GivenAnInvalidDateTime_WhenAddHyphensDate_ExceptionShouldBeThrown(string input) diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter.UnitTests/Filters/StringFiltersTests.cs b/src/Microsoft.Health.Fhir.Liquid.Converter.UnitTests/Filters/StringFiltersTests.cs index bf7d3a461..85ba98ce7 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter.UnitTests/Filters/StringFiltersTests.cs +++ b/src/Microsoft.Health.Fhir.Liquid.Converter.UnitTests/Filters/StringFiltersTests.cs @@ -11,6 +11,17 @@ namespace Microsoft.Health.Fhir.Liquid.Converter.UnitTests.FilterTests { public class StringFiltersTests { + [Fact] + public void ToDoubleTest() + { + Assert.Equal(0, Filters.ToDouble("0")); + Assert.Equal(1000, Filters.ToDouble("1000")); + Assert.Equal(50.05, Filters.ToDouble("50.05")); + + Assert.Throws(() => Filters.ToDouble("invalid")); + Assert.Throws(() => Filters.ToDouble(null)); + } + [Fact] public void CharAtTest() { diff --git a/src/Microsoft.Health.Fhir.Liquid.Converter/Filters/DateFilters.cs b/src/Microsoft.Health.Fhir.Liquid.Converter/Filters/DateFilters.cs index e0fcde9b1..983bc4054 100644 --- a/src/Microsoft.Health.Fhir.Liquid.Converter/Filters/DateFilters.cs +++ b/src/Microsoft.Health.Fhir.Liquid.Converter/Filters/DateFilters.cs @@ -4,7 +4,6 @@ // ------------------------------------------------------------------------------------------------- using System; -using System.Text.RegularExpressions; using Microsoft.Health.Fhir.Liquid.Converter.Exceptions; using Microsoft.Health.Fhir.Liquid.Converter.Models; @@ -15,114 +14,86 @@ namespace Microsoft.Health.Fhir.Liquid.Converter /// public partial class Filters { - private static readonly Regex DateTimeRegex = new Regex(@"^((?\d{4})((?\d{2})((?\d{2})(?