XUS8P788 ;BP/BDT - set locks for options; Aug 02, 2023@06:28:12
;;8.0;KERNEL;**788**;Jul 10, 1995;Build 2
;Per VA Directive 6402, this routine should not be modified.
;Post routine for XU*8*788
Q
;
POST ; Post rouitne for XU*8*788
D SETAUDTS
Q
;
BACKOUT ; backout patch section. This wil be rollback the original data before the patch.
D BACKOUTF
Q
;
SETAUDTS ; set AUDIT for FILES/FIELDS
N XUI S XUI=""
K ^XTMP("XU788 KERNEL PATCH FILES")
F XUI=1:1:100 S XUFILE=$T(FILES+XUI) Q:$P(XUFILE,";;",2)="$$END" D
. D SETAUDT($P(XUFILE,";;",2),$P(XUFILE,";;",3),"y")
. Q
Q
;
SETAUDT(XUFILE,XUFIELD,KFL) ;set Audit for a field
;XUFILE = file number
;XUIELD = field number
;---------------------
N XUI,XUY,XUF S XUI=""
F XUI=1:1:100 S XUF=$P(XUFIELD,";",XUI) Q:XUF="" D
. S ^XTMP("XU788 KERNEL PATCH FILES",$J,XUFILE,XUF)=$G(^DD(XUFILE,XUF,"AUDIT"),"n")
. DO TURNON^DIAUTL(XUFILE,XUF,KFL)
. Q
Q
;
BACKOUTF ; backout Audit fields
N XUI S XUI=""
K ^XTMP("XU788 KERNEL PATCH FILES")
F XUI=1:1:100 S XUFILE=$T(FILES+XUI) Q:$P(XUFILE,";;",2)="$$END" D
. D SETAUDT($P(XUFILE,";;",2),$P(XUFILE,";;",3),"n")
. Q
Q
;
PRINTFLS ;backing up patch data for the listed AUDIT files/fields
N XUI,XUY,XUFILE S XUI=""
F XUI=1:1:100 S XUFILE=$T(FILES+XUI) Q:$P(XUFILE,";;",2)="$$END" D
. D PRINTFL($P(XUFILE,";;",2),$P(XUFILE,";;",3))
Q
;
PRINTFL(XUFILE,XUFIELDS) ;backing up patch data for a AUDIT single file/fields
N XUI,XUY S XUY=""
F XUI=1:1:100 S XUFIELD=$P(XUFIELDS,";",XUI) Q:XUFIELD="" D
. W !,"FILE: ",?8,XUFILE,?15," FIELD :",XUFIELD
. W ?30,"AUDIT SET: ",$G(^DD(XUFILE,XUFIELD,"AUDIT"),"n")
Q
;
FILES ; List files and field to set AUDIT
;;8989.3;;.01;9;9.8;9.81;11;11.2;21;30.1;31.1;31.2;31.3;41;51;202;203;204;205;206;207;209;210;211;214;217;218;219;220;230;320;320.2
;;3.5;;.01;.02;1;3
;;14.7;;.01;2;3;4;5;6;7;8;9;11;12;13;21
;;14.5;;.01;.1;1;2;3;4;5;6;7;8;9;10
;;200;;2;3;7;7.2;9.2;9.4;11;30;31.1;32;51;200.1
;;$$END;;
;
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HXUS8P788 2030 printed Nov 22, 2024@17:22:09 Page 2
XUS8P788 ;BP/BDT - set locks for options; Aug 02, 2023@06:28:12
+1 ;;8.0;KERNEL;**788**;Jul 10, 1995;Build 2
+2 ;Per VA Directive 6402, this routine should not be modified.
+3 ;Post routine for XU*8*788
+4 QUIT
+5 ;
POST ; Post rouitne for XU*8*788
+1 DO SETAUDTS
+2 QUIT
+3 ;
BACKOUT ; backout patch section. This wil be rollback the original data before the patch.
+1 DO BACKOUTF
+2 QUIT
+3 ;
SETAUDTS ; set AUDIT for FILES/FIELDS
+1 NEW XUI
SET XUI=""
+2 KILL ^XTMP("XU788 KERNEL PATCH FILES")
+3 FOR XUI=1:1:100
SET XUFILE=$TEXT(FILES+XUI)
if $PIECE(XUFILE,";;",2)="$$END"
QUIT
Begin DoDot:1
+4 DO SETAUDT($PIECE(XUFILE,";;",2),$PIECE(XUFILE,";;",3),"y")
+5 QUIT
End DoDot:1
+6 QUIT
+7 ;
SETAUDT(XUFILE,XUFIELD,KFL) ;set Audit for a field
+1 ;XUFILE = file number
+2 ;XUIELD = field number
+3 ;---------------------
+4 NEW XUI,XUY,XUF
SET XUI=""
+5 FOR XUI=1:1:100
SET XUF=$PIECE(XUFIELD,";",XUI)
if XUF=""
QUIT
Begin DoDot:1
+6 SET ^XTMP("XU788 KERNEL PATCH FILES",$JOB,XUFILE,XUF)=$GET(^DD(XUFILE,XUF,"AUDIT"),"n")
+7 DO TURNON^DIAUTL(XUFILE,XUF,KFL)
+8 QUIT
End DoDot:1
+9 QUIT
+10 ;
BACKOUTF ; backout Audit fields
+1 NEW XUI
SET XUI=""
+2 KILL ^XTMP("XU788 KERNEL PATCH FILES")
+3 FOR XUI=1:1:100
SET XUFILE=$TEXT(FILES+XUI)
if $PIECE(XUFILE,";;",2)="$$END"
QUIT
Begin DoDot:1
+4 DO SETAUDT($PIECE(XUFILE,";;",2),$PIECE(XUFILE,";;",3),"n")
+5 QUIT
End DoDot:1
+6 QUIT
+7 ;
PRINTFLS ;backing up patch data for the listed AUDIT files/fields
+1 NEW XUI,XUY,XUFILE
SET XUI=""
+2 FOR XUI=1:1:100
SET XUFILE=$TEXT(FILES+XUI)
if $PIECE(XUFILE,";;",2)="$$END"
QUIT
Begin DoDot:1
+3 DO PRINTFL($PIECE(XUFILE,";;",2),$PIECE(XUFILE,";;",3))
End DoDot:1
+4 QUIT
+5 ;
PRINTFL(XUFILE,XUFIELDS) ;backing up patch data for a AUDIT single file/fields
+1 NEW XUI,XUY
SET XUY=""
+2 FOR XUI=1:1:100
SET XUFIELD=$PIECE(XUFIELDS,";",XUI)
if XUFIELD=""
QUIT
Begin DoDot:1
+3 WRITE !,"FILE: ",?8,XUFILE,?15," FIELD :",XUFIELD
+4 WRITE ?30,"AUDIT SET: ",$GET(^DD(XUFILE,XUFIELD,"AUDIT"),"n")
End DoDot:1
+5 QUIT
+6 ;
FILES ; List files and field to set AUDIT
+1 ;;8989.3;;.01;9;9.8;9.81;11;11.2;21;30.1;31.1;31.2;31.3;41;51;202;203;204;205;206;207;209;210;211;214;217;218;219;220;230;320;320.2
+2 ;;3.5;;.01;.02;1;3
+3 ;;14.7;;.01;2;3;4;5;6;7;8;9;11;12;13;21
+4 ;;14.5;;.01;.1;1;2;3;4;5;6;7;8;9;10
+5 ;;200;;2;3;7;7.2;9.2;9.4;11;30;31.1;32;51;200.1
+6 ;;$$END;;
+7 ;