source: WorldVistAEHR/trunk/r/GEN_MED_REC_VITALS-GMRV/GMRVCAQU.m@ 1166

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

initial load of WorldVistAEHR

File size: 2.9 KB
Line 
1GMRVCAQU ;HIRMFO/YH-DISPLAY CATEGORY/QUALIFIER/SYNONYM TABLE FOR VITAL TYPE ;4/30/97
2 ;;4.0;Vitals/Measurements;**1**;Apr 25, 1997
3EN1 ;DISPLAY QUALIFIER/SYNONYM TABLE FOR EACH VITAL TYPE
4DEV S %ZIS="Q" D ^%ZIS K %ZIS G:POP Q1 I $E(IOST)="P",'$D(IO("Q")),'$D(IO("S")) D ^%ZISC W !,?3,"PRINTED REPORTS MUST BE QUEUED!!",$C(7) G DEV
5 I $D(IO("Q")) S ZTIO=ION,ZTDESC="Vital Categry/Qualifier/Synonym Table",ZTRTN="START^GMRVCAQU" D ^%ZTLOAD K IO("Q"),ZTSK,ZTIO Q
6START ;
7 S (GMROUT,GMRPG)=0 U IO D HDR F GMRVIT(1)="BLOOD PRESSURE","PULSE","RESPIRATION","TEMPERATURE","WEIGHT","CIRCUMFERENCE/GIRTH","HEIGHT","PULSE OXIMETRY" Q:GMROUT D
8 . S GMRVIT=$O(^GMRD(120.51,"B",GMRVIT(1),0)) Q:GMRVIT'>0!GMROUT D
9 . . S GMRVITY=$P(^GMRD(120.51,GMRVIT,0),"^",2) Q:GMRVITY=""!GMROUT S GLVL=8 D LISTQ^GMRVQUAL Q:GMROUT D OTHERQ D CLEAR
10Q1 K GMRVIT,GMRVITY,GLVL,GMROUT,GMRPG D CLEAR
11 S:$D(ZTQUEUED) ZTREQ="@" D ^%ZISC
12 Q
13HDR ;
14 Q:$G(GSFILE)>0 I $E(IOST)'="P",GMRPG>0 W "Press return to continue ""^"" to escape " R X:DTIME I X="^"!'$T S GMROUT=1 Q
15 W @IOF S GMRPG=GMRPG+1
16 W !,"Vitals/Measurements Category/Qualifier/Synonym Table",?65,"Page ",GMRPG,!,$$RJ^XLFSTR(" ",75,"-")
17 W:GMRPG>1 !,GLABEL,!,GLABEL(1)
18 Q
19CLEAR ;
20 K GCHART1,GQUAL,GMRVDFLT,GORDER,GLABEL,GFLAG,GMAX,GMIN,GMRLAST,GMRINF,GCAT,GCHA,GCHART,GCOL,GDA,GENTR,GTXT,GBLNK,GCOUNT,GLN,GMRENTR,GMRVODR,GSIDE,GTYPE,GDASH
21 Q
22OTHERQ ;
23 Q:'$D(GCHART)&('$D(GCHART1)) S GCOL=1,GFLAG=0,$P(GLABEL," ",80)="",$P(GBLNK," ",80)="",$P(GLABEL(1)," ",80)="",$P(GDASH,"-",20)=""
24 S (GMAX,GMAX(1))=0 F S GMAX(1)=$O(GCOUNT(GMAX(1))) Q:GMAX(1)'>0 S GMAX(2)="" F S GMAX(2)=$O(GCOUNT(GMAX(1),GMAX(2))) Q:GMAX(2)="" I GCOUNT(GMAX(1),GMAX(2))>GMAX S GMAX=GCOUNT(GMAX(1),GMAX(2))
25 Q:+$G(GMAX)=0 F I=1:1:GMAX S $P(GTXT(I)," ",80)=""
26 S GMRVODR=0 F S GMRVODR=$O(GCOUNT(GMRVODR)) Q:GMRVODR'>0 S GCAT=$O(GCOUNT(GMRVODR,"")) Q:GCAT="" D
27 . S GCOL=$S(GMRVODR=1:1,GMRVODR=2:18,GMRVODR=3:39,GMRVODR=4:58,1:70)
28 . I GMRVODR=2,GMRVIT(1)="PULSE" S GCOL=28
29 . I GMRVODR=2,GMRVIT(1)="RESPIRATION" S GCOL=32
30 . S GLABEL=$S(GMRVODR=1:$E(GCAT_GBLNK,1,80),1:$E($E(GLABEL,1,GCOL)_GCAT_GBLNK,1,80))
31 . S GCAT(1)=$E(GDASH,1,$L(GCAT))
32 . S GLABEL(1)=$S(GMRVODR=1:$E(GCAT(1)_GBLNK,1,80),1:$E($E(GLABEL(1),1,GCOL)_GCAT(1)_GBLNK,1,80))
33 . S I=0,GCHA="" F S GCHA=$O(GQUAL(GMRVODR,GCHA)) Q:GCHA="" D
34 . . S GSYNO(1)=$O(^GMRD(120.52,"B",GCHA,0)) Q:GSYNO(1)'>0 S GSYNO=$P($G(^GMRD(120.52,GSYNO(1),0)),"^",2)
35 . . S I=I+1,GTXT(I)=$S(GMRVODR=1:$E(GCHA_": "_GSYNO_GBLNK,1,80),1:$E($E(GTXT(I),1,GCOL)_GCHA_": "_GSYNO_GBLNK,1,80))
36 W !!,"Qualifiers for "_GMRVIT(1)_": ",!!,GLABEL,!,GLABEL(1)
37 F I=1:1:GMAX D:IOSL<($Y+6) HDR Q:GMROUT W !,GTXT(I)
38 Q
39GETSYN(GSYNON,GCHA) ;EXTRACT SYNONYM
40 ;I $D(GSYNON(GCHA)) S GSYNON=GSYNON(GCHA) Q
41 ;I GCHA["-" S GCHA=$P(GCHA,"-")_" "_$P(GCHA,"-",2)
42 ;I $L(GCHA," ")<2 S GSYNON=$E(GCHA)_$$LOW^XLFSTR($E(GCHA,2,3)) Q
43 ;N GLEN,I S GLEN=$L(GCHA," ") F I=1:1:GLEN S GSYNON=GSYNON_$S($E($P(GCHA," ",I))'="(":$E($P(GCHA," ",I)),1:"")
44 ;Q
Note: See TracBrowser for help on using the repository browser.