source: FOIAVistA/tag/r/ONCOLOGY-ONC/ONCOENV.m@ 1033

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

initial load of FOIAVistA 6/30/08 version

File size: 4.6 KB
Line 
1ONCOENV ;WASH ISC/SRR,MLH-PACKAGE ENVIRONMENT CHECK VERSION 2.11
2 ;;2.11;ONCOLOGY;;Mar 07, 1995
3 ;
4 ; Just a reminder - if variables are defined here for the post init,
5 ; don't NEW them in this routine or they'll be clobbered.
6 I '$D(IOF) S IOP="HOME" D ^%ZIS ; set up environment
7 ;
8PRE ; PRE INIT - Check user and device
9 I $G(DUZ)<1 W !!!?15,"YOU ARE NOT IDENTIFIED AS A USER!!",!!?17,"TERMINATING this Installation!",!!! K DIFQ
10 E D CK
11 D EX ; clean up
12 QUIT
13 ;
14CK ;Check if installed
15 ; 7/14/94 MLH added NEW to next line to cause version to be
16 ; correctly identified
17NN N VR,V S VR=$P($T(ONCOENV+1),";",3),V=$G(^ONCO(169.99,0,"NVR")) ; version number
18 IF V=VR D ; already installed - bail out?
19 . N I,Y
20 . S I=$P(^ONCO(169.99,0),U,3) ; site number
21 . S Y=$P(^ONCO(169.99,I,0),U,4) ; installation date
22 . D DD^%DT
23 . W !!,*7,*7,?10,"INSTALLATION "_V_" Completed: "_Y_"."
24 . I '$$GOAHEAD K DIFQ ; let user bail out
25 . Q
26 ;END IF
27 ;
28 I $D(DIFQ) D START ; didn't bail out
29 I $D(DIFQ),'OFST D RSTSET ; set up for restaging
30 ;
31 ; 7/12/94 MLH REMOVED logic to check proceeding w/o restaging
32 ; to entry point ONCOENA
33 ;
34 I $D(DIFQ),$G(ONCOI1ST)'>0 D QNORSTG^ONCOENA ; they don't want to restage - do they want to quit?
35 Q
36 ;
37START S XIU="T",OFST=0,NM="ONCOLOGY TUMOR REGISTRY"
38 S %H=$H D YX^%DTC S (ONCOBEG,ONCOST)=Y D DD^%DT
39 D LOGO^ONCODIS,V W !!
40 IF '$O(^ONCO(160,0)) D ; virgin install
41 . S OFST=1
42 . D CV
43 . Q
44 ELSE D ; non-virgin
45 . D CI
46 . Q
47 ;END IF
48 ;
49EX ;Exit conversion
50 K DIK,DIR,DIU,ER,RR,I,J,K,L,LTD,MC,N,N1,NAC,NF,NFM,NXT,REM,S,T,TC,XDD,XIU F I="T","N","M" K ^UTILITY($J,I)
51 Q
52 ;
53CI ;CHECK INSTALLATION VERSION
54 S INS=$G(^ONCO(169.99,0,"INS"))
55 IF INS'="",'$D(^DD(160)) D ; previously aborted in the middle?
56 . W !!?10,"Appears installation was started, not completed"
57 . W !?10,"- no other information available, will continue..."
58 . S V=$G(^ONCO(169.99,0,"OVR"))
59 . Q
60 ELSE D
61 . IF INS'="" D ; previously aborted in the middle?
62 .. S VX=$P(INS,U),ST=$P(INS,U,2),Y=ST D DD^%DT
63 .. W !!?10,"Appears installation of V"_VX_" on "_Y
64 .. W !?10,"began, but did not complete - will continue installation..."
65 .. Q
66 . ;END IF
67 . ;
68 . D CV ; get version number
69 . Q
70 ;END IF
71 ;
72CN W !!,"I am going to clean out DD's (national fields only)."
73 W !,"I will also purge the static files, except for FOLLOW-UP FORM LETTER."
74 D AB ; do they want to abort?
75 I Y'=1 ; yes, user bailed out
76 E I V=""!(V>1.79) ; no, and no need to do ICDO conv
77 E W !!,"Please convert to Version 2.0 before proceeding.",!! K DIFQ ; no, but version too old - must do ICDO conv
78 ;END IF
79 ;
80 Q
81 ;
82V W !!!?25,"INSTALLATION: VERSION ",VR,!?25,Y Q
83 ;
84AB K DIR S DIR("A")=" CONTINUE with Installation: ",DIR("B")="Yes",DIR(0)="Y" D ^DIR Q:Y=1 D ABORT Q
85ABORT W !!?7,"Installation aborted - you may DO ^ONCOINIT at any time." K DIFQ
86 Q
87 ;
88GOAHEAD() ; does user want to go ahead with installation?
89 N DIR
90 S DIR("A")="Do you want to proceed",DIR("B")="No",DIR(0)="Y"
91 S DIR("?",1)="It appears that you have already installed this version successfully."
92 S DIR("?",2)="Unless your ISC has requested that you reinstall, you can stop here"
93 S DIR("?",2.5)="and no changes will have been made to the package."
94 IF $T(+2)["2.1;" D ; following message applies only to released version
95 . S DIR("?",2.9)=""
96 . S DIR("?",3)="Remember that if you proceed with installation, you must re-apply"
97 . S DIR("?",4)="all patches to this package before allowing users to log back in"
98 . S DIR("?",5)="to the system."
99 . S DIR("?",5.9)=""
100 . S DIR("?",6)="If you need further help, answer No here and contact your ISC."
101 . Q
102 ;END IF
103 ;
104 D ^DIR
105 Q Y
106 ;
107CV S VRN=$G(^ONCO(169.99,0,"NVR")),V=$P(VRN,U),VND=$P(VRN,U,3),V=$S('V:"NONE",1:V),VX=$S(V["T":"Alpha Test",V["V":"Beta Test/Verification",1:"Released")_" Version",^ONCO(169.99,0,"OVR")=V
108 I 'OFST W !?20,"VERSION "_V_" currently installed",!?32,VX
109 E I '$D(^ONCO(160)) W !,?20,"This is a VIRGIN Installation",!!
110 Q
111 ;
112RSTSET ;JAH 01FEB95; Set up for restaging - called by CK
113 W !!,"The post-initialization can automatically recompute"
114 W !,"the AJCC staging of entries on your primary file with"
115 W !,"a DIAGNOSIS DATE on or after a date you specify."
116 W !!,"Answer YES to restage."
117 S DIR(0)="Y",DIR("B")="NO",DIR("A")="Do you want to RESTAGE"
118 S DIR("?")="Answer Yes or No to the restaging question."
119 S DIR("?",1)="The Oncology Registrar may be best suited to help answer the restaging questions"
120 D ^DIR
121 I $D(DTOUT)!$D(DUOUT)!(Y=0) S ONCOI1ST=-1
122 E S ONCOI1ST=$$RSTGASK^ONCOU55A ; get the date
123 Q
Note: See TracBrowser for help on using the repository browser.