BDGPOST ; IHS/ANMC/LJF - PIMS POSTINIT ; [ 04/09/2004 11:11 AM ]
;;5.3;PIMS;;APR 26, 2002
; post init code for ADT data
;
NEW X
S X(1)="IHS Postinit: Warning! These may take a long time to run."
S X(2)="If this process should error out, it can be restarted AFTER"
S X(3)="the cause of the error has been found and corrected. At that"
S X(4)="point, go into KIDS and select 'Installation...',then select"
S X(5)="'Restart Install of Package(s)'."
D MES^XPDUTL(.X)
;
;IHS/ITSC/WAR 8/20/03 - This next call was commented out because of too
; many past entries. The entries are now created by the new rec.
; fire new cross-references
;D AIHSDAM^BSDPOST ;set new AIHSDAM xref
;
; copy data to new parameter and table files
1 D PARAM^BSDPOST1,LOG(1) ;copy scheduling parameters to new file
2 D CLINIC^BSDPOST,LOG(2) ;copy clinic parameters to new file
3 D PCCLINK^BDGPOST1,LOG(3) ;add PIMS to PCC Master Control file
4 D PARAM^BDGPOST1,LOG(4) ;copy ADT parameters to new file
5 D WARD^BDGPOST2,LOG(5) ;copy IHS ward items to new file
6 D TRSPEC^BDGPOST1,LOG(6) ;new observation specialties
7 D CHRTDEF^BDGPOST1,LOG(7) ;copy chart deficiencies to new file
8 D EVENT^BDGPOST2,LOG(8) ;add non-PIMS items to event driver
9 D LETTER^BSDPOST,LOG(9) ;add Appointment Slip letter
;
; copy patient data to new file structures
10 D EN^BDGPOST3,LOG(10) ;build transfer facility file
11 D DGPM^BDGPOST2,LOG(11) ;move fields in file 405
12 D SIDNR^BDGPOST2,LOG(12) ;clean out old SI/DNR data
13 D SCHVST^BDGPOST2,LOG(13) ;copy Scheduled Visit data to new file
14 D WAIT^BSDPOST1,LOG(14) ;copy waiting list to new file
15 D IC^BDGPOST4,LOG(15) ;copy data to new Incomplete Chart file
;
16 I '$D(^BDGX(16)),$G(^DG(43,1,9999999))]"" S $P(^(9999999),U)=0 D LOG(16) ;stuff "track all patients in SPT" to NO
;
; clean up from last version
17 D OLDFILES^BDGPOST1,LOG(17) ;change name of old files
18 D ADTTMPL^BDGPOST1,LOG(18) ;stuff 2 ADT Template entries
19 D FACMOV^BDGPOST1,LOG(19) ;add new fac mov type
20 D MERG^BSDPOST,LOG(20) ;change Scheduling Merge routine
;
; set up new functions
21 D PCMM^BSDPOST1,LOG(21) ;set up server side files for PCMM
22 D POST^BSDLINK,LOG(22) ;set Sched entry for PCC merges
;IHS/ITSC/WAR 8/20/03 added this next call per the EHR project needs
23 D ASTOP^BSDPOST,LOG(23) ;index existing recs for EHR visit History
;IHS/ITSC/LJF 10/10/2003 added call to VA pre-init for patch 526
24 D EN^DG53P526,LOG(24) ;adds Resource & Device entries
;IHS/ITSC/WAR 10/17/03 added next two calls
25 D PKGFILE^BSDPOST,LOG(25) ;update "SD" version in pkg file
26 D PKGFILE^BDGPOST1,LOG(26) ;update "DG" version in pkg file
27 K ^DD(10,0,"SCR") D LOG(27) ;remove file screen from Race file;IHS/ITSC/LJF 1/9/2004
28 D CANCEL^BSDPOST1,LOG(28) ;inactivate SHERI cancellation reason;IHS/ITSC/LJF 4/9/2004
Q
;
LOG(N) ; keep track of where post init is
; Can use this info if restart is needed
S ^BDGX(N)=$$NOW^XLFDT
Q
;
RESTART ; if post init bombs, can be restarted here AFTER problem is fixed
; will start after last log entry
I '$D(U) W !!,"Please set up your user variables!" Q
S Y=$O(^BDGX(999),-1) I Y D @Y
Q
BDGPOST ; IHS/ANMC/LJF - PIMS POSTINIT ; [ 04/09/2004 11:11 AM ]
+1 ;;5.3;PIMS;;APR 26, 2002
+2 ; post init code for ADT data
+3 ;
+4 NEW X
+5 SET X(1)="IHS Postinit: Warning! These may take a long time to run."
+6 SET X(2)="If this process should error out, it can be restarted AFTER"
+7 SET X(3)="the cause of the error has been found and corrected. At that"
+8 SET X(4)="point, go into KIDS and select 'Installation...',then select"
+9 SET X(5)="'Restart Install of Package(s)'."
+10 DO MES^XPDUTL(.X)
+11 ;
+12 ;IHS/ITSC/WAR 8/20/03 - This next call was commented out because of too
+13 ; many past entries. The entries are now created by the new rec.
+14 ; fire new cross-references
+15 ;D AIHSDAM^BSDPOST ;set new AIHSDAM xref
+16 ;
+17 ; copy data to new parameter and table files
1 ;copy scheduling parameters to new file
DO PARAM^BSDPOST1
DO LOG(1)
2 ;copy clinic parameters to new file
DO CLINIC^BSDPOST
DO LOG(2)
3 ;add PIMS to PCC Master Control file
DO PCCLINK^BDGPOST1
DO LOG(3)
4 ;copy ADT parameters to new file
DO PARAM^BDGPOST1
DO LOG(4)
5 ;copy IHS ward items to new file
DO WARD^BDGPOST2
DO LOG(5)
6 ;new observation specialties
DO TRSPEC^BDGPOST1
DO LOG(6)
7 ;copy chart deficiencies to new file
DO CHRTDEF^BDGPOST1
DO LOG(7)
8 ;add non-PIMS items to event driver
DO EVENT^BDGPOST2
DO LOG(8)
9 ;add Appointment Slip letter
DO LETTER^BSDPOST
DO LOG(9)
+1 ;
+2 ; copy patient data to new file structures
10 ;build transfer facility file
DO EN^BDGPOST3
DO LOG(10)
11 ;move fields in file 405
DO DGPM^BDGPOST2
DO LOG(11)
12 ;clean out old SI/DNR data
DO SIDNR^BDGPOST2
DO LOG(12)
13 ;copy Scheduled Visit data to new file
DO SCHVST^BDGPOST2
DO LOG(13)
14 ;copy waiting list to new file
DO WAIT^BSDPOST1
DO LOG(14)
15 ;copy data to new Incomplete Chart file
DO IC^BDGPOST4
DO LOG(15)
+1 ;
16 ;stuff "track all patients in SPT" to NO
IF '$DATA(^BDGX(16))
IF $GET(^DG(43,1,9999999))]""
SET $PIECE(^(9999999),U)=0
DO LOG(16)
+1 ;
+2 ; clean up from last version
17 ;change name of old files
DO OLDFILES^BDGPOST1
DO LOG(17)
18 ;stuff 2 ADT Template entries
DO ADTTMPL^BDGPOST1
DO LOG(18)
19 ;add new fac mov type
DO FACMOV^BDGPOST1
DO LOG(19)
20 ;change Scheduling Merge routine
DO MERG^BSDPOST
DO LOG(20)
+1 ;
+2 ; set up new functions
21 ;set up server side files for PCMM
DO PCMM^BSDPOST1
DO LOG(21)
22 ;set Sched entry for PCC merges
DO POST^BSDLINK
DO LOG(22)
+1 ;IHS/ITSC/WAR 8/20/03 added this next call per the EHR project needs
23 ;index existing recs for EHR visit History
DO ASTOP^BSDPOST
DO LOG(23)
+1 ;IHS/ITSC/LJF 10/10/2003 added call to VA pre-init for patch 526
24 ;adds Resource & Device entries
DO EN^DG53P526
DO LOG(24)
+1 ;IHS/ITSC/WAR 10/17/03 added next two calls
25 ;update "SD" version in pkg file
DO PKGFILE^BSDPOST
DO LOG(25)
26 ;update "DG" version in pkg file
DO PKGFILE^BDGPOST1
DO LOG(26)
27 ;remove file screen from Race file;IHS/ITSC/LJF 1/9/2004
KILL ^DD(10,0,"SCR")
DO LOG(27)
28 ;inactivate SHERI cancellation reason;IHS/ITSC/LJF 4/9/2004
DO CANCEL^BSDPOST1
DO LOG(28)
+1 QUIT
+2 ;
LOG(N) ; keep track of where post init is
+1 ; Can use this info if restart is needed
+2 SET ^BDGX(N)=$$NOW^XLFDT
+3 QUIT
+4 ;
RESTART ; if post init bombs, can be restarted here AFTER problem is fixed
+1 ; will start after last log entry
+2 IF '$DATA(U)
WRITE !!,"Please set up your user variables!"
QUIT
+3 SET Y=$ORDER(^BDGX(999),-1)
IF Y
DO @Y
+4 QUIT