source: WorldVistAEHR/trunk/r/AUTOMATED_MED_INFO_EXCHANGE-DVBA-DVBC/DVBAUTL3.m@ 1073

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

initial load of WorldVistAEHR

File size: 2.5 KB
Line 
1DVBAUTL3 ;ALB/JLU-A general utility routine ;1/28/93
2 ;;2.7;AMIE;;Apr 10, 1995
3 ;
4DEL(DA) ;this subroutine will delete an entry from file 396
5 N Z
6 S DIK="^DVB(396,"
7 D ^DIK
8 I IOST?1"C-".E W *7,!,?10,"7131 entry deleted.",?39,"<Return to continue>"
9 R Z:DTIME
10 K DIK
11 Q
12 ;
13FILE ;this subroutine files the results into 396 for DVBARQP
14 N A
15 S A=^DVB(396,DVBAENTR,0)
16 S $P(A,U,5)=$P(DVBARPT(1),U,2)
17 S $P(A,U,9)=$P(DVBARPT(1),U,3)
18 S $P(A,U,6)=$P(DVBARPT(2),U,2)
19 S $P(A,U,11)=$P(DVBARPT(2),U,3)
20 S $P(A,U,7)=$P(DVBARPT(3),U,2)
21 S $P(A,U,13)=$P(DVBARPT(3),U,3)
22 S $P(A,U,8)=$P(DVBARPT(4),U,2)
23 S $P(A,U,15)=$P(DVBARPT(4),U,3)
24 S $P(A,U,16)=$P(DVBARPT(5),U,2)
25 S $P(A,U,17)=$P(DVBARPT(5),U,3)
26 S $P(A,U,18)=$P(DVBARPT(6),U,2)
27 S $P(A,U,19)=$P(DVBARPT(6),U,3)
28 S $P(A,U,20)=$P(DVBARPT(7),U,2)
29 S $P(A,U,21)=$P(DVBARPT(7),U,3)
30 S $P(A,U,22)=$P(DVBARPT(8),U,2)
31 S $P(A,U,23)=$P(DVBARPT(8),U,3)
32 S $P(A,U,24)=$P(DVBARPT(9),U,2)
33 S $P(A,U,27)=$P(DVBARPT(10),U,2)
34 S $P(A,U,28)=$P(DVBARPT(10),U,3)
35 S ^DVB(396,DVBAENTR,0)=A
36 S $P(^DVB(396,DVBAENTR,1),U,7)=$P(DVBARPT(9),U,3)
37 D DIVUPDT^DVBAUTL2
38 Q
39 ;
40INITRPT ;This subroutine will setup the report array.
41 S DVBAO=^DVB(396,DVBAENTR,0)
42 S DVBARPT(1)="Notice of discharge"_"^"_$S($D(DVBAEDT):$P(DVBAO,U,5),1:"NO")_"^"_$S($D(DVBAEDT):$P(DVBAO,U,9),1:"")
43 S DVBARPT(2)="Hospital Summary"_"^"_$S($D(DVBAEDT):$P(DVBAO,U,6),1:"NO")_"^"_$S($D(DVBAEDT):$P(DVBAO,U,11),1:"")
44 S DVBARPT(3)="Certificate (21-day)"_"^"_$S($D(DVBAEDT):$P(DVBAO,U,7),1:"NO")_"^"_$S($D(DVBAEDT):$P(DVBAO,U,13),1:"")
45 S DVBARPT(4)="Other/Exam (Review Remarks)"_"^"_$S($D(DVBAEDT):$P(DVBAO,U,8),1:"NO")_"^"_$S($D(DVBAEDT):$P(DVBAO,U,15),1:"")
46 S DVBARPT(5)="Special Report"_"^"_$S($D(DVBAEDT):$P(DVBAO,U,16),1:"NO")_"^"_$S($D(DVBAEDT):$P(DVBAO,U,17),1:"")
47 S DVBARPT(6)="Competency Report"_"^"_$S($D(DVBAEDT):$P(DVBAO,U,18),1:"NO")_"^"_$S($D(DVBAEDT):$P(DVBAO,U,19),1:"")
48 S DVBARPT(7)="VA Form 21-2680"_"^"_$S($D(DVBAEDT):$P(DVBAO,U,20),1:"NO")_"^"_$S($D(DVBAEDT):$P(DVBAO,U,21),1:"")
49 S DVBARPT(8)="Asset Information"_"^"_$S($D(DVBAEDT):$P(DVBAO,U,22),1:"NO")_"^"_$S($D(DVBAEDT):$P(DVBAO,U,23),1:"")
50 S DVBAP=^DVB(396,DVBAENTR,1)
51 S DVBARPT(9)="Admission Report"_"^"_$S($D(DVBAEDT):$P(DVBAO,U,24),1:"NO")_"^"_$S($D(DVBAEDT):$P(DVBAP,U,7),1:"")
52 S DVBARPT(10)="Beginning Date Care"_"^"_$S($D(DVBAEDT):$P(DVBAO,U,27),1:"NO")_"^"_$S($D(DVBAEDT):$P(DVBAO,U,28),1:"")
53 Q
54 ;
55IFNPAR() ;
56 ;This function call returns the internal entry number of the entry in
57 ;the parameter file 396.1. There are no inputs. The outputs are either
58 ;the IFN or zero.
59 ;
60 N X
61 S X=$O(^DVB(396.1,0))
62 I 'X Q 0
63 Q X
Note: See TracBrowser for help on using the repository browser.