FHINI001 ; ; 11-OCT-1995
;;5.0;Dietetics;;Oct 11, 1995
Q:'DIFQ(111) F I=1:2 S X=$T(Q+I) Q:X="" S Y=$E($T(Q+I+1),4,999),X=$E(X,4,999) S:$A(Y)=126 I=I+1,Y=$E(Y,2,999)_$E($T(Q+I+1),5,99) S:$A(Y)=61 Y=$E(Y,2,999) X NO E S @X=Y
Q Q
;;^DIC(111,0,"GL")
;;=^FH(111,
;;^DIC("B","DIETS",111)
;;=
;;^DIC(111,"%D",0)
;;=^^5^5^2871124^
;;^DIC(111,"%D",1,0)
;;=This file contains a list of all of the diet modifications allowed
;;^DIC(111,"%D",2,0)
;;=by the using facility. Associated with each diet are characteristics
;;^DIC(111,"%D",3,0)
;;=such as alternate names, an abbreviated name, whether a clinician
;;^DIC(111,"%D",4,0)
;;=is to be bulletined when ordered, and a diet precedence which
;;^DIC(111,"%D",5,0)
;;=is used to prevent diet conflicts and as a printing sequence order.
;;^DD(111,0)
;;=FIELD^^99^9
;;^DD(111,0,"ID",99)
;;=W:$D(^("I")) " (** INACTIVE **)"
;;^DD(111,0,"IX","AC",111,99)
;;=
;;^DD(111,0,"IX","B",111,.01)
;;=
;;^DD(111,0,"IX","B",111.01,.01)
;;=
;;^DD(111,0,"IX","C",111,1)
;;=
;;^DD(111,0,"NM","DIETS")
;;=
;;^DD(111,0,"PT",111.1,1)
;;=
;;^DD(111,0,"PT",111.1,2)
;;=
;;^DD(111,0,"PT",111.1,3)
;;=
;;^DD(111,0,"PT",111.1,4)
;;=
;;^DD(111,0,"PT",111.1,5)
;;=
;;^DD(111,0,"PT",115.02,1)
;;=
;;^DD(111,0,"PT",115.02,2)
;;=
;;^DD(111,0,"PT",115.02,3)
;;=
;;^DD(111,0,"PT",115.02,4)
;;=
;;^DD(111,0,"PT",115.02,5)
;;=
;;^DD(111,0,"PT",119.6,15)
;;=
;;^DD(111,0,"SCR")
;;=I '$D(^FH(111,+Y,"I"))!$D(^XUSEC("FHMGR",DUZ))!(DUZ(0)["@")
;;^DD(111,.01,0)
;;=NAME^RF^^0;1^K:$L(X)>30!($L(X)<3)!'(X'?1P.E)!(X'?.ANP) X
;;^DD(111,.01,1,0)
;;=^.1
;;^DD(111,.01,1,1,0)
;;=111^B
;;^DD(111,.01,1,1,1)
;;=S ^FH(111,"B",$E(X,1,30),DA)=""
;;^DD(111,.01,1,1,2)
;;=K ^FH(111,"B",$E(X,1,30),DA)
;;^DD(111,.01,1,1,"%D",0)
;;=^^1^1^2911118^
;;^DD(111,.01,1,1,"%D",1,0)
;;=This is the normal B cross-reference of the NAME field.
;;^DD(111,.01,3)
;;=ANSWER MUST BE 3-30 CHARACTERS IN LENGTH
;;^DD(111,.01,21,0)
;;=^^2^2^2940526^^
;;^DD(111,.01,21,1,0)
;;=This field contains the name of a diet or diet modification as
;;^DD(111,.01,21,2,0)
;;=it would normally be known to ward/medical personnel.
;;^DD(111,.01,"DEL",1,0)
;;=I DUZ(0)'["@",'$D(^XUSEC("FHMGR",DUZ))
;;^DD(111,.01,"DT")
;;=2880108
;;^DD(111,1,0)
;;=SYNONYM^F^^0;2^K:$L(X)>12!($L(X)<1) X
;;^DD(111,1,1,0)
;;=^.1
;;^DD(111,1,1,1,0)
;;=111^C
;;^DD(111,1,1,1,1)
;;=S ^FH(111,"C",$E(X,1,30),DA)=""
;;^DD(111,1,1,1,2)
;;=K ^FH(111,"C",$E(X,1,30),DA)
;;^DD(111,1,3)
;;=ANSWER MUST BE 1-12 CHARACTERS IN LENGTH
;;^DD(111,1,21,0)
;;=^^2^2^2891120^^^
;;^DD(111,1,21,1,0)
;;=This field may contain a synonym for the diet name; the synonym
;;^DD(111,1,21,2,0)
;;=is generally terminology known and used by ward/medical personnel.
;;^DD(111,1,"DT")
;;=2850202
;;^DD(111,2,0)
;;=ASK EXPIRATION DATE?^S^Y:YES;N:NO;^0;3^Q
;;^DD(111,2,21,0)
;;=^^4^4^2880709^
;;^DD(111,2,21,1,0)
;;=This field, when answered YES, will result in the user
;;^DD(111,2,21,2,0)
;;=being prompted for a diet expiration date (as well as the
;;^DD(111,2,21,3,0)
;;=start date) whenever this diet is contained in a total
;;^DD(111,2,21,4,0)
;;=diet order.
;;^DD(111,2,"DT")
;;=2850608
;;^DD(111,3,0)
;;=DIET PRECEDENCE^RNJ2,0^^0;4^K:+X'=X!(X>99)!(X<1)!(X?.E1"."1N.N) X
;;^DD(111,3,3)
;;=TYPE A WHOLE NUMBER BETWEEN 1 AND 99
;;^DD(111,3,21,0)
;;=^^6^6^2880709^
;;^DD(111,3,21,1,0)
;;=This is a numerical value which performs two functions:
;;^DD(111,3,21,2,0)
;;=no two diet modifications with the same precedence may be
;;^DD(111,3,21,3,0)
;;=selected. The same number can therefore be assigned to
;;^DD(111,3,21,4,0)
;;=mutually-exclusive diet modifications. Secondly, the diet
;;^DD(111,3,21,5,0)
;;=modifications will be listed in precedence order, from
;;^DD(111,3,21,6,0)
;;=low to high.
;;^DD(111,3,"DT")
;;=2850129
;;^DD(111,4,0)
;;=PRODUCTION DIET^R*P116.2'^FH(116.2,^0;5^S DIC("S")="I $P(^(0),""^"",4)'=""Y""" D ^DIC K DIC S DIC=DIE,X=+Y K:Y<0 X
;;^DD(111,4,12)
;;=Include only non-combo production diets.
;;^DD(111,4,12.1)
;;=S DIC("S")="I $P(^(0),""^"",4)'=""Y"""
;;^DD(111,4,21,0)
;;=^^3^3^2880709^
;;^DD(111,4,21,1,0)
;;=This field contains the Production Diet entry (file 116.2) which
;;^DD(111,4,21,2,0)
;;=would be prepared for this diet modification were it to stand
;;^DD(111,4,21,3,0)
;;=alone from other diet modifications.
;;^DD(111,4,"DT")
;;=2870713
;;^DD(111,5,0)
;;=BULLETIN CLINICIAN?^S^Y:YES;N:NO;^0;6^Q
;;^DD(111,5,21,0)
;;=^^3^3^2950717^^
;;^DD(111,5,21,1,0)
;;=This field, if answered YES, will result in a bulletin being
;;^DD(111,5,21,2,0)
;;=sent to the clinician responsible for the ward on which the
;;^DD(111,5,21,3,0)
;;=patient resides any time this diet modification is ordered.
;;^DD(111,5,"DT")
;;=2850608
;;^DD(111,6,0)
;;=ABBREVIATED LABEL^RF^^0;7^K:$L(X)>12!($L(X)<1) X
FHINI001 ; ; 11-OCT-1995
+1 ;;5.0;Dietetics;;Oct 11, 1995
+2 IF 'DIFQ(111)
QUIT
FOR I=1:2
SET X=$TEXT(Q+I)
IF X=""
QUIT
SET Y=$EXTRACT($TEXT(Q+I+1),4,999)
SET X=$EXTRACT(X,4,999)
IF $ASCII(Y)=126
SET I=I+1
SET Y=$EXTRACT(Y,2,999)_$EXTRACT($TEXT(Q+I+1),5,99)
IF $ASCII(Y)=61
SET Y=$EXTRACT(Y,2,999)
XECUTE NO
IF '$TEST
SET @X=Y
Q QUIT
+1 ;;^DIC(111,0,"GL")
+2 ;;=^FH(111,
+3 ;;^DIC("B","DIETS",111)
+4 ;;=
+5 ;;^DIC(111,"%D",0)
+6 ;;=^^5^5^2871124^
+7 ;;^DIC(111,"%D",1,0)
+8 ;;=This file contains a list of all of the diet modifications allowed
+9 ;;^DIC(111,"%D",2,0)
+10 ;;=by the using facility. Associated with each diet are characteristics
+11 ;;^DIC(111,"%D",3,0)
+12 ;;=such as alternate names, an abbreviated name, whether a clinician
+13 ;;^DIC(111,"%D",4,0)
+14 ;;=is to be bulletined when ordered, and a diet precedence which
+15 ;;^DIC(111,"%D",5,0)
+16 ;;=is used to prevent diet conflicts and as a printing sequence order.
+17 ;;^DD(111,0)
+18 ;;=FIELD^^99^9
+19 ;;^DD(111,0,"ID",99)
+20 ;;=W:$D(^("I")) " (** INACTIVE **)"
+21 ;;^DD(111,0,"IX","AC",111,99)
+22 ;;=
+23 ;;^DD(111,0,"IX","B",111,.01)
+24 ;;=
+25 ;;^DD(111,0,"IX","B",111.01,.01)
+26 ;;=
+27 ;;^DD(111,0,"IX","C",111,1)
+28 ;;=
+29 ;;^DD(111,0,"NM","DIETS")
+30 ;;=
+31 ;;^DD(111,0,"PT",111.1,1)
+32 ;;=
+33 ;;^DD(111,0,"PT",111.1,2)
+34 ;;=
+35 ;;^DD(111,0,"PT",111.1,3)
+36 ;;=
+37 ;;^DD(111,0,"PT",111.1,4)
+38 ;;=
+39 ;;^DD(111,0,"PT",111.1,5)
+40 ;;=
+41 ;;^DD(111,0,"PT",115.02,1)
+42 ;;=
+43 ;;^DD(111,0,"PT",115.02,2)
+44 ;;=
+45 ;;^DD(111,0,"PT",115.02,3)
+46 ;;=
+47 ;;^DD(111,0,"PT",115.02,4)
+48 ;;=
+49 ;;^DD(111,0,"PT",115.02,5)
+50 ;;=
+51 ;;^DD(111,0,"PT",119.6,15)
+52 ;;=
+53 ;;^DD(111,0,"SCR")
+54 ;;=I '$D(^FH(111,+Y,"I"))!$D(^XUSEC("FHMGR",DUZ))!(DUZ(0)["@")
+55 ;;^DD(111,.01,0)
+56 ;;=NAME^RF^^0;1^K:$L(X)>30!($L(X)<3)!'(X'?1P.E)!(X'?.ANP) X
+57 ;;^DD(111,.01,1,0)
+58 ;;=^.1
+59 ;;^DD(111,.01,1,1,0)
+60 ;;=111^B
+61 ;;^DD(111,.01,1,1,1)
+62 ;;=S ^FH(111,"B",$E(X,1,30),DA)=""
+63 ;;^DD(111,.01,1,1,2)
+64 ;;=K ^FH(111,"B",$E(X,1,30),DA)
+65 ;;^DD(111,.01,1,1,"%D",0)
+66 ;;=^^1^1^2911118^
+67 ;;^DD(111,.01,1,1,"%D",1,0)
+68 ;;=This is the normal B cross-reference of the NAME field.
+69 ;;^DD(111,.01,3)
+70 ;;=ANSWER MUST BE 3-30 CHARACTERS IN LENGTH
+71 ;;^DD(111,.01,21,0)
+72 ;;=^^2^2^2940526^^
+73 ;;^DD(111,.01,21,1,0)
+74 ;;=This field contains the name of a diet or diet modification as
+75 ;;^DD(111,.01,21,2,0)
+76 ;;=it would normally be known to ward/medical personnel.
+77 ;;^DD(111,.01,"DEL",1,0)
+78 ;;=I DUZ(0)'["@",'$D(^XUSEC("FHMGR",DUZ))
+79 ;;^DD(111,.01,"DT")
+80 ;;=2880108
+81 ;;^DD(111,1,0)
+82 ;;=SYNONYM^F^^0;2^K:$L(X)>12!($L(X)<1) X
+83 ;;^DD(111,1,1,0)
+84 ;;=^.1
+85 ;;^DD(111,1,1,1,0)
+86 ;;=111^C
+87 ;;^DD(111,1,1,1,1)
+88 ;;=S ^FH(111,"C",$E(X,1,30),DA)=""
+89 ;;^DD(111,1,1,1,2)
+90 ;;=K ^FH(111,"C",$E(X,1,30),DA)
+91 ;;^DD(111,1,3)
+92 ;;=ANSWER MUST BE 1-12 CHARACTERS IN LENGTH
+93 ;;^DD(111,1,21,0)
+94 ;;=^^2^2^2891120^^^
+95 ;;^DD(111,1,21,1,0)
+96 ;;=This field may contain a synonym for the diet name; the synonym
+97 ;;^DD(111,1,21,2,0)
+98 ;;=is generally terminology known and used by ward/medical personnel.
+99 ;;^DD(111,1,"DT")
+100 ;;=2850202
+101 ;;^DD(111,2,0)
+102 ;;=ASK EXPIRATION DATE?^S^Y:YES;N:NO;^0;3^Q
+103 ;;^DD(111,2,21,0)
+104 ;;=^^4^4^2880709^
+105 ;;^DD(111,2,21,1,0)
+106 ;;=This field, when answered YES, will result in the user
+107 ;;^DD(111,2,21,2,0)
+108 ;;=being prompted for a diet expiration date (as well as the
+109 ;;^DD(111,2,21,3,0)
+110 ;;=start date) whenever this diet is contained in a total
+111 ;;^DD(111,2,21,4,0)
+112 ;;=diet order.
+113 ;;^DD(111,2,"DT")
+114 ;;=2850608
+115 ;;^DD(111,3,0)
+116 ;;=DIET PRECEDENCE^RNJ2,0^^0;4^K:+X'=X!(X>99)!(X<1)!(X?.E1"."1N.N) X
+117 ;;^DD(111,3,3)
+118 ;;=TYPE A WHOLE NUMBER BETWEEN 1 AND 99
+119 ;;^DD(111,3,21,0)
+120 ;;=^^6^6^2880709^
+121 ;;^DD(111,3,21,1,0)
+122 ;;=This is a numerical value which performs two functions:
+123 ;;^DD(111,3,21,2,0)
+124 ;;=no two diet modifications with the same precedence may be
+125 ;;^DD(111,3,21,3,0)
+126 ;;=selected. The same number can therefore be assigned to
+127 ;;^DD(111,3,21,4,0)
+128 ;;=mutually-exclusive diet modifications. Secondly, the diet
+129 ;;^DD(111,3,21,5,0)
+130 ;;=modifications will be listed in precedence order, from
+131 ;;^DD(111,3,21,6,0)
+132 ;;=low to high.
+133 ;;^DD(111,3,"DT")
+134 ;;=2850129
+135 ;;^DD(111,4,0)
+136 ;;=PRODUCTION DIET^R*P116.2'^FH(116.2,^0;5^S DIC("S")="I $P(^(0),""^"",4)'=""Y""" D ^DIC K DIC S DIC=DIE,X=+Y K:Y<0 X
+137 ;;^DD(111,4,12)
+138 ;;=Include only non-combo production diets.
+139 ;;^DD(111,4,12.1)
+140 ;;=S DIC("S")="I $P(^(0),""^"",4)'=""Y"""
+141 ;;^DD(111,4,21,0)
+142 ;;=^^3^3^2880709^
+143 ;;^DD(111,4,21,1,0)
+144 ;;=This field contains the Production Diet entry (file 116.2) which
+145 ;;^DD(111,4,21,2,0)
+146 ;;=would be prepared for this diet modification were it to stand
+147 ;;^DD(111,4,21,3,0)
+148 ;;=alone from other diet modifications.
+149 ;;^DD(111,4,"DT")
+150 ;;=2870713
+151 ;;^DD(111,5,0)
+152 ;;=BULLETIN CLINICIAN?^S^Y:YES;N:NO;^0;6^Q
+153 ;;^DD(111,5,21,0)
+154 ;;=^^3^3^2950717^^
+155 ;;^DD(111,5,21,1,0)
+156 ;;=This field, if answered YES, will result in a bulletin being
+157 ;;^DD(111,5,21,2,0)
+158 ;;=sent to the clinician responsible for the ward on which the
+159 ;;^DD(111,5,21,3,0)
+160 ;;=patient resides any time this diet modification is ordered.
+161 ;;^DD(111,5,"DT")
+162 ;;=2850608
+163 ;;^DD(111,6,0)
+164 ;;=ABBREVIATED LABEL^RF^^0;7^K:$L(X)>12!($L(X)<1) X