handles cases with both OP and UV meds
This commit is contained in:
parent
7cfbe69c61
commit
707b70f717
|
@ -52,7 +52,7 @@ EXTRACT(MEDXML,DFN,MEDOUTXML) ; EXTRACT MEDICATIONS INTO PROVIDED XML TEMPLATE
|
||||||
. . D INSINNER^GPLXPATH(MEDOUTXML,PENDINGXML) ;ADD PENDING TO ACTIVE
|
. . D INSINNER^GPLXPATH(MEDOUTXML,PENDINGXML) ;ADD PENDING TO ACTIVE
|
||||||
. E D CP^GPLXPATH(PENDINGXML,MEDOUTXML) ; NO ACTIVE MEDS, JUST COPY
|
. E D CP^GPLXPATH(PENDINGXML,MEDOUTXML) ; NO ACTIVE MEDS, JUST COPY
|
||||||
. S MEDCNT=MEDCNT+@MEDTVMAP@(0) ; SAVE COUNT TO KNOW HOW TO ADD TO MAP
|
. S MEDCNT=MEDCNT+@MEDTVMAP@(0) ; SAVE COUNT TO KNOW HOW TO ADD TO MAP
|
||||||
. W MEDCNT,!
|
. ; W MEDCNT,!
|
||||||
. W "HAS OP PENDING MEDS",!
|
. W "HAS OP PENDING MEDS",!
|
||||||
N MEDRSLT,I,J,K,MEDPTMP,X,MEDVMAP,TBUF
|
N MEDRSLT,I,J,K,MEDPTMP,X,MEDVMAP,TBUF
|
||||||
D ACTIVE^ORWPS(.MEDRSLT,DFN)
|
D ACTIVE^ORWPS(.MEDRSLT,DFN)
|
||||||
|
@ -82,7 +82,7 @@ EXTRACT(MEDXML,DFN,MEDOUTXML) ; EXTRACT MEDICATIONS INTO PROVIDED XML TEMPLATE
|
||||||
; S @MEDTVMAP@(0)=ZA(0) ; SAVE NUMBER OF MEDS
|
; S @MEDTVMAP@(0)=ZA(0) ; SAVE NUMBER OF MEDS
|
||||||
F ZI=1:1:ZA(0) D ; FOR EACH MED
|
F ZI=1:1:ZA(0) D ; FOR EACH MED
|
||||||
. I DEBUG W "ZI IS ",ZI,!
|
. I DEBUG W "ZI IS ",ZI,!
|
||||||
. W ZI," ",MEDCNT,!
|
. ; W ZI," ",MEDCNT,!
|
||||||
. S ZJ=$P(ZA(ZI),U,1) ; INDEX OF FIRST LINE OF MED IN MEDRSLT
|
. 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
|
. S MEDPTMP=MEDRSLT(ZJ) ; PULL OUT FIRST LINE OF MED
|
||||||
. I $P(MEDPTMP,U,1)?1"~OP" Q ; SKIP OP ACTIVE AND PENDING
|
. I $P(MEDPTMP,U,1)?1"~OP" Q ; SKIP OP ACTIVE AND PENDING
|
||||||
|
|
Loading…
Reference in New Issue