HLPOSTQ ;ALB/JRP - POST-INIT QUESTIONS;23-MAR-95
;;1.6;HEALTH LEVEL SEVEN;;Oct 13, 1995
RUNAGAIN(RUNDATE) ;ASK USER IF POST-INIT SHOULD BE RUN AGAIN
;INPUT : RUNDATE - Date post-init was originally run
;OUTPUT : 1 = Yes
; 0 = No
; -1 = Error (bad input/time out/user abort)
;
;CHECK INPUT
Q:('$G(RUNDATE)) -1
Q:(RUNDATE'?7N.1".".6N) -1
;DECLARE VARIABLES
N X,Y,DIR,DTOUT,DUOUT,DIRUT,DIROUT
S Y=RUNDATE
X ^DD("DD")
S RUNDATE=$P(Y,"@",1)_" @ "_$P(Y,"@",2)
S DIR(0)="YA"
S DIR("A")="Do you wish to continue ? "
S DIR("A",1)="Post-init was already run on "_RUNDATE
S DIR("B")="NO"
S DIR("?",1)="This post-init has already been run. Answering 'YES' will allow you to"
S DIR("?",2)="selectively re-run portions of the post-init. If you do not want to do"
S DIR("?")="this, answer 'NO' (the default response)."
W !!
D ^DIR
;USER ABORT
Q:($D(DIRUT)) -1
;RETURN Y
Q (+Y)
PROTINST() ;ASK USER IF PROTOCOLS SHOULD BE RE-INSTALLED
;INPUT : None
;OUTPUT : 1 = Yes
; 0 = No
; -1 = Error (bad input/time out/user abort)
;
;DECLARE VARIABLES
N X,Y,DIR,DTOUT,DUOUT,DIRUT,DIROUT
S DIR(0)="YA"
S DIR("A")="Do you want to re-install PROTOCOLS ? "
S DIR("B")="YES"
S DIR("?",1)="This package distributes a set of protocols which may have already"
S DIR("?",2)="been installed. Answering 'YES' (the default and recommended response)"
S DIR("?")="will re-install these protocols."
W !!
D ^DIR
;USER ABORT
Q:($D(DIRUT)) -1
;RETURN Y
Q (+Y)
LISTINST() ;ASK USER IF LIST TEMPLATES SHOULD BE RE-INSTALLED
;INPUT : None
;OUTPUT : 1 = Yes
; 0 = No
; -1 = Error (bad input/time out/user abort)
;
;DECLARE VARIABLES
N X,Y,DIR,DTOUT,DUOUT,DIRUT,DIROUT
S DIR(0)="YA"
S DIR("A")="Do you want to re-install LIST TEMPLATES ? "
S DIR("B")="YES"
S DIR("?",1)="This package distributes a set of list templates which may have already"
S DIR("?",2)="been installed. Answering 'YES' (the default and recommended response)"
S DIR("?")="will re-install these list templates."
W !!
D ^DIR
;USER ABORT
Q:($D(DIRUT)) -1
;RETURN Y
Q (+Y)
FILECNV() ;ASK USER IF FILE CONVERSIONS SHOULD BE RE-RUN
;INPUT : None
;OUTPUT : 1 = Yes
; 0 = No
; -1 = Error (bad input/time out/user abort)
;
;DECLARE VARIABLES
N X,Y,DIR,DTOUT,DUOUT,DIRUT,DIROUT
S DIR(0)="YA"
S DIR("A")="Do you want to re-run the file conversions ? "
S DIR("B")="YES"
S DIR("?",1)="Installation of this package requires that a set of file conversions be"
S DIR("?",2)="run. Answering 'YES' (the default and recommended response) will allow"
S DIR("?",3)="these conversions to be re-run. Answer 'NO' if the file conversions"
S DIR("?")="have already run to completion."
W !!
D ^DIR
;USER ABORT
Q:($D(DIRUT))
;RETURN Y
Q (+Y)
HLPOSTQ ;ALB/JRP - POST-INIT QUESTIONS;23-MAR-95
+1 ;;1.6;HEALTH LEVEL SEVEN;;Oct 13, 1995
RUNAGAIN(RUNDATE) ;ASK USER IF POST-INIT SHOULD BE RUN AGAIN
+1 ;INPUT : RUNDATE - Date post-init was originally run
+2 ;OUTPUT : 1 = Yes
+3 ; 0 = No
+4 ; -1 = Error (bad input/time out/user abort)
+5 ;
+6 ;CHECK INPUT
+7 IF ('$GET(RUNDATE))
QUIT -1
+8 IF (RUNDATE'?7N.1".".6N)
QUIT -1
+9 ;DECLARE VARIABLES
+10 NEW X,Y,DIR,DTOUT,DUOUT,DIRUT,DIROUT
+11 SET Y=RUNDATE
+12 XECUTE ^DD("DD")
+13 SET RUNDATE=$PIECE(Y,"@",1)_" @ "_$PIECE(Y,"@",2)
+14 SET DIR(0)="YA"
+15 SET DIR("A")="Do you wish to continue ? "
+16 SET DIR("A",1)="Post-init was already run on "_RUNDATE
+17 SET DIR("B")="NO"
+18 SET DIR("?",1)="This post-init has already been run. Answering 'YES' will allow you to"
+19 SET DIR("?",2)="selectively re-run portions of the post-init. If you do not want to do"
+20 SET DIR("?")="this, answer 'NO' (the default response)."
+21 WRITE !!
+22 DO ^DIR
+23 ;USER ABORT
+24 IF ($DATA(DIRUT))
QUIT -1
+25 ;RETURN Y
+26 QUIT (+Y)
PROTINST() ;ASK USER IF PROTOCOLS SHOULD BE RE-INSTALLED
+1 ;INPUT : None
+2 ;OUTPUT : 1 = Yes
+3 ; 0 = No
+4 ; -1 = Error (bad input/time out/user abort)
+5 ;
+6 ;DECLARE VARIABLES
+7 NEW X,Y,DIR,DTOUT,DUOUT,DIRUT,DIROUT
+8 SET DIR(0)="YA"
+9 SET DIR("A")="Do you want to re-install PROTOCOLS ? "
+10 SET DIR("B")="YES"
+11 SET DIR("?",1)="This package distributes a set of protocols which may have already"
+12 SET DIR("?",2)="been installed. Answering 'YES' (the default and recommended response)"
+13 SET DIR("?")="will re-install these protocols."
+14 WRITE !!
+15 DO ^DIR
+16 ;USER ABORT
+17 IF ($DATA(DIRUT))
QUIT -1
+18 ;RETURN Y
+19 QUIT (+Y)
LISTINST() ;ASK USER IF LIST TEMPLATES SHOULD BE RE-INSTALLED
+1 ;INPUT : None
+2 ;OUTPUT : 1 = Yes
+3 ; 0 = No
+4 ; -1 = Error (bad input/time out/user abort)
+5 ;
+6 ;DECLARE VARIABLES
+7 NEW X,Y,DIR,DTOUT,DUOUT,DIRUT,DIROUT
+8 SET DIR(0)="YA"
+9 SET DIR("A")="Do you want to re-install LIST TEMPLATES ? "
+10 SET DIR("B")="YES"
+11 SET DIR("?",1)="This package distributes a set of list templates which may have already"
+12 SET DIR("?",2)="been installed. Answering 'YES' (the default and recommended response)"
+13 SET DIR("?")="will re-install these list templates."
+14 WRITE !!
+15 DO ^DIR
+16 ;USER ABORT
+17 IF ($DATA(DIRUT))
QUIT -1
+18 ;RETURN Y
+19 QUIT (+Y)
FILECNV() ;ASK USER IF FILE CONVERSIONS SHOULD BE RE-RUN
+1 ;INPUT : None
+2 ;OUTPUT : 1 = Yes
+3 ; 0 = No
+4 ; -1 = Error (bad input/time out/user abort)
+5 ;
+6 ;DECLARE VARIABLES
+7 NEW X,Y,DIR,DTOUT,DUOUT,DIRUT,DIROUT
+8 SET DIR(0)="YA"
+9 SET DIR("A")="Do you want to re-run the file conversions ? "
+10 SET DIR("B")="YES"
+11 SET DIR("?",1)="Installation of this package requires that a set of file conversions be"
+12 SET DIR("?",2)="run. Answering 'YES' (the default and recommended response) will allow"
+13 SET DIR("?",3)="these conversions to be re-run. Answer 'NO' if the file conversions"
+14 SET DIR("?")="have already run to completion."
+15 WRITE !!
+16 DO ^DIR
+17 ;USER ABORT
+18 IF ($DATA(DIRUT))
QUIT
+19 ;RETURN Y
+20 QUIT (+Y)