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

PSDRF2.m

Go to the documentation of this file.
PSDRF2 ;BIR/JPW,LTL-Nurse RF Dispensing count correction; 8 Aug 94
 ;;3.0; CONTROLLED SUBSTANCES ;;13 Feb 97
QTY S DIR(0)="NA^.01:999999:2",DIR("A")="Correct Count: "
 W ! D ^DIR K DIR
 I $D(DIRUT)!(Y'>0) S PSDOUT=1 G END
 S PSDQ(1)=Y,PSDTYP=9,PSDQ=OQTY-Y
 I PSDQ(1)=OQTY W !!,"That's no change." Q
 I Y>OQTY S NAOU(1)=0 D ^PSDORSU G:$G(NAOU(1)) BAL^PSDRF I $G(PSDOUT) G END
 S DIR(0)="58.81,15" W ! D ^DIR K DIR
 I $D(DIRUT) S PSDOUT=1 G END
 S PSDRE=Y
WIT W ! S NUR2=$$WITNESS^XUVERIFY("WITNESS")
 I DUZ=NUR2 W !!,"Hold it, you can't witness yourself!",$C(7) G WIT
 I NUR2'>0 S PSDOUT=1 Q
 W !!,"Thank you, ",$S($P($G(^VA(200,NUR2,.1)),U,4)]"":$P($G(^(.1)),U,4),1:$P($G(^VA(200,NUR2,0)),U))
 D UPDAT^PSDRF1
END K %,%DT,%H,%I,CNT,CNT1,DA,DIC,DIE,DINUM,DIR,DIROUT,DIRUT,DIWF,DIWL,DIWR,DR,DTOUT,DUOUT,LN,MSG,MSG1
 K NAOUN,NBKU,NPKG,OK,OKTYP,ORD,PSDA,PSDEM,PSDQTY,PSDRD,PSDRE,PSDRN,PSDT,PSDUZ,PSDUZN,REQD,TEXT,TYPE,WORD,X
 Q