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

BLRMERGI.m

Go to the documentation of this file.
  1. BLRMERGI ;IHS/ISD/EDE - LR*5.2*1005` PATCH ENVIRONMENT CHECK/POST INIT ROUTINE [ 01/25/1999 10:30 AM ]
  1. ;;5.2;BLR;**1005**;DEC 14, 1998
  1. ;
  1. START ; Does not prevent loading of the transport global.
  1. ; Environment check is done only during the install.
  1. Q:'$G(XPDENV)
  1. D CHECK
  1. D EXIT
  1. Q
  1. ;
  1. CHECK ; Perform environment check
  1. N BLRVER
  1. I $S('$G(IOM):1,'$G(IOSL):1,$G(U)'="^":1,1:0) D Q
  1. . D BMES^XPDUTL($$CJ^XLFSTR("Terminal Device is not defined",80))
  1. . S XPDQUIT=2
  1. . Q
  1. I $S('$G(DUZ):1,$D(DUZ)[0:1,$D(DUZ(0))[0:1,1:0) D Q
  1. . D BMES^XPDUTL($$CJ^XLFSTR("Please log in to set local DUZ... variables",80))
  1. . S XPDQUIT=2
  1. . Q
  1. I '$D(^VA(200,$G(DUZ),0))#2 D Q
  1. . D BMES^XPDUTL($$CJ^XLFSTR("You are not a valid user on this system",80))
  1. . S XPDQUIT=2
  1. . Q
  1. S BLRVER=$$VERSION^XPDUTL("LR")
  1. I BLRVER'[5.2 D Q
  1. . D BMES^XPDUTL($$CJ^XLFSTR("You must have LAB MESSAGING V5.2 Installed",80))
  1. . S XPDQUIT=2
  1. . Q
  1. S XPDIQ("XPZ1","B")="NO"
  1. Q
  1. ;
  1. EXIT ;
  1. I $G(XPDQUIT) D BMES^XPDUTL($$CJ^XLFSTR("--- Install Environment Check FAILED ---",80))
  1. I '$G(XPDQUIT) D BMES^XPDUTL($$CJ^XLFSTR("--- Environment Check is Ok ---",80))
  1. Q
  1. ;
  1. POST ; PEP - ENTRY POINT FOR POST INITITALIZATION
  1. N BLRPKIEN
  1. S BLRPKIEN=$O(^DIC(9.4,"C","LR",0))
  1. Q:'BLRPKIEN
  1. ; if AFFECTS RECORD MERGE for file 2 already in Package entry
  1. ; edit data, else add subfile entry.
  1. D:'$D(^DIC(9.4,BLRPKIEN,20,2,0)) ADD ; add subfile entry if not there
  1. D EDIT
  1. Q
  1. ;
  1. ADD ; ADD AFFECTS RECORD MERGE ENTRY
  1. S DIC="^DIC(9.4,26,20," ; global root of subfile
  1. S DIC(0)="L" ; allow laygo
  1. S DIC("P")=$P(^DD(9.4,20,0),"^",2) ; subfile bookeeper node
  1. S DA(1)=26 ; entry # subfile
  1. S DINUM=2 ; force entry in subfile
  1. S X=2 ; entry # of file affected
  1. D FILE^DICN
  1. Q
  1. ;
  1. EDIT ; EDIT EXISTING AFFECTS RECORD MERGE ENTRY
  1. S DIE="^DIC(9.4,"_BLRPKIEN_",20," ; global root of subfile
  1. S DA(1)=BLRPKIEN ; entry # in file
  1. S DA=2 ; entry # in subfile
  1. S DR="3////BLRMERG;4////I $D(^DPT(XDRMRG(""FR""),""LR"")) S XDRZ=1"
  1. D ^DIE
  1. Q