MEDS DEBUGGING
This commit is contained in:
parent
efb41d328e
commit
bcbd908de9
|
@ -82,13 +82,12 @@ EXTRACT(MEDXML,DFN,MEDOUTXML) ; EXTRACT MEDICATIONS INTO PROVIDED XML TEMPLATE
|
|||
S @MEDTVMAP@(0)=ZA(0) ; SAVE NUMBER OF MEDS
|
||||
F ZI=1:1:ZA(0) D ; FOR EACH MED
|
||||
. I DEBUG W "ZI IS ",ZI,!
|
||||
. S MEDVMAP=$NA(@MEDTVMAP@(ZI+MEDCNT)) ; START PAST OP ACTIVE MEDS
|
||||
. W ZI," ",MEDCNT,!
|
||||
. K @MEDVMAP
|
||||
. I DEBUG W "VMAP= ",MEDVMAP,!
|
||||
. S ZJ=$P(ZA(ZI),U,1) ; INDEX OF FIRST LINE OF MED IN MEDRSLT
|
||||
. S MEDPTMP=MEDRSLT(ZJ) ; PULL OUT FIRST LINE OF MED
|
||||
. I $P(MEDPTMP,U,1)?1"~OP" Q ; SKIP OP ACTIVE AND PENDING
|
||||
. S MEDCOUNT=MEDCOUNT+1 ; WE ARE GOING TO ADD A MED
|
||||
. S MEDVMAP=$NA(@MEDTVMAP@(ZI+MEDCNT)) ; START PAST OP ACTIVE MEDS
|
||||
. S @MEDTVMAP@(0)=@MEDTVMAP@(0)+1 ; ADDING A MED HERE
|
||||
. S @MEDVMAP@("MEDOBJECTID")="MED"_(ZI+MEDCNT) ; UNIQUE OBJID FOR MEDS
|
||||
. I $P(MEDPTMP,"^",11)="" S @MEDVMAP@("MEDISSUEDATETXT")=""
|
||||
|
|
Loading…
Reference in New Issue