1 | DVBHQZ4 ;ISC-ALBANY/PKE-enter in Suspense File ; 8/25/87 16:05 ;
|
---|
2 | ;;V4.0;HINQ;;03/25/92
|
---|
3 | D DIV,TELL,FIND G EX
|
---|
4 | Q
|
---|
5 | FIND S DIC="^DPT(",DIC(0)="AEMQZ" D ^DIC Q:+Y'>0 S DFN=+Y D VER W:$D(DVBVER) !,?20,"Verified" W:'$D(DVBVER) !,?15 D EN^DVBHQUT G FIND
|
---|
6 | Q ;G EX
|
---|
7 | ;
|
---|
8 | EN I $D(^DVB(395.5,DFN,0)),"PNEA"[$P(^(0),U,4) W !,$C(7),"A HINQ Request has already been made for this patient",!,"Do you wish to make another Request"
|
---|
9 | E W !,"Do you wish to request a HINQ inquiry "
|
---|
10 | AGAIN S %=2 D YN^DICN I %=1 S DVBDIV=0 D EN^DVBHQUT G EX1
|
---|
11 | I %Y'["?" G EX1
|
---|
12 | D H1 G AGAIN
|
---|
13 | ;
|
---|
14 | EX K DFN,%
|
---|
15 | EX1 K X,%Y,C,D0,D1,DA,DVBO,DI,DIC,DIE,DK,DL,DOW,DR,Z,DVBDIV,DVBDIVN,Y,DVBVER,DVBSTOP,DVBKEY,DVBTIM,DVBGO,DVBZ,DVBNUM,DVBP QUIT
|
---|
16 | ;
|
---|
17 | VER K DVBVER I $D(DFN),$D(^DPT(DFN,.361)),$P(^(.361),"^",1)="V" S DVBVER="" Q
|
---|
18 | Q
|
---|
19 | ;
|
---|
20 | DIV S DVBDIV=0 I $D(^DVB(395,1,"HQ")),$P(^("HQ"),U,13) S DVBDIV=$P(^DG(43,1,"GL"),U,3) I DVBDIV
|
---|
21 | E Q
|
---|
22 | S DIC(0)="AZEQMN",DIC="^DG(40.8,",DIC("A")="Select Medical Center Division: ",DIC("B")=DVBDIV
|
---|
23 | S X=DVBDIV D ^DIC I +Y>0 S DVBDIV=+Y,DVBDIVN=$S($D(Y(0,0)):Y(0,0),1:$P(Y,U,2))
|
---|
24 | K DIC("A"),DIC("B") Q
|
---|
25 | ;
|
---|
26 | TELL I DVBDIV,$D(DVBDIVN) W !,"The HINQ response will show the '"_DVBDIVN_"' division",!
|
---|
27 | Q
|
---|
28 | ;
|
---|
29 | HINQ I $D(DUZ)#2'=1 W !,"DUZ not defined",! Q
|
---|
30 | I $D(^VA(200,DUZ,.1)) S DVBNUM=$P(^(.1),U,9) I DVBNUM
|
---|
31 | E W !," HINQ Employee Number not in New Person file",!," Notify System Manager",! Q
|
---|
32 | S DVBGO=0
|
---|
33 | W !!,"Select patients, enter your Password and HINQ requests will be sent",!
|
---|
34 | ;
|
---|
35 | D DIV,TELL,AGN G EX
|
---|
36 | ;
|
---|
37 | AGN S DIC="^DPT(",DIC(0)="AEMQZ" D ^DIC I +Y>0 S DVBGO=DVBGO+1,DFN=+Y D VER W:$D(DVBVER) !,?25,"Verified"
|
---|
38 | G:Y'>0 PAS
|
---|
39 | I $D(^DVB(395.5,DFN,0)),"PNE"[$P(^(0),U,4) W !,$C(7),"A HINQ Request has already been made for this patient",!,"Do you wish to make another Request"
|
---|
40 | E D ^DVBHQUT G AGN
|
---|
41 | ASK S %=2 D YN^DICN I %=1 S DVBGO=DVBGO+1 D ^DVBHQUT G AGN
|
---|
42 | I %Y["?" D H2 G ASK
|
---|
43 | I %=2 S DVBGO=DVBGO-1 G AGN
|
---|
44 | PAS I DVBGO>0 W ! D PASS^DVBHQDB
|
---|
45 | Q ;G EX
|
---|
46 | ;
|
---|
47 | H1 W !!,"Answer 'Y'es to enter a Request in the HINQ suspense File" D H3 Q
|
---|
48 | ;
|
---|
49 | H2 W !!,"Answer 'Y'es to enter a Request in the HINQ suspense File" W:DVBDIV !,"The HINQ responses will show the '"_DVBDIVN_"' Division"
|
---|
50 | W !,"When you enter the HINQ password all 'P'ending requests in the",!,"HINQ suspense file will be processed"
|
---|
51 | ;
|
---|
52 | H3 W !!,"Do you wish to request a HINQ inquiry " Q
|
---|