source: FOIAVistA/trunk/r/INCIDENT_REPORTING-QAN/QANBENE.m@ 632

Last change on this file since 632 was 628, checked in by George Lilly, 15 years ago

initial load of FOIAVistA 6/30/08 version

File size: 3.0 KB
Line 
1QANBENE ;HISC/GJC-Special incidents invol. a beneficiary ;3/3/92 [ 09/15/95 7:51 AM ]
2 ;;2.0;Incident Reporting;**1,18,23,26,28**;08/07/1992
3 ;
4 D KILL^QANBENE0,^QAQDATE I QAQQUIT D K^QAQDATE W !!,$C(7),"Invalid date range, no report will be produced." Q
5 S (PAGE,QANCONT,QANQUIT)=0
6 S Y=QAQNBEG D DD^%DT S QANDATE(0)=Y
7 S Y=QAQNEND D DD^%DT S QANDATE(1)=Y
8 S QANLWLT=QAQNBEG-.0000001,QANUPLT=QAQNEND_".9999999"
9 D DIV^QANRPT1
10 S QANSITE(0)=$S($G(^QA(740,1,0))]"":$P(^(0),U),1:"")
11 I QANSITE(0)']"" W !!,$C(7),"Site Parameters file incomplete, contact your site manager." D KILL^QANBENE0 Q
12 S QANSITE=$$PRIM^VASITE(DT),QANSITE=$$SITE^VASITE(DT,QANSITE)
13 S QANSITE(1)=$P(QANSITE,U,3)
14 S QANSITE=$P(QANSITE,U,2)
15 I $G(QANDVFLG)=1 S QANSITE=$$NAME^VASITE(DT)
16 S QANHEAD(0)="Summary of Incidents Involving Patients (RCS 10-0073)"
17 S QANHEAD(1)="For the period "_QANDATE(0)_" to "_QANDATE(1)
18 S QANHEAD(2)="Site Name: "_QANSITE_" FTS#:____________________"
19 ;/*** SET UP TABS ***/
20 S QANTAB(1)=$J(((5/80)*IOM),2,0),QANTAB(2)=$J(((10/80)*IOM),2,0),QANTAB(3)=$J(((25/80)*IOM),2,0),QANTAB(4)=$J(((27/80)*IOM),2,0),QANTAB(5)=$J(((45/80)*IOM),2,0),QANTAB(6)=$J(((55/80)*IOM),2,0)
21 ;/*** SET UP TABS ***/
22 ;D DIV^QANRPT1
23 K DIR S DIR(0)="FAO^1:1^K:""BCO""'[X X",DIR("A")="Select Incident Status (B/C/O): ",DIR("?")="Enter ""O"" to select open cases, ""C"" for closed cases, or ""B"" for both open and closed cases" D ^DIR K DIR
24 I $D(DIRUT) D KILL^QANBENE0 Q
25 S QANFLG("IR STAT")=$S("B"[Y:"013","C"[Y:"0",1:"13") ;set IR Status flag
26EN2 ;Call to ^QANBENE0
27 D EN1^QANBENE0
28 Q
29VALID ;Validate as a reportable incident.
30 S QANSWCH=0
31 I $D(^QA(742.1,"BUPPER","PATIENT ABUSE",QAN("INC"))) S QANSWCH=1 Q
32 I $D(^QA(742.1,"BUPPER","DEATH",QAN("INC"))) S QANSWCH=1 Q
33 I $D(^QA(742.1,"BUPPER","INFORMED CONSENT-FAIL. TO OBTAIN",QAN("INC"))) S QANSWCH=1 Q
34 I $D(^QA(742.1,"BUPPER","FALL",QAN("INC"))) S QANSWCH=1 Q
35 I $D(^QA(742.1,"BUPPER","HOMICIDE",QAN("INC"))) S QANSWCH=1 Q
36 I $D(^QA(742.1,"BUPPER","MEDICATION ERROR",QAN("INC"))) S QANSWCH=1 Q
37 I $D(^QA(742.1,"BUPPER","MISSING PATIENT",QAN("INC"))) S QANSWCH=1 Q
38 I $D(^QA(742.1,"BUPPER","ASSAULT-PATIENT TO PATIENT",QAN("INC"))) S QANSWCH=1 Q
39 I $D(^QA(742.1,"BUPPER","INFORMED CONSENT, FAIL. TO OBTAIN",QAN("INC"))) S QANSWCH=1 Q
40 I $D(^QA(742.1,"BUPPER","ASSAULT-PATIENT/STAFF",QAN("INC"))) S QANSWCH=1 Q
41 I $D(^QA(742.1,"BUPPER","ASSAULT, PATIENT TO PATIENT",QAN("INC"))) S QANSWCH=1 Q
42 I $D(^QA(742.1,"BUPPER","ASSAULT, PATIENT/STAFF",QAN("INC"))) S QANSWCH=1 Q
43 I $D(^QA(742.1,"BUPPER","FIRE, PATIENT INVOLVED IN",QAN("INC"))) S QANSWCH=1 Q
44 I $D(^QA(742.1,"BUPPER","INJURY NOT OTHERWISE LISTED",QAN("INC"))) S QANSWCH=1 Q
45 I $D(^QA(742.1,"BUPPER","FIRE-PATIENT INVOLVED IN",QAN("INC"))) S QANSWCH=1 Q
46 I $D(^QA(742.1,"BUPPER","SEXUAL ASSAULT",QAN("INC"))) S QANSWCH=1 Q
47 I $D(^QA(742.1,"BUPPER","SUICIDE ATTEMPT",QAN("INC"))) S QANSWCH=1 Q
48 I $D(^QA(742.1,"BUPPER","SUICIDE",QAN("INC"))) S QANSWCH=1 Q
49 I $D(^QA(742.1,"BUPPER","TRANSFUSION ERROR",QAN("INC"))) S QANSWCH=1
50 Q
Note: See TracBrowser for help on using the repository browser.