source: WorldVistAEHR/trunk/r/ONCOLOGY-ONC/ONCOX8.m@ 1259

Last change on this file since 1259 was 613, checked in by George Lilly, 15 years ago

initial load of WorldVistAEHR

File size: 5.1 KB
RevLine 
[613]1ONCOX8 ; GENERATED FROM 'ONCOX8' PRINT TEMPLATE (#849) ; 08/13/03 ; (FILE 165.5, MARGIN=132)
2 G BEGIN
3N W !
4T 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)
5 S DISTP=DISTP+1,DILCT=DILCT+1 D:'(DISTP#100) CSTP^DIO2
6 Q
7DT I $G(DUZ("LANG"))>1,Y W $$OUT^DIALOGU(Y,"DD") Q
8 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
9 W Y Q
10M D @DIXX
11 Q
12BEGIN ;
13 S:'$D(DN) DN=1 S DISTP=$G(DISTP),DILCT=$G(DILCT)
14 I $D(DXS)<9 M DXS=^DIPT(849,"DXS")
15 S I(0)="^ONCO(165.5,",J(0)=165.5
16 D T Q:'DN D N D N:$X>1 Q:'DN W ?1 W "Chemotherapy Date: "
17 S X=$G(^ONCO(165.5,D0,3)) S Y=$P(X,U,11) S Y(0)=Y S X=Y D DATEOT^ONCOES W $E(Y,1,30)
18 D N:$X>39 Q:'DN W ?39 X DXS(1,9.2) X "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)" K DIP K:DN Y W X
19 D N:$X>59 Q:'DN W ?59 X DXS(2,9.2) X "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)" K DIP K:DN Y W X
20 D N:$X>1 Q:'DN W ?1 W "Reason for No Chemotherapy: "
21 S X=$G(^ONCO(165.5,D0,3)) S Y=$P(X,U,36) W:Y]"" $S($D(DXS(8,Y)):DXS(8,Y),1:Y)
22 D N:$X>6 Q:'DN W ?6 W "Text-Rx-Chemo: "
23 S:'$D(DIWF) DIWF="" S:DIWF'["N" DIWF=DIWF_"N" S X="" S I(1)=17,J(1)=165.5111 F D1=0:0 Q:$O(^ONCO(165.5,D0,17,D1))'>0 S D1=$O(^(D1)) D:$X>24 T Q:'DN D A1
24 G A1R
25A1 ;
26 S X=$G(^ONCO(165.5,D0,17,D1,0)) S DIWL=25,DIWR=130 D ^DIWP
27 Q
28A1R ;
29 D 0^DIWW
30 D ^DIWW
31 D N:$X>1 Q:'DN W ?1 W "Hormone Therapy Date: "
32 S X=$G(^ONCO(165.5,D0,3)) S Y=$P(X,U,14) S Y(0)=Y S X=Y D DATEOT^ONCOES W $E(Y,1,30)
33 D N:$X>39 Q:'DN W ?39 X DXS(3,9.2) X "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)" K DIP K:DN Y W X
34 D N:$X>59 Q:'DN W ?59 X DXS(4,9.2) X "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)" K DIP K:DN Y W X
35 D N:$X>1 Q:'DN W ?1 W "Reason for No Hormone Therapy: "
36 S X=$G(^ONCO(165.5,D0,3)) S Y=$P(X,U,37) W:Y]"" $S($D(DXS(9,Y)):DXS(9,Y),1:Y)
37 D N:$X>6 Q:'DN W ?6 W "Text-Rx-Hormone: "
38 S:'$D(DIWF) DIWF="" S:DIWF'["N" DIWF=DIWF_"N" S X="" S I(1)=18,J(1)=165.5112 F D1=0:0 Q:$O(^ONCO(165.5,D0,18,D1))'>0 S D1=$O(^(D1)) D:$X>26 T Q:'DN D B1
39 G B1R
40B1 ;
41 S X=$G(^ONCO(165.5,D0,18,D1,0)) S DIWL=27,DIWR=130 D ^DIWP
42 Q
43B1R ;
44 D 0^DIWW
45 D ^DIWW
46 D N:$X>1 Q:'DN W ?1 W "Immunotherapy Date: "
47 S X=$G(^ONCO(165.5,D0,3)) S Y=$P(X,U,17) S Y(0)=Y S X=Y D DATEOT^ONCOES W $E(Y,1,30)
48 D N:$X>39 Q:'DN W ?39 X DXS(5,9.2) X "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)" K DIP K:DN Y W X
49 S X=$G(^ONCO(165.5,D0,3)) D N:$X>59 Q:'DN W ?59 S Y=$P(X,U,19) W:Y]"" $S($D(DXS(10,Y)):DXS(10,Y),1:Y)
50 D N:$X>6 Q:'DN W ?6 W "Text-RX-Immunotherapy: "
51 S:'$D(DIWF) DIWF="" S:DIWF'["N" DIWF=DIWF_"N" S X="" S I(1)=20,J(1)=165.5114 F D1=0:0 Q:$O(^ONCO(165.5,D0,20,D1))'>0 S D1=$O(^(D1)) D:$X>32 T Q:'DN D C1
52 G C1R
53C1 ;
54 S X=$G(^ONCO(165.5,D0,20,D1,0)) S DIWL=33,DIWR=130 D ^DIWP
55 Q
56C1R ;
57 D 0^DIWW
58 D ^DIWW
59 D N:$X>1 Q:'DN W ?1 W "Other Therapy Date: "
60 S X=$G(^ONCO(165.5,D0,3)) S Y=$P(X,U,23) S Y(0)=Y S X=Y D DATEOT^ONCOES W $E(Y,1,30)
61 D N:$X>39 Q:'DN W ?39 X DXS(6,9.2) X "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)" K DIP K:DN Y W X
62 D N:$X>59 Q:'DN W ?59 X DXS(7,9.2) X "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)" K DIP K:DN Y W X
63 D N:$X>6 Q:'DN W ?6 W "Text-Rx-Other: "
64 S:'$D(DIWF) DIWF="" S:DIWF'["N" DIWF=DIWF_"N" S X="" S I(1)=21,J(1)=165.5115 F D1=0:0 Q:$O(^ONCO(165.5,D0,21,D1))'>0 S D1=$O(^(D1)) D:$X>24 T Q:'DN D D1
65 G D1R
66D1 ;
67 S X=$G(^ONCO(165.5,D0,21,D1,0)) S DIWL=25,DIWR=130 D ^DIWP
68 Q
69D1R ;
70 D 0^DIWW
71 D ^DIWW
72 D N:$X>6 Q:'DN W ?6 W " " K DIP K:DN Y
73 D N:$X>1 Q:'DN W ?1 W "Protocol Eligibility Status: "
74 S X=$G(^ONCO(165.5,D0,"BLA2")) S Y=$P(X,U,1) W:Y]"" $S($D(DXS(11,Y)):DXS(11,Y),1:Y)
75 D N:$X>1 Q:'DN W ?1 W "Protocol Participation: "
76 S X=$G(^ONCO(165.5,D0,"STS2")) D N:$X>31 Q:'DN W ?31 S Y=$P(X,U,31) W:Y]"" $S($D(DXS(12,Y)):DXS(12,Y),1:Y)
77 D N:$X>6 Q:'DN W ?6 W " " K DIP K:DN Y
78 D N:$X>6 Q:'DN W ?6 W "Text Remarks: "
79 S:'$D(DIWF) DIWF="" S:DIWF'["N" DIWF=DIWF_"N" S X="" S I(1)=19,J(1)=165.5113 F D1=0:0 Q:$O(^ONCO(165.5,D0,19,D1))'>0 S D1=$O(^(D1)) D:$X>23 T Q:'DN D E1
80 G E1R
81E1 ;
82 S X=$G(^ONCO(165.5,D0,19,D1,0)) S DIWL=24,DIWR=130 D ^DIWP
83 Q
84E1R ;
85 D 0^DIWW
86 D ^DIWW
87 D N:$X>6 Q:'DN W ?6 W "Physician's Staging: "
88 S X=$G(^ONCO(165.5,D0,7)) W ?0,$E($P(X,U,10),1,30)
89 D N:$X>49 Q:'DN W ?49 W "MD: "
90 S Y=$P(X,U,11) S Y=$S(Y="":Y,$D(^ONCO(165,Y,0))#2:$P(^(0),U),1:Y) W $E(Y,1,30)
91 D N:$X>6 Q:'DN W ?6 W "QA Selected: "
92 S Y=$P(X,U,4) W:Y]"" $S($D(DXS(13,Y)):DXS(13,Y),1:Y)
93 D N:$X>34 Q:'DN W ?34 W "QA Review: "
94 S Y=$P(X,U,8) W:Y]"" $S($D(DXS(14,Y)):DXS(14,Y),1:Y)
95 D N:$X>54 Q:'DN W ?54 W "QA Date: "
96 S Y=$P(X,U,9) S Y(0)=Y S X=Y D DATEOT^ONCOES W $E(Y,1,30)
97 D N:$X>1 Q:'DN W ?1 W " "
98 K Y K DIWF
99 Q
100HEAD ;
101 W !,"------------------------------------------------------------------------------------------------------------------------------------",!!
Note: See TracBrowser for help on using the repository browser.