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

AGED7.m

Go to the documentation of this file.
AGED7 ; IHS/ASDS/EFG - EDIT - PAGE 7 (PRIVATE INSURANCE) ;  
 ;;7.1;PATIENT REGISTRATION;;AUG 25,2005
 ;
VAR ;
 I $D(DIRUT) G END
 I AGOPT(5)'="Y" G END:$D(AGXTERN)!$D(DUOUT)!$D(DLOUT) G END
 S AG("PG")=7,AG("LINE")="=" K AG("EDIT"),AG("ALPHORD")
L1 ;
 I $D(AGSEENLY) S AGINSPTR=$P($P(AGINSREC,U,11),",",3) G L4DATA
 I '$D(AGSEENLY)&($G(AGADDINS)="E") S AGINSPTR=$P($P(AGINSREC,U,11),",",3) G L3
L11 ;
L1A S AG("EDIT")="",AG("DFLT")="NO" D ADDCOV^AG7 Q  ;agpatch set from PI Elig file fields
L3 W !
 S:$G(AGINSPTR)="" AGINSPTR=$G(AGEL("IN"))
 I $G(AGINSPTR)="" Q
 S DIC=9000006.11,AG("TOTAL")=0,DA=DFN
ALPHORD ;
L4 ;
L4DATA ;
 S AGELP("HRN")=$G(AGCHRT),AGELP("TYPE")="PI",AGELP("PDFN")=DFN
 S AGELP("PH")=$S('$D(^AUPNPRVT(DFN,11,AGINSPTR,0)):"",1:$P(^(0),U,8)),AGELP("INS")=$S(AGELP("PH")]"":$P(^(0),U),1:"")
 ;Q:$G(AGELP("PH"))=""
 I '$D(AGSEENLY),$D(AGELP("PH"))]"",$D(AGELP("INS"))]"" D DISP^AGEL Q:$G(Y)=AGOPT("ESCAPE")  G VAR
 I $D(AGSEENLY),(AGELP("PH")]""),(AGELP("INS")]"") D DISP^AGEL
 Q:$G(Y)=AGOPT("ESCAPE")
 G END:$D(AGSEENLY)
L4DATA1 ;
L4A ;
L5 ;
L6 ;
L7 ;
END I $D(DTOUT) S AGTOUT=""
 K AG,AGI,AGY,DUOUT,DFOUT,DQOUT,DTOUT,DLOUT,DA,DIC,DIE,DR,DRENT
 K AG("DRENT1"),AGL,AG("LKERR"),AG("LKPRINT"),Y
 Q:$D(AGXTERN)
 Q:$D(DIROUT)
 K DIR
 Q
UP Q:$D(AGXTERN)
 Q
EDIT S DIE="^AUPNPRVT("_DFN_",11,"
 S DA=AGINSPTR,DA(1)=DFN
 W !
 D ^DIE
 Q
DATA W !,AG("N"),".",?22-$L(AG("L")),AG("L"),":"
 D ^AGDICLK
 Q:$D(AG("LKERR"))
 W ?26,AG("LKPRINT")
 Q
PRVTKILL ;
 Q