source: FOIAVistA/trunk/r/NOIS-FSC/FSCLMPNF.m@ 897

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

initial load of FOIAVistA 6/30/08 version

File size: 1.9 KB
Line 
1FSCLMPNF ;SLC/STAFF NOIS List Manager Protocol Notification Find ;1/13/98 12:58
2 ;;1.1;NOIS;;Sep 06, 1998
3 ;
4NOTIFY ; from FSCLMPN
5 N OK,TYPE,USER,USERNAME K ^TMP("FSC LIST",$J)
6 S USER=DUZ D USER(.USER,.USERNAME,.OK)
7 I 'OK Q
8 S TYPE="ONLY" D CALLS(.TYPE,USERNAME,.OK)
9 I 'OK Q
10 I TYPE="ALL" D ALL(USER)
11 I TYPE="ONLY" D ONLY(USER)
12 S FSCQUERY=1 S:FSCLNAME'["(MODIFIED)" FSCLNAME=FSCLNAME_" (MODIFIED)"
13 S VALMBG=1 K VALMQUIT D ENTRY^FSCLML I $D(VALMQUIT) S VALMBCK="Q" Q
14 D HEADER^FSCLML
15 Q
16 ;
17USER(USER,USERNAME,OK) ;
18 N DIC,X,Y K DIC S OK=0
19 S DIC=200,DIC(0)="AEMQ",DIC("A")="Notification user: ",DIC("B")=$$VALUE^FSCGET(USER,7100,2.1)
20 D ^DIC K DIC
21 I Y<1 Q
22 S USER=+Y,USERNAME=$P(Y,U,2),OK=1
23 Q
24 ;
25CALLS(TYPE,USERNAME,OK) ;
26 N DIR,X,Y K DIR S OK=0
27 S DIR(0)="SAMO^ALL:ALL;ONLY:ONLY"
28 S DIR("A")="Find (A)ll calls for "_USERNAME_" or (O)nly those calls on this list? ",DIR("B")=TYPE
29 S DIR("?",1)="Enter ALL to find all calls scheduled for this person."
30 S DIR("?",2)="Enter ONLY to find only those calls scheduled for this person"
31 S DIR("?",3)="that are on this list."
32 S DIR("?")="^D HELP^FSCU(.DIR)"
33 S DIR("??")="FSC U1 NOIS"
34 D ^DIR K DIR
35 I $D(DTOUT)!$D(DUOUT) Q
36 S TYPE=Y,OK=1
37 Q
38 ;
39ALL(USER) ; from FSCRPCN
40 N CALL,LNUM,NUM
41 S NUM=0 F S NUM=$O(^FSCD("NOTIFY","AUSER",USER,NUM)) Q:NUM<1 D
42 .S CALL=+$G(^FSCD("NOTIFY",NUM,0)) I 'CALL Q
43 .S ^TMP("FSC LIST",$J,CALL)=""
44 S LNUM=0 F S LNUM=$O(^FSC("LIST","C",USER,LNUM)) Q:LNUM<1 D
45 .S NUM=0 F S NUM=$O(^FSCD("NOTIFY","ALIST",LNUM,NUM)) Q:NUM<1 D
46 ..S CALL=+$G(^FSCD("NOTIFY",NUM,0)) I 'CALL Q
47 ..S ^TMP("FSC LIST",$J,CALL)=""
48 Q
49 ;
50ONLY(USER) ;
51 N CALL,DONE,LNUM
52 S CALL=0 F S CALL=$O(^TMP("FSC LIST CALLS",$J,"CX",CALL)) Q:CALL<1 D
53 .I $D(^FSCD("NOTIFY","ACUSER",CALL,USER)) S ^TMP("FSC LIST",$J,CALL)="" Q
54 .S (DONE,LNUM)=0 F S LNUM=$O(^FSCD("NOTIFY","ACLIST",CALL,LNUM)) Q:LNUM<1 D Q:DONE
55 ..I $D(^FSC("LIST","C",USER,LNUM)) S ^TMP("FSC LIST",$J,CALL)="",DONE=1
56 Q
Note: See TracBrowser for help on using the repository browser.