source: WorldVistAEHR/trunk/r/DIETETICS-FH/FHDCR2.m@ 1042

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

initial load of WorldVistAEHR

File size: 678 bytes
Line 
1FHDCR2 ; HISC/REL/NCA - Find Order Changes ;4/20/95 11:33
2 ;;5.5;DIETETICS;;Jan 28, 2005
3EVT ; Find order changes,SF,FP,Isolation,SO,Location
4 ; Except Allergies.
5 I SF,$P($G(^FHPT(FHDFN,"A",ADM,"SF",+SF,0)),"^",2)>FHD,$P($G(^FHPT(FHDFN,"A",ADM,"SF",+SF,0)),"^",34)'="Y" S FLG2=1 Q
6 F KK=FHD-.0001:0 S KK=$O(^FH(119.8,"AP",FHDFN,KK)) Q:KK>TIM!(KK<1) F DA=0:0 S DA=$O(^FH(119.8,"AP",FHDFN,KK,DA)) Q:DA<1 D Q:FLG2
7 .S Z=$G(^FH(119.8,DA,0)) Q:Z="" S D1=$P(Z,"^",2),TYP=$P(Z,"^",5),ACT=$P(Z,"^",6)
8 .I TYP="L" D Q
9 ..I "AT"[ACT S FLG2=1 Q
10 ..Q
11 .I TYP="D" Q
12 .I TYP="M" Q
13 .I TYP="I" S FLG2=1 Q
14 .I TYP="T" Q
15 .I TYP="O" Q
16 .I TYP="P" S FLG2=1 Q
17 .I TYP="S" S FLG2=1 Q
18 .Q
19 Q
Note: See TracBrowser for help on using the repository browser.