source: WorldVistAEHR/trunk/r/SCHEDULING-SD-SC/SCMCHLX.m@ 1361

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

initial load of WorldVistAEHR

File size: 2.5 KB
RevLine 
[613]1SCMCHLX ;BP/DJB - PCMM HL7 EVENT File Xref APIs ; 10 Dec 2002 8:44 PM
2 ;;5.3;Scheduling;**177,264,272**;May 01, 1999
3 ;
4 ;Reference routine: SCDXFX01
5AACXMIT(IFN,SET,OLDEVPTR) ;Logic for AACXMIT* xrefs on PCMM HL7 EVENT
6 ; file (#404.48).
7 ;
8 ; Input: IFN: Pointer to entry in file
9 ; SET: 1 = Set xref
10 ; 0 = Kill xref
11 ; -1 = Check value of TRANSMISSION REQUIRED field (#.04).
12 ; If "YES"- Set xref
13 ; If "NO" - Kill xref
14 ; OLDEVPTR: Previous value of EVENT POINTER field (#.07).
15 ; Only valid when KILLing xref is due to data in this
16 ; field changing.
17 ;Output: None
18 ;
19 ;Check input
20 Q:'$G(IFN)
21 Q:'$D(^SCPT(404.48,IFN))
22 S:$G(SET)="" SET=-1
23 S OLDEVPTR=+$G(OLDEVPTR)
24 ;
25 ;Declare variables
26 NEW EVPTR,EVENT,ND,XMIT
27 ;
28 ;Get data
29 S ND=$G(^SCPT(404.48,IFN,0)) ;....Get zero node
30 S XMIT=+$P(ND,"^",3) ;............Transmission Required field
31 S EVPTR=$P(ND,"^",7) ;............Event Pointer field
32 I 'SET,OLDEVPTR S EVPTR=OLDEVPTR ;Use old Event Pointer if killing
33 ; due to value changing.
34 Q:'EVPTR ;.......................Quit if no Event Pointer
35 ;
36 ;Set/Kill logic based on value of TRANSMISSION REQUIRED
37 I SET=-1 S SET=$S(XMIT=1:1,1:0)
38 ;
39 ;Set/Kill xref
40 I SET S ^SCPT(404.48,"AACXMIT",EVPTR,IFN)="" ;..Set xref
41 E KILL ^SCPT(404.48,"AACXMIT",EVPTR,IFN) ;.....Kill xref
42 Q
43 ;
44TXREF(IFN) ;Logic for AEVENT* xrefs on TEAM file. Create entry in
45 ; PCMM HL7 EVENT file.
46 ;
47 ;***THIS CALL NOT USED***
48 ;bp/djb 6/15/99
49 ;No longer sending Primary Care Team data to Austin.
50 ;
51 D TXREF^SCMCHLX1($G(IFN))
52 Q
53 ;
54PTXREF(IFN,OLDTYPE) ;Logic for AEVENT* xrefs on PATIENT TEAM ASSIGN file.
55 ; Create entry in PCMM HL7 EVENT file.
56 ;
57 ;***THIS CALL NOT USED***
58 ;bp/djb 6/15/99
59 ;No longer sending Primary Care Team data to Austin.
60 ;
61 D PTXREF^SCMCHLX1($G(IFN),$G(OLDTYPE))
62 Q
63 ;
64PTPXREF(IFN,OLDROLE) ;Logic for AEVENT* xrefs on PATIENT TEAM POSITION
65 ; ASSIGN file. Create entry in PCMM HL7 EVENT file.
66 D PTPXREF^SCMCHLX1($G(IFN),$G(OLDROLE))
67 Q
68 ;
69POSHXREF(IFN) ;Logic for AEVENT* xrefs on POSITION ASSIGNMENT HISTORY file.
70 ; Create entry in PCMM HL7 EVENT file.
71 D POSHXREF^SCMCHLX1($G(IFN))
72 Q
73 ;
74PREHXREF(IFN) ;Logic for AEVENT* xrefs on PRECEPTOR ASSIGNMENT HISTORY file.
75 ; Create entry in PCMM HL7 EVENT file.
76 D PREHXREF^SCMCHLX1($G(IFN))
77 Q
78POSBXREF(IFN,FILE) ;Logic for Bookable Hour Cross reference
79 ;Create entry in PCMM HL7 EVENT file
80 D POSBXREF^SCMCHLX1(+$G(IFN),$G(FILE))
81 Q
Note: See TracBrowser for help on using the repository browser.