Home   Package List   Routine Alphabetical List   Global Alphabetical List   FileMan Files List   FileMan Sub-Files List   Package Component Lists   Package-Namespace Mapping  
Routine: BLRPRE

BLRPRE.m

Go to the documentation of this file.
  1. BLRPRE ; IHS/HQW/TPF - ENVIRONMENT CHECK FOR PATCH 16; [ 05/28/2003 11:54 AM ]
  1. ;;5.2;LR;**1016**;NOV 18, 2002
  1. ;
  1. S $P(LINE,"*",81)=""
  1. S XPDNOQUE="NO QUE" ;NO QUEUING ALLOWED
  1. S (XPDDIQ("XPZ1"),XPDDIQ("XPZ2"))=0 ;PREVENT "DIABLE OPTIONS" AND "MOVE ROUTINES" QUESTIONS
  1. S XPDABORT=0
  1. I '$G(DUZ) W !,"DUZ UNDEFINED OR 0." D SORRY Q
  1. ;
  1. I '$L($G(DUZ(0))) W !,"DUZ(0) UNDEFINED OR NULL." D SORRY Q
  1. ;
  1. D HOME^%ZIS,DT^DICRW
  1. S X=$P($G(^VA(200,DUZ,0)),U)
  1. I $G(X) D BMES^XPDUTL("Installer cannot be identified!") D SORRY Q
  1. D BMES^XPDUTL("Hello, "_$P(X,",",2)_" "_$P(X,","))
  1. D BMES^XPDUTL("Checking Environment for Patch "_$P($T(+2),";",5)_" of Version "_$P($T(+2),";",3)_" of "_$P($T(+2),";",4)_".")
  1. ;
  1. S X=$G(^DD("VERSION"))
  1. D BMES^XPDUTL("Need at least FileMan 21.....FileMan "_X_" Present")
  1. I X<21 D SORRY Q
  1. ;
  1. S X=$G(^DIC(9.4,$O(^DIC(9.4,"C","XU",0)),"VERSION"))
  1. D BMES^XPDUTL("Need at least Kernel 8.0.....Kernel "_X_" Present")
  1. I X<8.0 D SORRY Q
  1. ;
  1. ;
  1. VERSION ;
  1. ;CHECK FOR PREVIOUS PATCH NEEDED
  1. S %=$D(^XPD("9.7","B","LR*5.2*1015"))
  1. I '% D Q
  1. . D BMES^XPDUTL("Patch 1016 of version 5.2 of the RPMS Laboratory Package")
  1. . D BMES^XPDUTL("Cannot Be Installed Unless")
  1. . D BMES^XPDUTL("Patch 1015 of version 5.2 Has Been Previously Installed.")
  1. . D SORRY
  1. ;
  1. ;GET INSTALL STATUS
  1. S %=$O(^XPD("9.7","B","LR*5.2*1015",""))
  1. S LRSTATUS=$P($G(^XPD(9.7,%,0)),U,9)
  1. I LRSTATUS'=3 D Q ;IF INSTALL STATUS NOT COMPLETE QUIT
  1. .D BMES^XPDUTL("Install of Patch 1015 not complete!")
  1. .D SORRY
  1. ;
  1. D BMES^XPDUTL("Patch 1015 of version LR 5.2 Has Been Previously Installed......OK to continue")
  1. ;
  1. ;
  1. ;
  1. ENVOK ; If this is just an environment check, end here.
  1. D BMES^XPDUTL("ENVIRONMENT OK.")
  1. ;
  1. ; The following line prevents the "Disable Options..." and "Move
  1. ; Routines..." questions from being asked during the install.
  1. I $G(XPDENV)=1 S (XPDDIQ("XPZ1"),XPDDIQ("XPZ2"))=0
  1. ;
  1. ;VERIFY BACKUPS HAVE BEEN DONE
  1. W !!
  1. S DIR(0)="Y"
  1. S DIR("B")="NO"
  1. S DIR("A")="Has a SUCCESSFUL system backup been performed??"
  1. D ^DIR
  1. I $D(DIRUT)!($G(Y)=0) D BMES^XPDUTL("Please perform a successful backup before contnuing!!") S XPDABORT=1 Q
  1. S %DT="R",X="NOW" D ^%DT X ^DD("DD")
  1. D BMES^XPDUTL("BACKUPS CONFIRMED BY "_$P($G(^VA(200,DUZ,0)),U)_" ON "_$P(Y,"@")_" AT "_$P(Y,"@",2))
  1. ;
  1. ;
  1. Q
  1. SORRY ;
  1. K DIFQ
  1. S XPDABORT=1
  1. D BMES^XPDUTL("Sorry....something is wrong with your enviroment")
  1. D BMES^XPDUTL("for a Lab 5.2 Patch 15 install!")
  1. D BMES^XPDUTL("Please print/capture this screen and notify")
  1. D BMES^XPDUTL("the Help Desk")
  1. Q