[613] | 1 | QANUTL5 ;HISC/GJC-Utilities for Incident Reporting (Incident Status) ;10/6/92
|
---|
| 2 | ;;2.0;Incident Reporting;**1,10,18,26**;08/07/1992
|
---|
| 3 | ;
|
---|
| 4 | BDCAST ;Required message broadcast.
|
---|
| 5 | S MSSG0="W !?10,""This incident requires immediate phone notification to the VISN."""
|
---|
| 6 | S MSSG1="W !?10,""This incident requires E-MAIL to the VISN."""
|
---|
| 7 | S MSSG2="W !?10,""This incident requires further investigation."""
|
---|
| 8 | S MSSG3="W !?10,""This incident requires a Mortality and Morbidity (M&M) report."""
|
---|
| 9 | S MSSG4="W !?10,""This incident requires Psychological Autopsy."""
|
---|
| 10 | S QANGLB1=$S($D(^QA(742,QANDFN,0))#2:^(0),1:""),QANGLB2=$S($D(^QA(742.4,QANIEN,0))#2:^(0),1:"") Q:QANGLB1']""!(QANGLB2']"")
|
---|
| 11 | S INCQAN("SUICIDE")=$O(^QA(742.1,"BUPPER","SUICIDE",0))
|
---|
| 12 | S INCQAN("SUICIDE ATTEMPT")=$O(^QA(742.1,"BUPPER","SUICIDE ATTEMPT",0))
|
---|
| 13 | S INCQAN("SEXUAL ASSAULT")=$O(^QA(742.1,"BUPPER","SEXUAL ASSAULT",0))
|
---|
| 14 | S INCQAN("HOMICIDE")=$O(^QA(742.1,"BUPPER","HOMICIDE",0))
|
---|
| 15 | S INCQAN("PATIENT ABUSE")=$O(^QA(742.1,"BUPPER","PATIENT ABUSE",0))
|
---|
| 16 | S INCQAN("FALL")=$O(^QA(742.1,"BUPPER","FALL",0))
|
---|
| 17 | S INCQAN("TRANSFUSION ERROR")=$O(^QA(742.1,"BUPPER","TRANSFUSION ERROR",0))
|
---|
| 18 | S INCQAN("MEDICATION ERROR")=$O(^QA(742.1,"BUPPER","MEDICATION ERROR",0))
|
---|
| 19 | S INCQAN("INJURY NOT OTHERWISE LISTED")=$O(^QA(742.1,"BUPPER","INJURY NOT OTHERWISE LISTED",0))
|
---|
| 20 | S INCQAN("FIRE-PATIENT INVOLVED IN")=$O(^QA(742.1,"BUPPER","FIRE-PATIENT INVOLVED IN",0))
|
---|
| 21 | S INCQAN("ASSAULT-PATIENT TO PATIENT")=$O(^QA(742.1,"BUPPER","ASSAULT-PATIENT TO PATIENT",0))
|
---|
| 22 | S INCQAN("ASSAULT-PATIENT/STAFF")=$O(^QA(742.1,"BUPPER","ASSAULT-PATIENT/STAFF",0))
|
---|
| 23 | S INCQAN("DEATH")=$O(^QA(742.1,"BUPPER","DEATH",0))
|
---|
| 24 | S INCQAN("MISSING PATIENT")=$O(^QA(742.1,"BUPPER","MISSING PATIENT",0))
|
---|
| 25 | S INCQAN("INFORMED CONSENT-FAIL. TO OBTAIN")=$O(^QA(742.1,"BUPPER","INFORMED CONSENT-FAIL. TO OBTAIN",0))
|
---|
| 26 | I $P(QANGLB2,U,2)=INCQAN("DEATH") D DEATH^QANUTL Q
|
---|
| 27 | I $P(QANGLB2,U,2)=INCQAN("SUICIDE") X MSSG0,MSSG1,MSSG4
|
---|
| 28 | I $P(QANGLB2,U,2)=INCQAN("SUICIDE ATTEMPT"),("01"[$P(QANGLB1,U,10)) X MSSG1,MSSG3
|
---|
| 29 | I $P(QANGLB2,U,2)=INCQAN("SUICIDE ATTEMPT"),($P(QANGLB1,U,10)["2") X MSSG0,MSSG1,MSSG3
|
---|
| 30 | I $P(QANGLB2,U,2)=INCQAN("PATIENT ABUSE") D ABUSE^QANUTL Q
|
---|
| 31 | I $P(QANGLB2,U,2)=INCQAN("INFORMED CONSENT-FAIL. TO OBTAIN") X MSSG1
|
---|
| 32 | I $P(QANGLB2,U,2)=INCQAN("FALL"),($P(QANGLB1,U,10)["2") X MSSG1
|
---|
| 33 | I $P(QANGLB2,U,2)=INCQAN("FALL"),($P(QANGLB1,U,10)["3") X MSSG0,MSSG1,MSSG2
|
---|
| 34 | I $P(QANGLB2,U,2)=INCQAN("HOMICIDE") X MSSG0,MSSG1,MSSG2
|
---|
| 35 | I $P(QANGLB2,U,2)=INCQAN("MEDICATION ERROR"),($P(QANGLB1,U,10)["2") X MSSG1,MSSG2
|
---|
| 36 | I $P(QANGLB2,U,2)=INCQAN("MEDICATION ERROR"),($P(QANGLB1,U,10)["3") X MSSG0,MSSG1,MSSG2
|
---|
| 37 | I $P(QANGLB2,U,2)=INCQAN("MISSING PATIENT"),($P(QANGLB1,U,10)["2") X MSSG1,MSSG2
|
---|
| 38 | I $P(QANGLB2,U,2)=INCQAN("MISSING PATIENT"),($P(QANGLB1,U,10)["3") X MSSG0,MSSG1,MSSG2
|
---|
| 39 | I $P(QANGLB2,U,2)=INCQAN("ASSAULT-PATIENT/STAFF"),($P(QANGLB1,U,10)["2") X MSSG1,MSSG2
|
---|
| 40 | I $P(QANGLB2,U,2)=INCQAN("ASSAULT-PATIENT/STAFF"),($P(QANGLB1,U,10)["3") X MSSG0,MSSG1,MSSG2
|
---|
| 41 | I $P(QANGLB2,U,2)=INCQAN("ASSAULT-PATIENT TO PATIENT"),("23"[$P(QANGLB1,U,10)) X MSSG0,MSSG1,MSSG2
|
---|
| 42 | I $P(QANGLB2,U,2)=INCQAN("INJURY NOT OTHERWISE LISTED"),($P(QANGLB1,U,10)["2") X MSSG1,MSSG2
|
---|
| 43 | I $P(QANGLB2,U,2)=INCQAN("INJURY NOT OTHERWISE LISTED"),($P(QANGLB1,U,10)["3") X MSSG0,MSSG1,MSSG2
|
---|
| 44 | I $P(QANGLB2,U,2)=INCQAN("FIRE-PATIENT INVOLVED IN"),("23"[$P(QANGLB1,U,10)) X MSSG0,MSSG1,MSSG2
|
---|
| 45 | I $P(QANGLB2,U,2)=INCQAN("SEXUAL ASSAULT") X MSSG0,MSSG1,MSSG2
|
---|
| 46 | I $P(QANGLB2,U,2)=INCQAN("TRANSFUSION ERROR"),($P(QANGLB1,U,10)["2") X MSSG1,MSSG2
|
---|
| 47 | I $P(QANGLB2,U,2)=INCQAN("TRANSFUSION ERROR"),($P(QANGLB1,U,10)["3") X MSSG0,MSSG1,MSSG2
|
---|
| 48 | EXIT ;Exit and Quit!
|
---|
| 49 | Q
|
---|