source: WorldVistAEHR/trunk/r/RADIOLOGY_NUCLEAR_MEDICINE-RA/RASTEXT1.m@ 1154

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

initial load of WorldVistAEHR

File size: 2.0 KB
Line 
1RASTEXT1 ;HISC/CAH,FPT,GJC AISC/TMP,TAC-Selection of patient for status tracking ;9/4/97 15:10
2 ;;5.0;Radiology/Nuclear Medicine;;Mar 16, 1998
3SELECT ;
4 S RACONTIN=0 ;ft
5 I RADTI,(($O(^TMP($J,"RASTEXT",RADTI))>0)!($O(^TMP($J,"RASTEXT",RADTI,I1))>0)) S RACONTIN=1
6 W !!,"Enter " W:RAED "Case #, " W "Status, (N)ext status" W:RACONTIN ", (C)ontinue"
7 W ", '^' to Stop: "_$S(RACONTIN=1:"CONTINUE",1:"NEXT")_"// " R RAX:DTIME I '$T S RAQ=1 Q
8 G:RAX["?" HELP S:RAX="^" RAQ=1 Q:RAQ
9 I RAX="" S RAX=$S(RACONTIN=1:"C",1:"N")
10 G NEXT:"Nn"[$E(RAX)
11 G:RAX?1N.E&(RAED) CASE
12 S RAX=$$UP^XLFSTR(RAX)
13 I RAX=$E("CONTINUE",1,$L(RAX)) S RAX="C"
14 G:RAX?1A.E SEL1
15HELP W:RAX'["?" *7
16 W !!,"Enter " W:RAED "a case number OR",!,"Multiple case #'s separated by commas OR",! W "The name of another status OR",!,"'N' to get the screen containing the next status"
17 W:RADTI " OR",!,"'C' to continue with the next screen of patients for this status"
18 G SELECT
19 ;
20SEL1 I "Cc"[RAX,RADTI,($O(^TMP($J,"RASTEXT",RADTI))>0!($O(^(RADTI,I1))>0)) Q
21 I "Cc"[RAX,'RADTI G HELP
22 S DIC="^RA(72,",DIC(0)="EQZF",X=RAX
23 S DIC("S")="S RAZ=^(0) I $P(RAZ,U,3)>0,(+$P(RAZ,U,7)=+$O(^RA(79.2,""B"",RAIMGTY,0))),($P(RAZ,U,3)'>8),($P(RAZ,U,5)=""Y"")"
24 D ^DIC K DIC("S"),RAZ I Y'>0 W !,"Status ",RAX," not selected." G SELECT
25 I $P(Y(0),"^",3)>0,$D(^RADPT("AS",+Y)) K ^TMP($J,"RASTEXT") S RASTAT=+Y,RAORD=$P(Y(0),"^",3) D START^RASTEXT S (RADTI,RACTR)=0 Q
26 W *7,!,"No data exists for status ",$P(Y(0),"^") G SELECT
27 ;
28CASE S X=RAX D ^RASTED Q:RAXIT K ^TMP($J,"RASTEXT") D START^RASTEXT S (RADFN,RACTR,RADTI)=0 Q
29 ;
30NEXT I $O(RASEQARR(RAORD))=""!($O(RASEQARR(RAORD))>8) W *7,!,"Last status - Do you want to start over? YES// " R RAX:DTIME S:'$T RAQ=1 S RAX=$E(RAX) D Q:RAQ G:'$D(RAX) NEXT S RAORD=""
31 .I RAX="?" W !!,"Answer YES or NO",! K RAX Q
32 .S:"Yy"'[RAX!(RAX="^") RAQ=1
33 K ^TMP($J,"RASTEXT") D NXTSTAT,START^RASTEXT G NEXT:'RACTR S (RACTR,RADTI)=0
34 Q
35 ;
36NXTSTAT ;get next status
37 S RAORD=$O(RASEQARR(RAORD)),RASTAT=RASEQARR(RAORD) I $D(^RA(72,+RASTAT,0)),$P(^(0),"^",5)'="Y" Q:'RAORD!(RAORD>8) G NXTSTAT
38 Q
Note: See TracBrowser for help on using the repository browser.