VistA-WorldVistAEHR/r/LAB_SERVICE-LR-LS/LRGVP.m

30 lines
1.6 KiB
Mathematica

LRGVP ;SLC/CJS - GROUP DATA REVIEW DISPLAY ;2/5/91 13:29 ;
;;5.2;LAB SERVICE;**112**;Sep 27, 1994
I '$D(LRPARAM) D ^LRPARAM
K LRORD S LRGVP="",LRPANEL="ALL" W !,"Print manually entered data by accession",!
S DIC="^LRO(68,",DIC(0)="AEFOMQ" D ^DIC S LRAA=+Y,LRNAME=$P(Y,U,2) Q:LRAA<1 D PHD Q:LREND
Q:'$D(^LRO(68,LRAA,1,LRAD,1,0)) S:'$D(LRNAME) LRNAME=$P(^LRO(68,LRAA,0),U,1)
S %ZIS="Q" D ^%ZIS Q:POP
I $D(IO("Q")) K IO("Q") S ZTRTN="DQ^LRGVP",ZTSAVE("LR*")="",ZTSAVE("^TMP(""LR"",$J,")="" D ^%ZTLOAD G END
DQ U IO D HED S LRAN=LRFAN-.01 F S LRAN=$O(^LRO(68,LRAA,1,LRAD,1,LRAN)) Q:LRAN<1!(LRAN>LRLAN) D PRINT Q:$D(DUOUT)!$D(DTOUT)
W:'$D(LRORD) !,"No data to review.",! D ^%ZISC
END K LRGFLPG G ^LRGVK
PRINT Q:'$D(^LRO(68,LRAA,1,LRAD,1,LRAN,0)) S LRDFN=+^(0),LRORD=$S($D(^(.1)):^(.1),1:0),LRODT=$S($P(^(0),U,4):$P(^(0),U,4),1:$P(^(0),U,3)),LRSN=$P(^(0),U,5) Q:LRSN<1
S LRDPF=$P(^LR(LRDFN,0),U,2) W:'$L($S($D(^LRO(68,LRAA,1,LRAD,1,LRAN,3)):$P(^(3),U,3),1:""))&(LRDPF=2) !,"NOT COLLECTED"
S DFN=$P(^LR(LRDFN,0),U,3) D PT^LRX W:$E(IOST,1,2)'="C-"&(IOSL\3*2<$Y) @IOF
D:$E(IOST,1,2)="C-"&$D(LRGFLPG) PG Q:$D(DUOUT)!$D(DTOUT) S LRGFLPG=""
W !!,PNM,?30,"SSN: ",SSN,?50,"WARD: ",$S(LRDPF=2&($L(LRWRD)):LRWRD,$D(^LR(LRDFN,.1)):^(.1),1:"") W:LRORD !,"ORDER NUMBER: ",LRORD
S LRPANEL="ALL" D VER^LRVER1
W !,"----" F I=1:5:IOM-6 W "-----"
Q
PHD ;
S X="N",%DT="T" D ^%DT D DD^LRX S LRDT=Y,%H=$H-$P(^LAB(69.9,1,0),"^",7) D YMD^LRX S LRTM60=9999999-X
D ADATE^LRWU S LRAD=Y Q:LREND D LRAN^LRWU3
Q
PG K DTOUT,DUOUT
S DIR(0)="E" D ^DIR K DIR
W @IOF
Q
HED W @IOF,!,"WorkList Name: ",LRNAME,?40,LRDT,!!
Q