source: WorldVistAEHR/trunk/r/PHARMACY_DATA_MANAGEMENT-PSS/PSSJXR24.m@ 619

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

initial load of WorldVistAEHR

File size: 3.4 KB
RevLine 
[613]1PSSJXR24 ; COMPILED XREF FOR FILE #55.02 ; 01/17/08
2 ;
3 I X'="" D
4 .N DIK,DIV,DIU,DIN
5 .I X S DIU=$S($D(^PS(55,DA(1),5,DA,5)):$P(^(5),"^",7),1:""),$P(^(5),"^",7)=DIU+X I $O(^DD(55.06,54,1,0)) K DIV S (DIV(0),D0)=DA(1),(DIV(1),D1)=DA,DIV=DIU+X,DIH=55.06,DIG=54 D ^DICR
6 S X=$P(DIKZ(5),U,8)
7 I X'="" ; I '$D(DIU(0)),X S PSGAMSF=0 D ^PSGAMSA
8 S DIKZ(4)=$G(^PS(55,DA(1),5,DA,4))
9 S X=$P(DIKZ(4),U,18)
10 I X'="" I '$D(DIU(0)) D:$D(PSGAL(71)) KILL^PSGAL5:PSGAL(71)=X K PSGAL
11 S X=$P(DIKZ(4),U,19)
12 I X'="" I '$D(DIU(0)) D:$D(PSGAL(72)) KILL^PSGAL5:PSGAL(72)=X K PSGAL
13 S X=$P(DIKZ(4),U,20)
14 I X'="" I '$D(DIU(0)) D:$D(PSGAL(73)) KILL^PSGAL5:PSGAL(73)=X K PSGAL
15 S X=$P(DIKZ(4),U,21)
16 I X'="" I '$D(DIU(0)) D:$D(PSGAL(74)) KILL^PSGAL5:PSGAL(74)=X K PSGAL
17 S X=$P(DIKZ(4),U,22)
18 I X'="" I '$D(DIU(0)) D:$D(PSGAL(75)) KILL^PSGAL5:PSGAL(75)=X K PSGAL
19 S X=$P(DIKZ(4),U,23)
20 I X'="" I '$D(DIU(0)) D:$D(PSGAL(76)) KILL^PSGAL5:PSGAL(76)=X K PSGAL
21 S X=$P(DIKZ(4),U,24)
22 I X'="" I '$D(DIU(0)) D:$D(PSGAL(77)) KILL^PSGAL5:PSGAL(77)=X K PSGAL
23 S DIKZ(0)=$G(^PS(55,DA(1),5,DA,0))
24 S X=$P(DIKZ(0),U,20)
25 I X'="" I '$D(DIU(0)) D:$D(PSGAL(79)) KILL^PSGAL5:PSGAL(79)=X K PSGAL
26 S X=$P(DIKZ(0),U,20)
27 I X'="" S ^PS(55,"AUDDD",$E(X,1,30),DA(1),DA)=""
28 S DIKZ(6.5)=$G(^PS(55,DA(1),5,DA,6.5))
29 S X=$P(DIKZ(6.5),U,1)
30 I X'="" I '$D(DIU(0)) D:$D(PSGAL(78)) KILL^PSGAL5:PSGAL(78)=X K PSGAL
31 S X=$P(DIKZ(0),U,21)
32 I X'="" I '$D(DIU(0)) D:$D(PSGAL(80)) KILL^PSGAL5:PSGAL(80)=X K PSGAL
33 S DIKZ(.1)=$G(^PS(55,DA(1),5,DA,.1))
34 S X=$P(DIKZ(.1),U,1)
35 I X'="" S ^PS(55,DA(1),5,"C",$E(X,1,30),DA)=""
36 S X=$P(DIKZ(.1),U,1)
37 I X'="" I '$D(DIU(0)) D:$D(PSGAL(101)) KILL^PSGAL5:PSGAL(101)=X K PSGAL
38 S X=$P(DIKZ(.1),U,2)
39 I X'="" I '$D(DIU(0)) D:$D(PSGAL(102)) KILL^PSGAL5:PSGAL(102)=X K PSGAL
40 S X=$P(DIKZ(0),U,24)
41 I X'="" I '$D(DIU(0)) D:$D(PSGAL(103)) KILL^PSGAL5:PSGAL(103)=X K PSGAL
42 S X=$P(DIKZ(0),U,25)
43 I X'="" I '$D(DIU(0)) D:$D(PSGAL(104)) KILL^PSGAL5:PSGAL(104)=X K PSGAL
44 S X=$P(DIKZ(0),U,26)
45 I X'="" I '$D(DIU(0)) D:$D(PSGAL(105)) KILL^PSGAL5:PSGAL(105)=X K PSGAL
46 S X=$P(DIKZ(.1),U,3)
47 I X'="" I '$D(DIU(0)) D:$D(PSGAL(106)) KILL^PSGAL5:PSGAL(106)=X K PSGAL
48 S X=$P(DIKZ(0),U,27)
49 I X'="" I '$D(DIU(0)) D:$D(PSGAL(107)) KILL^PSGAL5:PSGAL(107)=X K PSGAL
50CR1 S DIXR=480
51 K X
52 S DIKZ(2)=$G(^PS(55,DA(1),5,DA,2))
53 S X(1)=$P(DIKZ(2),U,2)
54 S X(2)=$P(DIKZ(2),U,4)
55 S X=$G(X(1))
56 I $G(X(1))]"",$G(X(2))]"" D
57 . K X1,X2 M X1=X,X2=X
58 . N DIKXARR M DIKXARR=X S DIKCOND=1
59 . S X=$$PATCH^XPDUTL("PXRM*1.5*12")
60 . S DIKCOND=$G(X) K X M X=DIKXARR
61 . Q:'DIKCOND
62 . D SPSPA^PSJXRFS(.X,.DA,"UD")
63CR2 S DIXR=492
64 K X
65 S DIKZ(.2)=$G(^PS(55,DA(1),5,DA,.2))
66 S X(1)=$P(DIKZ(.2),U,8)
67 S DIKZ(0)=$G(^PS(55,DA(1),5,DA,0))
68 S X(2)=$P(DIKZ(0),U,21)
69 S X=$G(X(1))
70 I $G(X(1))]"",$G(X(2))]"" D
71 . K X1,X2 M X1=X,X2=X
72 . N DIKXARR M DIKXARR=X S DIKCOND=1
73 . S X=1
74 . S DIKCOND=$G(X) K X M X=DIKXARR
75 . Q:'DIKCOND
76 . S ^PS(55,"ACX",$E(X(1),1,30),$E(X(2),1,30),DA_"U")=""
77CR3 S DIXR=495
78 K X
79 S DIKZ(2)=$G(^PS(55,DA(1),5,DA,2))
80 S X(1)=$P(DIKZ(2),U,4)
81 S DIKZ(8)=$G(^PS(55,DA(1),5,DA,8))
82 S X(2)=$P(DIKZ(8),U,1)
83 S X=$G(X(1))
84 I $G(X(1))]"",$G(X(2))]"" D
85 . K X1,X2 M X1=X,X2=X
86 . S ^PS(55,"AUDC",$E(X(1),1,20),$E(X(2),1,20),DA(1),DA)=""
87CR4 S DIXR=497
88 K X
89 S DIKZ(2)=$G(^PS(55,DA(1),5,DA,2))
90 S X(1)=$P(DIKZ(2),U,4)
91 S DIKZ(8)=$G(^PS(55,DA(1),5,DA,8))
92 S X(2)=$P(DIKZ(8),U,1)
93 S X=$G(X(1))
94 I $G(X(1))]"",$G(X(2))]"" D
95 . K X1,X2 M X1=X,X2=X
96 . S ^PS(55,DA(1),5,"AUN",X(1),X(2),DA)=""
97CR5 K X
98 G:'$D(DIKLM) A^PSSJXR23 Q:$D(DISET)
99END G ^PSSJXR25
Note: See TracBrowser for help on using the repository browser.