source: FOIAVistA/trunk/r/NOIS-FSC/FSCXMRU.m@ 1757

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

initial load of FOIAVistA 6/30/08 version

File size: 2.7 KB
Line 
1FSCXMRU ;SLC/STAFF-NOIS Xrefs MRU ;12/27/96 14:25
2 ;;1.1;NOIS;;Sep 06, 1998
3 ;
4AUTL(OP,FIELD,VALUE,NUM) ; from dd 7101.1
5 N USER,TIME,LIST,INDEX
6 I OP="SET" D Q
7 .I FIELD="USER" D Q
8 ..I VALUE S TIME=$P(^FSCD("MRU",NUM,0),U,2),LIST=$P(^(0),U,3),INDEX=+$P(^(0),U,4) I TIME,LIST S ^FSCD("MRU","AUTL",VALUE,-TIME,LIST,INDEX)=NUM
9 .I FIELD="TIME" D Q
10 ..I VALUE S USER=$P(^FSCD("MRU",NUM,0),U),LIST=$P(^(0),U,3),INDEX=+$P(^(0),U,4) I USER,LIST S ^FSCD("MRU","AUTL",USER,-VALUE,LIST,INDEX)=NUM
11 .I FIELD="LIST" D Q
12 ..I VALUE S USER=$P(^FSCD("MRU",NUM,0),U),TIME=$P(^(0),U,2),INDEX=+$P(^(0),U,4) I USER,TIME S ^FSCD("MRU","AUTL",USER,-TIME,VALUE,INDEX)=NUM
13 .I FIELD="VALUE" D Q
14 ..S USER=$P(^FSCD("MRU",NUM,0),U),TIME=$P(^(0),U,2),LIST=$P(^(0),U,3) I USER,TIME,LIST S ^FSCD("MRU","AUTL",USER,-TIME,LIST,+VALUE)=NUM
15 I OP="KILL" D Q
16 .I FIELD="USER" D Q
17 ..I VALUE S TIME=$P(^FSCD("MRU",NUM,0),U,2),LIST=$P(^(0),U,3),INDEX=+$P(^(0),U,4) I TIME,LIST K ^FSCD("MRU","AUTL",VALUE,-TIME,LIST,INDEX)
18 .I FIELD="TIME" D Q
19 ..I VALUE S USER=$P(^FSCD("MRU",NUM,0),U),LIST=$P(^(0),U,3),INDEX=+$P(^(0),U,4) I USER,LIST K ^FSCD("MRU","AUTL",USER,-VALUE,LIST,INDEX)
20 .I FIELD="LIST" D Q
21 ..I VALUE S USER=$P(^FSCD("MRU",NUM,0),U),TIME=$P(^(0),U,2),INDEX=+$P(^(0),U,4) I USER,TIME K ^FSCD("MRU","AUTL",USER,-TIME,VALUE,INDEX)
22 .I FIELD="VALUE" D Q
23 ..S USER=$P(^FSCD("MRU",NUM,0),U),TIME=$P(^(0),U,2),LIST=$P(^(0),U,3) I USER,TIME,LIST K ^FSCD("MRU","AUTL",USER,-TIME,LIST,+VALUE)
24 Q
25 ;
26AUL(OP,FIELD,VALUE,NUM) ; from dd 7101.1
27 N USER,LIST
28 I OP="SET" D Q
29 .I FIELD="USER" D Q
30 ..I VALUE S LIST=$P(^FSCD("MRU",NUM,0),U,3),INDEX=+$P(^(0),U,4) I LIST S ^FSCD("MRU","AUL",VALUE,LIST,INDEX)=NUM
31 .I FIELD="LIST" D Q
32 ..I VALUE S USER=$P(^FSCD("MRU",NUM,0),U),INDEX=+$P(^(0),U,4) I USER S ^FSCD("MRU","AUL",USER,VALUE,INDEX)=NUM
33 .I FIELD="VALUE" D Q
34 ..S USER=$P(^FSCD("MRU",NUM,0),U),LIST=$P(^(0),U,3) I USER,LIST S ^FSCD("MRU","AUL",USER,LIST,+VALUE)=NUM
35 I OP="KILL" D Q
36 .I FIELD="USER" D Q
37 ..I VALUE S LIST=$P(^FSCD("MRU",NUM,0),U,3),INDEX=+$P(^(0),U,4) I LIST K ^FSCD("MRU","AUL",VALUE,LIST,INDEX)
38 .I FIELD="LIST" D Q
39 ..I VALUE S USER=$P(^FSCD("MRU",NUM,0),U),INDEX=+$P(^(0),U,4) I USER K ^FSCD("MRU","AUL",USER,VALUE,INDEX)
40 .I FIELD="VALUE" D Q
41 ..S USER=$P(^FSCD("MRU",NUM,0),U),LIST=$P(^(0),U,3) I USER,LIST K ^FSCD("MRU","AUL",USER,LIST,+VALUE)
42 Q
43 ;
44AUT(OP,FIELD,VALUE,NUM) ; from dd 7101.1
45 N USER,TIME
46 I OP="SET" D Q
47 .I FIELD="USER" D Q
48 ..I VALUE S TIME=$P(^FSCD("MRU",NUM,0),U,2) I TIME S ^FSCD("MRU","AUT",VALUE)=TIME
49 .I FIELD="TIME" D Q
50 ..I VALUE S USER=$P(^FSCD("MRU",NUM,0),U) I USER S ^FSCD("MRU","AUT",USER)=VALUE
51 I OP="KILL" D Q
52 .I FIELD="USER" D Q
53 ..I VALUE K ^FSCD("MRU","AUT",VALUE)
54 .I FIELD="TIME" D Q
55 ..S USER=$P(^FSCD("MRU",NUM,0),U) I USER K ^FSCD("MRU","AUT",USER)
56 Q
Note: See TracBrowser for help on using the repository browser.