added Immunizations to RIM variable analysis code.. changed global for

parms to  ^TMP("C0CPARMS",$J)
This commit is contained in:
george 2009-02-04 20:18:25 +00:00
parent bfab33053b
commit 39dad84c43
3 changed files with 17 additions and 8 deletions

View File

@ -22,7 +22,7 @@ SET(INPARMS) ;INITIALIZE RUNTIME PARMS USING INPARMS TO OVERRIDE DEFAULTS
; THE SAME FORMAT IS USED BY RPC AND COMMAND LINE ENTRY POINTS ; THE SAME FORMAT IS USED BY RPC AND COMMAND LINE ENTRY POINTS
; ;
N PTMP ; N PTMP ;
S C0CPARMS=$NA(^TMP($J,"C0CPARMS")) ;BASE FOR THIS RUN S C0CPARMS=$NA(^TMP("C0CPARMS",$J)) ;BASE FOR THIS RUN
;K @C0CPARMS ;START WITH EMPTY PARMS; MAY NOT WANT TO DO THIS KILL ;K @C0CPARMS ;START WITH EMPTY PARMS; MAY NOT WANT TO DO THIS KILL
I $G(INPARMS)'="" D ; OVERRIDES PROVIDED I $G(INPARMS)'="" D ; OVERRIDES PROVIDED
. N C0CI S C0CI="" . N C0CI S C0CI=""
@ -39,7 +39,7 @@ SET(INPARMS) ;INITIALIZE RUNTIME PARMS USING INPARMS TO OVERRIDE DEFAULTS
; ;
CHECK ; CHECK TO SEE IF PARMS ARE PRESENT, ELSE RUN SET CHECK ; CHECK TO SEE IF PARMS ARE PRESENT, ELSE RUN SET
; ;
I '$D(C0CPARMS) S C0CPARMS=$NA(^TMP($J,"C0CPARMS")) ;SHOULDN'T HAPPEN I '$D(C0CPARMS) S C0CPARMS=$NA(^TMP("C0CPARMS",$J)) ;SHOULDN'T HAPPEN
I '$D(@C0CPARMS) D SET("SETWITHCHECK:1") I '$D(@C0CPARMS) D SET("SETWITHCHECK:1")
Q Q
; ;

View File

@ -37,6 +37,12 @@ MAP(IPXML,DFN,OUTXML) ; MAP IMMUNIZATIONS
. . E D ;NOT THE FIRST . . E D ;NOT THE FIRST
. . . D INSINNER^GPLXPATH(OUTXML,"C0CZT") . . . D INSINNER^GPLXPATH(OUTXML,"C0CZT")
E S @OUTXML@(0)=0 ; SIGNAL NO IMMUNIZATIONS E S @OUTXML@(0)=0 ; SIGNAL NO IMMUNIZATIONS
N IMMUTMP,I
D MISSING^GPLXPATH(OUTXML,"IMMUTMP") ; SEARCH XML FOR MISSING VARS
I IMMUTMP(0)>0 D ; IF THERE ARE MISSING VARS -
. ; STRINGS MARKED AS @@X@@
. W !,"IMMUNE Missing list: ",!
. F I=1:1:IMMUTMP(0) W IMMUTMP(I),!
Q Q
; ;
EXTRACT(IPXML,DFN,OUTXML) ; EXTRACT IMMUNIZATIONS INTO VARIABLES EXTRACT(IPXML,DFN,OUTXML) ; EXTRACT IMMUNIZATIONS INTO VARIABLES
@ -95,11 +101,7 @@ EXTRACT(IPXML,DFN,OUTXML) ; EXTRACT IMMUNIZATIONS INTO VARIABLES
. . . S @VMAP@("IMMUNEPRODUCTNAMETEXT")=C0CIN ;NAME . . . S @VMAP@("IMMUNEPRODUCTNAMETEXT")=C0CIN ;NAME
. . . S @VMAP@("IMMUNEPRODUCTCODE")="" ; CVX CODE . . . S @VMAP@("IMMUNEPRODUCTCODE")="" ; CVX CODE
. . . S @VMAP@("IMMUNEPRODUCTCODESYSTEM")="" ;NO CODE . . . S @VMAP@("IMMUNEPRODUCTCODESYSTEM")="" ;NO CODE
N IMMUTMP,I N C0CIRIM S C0CIRIM=$NA(^TMP("GPLRIM","VARS",DFN,"IMMUNE"))
D MISSING^GPLXPATH(ARYTMP,"IMMUTMP") ; SEARCH XML FOR MISSING VARS M @C0CIRIM=@TVMAP ; PERSIST RIM VARIABLES
I IMMUTMP(0)>0 D ; IF THERE ARE MISSING VARS -
. ; STRINGS MARKED AS @@X@@
. W !,"IMMUNE Missing list: ",!
. F I=1:1:IMMUTMP(0) W IMMUTMP(I),!
Q Q
; ;

View File

@ -108,6 +108,11 @@ SETATTR(SDFN) ; SET ATTRIBUTES BASED ON VARS
. D APOST("SATTR","RIMTBL","PROBLEMS") . D APOST("SATTR","RIMTBL","PROBLEMS")
. ; W "POSTING PROBLEMS",! . ; W "POSTING PROBLEMS",!
I $D(@SBASE@("VITALS",1)) D APOST("SATTR","RIMTBL","VITALS") I $D(@SBASE@("VITALS",1)) D APOST("SATTR","RIMTBL","VITALS")
I $D(@SBASE@("IMMUNE",1)) D ;IMMUNIZATIONS PRESENT
. D APOST("SATTR","RIMTBL","IMMUNE")
. N ZR,ZI
. D GETPA(.ZR,SDFN,"IMMUNE","IMMUNEPRODUCTCODE")
. I ZR(0)>0 D APOST("SATTR","RIMTBL","IMMUNECODE") ;IMMUNIZATION CODES
I $D(@SBASE@("MEDS",1)) D ; IF THE PATIENT HAS MEDS VARIABLES I $D(@SBASE@("MEDS",1)) D ; IF THE PATIENT HAS MEDS VARIABLES
. D APOST("SATTR","RIMTBL","MEDS") . D APOST("SATTR","RIMTBL","MEDS")
. N ZR,ZI . N ZR,ZI
@ -306,6 +311,8 @@ AINIT ; INITIALIZE ATTRIBUTE TABLE
D APUSH(RIMTBL,"VITALSNOCODE") D APUSH(RIMTBL,"VITALSNOCODE")
D APUSH(RIMTBL,"VITALSDATE") D APUSH(RIMTBL,"VITALSDATE")
D APUSH(RIMTBL,"VITALSNODATE") D APUSH(RIMTBL,"VITALSNODATE")
D APUSH(RIMTBL,"IMMUNE")
D APUSH(RIMTBL,"IMMUNECODE")
D APUSH(RIMTBL,"MEDS") D APUSH(RIMTBL,"MEDS")
D APUSH(RIMTBL,"MEDSCODE") D APUSH(RIMTBL,"MEDSCODE")
D APUSH(RIMTBL,"MEDSNOCODE") D APUSH(RIMTBL,"MEDSNOCODE")