source: Scheduling/trunk/m/BSDX03.m@ 1235

Last change on this file since 1235 was 1187, checked in by Sam Habiel, 14 years ago

Changes to BSDX01 to prevent Scheduled,dc'ed,completed radiology appointments from being cancelled. Updated files to T2.

File size: 1.4 KB
RevLine 
[1161]1BSDX03 ; IHS/OIT/HMW - WINDOWS SCHEDULING RPCS ; 4/28/11 10:14am
[1187]2 ;;1.6T2;BSDX;;May 16, 2011
[1161]3 ;Licensed under LGPL
[614]4 ;
5 ;
6 Q
7 ;
8XR2S(BSDXDA) ;EP
9 ;XR2 is the ARSRC xref for the
10 ;RESOURCE field of the BSDX APPOINTMENT file
11 ;Format is ^BSDXAPPT("ARSRC",RESOURCEID,STARTTIME,APPTID)
12 Q:'$D(^BSDXAPPT(BSDXDA,0))
13 N BSDXNOD,BSDXAPPID,BSDXRSID,BSDXS
14 S BSDXNOD=^BSDXAPPT(BSDXDA,0)
15 S BSDXAPPID=BSDXDA
16 S BSDXRSID=$P(BSDXNOD,U,7)
17 Q:'+BSDXAPPID>0
18 Q:'+BSDXRSID>0
19 S BSDXS=$P(BSDXNOD,U)
20 Q:'+BSDXS
21 S ^BSDXAPPT("ARSRC",BSDXRSID,BSDXS,BSDXAPPID)=""
22 Q
23 ;
24XR2K(BSDXA) ;EP
25 Q:'$D(^BSDXAPPT(BSDXA,0))
26 N BSDXNOD,BSDXAPPID,BSDXRSID,BSDXS
27 S BSDXNOD=^BSDXAPPT(BSDXA,0)
28 S BSDXAPPID=BSDXA
29 S BSDXRSID=$P(BSDXNOD,U,7)
30 S BSDXS=$P(BSDXNOD,U)
31 Q:'+BSDXAPPID>0
32 Q:'+BSDXRSID>0
33 Q:'+BSDXS>0
34 K ^BSDXAPPT("ARSRC",BSDXRSID,BSDXS,BSDXAPPID)
35 Q
36XR4S(BSDXDA) ;EP
37 ;XR4 is the ARSCT xref for the
38 ;STARTTIME field of the BSDX ACCESS BLOCK file
39 ;Format is ^BSDXAB("ARSCT",RESOURCEID,STARTTIME,DA)
40 Q:'$D(^BSDXAB(BSDXDA,0))
41 N BSDXNOD,BSDXR,BSDXS
42 S BSDXNOD=^BSDXAB(BSDXDA,0)
43 S BSDXR=$P(BSDXNOD,U)
44 S BSDXS=$P(BSDXNOD,U,2)
45 Q:'+BSDXR>0
46 Q:'+BSDXS>0
47 S ^BSDXAB("ARSCT",BSDXR,BSDXS,BSDXDA)=""
48 Q
49 ;
50XR4K(BSDXDA) ;EP
51 Q:'$D(^BSDXAB(BSDXDA,0))
52 N BSDXNOD,BSDXR,BSDXS
53 S BSDXNOD=^BSDXAB(BSDXDA,0)
54 S BSDXR=$P(BSDXNOD,U)
55 S BSDXS=$P(BSDXNOD,U,2)
56 Q:'+BSDXR>0
57 Q:'+BSDXS>0
58 K ^BSDXAB("ARSCT",BSDXR,BSDXS,BSDXDA)
59 Q
Note: See TracBrowser for help on using the repository browser.