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

RMPR22.m

Go to the documentation of this file.
RMPR22 ;PHX/DWL-EDIT 10-2319 RECORD ;8/29/1994
 ;;3.0;PROSTHETICS;;Feb 09, 1996
EN D GETPAT^RMPRUTIL
LIST G:'$D(RMPRDFN) EXIT S RC=0,RMPRA="" D ^RMPRL22
OVER S %=1 R !,"ARE YOU READY TO ACCEPT THESE ENTRIES" D YN^DICN G:$D(DTOUT) EXIT G:%=1 EXIT
 S %=2 R !,"DO YOU WISH TO DELETE AN ENTRY" D YN^DICN G:$D(DTOUT) EXIT G:%=1 DEL
 W !,"ENTER THE NUMBER OF THE ENTRY YOU WISH TO EDIT.    " R ANS:DTIME Q:'$T!(ANS="^")
 I ANS'?1.2N!(ANS>RC) W $C(7),!,"ANSWER MUST BE A WHOLE NUMBER NOT GREATER THAN ",RC,"." G OVER
 I ANS>0,(ANS<(RC+1)) S RMPRA=RMPRA(ANS)
 G EDIT
EXIT K RMPRQT,Y,RMPRK,%,DIC,DIK,RMPRG,DA,DIE,DR,RMPRI,PRCP("I"),PRCP("ITEM"),PRCP("TYP"),PRCP("COM"),X,RMPRGIP,RMPRDFN,RMPRD,RMPRACT,RMPRIP,RMPRTO,RMPRCT,RMPRRD,RED,RMPRDD,RMPRSO
 Q
EDIT S DIC="^RMPR(660,",DIC(0)="N,Z",X=RMPRA D ^DIC G:Y=-1 LIST S RED=^RMPR(660,+Y,0),DA=+Y,DIE=DIC,DR="4" D ^DIE S RMPRI=$P(^RMPR(660,DA,0),U,6)
 I RMPRI=$P(RED,U,6) S RMPRI=$P(^RMPR(661,RMPRI,0),U,1) G COST
 S RMPRI=$P(^RMPR(661,RMPRI,0),U,1) S RMPRCT(RMPRA)=$S($D(RMPRCT(RMPRA)):RMPRCT(RMPRA),1:0)
COST W !,"UNIT COST: $",RMPRCT(RMPRA),"  " R ANS:DTIME G:'$T KILL^RMPR21 S:(RMPRCT(RMPRA)'=ANS)&(ANS>0) RMPRCT(RMPRA)=ANS
 S DR="5;12;7;2;62;63;10;9;21;16" D ^DIE I $P(^RMPR(660,RMPRA,0),U,14)["V"&($P(^(0),U,9)'="") S $P(^(0),U,9)=""
 S RMPRTO=$P(^RMPR(660,RMPRA,0),U,7)*RMPRCT(RMPRA),$P(^(0),U,16)=RMPRTO W !,"TOTAL COST: $",RMPRTO
 G LIST
DEL W !,"ENTER THE NUMBER OF THE ENTRY YOU WISH TO DELETE.   " R ANS:DTIME Q:'$T!(ANS="^")
 I ANS'?1.1N!(ANS>RC) W $C(7),!,"ANSWER MUST BE A WHOLE NUMBER NOT GREATER THAN ",RC,"." G LIST
 I ANS>0,(ANS<(RC+1)) K RMPRCT(ANS) S DA=RMPRA(ANS),DIK="^RMPR(660," D ^DIK K RMPRA(ANS)
 G LIST