source: FOIAVistA/trunk/r/LAB_SERVICE-LR-LS/LRUTW.m@ 1274

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

initial load of FOIAVistA 6/30/08 version

File size: 2.5 KB
Line 
1LRUTW ;AVAMC/REG - DISPLAY LAB TEST INFO FOR LAB ; 2/14/89 17:19 ;
2 ;;5.2;LAB SERVICE;;Sep 27, 1994
3 N N,LRCSREC,AGE,SEX
4 S AGE="??",SEX="M",IOP="HOME" D ^%ZIS W @IOF
5ASK S DIC="^LAB(60,",DIC(0)="AEMOQZ",DIC("S")="I $E($P(^(0),U,3),1)'[""N""" D ^DIC K DIC G:X=""!(X[U)!(Y<0) END S LRIFN=+Y
6 D HDR I $D(^LAB(60,LRIFN,5)),$P(^(5,0),U,4) W !,"Synonym: " F X=0:0 S X=$O(^LAB(60,LRIFN,5,X)) Q:'X D:$Y>21 SYN W !?5,$P(^LAB(60,LRIFN,5,X,0),U,1)
7 I $D(^LAB(60,LRIFN,2)),$P(^(2,0),U,4) W !,"Tests in panel:" F X=0:0 S X=$O(^LAB(60,LRIFN,2,X)) Q:'X D:$Y>21 PANEL W !?5,$P(^LAB(60,+^LAB(60,LRIFN,2,X,0),0),U,1)
8 I $D(^LAB(60,LRIFN,1,0)),$P(^LAB(60,LRIFN,1,0),U,4)>0 D NORM
9 I $D(^LAB(60,LRIFN,6)),$P(^(6,0),U,4) W !,"General Ward Instructions:" F M=0:0 S M=$O(^LAB(60,LRIFN,6,M)) Q:'M D:$Y>21 WARD W !,^LAB(60,LRIFN,6,M,0)
10 I $D(^LAB(60,LRIFN,3,0)),$P(^LAB(60,LRIFN,3,0),U,4)>0 D LIST
11 W !! G ASK
12LIST I $D(^LAB(60,LRIFN,3)),$P(^(3,0),U,4) D COL S N=0 F A=1:1 S N=$O(^LAB(60,LRIFN,3,N)) Q:'N D:$Y>21 COLL S LRND=^LAB(60,LRIFN,3,N,0) D SHOW
13 Q
14SHOW S LRCSREC=$G(^LAB(62,+LRND,0))
15 W:A>1 ! W !,$S($L($P(LRCSREC,U)):$E($P(LRCSREC,U),1,20),1:"??")
16 W ?21,$E($P(LRND,U,2),1,15),?37,$E($P(LRCSREC,U,3),1,30)
17 W ?68,$E($P(LRND,U,4),1,12)
18 Q:'$D(^LAB(60,LRIFN,3,N,1,0))
19 I $D(^LAB(60,LRIFN,3)),$P(^(3,0),U,4) W !,"Ward Instructions:" S M=0 F B=1:1 S M=$O(^LAB(60,LRIFN,3,N,1,M)) Q:'M D:$Y>21 WARD W !,^LAB(60,LRIFN,3,N,1,M,0)
20LAB ;S M=0 F C=1:1 S M=$O(^LAB(60,LRIFN,3,N,2,M)) Q:'M W:C=1 !!,"Lab Processing Instructions:" W !,^LAB(60,LRIFN,3,N,2,M,0)
21 Q
22NORM S N=0 F A=1:1 S N=$O(^LAB(60,LRIFN,1,N)) Q:'N W:A=1 !!,"Reference Values",?22,"Ref Low",?30,"Ref High",?41,"Critical Low",?54,"Critical High",!,?22,"<---",?63,"--->",! D LST
23 Q
24LST W !,$E($P(^LAB(61,N,0),U),1,19) S P=^LAB(60,LRIFN,1,N,0)
25 W ?25,@$S($P(P,U,2)'="":$P(P,U,2),1:""""""),?32,@$S($P(P,U,3)'="":$P(P,U,3),1:""""""),?48,@$S($P(P,U,4)'="":$P(P,U,4),1:""""""),?60,@$S($P(P,U,5):$P(P,U,5),1:""""""),?70,$P(P,U,7)
26 I $L($P(P,U,11,12))>1 W !,?10,"Therapeutic low: ",$P(P,U,11),?37,"Therapeutic high: ",$P(P,U,12)
27 F X=0:0 S X=$O(^LAB(60,LRIFN,1,N,1,X)) Q:'X W !,^(X,0)
28 Q
29PANEL D HOLD W !,"Tests in panel: " Q
30 Q
31HDR W @IOF,"Lab test",?20,"Highest allowed urgency Cost",!
32 W $E($P(Y(0),U,1),1,26),?28,$S($P(Y(0),U,16):$E($P(^LAB(62.05,$P(Y(0),U,16),0),U,1),1,14),1:"any"),?45,$P(Y(0),U,11) Q
33HOLD R !,"Press any key to continue ",%:DTIME D HDR Q
34COL W !,"Collection Sample",?21,"VA Lab Slip",?37,"Container",?68,"Vol Req(ml)" Q
35COLL D HOLD,COL Q
36WARD D HOLD W !,"Ward Instructions:" Q
37SYN D HOLD W !,"Synonym:" Q
38END D V^LRU Q
Note: See TracBrowser for help on using the repository browser.