source: WorldVistAEHR/trunk/r/KERNEL-XU-A4A7-USC-XG-XLF-XNOA-XPD-XQ-XVIR-ZI-ZOSF-ZOSV-ZT-ZU-%Z-XIP--XQAB--XUC--XUR--ZIN--ZTED/XPDZPAT.m@ 1806

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

initial load of WorldVistAEHR

File size: 4.2 KB
Line 
1XPDZPAT ;FGO/JHS;Simple Patch Procedure ; 12/2/05 7:21pm
2 ;;8.0;KERNEL;**L33**;Jul 10, 1995
3 D UCI^%ZOSV S AAQU=$P(Y,",",1) W !!,"Simple Patch/Package Installation - "_AAQU_" - " S X=$$NOW^XLFDT S AAQDT=$$FMTE^XLFDT(X) W AAQDT
4 W !!,"NOTE: Do not use this option for installs which require Logins Inhibited.",!,?7,"Instead, use AAQMENU from programmer mode with Simple Patch option."
5 W !!,?7,"You can finish an install using the options under",!,?7,"the KIDS Installation Menu if it terminates abnormally,",!,?7,"or you want to interrupt the process to run other options."
6 S (AAQBAK,AAQCALL,AAQFTP,AAQSEQ,AAQXMZ)=0,AAQINST=1,AAQP=""
7 G ENPAT^XPDZPRE
8CHKRL G:AAQRL="L" ASKCHK
9 G INCK
10ASKCHK ; Load a Distribution
11 G:^%ZOSF("OS")'["OpenM-NT" LOAD S %=1 R !!,"==> Do you want to check your Download Directory for the file" D YN^DICN G:$D(DTOUT) EXIT G:%=2 LOAD I %=0 W !!,"Answer YES for a quick lookup of the file with an optional rename."
12 G:%Y="^" EXIT
13 I %=1 D ^AAQFILE G:AAQFN="" EXIT G LOAD
14 G ASKCHK
15LOAD W ! D EN1^XPDIL G:$D(DUOUT)!$D(DTOUT) EXIT G PRE
16INCK S XMR=^XMB(3.9,AAQXMZ,0),XMP2="I" D MM^XMP2 S XCF=2 D ENH^XMP2A
17PRE ; Pre-Install Checksums
18 W !!,"==> Pre-Install Checksums will run now."
19 K ^DISV(DUZ,"^XPD(9.7,") ;Prevent selection with spacebar-return
20 S AAQUCI=AAQU D TRN^XPDZCHK G:$D(DUOUT)!$D(DTOUT) EXIT
21 G:$D(AAQPAT) SPAT W $C(7),!!,"A Patch INSTALL NAME was not selected."
22SPAT S AAQP=AAQPAT
23VER ; Verify Checksums in Transport Global
24 W !!,"==> KIDS Verify Checksums option will run now."
25 S AAQUCI=AAQU,D0=AAQD0,Y="PNT^XPDZVER(9.7)" D ENBAT^XPDZVER
26BAK ; Backup a Transport Global
27 W !,"==> KIDS Backup will run now.",!
28 S AAQUCI=AAQU D ^XPDZIB G:$D(DUOUT)!$D(DTOUT) EXIT
29 ; Install Package
30 W !,"==> KIDS Install option will run now.",!
31 S XPDIDVT=0 ;Disable Graphical Progress Bar for clean screen capture
32 D EN^XPDI G:$D(DUOUT)!$D(DTOUT) EXIT
33CHKQ ; Check for queued or not installed
34 I '$D(^XPD(9.6,"B",AAQP)) W !!,"The KIDS Build "_AAQP_" has not been installed or has been queued.",!,"Remember to run the Post-Install Checksums after installation." G CHKDEL
35POST ; Post-Install Checksums
36 W !!,"==> Post-Install Checksums will run now."
37 S D0=0,D0=$O(^XPD(9.6,"B",AAQP,D0)) S AAQD0=D0,AAQPAT=AAQP D ENBLD^XPDZCHK
38CHKDEL ; Alpha/OpenM-NT, Delete KIDS file from Download Directory
39 I AAQRL="L",^%ZOSF("OS")["OpenM-NT" W !,"==> The KIDS file can be deleted from your Download Directory now." D ^AAQFILE
40REM W !!,"==> REMINDER: Check the Patch Description for Post-Install procedures."
41 W !,"Simple Patch Installation Finished - "_AAQU_" - " S X=$$NOW^XLFDT W $$FMTE^XLFDT(X),!
42 G:'$D(^VA(200,"B","PATCHES,ALL D")) CKUPDT
43 G:'$D(XMZ) CKUPDT
44 S XMY("PATCHES,ALL D")="" D ENT1^XMD
45 W !,"Forwarding message #"_XMZ_" to PATCHES,ALL D.",!
46CKUPDT ;;I $D(^DIZ(437016,0)),AAQU="VAH" D ^XPDZUPDT
47 I $D(^DIZ(437016,0)),AAQU="EHR" D ^XPDZUPDT
48 ; Checking the Status of TaskMan
49 ; Code is current as of XU*8*137 SEQ #123
50 I $D(^%ZTSCH("WAIT")) W $C(7),!!,"Taskman has been Placed In a Wait State." G ASKREM
51 G CKSTOP
52ASKREM S %=1 R !!,"Do you want to 'Remove Taskman from WAIT State'" D YN^DICN G:$D(DTOUT) CKSTOP D:%=1 RUN^ZTMKU I %=0 W !!,"Answer NO to leave Taskman in same status for another patch." G ASKREM
53 G:%Y="^" CKSTOP
54 I %=-1 W $C(7) G ASKREM
55CKSTOP I $D(^%ZTSCH("STOP","MGR")) W $C(7),!!,"Taskman has been Stopped." G ASKRES
56 G ASKRET
57ASKRES S %=1 R !!,"Do you want to 'Restart Task Manager'" D YN^DICN G:$D(DTOUT) ASKRET D:%=1 RESTART^ZTMB I %=0 W !!,"Answer NO to leave Taskman in same status for another patch." G ASKRES
58 G:%Y="^" ASKRET
59 I %=-1 W $C(7) G ASKRES
60ASKRET R !,"Press RETURN to Continue:",X:DTIME
61EXIT W @IOF K AAQBAK,AAQBX,AAQD0,AAQFILE,AAQFN,AAQFTP,AAQINST,AAQLN2,AAQLN3,AAQP,AAQP1,AAQP2,AAQP3,AAQPAT,AAQPX,AAQPRE,AAQRL,AAQROU,AAQSEQ,AAQSUB,AAQU,AAQUCI,AAQX1,AAQX12,AAQX2,AAQX3,AAQXM,AAQXMZ,POP,Z
62 ;AAQFILE and AAQFN set in AAQFILE, AAQROU set in XPDZIB, DTOUT and DUOUT killed by EXPRE
63 D EXPRE K ^TMP($J),^UTILITY($J),%,%Y,%Z,%ZO,DA,DIE,DIF,D0,DDH,DIC,I,T,X,XCF,XCN,XMDISPI,XMDUZ,XMP2,XMR,XMZ,XPD,XPDIDVT,XQM,Y Q
64EXPRE K AAQAERR,AAQAP,AAQAP1,AAQAP2,AAQAP3,AAQCALL,AAQCOM,AAQCONT,AAQDL,AAQDLX,AAQDT,AAQDUZ,AAQIERR,AAQIN,AAQINDT,AAQIRM
65 K AAQLINE,AAQPKG,AAQPNO,AAQPNSV,AAQPV,AAQSERR,AAQSQ,AAQSQSV,AAQSYS,AAQSYSX,AAQTOT,AAQTXT,AAQTYP,AAQVERR,AAQX,AAQZN,DATE,DTOUT,DUOUT,IFN,K,RV0,RV1,VERSION Q
Note: See TracBrowser for help on using the repository browser.