FHINI0M5 ; ; 11-OCT-1995
;;5.0;Dietetics;;Oct 11, 1995
Q:'DIFQ(118.1) 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(118.1,0,"GL")
;;=^FH(118.1,
;;^DIC("B","SUPPLEMENTAL FEEDING MENU",118.1)
;;=
;;^DIC(118.1,"%D",0)
;;=^^5^5^2871124^
;;^DIC(118.1,"%D",1,0)
;;=This file contains a pattern of supplemental feedings (up to four
;;^DIC(118.1,"%D",2,0)
;;=items for each of three time periods) which are often requested
;;^DIC(118.1,"%D",3,0)
;;=in common situations (e.g., a diabetic patient) and avoids the
;;^DIC(118.1,"%D",4,0)
;;=necessity of individually selecting the various items when
;;^DIC(118.1,"%D",5,0)
;;=ordering supplemental feedings.
;;^DD(118.1,0)
;;=FIELD^^99^28
;;^DD(118.1,0,"ID",99)
;;=W:$D(^("I")) " (** INACTIVE **)"
;;^DD(118.1,0,"IX","AC",118.1,99)
;;=
;;^DD(118.1,0,"IX","B",118.1,.01)
;;=
;;^DD(118.1,0,"IX","C",118.1,1)
;;=
;;^DD(118.1,0,"NM","SUPPLEMENTAL FEEDING MENU")
;;=
;;^DD(118.1,0,"PT",111.1,18)
;;=
;;^DD(118.1,0,"PT",115.07,3)
;;=
;;^DD(118.1,0,"SCR")
;;=I '$D(^FH(118.1,+Y,"I"))!$D(^XUSEC("FHMGR",DUZ))!(DUZ(0)["@")
;;^DD(118.1,.01,0)
;;=NAME^RF^^0;1^K:$L(X)>27!($L(X)<3)!'(X'?1P.E)!(X'?.ANP) X
;;^DD(118.1,.01,1,0)
;;=^.1
;;^DD(118.1,.01,1,1,0)
;;=118.1^B
;;^DD(118.1,.01,1,1,1)
;;=S ^FH(118.1,"B",$E(X,1,30),DA)=""
;;^DD(118.1,.01,1,1,2)
;;=K ^FH(118.1,"B",$E(X,1,30),DA)
;;^DD(118.1,.01,1,1,"%D",0)
;;=^^1^1^2911118^
;;^DD(118.1,.01,1,1,"%D",1,0)
;;=This is the normal B cross-reference of the NAME field.
;;^DD(118.1,.01,3)
;;=ANSWER MUST BE 3-27 CHARACTERS IN LENGTH
;;^DD(118.1,.01,21,0)
;;=^^2^2^2880710^
;;^DD(118.1,.01,21,1,0)
;;=This is the name of the supplemental feeding menu, a pre-set
;;^DD(118.1,.01,21,2,0)
;;=collection of feeding items for the three feeding times.
;;^DD(118.1,.01,"DEL",1,0)
;;=I DUZ(0)'["@",'$D(^XUSEC("FHMGR",DUZ))
;;^DD(118.1,.01,"DT")
;;=2850207
;;^DD(118.1,1,0)
;;=SYNONYM^F^^0;2^K:$L(X)>10!($L(X)<3) X
;;^DD(118.1,1,1,0)
;;=^.1
;;^DD(118.1,1,1,1,0)
;;=118.1^C
;;^DD(118.1,1,1,1,1)
;;=S ^FH(118.1,"C",$E(X,1,30),DA)=""
;;^DD(118.1,1,1,1,2)
;;=K ^FH(118.1,"C",$E(X,1,30),DA)
;;^DD(118.1,1,3)
;;=ANSWER MUST BE 3-10 CHARACTERS IN LENGTH
;;^DD(118.1,1,21,0)
;;=^^1^1^2880710^
;;^DD(118.1,1,21,1,0)
;;=This field may contain a synonym for the feeding menu.
;;^DD(118.1,1,"DT")
;;=2850316
;;^DD(118.1,3,0)
;;=DIETARY OR THERAPEUTIC^RS^D:DIETARY;T:THERAPEUTIC;^1;25^Q
;;^DD(118.1,3,21,0)
;;=^^2^2^2880710^
;;^DD(118.1,3,21,1,0)
;;=This field indicates whether the menu is generally ordered
;;^DD(118.1,3,21,2,0)
;;=for dietary or therapeutic reasons.
;;^DD(118.1,3,"DT")
;;=2851003
;;^DD(118.1,10,0)
;;=10AM FEEDING #1^*P118'^FH(118,^1;1^S DIC("S")="I $P(^(0),U,3)'=""Y""" D ^DIC K DIC S DIC=DIE,X=+Y K:Y<0 X
;;^DD(118.1,10,12)
;;=Cannot select bulk nourishments
;;^DD(118.1,10,12.1)
;;=S DIC("S")="I $P(^(0),U,3)'=""Y"""
;;^DD(118.1,10,21,0)
;;=^^1^1^2880710^^
;;^DD(118.1,10,21,1,0)
;;=This is the first supplemental feeding item for the 10am feeding.
;;^DD(118.1,10,"DT")
;;=2850604
;;^DD(118.1,10.5,0)
;;=10AM #1 QTY^NJ2,0^^1;2^K:+X'=X!(X>20)!(X<1)!(X?.E1"."1N.N) X
;;^DD(118.1,10.5,3)
;;=TYPE A WHOLE NUMBER BETWEEN 1 AND 20
;;^DD(118.1,10.5,21,0)
;;=^^1^1^2880710^^
;;^DD(118.1,10.5,21,1,0)
;;=This is the quantity of the first 10am feeding item.
;;^DD(118.1,11,0)
;;=10AM FEEDING #2^*P118'^FH(118,^1;3^S DIC("S")="I $P(^(0),U,3)'=""Y""" D ^DIC K DIC S DIC=DIE,X=+Y K:Y<0 X
;;^DD(118.1,11,12)
;;=Cannot select bulk nourishments
;;^DD(118.1,11,12.1)
;;=S DIC("S")="I $P(^(0),U,3)'=""Y"""
;;^DD(118.1,11,21,0)
;;=^^1^1^2880710^^
;;^DD(118.1,11,21,1,0)
;;=This is the second supplemental feeding item for the 10am feeding.
;;^DD(118.1,11,"DT")
;;=2850604
;;^DD(118.1,11.5,0)
;;=10AM #2 QTY^NJ2,0^^1;4^K:+X'=X!(X>20)!(X<1)!(X?.E1"."1N.N) X
;;^DD(118.1,11.5,3)
;;=TYPE A WHOLE NUMBER BETWEEN 1 AND 20
;;^DD(118.1,11.5,21,0)
;;=^^1^1^2880710^^
;;^DD(118.1,11.5,21,1,0)
;;=This is the quantity of the second 10am feeding item.
;;^DD(118.1,12,0)
;;=10AM FEEDING #3^*P118'^FH(118,^1;5^S DIC("S")="I $P(^(0),U,3)'=""Y""" D ^DIC K DIC S DIC=DIE,X=+Y K:Y<0 X
;;^DD(118.1,12,12)
;;=Cannot select bulk nourishments
;;^DD(118.1,12,12.1)
;;=S DIC("S")="I $P(^(0),U,3)'=""Y"""
;;^DD(118.1,12,21,0)
;;=^^1^1^2880710^^^
;;^DD(118.1,12,21,1,0)
;;=This is the third supplemental feeding item for the 10am feeding.
;;^DD(118.1,12.5,0)
;;=10AM #3 QTY^NJ2,0^^1;6^K:+X'=X!(X>20)!(X<1)!(X?.E1"."1N.N) X
;;^DD(118.1,12.5,3)
;;=TYPE A WHOLE NUMBER BETWEEN 1 AND 20
;;^DD(118.1,12.5,21,0)
;;=^^1^1^2880710^^^
;;^DD(118.1,12.5,21,1,0)
;;=This is the quantity of the third 10am feeding item.
;;^DD(118.1,13,0)
;;=10AM FEEDING #4^*P118'^FH(118,^1;7^S DIC("S")="I $P(^(0),U,3)'=""Y""" D ^DIC K DIC S DIC=DIE,X=+Y K:Y<0 X
FHINI0M5 ; ; 11-OCT-1995
+1 ;;5.0;Dietetics;;Oct 11, 1995
+2 IF 'DIFQ(118.1)
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(118.1,0,"GL")
+2 ;;=^FH(118.1,
+3 ;;^DIC("B","SUPPLEMENTAL FEEDING MENU",118.1)
+4 ;;=
+5 ;;^DIC(118.1,"%D",0)
+6 ;;=^^5^5^2871124^
+7 ;;^DIC(118.1,"%D",1,0)
+8 ;;=This file contains a pattern of supplemental feedings (up to four
+9 ;;^DIC(118.1,"%D",2,0)
+10 ;;=items for each of three time periods) which are often requested
+11 ;;^DIC(118.1,"%D",3,0)
+12 ;;=in common situations (e.g., a diabetic patient) and avoids the
+13 ;;^DIC(118.1,"%D",4,0)
+14 ;;=necessity of individually selecting the various items when
+15 ;;^DIC(118.1,"%D",5,0)
+16 ;;=ordering supplemental feedings.
+17 ;;^DD(118.1,0)
+18 ;;=FIELD^^99^28
+19 ;;^DD(118.1,0,"ID",99)
+20 ;;=W:$D(^("I")) " (** INACTIVE **)"
+21 ;;^DD(118.1,0,"IX","AC",118.1,99)
+22 ;;=
+23 ;;^DD(118.1,0,"IX","B",118.1,.01)
+24 ;;=
+25 ;;^DD(118.1,0,"IX","C",118.1,1)
+26 ;;=
+27 ;;^DD(118.1,0,"NM","SUPPLEMENTAL FEEDING MENU")
+28 ;;=
+29 ;;^DD(118.1,0,"PT",111.1,18)
+30 ;;=
+31 ;;^DD(118.1,0,"PT",115.07,3)
+32 ;;=
+33 ;;^DD(118.1,0,"SCR")
+34 ;;=I '$D(^FH(118.1,+Y,"I"))!$D(^XUSEC("FHMGR",DUZ))!(DUZ(0)["@")
+35 ;;^DD(118.1,.01,0)
+36 ;;=NAME^RF^^0;1^K:$L(X)>27!($L(X)<3)!'(X'?1P.E)!(X'?.ANP) X
+37 ;;^DD(118.1,.01,1,0)
+38 ;;=^.1
+39 ;;^DD(118.1,.01,1,1,0)
+40 ;;=118.1^B
+41 ;;^DD(118.1,.01,1,1,1)
+42 ;;=S ^FH(118.1,"B",$E(X,1,30),DA)=""
+43 ;;^DD(118.1,.01,1,1,2)
+44 ;;=K ^FH(118.1,"B",$E(X,1,30),DA)
+45 ;;^DD(118.1,.01,1,1,"%D",0)
+46 ;;=^^1^1^2911118^
+47 ;;^DD(118.1,.01,1,1,"%D",1,0)
+48 ;;=This is the normal B cross-reference of the NAME field.
+49 ;;^DD(118.1,.01,3)
+50 ;;=ANSWER MUST BE 3-27 CHARACTERS IN LENGTH
+51 ;;^DD(118.1,.01,21,0)
+52 ;;=^^2^2^2880710^
+53 ;;^DD(118.1,.01,21,1,0)
+54 ;;=This is the name of the supplemental feeding menu, a pre-set
+55 ;;^DD(118.1,.01,21,2,0)
+56 ;;=collection of feeding items for the three feeding times.
+57 ;;^DD(118.1,.01,"DEL",1,0)
+58 ;;=I DUZ(0)'["@",'$D(^XUSEC("FHMGR",DUZ))
+59 ;;^DD(118.1,.01,"DT")
+60 ;;=2850207
+61 ;;^DD(118.1,1,0)
+62 ;;=SYNONYM^F^^0;2^K:$L(X)>10!($L(X)<3) X
+63 ;;^DD(118.1,1,1,0)
+64 ;;=^.1
+65 ;;^DD(118.1,1,1,1,0)
+66 ;;=118.1^C
+67 ;;^DD(118.1,1,1,1,1)
+68 ;;=S ^FH(118.1,"C",$E(X,1,30),DA)=""
+69 ;;^DD(118.1,1,1,1,2)
+70 ;;=K ^FH(118.1,"C",$E(X,1,30),DA)
+71 ;;^DD(118.1,1,3)
+72 ;;=ANSWER MUST BE 3-10 CHARACTERS IN LENGTH
+73 ;;^DD(118.1,1,21,0)
+74 ;;=^^1^1^2880710^
+75 ;;^DD(118.1,1,21,1,0)
+76 ;;=This field may contain a synonym for the feeding menu.
+77 ;;^DD(118.1,1,"DT")
+78 ;;=2850316
+79 ;;^DD(118.1,3,0)
+80 ;;=DIETARY OR THERAPEUTIC^RS^D:DIETARY;T:THERAPEUTIC;^1;25^Q
+81 ;;^DD(118.1,3,21,0)
+82 ;;=^^2^2^2880710^
+83 ;;^DD(118.1,3,21,1,0)
+84 ;;=This field indicates whether the menu is generally ordered
+85 ;;^DD(118.1,3,21,2,0)
+86 ;;=for dietary or therapeutic reasons.
+87 ;;^DD(118.1,3,"DT")
+88 ;;=2851003
+89 ;;^DD(118.1,10,0)
+90 ;;=10AM FEEDING #1^*P118'^FH(118,^1;1^S DIC("S")="I $P(^(0),U,3)'=""Y""" D ^DIC K DIC S DIC=DIE,X=+Y K:Y<0 X
+91 ;;^DD(118.1,10,12)
+92 ;;=Cannot select bulk nourishments
+93 ;;^DD(118.1,10,12.1)
+94 ;;=S DIC("S")="I $P(^(0),U,3)'=""Y"""
+95 ;;^DD(118.1,10,21,0)
+96 ;;=^^1^1^2880710^^
+97 ;;^DD(118.1,10,21,1,0)
+98 ;;=This is the first supplemental feeding item for the 10am feeding.
+99 ;;^DD(118.1,10,"DT")
+100 ;;=2850604
+101 ;;^DD(118.1,10.5,0)
+102 ;;=10AM #1 QTY^NJ2,0^^1;2^K:+X'=X!(X>20)!(X<1)!(X?.E1"."1N.N) X
+103 ;;^DD(118.1,10.5,3)
+104 ;;=TYPE A WHOLE NUMBER BETWEEN 1 AND 20
+105 ;;^DD(118.1,10.5,21,0)
+106 ;;=^^1^1^2880710^^
+107 ;;^DD(118.1,10.5,21,1,0)
+108 ;;=This is the quantity of the first 10am feeding item.
+109 ;;^DD(118.1,11,0)
+110 ;;=10AM FEEDING #2^*P118'^FH(118,^1;3^S DIC("S")="I $P(^(0),U,3)'=""Y""" D ^DIC K DIC S DIC=DIE,X=+Y K:Y<0 X
+111 ;;^DD(118.1,11,12)
+112 ;;=Cannot select bulk nourishments
+113 ;;^DD(118.1,11,12.1)
+114 ;;=S DIC("S")="I $P(^(0),U,3)'=""Y"""
+115 ;;^DD(118.1,11,21,0)
+116 ;;=^^1^1^2880710^^
+117 ;;^DD(118.1,11,21,1,0)
+118 ;;=This is the second supplemental feeding item for the 10am feeding.
+119 ;;^DD(118.1,11,"DT")
+120 ;;=2850604
+121 ;;^DD(118.1,11.5,0)
+122 ;;=10AM #2 QTY^NJ2,0^^1;4^K:+X'=X!(X>20)!(X<1)!(X?.E1"."1N.N) X
+123 ;;^DD(118.1,11.5,3)
+124 ;;=TYPE A WHOLE NUMBER BETWEEN 1 AND 20
+125 ;;^DD(118.1,11.5,21,0)
+126 ;;=^^1^1^2880710^^
+127 ;;^DD(118.1,11.5,21,1,0)
+128 ;;=This is the quantity of the second 10am feeding item.
+129 ;;^DD(118.1,12,0)
+130 ;;=10AM FEEDING #3^*P118'^FH(118,^1;5^S DIC("S")="I $P(^(0),U,3)'=""Y""" D ^DIC K DIC S DIC=DIE,X=+Y K:Y<0 X
+131 ;;^DD(118.1,12,12)
+132 ;;=Cannot select bulk nourishments
+133 ;;^DD(118.1,12,12.1)
+134 ;;=S DIC("S")="I $P(^(0),U,3)'=""Y"""
+135 ;;^DD(118.1,12,21,0)
+136 ;;=^^1^1^2880710^^^
+137 ;;^DD(118.1,12,21,1,0)
+138 ;;=This is the third supplemental feeding item for the 10am feeding.
+139 ;;^DD(118.1,12.5,0)
+140 ;;=10AM #3 QTY^NJ2,0^^1;6^K:+X'=X!(X>20)!(X<1)!(X?.E1"."1N.N) X
+141 ;;^DD(118.1,12.5,3)
+142 ;;=TYPE A WHOLE NUMBER BETWEEN 1 AND 20
+143 ;;^DD(118.1,12.5,21,0)
+144 ;;=^^1^1^2880710^^^
+145 ;;^DD(118.1,12.5,21,1,0)
+146 ;;=This is the quantity of the third 10am feeding item.
+147 ;;^DD(118.1,13,0)
+148 ;;=10AM FEEDING #4^*P118'^FH(118,^1;7^S DIC("S")="I $P(^(0),U,3)'=""Y""" D ^DIC K DIC S DIC=DIE,X=+Y K:Y<0 X