source: WorldVistAEHR/trunk/r/RECORD_TRACKING-RT/RTP32.m@ 1704

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

initial load of WorldVistAEHR

File size: 1.5 KB
RevLine 
[613]1RTP32 ;MJK/TROY ISC;Detailed Non-fillable List ; 5/15/87 4:41 PM ;
2 ;;v 2.0;Record Tracking;;10/22/91
3 S RTDTEND=RTDT,X="T-100",%DT="" D ^%DT K %DT S RTDTX=Y
4 I '$D(RTPULL) F RTDTE=RTBEG:0 S RTDTE=$O(^RTV(194.2,"C",RTDTE)) Q:RTDTEND<$P(RTDTE,".")!('RTDTE) F RTP=0:0 S RTP=$O(^RTV(194.2,"C",RTDTE,RTP)) Q:'RTP I $D(^RTV(194.2,RTP,0)),$P(^(0),"^",10)=1 D RTQ
5 I $D(RTPULL) S RTP=RTPULL D RTQ
6 K RTP,RTDTE,RTDTEND,RTDTX Q
7 ;
8RTQ Q:'$D(^RTV(194.2,RTP,0)) S X=^(0) Q:$P(X,"^",6)="x"!($P(X,"^",15)'=+RTAPL) S RTB=+$P(X,"^",5)
9 F RTQ=0:0 S RTQ=$O(^RTV(190.1,"AP",RTP,RTQ)) Q:'RTQ I $D(^RTV(190.1,RTQ,0)) S RTQ0=^(0) I $P(RTQ0,"^",6)="n",$P(RTQ0,"^",5)=RTB,$D(^RT(+RTQ0,0)),$P(^(0),"^")["DPT(" S RTE=$P(^(0),"^"),DFN=+^(0),RTDT=RTDTX D START^RTNQ3 S RTNONE=""
10 K RTB,RTQ,RTE,DFN,RTDT Q
11 ;
12DATE ;get date from parameters
13 S RTPCE=20 D WINDOW^RTRPT
14 S X1=DT,X2=-1 D C^%DTC
15 I X=RTWND S RTWND=""
16 Q
17 ;
18BAR S RTIFN=RT S:$D(X) RTXSAV=X
19 Q:'$D(^RT(RT,0)) S X=$P(^(0),U,3),T=5 Q:'$D(RTWND(X)) I $P(^(0),U,8)'<RTWND(X) Q
20 D FMT^RTL1 I RTFMT S RTQSAV=RTQ,RTNUM=1 D PRT^RTL1
21 S RTQ=RTQSAV S:$D(RTXSAV) X=RTXSAV
22 K RTQSAV,RTXSAV,RTNUM Q
23 ;
24DEV ;select barcode device
25 D DATE Q:'RTWND Q:$D(RTIRE)
26 S RTDEV=$P(RTFR,U,4) ;,IOP="HOME" D ^%ZIS K IOP
27 S RTTASK=1 W !,"Select Barcode Printer ",!
28 S RTDESC="Clinic List Labels ["_$P($P(RTAPL,U),";",2)_"]"
291 S RTVAR="RTDV^RTSORT^RTAPL^RTDT^RTLIST"_$S($D(RTPULL):"^RTPULL^RTPULL0",1:"")_"^RTTASK"_"^RTWND"
30 I RTWND F JA=0:0 S JA=$O(RTWND(JA)) Q:'JA S RTVAR=RTVAR_"^RTWND("_JA_")"
31 K JA S RTPGM="START^RTP3" D ZIS^RTUTL
32 Q
Note: See TracBrowser for help on using the repository browser.