AGED4A3 ; IHS/ASDS/EFG - PAGE 4 - INSURANCE SUMMARY OVERFLOW ; 07 Sep 2005 7:26 AM
;;7.1;PATIENT REGISTRATION;**1,2,12**;AUG 25, 2005;Build 1
;IHS/OIT/NKD AG*7.1*12 INSURER TYPE
;
PRVTINS(AGINSREC) ;EP -
;S:$G(AGINSREC)'="" AGSELECT=AGINSREC
;D ^AGED7
;S NOPVTB=0
;K AGSELECT
;Q:$G(Y)=AGOPT("ESCAPE")
;I '$O(^AUPNPRVT(DFN,11,0)) Q
;I $G(AGINSPTR)'="",($P($G(^AUTNINS(AGINSPTR,2)),U)'="K"),($G(AGELP("PH"))'="") S INSPTR=AGINSPTR D ^AGED7B
;K AGELP
;IHS/SD/TPF AG*7.1*1 NEW CODE
S:$G(AGINSREC)'="" AGSELECT=AGINSREC
S PARDFN=$P($P(AGINSREC,U,11),",")
S PARREC=$P($P(AGINSREC,U,11),",",3)
S POLHPTR=$E($P(AGINSREC,U,7),2,99)
S AGINSPTR=$P(AGINSREC,U,2)
S NEWENTRY=0
D EN^AGEDPRV(PARDFN,PARREC,0,AGINSREC,AGINSPTR,POLHPTR)
Q:$D(DTOUT)!$D(DUOUT)!$D(DIROUT)
Q:$G(Y)=AGOPT("ESCAPE")
I $D(DFOUT) K DFOUT Q ;AG*7.1*2 SO ^^ TAKES USER TO INS. SUMMARY PAGE FROM POL MEM vIEW PAGE
;IS THERE PAGE B INFO?
I '$O(^AUPNPRVT(DFN,11,0)) Q
;I $G(AGINSPTR)'="",($P($G(^AUTNINS(AGINSPTR,2)),U)'="K"),($G(POLHPTR)'="") D EN^AGEDPRVB(PARDFN,PARREC,0,AGINSREC,"","","")
I $G(AGINSPTR)'="",($$INSTYP^AGUTL(AGINSPTR)'="K"),($G(POLHPTR)'="") D EN^AGEDPRVB(PARDFN,PARREC,0,AGINSREC,"","","") ;IHS/OIT/NKD AG*7.1*12
K POLHPTR,AGINSPTR
K PARDFN,PARREC,NEWENTRY,AGSELECT
;END NEW
Q
AGED4A3 ; IHS/ASDS/EFG - PAGE 4 - INSURANCE SUMMARY OVERFLOW ; 07 Sep 2005 7:26 AM
+1 ;;7.1;PATIENT REGISTRATION;**1,2,12**;AUG 25, 2005;Build 1
+2 ;IHS/OIT/NKD AG*7.1*12 INSURER TYPE
+3 ;
PRVTINS(AGINSREC) ;EP -
+1 ;S:$G(AGINSREC)'="" AGSELECT=AGINSREC
+2 ;D ^AGED7
+3 ;S NOPVTB=0
+4 ;K AGSELECT
+5 ;Q:$G(Y)=AGOPT("ESCAPE")
+6 ;I '$O(^AUPNPRVT(DFN,11,0)) Q
+7 ;I $G(AGINSPTR)'="",($P($G(^AUTNINS(AGINSPTR,2)),U)'="K"),($G(AGELP("PH"))'="") S INSPTR=AGINSPTR D ^AGED7B
+8 ;K AGELP
+9 ;IHS/SD/TPF AG*7.1*1 NEW CODE
+10 IF $GET(AGINSREC)'=""
SET AGSELECT=AGINSREC
+11 SET PARDFN=$PIECE($PIECE(AGINSREC,U,11),",")
+12 SET PARREC=$PIECE($PIECE(AGINSREC,U,11),",",3)
+13 SET POLHPTR=$EXTRACT($PIECE(AGINSREC,U,7),2,99)
+14 SET AGINSPTR=$PIECE(AGINSREC,U,2)
+15 SET NEWENTRY=0
+16 DO EN^AGEDPRV(PARDFN,PARREC,0,AGINSREC,AGINSPTR,POLHPTR)
+17 IF $DATA(DTOUT)!$DATA(DUOUT)!$DATA(DIROUT)
QUIT
+18 IF $GET(Y)=AGOPT("ESCAPE")
QUIT
+19 ;AG*7.1*2 SO ^^ TAKES USER TO INS. SUMMARY PAGE FROM POL MEM vIEW PAGE
IF $DATA(DFOUT)
KILL DFOUT
QUIT
+20 ;IS THERE PAGE B INFO?
+21 IF '$ORDER(^AUPNPRVT(DFN,11,0))
QUIT
+22 ;I $G(AGINSPTR)'="",($P($G(^AUTNINS(AGINSPTR,2)),U)'="K"),($G(POLHPTR)'="") D EN^AGEDPRVB(PARDFN,PARREC,0,AGINSREC,"","","")
+23 ;IHS/OIT/NKD AG*7.1*12
IF $GET(AGINSPTR)'=""
IF ($$INSTYP^AGUTL(AGINSPTR)'="K")
IF ($GET(POLHPTR)'="")
DO EN^AGEDPRVB(PARDFN,PARREC,0,AGINSREC,"","","")
+24 KILL POLHPTR,AGINSPTR
+25 KILL PARDFN,PARREC,NEWENTRY,AGSELECT
+26 ;END NEW
+27 QUIT