source: WorldVistAEHR/trunk/r/NOIS-FSC/FSCNMS.m@ 846

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

initial load of WorldVistAEHR

File size: 1.8 KB
Line 
1FSCNMS ;SLC/STAFF NOIS Notification Mail Send ;1/13/98 13:55
2 ;;1.1;NOIS;;Sep 06, 1998
3 ;
4MAIL(XMSUB) ; from FSCLMPNN
5 Q:'$D(XMSUB) I XMSUB[U S XMSUB=$$REPLACE^FSCRU(XMSUB,U,"~U~")
6 N CNT,DIR,LINE,XMTEXT,XMY,Y K DIR,XMY,XMZ,^TMP("FSC MAIL",$J),^TMP("FSC TEXT",$J)
7 S DIR(0)="YAO",DIR("A")="Do you want to load the list document into the message? ",DIR("B")="NO"
8 S DIR("?",1)="Enter YES to load the display into the message."
9 S DIR("?",2)="Enter NO to just send a message without the display."
10 S DIR("?",3)="When loading the display into the message, you can later edit the message"
11 S DIR("?",4)="before sending. Be aware that displays may have edited information."
12 S DIR("?")="^D HELP^FSCU(.DIR)"
13 S DIR("??")="FSC U1 NOIS"
14 D ^DIR K DIR
15 I $D(DIRUT) Q
16 D
17 .I Y D Q
18 ..S ^TMP("FSC MAIL",$J,1,0)=" "
19 ..S ^TMP("FSC MAIL",$J,2,0)=" *** NOIS INFORMATION ***"
20 ..S CNT=2 I $G(FSCCALLS)="EVALUES" S ^TMP("FSC MAIL",$J,3,0)=$G(VALMHDR(1)),CNT=3
21 ..S LINE=0 F S LINE=$O(@VALMAR@(LINE)) Q:LINE<1 S CNT=CNT+1,^TMP("FSC MAIL",$J,CNT,0)=^(LINE,0)
22 ..D EDITWP^FSCEU("^TMP(""FSC MAIL"",$J)","You may edit this message.")
23 .D WP^FSCEU("MAIL","Enter your mail message.")
24 S XMTEXT=""
25 I $O(^TMP("FSC MAIL",$J,0)) S XMTEXT="^TMP(""FSC MAIL"",$J,"
26 I $O(^TMP("FSC TEXT",$J,"MAIL",0)) S XMTEXT="^TMP(""FSC TEXT"",$J,""MAIL"","
27 I '$L(XMTEXT) Q
28 D EN^XM W !,"This message will be sent to you." S XMY(DUZ)="" D DES^XMA21
29 I '$D(XMY) Q
30 N DIR,Y K DIR
31 S DIR(0)="YAO",DIR("A")="Send notification message: ",DIR("B")="YES"
32 S DIR("?",1)="Enter YES to send this message."
33 S DIR("?",2)="Enter NO or '^' to exit without sending the message, '??' for more help."
34 S DIR("?")="^D HELP^FSCU(.DIR)"
35 S DIR("??")="FSC U1 NOIS"
36 D ^DIR K DIR
37 I $D(DIRUT) Q
38 I Y'=1 Q
39 D ^XMD I $G(XMZ) W !,"Message #",XMZ," sent." H 2
40 D KILL^XM K ^TMP("FSC MAIL",$J),^TMP("FSC TEXT",$J)
41 Q
Note: See TracBrowser for help on using the repository browser.