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

APCLOS61.m

Go to the documentation of this file.
APCLOS61 ; IHS/CMI/LAB - ambulatory continued ;
 ;;2.0;IHS PCC SUITE;**11**;MAY 14, 2009;Build 58
 ;
 ;cmi/anch/maw 9/10/2007 code set versioning in APC
 ;
 D PROV
 D POV
 Q
COUNT ;
 I '$D(@X) S @X=0
 S %=@X,%=%+1,@X=%
 Q
PROV ;provider type
 S APCLX=0 F  S APCLX=$O(^AUPNVPRV("AD",APCLVDFN,APCLX)) Q:APCLX'=+APCLX  I $D(^AUPNVPRV(APCLX,0)) D PROV1
 Q
PROV1 ;
 S APCLPROV=$P(^AUPNVPRV(APCLX,0),U)
CHKDISC ;
 I $P(^DD(9000010.06,.01,0),U,2)[200 S APCLDISC=$$PROVCLS^XBFUNC1(APCLPROV) G CHKDISC1
 S APCLY=$P(^DIC(6,APCLPROV,0),U,4)
 I APCLY="" S APCLDISC="DISCIPLINE UNAVAILABLE" G CHKDISC1
 S APCLDISC=$P(^DIC(7,APCLY,0),U) Q:APCLDISC=""
CHKDISC1 S X=APCLP D COUNT
 Q
 ;
POV ;
 S APCLPDFN=0 F  S APCLPDFN=$O(^AUPNVPOV("AD",APCLVDFN,APCLPDFN)) Q:APCLPDFN'=+APCLPDFN  I $D(^AUPNVPOV(APCLPDFN,0)) D POV1
 Q
POV1 ;
 S APCLPOV=$P(^AUPNVPOV(APCLPDFN,0),U)
 Q:'$D(^ICD9(APCLPOV,0))
 ;
 S X=APCLA D COUNT
APC ;
 Q  ;1/6/200 - no longer do this.
 ;S APCLX=$P(^ICD9(APCLPOV,0),U),APCLAPC=APCLAPCD D ^APCLRAPC  ;cmi/anch/maw 9/10/2007 orig line
 S APCLX=$P($$ICDDX^ICDEX(APCLPOV),U,2),APCLAPC=APCLAPCD D ^APCLRAPC  ;cmi/anch/maw 9/10/2007 csv
 S X=APCLH D COUNT
 Q
 ;