source: WorldVistAEHR/trunk/r/ORDER_ENTRY_RESULTS_REPORTING-OR-OCX--ORRC--ORRJ/OCXOED08.m@ 1211

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

initial load of WorldVistAEHR

File size: 1.9 KB
RevLine 
[613]1OCXOED08 ;SLC/RJS,CLA - Rule Editor (Element Options) ;10/29/98 12:37
2 ;;3.0;ORDER ENTRY/RESULTS REPORTING;**32**;Dec 17,1997
3 ;; ;;ORDER CHECK EXPERT version 1.01 released OCT 29,1998
4 ;
5 ;
6S ;
7 ;
8 Q
9EN(OCXD0,OCXRD,OCXACT) ;
10 ;
11 ;
12 N OCXTHLN,OCXTNLN,OCXTRLN,OCXTULN,OCXTNLN
13 ;
14 S OCXOPT=$$GETOPT^OCXOEDT(.OCXACT) Q:(OCXOPT=U) 1 X:$L(OCXOPT) OCXOPT
15 ;
16 Q:'$D(^OCXS(860.3,OCXD0)) 1
17 ;
18 Q 0
19 ;
20 ;
21EDELE(OCXD0) ;
22 N X S X=$$DIE("^OCXS(860.3,",OCXD0,".01;.02")
23 Q:'$D(^OCXS(860.3,OCXD0))
24 Q
25 ;
26EDEXP(OCXD0,OCXD1) ;
27 D EN^OCXOED09(OCXD0,OCXD1)
28 Q
29 ;
30EOPT(OCXMODE,OCXD0) ;
31 ;
32 I OCXMODE="ADD" D Q
33 .S:'$D(^OCXS(860.3,OCXD0,"COND",0)) ^OCXS(860.3,OCXD0,"COND",0)="^860.31^^"
34 .N OCXD1 S OCXD1=$O(^OCXS(860.3,OCXD0,"COND","@"),-1)+1
35 .S ^OCXS(860.3,OCXD0,"COND",OCXD1,0)=OCXD1,^OCXS(860.3,OCXD0,"COND","B",OCXD1,OCXD1)=""
36 .D EDEXP(OCXD0,OCXD1)
37 I OCXMODE="DEL" D Q
38 .S:'$D(^OCXS(860.3,OCXD0,"COND",0)) ^OCXS(860.3,OCXD0,"COND",0)="^860.31^^"
39 .N OCXD1,DA S DA(1)=OCXD0,OCXD1=+$$DIC("^OCXS(860.3,"_OCXD0_",""COND"",","AEMQN","Select Expression Index Number: ") Q:(OCXD1<0)
40 .Q:'$$READ("Y","Are you sure you want to Delete ?","YES")
41 .Q:'$$DIE("^OCXS(860.3,"_(+OCXD0)_",""COND"",",OCXD1,"S DA(1)="_(+OCXD0)_";.01///@")
42 .W !!,"Deleted..." H 1
43 Q
44 ;
45COMP ;
46 D ^OCXOCMP
47 Q
48 ;
49 ;
50READ(OCXZ0,OCXZA,OCXZB,OCXZL) ;
51 N OCXLINE,DIR,DTOUT,DUOUT,DIRUT,DIROUT
52 Q:'$L($G(OCXZ0)) U
53 S DIR(0)=OCXZ0
54 S:$L($G(OCXZA)) DIR("A")=OCXZA
55 S:$L($G(OCXZB)) DIR("B")=OCXZB
56 F OCXLINE=1:1:($G(OCXZL)-1) W !
57 D ^DIR
58 I $D(DTOUT)!$D(DUOUT)!$D(DIRUT)!$D(DIROUT) Q U
59 Q Y
60 ;
61DIE(DIE,DA,DR) ;
62 ;
63 D RM(IOM) N DUOUT,DTOUT,DIC S DIC=DIE D ^DIE D RM(0) Q:$G(DTOUT) 0 Q:$G(DUOUT) 0 Q 1
64 ;
65RM(X) X ^%ZOSF("RM") Q
66 ;
67DIC(OCXDIC,OCXDIC0,OCXDICA,OCXX,OCXDICS,OCXDR,DA) ;
68 ;
69 N DIC,X,Y
70 S DIC=$G(OCXDIC) Q:'$L(DIC) -1
71 S DIC(0)=$G(OCXDIC0) S:$L($G(OCXX)) X=OCXX
72 S:$L($G(OCXDICS)) DIC("S")=OCXDICS
73 S:$L($G(OCXDICA)) DIC("A")=OCXDICA
74 S:$L($G(OCXDR)) DIC("DR")=OCXDR
75 D ^DIC Q:(Y<1) 0 Q Y
76 ;
Note: See TracBrowser for help on using the repository browser.