- AUTP8 ; IHS/ASDST/GTH - AUT 98.1 PATCH 8 ; [ 06/04/2001 5:53 PM ]
- ;;98.1;IHS DICTIONARIES (POINTERS);**8**;MAR 04, 1998;Build 6
- ;
- I '$G(DUZ) W !,"DUZ UNDEFINED OR 0." D SORRY(1) Q
- ;
- I '$L($G(DUZ(0))) W !,"DUZ(0) UNDEFINED OR NULL." D SORRY(1) Q
- ;
- I '(DUZ(0)["@") W:'$D(ZTQUEUED) !,"DUZ(0) DOES NOT CONTAIN AN '@'." D SORRY(1) Q
- ;
- S X=$P(^VA(200,DUZ,0),U)
- W !!,$$C^XBFUNC("Hello, "_$P(X,",",2)_" "_$P(X,","))
- W !!,$$C^XBFUNC("Checking Environment for "_$P($T(+2),";",4)_" V "_$P($T(+2),";",3)_" Patch "_$P($T(+2),";",5)_".")
- ;
- S X=$$VERSION^XPDUTL("AUT")
- W !!,$$C^XBFUNC("Need AUT v 98.1.....AUT v "_X_" Present")
- I X<98.1 D SORRY(1) Q
- ;
- S X=$$VERSION^XPDUTL("DI")
- W !,$$C^XBFUNC("Need at least FileMan 21.....FileMan "_X_" Present")
- I X<21 D SORRY(1) Q
- ;
- S X=$$VERSION^XPDUTL("XU")
- W !,$$C^XBFUNC("Need at least Kernel 8.....Kernel "_X_" Present")
- I X<8 D SORRY(1) Q
- ;
- NEW DA,DIC
- S X="AUT",DIC="^DIC(9.4,",DIC(0)="",D="C"
- D IX^DIC
- I Y<0,$D(^DIC(9.4,"C","AUT")) D Q
- . W !!,*7,*7,$$C^XBFUNC("You Have More Than One Entry In The"),!,$$C^XBFUNC("PACKAGE File with an ""AUT"" prefix.")
- . W !,$$C^XBFUNC("One entry needs to be deleted.")
- . W !,$$C^XBFUNC("FIX IT! Before Proceeding."),!!,*7,*7,*7
- . D SORRY(1)
- . I $$DIR^XBDIR("E")
- .Q
- W !,$$C^XBFUNC("No 'AUT' dups in PACKAGE file")
- ;
- ; If patches 1-7 have already been installed, don't load them.
- I $G(XPDENV)=0 D ; Run only during Load of Installation.
- . NEW DA
- . S DA(1)=+Y ; Y is set from previous DIC lookup into PACKAGE.
- . S DA=$O(^DIC(9.4,DA(1),22,"B",98.1,0))
- . F %=1:1:7 I $D(^DIC(9.4,DA(1),22,DA,"PAH","B",%)) S XPDQUIT("AUT*98.1*"_%)=1
- .Q
- ;
- ; The following line prevents the "Disable Options..." and "Move
- ; Routines..." questions from being asked during the install.
- I $G(XPDENV)=1 S (XPDDIQ("XPZ1"),XPDDIQ("XPZ2"))=0
- ;
- W !!,$$C^XBFUNC("ENVIRONMENT OK.")
- ;
- NEW B
- I $G(XPDA) S B=$O(^XTMP("XPDI",XPDA,"BLD",0))
- I $G(B),$$DIR^XBDIR("Y","Do you want to see the notes","NO","Do you want to see the notes file for this patch","","",1) D
- . S %=0
- . F S %=$O(^XTMP("XPDI",XPDA,"BLD",B,1,%)) Q:'% W !,^(%,0) I '(%#20),'$$DIR^XBDIR("E","","","","","",1) Q
- .Q
- KILL B
- ;
- I '$$DIR^XBDIR("E","","","","","",1) D SORRY(1) Q
- Q
- ;
- SORRY(X) ;
- KILL DIFQ
- S XPDQUIT=X
- F %=1:1:5 S XPDQUIT("AUT*98.1*"_%)=1
- W:'$D(ZTQUEUED) *7,!,$$C^XBFUNC("Sorry...."),$$DIR^XBDIR("E","Press RETURN")
- Q
- ;
- PRE ;EP - From KIDS.
- Q
- D BMES^XPDUTL("Beginning pre-install routine (PRE^AUTP8).")
- D BMES^XPDUTL("Pre-install routine is complete.")
- Q
- ;
- POST ;EP - From KIDS.
- D BMES^XPDUTL("Beginning post-install routine (POST^AUTP8).")
- D BMES^XPDUTL("Delivering MailMan message to select users...")
- D SAVE
- NEW DIFROM
- D MAIL^XBMAIL("ACHSZMGP,ACRZ MANAGERS MENU,XUMGR-XUPROGMODE","MSG^AUTP8MSG")
- S X="AUTP8MSG"
- X ^%ZOSF("DEL")
- D BMES^XPDUTL("Post-install routine is complete.")
- Q
- ;
- SAVE ; Save first few lines of install message into tmp global.
- KILL ^TMP("AUTP8MSG",$J)
- S ^TMP("AUTP8MSG",$J,1,0)="AUTP8MSG ; IHS/ASDST/GTH - AUT INSTALL MESSAGE ;"
- S ^TMP("AUTP8MSG",$J,2,0)=$T(+2)
- S ^TMP("AUTP8MSG",$J,3,0)="MSG ;;"
- S ^TMP("AUTP8MSG",$J,4,0)=" ;;AUT V "_$P($T(+2),";",3)_" "_$P($T(+2),";",4)_", Patch "_$P($P($T(+2),";",5),"**",2)
- S ^TMP("AUTP8MSG",$J,5,0)=" ;; --- AUT v 98.1, Patch 8, has been installed into this uci ---"
- NEW B,XCM,DIE,XCN
- S B=$O(^XTMP("XPDI","AUT*98.1*8","BLD",0))
- I B S %=0 F S %=$O(^XTMP("XPDI","AUT*98.1*8","BLD",B,1,%)) Q:'% S ^TMP("AUTP8MSG",$J,(%+5),0)=" ;;"_^(%,0)
- KILL B
- S X="AUTP8MSG",DIE="^TMP(""AUTP8MSG"",$J,",XCN=0
- X ^%ZOSF("SAVE")
- KILL ^TMP("AUTP8MSG",$J)
- Q
- ;
- AUTP8 ; IHS/ASDST/GTH - AUT 98.1 PATCH 8 ; [ 06/04/2001 5:53 PM ]
- +1 ;;98.1;IHS DICTIONARIES (POINTERS);**8**;MAR 04, 1998;Build 6
- +2 ;
- +3 IF '$GET(DUZ)
- WRITE !,"DUZ UNDEFINED OR 0."
- DO SORRY(1)
- QUIT
- +4 ;
- +5 IF '$LENGTH($GET(DUZ(0)))
- WRITE !,"DUZ(0) UNDEFINED OR NULL."
- DO SORRY(1)
- QUIT
- +6 ;
- +7 IF '(DUZ(0)["@")
- IF '$DATA(ZTQUEUED)
- WRITE !,"DUZ(0) DOES NOT CONTAIN AN '@'."
- DO SORRY(1)
- QUIT
- +8 ;
- +9 SET X=$PIECE(^VA(200,DUZ,0),U)
- +10 WRITE !!,$$C^XBFUNC("Hello, "_$PIECE(X,",",2)_" "_$PIECE(X,","))
- +11 WRITE !!,$$C^XBFUNC("Checking Environment for "_$PIECE($TEXT(+2),";",4)_" V "_$PIECE($TEXT(+2),";",3)_" Patch "_$PIECE($TEXT(+2),";",5)_".")
- +12 ;
- +13 SET X=$$VERSION^XPDUTL("AUT")
- +14 WRITE !!,$$C^XBFUNC("Need AUT v 98.1.....AUT v "_X_" Present")
- +15 IF X<98.1
- DO SORRY(1)
- QUIT
- +16 ;
- +17 SET X=$$VERSION^XPDUTL("DI")
- +18 WRITE !,$$C^XBFUNC("Need at least FileMan 21.....FileMan "_X_" Present")
- +19 IF X<21
- DO SORRY(1)
- QUIT
- +20 ;
- +21 SET X=$$VERSION^XPDUTL("XU")
- +22 WRITE !,$$C^XBFUNC("Need at least Kernel 8.....Kernel "_X_" Present")
- +23 IF X<8
- DO SORRY(1)
- QUIT
- +24 ;
- +25 NEW DA,DIC
- +26 SET X="AUT"
- SET DIC="^DIC(9.4,"
- SET DIC(0)=""
- SET D="C"
- +27 DO IX^DIC
- +28 IF Y<0
- IF $DATA(^DIC(9.4,"C","AUT"))
- Begin DoDot:1
- +29 WRITE !!,*7,*7,$$C^XBFUNC("You Have More Than One Entry In The"),!,$$C^XBFUNC("PACKAGE File with an ""AUT"" prefix.")
- +30 WRITE !,$$C^XBFUNC("One entry needs to be deleted.")
- +31 WRITE !,$$C^XBFUNC("FIX IT! Before Proceeding."),!!,*7,*7,*7
- +32 DO SORRY(1)
- +33 IF $$DIR^XBDIR("E")
- +34 QUIT
- End DoDot:1
- QUIT
- +35 WRITE !,$$C^XBFUNC("No 'AUT' dups in PACKAGE file")
- +36 ;
- +37 ; If patches 1-7 have already been installed, don't load them.
- +38 ; Run only during Load of Installation.
- IF $GET(XPDENV)=0
- Begin DoDot:1
- +39 NEW DA
- +40 ; Y is set from previous DIC lookup into PACKAGE.
- SET DA(1)=+Y
- +41 SET DA=$ORDER(^DIC(9.4,DA(1),22,"B",98.1,0))
- +42 FOR %=1:1:7
- IF $DATA(^DIC(9.4,DA(1),22,DA,"PAH","B",%))
- SET XPDQUIT("AUT*98.1*"_%)=1
- +43 QUIT
- End DoDot:1
- +44 ;
- +45 ; The following line prevents the "Disable Options..." and "Move
- +46 ; Routines..." questions from being asked during the install.
- +47 IF $GET(XPDENV)=1
- SET (XPDDIQ("XPZ1"),XPDDIQ("XPZ2"))=0
- +48 ;
- +49 WRITE !!,$$C^XBFUNC("ENVIRONMENT OK.")
- +50 ;
- +51 NEW B
- +52 IF $GET(XPDA)
- SET B=$ORDER(^XTMP("XPDI",XPDA,"BLD",0))
- +53 IF $GET(B)
- IF $$DIR^XBDIR("Y","Do you want to see the notes","NO","Do you want to see the notes file for this patch","","",1)
- Begin DoDot:1
- +54 SET %=0
- +55 FOR
- SET %=$ORDER(^XTMP("XPDI",XPDA,"BLD",B,1,%))
- IF '%
- QUIT
- WRITE !,^(%,0)
- IF '(%#20)
- IF '$$DIR^XBDIR("E","","","","","",1)
- QUIT
- +56 QUIT
- End DoDot:1
- +57 KILL B
- +58 ;
- +59 IF '$$DIR^XBDIR("E","","","","","",1)
- DO SORRY(1)
- QUIT
- +60 QUIT
- +61 ;
- SORRY(X) ;
- +1 KILL DIFQ
- +2 SET XPDQUIT=X
- +3 FOR %=1:1:5
- SET XPDQUIT("AUT*98.1*"_%)=1
- +4 IF '$DATA(ZTQUEUED)
- WRITE *7,!,$$C^XBFUNC("Sorry...."),$$DIR^XBDIR("E","Press RETURN")
- +5 QUIT
- +6 ;
- PRE ;EP - From KIDS.
- +1 QUIT
- +2 DO BMES^XPDUTL("Beginning pre-install routine (PRE^AUTP8).")
- +3 DO BMES^XPDUTL("Pre-install routine is complete.")
- +4 QUIT
- +5 ;
- POST ;EP - From KIDS.
- +1 DO BMES^XPDUTL("Beginning post-install routine (POST^AUTP8).")
- +2 DO BMES^XPDUTL("Delivering MailMan message to select users...")
- +3 DO SAVE
- +4 NEW DIFROM
- +5 DO MAIL^XBMAIL("ACHSZMGP,ACRZ MANAGERS MENU,XUMGR-XUPROGMODE","MSG^AUTP8MSG")
- +6 SET X="AUTP8MSG"
- +7 XECUTE ^%ZOSF("DEL")
- +8 DO BMES^XPDUTL("Post-install routine is complete.")
- +9 QUIT
- +10 ;
- SAVE ; Save first few lines of install message into tmp global.
- +1 KILL ^TMP("AUTP8MSG",$JOB)
- +2 SET ^TMP("AUTP8MSG",$JOB,1,0)="AUTP8MSG ; IHS/ASDST/GTH - AUT INSTALL MESSAGE ;"
- +3 SET ^TMP("AUTP8MSG",$JOB,2,0)=$TEXT(+2)
- +4 SET ^TMP("AUTP8MSG",$JOB,3,0)="MSG ;;"
- +5 SET ^TMP("AUTP8MSG",$JOB,4,0)=" ;;AUT V "_$PIECE($TEXT(+2),";",3)_" "_$PIECE($TEXT(+2),";",4)_", Patch "_$PIECE($PIECE($TEXT(+2),";",5),"**",2)
- +6 SET ^TMP("AUTP8MSG",$JOB,5,0)=" ;; --- AUT v 98.1, Patch 8, has been installed into this uci ---"
- +7 NEW B,XCM,DIE,XCN
- +8 SET B=$ORDER(^XTMP("XPDI","AUT*98.1*8","BLD",0))
- +9 IF B
- SET %=0
- FOR
- SET %=$ORDER(^XTMP("XPDI","AUT*98.1*8","BLD",B,1,%))
- IF '%
- QUIT
- SET ^TMP("AUTP8MSG",$JOB,(%+5),0)=" ;;"_^(%,0)
- +10 KILL B
- +11 SET X="AUTP8MSG"
- SET DIE="^TMP(""AUTP8MSG"",$J,"
- SET XCN=0
- +12 XECUTE ^%ZOSF("SAVE")
- +13 KILL ^TMP("AUTP8MSG",$JOB)
- +14 QUIT
- +15 ;