ORY301 ; BP/TC - Pre-install routine for patch OR*3*301 ;09/10/08
;;3.0;ORDER ENTRY/RESULTS REPORTING;**301**;Dec 17, 1997;Build 12
;
PRE ; initiate pre-install process
; this process sets the Anatomic Pathology (AP) results notification
; to Mandatory at the User, Division, & System levels if defined.
;
S (ERADDIV,ERADSYS)=""
D CHG^XPAR("DIV","ORB PROCESSING FLAG","ANATOMIC PATHOLOGY RESULTS","MANDATORY",.ERRDIV)
D CHG^XPAR("SYS","ORB PROCESSING FLAG","ANATOMIC PATHOLOGY RESULTS","MANDATORY",.ERRSYS)
; Parameter instance does not exist, add it.
I $P(ERRDIV,U)="89895008" D ADD^XPAR("DIV","ORB PROCESSING FLAG","ANATOMIC PATHOLOGY RESULTS","MANDATORY",.ERADDIV)
I $P(ERRSYS,U)="89895008" D ADD^XPAR("SYS","ORB PROCESSING FLAG","ANATOMIC PATHOLOGY RESULTS","MANDATORY",.ERADSYS)
I $P(ERRDIV,U)="89895009"!($P(ERRSYS,U)="89895009")!($P(ERADDIV,U)="89895009")!($P(ERADSYS,U)="89895009") D MAIL ; Filing error.
I ERRDIV="" K ERRDIV
I ERRSYS="" K ERRSYS
I ERADDIV="" K ERADDIV
I ERADSYS="" K ERADSYS
N ORPAR,ORENT,ORINST,ORVAL S ORPAR="48",ORENT=0,ORINST=""
F S ORENT=$O(^XTV(8989.5,"AC",ORPAR,ORENT)) Q:ORENT="" D ;DBIA #2686
.I ORENT["VA(200," F S ORINST=$O(^XTV(8989.5,"AC",ORPAR,ORENT,ORINST)) Q:ORINST'>0 D
..S ORVAL=^XTV(8989.5,"AC",ORPAR,ORENT,ORINST) I ORINST="71"&((ORVAL="E")!(ORVAL="D")) D
...N ORPIEN S ORPIEN="",ORPIEN=$O(^XTV(8989.5,"AC",ORPAR,ORENT,ORINST,ORPIEN)) Q:ORPIEN=""
...N DIE,DA,DR S DIE="^XTV(8989.5,",DR="1///M",DA=ORPIEN D ^DIE K DIE,DA,DR
K ORPAR,ORENT,ORINST,ORVAL,ORPIEN
Q
;
MAIL ;
; setup, create, and send a mailman message to the installer
; instructing him/her on how to manually set the AP results
; notfication to Mandatory at the Division/System level in VistA when
; the pre-install process has failed.
N XMSUB,XMTEXT,XMDUZ,XMY,XMZ,XMMG,ORTXT,I
S XMDUZ="PATCH OR*3*301 PRE-INIT" S:$G(DUZ) XMY(DUZ)=""
S I=0,I=I+1,^TMP($J,"ORTXT",I)=""
S I=I+1,^TMP($J,"ORTXT",I)="A filing error has occurred in the process of modifying the ORB PROCESSING FLAG"
S I=I+1,^TMP($J,"ORTXT",I)="parameter and setting the ANATOMIC PATHOLOGY (AP) RESULTS notification to"
S I=I+1,^TMP($J,"ORTXT",I)="MANDATORY at the Division & System levels programmatically.",I=I+1,^TMP($J,"ORTXT",I)=""
S I=I+1,^TMP($J,"ORTXT",I)="Attached are some instructions on how to manually change these parameter settings"
S I=I+1,^TMP($J,"ORTXT",I)="in VistA. Please follow the below instructions to make this change."
S I=I+1,^TMP($J,"ORTXT",I)=""
S I=I+1,^TMP($J,"ORTXT",I)="If the ANATOMIC PATHOLOGY RESULTS instance currently exists for this parameter"
S I=I+1,^TMP($J,"ORTXT",I)="at the Division/System level, please follow these steps to change the value:"
S I=I+1,^TMP($J,"ORTXT",I)=""
S I=I+1,^TMP($J,"ORTXT",I)=" 1)In VistA, access the General Parameter Tools menu [XPAR MENU TOOLS]."
S I=I+1,^TMP($J,"ORTXT",I)=" 2)Select EP, Edit Parameter Values [XPAR EDIT PARAMETER]."
S I=I+1,^TMP($J,"ORTXT",I)=" 3)At the Select PARAMETER DEFINITION NAME: prompt, "
S I=I+1,^TMP($J,"ORTXT",I)=" enter in ORB PROCESSING FLAG."
S I=I+1,^TMP($J,"ORTXT",I)=" 4)At the next prompt, select the Division (DIV)/System (SYS) level setting."
S I=I+1,^TMP($J,"ORTXT",I)=" 5)At the Select Notification: prompt, "
S I=I+1,^TMP($J,"ORTXT",I)=" enter in ANATOMIC PATHOLOGY RESULTS."
S I=I+1,^TMP($J,"ORTXT",I)=" 6)At the next prompt, Notification: ANATOMIC PATHOLOGY RESULTS// hit enter."
S I=I+1,^TMP($J,"ORTXT",I)=" 7)At the next prompt, Value: Enabled// change this value to MANDATORY if it"
S I=I+1,^TMP($J,"ORTXT",I)=" is not already set to so."
S I=I+1,^TMP($J,"ORTXT",I)=""
S I=I+1,^TMP($J,"ORTXT",I)=""
S I=I+1,^TMP($J,"ORTXT",I)="If the ANATOMIC PATHOLOGY RESULTS instance DOES NOT currently exists for this"
S I=I+1,^TMP($J,"ORTXT",I)="parameter at the Division/System level, please follow these steps to add this instance:"
S I=I+1,^TMP($J,"ORTXT",I)=""
S I=I+1,^TMP($J,"ORTXT",I)=" 1)In VistA, access the General Parameter Tools menu [XPAR MENU TOOLS]."
S I=I+1,^TMP($J,"ORTXT",I)=" 2)Select EP, Edit Parameter Values [XPAR EDIT PARAMETER]."
S I=I+1,^TMP($J,"ORTXT",I)=" 3)At the Select PARAMETER DEFINITION NAME: prompt, "
S I=I+1,^TMP($J,"ORTXT",I)=" enter in ORB PROCESSING FLAG."
S I=I+1,^TMP($J,"ORTXT",I)=" 4)At the next prompt, select the Division (DIV)/System (SYS) level setting."
S I=I+1,^TMP($J,"ORTXT",I)=" 5)At the Select Notification: prompt, "
S I=I+1,^TMP($J,"ORTXT",I)=" enter in ANATOMIC PATHOLOGY RESULTS."
S I=I+1,^TMP($J,"ORTXT",I)=" 6)Are you adding ANATOMIC PATHOLOGY RESULTS as a new Notification? Yes//"
S I=I+1,^TMP($J,"ORTXT",I)=" at this prompt, select YES or hit enter."
S I=I+1,^TMP($J,"ORTXT",I)=" 7)At the next prompt, Notification: ANATOMIC PATHOLOGY RESULTS// hit enter."
S I=I+1,^TMP($J,"ORTXT",I)=" 8)At the Value: prompt, enter in MANDATORY."
S I=I+1,^TMP($J,"ORTXT",I)="",XMTEXT="^TMP($J,""ORTXT"",",XMSUB="PATCH OR*3*301 Pre-init FAILED!"
D ^XMD
Q
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HORY301 5057 printed Dec 13, 2024@02:40:50 Page 2
ORY301 ; BP/TC - Pre-install routine for patch OR*3*301 ;09/10/08
+1 ;;3.0;ORDER ENTRY/RESULTS REPORTING;**301**;Dec 17, 1997;Build 12
+2 ;
PRE ; initiate pre-install process
+1 ; this process sets the Anatomic Pathology (AP) results notification
+2 ; to Mandatory at the User, Division, & System levels if defined.
+3 ;
+4 SET (ERADDIV,ERADSYS)=""
+5 DO CHG^XPAR("DIV","ORB PROCESSING FLAG","ANATOMIC PATHOLOGY RESULTS","MANDATORY",.ERRDIV)
+6 DO CHG^XPAR("SYS","ORB PROCESSING FLAG","ANATOMIC PATHOLOGY RESULTS","MANDATORY",.ERRSYS)
+7 ; Parameter instance does not exist, add it.
+8 IF $PIECE(ERRDIV,U)="89895008"
DO ADD^XPAR("DIV","ORB PROCESSING FLAG","ANATOMIC PATHOLOGY RESULTS","MANDATORY",.ERADDIV)
+9 IF $PIECE(ERRSYS,U)="89895008"
DO ADD^XPAR("SYS","ORB PROCESSING FLAG","ANATOMIC PATHOLOGY RESULTS","MANDATORY",.ERADSYS)
+10 ; Filing error.
IF $PIECE(ERRDIV,U)="89895009"!($PIECE(ERRSYS,U)="89895009")!($PIECE(ERADDIV,U)="89895009")!($PIECE(ERADSYS,U)="89895009")
DO MAIL
+11 IF ERRDIV=""
KILL ERRDIV
+12 IF ERRSYS=""
KILL ERRSYS
+13 IF ERADDIV=""
KILL ERADDIV
+14 IF ERADSYS=""
KILL ERADSYS
+15 NEW ORPAR,ORENT,ORINST,ORVAL
SET ORPAR="48"
SET ORENT=0
SET ORINST=""
+16 ;DBIA #2686
FOR
SET ORENT=$ORDER(^XTV(8989.5,"AC",ORPAR,ORENT))
if ORENT=""
QUIT
Begin DoDot:1
+17 IF ORENT["VA(200,"
FOR
SET ORINST=$ORDER(^XTV(8989.5,"AC",ORPAR,ORENT,ORINST))
if ORINST'>0
QUIT
Begin DoDot:2
+18 SET ORVAL=^XTV(8989.5,"AC",ORPAR,ORENT,ORINST)
IF ORINST="71"&((ORVAL="E")!(ORVAL="D"))
Begin DoDot:3
+19 NEW ORPIEN
SET ORPIEN=""
SET ORPIEN=$ORDER(^XTV(8989.5,"AC",ORPAR,ORENT,ORINST,ORPIEN))
if ORPIEN=""
QUIT
+20 NEW DIE,DA,DR
SET DIE="^XTV(8989.5,"
SET DR="1///M"
SET DA=ORPIEN
DO ^DIE
KILL DIE,DA,DR
End DoDot:3
End DoDot:2
End DoDot:1
+21 KILL ORPAR,ORENT,ORINST,ORVAL,ORPIEN
+22 QUIT
+23 ;
MAIL ;
+1 ; setup, create, and send a mailman message to the installer
+2 ; instructing him/her on how to manually set the AP results
+3 ; notfication to Mandatory at the Division/System level in VistA when
+4 ; the pre-install process has failed.
+5 NEW XMSUB,XMTEXT,XMDUZ,XMY,XMZ,XMMG,ORTXT,I
+6 SET XMDUZ="PATCH OR*3*301 PRE-INIT"
if $GET(DUZ)
SET XMY(DUZ)=""
+7 SET I=0
SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=""
+8 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)="A filing error has occurred in the process of modifying the ORB PROCESSING FLAG"
+9 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)="parameter and setting the ANATOMIC PATHOLOGY (AP) RESULTS notification to"
+10 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)="MANDATORY at the Division & System levels programmatically."
SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=""
+11 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)="Attached are some instructions on how to manually change these parameter settings"
+12 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)="in VistA. Please follow the below instructions to make this change."
+13 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=""
+14 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)="If the ANATOMIC PATHOLOGY RESULTS instance currently exists for this parameter"
+15 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)="at the Division/System level, please follow these steps to change the value:"
+16 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=""
+17 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=" 1)In VistA, access the General Parameter Tools menu [XPAR MENU TOOLS]."
+18 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=" 2)Select EP, Edit Parameter Values [XPAR EDIT PARAMETER]."
+19 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=" 3)At the Select PARAMETER DEFINITION NAME: prompt, "
+20 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=" enter in ORB PROCESSING FLAG."
+21 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=" 4)At the next prompt, select the Division (DIV)/System (SYS) level setting."
+22 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=" 5)At the Select Notification: prompt, "
+23 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=" enter in ANATOMIC PATHOLOGY RESULTS."
+24 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=" 6)At the next prompt, Notification: ANATOMIC PATHOLOGY RESULTS// hit enter."
+25 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=" 7)At the next prompt, Value: Enabled// change this value to MANDATORY if it"
+26 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=" is not already set to so."
+27 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=""
+28 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=""
+29 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)="If the ANATOMIC PATHOLOGY RESULTS instance DOES NOT currently exists for this"
+30 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)="parameter at the Division/System level, please follow these steps to add this instance:"
+31 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=""
+32 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=" 1)In VistA, access the General Parameter Tools menu [XPAR MENU TOOLS]."
+33 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=" 2)Select EP, Edit Parameter Values [XPAR EDIT PARAMETER]."
+34 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=" 3)At the Select PARAMETER DEFINITION NAME: prompt, "
+35 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=" enter in ORB PROCESSING FLAG."
+36 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=" 4)At the next prompt, select the Division (DIV)/System (SYS) level setting."
+37 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=" 5)At the Select Notification: prompt, "
+38 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=" enter in ANATOMIC PATHOLOGY RESULTS."
+39 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=" 6)Are you adding ANATOMIC PATHOLOGY RESULTS as a new Notification? Yes//"
+40 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=" at this prompt, select YES or hit enter."
+41 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=" 7)At the next prompt, Notification: ANATOMIC PATHOLOGY RESULTS// hit enter."
+42 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=" 8)At the Value: prompt, enter in MANDATORY."
+43 SET I=I+1
SET ^TMP($JOB,"ORTXT",I)=""
SET XMTEXT="^TMP($J,""ORTXT"","
SET XMSUB="PATCH OR*3*301 Pre-init FAILED!"
+44 DO ^XMD
+45 QUIT