Home   Package List   Routine Alphabetical List   Global Alphabetical List   FileMan Files List   FileMan Sub-Files List   Package Component Lists   Package-Namespace Mapping  
Routine: ACDWCD4

ACDWCD4.m

Go to the documentation of this file.
ACDWCD4 ;IHS/ADC/EDE/KML - CLIENT DET OP FOR INTERVENTIONS 10:11;
 ;;4.1;CHEMICAL DEPENDENCY MIS;;MAY 11, 1998
 ;*********************************************************************
 ;//^ACDWDRV3, ^ACDWIIF
 ;*********************************************************************
 ;S ACDP1="" F  S ACDP1=$O(^TMP("ACD",ACDJOB,ACDBT,ACDTGSUB,"VAL",ACDP1)) Q:ACDP1=""  F ACDP2=0:0 S ACDP2=$O(^TMP("ACD",ACDJOB,ACDBT,ACDTGSUB,"VAL",ACDP1,ACDP2)) Q:'ACDP2  S ACDDA=ACDP2 D ^ACDWCINV D P1
 S ACDP1=""
 F  S ACDP1=$O(^TMP("ACD",ACDJOB,ACDBT,ACDTGSUB,"VAL",ACDP1)) Q:ACDP1=""  D  Q:$D(DIRUT)
 . F ACDP2=0:0 S ACDP2=$O(^TMP("ACD",ACDJOB,ACDBT,ACDTGSUB,"VAL",ACDP1,ACDP2)) Q:'ACDP2  S ACDDA=ACDP2 D ^ACDWCINV D P1 Q:$D(DIRUT)
 . Q
 D ^ACDWK Q
P1 ;Output
 D F W !,"CLIENT NAME:",?40,ACDDFN
 D F W !,"  VETERAN STATUS:",?40,ACDVET
 D F W !,"  AGE/SEX:",?40,$S($G(ACDAGE)'="":ACDAGE,1:"UNKNOWN - ")," YEARS OLD  / ",ACDSEX
 S ACDTRIBN=$O(^AUTTTRI("C",ACDTRIB,0)) I ACDTRIBN S ACDTRIBN=$P(^AUTTTRI(ACDTRIBN,0),U)
 S ACDSTATN=$O(^DIC(5,"C",ACDSTATE,0)) I ACDSTATN S ACDSTATN=$P(^DIC(5,ACDSTATN,0),U)
 D F W !,"  STATE/STATE CODE:",?40,$S($G(ACDSTATN)'="":$E(ACDSTATN,1,35),1:"UNKNOWN")," / ",ACDSTATE
 D F W !,"  TRIBE/TRIBE CODE",?40,$S($G(ACDTRIBN)'="":$E(ACDTRIBN,1,35),1:"UNKNOWN")," / ",ACDTRIB
 D F W !!,"VISIT DATE:",?40,ACDCLIV
 D F W !,"COMPONENT:",?40,ACDCOMCL," / ",ACDCOMTL
 D F W !,"INTERVENTION MEMBERS:" S ACDLP="" F  D F S ACDLP=$O(ACDPROVA(ACDLP)) Q:ACDLP=""  W ?40,ACDLP,!
 D F W !!,"PRIMARY PROBLEM:",?40,ACDPROBP
 D F W !,"OTHER PROBLEMS:" S ACDLP="" F  D F S ACDLP=$O(ACDPTA(ACDLP)) Q:ACDLP=""  W ?40,ACDLP,!
 D F W !!,"SUICIDE HISTORY:",?40,ACDINVSH
XXX ;
 D F W !!,"RECOMMENDED PLACEMENT:",?40,ACDPLAR_" / "_ACDPLAR1
 D F W !,"ACTUAL PLACEMENT:",?40,ACDPLAA_" / "_ACDPLAA1
 D F W !,"DIFFERENCE REASON:",?40,ACDDIF
 D F W !,"PLACEMENT PROGRAM: ",?40,ACDINVPP
 D F W !,"COST ($$$): ",?40,ACDINVCT
 D F W !,"TOTAL DAYS OF TREATMENT:",?40,ACDINVTD
 D F W !,"TREATMENT COMPLETE:",?40,ACDINVTC
 W !!,"..........................................",!
 ;
 Q
F ;Form feed
 Q:$D(DIRUT)
 I $Y+4>IOSL D F^ACDWUTL