BPCBHTPP ; IHS/OIT/MJL - behavioral health display for GUI ;
;;1.5;BPC;;MAY 26, 2005
;
;
;
TEST ;
D TPP(.RETVAL,234,"B")
Q
TPP(BGUARRAY,BPCIEN,BPCPREV) ;EP CALL FROM REMOTE PROC: BPCBH SUICIDE FORM DSP
;
S JOB=$J,BPCGUI=1,XWBWRAP=1
S ZTIO="",ZTQUEUED=1
S BGUARRAY="^XTMP(""BPCTP"","_$J_")"
S AMHTP=BPCIEN,AMHBROW=1
S AMHPREV=BPCPREV
K ^XTMP("BPCTP",JOB)
S ^XTMP("BPCTPRUN",JOB)=""
D ^XBKSET
S ZTRTN="TSK^BPCBHTPP",ZTIO="",ZTDESC="BPC TP DISPLAY",ZTSAVE("AMH*")="",ZTSAVE("JOB")="",ZTDTH=$H D ^%ZTLOAD
F I=1:1:60 Q:$G(^XTMP("BPCTPRUN",$J))="DONE" H 1
D KILL
Q
;
TSK ;
D ^XBKSET
S ^XTMP("BPCTPRUN",JOB)="START"
D GUIR^XBLM("PRINT^AMHLETPP","^XTMP(""BPCTP"",JOB)")
S ^XTMP("BPCTP",JOB,.5)=$O(^XTMP("BPCTP",JOB,""),-1)+1
S ^XTMP("BPCTPRUN",JOB)="DONE"
Q
;
KILL ;
K BPCCTR,BPCGUI,AMHTP,DIC,JOB,X,Y,ZTDESC,ZTDTH,ZTIO,ZTRTN,ZTSAVE,AMHPREV
Q
BPCBHTPP ; IHS/OIT/MJL - behavioral health display for GUI ;
+1 ;;1.5;BPC;;MAY 26, 2005
+2 ;
+3 ;
+4 ;
TEST ;
+1 DO TPP(.RETVAL,234,"B")
+2 QUIT
TPP(BGUARRAY,BPCIEN,BPCPREV) ;EP CALL FROM REMOTE PROC: BPCBH SUICIDE FORM DSP
+1 ;
+2 SET JOB=$JOB
SET BPCGUI=1
SET XWBWRAP=1
+3 SET ZTIO=""
SET ZTQUEUED=1
+4 SET BGUARRAY="^XTMP(""BPCTP"","_$JOB_")"
+5 SET AMHTP=BPCIEN
SET AMHBROW=1
+6 SET AMHPREV=BPCPREV
+7 KILL ^XTMP("BPCTP",JOB)
+8 SET ^XTMP("BPCTPRUN",JOB)=""
+9 DO ^XBKSET
+10 SET ZTRTN="TSK^BPCBHTPP"
SET ZTIO=""
SET ZTDESC="BPC TP DISPLAY"
SET ZTSAVE("AMH*")=""
SET ZTSAVE("JOB")=""
SET ZTDTH=$HOROLOG
DO ^%ZTLOAD
+11 FOR I=1:1:60
IF $GET(^XTMP("BPCTPRUN",$JOB))="DONE"
QUIT
HANG 1
+12 DO KILL
+13 QUIT
+14 ;
TSK ;
+1 DO ^XBKSET
+2 SET ^XTMP("BPCTPRUN",JOB)="START"
+3 DO GUIR^XBLM("PRINT^AMHLETPP","^XTMP(""BPCTP"",JOB)")
+4 SET ^XTMP("BPCTP",JOB,.5)=$ORDER(^XTMP("BPCTP",JOB,""),-1)+1
+5 SET ^XTMP("BPCTPRUN",JOB)="DONE"
+6 QUIT
+7 ;
KILL ;
+1 KILL BPCCTR,BPCGUI,AMHTP,DIC,JOB,X,Y,ZTDESC,ZTDTH,ZTIO,ZTRTN,ZTSAVE,AMHPREV
+2 QUIT