GMRAIVDK ;BPOIFO/JG - KIDS POST INSTALL FOR VDEF PATCH ;10/5/04 08:57
;;4.0;ADVERSE REACTION TRACKING;**22,23**;Mar 29, 1996
;
; This routine uses the following IAs:
; #4447 - POSTKID^VDEF (controlled)
; #10141 - XPDUTL calls (controlled)
;
; This program is used as the KIDS Post-Install routine
; for the second VDEF patch that installs GMRA application
; specific components that are required by VDEF to construct
; a message.
;
POSTKID ; Entry point
; Inputs that are required by POSTKID^VDEFVU:
; MSGTYP - HL7 message type (ADT, ORU, etc)
; EVNTYP - HL7 event type (A60, R01, etc)
; SUBTYP - VDEF Event Subtype (ALGY, PPAR, etc)
; PROTO - VistA HL7 Event Driver Protocol Name
; CUSTPKG - Custodial Package Name
; EXTROUT - VDEF Message Extraction Program
; EVDESC - Event description
; SUBDESC - Subtype description
;
; If needed, POSTKID^VDEFVU will generate error message (BMES^XPDUTL)
; and set GMRABORT=1
;
K XPDABORT
I $G(XPDNM)="" D BMES^XPDUTL("Must be run as a KIDS Post-Install process.") S XPDABORT=1 Q
N MSGTYP,EVNTYP,SUBTYP,PROTO,CUSTPKG,EXTROUT,EVDESC,SUBDESC,ERRMSG,GMRABORT
;
; Create Allergy Update/Insert Event
S MSGTYP="ORU"
S EVNTYP="R01"
S SUBTYP="ALGY"
S PROTO="GMRA VDEF ORU R01 ALLERGY VS"
S CUSTPKG="ADVERSE REACTION TRACKING"
S EXTROUT="GMRAIAL1"
S EVDESC="ALLERGY UPDATE/INSERT"
S SUBDESC="ALLERGY UPDATE/INSERT"
D POSTKID^VDEFVU(MSGTYP,EVNTYP,SUBTYP,PROTO,CUSTPKG,EXTROUT,EVDESC,SUBDESC,.GMRABORT)
Q:$G(GMRABORT)
;
; Create Allergy Assessment Event
S SUBTYP="ADAS"
S PROTO="GMRA VDEF ORU R01 ADV ASSESS VS"
S EVDESC="ALLERGY ASSESSMENT"
S SUBDESC="ALLERGY ASSESSMENT"
D POSTKID^VDEFVU(MSGTYP,EVNTYP,SUBTYP,PROTO,CUSTPKG,EXTROUT,EVDESC,SUBDESC,.GMRABORT)
Q:$G(GMRABORT)
;
; Create Adverse Reaction Report Event
S SUBTYP="ADRA"
S PROTO="GMRA VDEF ORU R01 ADV REACT VS"
S EXTROUT="GMRAIAD1"
S EVDESC="ADVERSE REACTION REPORT"
S SUBDESC="ADVERSE REACTION"
D POSTKID^VDEFVU(MSGTYP,EVNTYP,SUBTYP,PROTO,CUSTPKG,EXTROUT,EVDESC,SUBDESC,.GMRABORT)
Q:$G(GMRABORT)
;
; Success!!
D BMES^XPDUTL("VDEF Event(s) successfully installed in VDEF globals.")
Q
GMRAIVDK ;BPOIFO/JG - KIDS POST INSTALL FOR VDEF PATCH ;10/5/04 08:57
+1 ;;4.0;ADVERSE REACTION TRACKING;**22,23**;Mar 29, 1996
+2 ;
+3 ; This routine uses the following IAs:
+4 ; #4447 - POSTKID^VDEF (controlled)
+5 ; #10141 - XPDUTL calls (controlled)
+6 ;
+7 ; This program is used as the KIDS Post-Install routine
+8 ; for the second VDEF patch that installs GMRA application
+9 ; specific components that are required by VDEF to construct
+10 ; a message.
+11 ;
POSTKID ; Entry point
+1 ; Inputs that are required by POSTKID^VDEFVU:
+2 ; MSGTYP - HL7 message type (ADT, ORU, etc)
+3 ; EVNTYP - HL7 event type (A60, R01, etc)
+4 ; SUBTYP - VDEF Event Subtype (ALGY, PPAR, etc)
+5 ; PROTO - VistA HL7 Event Driver Protocol Name
+6 ; CUSTPKG - Custodial Package Name
+7 ; EXTROUT - VDEF Message Extraction Program
+8 ; EVDESC - Event description
+9 ; SUBDESC - Subtype description
+10 ;
+11 ; If needed, POSTKID^VDEFVU will generate error message (BMES^XPDUTL)
+12 ; and set GMRABORT=1
+13 ;
+14 KILL XPDABORT
+15 IF $GET(XPDNM)=""
DO BMES^XPDUTL("Must be run as a KIDS Post-Install process.")
SET XPDABORT=1
QUIT
+16 NEW MSGTYP,EVNTYP,SUBTYP,PROTO,CUSTPKG,EXTROUT,EVDESC,SUBDESC,ERRMSG,GMRABORT
+17 ;
+18 ; Create Allergy Update/Insert Event
+19 SET MSGTYP="ORU"
+20 SET EVNTYP="R01"
+21 SET SUBTYP="ALGY"
+22 SET PROTO="GMRA VDEF ORU R01 ALLERGY VS"
+23 SET CUSTPKG="ADVERSE REACTION TRACKING"
+24 SET EXTROUT="GMRAIAL1"
+25 SET EVDESC="ALLERGY UPDATE/INSERT"
+26 SET SUBDESC="ALLERGY UPDATE/INSERT"
+27 DO POSTKID^VDEFVU(MSGTYP,EVNTYP,SUBTYP,PROTO,CUSTPKG,EXTROUT,EVDESC,SUBDESC,.GMRABORT)
+28 IF $GET(GMRABORT)
QUIT
+29 ;
+30 ; Create Allergy Assessment Event
+31 SET SUBTYP="ADAS"
+32 SET PROTO="GMRA VDEF ORU R01 ADV ASSESS VS"
+33 SET EVDESC="ALLERGY ASSESSMENT"
+34 SET SUBDESC="ALLERGY ASSESSMENT"
+35 DO POSTKID^VDEFVU(MSGTYP,EVNTYP,SUBTYP,PROTO,CUSTPKG,EXTROUT,EVDESC,SUBDESC,.GMRABORT)
+36 IF $GET(GMRABORT)
QUIT
+37 ;
+38 ; Create Adverse Reaction Report Event
+39 SET SUBTYP="ADRA"
+40 SET PROTO="GMRA VDEF ORU R01 ADV REACT VS"
+41 SET EXTROUT="GMRAIAD1"
+42 SET EVDESC="ADVERSE REACTION REPORT"
+43 SET SUBDESC="ADVERSE REACTION"
+44 DO POSTKID^VDEFVU(MSGTYP,EVNTYP,SUBTYP,PROTO,CUSTPKG,EXTROUT,EVDESC,SUBDESC,.GMRABORT)
+45 IF $GET(GMRABORT)
QUIT
+46 ;
+47 ; Success!!
+48 DO BMES^XPDUTL("VDEF Event(s) successfully installed in VDEF globals.")
+49 QUIT