Changeset 396 for ccr/trunk/p
- Timestamp:
- Mar 15, 2009, 8:14:48 PM (16 years ago)
- Location:
- ccr/trunk/p
- Files:
-
- 16 edited
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
ccr/trunk/p/C0CALERT.m
r391 r396 110 110 . D GETN1^C0CRNF("C0CG1",120.8,DFN,"B") ;GET VALUES BY NAME 111 111 . S C0CT=$$ZVALUEI^C0CRNF("ORIGINATION DATE/TIME","C0CG1") 112 . S @ALTVMAP@("ALERTDATETIME")=$$FMDTOUTC^C CRUTIL(C0CT)112 . S @ALTVMAP@("ALERTDATETIME")=$$FMDTOUTC^C0CUTIL(C0CT) 113 113 . K @ALTARYTMP 114 114 . D MAP^C0CXPATH(ALTXML,ALTVMAP,ALTARYTMP) -
ccr/trunk/p/C0CCCD.m
r392 r396 184 184 N VMAP S VMAP=$NA(^TMP("C0CCCR",$J,DFN,"HEADER")) 185 185 ; K @VMAP 186 S @VMAP@("DATETIME")=$$FMDTOUTC^C CRUTIL($$NOW^XLFDT,"DT")186 S @VMAP@("DATETIME")=$$FMDTOUTC^C0CUTIL($$NOW^XLFDT,"DT") 187 187 I IHDR="" D ; HEADER ARRAY IS NOT PROVIDED, USE DEFAULTS 188 188 . S @VMAP@("ACTORPATIENT")="ACTORPATIENT_"_DFN -
ccr/trunk/p/C0CCCR.m
r391 r396 145 145 N VMAP S VMAP=$NA(^TMP("C0CCCR",$J,DFN,"HEADER")) 146 146 ; K @VMAP 147 S @VMAP@("DATETIME")=$$FMDTOUTC^C CRUTIL($$NOW^XLFDT,"DT")147 S @VMAP@("DATETIME")=$$FMDTOUTC^C0CUTIL($$NOW^XLFDT,"DT") 148 148 ; I IHDR="" D ; HEADER ARRAY IS NOT PROVIDED, USE DEFAULTS 149 149 D ; ALWAYS MAP THESE VARIABLES -
ccr/trunk/p/C0CIMMU.m
r391 r396 79 79 . . D GETN^C0CRNF("C0CI",9000010.11,C0CIEN) ; GET THE FILEMAN RECORD FOR IENS 80 80 . . W C0CIEN,"_",C0CIMD 81 . . S C0CT=$$FMDTOUTC^C CRUTIL(9999999-C0CIMD,"DT") ; FORMAT DATE/TIME81 . . S C0CT=$$FMDTOUTC^C0CUTIL(9999999-C0CIMD,"DT") ; FORMAT DATE/TIME 82 82 . . W C0CT,! 83 83 . . S @VMAP@("IMMUNEOBJECTID")="IMMUNIZATION_"_C0CC ;UNIQUE OBJECT ID -
ccr/trunk/p/C0CLABS.m
r391 r396 183 183 . . S C0CX1=XV("RESULTASSESSMENTDATETIME") ;DATE TIME IN HL7 FORMAT 184 184 . . S C0CX2=$$HL7TFM^XLFDT(C0CX1,"L") ;FM DT LOCAL 185 . . S XV("RESULTASSESSMENTDATETIME")=$$FMDTOUTC^C CRUTIL(C0CX2,"DT") ;UTC TIME185 . . S XV("RESULTASSESSMENTDATETIME")=$$FMDTOUTC^C0CUTIL(C0CX2,"DT") ;UTC TIME 186 186 . . M @C0CLB@(C0CLI)=XV ; PERSIST THE OBR VARS 187 187 . . S C0CLOBX=0 ; MARK THE BEGINNING OF A NEW SECTION … … 221 221 . . S C0CX1=XV("RESULTTESTDATETIME") ;DATE TIME IN HL7 FORMAT 222 222 . . S C0CX2=$$HL7TFM^XLFDT(C0CX1,"L") ;FM DT LOCAL 223 . . S XV("RESULTTESTDATETIME")=$$FMDTOUTC^C CRUTIL(C0CX2,"DT") ;UTC TIME223 . . S XV("RESULTTESTDATETIME")=$$FMDTOUTC^C0CUTIL(C0CX2,"DT") ;UTC TIME 224 224 . . ; I 'C0CQT ZWR XV 225 225 . . M @C0CLB2@(C0CLOBX)=XV ; PERSIST THE TEST RESULT VARIABLES -
ccr/trunk/p/C0CPROBS.m
r391 r396 54 54 . S @VMAP@("PROBLEMCODINGVERSION")="" 55 55 . S @VMAP@("PROBLEMCODEVALUE")=$P(PTMP,U,4) 56 . S @VMAP@("PROBLEMDATEOFONSET")=$$FMDTOUTC^C CRUTIL($P(PTMP,U,5),"DT")57 . S @VMAP@("PROBLEMDATEMOD")=$$FMDTOUTC^C CRUTIL($P(PTMP,U,6),"DT")56 . S @VMAP@("PROBLEMDATEOFONSET")=$$FMDTOUTC^C0CUTIL($P(PTMP,U,5),"DT") 57 . S @VMAP@("PROBLEMDATEMOD")=$$FMDTOUTC^C0CUTIL($P(PTMP,U,6),"DT") 58 58 . S @VMAP@("PROBLEMSC")=$P(PTMP,U,7) 59 59 . S @VMAP@("PROBLEMSE")=$P(PTMP,U,8) … … 66 66 . S @VMAP@("PROBLEMSERVICE")=$P(PTMP,U,13) 67 67 . S @VMAP@("PROBLEMHASCMT")=$P(PTMP,U,14) 68 . S @VMAP@("PROBLEMDTREC")=$$FMDTOUTC^C CRUTIL($P(PTMP,U,15),"DT")69 . S @VMAP@("PROBLEMINACT")=$$FMDTOUTC^C CRUTIL($P(PTMP,U,16),"DT")68 . S @VMAP@("PROBLEMDTREC")=$$FMDTOUTC^C0CUTIL($P(PTMP,U,15),"DT") 69 . S @VMAP@("PROBLEMINACT")=$$FMDTOUTC^C0CUTIL($P(PTMP,U,16),"DT") 70 70 . S ARYTMP=$NA(@TARYTMP@(J)) 71 71 . ; W "ARYTMP= ",ARYTMP,! -
ccr/trunk/p/C0CRPMS.m
r345 r396 37 37 F S G=$O(^AUPNVSIT("AA",C0CDFN,G)) Q:(G="")!(GN>C0CCNT) D ; 38 38 . S GN=GN+1 39 . W $$FMDTOUTC^C CRUTIL(9999999-G),!39 . W $$FMDTOUTC^C0CUTIL(9999999-G),! 40 40 Q 41 41 ; … … 48 48 F S C0CG=$$NEXTV(C0CDFN,C0CG) Q:(C0CG="")!(GN'<C0CCNT) D ; 49 49 . S GN=GN+1 50 . W $$FMDTOUTC^C CRUTIL(C0CG),!50 . W $$FMDTOUTC^C0CUTIL(C0CG),! 51 51 Q 52 52 ; … … 77 77 N C0CG S C0CG="" 78 78 F S C0CG=$$NEXTV(C0CDFN,C0CG) Q:C0CG="" D ; LOOP BACKWARD THROUGH VISITS 79 . W C0CG," ",$$FMDTOUTC^C CRUTIL(C0CG),!79 . W C0CG," ",$$FMDTOUTC^C0CUTIL(C0CG),! 80 80 . S APCDVLDT=C0CG 81 81 . D ^APCDVLK -
ccr/trunk/p/C0CUTIL.m
r394 r396 1 CCRUTIL ;CCRCCD/SMH - Various Utilites for generating the CCR/CCD;06/15/08 2 ;;0.1;CCRCCD;;Jun 15, 2008; 3 ;Copyright 2008 WorldVistA. Licensed under the terms of the GNU 1 C0CUTIL ;WV/C0C/SMH - Various Utilites for generating the CCR/CCD;06/15/08 2 ;;0.1;C0C;;Jun 15, 2008; 3 ;Copyright 2008-2009 Sam Habiel & George Lily. 4 ;Licensed under the terms of the GNU 4 5 ;General Public License See attached copy of the License. 5 6 ; … … 122 123 Q 123 124 ; 125 RPMS ; Are we running on an RPMS system rather than Vista? 126 Q $G(DUZ("AG")="I") ; If User Agency is Indian Health Service -
ccr/trunk/p/C0CVITAL.m
r391 r396 46 46 D VITDATES(.VDATES) ; PULL OUT THE DATES INTO AN ARRAY 47 47 ; I DEBUG ZWR VDATES ;DEBUG 48 S VCNT=$$SORTDT^C CRUTIL(.VSORT,.VDATES,-1) ; PUT VITALS IN REVERSE48 S VCNT=$$SORTDT^C0CUTIL(.VSORT,.VDATES,-1) ; PUT VITALS IN REVERSE 49 49 ; DATE ORDER AND COUNT THEM. VSORT CONTAINS INDIRECT INDEXES ONLY 50 50 S @VITTVMAP@(0)=VCNT ; SAVE NUMBER OF VITALS … … 56 56 . . S VITPTMP=VITRSLT(VSORT(J)) ; DATE SORTED VITAL FROM RETURN ARRAY 57 57 . . I DEBUG W "VITAL ",VSORT(J),! 58 . . I DEBUG W VITRSLT(VSORT(J))," ",$$FMDTOUTC^C CRUTIL($P(VITPTMP,U,4),"DT"),!58 . . I DEBUG W VITRSLT(VSORT(J))," ",$$FMDTOUTC^C0CUTIL($P(VITPTMP,U,4),"DT"),! 59 59 . . I DEBUG W $P(VITPTMP,U,4),! 60 60 . . S @VITVMAP@("VITALSIGNSDATAOBJECTID")="VITAL"_J ; UNIQUE OBJID 61 61 . . I $P(VITPTMP,U,2)="HT" D 62 62 . . . S @VITVMAP@("VITALSIGNSDATETIMETYPETEXT")="OBSERVED" 63 . . . S @VITVMAP@("VITALSIGNSEXACTDATETIME")=$$FMDTOUTC^C CRUTIL($P(VITPTMP,U,4),"DT")63 . . . S @VITVMAP@("VITALSIGNSEXACTDATETIME")=$$FMDTOUTC^C0CUTIL($P(VITPTMP,U,4),"DT") 64 64 . . . S @VITVMAP@("VITALSIGNSDESCRIPTIONTEXT")="HEIGHT" 65 65 . . . S @VITVMAP@("VITALSIGNSSOURCEACTORID")="ACTORSYSTEM_1" … … 75 75 . . E I $P(VITPTMP,U,2)="WT" D 76 76 . . . S @VITVMAP@("VITALSIGNSDATETIMETYPETEXT")="OBSERVED" 77 . . . S @VITVMAP@("VITALSIGNSEXACTDATETIME")=$$FMDTOUTC^C CRUTIL($P(VITPTMP,U,4),"DT")77 . . . S @VITVMAP@("VITALSIGNSEXACTDATETIME")=$$FMDTOUTC^C0CUTIL($P(VITPTMP,U,4),"DT") 78 78 . . . S @VITVMAP@("VITALSIGNSDESCRIPTIONTEXT")="WEIGHT" 79 79 . . . S @VITVMAP@("VITALSIGNSSOURCEACTORID")="ACTORSYSTEM_1" … … 89 89 . . E I $P(VITPTMP,U,2)="BP" D 90 90 . . . S @VITVMAP@("VITALSIGNSDATETIMETYPETEXT")="OBSERVED" 91 . . . S @VITVMAP@("VITALSIGNSEXACTDATETIME")=$$FMDTOUTC^C CRUTIL($P(VITPTMP,U,4),"DT")91 . . . S @VITVMAP@("VITALSIGNSEXACTDATETIME")=$$FMDTOUTC^C0CUTIL($P(VITPTMP,U,4),"DT") 92 92 . . . S @VITVMAP@("VITALSIGNSDESCRIPTIONTEXT")="BLOOD PRESSURE" 93 93 . . . S @VITVMAP@("VITALSIGNSSOURCEACTORID")="ACTORSYSTEM_1" … … 103 103 . . E I $P(VITPTMP,U,2)="T" D 104 104 . . . S @VITVMAP@("VITALSIGNSDATETIMETYPETEXT")="OBSERVED" 105 . . . S @VITVMAP@("VITALSIGNSEXACTDATETIME")=$$FMDTOUTC^C CRUTIL($P(VITPTMP,U,4),"DT")105 . . . S @VITVMAP@("VITALSIGNSEXACTDATETIME")=$$FMDTOUTC^C0CUTIL($P(VITPTMP,U,4),"DT") 106 106 . . . S @VITVMAP@("VITALSIGNSDESCRIPTIONTEXT")="TEMPERATURE" 107 107 . . . S @VITVMAP@("VITALSIGNSSOURCEACTORID")="ACTORSYSTEM_1" … … 117 117 . . E I $P(VITPTMP,U,2)="R" D 118 118 . . . S @VITVMAP@("VITALSIGNSDATETIMETYPETEXT")="OBSERVED" 119 . . . S @VITVMAP@("VITALSIGNSEXACTDATETIME")=$$FMDTOUTC^C CRUTIL($P(VITPTMP,U,4),"DT")119 . . . S @VITVMAP@("VITALSIGNSEXACTDATETIME")=$$FMDTOUTC^C0CUTIL($P(VITPTMP,U,4),"DT") 120 120 . . . S @VITVMAP@("VITALSIGNSDESCRIPTIONTEXT")="RESPIRATION" 121 121 . . . S @VITVMAP@("VITALSIGNSSOURCEACTORID")="ACTORSYSTEM_1" … … 131 131 . . E I $P(VITPTMP,U,2)="P" D 132 132 . . . S @VITVMAP@("VITALSIGNSDATETIMETYPETEXT")="OBSERVED" 133 . . . S @VITVMAP@("VITALSIGNSEXACTDATETIME")=$$FMDTOUTC^C CRUTIL($P(VITPTMP,U,4),"DT")133 . . . S @VITVMAP@("VITALSIGNSEXACTDATETIME")=$$FMDTOUTC^C0CUTIL($P(VITPTMP,U,4),"DT") 134 134 . . . S @VITVMAP@("VITALSIGNSDESCRIPTIONTEXT")="PULSE" 135 135 . . . S @VITVMAP@("VITALSIGNSSOURCEACTORID")="ACTORSYSTEM_1" … … 145 145 . . E I $P(VITPTMP,U,2)="PN" D 146 146 . . . S @VITVMAP@("VITALSIGNSDATETIMETYPETEXT")="OBSERVED" 147 . . . S @VITVMAP@("VITALSIGNSEXACTDATETIME")=$$FMDTOUTC^C CRUTIL($P(VITPTMP,U,4),"DT")147 . . . S @VITVMAP@("VITALSIGNSEXACTDATETIME")=$$FMDTOUTC^C0CUTIL($P(VITPTMP,U,4),"DT") 148 148 . . . S @VITVMAP@("VITALSIGNSDESCRIPTIONTEXT")="PAIN" 149 149 . . . S @VITVMAP@("VITALSIGNSSOURCEACTORID")="ACTORSYSTEM_1" … … 160 160 . . . ;W "IN VITAL: OTHER",! 161 161 . . . S @VITVMAP@("VITALSIGNSDATETIMETYPETEXT")="OBSERVED" 162 . . . S @VITVMAP@("VITALSIGNSEXACTDATETIME")=$$FMDTOUTC^C CRUTIL($P(VITPTMP,U,4),"DT")162 . . . S @VITVMAP@("VITALSIGNSEXACTDATETIME")=$$FMDTOUTC^C0CUTIL($P(VITPTMP,U,4),"DT") 163 163 . . . S @VITVMAP@("VITALSIGNSDESCRIPTIONTEXT")="OTHER VITAL" 164 164 . . . S @VITVMAP@("VITALSIGNSSOURCEACTORID")="ACTORSYSTEM_1" -
ccr/trunk/p/CCRDPT.m
r175 r396 111 111 N DOB S DOB=$$GET1^DIQ(2,DFN,.03,"I") 112 112 ; Date in FM Date Format. Convert to UTC/ISO 8601. 113 Q $$FMDTOUTC^C CRUTIL(DOB,"D")113 Q $$FMDTOUTC^C0CUTIL(DOB,"D") 114 114 GENDER(DFN) ; Gender/Sex 115 115 Q $$GET1^DIQ(2,DFN,.02) ; -
ccr/trunk/p/CCRMEDS.m
r359 r396 111 111 . S @MEDVMAP@("MEDOBJECTID")="MED"_(MEDCNT) ; UNIQUE OBJID FOR MEDS 112 112 . I $P(MEDPTMP,"^",11)="" S @MEDVMAP@("MEDISSUEDATETXT")="" 113 . E S @MEDVMAP@("MEDISSUEDATETXT")=$$FMDTOUTC^C CRUTIL($P(MEDPTMP,"^",11),"DT") ; GETS LAST FILL DATE113 . E S @MEDVMAP@("MEDISSUEDATETXT")=$$FMDTOUTC^C0CUTIL($P(MEDPTMP,"^",11),"DT") ; GETS LAST FILL DATE 114 114 . S @MEDVMAP@("MEDISSUEDATE")="" 115 115 . S @MEDVMAP@("MEDLASTFILLDATETXT")="" -
ccr/trunk/p/CCRMEDS1.m
r347 r396 60 60 . ; S @MAP@("MEDOBJECTID")="MED"_MED(.01) ;Rx Number 61 61 . S @MAP@("MEDISSUEDATETXT")="Issue Date" 62 . S @MAP@("MEDISSUEDATE")=$$FMDTOUTC^C CRUTIL($P(MED(1),U))62 . S @MAP@("MEDISSUEDATE")=$$FMDTOUTC^C0CUTIL($P(MED(1),U)) 63 63 . S @MAP@("MEDLASTFILLDATETXT")="Last Fill Date" 64 . S @MAP@("MEDLASTFILLDATE")=$$FMDTOUTC^C CRUTIL($P(MED(101),U))64 . S @MAP@("MEDLASTFILLDATE")=$$FMDTOUTC^C0CUTIL($P(MED(101),U)) 65 65 . S @MAP@("MEDRXNOTXT")="Prescription Number" 66 66 . S @MAP@("MEDRXNO")=MED(.01) -
ccr/trunk/p/CCRMEDS2.m
r347 r396 66 66 . S @MAP@("MEDISSUEDATETXT")="Issue Date" 67 67 . ; Field 6 is "Effective date", and we pull it in timson format w/ I 68 . S @MAP@("MEDISSUEDATE")=$$FMDTOUTC^C CRUTIL($$GET1^DIQ(52.41,RXIEN,6,"I"),"DT")68 . S @MAP@("MEDISSUEDATE")=$$FMDTOUTC^C0CUTIL($$GET1^DIQ(52.41,RXIEN,6,"I"),"DT") 69 69 . ; Med never filled; next 4 fields are not applicable. 70 70 . S @MAP@("MEDLASTFILLDATETXT")="" -
ccr/trunk/p/CCRMEDS3.m
r347 r396 65 65 . S @MAP@("MEDISSUEDATETXT")="Documented Date" 66 66 . ; Field 6 is "Effective date", and we pull it in timson format w/ I 67 . S @MAP@("MEDISSUEDATE")=$$FMDTOUTC^C CRUTIL(MED(11,"I"),"DT")67 . S @MAP@("MEDISSUEDATE")=$$FMDTOUTC^C0CUTIL(MED(11,"I"),"DT") 68 68 . ; Med never filled; next 4 fields are not applicable. 69 69 . S @MAP@("MEDLASTFILLDATETXT")="" -
ccr/trunk/p/CCRMEDS4.m
r321 r396 63 63 . S @MAP@("MEDOBJECTID")="MED_INPATIENT_UD"_RXIEN 64 64 . S @MAP@("MEDISSUEDATETXT")="Order Date" 65 . S @MAP@("MEDISSUEDATE")=$$FMDTOUTC^C CRUTIL($P(MED(27),U),"DT")65 . S @MAP@("MEDISSUEDATE")=$$FMDTOUTC^C0CUTIL($P(MED(27),U),"DT") 66 66 . S @MAP@("MEDLASTFILLDATETXT")="" ; For Outpatient 67 67 . S @MAP@("MEDLASTFILLDATE")="" ; For Outpatient -
ccr/trunk/p/CCRMEDS6.m
r374 r396 69 69 . S @MAP@("MEDOBJECTID")="MED"_MEDCNT ; MEDCNT FOR ID 70 70 . S @MAP@("MEDISSUEDATETXT")="Issue Date" 71 . S @MAP@("MEDISSUEDATE")=$$FMDTOUTC^C CRUTIL($P(MEDS(MEDCNT),U,13))71 . S @MAP@("MEDISSUEDATE")=$$FMDTOUTC^C0CUTIL($P(MEDS(MEDCNT),U,13)) 72 72 . S @MAP@("MEDLASTFILLDATETXT")="Last Fill Date" 73 . S @MAP@("MEDLASTFILLDATE")=$$FMDTOUTC^C CRUTIL($P(MEDS(MEDCNT),U,11))73 . S @MAP@("MEDLASTFILLDATE")=$$FMDTOUTC^C0CUTIL($P(MEDS(MEDCNT),U,11)) 74 74 . S @MAP@("MEDRXNOTXT")="Prescription Number" 75 75 . S @MAP@("MEDRXNO")=$P(MEDS(MEDCNT),U,14) -
ccr/trunk/p/CCRVA200.m
r313 r396 1 CCRVA200 ;WV/C CDCCR/SMH - Routine to get Provider Data;07/13/20082 ;;0.1;C CDCCR;;JUL 13, 2007;Build 03 ;Copyright 2008 WorldVistA. Licensed under the terms of the GNU1 CCRVA200 ;WV/C0C/SMH - Routine to get Provider Data;07/13/2008 2 ;;0.1;C0C;;JUL 13, 2007;Build 0 3 ;Copyright 2008 Sam Habiel. Licensed under the terms of the GNU 4 4 ;General Public License See attached copy of the License. 5 5 ;
Note:
See TracChangeset
for help on using the changeset viewer.