Home   Package List   Routine Alphabetical List   Global Alphabetical List   FileMan Files List   FileMan Sub-Files List   Package Component Lists   Package-Namespace Mapping  
Routine: APCLPN1

APCLPN1.m

Go to the documentation of this file.
APCLPN1 ; IHS/CMI/LAB - PROVIDER NARRATIVE LISTING ;
 ;;2.0;IHS PCC SUITE;;MAY 14, 2009
START ;
 S APCLBT=$H
 K ^XTMP("APCLPN",APCLJOB,APCLBTH)
 D XTMP^APCLOSUT("APCLPN","PCC PROV NARR REVIEW")
V ; Run by visit date
 S APCLODAT=APCLSD_".9999" F  S APCLODAT=$O(^AUPNVSIT("B",APCLODAT)) Q:APCLODAT=""!((APCLODAT\1)>APCLED)  D V1
 ;
END ;
 S APCLET=$H
 Q
V1 ;
 S V="" F  S V=$O(^AUPNVSIT("B",APCLODAT,V)) Q:V'=+V  I $D(^AUPNVSIT(V,0)) S APCLVREC=^(0) D
 .K APCLSKIP
 .Q:'$P(APCLVREC,U,9)
 .Q:$P(APCLVREC,U,11)
 .Q:'$D(^AUPNVPOV("AD",V))
 .Q:'$D(^AUPNVPRV("AD",V))
 .S B=0 F  S B=$O(^AUPNVPRV("AD",V,B)) Q:B=""  D
 ..I APCLPRIM,$P(^AUPNVPRV(B,0),U,4)'="P" Q
 ..S P=$P(^AUPNVPRV(B,0),U)
 ..S F=0
 ..D @APCLPSRT
 ..Q:'F
 ..S ^XTMP("APCLPN",APCLJOB,APCLBTH,S,V)=""
 ..Q
 .Q
 Q
 ;
P ;
 I $D(APCLCDIS) S S="" D D Q:S=""
 S S=P,F=1
 Q
 ;
O ;
 Q:APCLPROV'=P
 S S=P,F=1
 Q
 ;
D ;
 Q:'$D(^DIC(6,P))
 S Y=$P(^DIC(6,P,0),U,4)
 Q:Y=""
 Q:APCLDISC'=Y
 S S=APCLDISC
 S F=1
 Q
 ;
A ;
 Q:'$D(^DIC(6,P))
 S Y=$P(^DIC(6,P,0),U,4)
 Q:Y=""
 S S=Y
 S F=1
 Q
 ;