source: FOIAVistA/trunk/r/SOCIAL_WORK-SOW-SWBH-SWFG/SOWKBC.m@ 1751

Last change on this file since 1751 was 628, checked in by George Lilly, 15 years ago

initial load of FOIAVistA 6/30/08 version

File size: 1.8 KB
Line 
1SOWKBC ;DLR/B'HAM ISC - Correct incomplete cases ; 10-10-95 [ 07/29/96 1:45 PM ]
2 ;;3.0; Social Work ;**39**;27 Apr 93
3 W !!,"This report will identify any incomplete Social Work cases.",!
4DEV K %ZIS,IOP,ZTSK S SOWKION=ION,%ZIS="QM",%ZIS("B")="" D ^%ZIS K %ZIS I POP S IOP=SOWKION D ^%ZIS K IOP,SOWKION G END
5 K SOWKION I $D(IO("Q")) S ZTDESC="SOCIAL WORK CASE CORRECTION",ZTRTN="BEGIN^SOWKBC" K IO("Q") D ^%ZTLOAD W:$D(ZTSK) !!,"Task Queued to Print",! K ZTSK G END
6BEGIN ;entry point to correct incomplete cases
7 N SOW,SW
8 W:$Y @IOF,!," Searching for incomplete cases "
9 S SW=0 F S SW=$O(^SOWK(650,SW)) Q:'SW W:$Y "." I $P(^SOWK(650,SW,0),U,13)="" S SOW(SW)=^(0)
10 I '$D(SOW) U IO W !!,"There were no incomplete cases found in your Social Work Case file."
11 I $D(SOW) D DISPLAY
12END ;end of routine
13 W:$E(IOST)'["C" @IOF D ^%ZISC
14 Q
15DISPLAY ;
16 N HDR
17 S HDR="Incomplete Case Information Report"
18 W:$Y @IOF W ?((IOM-$L(HDR))/2),HDR,!!
19 W !,"Case #",?15,"Social Work",?47,"CDC",! F X=1:1:75 W "-"
20 S SW=0 F S SW=$O(SOW(SW)) Q:'SW U IO W !,SW,?15,$S($D(^VA(200,$P(SOW(SW),U,3),0)):$E($P(^VA(200,$P(SOW(SW),U,3),0),U),1,20),1:"UNKNOWN"),?47,$S($P(SOW(SW),U,13)'="":$P(^SOWK(651,$P(SOW(SW),U,13),0),U),1:"UNKNOWN")
21 Q
22KIDS ;entry point to correct incomplete cases
23 N SOW,SW
24 W:$Y @IOF,!," Searching for incomplete cases "
25 S SW=0 F S SW=$O(^SOWK(650,SW)) Q:'SW W:$Y "." I $P(^SOWK(650,SW,0),U,13)="" S SOW(SW)=^(0)
26 I '$D(SOW) U IO W !!,"There were no incomplete cases found in your Social Work Case file."
27 I $D(SOW) D DISPLAY2
28 Q
29DISPLAY2 ;
30 N HDR,MSG
31 D BMES^XPDUTL("Incomplete Case Information Report....")
32 S SW=0 F S SW=$O(SOW(SW)) Q:'SW U IO S MSG="Case #"_SW_" for "_$S($D(^VA(200,$P(SOW(SW),U,3),0)):$E($P(^VA(200,$P(SOW(SW),U,3),0),U),1,20),1:"UNKNOWN")_" is incomplete." D MES^XPDUTL(MSG)
33 Q
Note: See TracBrowser for help on using the repository browser.