source: FOIAVistA/trunk/r/SPINAL_CORD_DYSFUNCTION-SPN/SPNPSR26.m@ 1397

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

initial load of FOIAVistA 6/30/08 version

File size: 1.5 KB
Line 
1SPNPSR26 ;SAN/WDE/Next Annual Rehab Eval filter 5-19-99
2 ;;2.0;Spinal Cord Dysfunction;**11**;01/02/1997
3 ;
4EN1(D0,BDATE,EDATE) ; *** Search entry point
5 ; Next annual rehab eval due up-front filter
6 ; Input:
7 ; ACTION,SEQUENCE = Search ACTION,SEQUENCE number
8 ; D0 = SCD (SPINAL CORD) REGISTRY file (#154) IEN
9 ; ^TMP($J,"SPNPRT",ACTION,SEQUENCE,"BEGINNING DATE") = Date ^ Date_(Ext)
10 ; ^TMP($J,"SPNPRT",ACTION,SEQUENCE,"ENDING DATE") = Date ^ Date_(Ext)
11 ; BDATE = Beginning date
12 ; EDATE = Ending date
13 ; Output:
14 ; $S( D0_Meets_Search_Criteria : 1 , 1 : 0 )
15 ;
16 N DATE,MEETSRCH
17 S MEETSRCH=0
18 S DATE("BEG")=BDATE
19 S DATE("END")=EDATE
20 S SPNY=0 F S SPNY=$O(^SPNL(154,D0,"REHAB",SPNY)) Q:(SPNY="")!('+SPNY) D Q:MEETSRCH=1
21 . S DATE("EVAL")=$P($G(^SPNL(154,D0,"REHAB",SPNY,0)),U,3)
22 . S MEETSRCH=$S(DATE("EVAL")<DATE("BEG"):0,DATE("EVAL")>DATE("END"):0,1:1) Q:MEETSRCH=1
23 Q MEETSRCH
24 ;
25EN2(ACTION,SEQUENCE) ; *** Prompt entry point
26 ; Input:
27 ; ACTION,SEQUENCE = Search ACTION,SEQUENCE number
28 ; Output:
29 ; SPNLEXIT = $S( User_Abort/Timeout : 1 , 1 : 0 )
30 ; ^TMP($J,"SPNPRT",ACTION,SEQUENCE,"BEGINNING DATE") = Date ^ Date_(Ext)
31 ; ^TMP($J,"SPNPRT",ACTION,SEQUENCE,"ENDING DATE") = Date ^ Date_(Ext)
32 ; ^TMP($J,"SPNPRT",ACTION,SEQUENCE,0) = $$EN1^SPNPSR26(D0,BDATE,EDATE)
33 ;
34 K ^TMP($J,"SPNPRT",ACTION,SEQUENCE)
35 S (BDATE,EDATE)=""
36 D EN1^SPNPSR00(ACTION,SEQUENCE,.BDATE,.EDATE)
37 I $G(BDATE)'="" I $G(EDATE)'="" S ^TMP($J,"SPNPRT",ACTION,SEQUENCE,0)="$$EN1^SPNPSR26(D0,"_BDATE_","_EDATE_")"
38 Q
Note: See TracBrowser for help on using the repository browser.