BLRPRE36 ; IHS/MSC/MKK - IHS Lab Patch LR*5.2*1036 Pre/Environment Routine ; 16-Jul-2015 06:30 ; MKK
;;5.2;IHS LABORATORY;**1036**;NOV 01, 1997;Build 10
;
ENVICHEK ; EP - Environment Checker
NEW BLRVERN,CP,ERRARRAY,ROWSTARS,RPMS,RPMSVER,TODAY,WOTCNT
;
Q:$$ENVIVARS()="Q"
;
D ENVHEADR^BLRPRE31(CP,RPMSVER,RPMS),BLANK
;
D SAVEOFF
;
D NEEDIT^BLRPRE31(CP,"LR","5.2",1035,.ERRARRAY),BLANK ; Lab Pre-Requisite
;
I XPDABORT>0 D SORRYEND^BLRPRE33(.ERRARRAY,CP) Q ; ENVIRONMENT HAS ERROR(S)
;
D BOKAY^BLRPRE31("ENVIRONMENT")
;
Q
;
ENVIVARS() ; EP - Setup the Environment variables
D SETEVARS
;
S TODAY=$$DT^XLFDT
S WOTCNT=$$WOTCNT(BLRVERN)
S ROWSTARS=$TR($J("",65)," ","*") ; Row of asterisks
;
S ^XTMP(BLRVERN,0)=$$HTFM^XLFDT(+$H+90)_"^"_$$DT^XLFDT_"^IHS Lab Patch "_CPSTR
M ^XTMP(BLRVERN,TODAY,WOTCNT,"DUZ")=DUZ
S ^XTMP(BLRVERN,TODAY,WOTCNT,"BEGIN")=$$NOW^XLFDT
;
S XUMF=1
;
I $G(XPDNM)="" D SORRY^BLRPRE31(CP,"XPDNM not defined or 0.") Q "Q"
;
S RPMS=$P(XPDNM,"*",1) ; RPMS Module
S RPMSVER=$P(XPDNM,"*",2) ; RPMS Version
;
I +$G(DUZ)<1 D SORRY^BLRPRE31(CP,"DUZ UNDEFINED OR 0.") Q "Q"
I $$GET1^DIQ(200,DUZ,"NAME")="" D SORRY^BLRPRE31(CP,"Installer cannot be identified!") Q "Q"
;
S XPDNOQUE=1 ; No Queuing Allowed
;
; The following line prevents the "Disable Options..." and "Move
; Routines..." questions from being asked during the install.
F X="XPO1","XPZ1","XPZ2","XPI1" S XPDDIQ(X)=0,XPDDIQ(X,"B")="NO"
;
S XPDABORT=0 ; KIDS install Flag
;
D HOME^%ZIS ; Reset/Initialize IO variables
D DTNOLF^DICRW ; Set DT variable without a Line Feed
;
Q "OK"
;
PRE ; EP - Ask for confirmation of Backup
NEW BLRVERN,CNT,CP,CPSTR,CRTLINE,DIRASTR,FDAROOT,IEN,IENS,MSGROOT
NEW BCKUPCNT ; Current Patch,Backup count
;
D SETEVARS
;
S XUMF=1
;
D INITSCR
D TITLE^XPDID(CPSTR)
D BLANK,BMES^XPDUTL("Pre-Install of "_BLRVERN_" Begins.")
;
Q:$$BACKUP()="Q"
;
D INITSCR
D TITLE^XPDID(CPSTR)
D BLANK,BMES^XPDUTL("Pre-Install of "_BLRVERN_" Continues.")
;
; Do Pre-install stuff here.
;
D TABMESG^BLRKIDSU("Pre-Install Processing Ends at "_$$UP^XLFSTR($$HTE^XLFDT($H,"5MPZ"))_".",5)
H 2 ; Pause so user can see the message.
;
D EXIT^XPDID
Q
;
BACKUP() ; EP - Confirm Backup
NEW BCKUPCNT,SUCCSTR
;
D SHOWBOX^BLRGMENU("ATTENTION",10,70)
;
D ^XBFMK
S DIR(0)="Y"
S DIR("B")="NO"
I $G(IOST)["C-VT" S SUCCSTR=$C(27)_"[1;7;5m"_">> SUCCESSFUL <<"_$C(27)_"[0m"
E S SUCCSTR=">> SUCCESSFUL <<"
S DIR("A")=$J("",10)_"Has a "_SUCCSTR_" backup been performed?"
S DIR("?")="A *NO* answer will abort the install process."
D ^DIR
W !
;
Q:+$G(Y)'=1 $$NOBACKUP() ; If BACKUP not performed, then ABORT installation.
;
Q:+$G(DEBUG) $$OKBACKUP() ; DEBUG will *NOT* store Backup Confirmation data.
;
; Store backup confirmation person & date/time
S BCKUPCNT=1+$O(^BLRINSTL("LAB PATCH",CP,"BACKUP CONFIRMED BY",0),-1)
S ^BLRINSTL("LAB PATCH",CP,"BACKUP CONFIRMED BY",BCKUPCNT)=$P($G(^VA(200,DUZ,0)),U)
S ^BLRINSTL("LAB PATCH",CP,"BACKUP CONFIRMED BY",BCKUPCNT,"DUZ")=DUZ
S ^BLRINSTL("LAB PATCH",CP,"BACKUP CONFIRMED BY",BCKUPCNT,"DATE/TIME")=$$HTE^XLFDT($H,"5MZ")
;
Q $$OKBACKUP()
;
OKBACKUP() ; EP - Backup Confirmed.
D MES^XPDUTL("")
D OKAY^BLRKIDSU("SUCCESSFUL system backup CONFIRMED by: "_$$GET1^DIQ(200,DUZ,"NAME")_".",5)
I +$G(DEBUG) D
. D MES^XPDUTL("")
. D TABMENU^BLRKIDSU("DEBUG will **NOT** Store Backup Confirmation.",10)
;
H 5 ; Pause to let the user see the message.
Q "OK"
;
NOBACKUP() ; EP - No backup message
S XPDABORT=1
D PASSMESG^BLRPRE31("ATTENTION")
D TABMESG^BLRKIDSU("SUCCESSFUL system backup has >>> NOT <<< been confirmed.",15)
D TABMESG^BLRKIDSU("Installer: "_$$GET1^DIQ(200,DUZ,"NAME")_" ["_DUZ_"].",25)
D TABMESG^BLRKIDSU("Install Aborting.",15)
H 2 ; Pause to let the user see the message.
Q "Q"
;
;
; ========================= UTILITIES FOLLOW ==========================
;
SETEVARS ; EP - SET standard "Enviroment" VARiables.
S (CP,PATCHNUM)=$P($T(+2),"*",3)
S CPSTR="LR*5.2*"_CP
S BLRVERN=$TR($P($T(+1),";")," ")
Q
;
BLANK ; EP - Blank Line
D MES^XPDUTL(" ")
Q
;
MESCNTR(STR) ; EP - Center a line and use XPDUTL to display it
D MES^XPDUTL($$CJ^XLFSTR(STR,IOM))
Q
;
WOTCNT(BLRVERN) ; EP - Counter for ^XTMP
NEW CNT,TODAY
;
S TODAY=$$DT^XLFDT
;
S CNT=1+$G(^XTMP(BLRVERN,0,TODAY))
S ^XTMP(BLRVERN,0,TODAY)=CNT
Q $TR($J(CNT,3)," ","0")
;
INITSCR ; EP - Initialize screen. Cloned from INIT^XPDID
N X,XPDSTR
I IO'=IO(0)!(IOST'["C-VT") S XPDIDVT=0 Q
I $T(PREP^XGF)="" S XPDIDVT=0 Q
D PREP^XGF
S XPDIDVT=1,X="IOSTBM",XPDSTR=""
D ENDR^%ZISS
S IOTM=3,IOBM=IOSL-4
W @IOSTBM
D FRAME^XGF(IOTM-2,0,IOTM-2,IOM-1) ; Top line
; D FRAME^XGF(IOBM+1,0,IOBM+1,IOM-1) ; Bottom line
D IOXY^XGF(IOTM-2,0)
Q
;
DEBUG ; EP - Debugging Line Label for environment checker
NEW BEGTIME,BLRVERN,CP,CPSTR,DEBUG,ENDTIME,ERRARRAY,LASTLOGI
NEW LRBLNOW,PATCHNUM,PREREQ,QFLG,ROWSTARS,RPMS,RPMSVER,STR
NEW SUCCSTR,TODAY,WHATCNT,WOTCNT,XPDABORT,XPDENV,XPDNM
;
; NOTE: DEBUG will not store "Backup" data.
;
D SETEVARS
;
W !!
W "Debug Routine ",BLRVERN," Begins:",!!
;
; Note -- DEBUG is a negative flag:
; 1="Don't Send Alerts"; 0="Send Alerts"
;
; D ^XBFMK
; S DIR(0)="YO"
; S DIR("B")="NO"
; S DIR("A")="Send Alerts/E-Mails"
; D ^DIR
; S:+$G(Y)=1 DEBUGA="YES"
;
S DEBUG=1 ; At this time, DO NOT ASK -- just DO NOT send alerts
;
W !
S XPDNM=CPSTR
S XPDENV=0
;
D ENVICHEK
D PRESSKEY^BLRGMENU(4)
;
Q:XPDABORT
;
D PRE
W !!!
;
D ^XBFMK
S DIR(0)="YO"
S DIR("B")="NO"
S DIR("A")="Test Post Install Code"
D ^DIR
;
D:+$G(Y)=1 POST^BLR35PST
;
W !!,"Debug Routine ",BLRVERN," Ends.",!!
Q
;
CHKBCKUP ; EP - Check to determine if BACKUP has been performed.
NEW CP ; Current Patch
S CP=$TR($P($T(+2),";",5),"*")
;
D PASSMESG^BLRPRE31("ATTENTION")
W !
;
D ^XBFMK
S DIR(0)="Y"
S DIR("B")="NO"
S DIR("A")=$J("",10)_"Has a >> SUCCESSFUL << backup been performed?"
D ^DIR
W !
;
I +$G(Y)'=1 D Q ; If BACKUP not performed, then ABORT installation.
. S XPDABORT=1
. D PASSMESG^BLRPRE31("ATTENTION")
. D BMES^XPDUTL($J("",15)_"SUCCESSFUL system backup has >>> NOT <<< been confirmed.")
. D BMES^XPDUTL($J("",25)_"Installer: "_$$GET1^DIQ(200,DUZ,"NAME")_" ["_DUZ_"].")
. D BMES^XPDUTL($J("",15)_"Install Aborting.")
. H 1 ; Pause 1 second to let the user see the message.
;
; Store backup confirmation person & date/time
S BCKUPCNT=1+$O(^BLRINSTL("LAB PATCH",CP,"BACKUP CONFIRMED BY",""),-1)
S ^BLRINSTL("LAB PATCH",CP,"BACKUP CONFIRMED BY",BCKUPCNT)=DUZ_"^"_$P($G(^VA(200,DUZ,0)),U)
S ^BLRINSTL("LAB PATCH",CP,"BACKUP CONFIRMED BY",BCKUPCNT,"DATE/TIME")=$$HTE^XLFDT($H,"5MZ")
;
D BOKAY^BLRPRE31("SUCCESSFUL system backup CONFIRMED by: "_$$GET1^DIQ(200,DUZ,"NAME")_".",5)
H 1 ; Pause 1 second to let the user see the message.
Q
;
SAVEOFF ; EP - Save off all routines being updated by this patch into the ^rBACKUP global.
NEW (DILOCKTM,DISYS,DT,DTIME,DUZ,IO,IOBS,IOF,IOM,ION,IOS,IOSL,IOST,IOT,IOXY,U,XPARSYS,XQXFLG)
;
F RTN="BLRRLEVN","BLRRLEVT","LROE","LRPHSET" D
. K ERRS,RTNA
. F LN=0:1:$G(^ROUTINE(RTN,0,0)) D
.. S RTNA(LN)=$G(^ROUTINE(RTN,0,LN))
. S X=$$ROUTINE^%R(RTN_".INT",.RTNA,.ERRS,"CSB")
Q
BLRPRE36 ; IHS/MSC/MKK - IHS Lab Patch LR*5.2*1036 Pre/Environment Routine ; 16-Jul-2015 06:30 ; MKK
+1 ;;5.2;IHS LABORATORY;**1036**;NOV 01, 1997;Build 10
+2 ;
ENVICHEK ; EP - Environment Checker
+1 NEW BLRVERN,CP,ERRARRAY,ROWSTARS,RPMS,RPMSVER,TODAY,WOTCNT
+2 ;
+3 IF $$ENVIVARS()="Q"
QUIT
+4 ;
+5 DO ENVHEADR^BLRPRE31(CP,RPMSVER,RPMS)
DO BLANK
+6 ;
+7 DO SAVEOFF
+8 ;
+9 ; Lab Pre-Requisite
DO NEEDIT^BLRPRE31(CP,"LR","5.2",1035,.ERRARRAY)
DO BLANK
+10 ;
+11 ; ENVIRONMENT HAS ERROR(S)
IF XPDABORT>0
DO SORRYEND^BLRPRE33(.ERRARRAY,CP)
QUIT
+12 ;
+13 DO BOKAY^BLRPRE31("ENVIRONMENT")
+14 ;
+15 QUIT
+16 ;
ENVIVARS() ; EP - Setup the Environment variables
+1 DO SETEVARS
+2 ;
+3 SET TODAY=$$DT^XLFDT
+4 SET WOTCNT=$$WOTCNT(BLRVERN)
+5 ; Row of asterisks
SET ROWSTARS=$TRANSLATE($JUSTIFY("",65)," ","*")
+6 ;
+7 SET ^XTMP(BLRVERN,0)=$$HTFM^XLFDT(+$HOROLOG+90)_"^"_$$DT^XLFDT_"^IHS Lab Patch "_CPSTR
+8 MERGE ^XTMP(BLRVERN,TODAY,WOTCNT,"DUZ")=DUZ
+9 SET ^XTMP(BLRVERN,TODAY,WOTCNT,"BEGIN")=$$NOW^XLFDT
+10 ;
+11 SET XUMF=1
+12 ;
+13 IF $GET(XPDNM)=""
DO SORRY^BLRPRE31(CP,"XPDNM not defined or 0.")
QUIT "Q"
+14 ;
+15 ; RPMS Module
SET RPMS=$PIECE(XPDNM,"*",1)
+16 ; RPMS Version
SET RPMSVER=$PIECE(XPDNM,"*",2)
+17 ;
+18 IF +$GET(DUZ)<1
DO SORRY^BLRPRE31(CP,"DUZ UNDEFINED OR 0.")
QUIT "Q"
+19 IF $$GET1^DIQ(200,DUZ,"NAME")=""
DO SORRY^BLRPRE31(CP,"Installer cannot be identified!")
QUIT "Q"
+20 ;
+21 ; No Queuing Allowed
SET XPDNOQUE=1
+22 ;
+23 ; The following line prevents the "Disable Options..." and "Move
+24 ; Routines..." questions from being asked during the install.
+25 FOR X="XPO1","XPZ1","XPZ2","XPI1"
SET XPDDIQ(X)=0
SET XPDDIQ(X,"B")="NO"
+26 ;
+27 ; KIDS install Flag
SET XPDABORT=0
+28 ;
+29 ; Reset/Initialize IO variables
DO HOME^%ZIS
+30 ; Set DT variable without a Line Feed
DO DTNOLF^DICRW
+31 ;
+32 QUIT "OK"
+33 ;
PRE ; EP - Ask for confirmation of Backup
+1 NEW BLRVERN,CNT,CP,CPSTR,CRTLINE,DIRASTR,FDAROOT,IEN,IENS,MSGROOT
+2 ; Current Patch,Backup count
NEW BCKUPCNT
+3 ;
+4 DO SETEVARS
+5 ;
+6 SET XUMF=1
+7 ;
+8 DO INITSCR
+9 DO TITLE^XPDID(CPSTR)
+10 DO BLANK
DO BMES^XPDUTL("Pre-Install of "_BLRVERN_" Begins.")
+11 ;
+12 IF $$BACKUP()="Q"
QUIT
+13 ;
+14 DO INITSCR
+15 DO TITLE^XPDID(CPSTR)
+16 DO BLANK
DO BMES^XPDUTL("Pre-Install of "_BLRVERN_" Continues.")
+17 ;
+18 ; Do Pre-install stuff here.
+19 ;
+20 DO TABMESG^BLRKIDSU("Pre-Install Processing Ends at "_$$UP^XLFSTR($$HTE^XLFDT($HOROLOG,"5MPZ"))_".",5)
+21 ; Pause so user can see the message.
HANG 2
+22 ;
+23 DO EXIT^XPDID
+24 QUIT
+25 ;
BACKUP() ; EP - Confirm Backup
+1 NEW BCKUPCNT,SUCCSTR
+2 ;
+3 DO SHOWBOX^BLRGMENU("ATTENTION",10,70)
+4 ;
+5 DO ^XBFMK
+6 SET DIR(0)="Y"
+7 SET DIR("B")="NO"
+8 IF $GET(IOST)["C-VT"
SET SUCCSTR=$CHAR(27)_"[1;7;5m"_">> SUCCESSFUL <<"_$CHAR(27)_"[0m"
+9 IF '$TEST
SET SUCCSTR=">> SUCCESSFUL <<"
+10 SET DIR("A")=$JUSTIFY("",10)_"Has a "_SUCCSTR_" backup been performed?"
+11 SET DIR("?")="A *NO* answer will abort the install process."
+12 DO ^DIR
+13 WRITE !
+14 ;
+15 ; If BACKUP not performed, then ABORT installation.
IF +$GET(Y)'=1
QUIT $$NOBACKUP()
+16 ;
+17 ; DEBUG will *NOT* store Backup Confirmation data.
IF +$GET(DEBUG)
QUIT $$OKBACKUP()
+18 ;
+19 ; Store backup confirmation person & date/time
+20 SET BCKUPCNT=1+$ORDER(^BLRINSTL("LAB PATCH",CP,"BACKUP CONFIRMED BY",0),-1)
+21 SET ^BLRINSTL("LAB PATCH",CP,"BACKUP CONFIRMED BY",BCKUPCNT)=$PIECE($GET(^VA(200,DUZ,0)),U)
+22 SET ^BLRINSTL("LAB PATCH",CP,"BACKUP CONFIRMED BY",BCKUPCNT,"DUZ")=DUZ
+23 SET ^BLRINSTL("LAB PATCH",CP,"BACKUP CONFIRMED BY",BCKUPCNT,"DATE/TIME")=$$HTE^XLFDT($HOROLOG,"5MZ")
+24 ;
+25 QUIT $$OKBACKUP()
+26 ;
OKBACKUP() ; EP - Backup Confirmed.
+1 DO MES^XPDUTL("")
+2 DO OKAY^BLRKIDSU("SUCCESSFUL system backup CONFIRMED by: "_$$GET1^DIQ(200,DUZ,"NAME")_".",5)
+3 IF +$GET(DEBUG)
Begin DoDot:1
+4 DO MES^XPDUTL("")
+5 DO TABMENU^BLRKIDSU("DEBUG will **NOT** Store Backup Confirmation.",10)
End DoDot:1
+6 ;
+7 ; Pause to let the user see the message.
HANG 5
+8 QUIT "OK"
+9 ;
NOBACKUP() ; EP - No backup message
+1 SET XPDABORT=1
+2 DO PASSMESG^BLRPRE31("ATTENTION")
+3 DO TABMESG^BLRKIDSU("SUCCESSFUL system backup has >>> NOT <<< been confirmed.",15)
+4 DO TABMESG^BLRKIDSU("Installer: "_$$GET1^DIQ(200,DUZ,"NAME")_" ["_DUZ_"].",25)
+5 DO TABMESG^BLRKIDSU("Install Aborting.",15)
+6 ; Pause to let the user see the message.
HANG 2
+7 QUIT "Q"
+8 ;
+9 ;
+10 ; ========================= UTILITIES FOLLOW ==========================
+11 ;
SETEVARS ; EP - SET standard "Enviroment" VARiables.
+1 SET (CP,PATCHNUM)=$PIECE($TEXT(+2),"*",3)
+2 SET CPSTR="LR*5.2*"_CP
+3 SET BLRVERN=$TRANSLATE($PIECE($TEXT(+1),";")," ")
+4 QUIT
+5 ;
BLANK ; EP - Blank Line
+1 DO MES^XPDUTL(" ")
+2 QUIT
+3 ;
MESCNTR(STR) ; EP - Center a line and use XPDUTL to display it
+1 DO MES^XPDUTL($$CJ^XLFSTR(STR,IOM))
+2 QUIT
+3 ;
WOTCNT(BLRVERN) ; EP - Counter for ^XTMP
+1 NEW CNT,TODAY
+2 ;
+3 SET TODAY=$$DT^XLFDT
+4 ;
+5 SET CNT=1+$GET(^XTMP(BLRVERN,0,TODAY))
+6 SET ^XTMP(BLRVERN,0,TODAY)=CNT
+7 QUIT $TRANSLATE($JUSTIFY(CNT,3)," ","0")
+8 ;
INITSCR ; EP - Initialize screen. Cloned from INIT^XPDID
+1 NEW X,XPDSTR
+2 IF IO'=IO(0)!(IOST'["C-VT")
SET XPDIDVT=0
QUIT
+3 IF $TEXT(PREP^XGF)=""
SET XPDIDVT=0
QUIT
+4 DO PREP^XGF
+5 SET XPDIDVT=1
SET X="IOSTBM"
SET XPDSTR=""
+6 DO ENDR^%ZISS
+7 SET IOTM=3
SET IOBM=IOSL-4
+8 WRITE @IOSTBM
+9 ; Top line
DO FRAME^XGF(IOTM-2,0,IOTM-2,IOM-1)
+10 ; D FRAME^XGF(IOBM+1,0,IOBM+1,IOM-1) ; Bottom line
+11 DO IOXY^XGF(IOTM-2,0)
+12 QUIT
+13 ;
DEBUG ; EP - Debugging Line Label for environment checker
+1 NEW BEGTIME,BLRVERN,CP,CPSTR,DEBUG,ENDTIME,ERRARRAY,LASTLOGI
+2 NEW LRBLNOW,PATCHNUM,PREREQ,QFLG,ROWSTARS,RPMS,RPMSVER,STR
+3 NEW SUCCSTR,TODAY,WHATCNT,WOTCNT,XPDABORT,XPDENV,XPDNM
+4 ;
+5 ; NOTE: DEBUG will not store "Backup" data.
+6 ;
+7 DO SETEVARS
+8 ;
+9 WRITE !!
+10 WRITE "Debug Routine ",BLRVERN," Begins:",!!
+11 ;
+12 ; Note -- DEBUG is a negative flag:
+13 ; 1="Don't Send Alerts"; 0="Send Alerts"
+14 ;
+15 ; D ^XBFMK
+16 ; S DIR(0)="YO"
+17 ; S DIR("B")="NO"
+18 ; S DIR("A")="Send Alerts/E-Mails"
+19 ; D ^DIR
+20 ; S:+$G(Y)=1 DEBUGA="YES"
+21 ;
+22 ; At this time, DO NOT ASK -- just DO NOT send alerts
SET DEBUG=1
+23 ;
+24 WRITE !
+25 SET XPDNM=CPSTR
+26 SET XPDENV=0
+27 ;
+28 DO ENVICHEK
+29 DO PRESSKEY^BLRGMENU(4)
+30 ;
+31 IF XPDABORT
QUIT
+32 ;
+33 DO PRE
+34 WRITE !!!
+35 ;
+36 DO ^XBFMK
+37 SET DIR(0)="YO"
+38 SET DIR("B")="NO"
+39 SET DIR("A")="Test Post Install Code"
+40 DO ^DIR
+41 ;
+42 IF +$GET(Y)=1
DO POST^BLR35PST
+43 ;
+44 WRITE !!,"Debug Routine ",BLRVERN," Ends.",!!
+45 QUIT
+46 ;
CHKBCKUP ; EP - Check to determine if BACKUP has been performed.
+1 ; Current Patch
NEW CP
+2 SET CP=$TRANSLATE($PIECE($TEXT(+2),";",5),"*")
+3 ;
+4 DO PASSMESG^BLRPRE31("ATTENTION")
+5 WRITE !
+6 ;
+7 DO ^XBFMK
+8 SET DIR(0)="Y"
+9 SET DIR("B")="NO"
+10 SET DIR("A")=$JUSTIFY("",10)_"Has a >> SUCCESSFUL << backup been performed?"
+11 DO ^DIR
+12 WRITE !
+13 ;
+14 ; If BACKUP not performed, then ABORT installation.
IF +$GET(Y)'=1
Begin DoDot:1
+15 SET XPDABORT=1
+16 DO PASSMESG^BLRPRE31("ATTENTION")
+17 DO BMES^XPDUTL($JUSTIFY("",15)_"SUCCESSFUL system backup has >>> NOT <<< been confirmed.")
+18 DO BMES^XPDUTL($JUSTIFY("",25)_"Installer: "_$$GET1^DIQ(200,DUZ,"NAME")_" ["_DUZ_"].")
+19 DO BMES^XPDUTL($JUSTIFY("",15)_"Install Aborting.")
+20 ; Pause 1 second to let the user see the message.
HANG 1
End DoDot:1
QUIT
+21 ;
+22 ; Store backup confirmation person & date/time
+23 SET BCKUPCNT=1+$ORDER(^BLRINSTL("LAB PATCH",CP,"BACKUP CONFIRMED BY",""),-1)
+24 SET ^BLRINSTL("LAB PATCH",CP,"BACKUP CONFIRMED BY",BCKUPCNT)=DUZ_"^"_$PIECE($GET(^VA(200,DUZ,0)),U)
+25 SET ^BLRINSTL("LAB PATCH",CP,"BACKUP CONFIRMED BY",BCKUPCNT,"DATE/TIME")=$$HTE^XLFDT($HOROLOG,"5MZ")
+26 ;
+27 DO BOKAY^BLRPRE31("SUCCESSFUL system backup CONFIRMED by: "_$$GET1^DIQ(200,DUZ,"NAME")_".",5)
+28 ; Pause 1 second to let the user see the message.
HANG 1
+29 QUIT
+30 ;
SAVEOFF ; EP - Save off all routines being updated by this patch into the ^rBACKUP global.
+1 NEW (DILOCKTM,DISYS,DT,DTIME,DUZ,IO,IOBS,IOF,IOM,ION,IOS,IOSL,IOST,IOT,IOXY,U,XPARSYS,XQXFLG)
+2 ;
+3 FOR RTN="BLRRLEVN","BLRRLEVT","LROE","LRPHSET"
Begin DoDot:1
+4 KILL ERRS,RTNA
+5 FOR LN=0:1:$GET(^ROUTINE(RTN,0,0))
Begin DoDot:2
+6 SET RTNA(LN)=$GET(^ROUTINE(RTN,0,LN))
End DoDot:2
+7 SET X=$$ROUTINE^%R(RTN_".INT",.RTNA,.ERRS,"CSB")
End DoDot:1
+8 QUIT