1 | DGRPX73 ; ;12/27/07
|
---|
2 | D DE G BEGIN
|
---|
3 | DE S DIE="^DPT(",DIC=DIE,DP=2,DL=1,DIEL=0,DU="" K DG,DE,DB Q:$O(^DPT(DA,""))=""
|
---|
4 | I $D(^(.29)) S %Z=^(.29) S %=$P(%Z,U,1) S:%]"" DE(4)=% S %=$P(%Z,U,2) S:%]"" DE(3)=% S %=$P(%Z,U,12) S:%]"" DE(1)=%
|
---|
5 | I $D(^(.3)) S %Z=^(.3) S %=$P(%Z,U,11) S:%]"" DE(12)=%
|
---|
6 | I $D(^(.31)) S %Z=^(.31) S %=$P(%Z,U,3) S:%]"" DE(5)=% S %=$P(%Z,U,4) S:%]"" DE(6)=%
|
---|
7 | I $D(^(.362)) S %Z=^(.362) S %=$P(%Z,U,12) S:%]"" DE(9)=% S %=$P(%Z,U,13) S:%]"" DE(10)=% S %=$P(%Z,U,14) S:%]"" DE(11)=% S %=$P(%Z,U,20) S:%]"" DE(14)=%
|
---|
8 | K %Z Q
|
---|
9 | ;
|
---|
10 | W W !?DL+DL-2,DLB_": "
|
---|
11 | Q
|
---|
12 | O D W W Y W:$X>45 !?9
|
---|
13 | I $L(Y)>19,'DV,DV'["I",(DV["F"!(DV["K")) G RW^DIR2
|
---|
14 | W:Y]"" "// " I 'DV,DV["I",$D(DE(DQ))#2 S X="" W " (No Editing)" Q
|
---|
15 | TR R X:DTIME E S (DTOUT,X)=U W $C(7)
|
---|
16 | Q
|
---|
17 | A K DQ(DQ) S DQ=DQ+1
|
---|
18 | B G @DQ
|
---|
19 | RE G PR:$D(DE(DQ)) D W,TR
|
---|
20 | N I X="" G NKEY:$D(^DD("KEY","F",DP,DIFLD)),A:DV'["R",X:'DV,X:D'>0,A
|
---|
21 | RD G QS:X?."?" I X["^" D D G ^DIE17
|
---|
22 | I X="@" D D G Z^DIE2
|
---|
23 | I X=" ",DV["d",DV'["P",$D(^DISV(DUZ,"DIE",DLB)) S X=^(DLB) I DV'["D",DV'["S" W " "_X
|
---|
24 | T G M^DIE17:DV,^DIE3:DV["V",P:DV'["S" X:$D(^DD(DP,DIFLD,12.1)) ^(12.1) I X?.ANP D SET I 'DDER X:$D(DIC("S")) DIC("S") I W:'$D(DB(DQ)) " "_% G V
|
---|
25 | K DDER G X
|
---|
26 | P I DV["P" S DIC=U_DU,DIC(0)=$E("EN",$D(DB(DQ))+1)_"M"_$E("L",DV'["'") S:DIC(0)["L" DLAYGO=+$P(DV,"P",2) G:DV["*" AST^DIED D NOSCR^DIED S X=+Y,DIC=DIE G X:X<0
|
---|
27 | G V:DV'["N" D D I $L($P(X,"."))>24 K X G Z
|
---|
28 | I $P(DQ(DQ),U,5)'["$",X?.1"-".N.1".".N,$P(DQ(DQ),U,5,99)["+X'=X" S X=+X
|
---|
29 | V D @("X"_DQ) K YS
|
---|
30 | Z K DIC("S"),DLAYGO I $D(X),X'=U D:$G(DE(DW,"INDEX")) SAVEVALS G:'$$KEYCHK UNIQFERR^DIE17 S DG(DW)=X S:DV["d" ^DISV(DUZ,"DIE",DLB)=X G A
|
---|
31 | X W:'$D(ZTQUEUED) $C(7),"??" I $D(DB(DQ)) G Z^DIE17
|
---|
32 | S X="?BAD"
|
---|
33 | QS S DZ=X D D,QQ^DIEQ G B
|
---|
34 | D S D=DIFLD,DQ(DQ)=DLB_U_DV_U_DU_U_DW_U_$P($T(@("X"_DQ))," ",2,99) Q
|
---|
35 | Y I '$D(DE(DQ)) D O G RD:"@"'[X,A:DV'["R"&(X="@"),X:X="@" S X=Y G N
|
---|
36 | PR S DG=DV,Y=DE(DQ),X=DU I $D(DQ(DQ,2)) X DQ(DQ,2) G RP
|
---|
37 | R I DG["P",@("$D(^"_X_"0))") S X=+$P(^(0),U,2) G RP:'$D(^(Y,0)) S Y=$P(^(0),U),X=$P(^DD(X,.01,0),U,3),DG=$P(^(0),U,2) G R
|
---|
38 | I DG["V",+Y,$P(Y,";",2)["(",$D(@(U_$P(Y,";",2)_"0)")) S X=+$P(^(0),U,2) G RP:'$D(^(+Y,0)) S Y=$P(^(0),U) I $D(^DD(+X,.01,0)) S DG=$P(^(0),U,2),X=$P(^(0),U,3) G R
|
---|
39 | X:DG["D" ^DD("DD") I DG["S" S %=$P($P(";"_X,";"_Y_":",2),";") S:%]"" Y=%
|
---|
40 | RP D O I X="" S X=DE(DQ) G A:'DV,A:DC<2,N^DIE17
|
---|
41 | I I DV'["I",DV'["#" G RD
|
---|
42 | D E^DIE0 G RD:$D(X),PR
|
---|
43 | Q
|
---|
44 | SET N DIR S DIR(0)="SV"_$E("o",$D(DB(DQ)))_U_DU,DIR("V")=1
|
---|
45 | I $D(DB(DQ)),'$D(DIQUIET) N DIQUIET S DIQUIET=1
|
---|
46 | D ^DIR I 'DDER S %=Y(0),X=Y
|
---|
47 | Q
|
---|
48 | SAVEVALS S @DIEZTMP@("V",DP,DIIENS,DIFLD,"O")=$G(DE(DQ)) S:$D(^("F"))[0 ^("F")=$G(DE(DQ))
|
---|
49 | I $D(DE(DW,"4/")) S @DIEZTMP@("V",DP,DIIENS,DIFLD,"4/")=""
|
---|
50 | E K @DIEZTMP@("V",DP,DIIENS,DIFLD,"4/")
|
---|
51 | Q
|
---|
52 | NKEY W:'$D(ZTQUEUED) "?? Required key field" S X="?BAD" G QS
|
---|
53 | KEYCHK() Q:$G(DE(DW,"KEY"))="" 1 Q @DE(DW,"KEY")
|
---|
54 | BEGIN S DNM="DGRPX73",DQ=1
|
---|
55 | 1 S DW=".29;12",DV="S",DU="",DLB="RATED INCOMPETENT?",DIFLD=.293
|
---|
56 | S DE(DW)="C1^DGRPX73"
|
---|
57 | S DU="0:NO;1:YES;"
|
---|
58 | G RE
|
---|
59 | C1 G C1S:$D(DE(1))[0 K DB
|
---|
60 | S X=DE(1),DIC=DIE
|
---|
61 | D EVENT^IVMPLOG(DA)
|
---|
62 | C1S S X="" G:DG(DQ)=X C1F1 K DB
|
---|
63 | S X=DG(DQ),DIC=DIE
|
---|
64 | D EVENT^IVMPLOG(DA)
|
---|
65 | C1F1 Q
|
---|
66 | X1 Q
|
---|
67 | 2 D:$D(DG)>9 F^DIE17,DE S Y=U,DQ=2 D X2 D:$D(DIEFIRE)#2 FIREREC^DIE17 G A:$D(Y)[0,A:Y=U S X=Y,DIC(0)="F",DW=DQ G OUT^DIE17
|
---|
68 | X2 S:'X Y=.313
|
---|
69 | Q
|
---|
70 | 3 D:$D(DG)>9 F^DIE17,DE S DQ=3,DW=".29;2",DV="D",DU="",DLB="DATE RULED INCOMPETENT (CIVIL)",DIFLD=.292
|
---|
71 | G RE
|
---|
72 | X3 S %DT="E" D ^%DT S X=Y K:Y<1 X
|
---|
73 | Q
|
---|
74 | ;
|
---|
75 | 4 S DW=".29;1",DV="D",DU="",DLB="DATE RULED INCOMPETENT (VA)",DIFLD=.291
|
---|
76 | G RE
|
---|
77 | X4 S %DT="E" D ^%DT S X=Y K:Y<1 X
|
---|
78 | Q
|
---|
79 | ;
|
---|
80 | 5 S DW=".31;3",DV="FXOa",DU="",DLB="CLAIM NUMBER",DIFLD=.313
|
---|
81 | S DQ(5,2)="S Y(0)=Y S Y=$E(Y,1,10)"
|
---|
82 | S DE(DW)="C5^DGRPX73"
|
---|
83 | G RE
|
---|
84 | C5 G C5S:$D(DE(5))[0 K DB
|
---|
85 | S X=DE(5),DIC=DIE
|
---|
86 | I ($T(AVAFC^VAFCDD01)'="") S VAFCF=".313;" D AVAFC^VAFCDD01(DA)
|
---|
87 | S X=DE(5),DIC=DIE
|
---|
88 | D EVENT^IVMPLOG(DA)
|
---|
89 | S X=DE(5),DIIX=2_U_DIFLD D AUDIT^DIET
|
---|
90 | C5S S X="" G:DG(DQ)=X C5F1 K DB
|
---|
91 | S X=DG(DQ),DIC=DIE
|
---|
92 | I ($T(AVAFC^VAFCDD01)'="") S VAFCF=".313;" D AVAFC^VAFCDD01(DA)
|
---|
93 | S X=DG(DQ),DIC=DIE
|
---|
94 | D EVENT^IVMPLOG(DA)
|
---|
95 | I $D(DE(5))'[0!(^DD(DP,DIFLD,"AUDIT")'="e") S X=DG(DQ),DIIX=3_U_DIFLD D AUDIT^DIET
|
---|
96 | C5F1 Q
|
---|
97 | X5 S DFN=DA D EV^DGLOCK I $D(X) S L=$S($D(^DPT(DA,0)):$P(^(0),U,9),1:X) W:X?1"SS".E " ",L S:X?1"SS".E X=L K:$L(X)>9 X Q:'$D(X) I X'=L K:$L(X)>8!($L(X)<7)!'(X?.N) X
|
---|
98 | I $D(X),X'?.ANP K X
|
---|
99 | Q
|
---|
100 | ;
|
---|
101 | 6 D:$D(DG)>9 F^DIE17,DE S DQ=6,DW=".31;4",DV="*P4'X",DU="",DLB="CLAIM FOLDER LOCATION",DIFLD=.314
|
---|
102 | S DE(DW)="C6^DGRPX73"
|
---|
103 | S DU="DIC(4,"
|
---|
104 | G RE
|
---|
105 | C6 G C6S:$D(DE(6))[0 K DB
|
---|
106 | S X=DE(6),DIC=DIE
|
---|
107 | D KILL^DGREGDD(DA)
|
---|
108 | C6S S X="" G:DG(DQ)=X C6F1 K DB
|
---|
109 | S X=DG(DQ),DIC=DIE
|
---|
110 | D SET^DGREGDD(DA,X)
|
---|
111 | C6F1 Q
|
---|
112 | X6 S DIC("S")="I $$CFLTF^DGREGDD(Y)" D ^DIC K DIC S DIC=DIE,X=+Y K:Y<0 X
|
---|
113 | Q
|
---|
114 | ;
|
---|
115 | 7 S DQ=8 ;@702
|
---|
116 | 8 D:$D(DG)>9 F^DIE17,DE S Y=U,DQ=8 D X8 D:$D(DIEFIRE)#2 FIREREC^DIE17 G A:$D(Y)[0,A:Y=U S X=Y,DIC(0)="F",DW=DQ G OUT^DIE17
|
---|
117 | X8 S:DGDR'["702" Y="@703"
|
---|
118 | Q
|
---|
119 | 9 D:$D(DG)>9 F^DIE17,DE S DQ=9,DW=".362;12",DV="SX",DU="",DLB="RECEIVING A&A BENEFITS?",DIFLD=.36205
|
---|
120 | S DE(DW)="C9^DGRPX73"
|
---|
121 | S DU="Y:YES;N:NO;U:UNKNOWN;"
|
---|
122 | G RE
|
---|
123 | C9 G C9S:$D(DE(9))[0 K DB
|
---|
124 | S X=DE(9),DIC=DIE
|
---|
125 | X ^DD(2,.36205,1,1,2.3) I X S X=DIV S Y(1)=$S($D(^DPT(D0,.362)):^(.362),1:"") S X=$P(Y(1),U,1),X=X S DIU=X K Y S X="" X ^DD(2,.36205,1,1,2.4)
|
---|
126 | S X=DE(9),DIC=DIE
|
---|
127 | S DFN=DA D EN^DGMTCOR K DGMTCOR
|
---|
128 | S X=DE(9),DIC=DIE
|
---|
129 | K DIV S DIV=X,D0=DA,DIV(0)=D0 S Y(0)=X S X='$$TOTCHK^DGLOCK2(DA) I X S X=DIV S Y(1)=$S($D(^DPT(D0,.362)):^(.362),1:"") S X=$P(Y(1),U,20),X=X S DIU=X K Y S X="" X ^DD(2,.36205,1,3,2.4)
|
---|
130 | S X=DE(9),DIC=DIE
|
---|
131 | D AUTOUPD^DGENA2(DA)
|
---|
132 | C9S S X="" G:DG(DQ)=X C9F1 K DB
|
---|
133 | S X=DG(DQ),DIC=DIE
|
---|
134 | X ^DD(2,.36205,1,1,1.3) I X S X=DIV S Y(1)=$S($D(^DPT(D0,.362)):^(.362),1:"") S X=$P(Y(1),U,1),X=X S DIU=X K Y S X="" X ^DD(2,.36205,1,1,1.4)
|
---|
135 | S X=DG(DQ),DIC=DIE
|
---|
136 | S DFN=DA D EN^DGMTCOR K DGMTCOR
|
---|
137 | S X=DG(DQ),DIC=DIE
|
---|
138 | K DIV S DIV=X,D0=DA,DIV(0)=D0 S Y(0)=X S X='$$TOTCHK^DGLOCK2(DA) I X S X=DIV S Y(1)=$S($D(^DPT(D0,.362)):^(.362),1:"") S X=$P(Y(1),U,20),X=X S DIU=X K Y S X="" X ^DD(2,.36205,1,3,1.4)
|
---|
139 | S X=DG(DQ),DIC=DIE
|
---|
140 | D AUTOUPD^DGENA2(DA)
|
---|
141 | C9F1 Q
|
---|
142 | X9 S DFN=DA D MV^DGLOCK I $D(X) S DFN=DA D EV^DGLOCK
|
---|
143 | Q
|
---|
144 | ;
|
---|
145 | 10 D:$D(DG)>9 F^DIE17,DE S DQ=10,DW=".362;13",DV="SX",DU="",DLB="RECEIVING HOUSEBOUND BENEFITS?",DIFLD=.36215
|
---|
146 | S DE(DW)="C10^DGRPX73"
|
---|
147 | S DU="Y:YES;N:NO;U:UNKNOWN;"
|
---|
148 | G RE
|
---|
149 | C10 G C10S:$D(DE(10))[0 K DB
|
---|
150 | S X=DE(10),DIC=DIE
|
---|
151 | X ^DD(2,.36215,1,1,2.3) I X S X=DIV S Y(1)=$S($D(^DPT(D0,.362)):^(.362),1:"") S X=$P(Y(1),U,2),X=X S DIU=X K Y S X="" X ^DD(2,.36215,1,1,2.4)
|
---|
152 | S X=DE(10),DIC=DIE
|
---|
153 | S DFN=DA D EN^DGMTCOR K DGMTCOR
|
---|
154 | S X=DE(10),DIC=DIE
|
---|
155 | K DIV S DIV=X,D0=DA,DIV(0)=D0 S Y(0)=X S X='$$TOTCHK^DGLOCK2(DA) I X S X=DIV S Y(1)=$S($D(^DPT(D0,.362)):^(.362),1:"") S X=$P(Y(1),U,20),X=X S DIU=X K Y S X="" X ^DD(2,.36215,1,3,2.4)
|
---|
156 | S X=DE(10),DIC=DIE
|
---|
157 | D AUTOUPD^DGENA2(DA)
|
---|
158 | C10S S X="" G:DG(DQ)=X C10F1 K DB
|
---|
159 | S X=DG(DQ),DIC=DIE
|
---|
160 | X ^DD(2,.36215,1,1,1.3) I X S X=DIV S Y(1)=$S($D(^DPT(D0,.362)):^(.362),1:"") S X=$P(Y(1),U,2),X=X S DIU=X K Y S X="" X ^DD(2,.36215,1,1,1.4)
|
---|
161 | S X=DG(DQ),DIC=DIE
|
---|
162 | S DFN=DA D EN^DGMTCOR K DGMTCOR
|
---|
163 | S X=DG(DQ),DIC=DIE
|
---|
164 | K DIV S DIV=X,D0=DA,DIV(0)=D0 S Y(0)=X S X='$$TOTCHK^DGLOCK2(DA) I X S X=DIV S Y(1)=$S($D(^DPT(D0,.362)):^(.362),1:"") S X=$P(Y(1),U,20),X=X S DIU=X K Y S X="" X ^DD(2,.36215,1,3,1.4)
|
---|
165 | S X=DG(DQ),DIC=DIE
|
---|
166 | D AUTOUPD^DGENA2(DA)
|
---|
167 | C10F1 Q
|
---|
168 | X10 S DFN=DA D MV^DGLOCK I $D(X) S DFN=DA D EV^DGLOCK
|
---|
169 | Q
|
---|
170 | ;
|
---|
171 | 11 D:$D(DG)>9 F^DIE17,DE S DQ=11,DW=".362;14",DV="SX",DU="",DLB="RECEIVING A VA PENSION?",DIFLD=.36235
|
---|
172 | S DE(DW)="C11^DGRPX73"
|
---|
173 | S DU="Y:YES;N:NO;U:UNKNOWN;"
|
---|
174 | G RE
|
---|
175 | C11 G C11S:$D(DE(11))[0 K DB
|
---|
176 | D ^DGRPX74
|
---|
177 | C11S S X="" G:DG(DQ)=X C11F1 K DB
|
---|
178 | D ^DGRPX75
|
---|
179 | C11F1 Q
|
---|
180 | X11 S DFN=DA D MV^DGLOCK
|
---|
181 | Q
|
---|
182 | ;
|
---|
183 | 12 D:$D(DG)>9 F^DIE17,DE S DQ=12,DW=".3;11",DV="SX",DU="",DLB="RECEIVING VA DISABILITY?",DIFLD=.3025
|
---|
184 | S DE(DW)="C12^DGRPX73"
|
---|
185 | S DU="Y:YES;N:NO;U:UNKNOWN;"
|
---|
186 | G RE
|
---|
187 | C12 G C12S:$D(DE(12))[0 K DB
|
---|
188 | D ^DGRPX76
|
---|
189 | C12S S X="" G:DG(DQ)=X C12F1 K DB
|
---|
190 | D ^DGRPX77
|
---|
191 | C12F1 Q
|
---|
192 | X12 S DFN=DA D MV^DGLOCK I $D(X),X="Y" D EC^DGLOCK1
|
---|
193 | Q
|
---|
194 | ;
|
---|
195 | 13 D:$D(DG)>9 F^DIE17,DE S Y=U,DQ=13 D X13 D:$D(DIEFIRE)#2 FIREREC^DIE17 G A:$D(Y)[0,A:Y=U S X=Y,DIC(0)="F",DW=DQ G OUT^DIE17
|
---|
196 | X13 S:(X'="Y")&($P($G(^DPT(DA,.362)),U,12,14)'["Y") Y=.36265
|
---|
197 | Q
|
---|
198 | 14 D:$D(DG)>9 F^DIE17,DE S DQ=14,DW=".362;20",DV="NJ8,2X",DU="",DLB="TOTAL ANNUAL VA CHECK AMOUNT",DIFLD=.36295
|
---|
199 | S DE(DW)="C14^DGRPX73"
|
---|
200 | G RE
|
---|
201 | C14 G C14S:$D(DE(14))[0 K DB
|
---|
202 | D ^DGRPX78
|
---|
203 | C14S S X="" G:DG(DQ)=X C14F1 K DB
|
---|
204 | D ^DGRPX79
|
---|
205 | C14F1 Q
|
---|
206 | X14 D DOL^DGLOCK2 K:+X'=X&(X'?.N1"."2N)!(X>99999)!(X<0) X I $D(X) S DFN=DA D MV^DGLOCK I $D(X),('$$TOTCHK^DGLOCK2(DFN)) D TOTCKMSG^DGLOCK2 K X
|
---|
207 | Q
|
---|
208 | ;
|
---|
209 | 15 D:$D(DG)>9 F^DIE17 G ^DGRPX710
|
---|