source: FOIAVistA/trunk/r/ORDER_ENTRY_RESULTS_REPORTING-OR-OCX--ORRC--ORRJ/ORECS01.m@ 1704

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

initial load of FOIAVistA 6/30/08 version

File size: 1.3 KB
Line 
1ORECS01 ;SLC/JDL-CPRS utility for Event Capture System; 2/10/03 13:04P
2 ;;3.0;ORDER ENTRY/RESULTS REPORTING;**141,149**;Dec 17, 1997
3 ;
4CHKESSO(ORY,CHK) ;--1=ESSO installed on site 0=not installed
5 S ORY=$$PATCH^XPDUTL("XWB*1.1*26")
6 Q
7 ;
8VSITID(ORY,VSTSTR) ;--Return Visit IEN ptr to #9000010
9 ;VSTSTR=HospLoc;DateTime;Category;PtIEN
10 N DTREF,PTID
11 S ORY=0
12 S DTREF=9999999-$P($P(VSTSTR,";",2),".")_"."_$P($P(VSTSTR,";",2),".",2)
13 S PTID=+$P(VSTSTR,";",4)
14 S:$D(^AUPNVSIT("AA",PTID,DTREF)) ORY=$O(^(DTREF,0))
15 Q
16 ;
17ECRPT(ORY,ORECARY) ;--EC report
18 Q:'$D(ORECARY)
19 D RPTEN^ECRRPC(.ORY,.ORECARY)
20 Q
21 ;
22ECPRINT(ORY,ORECARY) ;--Print ECS report to Device
23 Q:'$D(ORECARY)
24 D RPTEN^ECRRPC(.ORY,.ORECARY)
25 Q
26 ;
27GETDIV(ORY,USR) ;--Get user's division
28 S ORY=0
29 S:$G(DUZ(2)) ORY=DUZ(2)
30 Q
31SAVPATH(ORY,ECPATH) ;--Save user's ECS path
32 N IX,VAL,NM,HADIT,LST,INST,LAST
33 S (IX,HADIT,INST,LAST)=0,(VAL,NM)=""
34 D GETLST^XPAR(.LST,DUZ_";VA(200,","ORWT TOOLS MENU")
35 S LAST=+$G(LST(LST))
36 F S IX=$O(LST(IX)) Q:('IX)!HADIT D
37 . S NM=$P($P(LST(IX),U,2),"=",1)
38 . I $$UP^XLFSTR(NM)="EVENT CAPTURE INTERFACE" S HADIT=$P(LST(IX),U)
39 S $P(ECPATH,"=",2)=$C(34)_$P(ECPATH,"=",2)_$C(34)
40 S ORY=$P(ECPATH,"=",2)
41 D:HADIT CHG^XPAR(DUZ_";VA(200,","ORWT TOOLS MENU",HADIT,ECPATH)
42 D:'HADIT ADD^XPAR(DUZ_";VA(200,","ORWT TOOLS MENU",LAST+1,ECPATH)
43 Q
Note: See TracBrowser for help on using the repository browser.