source: FOIAVistA/trunk/r/FOUNDATIONS-XOBU/XOBUPRE.m@ 1595

Last change on this file since 1595 was 628, checked in by George Lilly, 15 years ago

initial load of FOIAVistA 6/30/08 version

File size: 1.8 KB
Line 
1XOBUPRE ;; mjk,ld/alb - Foundations Pre-Init ; 07/27/2002 13:00
2 ;;1.5;Foundations;;Sep 09, 2005
3 ;;Foundations Toolbox Release v1.5 [Build: 1.5.0.026]
4 ;
5 QUIT
6 ;
7EN ; -- pre-init code
8 ;
9 ; -- change package file name entry from XOBS VISTALINK SECURITY to VISTALINK SECURITY
10 DO PKGCHG
11 ;
12 ; -- delete obsolete SYSTEM file (18) if it exists
13 DO DEL(18,"SYSTEM")
14 ;
15 ; -- delete VISTALINK PERSON file (18.09) if it exists (interim file used in early developers' previews)
16 DO DEL(18.09,"VISTALINK PERSON")
17 ;
18 IF $$CHK() QUIT
19 ;
20 ; -- delete FOUNDATIONS SITE PARAMETERS file (18.01)
21 DO DEL(18.01,"FOUNDATIONS SITE PARAMETERS")
22 ;
23 ; -- delete FOUNDATIONS SECURITY PROVIDER file (18.02)
24 DO DEL(18.02,"FOUNDATIONS SECURITY PROVIDER")
25 ;
26 QUIT
27 ;
28PKGCHG ; -- change package file name
29 ;
30 ; -- change package file name entry to VISTALINK SECURITY
31 ; (should only affect VistALink v1.0 test sites)
32 NEW DA,DIC,DIE,DR,X,Y
33 SET DIC="^DIC(9.4,",DIC(0)="X",X="XOBS VISTALINK SECURITY" DO ^DIC
34 IF +Y>0 SET DIE=DIC,DA=+Y,DR=".01///VISTALINK SECURITY" DO ^DIE
35 ;
36 ; -- change package PREFIX for entry FOUNDATIONS
37 ; (should only affect VistALink v1.0 test sites)
38 NEW DA,DIC,DIE,DR,X,Y
39 SET DIC="^DIC(9.4,",DIC(0)="X",X="FOUNDATIONS",DIC("S")="IF $P(^(0),U,2)=""XOB""" DO ^DIC
40 IF +Y>0 SET DIE=DIC,DA=+Y,DR="1///XOBU" DO ^DIE
41 ;
42 QUIT
43 ;
44CHK() ; -- is newer version present
45 NEW XOBRES
46 ;
47 ; -- check if new configuration file is present
48 DO FILE^DID(18.03,"","NAME","XOBRES")
49 ;
50 ; -- if config file present than newer version installed
51 QUIT $GET(XOBRES("NAME"))="VISTALINK LISTENER CONFIGURATION"
52 ;
53DEL(XOBFILE,XOBNAME) ; -- delete file
54 NEW DIU,XOBRES
55 ;
56 DO FILE^DID(XOBFILE,"","NAME","XOBRES")
57 ;
58 ; -- if file present then delete
59 IF $GET(XOBRES("NAME"))=XOBNAME DO
60 . ; -- delete file and data
61 . SET DIU=XOBFILE,DIU(0)="TD" DO EN^DIU2
62 ;
63 QUIT
64 ;
Note: See TracBrowser for help on using the repository browser.