PRCATO9 ; GENERATED FROM 'PRCAP DEBTOR LOCATE' PRINT TEMPLATE (#401) ; 06/27/96 ; (FILE 430, MARGIN=80)
G BEGIN
N W !
T W:$X ! I '$D(DIOT(2)),DN,$D(IOSL),$S('$D(DIWF):1,$P(DIWF,"B",2):$P(DIWF,"B",2),1:1)+$Y'<IOSL,$D(^UTILITY($J,1))#2,^(1)?1U1P1E.E X ^(1)
S DISTP=DISTP+1,DILCT=DILCT+1 D:'(DISTP#100) CSTP^DIO2
Q
DT I $G(DUZ("LANG"))>1,Y W $$OUT^DIALOGU(Y,"DD") Q
I Y W $P("JAN^FEB^MAR^APR^MAY^JUN^JUL^AUG^SEP^OCT^NOV^DEC",U,$E(Y,4,5))_" " W:Y#100 $J(Y#100\1,2)_"," W Y\10000+1700 W:Y#1 " "_$E(Y_0,9,10)_":"_$E(Y_"000",11,12) Q
W Y Q
M D @DIXX
Q
BEGIN ;
S:'$D(DN) DN=1 S DISTP=$G(DISTP),DILCT=$G(DILCT)
I $D(DXS)<9 F X=0:0 S X=$O(^DIPT(401,"DXS",X)) Q:'X S Y=$O(^(X,"")) F X=X:0 Q:Y="" S DXS(X,Y)=^(Y),Y=$O(^(Y))
D N:$X>0 Q:'DN W ?0 W "BILL NO.: "
S X=$G(^PRCA(430,D0,0)) D N:$X>11 Q:'DN W ?11,$E($P(X,U,1),1,15)
D N:$X>39 Q:'DN W ?39 W "DEBTOR: "
D N:$X>49 Q:'DN W ?49 S Y=$P(X,U,9) S C=$P(^DD(430,9,0),U,2) D Y^DIQ:Y S C="," W $E(Y,1,25)
D N:$X>0 Q:'DN W ?0 S X="=",DIP(1)=X S X=79,X1=DIP(1) S %=X,X="" Q:X1="" S $P(X,X1,%\$L(X1)+1)=X1,X=$E(X,1,%) K DIP K:DN Y W X
D N:$X>0 Q:'DN W ?0 W "ABLE TO PAY:"
S X=$G(^PRCA(430,D0,8)) D N:$X>13 Q:'DN W ?13 S Y=$P(X,U,6) W:Y]"" $S($D(DXS(1,Y)):DXS(1,Y),1:Y)
D N:$X>24 Q:'DN W ?24 W "ABLE TO LOCATE:"
D N:$X>41 Q:'DN W ?41 S Y=$P(X,U,7) W:Y]"" $S($D(DXS(2,Y)):DXS(2,Y),1:Y)
D N:$X>49 Q:'DN W ?49 W "DMV LOCA. CHECK:"
D N:$X>67 Q:'DN W ?67 S Y=$P(X,U,18) W:Y]"" $S($D(DXS(3,Y)):DXS(3,Y),1:Y)
D N:$X>0 Q:'DN W ?0 W "POSTAL LOC. DATE SENT:"
D N:$X>23 Q:'DN W ?23 S Y=$P(X,U,8) D DT
D N:$X>39 Q:'DN W ?39 W "POSTAL LOC. DATE REC'D:"
D N:$X>64 Q:'DN W ?64 S Y=$P(X,U,9) D DT
D N:$X>0 Q:'DN W ?0 W "IRS ABLE TO LOCATE:"
D N:$X>22 Q:'DN W ?22 S Y=$P(X,U,10) W:Y]"" $S($D(DXS(4,Y)):DXS(4,Y),1:Y)
D N:$X>39 Q:'DN W ?39 W "IRS LOC. DATE SENT:"
D N:$X>61 Q:'DN W ?61 S Y=$P(X,U,11) D DT
D N:$X>0 Q:'DN W ?0 W "IRS LOC. DATE REC'D:"
W ?22 S Y=$P(X,U,12) D DT
D N:$X>39 Q:'DN W ?39 W "CREDIT REP. ABLE TO PAY:"
D N:$X>65 Q:'DN W ?65 S Y=$P(X,U,13) W:Y]"" $S($D(DXS(5,Y)):DXS(5,Y),1:Y)
D N:$X>0 Q:'DN W ?0 W "CREDIT REPT. DATE SENT:"
D N:$X>24 Q:'DN W ?24 S Y=$P(X,U,14) D DT
D N:$X>39 Q:'DN W ?39 W "CREDIT REP. DATE REC'D:"
D N:$X>64 Q:'DN W ?64 S Y=$P(X,U,15) D DT
D N:$X>0 Q:'DN W ?0 W "PATIENT FOLDER REVIEWED:"
D N:$X>25 Q:'DN W ?25 S Y=$P(X,U,16) W:Y]"" $S($D(DXS(6,Y)):DXS(6,Y),1:Y)
D N:$X>39 Q:'DN W ?39 W "DATE FOLDER REVIEWED:"
D N:$X>62 Q:'DN W ?62 S Y=$P(X,U,17) D DT
D T Q:'DN D N D N:$X>0 Q:'DN W ?0 W "LETTER1:"
S X=$G(^PRCA(430,D0,6)) D N:$X>9 Q:'DN W ?9 S Y=$P(X,U,1) D DT
D N:$X>25 Q:'DN W ?25 W "LETTER2:"
D N:$X>34 Q:'DN W ?34 S Y=$P(X,U,2) D DT
D N:$X>52 Q:'DN W ?52 W "LETTER3:"
D N:$X>61 Q:'DN W ?61 S Y=$P(X,U,3) D DT
D N:$X>0 Q:'DN W ?0 S X="=",DIP(1)=X S X=79,X1=DIP(1) S %=X,X="" Q:X1="" S $P(X,X1,%\$L(X1)+1)=X1,X=$E(X,1,%) K DIP K:DN Y W X
K Y
Q
HEAD ;
W !,"--------------------------------------------------------------------------------",!!
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HPRCATO9 3048 printed Dec 13, 2024@01:41:40 Page 2
PRCATO9 ; GENERATED FROM 'PRCAP DEBTOR LOCATE' PRINT TEMPLATE (#401) ; 06/27/96 ; (FILE 430, MARGIN=80)
+1 GOTO BEGIN
N WRITE !
T if $X
WRITE !
IF '$DATA(DIOT(2))
IF DN
IF $DATA(IOSL)
IF $SELECT('$DATA(DIWF):1,$PIECE(DIWF,"B",2):$PIECE(DIWF,"B",2),1:1)+$Y'<IOSL
IF $DATA(^UTILITY($JOB,1))#2
IF ^(1)?1U1P1E.E
XECUTE ^(1)
+1 SET DISTP=DISTP+1
SET DILCT=DILCT+1
if '(DISTP#100)
DO CSTP^DIO2
+2 QUIT
DT IF $GET(DUZ("LANG"))>1
IF Y
WRITE $$OUT^DIALOGU(Y,"DD")
QUIT
+1 IF Y
WRITE $PIECE("JAN^FEB^MAR^APR^MAY^JUN^JUL^AUG^SEP^OCT^NOV^DEC",U,$EXTRACT(Y,4,5))_" "
if Y#100
WRITE $JUSTIFY(Y#100\1,2)_","
WRITE Y\10000+1700
if Y#1
WRITE " "_$EXTRACT(Y_0,9,10)_":"_$EXTRACT(Y_"000",11,12)
QUIT
+2 WRITE Y
QUIT
M DO @DIXX
+1 QUIT
BEGIN ;
+1 if '$DATA(DN)
SET DN=1
SET DISTP=$GET(DISTP)
SET DILCT=$GET(DILCT)
+2 IF $DATA(DXS)<9
FOR X=0:0
SET X=$ORDER(^DIPT(401,"DXS",X))
if 'X
QUIT
SET Y=$ORDER(^(X,""))
FOR X=X:0
if Y=""
QUIT
SET DXS(X,Y)=^(Y)
SET Y=$ORDER(^(Y))
+3 if $X>0
DO N
if 'DN
QUIT
WRITE ?0
WRITE "BILL NO.: "
+4 SET X=$GET(^PRCA(430,D0,0))
if $X>11
DO N
if 'DN
QUIT
WRITE ?11,$EXTRACT($PIECE(X,U,1),1,15)
+5 if $X>39
DO N
if 'DN
QUIT
WRITE ?39
WRITE "DEBTOR: "
+6 if $X>49
DO N
if 'DN
QUIT
WRITE ?49
SET Y=$PIECE(X,U,9)
SET C=$PIECE(^DD(430,9,0),U,2)
if Y
DO Y^DIQ
SET C=","
WRITE $EXTRACT(Y,1,25)
+7 if $X>0
DO N
if 'DN
QUIT
WRITE ?0
SET X="="
SET DIP(1)=X
SET X=79
SET X1=DIP(1)
SET %=X
SET X=""
if X1=""
QUIT
SET $PIECE(X,X1,%\$LENGTH(X1)+1)=X1
SET X=$EXTRACT(X,1,%)
KILL DIP
if DN
KILL Y
WRITE X
+8 if $X>0
DO N
if 'DN
QUIT
WRITE ?0
WRITE "ABLE TO PAY:"
+9 SET X=$GET(^PRCA(430,D0,8))
if $X>13
DO N
if 'DN
QUIT
WRITE ?13
SET Y=$PIECE(X,U,6)
if Y]""
WRITE $SELECT($DATA(DXS(1,Y)):DXS(1,Y),1:Y)
+10 if $X>24
DO N
if 'DN
QUIT
WRITE ?24
WRITE "ABLE TO LOCATE:"
+11 if $X>41
DO N
if 'DN
QUIT
WRITE ?41
SET Y=$PIECE(X,U,7)
if Y]""
WRITE $SELECT($DATA(DXS(2,Y)):DXS(2,Y),1:Y)
+12 if $X>49
DO N
if 'DN
QUIT
WRITE ?49
WRITE "DMV LOCA. CHECK:"
+13 if $X>67
DO N
if 'DN
QUIT
WRITE ?67
SET Y=$PIECE(X,U,18)
if Y]""
WRITE $SELECT($DATA(DXS(3,Y)):DXS(3,Y),1:Y)
+14 if $X>0
DO N
if 'DN
QUIT
WRITE ?0
WRITE "POSTAL LOC. DATE SENT:"
+15 if $X>23
DO N
if 'DN
QUIT
WRITE ?23
SET Y=$PIECE(X,U,8)
DO DT
+16 if $X>39
DO N
if 'DN
QUIT
WRITE ?39
WRITE "POSTAL LOC. DATE REC'D:"
+17 if $X>64
DO N
if 'DN
QUIT
WRITE ?64
SET Y=$PIECE(X,U,9)
DO DT
+18 if $X>0
DO N
if 'DN
QUIT
WRITE ?0
WRITE "IRS ABLE TO LOCATE:"
+19 if $X>22
DO N
if 'DN
QUIT
WRITE ?22
SET Y=$PIECE(X,U,10)
if Y]""
WRITE $SELECT($DATA(DXS(4,Y)):DXS(4,Y),1:Y)
+20 if $X>39
DO N
if 'DN
QUIT
WRITE ?39
WRITE "IRS LOC. DATE SENT:"
+21 if $X>61
DO N
if 'DN
QUIT
WRITE ?61
SET Y=$PIECE(X,U,11)
DO DT
+22 if $X>0
DO N
if 'DN
QUIT
WRITE ?0
WRITE "IRS LOC. DATE REC'D:"
+23 WRITE ?22
SET Y=$PIECE(X,U,12)
DO DT
+24 if $X>39
DO N
if 'DN
QUIT
WRITE ?39
WRITE "CREDIT REP. ABLE TO PAY:"
+25 if $X>65
DO N
if 'DN
QUIT
WRITE ?65
SET Y=$PIECE(X,U,13)
if Y]""
WRITE $SELECT($DATA(DXS(5,Y)):DXS(5,Y),1:Y)
+26 if $X>0
DO N
if 'DN
QUIT
WRITE ?0
WRITE "CREDIT REPT. DATE SENT:"
+27 if $X>24
DO N
if 'DN
QUIT
WRITE ?24
SET Y=$PIECE(X,U,14)
DO DT
+28 if $X>39
DO N
if 'DN
QUIT
WRITE ?39
WRITE "CREDIT REP. DATE REC'D:"
+29 if $X>64
DO N
if 'DN
QUIT
WRITE ?64
SET Y=$PIECE(X,U,15)
DO DT
+30 if $X>0
DO N
if 'DN
QUIT
WRITE ?0
WRITE "PATIENT FOLDER REVIEWED:"
+31 if $X>25
DO N
if 'DN
QUIT
WRITE ?25
SET Y=$PIECE(X,U,16)
if Y]""
WRITE $SELECT($DATA(DXS(6,Y)):DXS(6,Y),1:Y)
+32 if $X>39
DO N
if 'DN
QUIT
WRITE ?39
WRITE "DATE FOLDER REVIEWED:"
+33 if $X>62
DO N
if 'DN
QUIT
WRITE ?62
SET Y=$PIECE(X,U,17)
DO DT
+34 DO T
if 'DN
QUIT
DO N
if $X>0
DO N
if 'DN
QUIT
WRITE ?0
WRITE "LETTER1:"
+35 SET X=$GET(^PRCA(430,D0,6))
if $X>9
DO N
if 'DN
QUIT
WRITE ?9
SET Y=$PIECE(X,U,1)
DO DT
+36 if $X>25
DO N
if 'DN
QUIT
WRITE ?25
WRITE "LETTER2:"
+37 if $X>34
DO N
if 'DN
QUIT
WRITE ?34
SET Y=$PIECE(X,U,2)
DO DT
+38 if $X>52
DO N
if 'DN
QUIT
WRITE ?52
WRITE "LETTER3:"
+39 if $X>61
DO N
if 'DN
QUIT
WRITE ?61
SET Y=$PIECE(X,U,3)
DO DT
+40 if $X>0
DO N
if 'DN
QUIT
WRITE ?0
SET X="="
SET DIP(1)=X
SET X=79
SET X1=DIP(1)
SET %=X
SET X=""
if X1=""
QUIT
SET $PIECE(X,X1,%\$LENGTH(X1)+1)=X1
SET X=$EXTRACT(X,1,%)
KILL DIP
if DN
KILL Y
WRITE X
+41 KILL Y
+42 QUIT
HEAD ;
+1 WRITE !,"--------------------------------------------------------------------------------",!!