Ignore:
Timestamp:
May 17, 2012, 6:11:54 PM (12 years ago)
Author:
Sam Habiel
Message:

Update based on OHUM's latest routines

File:
1 edited

Legend:

Unmodified
Added
Removed
  • ccr/branches/ohum/p/C0CNMED4.m

    r1428 r1433  
    11C0CNMED4        ; WV/CCDCCR/SMH/gpl - CCR/CCD PROCESSING FOR MEDICATIONS - Inpatient Meds/Unit Dose ;10/13/08 ; 5/10/12 2:54pm
    2         ;;1.2;C0C;;May 11, 2012;Build 46
     2        ;;1.2;C0C;;May 11, 2012;Build 47
    33        ; Copyright 2008 WorldVistA.  Licensed under the terms of the GNU
    44        ; General Public License See attached copy of the License.
     
    6161        S MEDMAP=$NA(^TMP("C0CCCR",$J,"MEDMAP"))
    6262        ;N MEDCOUNT S MEDCOUNT=@MEDMAP@(0) ; We already have meds in the array
     63        S C0CMFLAG=$$GET^C0CPARMS("MEDALL")_"^"_$$GET^C0CPARMS("MEDLIMIT")_"^"_$$GET^C0CPARMS("MEDACTIVE")_"^"_$$GET^C0CPARMS("MEDPENDING") ;SETTING FLAG
    6364        N I S I=0
    6465        F  S I=$O(MEDS("med",I)) Q:'I  D  ; For each medication
     66        . ;OHUM/RUT 3120507 ;STATUS VALIDATION FOR INPATIENT
     67               . I ($P(C0CMFLAG,"^",1)'=1) D
     68               . . I ($P(C0CMFLAG,"^",3)=1)&(MEDS("med",I,"vaStatus@value")'="ACTIVE") D
     69               . . . K MEDS("med",I) Q
     70               . . I ($P(C0CMFLAG,"^",4)=1)&(MEDS("med",I,"vaStatus@value")'="PENDING") D
     71               . . . K MEDS("med",I) Q
     72               . ;OHUM/RUT
    6573        . N MED M MED=MEDS("med",I)
    6674        . I $G(MED("vaType@value"))'="I" Q  ; not inpatient
Note: See TracChangeset for help on using the changeset viewer.