switch proccessing of vitals and problems so CCR would validate
added date time for ccr cleaned up template ccr (more to come) more work done in vitals section
This commit is contained in:
parent
e2223f14aa
commit
cd6dc2b91d
|
@ -15,12 +15,13 @@ FMDTOUTC(DATE,FORMAT) ; Convert Fileman Date to UTC Date Format; PUBLIC; Extrins
|
||||||
S D=$E(DATE,6,7)
|
S D=$E(DATE,6,7)
|
||||||
S H=$E(DATE,9,10)
|
S H=$E(DATE,9,10)
|
||||||
S MM=$E(DATE,11,12)
|
S MM=$E(DATE,11,12)
|
||||||
S S=$E(DATE,12,13)
|
S S=$E(DATE,13,14)
|
||||||
S OFF=$$TZ^XLFDT ; See Kernel Manual for documentation.
|
S OFF=$$TZ^XLFDT ; See Kernel Manual for documentation.
|
||||||
; If H, MM and S are empty, it means that the FM date didn't supply the time.
|
; If H, MM and S are empty, it means that the FM date didn't supply the time.
|
||||||
; In this case, set H, MM and S to "00"
|
; In this case, set H, MM and S to "00"
|
||||||
S:('$L(H)&'$L(MM)&'$L(S)) (H,MM,S)="00"
|
S:('$L(H)&'$L(MM)&'$L(S)) (H,MM,S)="00"
|
||||||
S UTC=Y_"-"_M_"-"_D_"T"_H_":"_MM_":"_S_OFF
|
I S="" S UTC=Y_"-"_M_"-"_D_"T"_H_":"_MM_OFF
|
||||||
|
E S UTC=Y_"-"_M_"-"_D_"T"_H_":"_MM_":"_S_OFF
|
||||||
I $L($G(FORMAT)),FORMAT="DT" Q UTC ; Date with time.
|
I $L($G(FORMAT)),FORMAT="DT" Q UTC ; Date with time.
|
||||||
E Q $P(UTC,"T")
|
E Q $P(UTC,"T")
|
||||||
;
|
;
|
||||||
|
|
|
@ -71,13 +71,14 @@ CCRRPC(CCRGRTN,DFN,CCRPART,TIME1,TIME2,HDRARY) ;RPC ENTRY POINT FOR CCR OUTPUT
|
||||||
INITSTPS(TAB) ; INITIALIZE CCR PROCESSING STEPS
|
INITSTPS(TAB) ; INITIALIZE CCR PROCESSING STEPS
|
||||||
; TAB IS PASSED BY NAME
|
; TAB IS PASSED BY NAME
|
||||||
; W "TAB= ",TAB,!
|
; W "TAB= ",TAB,!
|
||||||
D PUSH^GPLXPATH(TAB,"EXTRACT;GPLVITALS;//ContinuityOfCareRecord/Body/VitalSigns;^TMP($J,DFN,""VITALS"")")
|
|
||||||
D PUSH^GPLXPATH(TAB,"EXTRACT;GPLPROBS;//ContinuityOfCareRecord/Body/Problems;^TMP($J,DFN,""PROBLEMS"")")
|
D PUSH^GPLXPATH(TAB,"EXTRACT;GPLPROBS;//ContinuityOfCareRecord/Body/Problems;^TMP($J,DFN,""PROBLEMS"")")
|
||||||
|
D PUSH^GPLXPATH(TAB,"EXTRACT;GPLVITALS;//ContinuityOfCareRecord/Body/VitalSigns;^TMP($J,DFN,""VITALS"")")
|
||||||
Q
|
Q
|
||||||
;
|
;
|
||||||
HDRMAP(CXML,DFN,IHDR) ; MAP HEADER VARIABLES: FROM, TO ECT
|
HDRMAP(CXML,DFN,IHDR) ; MAP HEADER VARIABLES: FROM, TO ECT
|
||||||
N VMAP S VMAP=$NA(^TMP($J,DFN,"HEADER"))
|
N VMAP S VMAP=$NA(^TMP($J,DFN,"HEADER"))
|
||||||
; K @VMAP
|
; K @VMAP
|
||||||
|
S @VMAP@("DATETIME")=$$FMDTOUTC^CCRUTIL($$FMTHL7^XLFDT($$NOW^XLFDT),"DT")
|
||||||
I IHDR="" D ; HEADER ARRAY IS NOT PROVIDED, USE DEFAULTS
|
I IHDR="" D ; HEADER ARRAY IS NOT PROVIDED, USE DEFAULTS
|
||||||
. S @VMAP@("ACTORPATIENT")="ACTORPATIENT_"_DFN
|
. S @VMAP@("ACTORPATIENT")="ACTORPATIENT_"_DFN
|
||||||
. S @VMAP@("ACTORFROM")="ACTORPROVIDER_"_DUZ ; FROM DUZ - ???
|
. S @VMAP@("ACTORFROM")="ACTORPROVIDER_"_DUZ ; FROM DUZ - ???
|
||||||
|
|
154
p/GPLCCR0.m
154
p/GPLCCR0.m
|
@ -54,7 +54,7 @@ LOAD(ARY) ; LOAD A CCR TEMPLATE INTO ARY PASSED BY NAME
|
||||||
;;</Language>
|
;;</Language>
|
||||||
;;<Version>V1.0</Version>
|
;;<Version>V1.0</Version>
|
||||||
;;<DateTime>
|
;;<DateTime>
|
||||||
;;<ExactDateTime>@@DATETIME@@2008-03-18T23:10:58Z</ExactDateTime>
|
;;<ExactDateTime>@@DATETIME@@</ExactDateTime>
|
||||||
;;</DateTime>
|
;;</DateTime>
|
||||||
;;<Patient>
|
;;<Patient>
|
||||||
;;<ActorID>@@ACTORPATIENT@@</ActorID>
|
;;<ActorID>@@ACTORPATIENT@@</ActorID>
|
||||||
|
@ -71,13 +71,13 @@ LOAD(ARY) ; LOAD A CCR TEMPLATE INTO ARY PASSED BY NAME
|
||||||
;;<ActorLink>
|
;;<ActorLink>
|
||||||
;;<ActorID>@@ACTORTO@@</ActorID>
|
;;<ActorID>@@ACTORTO@@</ActorID>
|
||||||
;;<ActorRole>
|
;;<ActorRole>
|
||||||
;;<Text>Primary Provider</Text>
|
;;<Text>@@ACTORTOTEXT@@</Text>
|
||||||
;;</ActorRole>
|
;;</ActorRole>
|
||||||
;;</ActorLink>
|
;;</ActorLink>
|
||||||
;;</To>
|
;;</To>
|
||||||
;;<Purpose>
|
;;<Purpose>
|
||||||
;;<Description>
|
;;<Description>
|
||||||
;;<Text>@@PURPOSEDESCRIPTION@@CEND PHR</Text>
|
;;<Text>@@PURPOSEDESCRIPTION@@</Text>
|
||||||
;;</Description>
|
;;</Description>
|
||||||
;;</Purpose>
|
;;</Purpose>
|
||||||
;;<Body>
|
;;<Body>
|
||||||
|
@ -104,20 +104,20 @@ LOAD(ARY) ; LOAD A CCR TEMPLATE INTO ARY PASSED BY NAME
|
||||||
;;</Problems>
|
;;</Problems>
|
||||||
;;<FamilyHistory>
|
;;<FamilyHistory>
|
||||||
;;<FamilyProblemHistory>
|
;;<FamilyProblemHistory>
|
||||||
;;<CCRDataObjectID></CCRDataObjectID>
|
;;<CCRDataObjectID>@@FAMILYHISTORYOBJECTID@@</CCRDataObjectID>
|
||||||
;;<Source>
|
;;<Source>
|
||||||
;;<Actor>
|
;;<Actor>
|
||||||
;;<ActorID>AA0001</ActorID>
|
;;<ActorID>@@FAMILYHISTORYACTORID@@</ActorID>
|
||||||
;;</Actor>
|
;;</Actor>
|
||||||
;;</Source>
|
;;</Source>
|
||||||
;;<FamilyMember>
|
;;<FamilyMember>
|
||||||
;;<ActorID>AA0003</ActorID>
|
;;<ActorID>@@FAMILYMEMBERACTORID@@</ActorID>
|
||||||
;;<ActorRole>
|
;;<ActorRole>
|
||||||
;;<Text>Father</Text>
|
;;<Text>@@FAMILYMEMBERACTORROLETEXT@@</Text>
|
||||||
;;</ActorRole>
|
;;</ActorRole>
|
||||||
;;<Source>
|
;;<Source>
|
||||||
;;<Actor>
|
;;<Actor>
|
||||||
;;<ActorID>AA0001</ActorID>
|
;;<ActorID>@@FAMILYMEMBERSOURCACTORID@@</ActorID>
|
||||||
;;</Actor>
|
;;</Actor>
|
||||||
;;</Source>
|
;;</Source>
|
||||||
;;</FamilyMember>
|
;;</FamilyMember>
|
||||||
|
@ -241,16 +241,16 @@ LOAD(ARY) ; LOAD A CCR TEMPLATE INTO ARY PASSED BY NAME
|
||||||
;;</FamilyHistory>
|
;;</FamilyHistory>
|
||||||
;;<SocialHistory>
|
;;<SocialHistory>
|
||||||
;;<SocialHistoryElement>
|
;;<SocialHistoryElement>
|
||||||
;;<CCRDataObjectID>BB0004</CCRDataObjectID>
|
;;<CCRDataObjectID>@@SOCIALHISTORYOBJECTID@@</CCRDataObjectID>
|
||||||
;;<Type>
|
;;<Type>
|
||||||
;;<Text>Marital Status</Text>
|
;;<Text>@@SOCIALHISTORYTYPETEXT@@</Text>
|
||||||
;;</Type>
|
;;</Type>
|
||||||
;;<Description>
|
;;<Description>
|
||||||
;;<Text>Married</Text>
|
;;<Text>@@SOCIALHISTORYDESCRIPTIONTEXT@@</Text>
|
||||||
;;</Description>
|
;;</Description>
|
||||||
;;<Source>
|
;;<Source>
|
||||||
;;<Actor>
|
;;<Actor>
|
||||||
;;<ActorID>AA0001</ActorID>
|
;;<ActorID>@@SOCIALHISTORYSOURCACTORID@@</ActorID>
|
||||||
;;</Actor>
|
;;</Actor>
|
||||||
;;</Source>
|
;;</Source>
|
||||||
;;</SocialHistoryElement>
|
;;</SocialHistoryElement>
|
||||||
|
@ -299,69 +299,69 @@ LOAD(ARY) ; LOAD A CCR TEMPLATE INTO ARY PASSED BY NAME
|
||||||
;;</SocialHistory>
|
;;</SocialHistory>
|
||||||
;;<Medications>
|
;;<Medications>
|
||||||
;;<Medication>
|
;;<Medication>
|
||||||
;;<CCRDataObjectID>BB0008</CCRDataObjectID>
|
;;<CCRDataObjectID>@@MEDICATIONOBJECTID@@</CCRDataObjectID>
|
||||||
;;<DateTime>
|
;;<DateTime>
|
||||||
;;<Type>
|
;;<Type>
|
||||||
;;<Text>Begin Date</Text>
|
;;<Text>@@MEDICATIONDATETIMETEXT@@</Text>
|
||||||
;;</Type>
|
;;</Type>
|
||||||
;;<Age>
|
;;<Age>
|
||||||
;;<Value>42</Value>
|
;;<Value>@@MEDICATIONDATETIMEAGE@@</Value>
|
||||||
;;<Units>
|
;;<Units>
|
||||||
;;<Unit>Years</Unit>
|
;;<Unit>@@MEDICATIONDATETIMEAGEUNITS@@</Unit>
|
||||||
;;</Units>
|
;;</Units>
|
||||||
;;</Age>
|
;;</Age>
|
||||||
;;</DateTime>
|
;;</DateTime>
|
||||||
;;<Type>
|
;;<Type>
|
||||||
;;<Text>Medication</Text>
|
;;<Text>@@MEDICATIONTYPETEXT@@</Text>
|
||||||
;;</Type>
|
;;</Type>
|
||||||
;;<Status>
|
;;<Status>
|
||||||
;;<Text>Active</Text>
|
;;<Text>@@MEDICATIONSTATUSTEXT@@</Text>
|
||||||
;;</Status>
|
;;</Status>
|
||||||
;;<Source>
|
;;<Source>
|
||||||
;;<Actor>
|
;;<Actor>
|
||||||
;;<ActorID>AA0001</ActorID>
|
;;<ActorID>@@MEDICATIONSOURCEACTORID@@</ActorID>
|
||||||
;;</Actor>
|
;;</Actor>
|
||||||
;;</Source>
|
;;</Source>
|
||||||
;;<Product>
|
;;<Product>
|
||||||
;;<ProductName>
|
;;<ProductName>
|
||||||
;;<Text>simvastatin</Text>
|
;;<Text>@@MEDICATIONPRODUCTNAMETEXT@@</Text>
|
||||||
;;<Code>
|
;;<Code>
|
||||||
;;<Value>36567</Value>
|
;;<Value>@@MEDICATIONPRODUCTNAMECODEVALUE@@</Value>
|
||||||
;;<CodingSystem>RXNORM</CodingSystem>
|
;;<CodingSystem>@@MEDICATIONPRODUCTNAMECODINGINGSYSTEM@@</CodingSystem>
|
||||||
;;<Version>2005</Version>
|
;;<Version>@@MEDICATIONPRODUCTNAMECODEVERSION@@</Version>
|
||||||
;;</Code>
|
;;</Code>
|
||||||
;;</ProductName>
|
;;</ProductName>
|
||||||
;;<BrandName>
|
;;<BrandName>
|
||||||
;;<Text>Simvastatin</Text>
|
;;<Text>@@MEDICATIONBRANDNAMETEXT@@</Text>
|
||||||
;;<Code>
|
;;<Code>
|
||||||
;;<Value>00093715510</Value>
|
;;<Value>@@MEDICATIONBRANDNAMECODEVALUE@@</Value>
|
||||||
;;<CodingSystem>NDC</CodingSystem>
|
;;<CodingSystem>@@MEDICATIONBRANDNAMECODINGSYSTEM@@</CodingSystem>
|
||||||
;;<Version>2005</Version>
|
;;<Version>@@MEDICATIONBRANDNAMECODEVERSION@@</Version>
|
||||||
;;</Code>
|
;;</Code>
|
||||||
;;</BrandName>
|
;;</BrandName>
|
||||||
;;<Strength>
|
;;<Strength>
|
||||||
;;<Value>40</Value>
|
;;<Value>@@MEDICATIONSTRENGTHVALUE@@</Value>
|
||||||
;;<Units>
|
;;<Units>
|
||||||
;;<Unit>mg</Unit>
|
;;<Unit>@@MEDICATIONSTRENGTHUNIT@@</Unit>
|
||||||
;;</Units>
|
;;</Units>
|
||||||
;;</Strength>
|
;;</Strength>
|
||||||
;;<Form>
|
;;<Form>
|
||||||
;;<Text>tablet</Text>
|
;;<Text>@@MEDICATIONFORMTEXT@@</Text>
|
||||||
;;</Form>
|
;;</Form>
|
||||||
;;</Product>
|
;;</Product>
|
||||||
;;<Directions>
|
;;<Directions>
|
||||||
;;<Direction>
|
;;<Direction>
|
||||||
;;<Description>
|
;;<Description>
|
||||||
;;<Text>1 PO 1 time per day</Text>
|
;;<Text>@@MEDICATIONDIRECTIONDESCRIPTIONTEXT@@</Text>
|
||||||
;;</Description>
|
;;</Description>
|
||||||
;;<Dose>
|
;;<Dose>
|
||||||
;;<Value>1</Value>
|
;;<Value>@@MEDICATIONDIRECTIONDOSEVALUE@@</Value>
|
||||||
;;</Dose>
|
;;</Dose>
|
||||||
;;<Route>
|
;;<Route>
|
||||||
;;<Text>PO</Text>
|
;;<Text>@@MEDICATIONDIRECTIONROUTETEXT@@</Text>
|
||||||
;;</Route>
|
;;</Route>
|
||||||
;;<Frequency>
|
;;<Frequency>
|
||||||
;;<Value>1 time per day</Value>
|
;;<Value>@@MEDICATIONDIRECTIONFREQUENCYVALUE@@</Value>
|
||||||
;;</Frequency>
|
;;</Frequency>
|
||||||
;;</Direction>
|
;;</Direction>
|
||||||
;;</Directions>
|
;;</Directions>
|
||||||
|
@ -369,104 +369,46 @@ LOAD(ARY) ; LOAD A CCR TEMPLATE INTO ARY PASSED BY NAME
|
||||||
;;</Medications>
|
;;</Medications>
|
||||||
;;<VitalSigns>
|
;;<VitalSigns>
|
||||||
;;<Result>
|
;;<Result>
|
||||||
;;<CCRDataObjectID>@@DATAOBJECTID@@</CCRDataObjectID>
|
;;<CCRDataObjectID>@@VITALSIGNSDATAOBJECTID@@</CCRDataObjectID>
|
||||||
;;<DateTime>
|
;;<DateTime>
|
||||||
;;<Type>
|
;;<Type>
|
||||||
;;<Text>Assessment Time</Text>
|
;;<Text>@@VITALSIGNSDATETIMETYPETEXT@@</Text>
|
||||||
;;</Type>
|
;;</Type>
|
||||||
;;<ExactDateTime>@@HEIGHTWEIGHTDATATIME@@</ExactDateTime>
|
;;<ExactDateTime>@@VITALSIGNSEXACTDATETIME@@</ExactDateTime>
|
||||||
;;</DateTime>
|
;;</DateTime>
|
||||||
;;<Description>
|
;;<Description>
|
||||||
;;<Text>Height & Weight</Text>
|
;;<Text>@@VITALSIGNSDESCRIPTIONTEXT@@</Text>
|
||||||
;;</Description>
|
;;</Description>
|
||||||
;;<Source>
|
;;<Source>
|
||||||
;;<Actor>
|
;;<Actor>
|
||||||
;;<ActorID>@@HEIGHTWEIGHTSOURCE@@</ActorID>
|
;;<ActorID>@@VITALSIGNSSOURCEACTORID@@</ActorID>
|
||||||
;;</Actor>
|
;;</Actor>
|
||||||
;;</Source>
|
;;</Source>
|
||||||
;;<Test>
|
;;<Test>
|
||||||
;;<CCRDataObjectID>@@DATAOBJECTID@@</CCRDataObjectID>
|
;;<CCRDataObjectID>@@VITALSIGNSTESTOBJECTID@@</CCRDataObjectID>
|
||||||
;;<Type>
|
;;<Type>
|
||||||
;;<Text>Observation</Text>
|
;;<Text>@@VITALSIGNSTESTTYPETEXT@@</Text>
|
||||||
;;</Type>
|
;;</Type>
|
||||||
;;<Description>
|
;;<Description>
|
||||||
;;<Text>Height</Text>
|
;;<Text>@@VITALSIGNSDESCRIPTIONTEXT@@</Text>
|
||||||
;;<Code>
|
;;<Code>
|
||||||
;;<Value>50373000</Value>
|
;;<Value>@@VITALSIGNSDESCRIPTIONCODEVALUE@@</Value>
|
||||||
;;<CodingSystem>SNOMED</CodingSystem>
|
;;<CodingSystem>@@VITALSIGNSDESCRIPTIONCODINGSYSTEM@@</CodingSystem>
|
||||||
;;<Version>2006</Version>
|
;;<Version>@@VITALSIGNSCODEVERSION@@</Version>
|
||||||
;;</Code>
|
;;</Code>
|
||||||
;;</Description>
|
;;</Description>
|
||||||
;;<Source>
|
;;<Source>
|
||||||
;;<Actor>
|
;;<Actor>
|
||||||
;;<ActorID>@@HEIGHTSOURCEID@@</ActorID>
|
;;<ActorID>@@VITALSIGNSTESTSOURCEACTORID@@</ActorID>
|
||||||
;;</Actor>
|
;;</Actor>
|
||||||
;;</Source>
|
;;</Source>
|
||||||
;;<TestResult>
|
;;<TestResult>
|
||||||
;;<Value>@@HEIGHTINCHES@@</Value>
|
;;<Value>@@VITALSIGNSTESTRESULTVALUE@@</Value>
|
||||||
;;<Units>
|
;;<Units>
|
||||||
;;<Unit>in</Unit>
|
;;<Unit>@@VITALSIGNSTESTRESULTUNIT@@</Unit>
|
||||||
;;</Units>
|
;;</Units>
|
||||||
;;</TestResult>
|
;;</TestResult>
|
||||||
;;</Test>
|
;;</Test>
|
||||||
;;<Test>
|
|
||||||
;;<CCRDataObjectID>@@DATAOBJECTID@@</CCRDataObjectID>
|
|
||||||
;;<Type>
|
|
||||||
;;<Text>Observation</Text>
|
|
||||||
;;</Type>
|
|
||||||
;;<Description>
|
|
||||||
;;<Text>Weight</Text>
|
|
||||||
;;<Code>
|
|
||||||
;;<Value>363808001</Value>
|
|
||||||
;;<CodingSystem>SNOMED</CodingSystem>
|
|
||||||
;;<Version>2006</Version>
|
|
||||||
;;</Code>
|
|
||||||
;;</Description>
|
|
||||||
;;<Source>
|
|
||||||
;;<Actor>
|
|
||||||
;;<ActorID>@@WEIGHTSOURCEID@@</ActorID>
|
|
||||||
;;</Actor>
|
|
||||||
;;</Source>
|
|
||||||
;;<TestResult>
|
|
||||||
;;<Value>@@WEIGHTLBS@@</Value>
|
|
||||||
;;<Units>
|
|
||||||
;;<Unit>lb</Unit>
|
|
||||||
;;</Units>
|
|
||||||
;;</TestResult>
|
|
||||||
;;</Test>
|
|
||||||
;;</Result>
|
|
||||||
;;<Result>
|
|
||||||
;;<CCRDataObjectID>@@DATAOBJECTID@@</CCRDataObjectID>
|
|
||||||
;;<Description>
|
|
||||||
;;<Text>Blood Type</Text>
|
|
||||||
;;</Description>
|
|
||||||
;;<Source>
|
|
||||||
;;<Actor>
|
|
||||||
;;<ActorID>@@BLOODTYPESOURCEID@@</ActorID>
|
|
||||||
;;</Actor>
|
|
||||||
;;</Source>
|
|
||||||
;;<Test>
|
|
||||||
;;<CCRDataObjectID>@@DATAOBJECTID@@</CCRDataObjectID>
|
|
||||||
;;<Type>
|
|
||||||
;;<Text>Result</Text>
|
|
||||||
;;</Type>
|
|
||||||
;;<Description>
|
|
||||||
;;<Text>Blood Type</Text>
|
|
||||||
;;<Code>
|
|
||||||
;;<Value>278149003</Value>
|
|
||||||
;;<CodingSystem>SNOMED</CodingSystem>
|
|
||||||
;;<Version>2005</Version>
|
|
||||||
;;</Code>
|
|
||||||
;;</Description>
|
|
||||||
;;<Source>
|
|
||||||
;;<Actor>
|
|
||||||
;;<ActorID>@@BLOODTYPESOURCEID2@@</ActorID>
|
|
||||||
;;</Actor>
|
|
||||||
;;</Source>
|
|
||||||
;;<TestResult>
|
|
||||||
;;<Value>@@BLOODTYPERESULT@@</Value>
|
|
||||||
;;</TestResult>
|
|
||||||
;;</Test>
|
|
||||||
;;</Result>
|
;;</Result>
|
||||||
;;</VitalSigns>
|
;;</VitalSigns>
|
||||||
;;<HealthCareProviders>
|
;;<HealthCareProviders>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
GPLVITALS ; CCDCCR/GPL - CCR/CCD PROCESSING FOR VITALS ; 6/6/08
|
GPLVITALS ; CCDCCR/CJE - CCR/CCD PROCESSING FOR VITALS ; 07/03/08
|
||||||
;;0.1;CCDCCR;nopatch;noreleasedate
|
;;0.1;CCDCCR;;JUL 3,2008;
|
||||||
EXTRACT(VITXML,DFN,VITOUTXML) ; EXTRACT PROBLEMS INTO PROVIDED XML TEMPLATE
|
EXTRACT(VITXML,DFN,VITOUTXML) ; EXTRACT PROBLEMS INTO PROVIDED XML TEMPLATE
|
||||||
;
|
;
|
||||||
; VITXML AND OUTXML ARE PASSED BY NAME SO GLOBALS CAN BE USED
|
; VITXML AND OUTXML ARE PASSED BY NAME SO GLOBALS CAN BE USED
|
||||||
|
@ -17,15 +17,53 @@ EXTRACT(VITXML,DFN,VITOUTXML) ; EXTRACT PROBLEMS INTO PROVIDED XML TEMPLATE
|
||||||
. . K @VITVMAP
|
. . K @VITVMAP
|
||||||
. . I DEBUG W "VMAP= ",VMAP,!
|
. . I DEBUG W "VMAP= ",VMAP,!
|
||||||
. . S VITPTMP=VITRSLT(J) ; PULL OUT VITAL FROM RPC RETURN ARRAY
|
. . S VITPTMP=VITRSLT(J) ; PULL OUT VITAL FROM RPC RETURN ARRAY
|
||||||
. . S @VITVMAP@("DATAOBJECTID")="VITAL"_J ; UNIQUE OBJID FOR VITAL
|
. . S @VITVMAP@("VITALSIGNSDATAOBJECTID")="VITAL"_J ; UNIQUE OBJID FOR VITAL
|
||||||
. . I $P(VITPTMP,U,2)="HT" D
|
. . I $P(VITPTMP,U,2)="HT" D
|
||||||
. . . S @VITVMAP@("HEIGHTWEIGHTDATATIME")=$P(VITPTMP,U,4)
|
. . . S @VITVMAP@("VITALSIGNSDATETIMETYPETEXT")="OBSERVED"
|
||||||
. . . S @VITVMAP@("HEIGHTWEIGHTSOURCE")=$P(VITPTMP,U,7)
|
. . . S @VITVMAP@("VITALSIGNSEXACTDATETIME")=$$FMDTOUTC^CCRUTIL($P(VITPTMP,U,4),"DT")
|
||||||
. . . S @VITVMAP@("HEIGHTSOURCEID")=$P(VITPTMP,U,1)
|
. . . W "CONVERTED DATE TIME: ",@VITVMAP@("VITALSIGNSEXACTDATETIME"),!
|
||||||
. . . S @VITVMAP@("HEIGHTINCHES")=$P(VITPTMP,U,3)
|
. . . S @VITVMAP@("VITALSIGNSDESCRIPTIONTEXT")="HEIGHT"
|
||||||
. . I $P(VITPTMP,U,2)="WT" D
|
. . . ;S @VITVMAP@("VITALSIGNSSOURCEACTORID")=""
|
||||||
. . . S @VITVMAP@("WEIGHTSOURCEID")=$P(VITPTMP,U,1)
|
. . . S @VITVMAP@("VITALSIGNSTESTOBJECTID")="VITALTEST"_J
|
||||||
. . . S @VITVMAP@("WEIGHTLBS")=$P(VITPTMP,U,3)
|
. . . S @VITVMAP@("VITALSIGNSTESTTYPETEXT")="OBSERVED"
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSDESCRIPTIONTEXT")="HEIGHT"
|
||||||
|
. . . ;S @VITVMAP@("VITALSIGNSDESCRIPTIONCODEVALUE")=""
|
||||||
|
. . . ;S @VITVMAP@("VITALSIGNSDESCRIPTIONCODINGSYSTEM")=""
|
||||||
|
. . . ;S @VITVMAP@("VITALSIGNSDESCRIPTIONCODEVERSION")=""
|
||||||
|
. . . ;S @VITVMAP@("VITALSIGNSTESTSOURCEACTORID")=""
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSTESTRESULTVALUE")=$P(VITPTMP,U,3)
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSTESTRESULTUNIT")="in"
|
||||||
|
. . . ;S @VITVMAP@("HEIGHTWEIGHTSOURCE")=$P(VITPTMP,U,7)
|
||||||
|
. . E I $P(VITPTMP,U,2)="WT" D
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSDATETIMETYPETEXT")="OBSERVED"
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSEXACTDATETIME")=$$FMDTOUTC^CCRUTIL($P(VITPTMP,U,4),"DT")
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSDESCRIPTIONTEXT")="WEIGHT"
|
||||||
|
. . . ;S @VITVMAP@("VITALSIGNSSOURCEACTORID")=""
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSTESTOBJECTID")="VITALTEST"_J
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSTESTTYPETEXT")="OBSERVED"
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSDESCRIPTIONTEXT")="WEIGHT"
|
||||||
|
. . . ;S @VITVMAP@("VITALSIGNSDESCRIPTIONCODEVALUE")=""
|
||||||
|
. . . ;S @VITVMAP@("VITALSIGNSDESCRIPTIONCODINGSYSTEM")=""
|
||||||
|
. . . ;S @VITVMAP@("VITALSIGNSDESCRIPTIONCODEVERSION")=""
|
||||||
|
. . . ;S @VITVMAP@("VITALSIGNSTESTSOURCEACTORID")=""
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSTESTRESULTVALUE")=$P(VITPTMP,U,3)
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSTESTRESULTUNIT")="lbs"
|
||||||
|
. . E D
|
||||||
|
. . . ;W "IN VITAL: OTHER",!
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSDATETIMETYPETEXT")="OBSERVED"
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSEXACTDATETIME")=$$FMDTOUTC^CCRUTIL($P(VITPTMP,U,4),"DT")
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSDESCRIPTIONTEXT")="OTHER VITAL"
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSSOURCEACTORID")=""
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSTESTOBJECTID")="VITALTEST"_J
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSTESTTYPETEXT")="OBSERVED"
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSDESCRIPTIONTEXT")="OTHER"
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSDESCRIPTIONCODEVALUE")=""
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSDESCRIPTIONCODINGSYSTEM")=""
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSDESCRIPTIONCODEVERSION")=""
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSTESTSOURCEACTORID")=""
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSTESTRESULTVALUE")=$P(VITPTMP,U,3)
|
||||||
|
. . . S @VITVMAP@("VITALSIGNSTESTRESULTUNIT")="UNKNOWN"
|
||||||
|
. . . ;S @VITVMAP@("HEIGHTWEIGHTSOURCE")=$P(VITPTMP,U,7)
|
||||||
. . S VITARYTMP=$NA(@VITTARYTMP@(J))
|
. . S VITARYTMP=$NA(@VITTARYTMP@(J))
|
||||||
. . K @VITARYTMP
|
. . K @VITARYTMP
|
||||||
. . D MAP^GPLXPATH(VITXML,VITVMAP,VITARYTMP)
|
. . D MAP^GPLXPATH(VITXML,VITVMAP,VITARYTMP)
|
||||||
|
@ -37,13 +75,11 @@ EXTRACT(VITXML,DFN,VITOUTXML) ; EXTRACT PROBLEMS INTO PROVIDED XML TEMPLATE
|
||||||
. . . D INSINNER^GPLXPATH(VITOUTXML,VITARYTMP)
|
. . . D INSINNER^GPLXPATH(VITOUTXML,VITARYTMP)
|
||||||
; ZWR ^TMP($J,"VITALS",*)
|
; ZWR ^TMP($J,"VITALS",*)
|
||||||
; ZWR ^TMP($J,"VITALARYTMP",*) ; SHOW THE RESULTS
|
; ZWR ^TMP($J,"VITALARYTMP",*) ; SHOW THE RESULTS
|
||||||
; W "OUT OF FOR LOOP.",!
|
|
||||||
;ZWR
|
|
||||||
; ZWR @OUTXML
|
; ZWR @OUTXML
|
||||||
; $$HTML^DILF(
|
|
||||||
N VITTMP,I
|
N VITTMP,I
|
||||||
D MISSING^GPLXPATH(VITXML,"VITTMP") ; SEARCH XML FOR MISSING VARS
|
D MISSING^GPLXPATH(VITOUTXML,"VITTMP") ; SEARCH XML FOR MISSING VARS
|
||||||
I VITTMP(0)>0 D ; IF THERE ARE MISSING VARS - MARKED AS @@X@@
|
I VITTMP(0)>0 D ; IF THERE ARE MISSING VARS - MARKED AS @@X@@
|
||||||
. W "VITALS MISSING ",!
|
. W "VITALS MISSING ",!
|
||||||
. F I=1:1:VITTMP(0) W VITTMP(I),!
|
. F I=1:1:VITTMP(0) W VITTMP(I),!
|
||||||
Q
|
Q
|
||||||
|
;
|
||||||
|
|
Loading…
Reference in New Issue