Changeset 93


Ignore:
Timestamp:
Aug 19, 2008, 4:50:47 PM (16 years ago)
Author:
George Lilly
Message:

fixed Meds processing - patched up until new APIs are in place

Location:
ccr/trunk/p
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • ccr/trunk/p/GPLCCR.m

    r84 r93  
    4949    ;    "TO" VARIABLES
    5050    ;    IF NULL WILL DEFAULT TO "FROM" DUZ AND "TO" DFN
    51     S DEBUG=0
     51    I '$D(DEBUG) S DEBUG=0
    5252    S CCD=0 ; NEED THIS FLAG TO DISTINGUISH FROM CCD
    5353    I '$D(TESTLAB) S TESTLAB=0 ; FLAG FOR TESTING RESULTS SECTION
  • ccr/trunk/p/GPLMEDS.m

    r90 r93  
    3232   . S @MEDOUTXML@(0)=0
    3333   . Q
    34    IF DEBUG ZWR MEDRSLT
     34   I DEBUG ZWR MEDRSLT
    3535   S MEDTVMAP=$NA(^TMP("GPLCCR",$J,"MEDICATIONS"))
    3636   S MEDTARYTMP=$NA(^TMP("GPLCCR",$J,"MEDARYTMP"))
    3737   F J=1:3 Q:'$D(MEDRSLT(J))  D  ; FOR EACH MEDICATION IN THE LIST
    38    . W "J IS ",J,!
     38   . I DEBUG W "J IS ",J,!
    3939   . S MEDVMAP=$NA(@MEDTVMAP@(J))
    4040   . K @MEDVMAP
     
    4343   . S @MEDVMAP@("MEDICATIONOBJECTID")="MED"_J ; UNIQUE OBJID FOR MEDS
    4444   . ; PROCESSING FOR MEDS GOES HERE
    45    . S @MEDVMAP@("MEDICATIONDATETIMETEXT")=$$FMDTOUTC^CCRUTIL($P(MEDPTMP,"^",11),"DT") ; GETS LAST FILL DATE
     45   . S @MEDVMAP@("MEDISSUEDATETXT")=$$FMDTOUTC^CCRUTIL($P(MEDPTMP,"^",11),"DT") ; GETS LAST FILL DATE
    4646   . S @MEDVMAP@("MEDICATIONDATETIMEAGE")=""
    4747   . S @MEDVMAP@("MEDICATIONDATETIMEAGEUNITS")=""
    48    . S @MEDVMAP@("MEDICATIONTYPETEXT")="Medication"
    49    . S @MEDVMAP@("MEDICATIONSTATUSTEXT")=$P(MEDPTMP,"^",10) ; STATUS FROM RPC
    50    . S @MEDVMAP@("MEDICATIONSOURCEACTORID")="ACTORSYSTEM_1"
    51    . S @MEDVMAP@("MEDICATIONPRODUCTNAMETEXT")=$P(MEDPTMP,"^",3)
     48   . S @MEDVMAP@("MEDTYPETEXT")="Medication"
     49   . S @MEDVMAP@("MEDSTATUSTEXT")=$P(MEDPTMP,"^",10) ; STATUS FROM RPC
     50   . S @MEDVMAP@("MEDSOURCEACTORID")="ACTORSYSTEM_1"
     51   . S @MEDVMAP@("MEDPRODUCTNAMETEXT")=$P(MEDPTMP,"^",3)
    5252   . S @MEDVMAP@("MEDICATIONPRODUCTNAMECODEVALUE")=""
    5353   . S @MEDVMAP@("MEDICATIONPRODUCTNAMECODINGINGSYSTEM")=""
    5454   . S @MEDVMAP@("MEDICATIONPRODUCTNAMECODEVERSION")=""
    55    . S @MEDVMAP@("MEDICATIONBRANDNAMETEXT")=""
     55   . S @MEDVMAP@("MEDBRANDNAMETEXT")=""
    5656   . S @MEDVMAP@("MEDICATIONBRANDNAMECODEVALUE")=""
    5757   . S @MEDVMAP@("MEDICATIONBRANDNAMECODINGSYSTEM")=""
    5858   . S @MEDVMAP@("MEDICATIONBRANDNAMECODEVERSION")=""
    59    . S @MEDVMAP@("MEDICATIONSTRENGTHVALUE")=""
    60    . S @MEDVMAP@("MEDICATIONSTRENGTHUNIT")=""
    61    . S @MEDVMAP@("MEDICATIONFORMTEXT")=""
     59   . S @MEDVMAP@("MEDSTRENGTHVALUE")=""
     60   . S @MEDVMAP@("MEDSTRENGTHUNIT")=""
     61   . S @MEDVMAP@("MEDFORMTEXT")=""
     62   . S @MEDVMAP@("MEDQUANTITYVALUE")=""
     63   . S @MEDVMAP@("MEDQUANTITYUNIT")=""
     64   . S @MEDVMAP@("MEDRFNO")=""
    6265   . S @MEDVMAP@("MEDICATIONDESCRIPTIONTEXT")=$P(MEDRSLT(J+1)," *",2)
    63    . S @MEDVMAP@("MEDICATIONDIRECTIONDESCRIPTIONTEXT")=$P(MEDRSLT(J+2),"\ Sig: ",2)
     66   . S @MEDVMAP@("MEDDIRECTIONDESCRIPTIONTEXT")=$P(MEDRSLT(J+2),"\ Sig: ",2)
    6467   . S @MEDVMAP@("MEDICATIONDIRECTIONDOSEVALUE")=""
    6568   . S @MEDVMAP@("MEDICATIONDIRECTIONROUTETEXT")=""
  • ccr/trunk/p/GPLPROBS.m

    r89 r93  
    3535          . S @OUTXML@(0)=0
    3636          . ; Q
    37           ZWR RPCRSLT
     37          I DEBUG ZWR RPCRSLT
    3838          S TVMAP=$NA(^TMP("GPLCCR",$J,"PROBVALS"))
    3939          S TARYTMP=$NA(^TMP("GPLCCR",$J,"PROBARYTMP"))
     
    9898          . . . D CP^GPLXPATH("HTMLTMP","HTMLO")
    9999          . . . ; D INSINNER^GPLXPATH("HOUT","HTMLO","//")
    100           . D PARY^GPLXPATH("HTMLO")
     100          . I DEBUG D PARY^GPLXPATH("HTMLO")
    101101          . D INSB4^GPLXPATH(OUTXML,"HTMLO") ; INSERT AT TOP OF SECTION
    102102          N PROBSTMP,I
  • ccr/trunk/p/GPLVITALS.m

    r88 r93  
    166166          ; ZWR ^TMP($J,"VITALS",*)
    167167          ZWR ^TMP($J,"VITALARYTMP",*) ; SHOW THE RESULTS
    168           D PARY^GPLXPATH(VITOUTXML)
     168          I DEBUG D PARY^GPLXPATH(VITOUTXML)
    169169          N VITTMP,I
    170170          D MISSING^GPLXPATH(VITOUTXML,"VITTMP") ; SEARCH XML FOR MISSING VARS
Note: See TracChangeset for help on using the changeset viewer.