APCHS11E ; IHS/CMI/LAB - HEALTH SUMMARY SURVEILLANCE ;
;;2.0;IHS PCC SUITE;;MAY 14, 2009
;
; ******************** SURVEILLANCE - HARD CODE ********************
HH ;HCT/HGB
Q:APCHSAGE'<18&(APCHSEX="M")
Q:APCHSAGE'<45&(APCHSEX="F")
K APCHSLDT
S APCHSLAB="HCT" D LABDFN^APCHS11 D:APCHSLBD MULTLAB^APCHS11
S APCHSLAB="HGB" D LABDFN^APCHS11 D:APCHSLBD MULTLAB^APCHS11
S APCHSLAB="CBC" D LABDFN^APCHS11 D:APCHSLBD MULTLAB^APCHS11
Q:'APCHSLBD
S APCHSDIS="HCT/HGB"
S APCHSIVD=$O(APCHSLDT(""))
I 'APCHSIVD,APCHSAGE'<1 S APCHSDUE="MAY BE DUE NOW",APCHSDAT="" D DISPLAY^APCHS11 Q
I 'APCHSIVD,APCHSAGE'>1 S X1=APCHSDOB,X2=365 D C^%DTC S Y=X X APCHSCVD S APCHSDUE=Y,APCHSDAT="" D DISPLAY^APCHS11 Q
D PASTAGE^APCHS11
I APCHSAGE'>1,APCHSOLD'>(9/12) S X1=APCHSDOB,X2=365*12 D C^%DTC S Y=X X APCHSCVD S APCHSDUE=Y D GETDATE^APCHS11,DISPLAY^APCHS11 Q
I APCHSAGE'>4,APCHSOLD'>3 S X1=APCHSDOB,X2=365*4 D C^%DTC S Y=X X APCHSCVD S APCHSDUE=Y D GETDATE^APCHS11,DISPLAY^APCHS11 Q
I APCHSAGE'>12,APCHSOLD'>10 S X1=APCHSDOB,X2=365*12 D C^%DTC S Y=X X APCHSCVD S APCHSDUE=Y D GETDATE^APCHS11,DISPLAY^APCHS11 Q
I APCHSAGE>16,APCHSEX="F" I APCHSOLD'>15 S APCHSDUE="MAY BE DUE NOW" D GETDATE^APCHS11,DISPLAY^APCHS11 Q
I APCHSAGE>16,APCHSEX="F" S APCHSINT=365 D GETDATE^APCHS11,COMPARE^APCHS11,DISPLAY^APCHS11
Q
;
CHOL ;
K APCHSEXD,APCHSDF1,APCHSTEX
Q:APCHSAGE>65
I APCHSEX="M",APCHSAGE<35 Q
I APCHSEX="F",APCHSAGE<45 Q ;do not display for women under 45
S APCHSLAB="CHOLESTEROL"
D LABDFN^APCHS11
Q:'APCHSLBD
S APCHSDIS="CHOLESTEROL"
S APCHSINT=365*5
D REGLAB^APCHS11
Q
;
OCCULT ;EP to do occult blood maintanence item
Q:APCHSAGE<50 ;do not display if patient is under 50 yrs old
K APCHSLDT
S APCHSLAB="FECAL OCCULT BLOOD" D LABDFN^APCHS11 D:APCHSLBD MULTLAB^APCHS11
S APCHSLAB="GUAIAC" D LABDFN^APCHS11 D:APCHSLBD MULTLAB^APCHS11
S APCHSLAB="OCCULT BLOOD" D LABDFN^APCHS11 D:APCHSLBD MULTLAB^APCHS11
S APCHSLAB="HEMOCCULT" D LABDFN^APCHS11 D:APCHSLBD MULTLAB^APCHS11
S APCHSLAB="FECULT" D LABDFN^APCHS11 D:APCHSLBD MULTLAB^APCHS11
S APCHSDIS="FECAL OCCULT BLOOD"
S APCHSIVD=$O(APCHSLDT(""))
I 'APCHSIVD S APCHSDUE="MAY BE DUE NOW",APCHSDAT="" D DISPLAY^APCHS11 Q
S APCHSINT=365
D GETDATE^APCHS11
D COMPARE^APCHS11,DISPLAY^APCHS11 I 1
E D DISPLAY^APCHS11
Q