GMTS2 ;SLC/SBW - Health Summary Driver Cont. ; 02/27/2019
;;2.7;Health Summary;**2,58,62,122**;Oct 20, 1995;Build 183
;
TDISBLD ; Temporarily Disabled Components
D CKP^GMTSUP Q:$D(GMTSQIT) W "Temporarily disabled",!
I GMOOTXT]"" D CKP^GMTSUP Q:$D(GMTSQIT) W GMOOTXT,!
Q
PDISBLD ; Permanently Disabled Components
D CKP^GMTSUP Q:$D(GMTSQIT) W "Permanently disabled",!
I GMOOTXT]"" D CKP^GMTSUP Q:$D(GMTSQIT) W GMOOTXT,!
Q
NOMATCH ; User doesn't hold Security Key
D CKP^GMTSUP Q:$D(GMTSQIT)
W "This component is locked with security key "_GMTSLOCK_".",!
Q
NOSELECT ; No Selection Items
; Handles cases where components that require
; selection items have no selection items defined.
D CKP^GMTSUP Q:$D(GMTSQIT)
W "No selection items chosen for this component.",!
Q
NODATA ; No Data
; This will display "No Data Available" for commponents
; components that retrieve no data.
I $D(GMTSQIT),(GMTSQIT="") Q
N PRINTNAME,SELNAME
Q:GMTSWRIT=0 I $G(GMSUPRES)="Y" K:$D(GMTSOBJ) GMTSEG(+($G(GMTSEGN)))
I $E(IOST,1)'="C" Q:$G(GMSUPRES)="Y"
I GMSEL]"" D GETSEL,DISPSEL Q
D CKP^GMTSUP Q:$D(GMTSQIT) W:'$D(GMTSOBJ) !
D CKP^GMTSUP Q:$D(GMTSQIT) W " No data available",!
Q
GETSEL ; Get Selection Items
N GMX,GMI,GMDA,GMFROOT,GMROOT,GMNODE
S GMFROOT=$G(GMTSEG(GMTSEGN,GMSEL,0))
Q:GMFROOT=""
S (GMX,GMI)=0
F S GMI=$O(GMTSEG(GMTSEGN,GMSEL,GMI)) Q:GMI'>0 D
. S GMDA=$G(GMTSEG(GMTSEGN,GMSEL,GMI))
. S GMROOT=GMFROOT_GMDA_",0)"
. S GMNODE=$G(@GMROOT)
. S GMX=GMX+1,SELNAME(GMX)=$P(GMNODE,U)
. I GMSEL=9999999.09 S PRINTNAME(GMX)=$P($G(^AUTTEDT(GMDA,0)),U,4)
. I GMSEL=9999999.15 S PRINTNAME(GMX)=$P($G(^AUTTEXAM(GMDA,200)),U,1)
. I GMSEL=9999999.64 S PRINTNAME(GMX)=$P($G(^AUTTHF(GMDA,200)),U,1)
. I $G(PRINTNAME(GMX))="" S PRINTNAME(GMX)=SELNAME(GMX)
Q
DISPSEL ; Display selection items
N GMI,GMX
D CKP^GMTSUP Q:$D(GMTSQIT) W "No data available for: "
S (GMI,GMX)=0
F S GMI=$O(SELNAME(GMI)) Q:GMI'>0 D
. S GMX=GMX+1
. I GMX=1,($X+$L(PRINTNAME(GMI))>77) W !
. W:GMX>1 !
. D CKP^GMTSUP Q:$D(GMTSQIT) W PRINTNAME(GMI)
W !
Q
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HGMTS2 2124 printed Dec 13, 2024@01:56:54 Page 2
GMTS2 ;SLC/SBW - Health Summary Driver Cont. ; 02/27/2019
+1 ;;2.7;Health Summary;**2,58,62,122**;Oct 20, 1995;Build 183
+2 ;
TDISBLD ; Temporarily Disabled Components
+1 DO CKP^GMTSUP
if $DATA(GMTSQIT)
QUIT
WRITE "Temporarily disabled",!
+2 IF GMOOTXT]""
DO CKP^GMTSUP
if $DATA(GMTSQIT)
QUIT
WRITE GMOOTXT,!
+3 QUIT
PDISBLD ; Permanently Disabled Components
+1 DO CKP^GMTSUP
if $DATA(GMTSQIT)
QUIT
WRITE "Permanently disabled",!
+2 IF GMOOTXT]""
DO CKP^GMTSUP
if $DATA(GMTSQIT)
QUIT
WRITE GMOOTXT,!
+3 QUIT
NOMATCH ; User doesn't hold Security Key
+1 DO CKP^GMTSUP
if $DATA(GMTSQIT)
QUIT
+2 WRITE "This component is locked with security key "_GMTSLOCK_".",!
+3 QUIT
NOSELECT ; No Selection Items
+1 ; Handles cases where components that require
+2 ; selection items have no selection items defined.
+3 DO CKP^GMTSUP
if $DATA(GMTSQIT)
QUIT
+4 WRITE "No selection items chosen for this component.",!
+5 QUIT
NODATA ; No Data
+1 ; This will display "No Data Available" for commponents
+2 ; components that retrieve no data.
+3 IF $DATA(GMTSQIT)
IF (GMTSQIT="")
QUIT
+4 NEW PRINTNAME,SELNAME
+5 if GMTSWRIT=0
QUIT
IF $GET(GMSUPRES)="Y"
if $DATA(GMTSOBJ)
KILL GMTSEG(+($GET(GMTSEGN)))
+6 IF $EXTRACT(IOST,1)'="C"
if $GET(GMSUPRES)="Y"
QUIT
+7 IF GMSEL]""
DO GETSEL
DO DISPSEL
QUIT
+8 DO CKP^GMTSUP
if $DATA(GMTSQIT)
QUIT
if '$DATA(GMTSOBJ)
WRITE !
+9 DO CKP^GMTSUP
if $DATA(GMTSQIT)
QUIT
WRITE " No data available",!
+10 QUIT
GETSEL ; Get Selection Items
+1 NEW GMX,GMI,GMDA,GMFROOT,GMROOT,GMNODE
+2 SET GMFROOT=$GET(GMTSEG(GMTSEGN,GMSEL,0))
+3 if GMFROOT=""
QUIT
+4 SET (GMX,GMI)=0
+5 FOR
SET GMI=$ORDER(GMTSEG(GMTSEGN,GMSEL,GMI))
if GMI'>0
QUIT
Begin DoDot:1
+6 SET GMDA=$GET(GMTSEG(GMTSEGN,GMSEL,GMI))
+7 SET GMROOT=GMFROOT_GMDA_",0)"
+8 SET GMNODE=$GET(@GMROOT)
+9 SET GMX=GMX+1
SET SELNAME(GMX)=$PIECE(GMNODE,U)
+10 IF GMSEL=9999999.09
SET PRINTNAME(GMX)=$PIECE($GET(^AUTTEDT(GMDA,0)),U,4)
+11 IF GMSEL=9999999.15
SET PRINTNAME(GMX)=$PIECE($GET(^AUTTEXAM(GMDA,200)),U,1)
+12 IF GMSEL=9999999.64
SET PRINTNAME(GMX)=$PIECE($GET(^AUTTHF(GMDA,200)),U,1)
+13 IF $GET(PRINTNAME(GMX))=""
SET PRINTNAME(GMX)=SELNAME(GMX)
End DoDot:1
+14 QUIT
DISPSEL ; Display selection items
+1 NEW GMI,GMX
+2 DO CKP^GMTSUP
if $DATA(GMTSQIT)
QUIT
WRITE "No data available for: "
+3 SET (GMI,GMX)=0
+4 FOR
SET GMI=$ORDER(SELNAME(GMI))
if GMI'>0
QUIT
Begin DoDot:1
+5 SET GMX=GMX+1
+6 IF GMX=1
IF ($X+$LENGTH(PRINTNAME(GMI))>77)
WRITE !
+7 if GMX>1
WRITE !
+8 DO CKP^GMTSUP
if $DATA(GMTSQIT)
QUIT
WRITE PRINTNAME(GMI)
End DoDot:1
+9 WRITE !
+10 QUIT