FSCRPCAP ;SLC/STAFF-NOIS RPC Alert Process ;1/11/98 18:48
;;1.1;NOIS;;Sep 06, 1998
;
ALERT(XQADATA) ; from FSCRPCA
I '$O(^FSCD("SEND","B",+XQADATA,0)) Q
N CALL,LNUM,NUM
K ^TMP("FSC CURRENT LIST",$J)
K ^TMP("FSC LIST CLEANUP",$J)
S LNUM=0
S NUM=0 F S NUM=$O(^FSCD("SEND","B",+XQADATA,NUM)) Q:NUM<1 D
.S CALL=+$P($G(^FSCD("SEND",NUM,0)),U,2)
.D SETUP(CALL,$P($G(^FSCD("ALERT",+XQADATA,0)),U,3))
.D MRA^FSCMR(DUZ,CALL)
.S LNUM=LNUM+1
.S ^TMP("FSC LIST CLEANUP",$J,LNUM)=$P($G(^FSCD("ALERT",+XQADATA,0)),U,3)
.D OUTPUT^FSCRPCA
S NUM=0 F S NUM=$O(^FSCD("SEND","B",+XQADATA,NUM)) Q:NUM<1 D
.I '$L($P($G(^FSCD("SEND",NUM,0)),U,3)) S $P(^(0),U,3)=DT
Q
;
USER ; from FSCRPCA
N CALL,DA,DIK,LNUM,NUM,X,Y
K ^FSCD("ALERT","ALERT",DUZ)
K ^TMP("FSC CURRENT LIST",$J)
K ^TMP("FSC LIST CLEANUP",$J)
S LNUM=0
S DIK="^FSCD(""ALERT"","
S CALL=0 F S CALL=$O(^FSCD("ALERT","AUC",DUZ,CALL)) Q:CALL<1 S NUM=^(CALL) D
.D SETUP(CALL,$P($G(^FSCD("ALERT",NUM,0)),U,3))
.D MRA^FSCMR(DUZ,CALL)
.S LNUM=LNUM+1
.S ^TMP("FSC LIST CLEANUP",$J,LNUM)=$P(^FSCD("ALERT",NUM,0),U,3)
.S DA=+NUM D ^DIK
.D OUTPUT^FSCRPCA
Q
;
SETUP(CALL,MSG) ;
N LNUM
S LNUM=1+$O(^TMP("FSC CURRENT LIST",$J,"A"),-1)
I LNUM<1000 S LNUM=LNUM+1000
S ^TMP("FSC CURRENT LIST",$J,LNUM)=CALL_U_$$SHORT^FSCRPXUS(CALL,DUZ)_" ("_MSG_")"
S ^TMP("FSC CURRENT LIST",$J,"C",CALL)=LNUM
Q
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HFSCRPCAP 1403 printed Dec 13, 2024@02:19:13 Page 2
FSCRPCAP ;SLC/STAFF-NOIS RPC Alert Process ;1/11/98 18:48
+1 ;;1.1;NOIS;;Sep 06, 1998
+2 ;
ALERT(XQADATA) ; from FSCRPCA
+1 IF '$ORDER(^FSCD("SEND","B",+XQADATA,0))
QUIT
+2 NEW CALL,LNUM,NUM
+3 KILL ^TMP("FSC CURRENT LIST",$JOB)
+4 KILL ^TMP("FSC LIST CLEANUP",$JOB)
+5 SET LNUM=0
+6 SET NUM=0
FOR
SET NUM=$ORDER(^FSCD("SEND","B",+XQADATA,NUM))
if NUM<1
QUIT
Begin DoDot:1
+7 SET CALL=+$PIECE($GET(^FSCD("SEND",NUM,0)),U,2)
+8 DO SETUP(CALL,$PIECE($GET(^FSCD("ALERT",+XQADATA,0)),U,3))
+9 DO MRA^FSCMR(DUZ,CALL)
+10 SET LNUM=LNUM+1
+11 SET ^TMP("FSC LIST CLEANUP",$JOB,LNUM)=$PIECE($GET(^FSCD("ALERT",+XQADATA,0)),U,3)
+12 DO OUTPUT^FSCRPCA
End DoDot:1
+13 SET NUM=0
FOR
SET NUM=$ORDER(^FSCD("SEND","B",+XQADATA,NUM))
if NUM<1
QUIT
Begin DoDot:1
+14 IF '$LENGTH($PIECE($GET(^FSCD("SEND",NUM,0)),U,3))
SET $PIECE(^(0),U,3)=DT
End DoDot:1
+15 QUIT
+16 ;
USER ; from FSCRPCA
+1 NEW CALL,DA,DIK,LNUM,NUM,X,Y
+2 KILL ^FSCD("ALERT","ALERT",DUZ)
+3 KILL ^TMP("FSC CURRENT LIST",$JOB)
+4 KILL ^TMP("FSC LIST CLEANUP",$JOB)
+5 SET LNUM=0
+6 SET DIK="^FSCD(""ALERT"","
+7 SET CALL=0
FOR
SET CALL=$ORDER(^FSCD("ALERT","AUC",DUZ,CALL))
if CALL<1
QUIT
SET NUM=^(CALL)
Begin DoDot:1
+8 DO SETUP(CALL,$PIECE($GET(^FSCD("ALERT",NUM,0)),U,3))
+9 DO MRA^FSCMR(DUZ,CALL)
+10 SET LNUM=LNUM+1
+11 SET ^TMP("FSC LIST CLEANUP",$JOB,LNUM)=$PIECE(^FSCD("ALERT",NUM,0),U,3)
+12 SET DA=+NUM
DO ^DIK
+13 DO OUTPUT^FSCRPCA
End DoDot:1
+14 QUIT
+15 ;
SETUP(CALL,MSG) ;
+1 NEW LNUM
+2 SET LNUM=1+$ORDER(^TMP("FSC CURRENT LIST",$JOB,"A"),-1)
+3 IF LNUM<1000
SET LNUM=LNUM+1000
+4 SET ^TMP("FSC CURRENT LIST",$JOB,LNUM)=CALL_U_$$SHORT^FSCRPXUS(CALL,DUZ)_" ("_MSG_")"
+5 SET ^TMP("FSC CURRENT LIST",$JOB,"C",CALL)=LNUM
+6 QUIT