GMTSUP1 ; SLC/JER,KER - Utilities for Paging HS ; 09/21/2001
;;2.7;Health Summary;**28,29,47**;Oct 20, 1995
;
; External References
; DBIA 10102 DISP^XQORM1
; DBIA 10026 ^DIR
;
RJUMP ; XQOR for "^^"-jump is no longer supported
N GMDFN,GMTSAV W !,"Jumping not allowed.",! H 1 G RETURN
RETURN ; Return to Health Summary without Jump
W:$G(GMTSAV)'["?" !,">>> Returning to Health Summary",! H 1
Q
HELP ; Offers help to confused individuals
N GMQUIT
W @IOF
I X="?",GMTSTYP=TYP W "These components have been selected for Ad Hoc.",! S FLG=1 D LIST K FLG Q:$D(DTOUT) D HELP1 W ! Q
I X="?",GMTSTYP'=TYP W "These components are part of ",GMTSTITL," Health Summary Type",!,"or have been temporarily added. Added components are indicated by *.",! S FLG=2 D LIST K FLG Q:$D(DTOUT) D HELP1 W ! Q
I X="??" W "These components may be temporarily added (use ""=C"" to change limits)." D DISP^XQORM1 W !!
I X="???" D HELP2
Q
HELP1 ; Writes part of help prompt
D SCRNLNTH Q:$D(GMQUIT) W !!
D SCRNLNTH Q:$D(GMQUIT) W "To leave display order and jump to a different component, select any component",!
D SCRNLNTH Q:$D(GMQUIT) W "from the above list, or select any additional component to be temporarily",!
D SCRNLNTH Q:$D(GMQUIT) W "added to the display. Add ""=C"" to component to change limits or selection",!
D SCRNLNTH Q:$D(GMQUIT) W "items. EXAMPLE: LO=C",!!
D SCRNLNTH Q:$D(GMQUIT) W "Enter: ?? to see additional components.",!
D SCRNLNTH Q:$D(GMQUIT) W ?7,"??? to see HELP for ""^^""-jump.",!
D SCRNLNTH Q:$D(GMQUIT) W ?7,"<RET> to continue display.",!
D SCRNLNTH Q:$D(GMQUIT) W ?7,"+ to proceed to next component.",!
D SCRNLNTH Q:$D(GMQUIT) W ?7,"- to return to preceeding component.",!
D SCRNLNTH Q:$D(GMQUIT) W ?7,"^ to quit present patient's summary.",!
D SCRNLNTH Q:$D(GMQUIT) W ?7,"^^ to quit and return to menu.",!!
Q
HELP2 ; Help for "^^"-jump
D SCRNLNTH Q:$D(GMQUIT) W ?22,"Navigation OUTSIDE of Health Summary",!!
D SCRNLNTH Q:$D(GMQUIT) W "You may also enter ""^^"" followed by the name, partial name or synonym for",!
D SCRNLNTH Q:$D(GMQUIT) W "any of a variety of options OUTSIDE of Health Summary to which you can",!
D SCRNLNTH Q:$D(GMQUIT) W "jump. Partial matches will allow you to select from a subset of options.",!!
D SCRNLNTH Q:$D(GMQUIT) W "For example: ^^? will list ALL available options.",!
D SCRNLNTH Q:$D(GMQUIT) W ?14,"^^PN will show you all of the PROGRESS NOTES options, or",!
D SCRNLNTH Q:$D(GMQUIT) W ?14,"^^OR will show you all of the ORDER ENTRY options.",!!
D SCRNLNTH Q:$D(GMQUIT) W "You may also order a wide variety of LABORATORY tests using this syntax.",!
D SCRNLNTH Q:$D(GMQUIT) W "e.g., ^^CHEM 7 will allow you to ADD an order for that test.",!!
Q
LIST ; List components
N GMI,DUOUT
S GMI=0 F S GMI=$O(GMTSEG(GMI)) Q:GMI'>0 D SCRNLNTH Q:$D(DUOUT)!($D(DTOUT)) D LIST1 Q:$D(DUOUT)!($D(DTOUT))
Q
SCRNLNTH ; Checks screen length
N DIR
Q:$Y'>(IOSL-4)
S DIR(0)="E"
D ^DIR I $S($D(DUOUT):1,$D(DTOUT):1,1:0) S GMQUIT=""
W:'$D(GMQUIT) @IOF
Q
LIST1 ; Lists component information
N CREC S CREC=^GMT(142.1,$P(GMTSEG(GMI),U,2),0)
W:GMI#2 ! W ?$S(GMI#2:0,1:40) D:FLG=2 STAR W $P(CREC,U,4),?$S(GMI#2:8,1:48),$E($S($L($P(GMTSEG(GMI),U,5)):$P(GMTSEG(GMI),U,5),$L($P(CREC,U,9)):$P(CREC,U,9),1:$P(CREC,U)),1,24)
Q
STAR ; Writes * to indicate added component when called by GMTSUP
; for HST other than AD HOC
W $S($D(^GMT(142,TYP,1,"C",$P(GMTSEG(GMI),U,2))):" ",1:"*")
Q
GMTSUP1 ; SLC/JER,KER - Utilities for Paging HS ; 09/21/2001
+1 ;;2.7;Health Summary;**28,29,47**;Oct 20, 1995
+2 ;
+3 ; External References
+4 ; DBIA 10102 DISP^XQORM1
+5 ; DBIA 10026 ^DIR
+6 ;
RJUMP ; XQOR for "^^"-jump is no longer supported
+1 NEW GMDFN,GMTSAV
WRITE !,"Jumping not allowed.",!
HANG 1
GOTO RETURN
RETURN ; Return to Health Summary without Jump
+1 IF $GET(GMTSAV)'["?"
WRITE !,">>> Returning to Health Summary",!
HANG 1
+2 QUIT
HELP ; Offers help to confused individuals
+1 NEW GMQUIT
+2 WRITE @IOF
+3 IF X="?"
IF GMTSTYP=TYP
WRITE "These components have been selected for Ad Hoc.",!
SET FLG=1
DO LIST
KILL FLG
IF $DATA(DTOUT)
QUIT
DO HELP1
WRITE !
QUIT
+4 IF X="?"
IF GMTSTYP'=TYP
WRITE "These components are part of ",GMTSTITL," Health Summary Type",!,"or have been temporarily added. Added components are indicated by *.",!
SET FLG=2
DO LIST
KILL FLG
IF $DATA(DTOUT)
QUIT
DO HELP1
WRITE !
QUIT
+5 IF X="??"
WRITE "These components may be temporarily added (use ""=C"" to change limits)."
DO DISP^XQORM1
WRITE !!
+6 IF X="???"
DO HELP2
+7 QUIT
HELP1 ; Writes part of help prompt
+1 DO SCRNLNTH
IF $DATA(GMQUIT)
QUIT
WRITE !!
+2 DO SCRNLNTH
IF $DATA(GMQUIT)
QUIT
WRITE "To leave display order and jump to a different component, select any component",!
+3 DO SCRNLNTH
IF $DATA(GMQUIT)
QUIT
WRITE "from the above list, or select any additional component to be temporarily",!
+4 DO SCRNLNTH
IF $DATA(GMQUIT)
QUIT
WRITE "added to the display. Add ""=C"" to component to change limits or selection",!
+5 DO SCRNLNTH
IF $DATA(GMQUIT)
QUIT
WRITE "items. EXAMPLE: LO=C",!!
+6 DO SCRNLNTH
IF $DATA(GMQUIT)
QUIT
WRITE "Enter: ?? to see additional components.",!
+7 DO SCRNLNTH
IF $DATA(GMQUIT)
QUIT
WRITE ?7,"??? to see HELP for ""^^""-jump.",!
+8 DO SCRNLNTH
IF $DATA(GMQUIT)
QUIT
WRITE ?7,"<RET> to continue display.",!
+9 DO SCRNLNTH
IF $DATA(GMQUIT)
QUIT
WRITE ?7,"+ to proceed to next component.",!
+10 DO SCRNLNTH
IF $DATA(GMQUIT)
QUIT
WRITE ?7,"- to return to preceeding component.",!
+11 DO SCRNLNTH
IF $DATA(GMQUIT)
QUIT
WRITE ?7,"^ to quit present patient's summary.",!
+12 DO SCRNLNTH
IF $DATA(GMQUIT)
QUIT
WRITE ?7,"^^ to quit and return to menu.",!!
+13 QUIT
HELP2 ; Help for "^^"-jump
+1 DO SCRNLNTH
IF $DATA(GMQUIT)
QUIT
WRITE ?22,"Navigation OUTSIDE of Health Summary",!!
+2 DO SCRNLNTH
IF $DATA(GMQUIT)
QUIT
WRITE "You may also enter ""^^"" followed by the name, partial name or synonym for",!
+3 DO SCRNLNTH
IF $DATA(GMQUIT)
QUIT
WRITE "any of a variety of options OUTSIDE of Health Summary to which you can",!
+4 DO SCRNLNTH
IF $DATA(GMQUIT)
QUIT
WRITE "jump. Partial matches will allow you to select from a subset of options.",!!
+5 DO SCRNLNTH
IF $DATA(GMQUIT)
QUIT
WRITE "For example: ^^? will list ALL available options.",!
+6 DO SCRNLNTH
IF $DATA(GMQUIT)
QUIT
WRITE ?14,"^^PN will show you all of the PROGRESS NOTES options, or",!
+7 DO SCRNLNTH
IF $DATA(GMQUIT)
QUIT
WRITE ?14,"^^OR will show you all of the ORDER ENTRY options.",!!
+8 DO SCRNLNTH
IF $DATA(GMQUIT)
QUIT
WRITE "You may also order a wide variety of LABORATORY tests using this syntax.",!
+9 DO SCRNLNTH
IF $DATA(GMQUIT)
QUIT
WRITE "e.g., ^^CHEM 7 will allow you to ADD an order for that test.",!!
+10 QUIT
LIST ; List components
+1 NEW GMI,DUOUT
+2 SET GMI=0
FOR
SET GMI=$ORDER(GMTSEG(GMI))
IF GMI'>0
QUIT
DO SCRNLNTH
IF $DATA(DUOUT)!($DATA(DTOUT))
QUIT
DO LIST1
IF $DATA(DUOUT)!($DATA(DTOUT))
QUIT
+3 QUIT
SCRNLNTH ; Checks screen length
+1 NEW DIR
+2 IF $Y'>(IOSL-4)
QUIT
+3 SET DIR(0)="E"
+4 DO ^DIR
IF $SELECT($DATA(DUOUT):1,$DATA(DTOUT):1,1:0)
SET GMQUIT=""
+5 IF '$DATA(GMQUIT)
WRITE @IOF
+6 QUIT
LIST1 ; Lists component information
+1 NEW CREC
SET CREC=^GMT(142.1,$PIECE(GMTSEG(GMI),U,2),0)
+2 IF GMI#2
WRITE !
WRITE ?$SELECT(GMI#2:0,1:40)
IF FLG=2
DO STAR
WRITE $PIECE(CREC,U,4),?$SELECT(GMI#2:8,1:48),$EXTRACT($SELECT($LENGTH($PIECE(GMTSEG(GMI),U,5)):$PIECE(GMTSEG(GMI),U,5),$LENGTH($PIECE(CREC,U,9)):$PIECE(CREC,U,9),1:$PIECE(CREC,U)),1,24)
+3 QUIT
STAR ; Writes * to indicate added component when called by GMTSUP
+1 ; for HST other than AD HOC
+2 WRITE $SELECT($DATA(^GMT(142,TYP,1,"C",$PIECE(GMTSEG(GMI),U,2))):" ",1:"*")
+3 QUIT