Home   Package List   Routine Alphabetical List   Global Alphabetical List   FileMan Files List   FileMan Sub-Files List   Package Component Lists   Package-Namespace Mapping  
Routine: PSGWI005

PSGWI005.m

Go to the documentation of this file.
  1. PSGWI005 ; ; 04-JAN-1994
  1. ;;2.3; Automatic Replenishment/Ward Stock ;;4 JAN 94
  1. Q:'DIFQ(58.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
  1. Q Q
  1. ;;^DD(58.1,4,21,2,0)
  1. ;;=credit for the AMIS statistics for this AOU.
  1. ;;^DD(58.1,4,"DT")
  1. ;;=2890627
  1. ;;^DD(58.1,5,0)
  1. ;;=ASK EXPIRATION DATE?^S^0:NO;1:YES;^0;4^Q
  1. ;;^DD(58.1,5,3)
  1. ;;=Enter '1' or 'Y' if you wish to be prompted for Expiration Dates for items in this Area of Use when entering on-demands or quantities dispensed.
  1. ;;^DD(58.1,5,21,0)
  1. ;;=^^5^5^2900705^
  1. ;;^DD(58.1,5,21,1,0)
  1. ;;=If this field is set to '1' or 'Yes' for the Area of Use, the user will
  1. ;;^DD(58.1,5,21,2,0)
  1. ;;=be prompted for Expiration Dates when on-demands or quantities dispensed
  1. ;;^DD(58.1,5,21,3,0)
  1. ;;=(for inventories) are entered. If this field is set to '0' or 'No',
  1. ;;^DD(58.1,5,21,4,0)
  1. ;;=Expiration Dates can only be entered through the supervisor option
  1. ;;^DD(58.1,5,21,5,0)
  1. ;;='Expiration Date Enter/Edit'.
  1. ;;^DD(58.1,5,"DT")
  1. ;;=2900705
  1. ;;^DD(58.1,6,0)
  1. ;;=CRASH CART FLAG^S^0:NO;1:YES;^0;5^Q
  1. ;;^DD(58.1,6,1,0)
  1. ;;=^.1
  1. ;;^DD(58.1,6,1,1,0)
  1. ;;=^^TRIGGER^58.1^7
  1. ;;^DD(58.1,6,1,1,1)
  1. ;;=Q
  1. ;;^DD(58.1,6,1,1,2)
  1. ;;=K DIV S DIV=X,D0=DA,DIV(0)=D0 S Y(1)=$S($D(^PSI(58.1,D0,0)):^(0),1:"") S X=$P(Y(1),U,6),X=X S DIU=X K Y S X="" S DIH=$S($D(^PSI(58.1,DIV(0),0)):^(0),1:""),DIV=X S $P(^(0),U,6)=DIV,DIH=58.1,DIG=7 D ^DICR:$N(^DD(DIH,DIG,1,0))>0
  1. ;;^DD(58.1,6,1,1,"%D",0)
  1. ;;=^^2^2^2930830^
  1. ;;^DD(58.1,6,1,1,"%D",1,0)
  1. ;;=This cross-reference deletes any data in the CRASH CART LOCATION field
  1. ;;^DD(58.1,6,1,1,"%D",2,0)
  1. ;;=(58.1,7) if the CRASH CART FLAG is set to "NO".
  1. ;;^DD(58.1,6,1,1,"CREATE VALUE")
  1. ;;=NO EFFECT
  1. ;;^DD(58.1,6,1,1,"DELETE VALUE")
  1. ;;=@
  1. ;;^DD(58.1,6,1,1,"FIELD")
  1. ;;=CRASH CART LOCATION
  1. ;;^DD(58.1,6,3)
  1. ;;=Enter '1' or 'Y' if this Area of Use is a Crash Cart.
  1. ;;^DD(58.1,6,20,0)
  1. ;;=^.3LA^1^1
  1. ;;^DD(58.1,6,20,1,0)
  1. ;;=PSGW
  1. ;;^DD(58.1,6,21,0)
  1. ;;=^^3^3^2910503^^
  1. ;;^DD(58.1,6,21,1,0)
  1. ;;=This field will be set to '1' (for 'yes') if this area of use is a
  1. ;;^DD(58.1,6,21,2,0)
  1. ;;=crash cart. This flag will be used as a screen to list only crash
  1. ;;^DD(58.1,6,21,3,0)
  1. ;;=carts for the option 'Update Crash Cart Locations'.
  1. ;;^DD(58.1,6,"DT")
  1. ;;=2910503
  1. ;;^DD(58.1,7,0)
  1. ;;=CRASH CART LOCATION^P44'^SC(^0;6^Q
  1. ;;^DD(58.1,7,3)
  1. ;;=Enter the Location of this AOU. This field should only be used to enter locations for CRASH CARTS.
  1. ;;^DD(58.1,7,5,1,0)
  1. ;;=58.1^6^1
  1. ;;^DD(58.1,7,21,0)
  1. ;;=^^5^5^2910528^^
  1. ;;^DD(58.1,7,21,1,0)
  1. ;;=This field is meant to be used to record the location of an area of use
  1. ;;^DD(58.1,7,21,2,0)
  1. ;;=that is a crash cart. This field will be printed on the Expiration Date
  1. ;;^DD(58.1,7,21,3,0)
  1. ;;=report and will be updated in the option 'Update Crash Cart Locations'.
  1. ;;^DD(58.1,7,21,4,0)
  1. ;;=Only areas of use that have the field CRASH CART FLAG set to '1' (for
  1. ;;^DD(58.1,7,21,5,0)
  1. ;;='yes') will be selectable in the update option.
  1. ;;^DD(58.1,7,"DT")
  1. ;;=2910503
  1. ;;^DD(58.11,0)
  1. ;;=ITEM SUB-FIELD^NL^35^17
  1. ;;^DD(58.11,0,"DT")
  1. ;;=2930308
  1. ;;^DD(58.11,0,"ID",1)
  1. ;;=W ""
  1. ;;^DD(58.11,0,"ID",10)
  1. ;;=W:$D(^("0")) " ",$P(^("0"),U,8)
  1. ;;^DD(58.11,0,"IX","AC",58.11,30)
  1. ;;=
  1. ;;^DD(58.11,0,"IX","B",58.11,.01)
  1. ;;=
  1. ;;^DD(58.11,0,"NM","ITEM")
  1. ;;=
  1. ;;^DD(58.11,0,"UP")
  1. ;;=58.1
  1. ;;^DD(58.11,.01,0)
  1. ;;=ITEM^MR*P50'X^PSDRUG(^0;1^S DIC("S")="D DRGSCRN^PSGWUTL" D ^DIC K DIC S DIC=DIE,X=+Y K:Y<0 X I $D(X) D EDCHK^PSGWUTL
  1. ;;^DD(58.11,.01,1,0)
  1. ;;=^.1
  1. ;;^DD(58.11,.01,1,1,0)
  1. ;;=58.11^B
  1. ;;^DD(58.11,.01,1,1,1)
  1. ;;=S ^PSI(58.1,DA(1),1,"B",$E(X,1,30),DA)=""
  1. ;;^DD(58.11,.01,1,1,2)
  1. ;;=K ^PSI(58.1,DA(1),1,"B",$E(X,1,30),DA)
  1. ;;^DD(58.11,.01,3)
  1. ;;=
  1. ;;^DD(58.11,.01,4)
  1. ;;=
  1. ;;^DD(58.11,.01,12)
  1. ;;=Do not select INACTIVE or NON-PHARMACY items. NOTE: Items containing significant data can not be modified.
  1. ;;^DD(58.11,.01,12.1)
  1. ;;=S DIC("S")="D DRGSCRN^PSGWUTL"
  1. ;;^DD(58.11,.01,21,0)
  1. ;;=^^1^1^2930513^^^^
  1. ;;^DD(58.11,.01,21,1,0)
  1. ;;=ITEM defines the name of the drug stocked in this Area of Use.
  1. ;;^DD(58.11,.01,"DEL",13000,0)
  1. ;;=I 1 W !,"ITEMS CANNOT BE DELETED,MUST BE INACTIVATED!"
  1. ;;^DD(58.11,.01,"DT")
  1. ;;=2930603
  1. ;;^DD(58.11,1,0)
  1. ;;=STOCK LEVEL^RNJ4,0^^0;2^K:+X'=X!(X>9999)!(X<0)!(X?.E1"."1N.N) X