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

BLRDSP.m

Go to the documentation of this file.
BLRDSP ; IHS/HQT/MJL - DISPLAY QUEUE ENTRY AND TRANSACTION INFO ; [ 06/29/2001  1:38 PM ]
 ;;5.2;LR;**1010,1011**;MAR 01, 2001
 S U="^",BLRLR=""
 S BLRNPMT=1 D ENT^BLRPST W ! D MSG W !! K BLRNPMT,BLRCHLD
 F  D SEQ Q:R=""  D DSPENT
 Q
 ;
SEQ ;
 R "ENTRY: ",R:DTIME Q:R=""
 S BLRQSITE=$P(^AUTTSITE(1,0),U,1),BLRDH=$P(^BLRSITE(BLRQSITE,0),U,6)
 S:R?1L R=$$UC(R)
 K:"UB"'[R BLRCHLD
 I R="D" D ENT^BLRPST W !! G SEQ
 I R="C" D ^BLRPST W !! G SEQ
 I R="I" S DIC=9009022,DIC(0)="AEMQ" W ! D ^DIC D:Y  W ! G SEQ
 .S DA=+Y,LTN=DA D EN^DIQ
 I R="S" D ^%SS W !! G SEQ
 I R="L" D ^%LOCKTAB W !! G SEQ
 I R="E" D ^XTER W !! G SEQ
 I R="M" W " " D MSG W ! G SEQ
 I R="U" D PAR G SEQ
 I R="B" D CHILD G SEQ
 I R="P" S BLRDIR=-1 D NEXT G SEQ
 I R="N" S BLRDIR=1 D NEXT G SEQ
 I R="R" S R=$P(^BLRSITE(BLRQSITE,21,BLRDH,0),U,3) W *8,R D DSPENT G SEQ
 I R="?" W ! D HELP W !! G SEQ
 I R="H" G ^XUSCLEAN
 I R="<" W *8 D  G SEQ
 .I 'BLRLR W ! Q
 .S FND=0 F R=BLRLR-1:-1:1 I ^BLRSITE(BLRQSITE,21,BLRDH,R)=LTN,$D(^BLRSITE(BLRQSITE,21,BLRDH,R,0)) S FND=1 Q
 .I FND W R D DSP Q
 .W "NOT FOUND",!
 I R'?.N W " INVALID ENTRY",! G SEQ
 I '$D(^BLRSITE(BLRQSITE,21,BLRDH,R)) W " INVALID SEQ NO",! G SEQ
 ;W !
 Q
 ;
DSPENT ;
 S BLRLR=R
 ;S X=$G(^BLRSITE(BLRQSITE,21,BLRDH,R,0)) NO DATA STORED HERE NOW
 ;D:X'="" ENTRY
 S DA=^BLRSITE(BLRQSITE,21,BLRDH,R) D DSP
 Q
 ;
DSP ;
 W !
 S LTN=DA,DIC="^BLRTXLOG(" D EN^DIQ
 W !
 Q
 ;
ENTRY ;
 W !,"OPTION:      ",$P(X,U)
 W:$P(X,U,3) !,"ENTERED BY:  ",$P(^VA(200,$P(X,U,3),0),U)
 W !,"TIME:        ",$$TIME($P(X,U,2))
 W:$P(X,U,4)'="" !,"ACTION       ",$P(X,U,4)
 Q
 ;
PAR ;
 I $G(LTN) S BLRPAR=$P(^BLRTXLOG(LTN,1),U) I BLRPAR S DA=BLRPAR,BLRCHLD(BLRPAR)=LTN D DSP Q
 W " ??",!
 Q
 ;
CHILD ;
 I $G(LTN),$G(BLRCHLD(LTN)) S DA=BLRCHLD(LTN) D DSP Q
 W " ??",!
 Q
 ;
NEXT ;
 I $G(LTN) S DA=$O(^BLRTXLOG(LTN),BLRDIR) I DA D DSP Q
 W " ??",!
 Q
 ;
MSG ;
 I $P(^XMB(3.7,DUZ,0),U,6) D ^XM W ! Q
 W "NO MESSAGES"
 Q
 ;
HELP ;
 S BLROPT="D^C^I^S^L^E^M^U^B^P^N^R^(NUMBER)^?"
 F BLRN=1:1:$L(BLROPT,U) W !,$P(BLROPT,U,BLRN),$E($TR($J("",10)," ","."),1,11-$L($P(BLROPT,U,BLRN))),$P("PROCESSOR STATUS^CONTINUOUS PROCESSOR STATUS^TRANSACTION INQUIRY^SYSTEM STATUS^LOCK TABLE^ERROR MESSAGES^MAIL MESSAGES^UP TO PARENT^BACK TO CHILD^PREVIOUS SEQUENCE NO^NEXT SEQUENCE NO^MOST RECENT ENTRY^ENTRY IN QUEUE^HELP MENU",U,BLRN)
 K BLROPT
 Q
 ;
TIME(X) ;
 Q $E(X\3600*10000+(X#3600\60*100)+(X#60)+1000000,2,7)
 ;
UC(X) ;
 Q $TR(X,"abcdefghijklmnopqrstuvwxyz","ABCDEFGHIJKLMNOPQRSTUVWXYZ")