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

GMRCPOS2.m

Go to the documentation of this file.
  1. GMRCPOS2 ; SLC/DLT - Consult postinit file maintenance ;2/18/99 15:04
  1. ;;3.0;CONSULT/REQUEST TRACKING;**2**;DEC 27, 1997
  1. EN ; -- postinit
  1. N GMRCEND
  1. D FIX101
  1. Q
  1. FIX101 ; Move the GMRCR prefixed protocols "File Link" values from the
  1. ; CONSULTS PARAMETERS FILE 123.9 to the GMRCR protocol entry
  1. ;
  1. N DA,DIE,DR,FILELINK,SITE,NAME,SERVICE
  1. S SITE=$O(^GMR(123.9,0)) I 'SITE D BMES^XPDUTL("CONSULTS PARAMETERS FILE not defined. Stopped PROTOCOL FILE cleanup!") S GMRCEND=1 Q
  1. ;
  1. I '$D(^GMR(123.9,SITE,99,0)) D Q:GMRCEND
  1. .D BMES^XPDUTL("No GMRCR protocols saved before CONSULT/REQUEST TRACKING V 3.0 installation")
  1. .D BMES^XPDUTL("Need to MANUALLY correct the GMRCR-prefixed PROTOCOL FILE, FILE LINK field")
  1. .S GMRCEND=1 Q
  1. ;
  1. S DA=0 F S DA=$O(^GMR(123.9,SITE,99,DA)) Q:'DA D
  1. . S FILELINK=$P($G(^GMR(123.9,SITE,99,DA,0)),"^",2)
  1. . S NAME=$P($G(^ORD(101,DA,0)),U,1) I '$L(NAME) D Q
  1. .. D BMES^XPDUTL("No FILE LINK update for PROTOCOL: PROTOCOL "_DA_" no longer defined")
  1. . S SERVICE=$P($G(^GMR(123.5,+FILELINK,0)),"^",1)
  1. . Q:FILELINK=$P($G(^ORD(101,DA,5)),"^",1) ;no update needed
  1. . S DIE="^ORD(101,",DR="6////^S X=FILELINK"
  1. . D ^DIE
  1. . D BMES^XPDUTL("Changed PROTOCOL: "_NAME_", FILE LINK field to: "_SERVICE)
  1. . Q
  1. Q