Home   Package List   Routine Alphabetical List   Global Alphabetical List   FileMan Files List   FileMan Sub-Files List   Package Component Lists   Package-Namespace Mapping  
Routine: FSCXMRA

FSCXMRA.m

Go to the documentation of this file.
FSCXMRA ;SLC/STAFF-NOIS Xrefs MRA ;12/27/96  09:22
 ;;1.1;NOIS;;Sep 06, 1998
 ;
AUTC(OP,FIELD,VALUE,NUM) ; from dd 7101.1
 N USER,TIME,CALL
 I OP="SET" D  Q
 .I FIELD="USER" D  Q
 ..I VALUE S TIME=$P(^FSCD("MRA",NUM,0),U,2),CALL=$P(^(0),U,3) I TIME,CALL S ^FSCD("MRA","AUTC",VALUE,-TIME,CALL)=NUM
 .I FIELD="TIME" D  Q
 ..I VALUE S USER=$P(^FSCD("MRA",NUM,0),U),CALL=$P(^(0),U,3) I USER,CALL S ^FSCD("MRA","AUTC",USER,-VALUE,CALL)=NUM
 .I FIELD="CALL" D  Q
 ..I VALUE S USER=$P(^FSCD("MRA",NUM,0),U),TIME=$P(^(0),U,2) I USER,TIME S ^FSCD("MRA","AUTC",USER,-TIME,VALUE)=NUM
 I OP="KILL" D  Q
 .I FIELD="USER" D  Q
 ..I VALUE S TIME=$P(^FSCD("MRA",NUM,0),U,2),CALL=$P(^(0),U,3) I TIME,CALL K ^FSCD("MRA","AUTC",VALUE,-TIME,CALL)
 .I FIELD="TIME" D  Q
 ..I VALUE S USER=$P(^FSCD("MRA",NUM,0),U),CALL=$P(^(0),U,3) I USER,CALL K ^FSCD("MRA","AUTC",USER,-VALUE,CALL)
 .I FIELD="CALL" D  Q
 ..I VALUE S USER=$P(^FSCD("MRA",NUM,0),U),TIME=$P(^(0),U,2) I USER,TIME K ^FSCD("MRA","AUTC",USER,-TIME,VALUE)
 Q
 ;
AUC(OP,FIELD,VALUE,NUM) ; from dd 7101.1
 N USER,CALL
 I OP="SET" D  Q
 .I FIELD="USER" D  Q
 ..I VALUE S CALL=$P(^FSCD("MRA",NUM,0),U,3) I CALL S ^FSCD("MRA","AUC",VALUE,CALL)=NUM
 .I FIELD="CALL" D  Q
 ..I VALUE S USER=$P(^FSCD("MRA",NUM,0),U) I USER S ^FSCD("MRA","AUC",USER,VALUE)=NUM
 I OP="KILL" D  Q
 .I FIELD="USER" D  Q
 ..I VALUE S CALL=$P(^FSCD("MRA",NUM,0),U,3) I CALL K ^FSCD("MRA","AUC",VALUE,CALL)
 .I FIELD="CALL" D  Q
 ..I VALUE S USER=$P(^FSCD("MRA",NUM,0),U) I USER K ^FSCD("MRA","AUC",USER,VALUE)
 Q
 ;
AUT(OP,FIELD,VALUE,NUM) ; from dd 7101.1
 N USER,TIME
 I OP="SET" D  Q
 .I FIELD="USER" D  Q
 ..I VALUE S TIME=$P(^FSCD("MRA",NUM,0),U,2) I TIME S ^FSCD("MRA","AUT",VALUE)=TIME
 .I FIELD="TIME" D  Q
 ..I VALUE S USER=$P(^FSCD("MRA",NUM,0),U) I USER S ^FSCD("MRA","AUT",USER)=VALUE
 I OP="KILL" D  Q
 .I FIELD="USER" D  Q
 ..I VALUE K ^FSCD("MRA","AUT",VALUE)
 .I FIELD="TIME" D  Q
 ..S USER=$P(^FSCD("MRA",NUM,0),U) I USER K ^FSCD("MRA","AUT",USER)
 Q