ACHS31E1 ;IHS/OIT/FCJ - ACHS 3.1 PATCH ENV CHECK ;
;;3.1;CONTRACT HEALTH MGMT SYSTEM;**27**;JUN 11,2001;Build 43
;3.1*14 1/11/2008;IHS/OIT/FCJ
; CHANGE INTROE SECTION WITH EACH PATCH and requirements
;
;
I '$G(IOM) D HOME^%ZIS
I '$G(DUZ) W !,"DUZ UNDEFINED OR 0." D SORRY(2) Q
I '$L($G(DUZ(0))) W !,"DUZ(0) UNDEFINED OR NULL." D SORRY(2) Q
I '(DUZ(0)["@") W:'$D(ZTQUEUED) !,"DUZ(0) DOES NOT CONTAIN AN '@'." D SORRY(2) Q
;
S X=$$GET1^DIQ(200,DUZ,.01)
W !!,$$CJ^XLFSTR("Hello, "_$P(X,",",2)_" "_$P(X,","),IOM)
W !!,$$CJ^XLFSTR("Checking Environment for "_$P($T(+2),";",4)_" V "_$P($T(+2),";",3)_" Patch "_$P($T(+2),";",5)_".",IOM)
;
NEW IORVON,IORVOFF
S X="IORVON;IORVOFF"
D ENDR^%ZISS
AR ;
;TEST FOR AREA OFFICE INSTALL, LEX AND ICD INSTALLS ARE NOT REQUIRED FOR AREA INSTALLS
S ACHSAR=0
S DIR(0)="Y",DIR("A")="Is this an AREA OFFICE install",DIR("B")="N"
S DIR("?")="Only answer Yes if this is being installed in the Area office namespace without a facility operating in this namespace."
D ^DIR
I $D(DTOUT)!$D(DUOUT)!$D(DIRUT) W !,"User stopped environment check." Q
S ACHSAR=+Y
CHK ;
I '$$INSTALLD("ACHS*3.1*20") S XPDQUIT=2
I $$VCHK("DI","22.0",2,"<")
I '$$INSTALLD("XU*8.0*1017") S XPDQUIT=2
I '$$INSTALLD("AUPN*99.1*26") S XPDQUIT=2
I '$$INSTALLD("AG*7.1*13") S XPDQUIT=2
I '$$INSTALLD("AUT*98.1*20") S XPDQUIT=2
I $$VCHK("ATX","5.1",2,"<")
I ACHSAR=0 D
.I '$$INSTALLD("LEX*2.0*1003") S BMCQUIT=2 D SORRY(BMCQUIT)
.I $$VCHK("AICD","4.0",2,"<")
;
NEW DA,DIC
S X="ACHS",DIC="^DIC(9.4,",DIC(0)="",D="C"
D IX^DIC
I Y<0,$D(^DIC(9.4,"C","ACHS")) D
.W !!,*7,*7,$$CJ^XLFSTR("You Have More Than One Entry In The",IOM),!,$$CJ^XLFSTR("PACKAGE File with an ""ACHS"" prefix.",IOM)
.W !,$$CJ^XLFSTR(IORVON_"One entry needs to be deleted."_IORVOFF,IOM)
.D SORRY(2)
;
I $G(XPDQUIT) W !,$$CJ^XLFSTR(IORVON_"You must install it, Before Proceeding."_IORVOFF,IOM),!!,*7,*7,*7 Q
W !!,$$CJ^XLFSTR("ENVIRONMENT OK.",IOM)
D HELP^XBHELP("INTROE","ACHS31E1")
I '$$DIR^XBDIR("E","","","","","",1) D SORRY(2) Q
I $G(XPDENV)=1 S (XPDDIQ("XPZ1"),XPDDIQ("XPZ2"))=0 D HELP^XBHELP("INTROI","ACHS31E1") I '$$DIR^XBDIR("E","","","","","",1) D SORRY(2)
Q
;
SORRY(X) ;
KILL DIFQ
S XPDQUIT=X
W *7,!,$$CJ^XLFSTR("Sorry....FIX IT!",IOM)
Q
;
VCHK(ACHSPRE,ACHSVER,ACHSQUIT,ACHSCOMP) ; Check versions needed.
;
NEW ACHSV
S ACHSV=$$VERSION^XPDUTL(ACHSPRE)
W !,$$CJ^XLFSTR("Need "_$S(ACHSCOMP="<":"at least ",1:"")_ACHSPRE_" v "_ACHSVER_"....."_ACHSPRE_" v "_ACHSV_" Present",IOM)
I @(ACHSV_ACHSCOMP_ACHSVER) D SORRY(ACHSQUIT) Q 0
Q 1
INSTALLD(ACHS) ;EP; Determine if patch ACHS was installed, where ACHS is
; the name of the INSTALL. E.g "AVA*93.2*12".
;
NEW DIC,X,Y
; lookup package.
S X=$P(ACHS,"*",1)
S DIC="^DIC(9.4,",DIC(0)="FM",D="C"
D IX^DIC
I Y<1 Q 0
; lookup version.
S DIC=DIC_+Y_",22,",X=$P(ACHS,"*",2)
D ^DIC
I Y<1 Q 0
; lookup patch.
S DIC=DIC_+Y_",""PAH"",",X=$P(ACHS,"*",3)
D ^DIC
I Y<1 S P=DIC_"""B"","_X_")" I $O(@P)'="" S Y=1
I $D(P),$P(ACHS,"*")["XU" I '$D(@P) S Y=-1
I Y>0 W !,$$CJ^XLFSTR("Need at least "_ACHS_"....."_ACHS_" Present",IOM)
I Y<0 W !,$$CJ^XLFSTR("Need at least "_ACHS_".....",IOM)
Q $S(Y<1:0,1:1)
; -------------------------------------------
INTROE ; Intro text during KIDS Environment check.
;;In this distribution:
;;Modifications New MBI:
;; 1. Denial Letters/Fact Sheets (DEN)
;; 2. Enter New Denial (ADD)
;; 3. Master Delivery Order Report (MDOL)
;; 4. Print Documents (PD)
;; 5. Re-Print Documents (REP)
;; 6. Initial Document (ID)
;; 7. CHS data - prepare for export (CDPE)
;; 8. Re-Export CHS Transmission Data (RETD)
;; 9. Mark Patient for Export (XPT)
;; 10. Display Individual CHS Documents
;; 11. Print a CHEF Request
;;
;; See Notes file for specific options
;;
;;###
;
INTROI ; Intro text during KIDS Install.
;;A standard message will be produced by this update.
;;
;;If you run interactively, results are displayed on your screen,
;;in the mail message and in the INSTALL file.
;;If you queue to TaskMan, please read the mail message for results of
;;this update, and remember not to Q to the HOME device.
;;###
;
ACHS31E1 ;IHS/OIT/FCJ - ACHS 3.1 PATCH ENV CHECK ;
+1 ;;3.1;CONTRACT HEALTH MGMT SYSTEM;**27**;JUN 11,2001;Build 43
+2 ;3.1*14 1/11/2008;IHS/OIT/FCJ
+3 ; CHANGE INTROE SECTION WITH EACH PATCH and requirements
+4 ;
+5 ;
+6 IF '$GET(IOM)
DO HOME^%ZIS
+7 IF '$GET(DUZ)
WRITE !,"DUZ UNDEFINED OR 0."
DO SORRY(2)
QUIT
+8 IF '$LENGTH($GET(DUZ(0)))
WRITE !,"DUZ(0) UNDEFINED OR NULL."
DO SORRY(2)
QUIT
+9 IF '(DUZ(0)["@")
IF '$DATA(ZTQUEUED)
WRITE !,"DUZ(0) DOES NOT CONTAIN AN '@'."
DO SORRY(2)
QUIT
+10 ;
+11 SET X=$$GET1^DIQ(200,DUZ,.01)
+12 WRITE !!,$$CJ^XLFSTR("Hello, "_$PIECE(X,",",2)_" "_$PIECE(X,","),IOM)
+13 WRITE !!,$$CJ^XLFSTR("Checking Environment for "_$PIECE($TEXT(+2),";",4)_" V "_$PIECE($TEXT(+2),";",3)_" Patch "_$PIECE($TEXT(+2),";",5)_".",IOM)
+14 ;
+15 NEW IORVON,IORVOFF
+16 SET X="IORVON;IORVOFF"
+17 DO ENDR^%ZISS
AR ;
+1 ;TEST FOR AREA OFFICE INSTALL, LEX AND ICD INSTALLS ARE NOT REQUIRED FOR AREA INSTALLS
+2 SET ACHSAR=0
+3 SET DIR(0)="Y"
SET DIR("A")="Is this an AREA OFFICE install"
SET DIR("B")="N"
+4 SET DIR("?")="Only answer Yes if this is being installed in the Area office namespace without a facility operating in this namespace."
+5 DO ^DIR
+6 IF $DATA(DTOUT)!$DATA(DUOUT)!$DATA(DIRUT)
WRITE !,"User stopped environment check."
QUIT
+7 SET ACHSAR=+Y
CHK ;
+1 IF '$$INSTALLD("ACHS*3.1*20")
SET XPDQUIT=2
+2 IF $$VCHK("DI","22.0",2,"<")
+3 IF '$$INSTALLD("XU*8.0*1017")
SET XPDQUIT=2
+4 IF '$$INSTALLD("AUPN*99.1*26")
SET XPDQUIT=2
+5 IF '$$INSTALLD("AG*7.1*13")
SET XPDQUIT=2
+6 IF '$$INSTALLD("AUT*98.1*20")
SET XPDQUIT=2
+7 IF $$VCHK("ATX","5.1",2,"<")
+8 IF ACHSAR=0
Begin DoDot:1
+9 IF '$$INSTALLD("LEX*2.0*1003")
SET BMCQUIT=2
DO SORRY(BMCQUIT)
+10 IF $$VCHK("AICD","4.0",2,"<")
End DoDot:1
+11 ;
+12 NEW DA,DIC
+13 SET X="ACHS"
SET DIC="^DIC(9.4,"
SET DIC(0)=""
SET D="C"
+14 DO IX^DIC
+15 IF Y<0
IF $DATA(^DIC(9.4,"C","ACHS"))
Begin DoDot:1
+16 WRITE !!,*7,*7,$$CJ^XLFSTR("You Have More Than One Entry In The",IOM),!,$$CJ^XLFSTR("PACKAGE File with an ""ACHS"" prefix.",IOM)
+17 WRITE !,$$CJ^XLFSTR(IORVON_"One entry needs to be deleted."_IORVOFF,IOM)
+18 DO SORRY(2)
End DoDot:1
+19 ;
+20 IF $GET(XPDQUIT)
WRITE !,$$CJ^XLFSTR(IORVON_"You must install it, Before Proceeding."_IORVOFF,IOM),!!,*7,*7,*7
QUIT
+21 WRITE !!,$$CJ^XLFSTR("ENVIRONMENT OK.",IOM)
+22 DO HELP^XBHELP("INTROE","ACHS31E1")
+23 IF '$$DIR^XBDIR("E","","","","","",1)
DO SORRY(2)
QUIT
+24 IF $GET(XPDENV)=1
SET (XPDDIQ("XPZ1"),XPDDIQ("XPZ2"))=0
DO HELP^XBHELP("INTROI","ACHS31E1")
IF '$$DIR^XBDIR("E","","","","","",1)
DO SORRY(2)
+25 QUIT
+26 ;
SORRY(X) ;
+1 KILL DIFQ
+2 SET XPDQUIT=X
+3 WRITE *7,!,$$CJ^XLFSTR("Sorry....FIX IT!",IOM)
+4 QUIT
+5 ;
VCHK(ACHSPRE,ACHSVER,ACHSQUIT,ACHSCOMP) ; Check versions needed.
+1 ;
+2 NEW ACHSV
+3 SET ACHSV=$$VERSION^XPDUTL(ACHSPRE)
+4 WRITE !,$$CJ^XLFSTR("Need "_$SELECT(ACHSCOMP="<":"at least ",1:"")_ACHSPRE_" v "_ACHSVER_"....."_ACHSPRE_" v "_ACHSV_" Present",IOM)
+5 IF @(ACHSV_ACHSCOMP_ACHSVER)
DO SORRY(ACHSQUIT)
QUIT 0
+6 QUIT 1
INSTALLD(ACHS) ;EP; Determine if patch ACHS was installed, where ACHS is
+1 ; the name of the INSTALL. E.g "AVA*93.2*12".
+2 ;
+3 NEW DIC,X,Y
+4 ; lookup package.
+5 SET X=$PIECE(ACHS,"*",1)
+6 SET DIC="^DIC(9.4,"
SET DIC(0)="FM"
SET D="C"
+7 DO IX^DIC
+8 IF Y<1
QUIT 0
+9 ; lookup version.
+10 SET DIC=DIC_+Y_",22,"
SET X=$PIECE(ACHS,"*",2)
+11 DO ^DIC
+12 IF Y<1
QUIT 0
+13 ; lookup patch.
+14 SET DIC=DIC_+Y_",""PAH"","
SET X=$PIECE(ACHS,"*",3)
+15 DO ^DIC
+16 IF Y<1
SET P=DIC_"""B"","_X_")"
IF $ORDER(@P)'=""
SET Y=1
+17 IF $DATA(P)
IF $PIECE(ACHS,"*")["XU"
IF '$DATA(@P)
SET Y=-1
+18 IF Y>0
WRITE !,$$CJ^XLFSTR("Need at least "_ACHS_"....."_ACHS_" Present",IOM)
+19 IF Y<0
WRITE !,$$CJ^XLFSTR("Need at least "_ACHS_".....",IOM)
+20 QUIT $SELECT(Y<1:0,1:1)
+21 ; -------------------------------------------
INTROE ; Intro text during KIDS Environment check.
+1 ;;In this distribution:
+2 ;;Modifications New MBI:
+3 ;; 1. Denial Letters/Fact Sheets (DEN)
+4 ;; 2. Enter New Denial (ADD)
+5 ;; 3. Master Delivery Order Report (MDOL)
+6 ;; 4. Print Documents (PD)
+7 ;; 5. Re-Print Documents (REP)
+8 ;; 6. Initial Document (ID)
+9 ;; 7. CHS data - prepare for export (CDPE)
+10 ;; 8. Re-Export CHS Transmission Data (RETD)
+11 ;; 9. Mark Patient for Export (XPT)
+12 ;; 10. Display Individual CHS Documents
+13 ;; 11. Print a CHEF Request
+14 ;;
+15 ;; See Notes file for specific options
+16 ;;
+17 ;;###
+18 ;
INTROI ; Intro text during KIDS Install.
+1 ;;A standard message will be produced by this update.
+2 ;;
+3 ;;If you run interactively, results are displayed on your screen,
+4 ;;in the mail message and in the INSTALL file.
+5 ;;If you queue to TaskMan, please read the mail message for results of
+6 ;;this update, and remember not to Q to the HOME device.
+7 ;;###
+8 ;