RAIPST15 ;HIRMFO/BNT - Post-init number three (patch twelve) ;5/19/99
VERSION ;;5.0;Radiology/Nuclear Medicine;**12**;Mar 16, 1998
;
EN1 ; *** Adding Event Drivers (HL7 version 2.3) to the Protocol file ***
I '$D(^ORD(101,"B","RA RPT 2.3")) D
. N RA101,RAFDA
. S RAFDA(101,"+1,",.01)="RA RPT 2.3"
. S RAFDA(101,"+1,",1)="Rad/nuc Med report released/verified"
. S RAFDA(101,"+1,",12)=$$PKG^RAIPST12()
. S RAFDA(101,"+1,",4)="event driver"
. S RAFDA(101,"+1,",20)="Q"
. S RAFDA(101,"+1,",770.1)="RA-VOICE-SERVER"
. S RAFDA(101,"+1,",770.3)="ORU"
. S RAFDA(101,"+1,",770.6)=$$PROID^RAIPST12()
. S RAFDA(101,"+1,",772)="Q"
. S RAFDA(101,"+1,",99)=$$TSTMP^RAIPST12()
. S RAFDA(101,"+1,",770.4)="R01"
. D MSG^RAIPST12("RA RPT 2.3",101),UPDATE^DIE("E","RAFDA")
. I $D(^ORD(101,"B","RA RPT 2.3")) D Q
. . S RA101=$O(^ORD(101,"B","RA RPT 2.3",0))
. . K RAFDA S RAFDA(101,RA101_",",770.95)=2.3 D FILE^DIE("E","RAFDA")
. . S ^ORD(101,RA101,1,1,0)="This protocol is triggered whenever a Radiology/Nuclear Medicine report"
. . S ^ORD(101,RA101,1,2,0)="enters into a status of verified or Released/Not Verified. It executes"
. . S ^ORD(101,RA101,1,3,0)="code that creates an HL7 version 2.3 ORU message consisting of PID, OBR"
. . S ^ORD(101,RA101,1,4,0)="and OBX segments. The message contains relevant information about the"
. . S ^ORD(101,RA101,1,5,0)="report, including procedure, procedure modifiers, diagnostic code,"
. . S ^ORD(101,RA101,1,6,0)="interpreting physician, impression text and report text."
. . S ^ORD(101,RA101,1,0)="^^6^6^"_$$DT^XLFDT()_"^^^^"
. . Q
. D MSG^RAIPST12("RA RPT 2.3",101,1)
. Q
I '$D(^ORD(101,"B","RA CANCEL 2.3")) D
. N RA101,RAFDA
. S RAFDA(101,"+1,",.01)="RA CANCEL 2.3"
. S RAFDA(101,"+1,",1)="Rad/Nuc Med exam cancellation"
. S RAFDA(101,"+1,",12)=$$PKG^RAIPST12()
. S RAFDA(101,"+1,",4)="event driver"
. S RAFDA(101,"+1,",20)="Q"
. S RAFDA(101,"+1,",770.1)="RA-VOICE-SERVER"
. S RAFDA(101,"+1,",770.3)="ORM"
. S RAFDA(101,"+1,",770.6)=$$PROID^RAIPST12()
. S RAFDA(101,"+1,",772)="Q"
. S RAFDA(101,"+1,",99)=$$TSTMP^RAIPST12()
. S RAFDA(101,"+1,",770.4)="O01"
. D MSG^RAIPST12("RA CANCEL 2.3",101),UPDATE^DIE("E","RAFDA")
. I $D(^ORD(101,"B","RA CANCEL 2.3")) D Q
. . S RA101=$O(^ORD(101,"B","RA CANCEL 2.3",0))
. . K RAFDA S RAFDA(101,RA101_",",770.95)=2.3 D FILE^DIE("E","RAFDA")
. . S ^ORD(101,RA101,1,1,0)="This protocol is triggered whenever a Radiology/Nuclear Medicine exam is"
. . S ^ORD(101,RA101,1,2,0)="cancelled. It executes code that creates an HL7 version 2.3 ORM message"
. . S ^ORD(101,RA101,1,3,0)="consisting of PID, ORC, and OBX segments. The message contains all"
. . S ^ORD(101,RA101,1,4,0)="relevant information about the exam, including procedure, time of"
. . S ^ORD(101,RA101,1,5,0)="cancellation, procedure modifiers, patient allergies and clinical history."
. . S ^ORD(101,RA101,1,0)="^^5^5^"_$$DT^XLFDT()_"^^"
. . Q
. D MSG^RAIPST12("RA CANCEL 2.3",101,1)
. Q
I '$D(^ORD(101,"B","RA REG 2.3")) D
. N RA101,RAFDA
. S RAFDA(101,"+1,",.01)="RA REG 2.3"
. S RAFDA(101,"+1,",1)="Rad/Nuc Med exam registered for HL7 v2.3 message"
. S RAFDA(101,"+1,",12)=$$PKG^RAIPST12()
. S RAFDA(101,"+1,",4)="event driver"
. S RAFDA(101,"+1,",20)="Q"
. S RAFDA(101,"+1,",770.1)="RA-VOICE-SERVER"
. S RAFDA(101,"+1,",770.3)="ORM"
. S RAFDA(101,"+1,",770.6)=$$PROID^RAIPST12()
. S RAFDA(101,"+1,",772)="Q"
. S RAFDA(101,"+1,",99)=$$TSTMP^RAIPST12()
. S RAFDA(101,"+1,",770.4)="O01"
. D MSG^RAIPST12("RA REG 2.3",101)
. D UPDATE^DIE("E","RAFDA")
. I $D(^ORD(101,"B","RA REG 2.3")) D Q
. . S RA101=$O(^ORD(101,"B","RA REG 2.3",0))
. . K RAFDA S RAFDA(101,RA101_",",770.95)=2.3 D FILE^DIE("E","RAFDA")
. . S ^ORD(101,RA101,1,1,0)="This protocol is triggered whenever a Radiology/Nuclear Medicine exam is"
. . S ^ORD(101,RA101,1,2,0)="registered. It executes code that creates an HL7 ORM version 2.3 message"
. . S ^ORD(101,RA101,1,3,0)="consisting of PID, ORC, OBR, and OBX segments. The message containes all"
. . S ^ORD(101,RA101,1,4,0)="relevant information about the exam, including procedure, time of"
. . S ^ORD(101,RA101,1,5,0)="registration, procedure modifiers, patient allergies, and clinical"
. . S ^ORD(101,RA101,1,6,0)="history."
. . S ^ORD(101,RA101,1,0)="^^6^6^"_$$DT^XLFDT()_"^^"
. . Q
. D MSG^RAIPST12("RA REG 2.3",101,1)
. Q
I '$D(^ORD(101,"B","RA EXAMINED 2.3")) D
. N RA101,RAFDA
. S RAFDA(101,"+1,",.01)="RA EXAMINED 2.3"
. S RAFDA(101,"+1,",1)="Rad/Nuc Med examined case"
. S RAFDA(101,"+1,",12)=$$PKG^RAIPST12()
. S RAFDA(101,"+1,",4)="event driver"
. S RAFDA(101,"+1,",20)="Q"
. S RAFDA(101,"+1,",770.1)="RA-VOICE-SERVER"
. S RAFDA(101,"+1,",770.3)="ORM"
. S RAFDA(101,"+1,",770.6)=$$PROID^RAIPST12()
. S RAFDA(101,"+1,",772)="Q"
. S RAFDA(101,"+1,",99)=$$TSTMP^RAIPST12()
. S RAFDA(101,"+1,",770.4)="O01"
. D MSG^RAIPST12("RA EXAMINED 2.3",101),UPDATE^DIE("E","RAFDA")
. I $D(^ORD(101,"B","RA EXAMINED 2.3")) D Q
. . S RA101=$O(^ORD(101,"B","RA EXAMINED 2.3",0))
. . K RAFDA S RAFDA(101,RA101_",",770.95)=2.3 D FILE^DIE("E","RAFDA")
. . S ^ORD(101,RA101,1,1,0)="This protocol is triggered whenever a Radiology/Nuclear Medicine exam has"
. . S ^ORD(101,RA101,1,2,0)="reached a status where GENERATE EXAMINED HL7 MSG is Y at that (or at a"
. . S ^ORD(101,RA101,1,3,0)="lower) status. An HL7 version 2.3 ORM message will be generated that"
. . S ^ORD(101,RA101,1,4,0)="contains all relevant information about the exam, including procedure,"
. . S ^ORD(101,RA101,1,5,0)="time of registration, procedure modifiers, patient allergies, and clinical"
. . S ^ORD(101,RA101,1,6,0)="history."
. . S ^ORD(101,RA101,1,0)="^^6^6^"_$$DT^XLFDT()_"^^"
. . Q
. D MSG^RAIPST12("RA EXAMINED 2.3",101,1)
. Q
Q
RAIPST15 ;HIRMFO/BNT - Post-init number three (patch twelve) ;5/19/99
VERSION ;;5.0;Radiology/Nuclear Medicine;**12**;Mar 16, 1998
+1 ;
EN1 ; *** Adding Event Drivers (HL7 version 2.3) to the Protocol file ***
+1 IF '$DATA(^ORD(101,"B","RA RPT 2.3"))
Begin DoDot:1
+2 NEW RA101,RAFDA
+3 SET RAFDA(101,"+1,",.01)="RA RPT 2.3"
+4 SET RAFDA(101,"+1,",1)="Rad/nuc Med report released/verified"
+5 SET RAFDA(101,"+1,",12)=$$PKG^RAIPST12()
+6 SET RAFDA(101,"+1,",4)="event driver"
+7 SET RAFDA(101,"+1,",20)="Q"
+8 SET RAFDA(101,"+1,",770.1)="RA-VOICE-SERVER"
+9 SET RAFDA(101,"+1,",770.3)="ORU"
+10 SET RAFDA(101,"+1,",770.6)=$$PROID^RAIPST12()
+11 SET RAFDA(101,"+1,",772)="Q"
+12 SET RAFDA(101,"+1,",99)=$$TSTMP^RAIPST12()
+13 SET RAFDA(101,"+1,",770.4)="R01"
+14 DO MSG^RAIPST12("RA RPT 2.3",101)
DO UPDATE^DIE("E","RAFDA")
+15 IF $DATA(^ORD(101,"B","RA RPT 2.3"))
Begin DoDot:2
+16 SET RA101=$ORDER(^ORD(101,"B","RA RPT 2.3",0))
+17 KILL RAFDA
SET RAFDA(101,RA101_",",770.95)=2.3
DO FILE^DIE("E","RAFDA")
+18 SET ^ORD(101,RA101,1,1,0)="This protocol is triggered whenever a Radiology/Nuclear Medicine report"
+19 SET ^ORD(101,RA101,1,2,0)="enters into a status of verified or Released/Not Verified. It executes"
+20 SET ^ORD(101,RA101,1,3,0)="code that creates an HL7 version 2.3 ORU message consisting of PID, OBR"
+21 SET ^ORD(101,RA101,1,4,0)="and OBX segments. The message contains relevant information about the"
+22 SET ^ORD(101,RA101,1,5,0)="report, including procedure, procedure modifiers, diagnostic code,"
+23 SET ^ORD(101,RA101,1,6,0)="interpreting physician, impression text and report text."
+24 SET ^ORD(101,RA101,1,0)="^^6^6^"_$$DT^XLFDT()_"^^^^"
+25 QUIT
End DoDot:2
QUIT
+26 DO MSG^RAIPST12("RA RPT 2.3",101,1)
+27 QUIT
End DoDot:1
+28 IF '$DATA(^ORD(101,"B","RA CANCEL 2.3"))
Begin DoDot:1
+29 NEW RA101,RAFDA
+30 SET RAFDA(101,"+1,",.01)="RA CANCEL 2.3"
+31 SET RAFDA(101,"+1,",1)="Rad/Nuc Med exam cancellation"
+32 SET RAFDA(101,"+1,",12)=$$PKG^RAIPST12()
+33 SET RAFDA(101,"+1,",4)="event driver"
+34 SET RAFDA(101,"+1,",20)="Q"
+35 SET RAFDA(101,"+1,",770.1)="RA-VOICE-SERVER"
+36 SET RAFDA(101,"+1,",770.3)="ORM"
+37 SET RAFDA(101,"+1,",770.6)=$$PROID^RAIPST12()
+38 SET RAFDA(101,"+1,",772)="Q"
+39 SET RAFDA(101,"+1,",99)=$$TSTMP^RAIPST12()
+40 SET RAFDA(101,"+1,",770.4)="O01"
+41 DO MSG^RAIPST12("RA CANCEL 2.3",101)
DO UPDATE^DIE("E","RAFDA")
+42 IF $DATA(^ORD(101,"B","RA CANCEL 2.3"))
Begin DoDot:2
+43 SET RA101=$ORDER(^ORD(101,"B","RA CANCEL 2.3",0))
+44 KILL RAFDA
SET RAFDA(101,RA101_",",770.95)=2.3
DO FILE^DIE("E","RAFDA")
+45 SET ^ORD(101,RA101,1,1,0)="This protocol is triggered whenever a Radiology/Nuclear Medicine exam is"
+46 SET ^ORD(101,RA101,1,2,0)="cancelled. It executes code that creates an HL7 version 2.3 ORM message"
+47 SET ^ORD(101,RA101,1,3,0)="consisting of PID, ORC, and OBX segments. The message contains all"
+48 SET ^ORD(101,RA101,1,4,0)="relevant information about the exam, including procedure, time of"
+49 SET ^ORD(101,RA101,1,5,0)="cancellation, procedure modifiers, patient allergies and clinical history."
+50 SET ^ORD(101,RA101,1,0)="^^5^5^"_$$DT^XLFDT()_"^^"
+51 QUIT
End DoDot:2
QUIT
+52 DO MSG^RAIPST12("RA CANCEL 2.3",101,1)
+53 QUIT
End DoDot:1
+54 IF '$DATA(^ORD(101,"B","RA REG 2.3"))
Begin DoDot:1
+55 NEW RA101,RAFDA
+56 SET RAFDA(101,"+1,",.01)="RA REG 2.3"
+57 SET RAFDA(101,"+1,",1)="Rad/Nuc Med exam registered for HL7 v2.3 message"
+58 SET RAFDA(101,"+1,",12)=$$PKG^RAIPST12()
+59 SET RAFDA(101,"+1,",4)="event driver"
+60 SET RAFDA(101,"+1,",20)="Q"
+61 SET RAFDA(101,"+1,",770.1)="RA-VOICE-SERVER"
+62 SET RAFDA(101,"+1,",770.3)="ORM"
+63 SET RAFDA(101,"+1,",770.6)=$$PROID^RAIPST12()
+64 SET RAFDA(101,"+1,",772)="Q"
+65 SET RAFDA(101,"+1,",99)=$$TSTMP^RAIPST12()
+66 SET RAFDA(101,"+1,",770.4)="O01"
+67 DO MSG^RAIPST12("RA REG 2.3",101)
+68 DO UPDATE^DIE("E","RAFDA")
+69 IF $DATA(^ORD(101,"B","RA REG 2.3"))
Begin DoDot:2
+70 SET RA101=$ORDER(^ORD(101,"B","RA REG 2.3",0))
+71 KILL RAFDA
SET RAFDA(101,RA101_",",770.95)=2.3
DO FILE^DIE("E","RAFDA")
+72 SET ^ORD(101,RA101,1,1,0)="This protocol is triggered whenever a Radiology/Nuclear Medicine exam is"
+73 SET ^ORD(101,RA101,1,2,0)="registered. It executes code that creates an HL7 ORM version 2.3 message"
+74 SET ^ORD(101,RA101,1,3,0)="consisting of PID, ORC, OBR, and OBX segments. The message containes all"
+75 SET ^ORD(101,RA101,1,4,0)="relevant information about the exam, including procedure, time of"
+76 SET ^ORD(101,RA101,1,5,0)="registration, procedure modifiers, patient allergies, and clinical"
+77 SET ^ORD(101,RA101,1,6,0)="history."
+78 SET ^ORD(101,RA101,1,0)="^^6^6^"_$$DT^XLFDT()_"^^"
+79 QUIT
End DoDot:2
QUIT
+80 DO MSG^RAIPST12("RA REG 2.3",101,1)
+81 QUIT
End DoDot:1
+82 IF '$DATA(^ORD(101,"B","RA EXAMINED 2.3"))
Begin DoDot:1
+83 NEW RA101,RAFDA
+84 SET RAFDA(101,"+1,",.01)="RA EXAMINED 2.3"
+85 SET RAFDA(101,"+1,",1)="Rad/Nuc Med examined case"
+86 SET RAFDA(101,"+1,",12)=$$PKG^RAIPST12()
+87 SET RAFDA(101,"+1,",4)="event driver"
+88 SET RAFDA(101,"+1,",20)="Q"
+89 SET RAFDA(101,"+1,",770.1)="RA-VOICE-SERVER"
+90 SET RAFDA(101,"+1,",770.3)="ORM"
+91 SET RAFDA(101,"+1,",770.6)=$$PROID^RAIPST12()
+92 SET RAFDA(101,"+1,",772)="Q"
+93 SET RAFDA(101,"+1,",99)=$$TSTMP^RAIPST12()
+94 SET RAFDA(101,"+1,",770.4)="O01"
+95 DO MSG^RAIPST12("RA EXAMINED 2.3",101)
DO UPDATE^DIE("E","RAFDA")
+96 IF $DATA(^ORD(101,"B","RA EXAMINED 2.3"))
Begin DoDot:2
+97 SET RA101=$ORDER(^ORD(101,"B","RA EXAMINED 2.3",0))
+98 KILL RAFDA
SET RAFDA(101,RA101_",",770.95)=2.3
DO FILE^DIE("E","RAFDA")
+99 SET ^ORD(101,RA101,1,1,0)="This protocol is triggered whenever a Radiology/Nuclear Medicine exam has"
+100 SET ^ORD(101,RA101,1,2,0)="reached a status where GENERATE EXAMINED HL7 MSG is Y at that (or at a"
+101 SET ^ORD(101,RA101,1,3,0)="lower) status. An HL7 version 2.3 ORM message will be generated that"
+102 SET ^ORD(101,RA101,1,4,0)="contains all relevant information about the exam, including procedure,"
+103 SET ^ORD(101,RA101,1,5,0)="time of registration, procedure modifiers, patient allergies, and clinical"
+104 SET ^ORD(101,RA101,1,6,0)="history."
+105 SET ^ORD(101,RA101,1,0)="^^6^6^"_$$DT^XLFDT()_"^^"
+106 QUIT
End DoDot:2
QUIT
+107 DO MSG^RAIPST12("RA EXAMINED 2.3",101,1)
+108 QUIT
End DoDot:1
+109 QUIT