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

BCHUEDT1.m

Go to the documentation of this file.
BCHUEDT1 ; IHS/CMI/LAB - EDIT A RECORD ; 
 ;;2.0;IHS RPMS CHR SYSTEM;;OCT 23, 2012;Build 27
 ;
 D ^BCHUIN
 D GETDATE
 I BCHDATE="" W !!,"No Date entered!" D EOJ Q
 D GETPROV
 K BCHR,BCHRRECS,BCHVRECS D RECLKUP
 I '$G(BCHR) D EOJ Q
 D EDIT
 D EOJ
 Q
GETDATE ; GET DATE OF ENCOUNTER
 W !
 S BCHDATE=""
 S DIR(0)="DO^:"_DT_":EPT",DIR("A")="Enter DATE OF SERVICE" D ^DIR K DIR S:$D(DUOUT) DIRUT=1
 Q:$D(DIRUT)
 S %DT="ET" D ^%DT G:Y<0 GETDATE
 I Y>DT W "  <Future dates not allowed>",$C(7),$C(7) K X G GETDATE
 K BCHODAT
 S BCHDATE=Y
 ;
 Q
 ;
GETPROV ;get location of encounter
 S BCHPROV=""
 S DIC("A")="Enter CHR (if known): ",DIC="^VA(200,",DIC(0)="AEMQ" D ^DIC K DIC,DA
 Q:Y<0
 S BCHPROV=+Y
 Q
EDIT ;
 S BCHEN1=1
 D DISP^BCHUEDT
 Q
 ;
RECLKUP ;
 D ^BCHULKUP
 Q
EOJ ; END OF JOB
 K BCHPROV,BCHDATE,DFN,BCHODAT,BCHR,BCHEN1
 Q
 ;