source: FOIAVistA/trunk/r/MAILMAN-XM/XMXANSER.m@ 794

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

initial load of FOIAVistA 6/30/08 version

File size: 3.1 KB
Line 
1XMXANSER ;ISC-SF/GMB-Answer a msg ;04/24/2002 10:08
2 ;;8.0;MailMan;;Jun 28, 2002
3 ; Replaces ^XMA11A (ISC-WASH/CAP/THM)
4 ; XMDUZ DUZ of who the msg is from
5 ; XMSUBJ Subject of the msg (defaults to 'Re:' original subject)
6 ; XMBODY Closed root of Body of the msg
7 ; Must be closed root, passed by value. See WP_ROOT
8 ; definition for WP^DIE(), FM word processing filer.
9 ; XMTO Additional addressees, besides msg originator
10 ; XMINSTR("FROM") String saying from whom (default is user)
11 ; XMINSTR("SELF BSKT") Basket to deliver to if sender is recipient
12 ; XMINSTR("SHARE BSKT") Basket to deliver to if recipient is "SHARED,MAIL"
13 ; XMINSTR("SHARE DATE") Delete date if recipient is "SHARED,MAIL"
14 ; XMINSTR("RCPT BSKT") Basket name (only) to deliver to for other recipients
15 ; XMINSTR("VAPOR") Date on which to vaporize (delete) this message
16 ; from recipient baskets
17 ; XMINSTR("LATER") Date on which to send this msg, if not now
18 ; XMINSTR("FLAGS") Any or all of the following:
19 ; P Priority
20 ; I Information only (may not be replied to)
21 ; X Closed msg (may not be forwarded)
22 ; C Confidential (surrogates may not read)
23 ; S Send to sender (make sender a recipient)
24 ; R Confirm receipt
25 ; XMINSTR("SCR KEY") Scramble key (implies that msg should be scrambled)
26 ; XMINSTR("SCR HINT") Hint (to guess the scramble key)
27 ; XMINSTR("KEYS") List of keys needed by recipient to read msg (NOT IMPLEMENTED)
28 ; XMINSTR("TYPE") Msg type is one of the following:
29 ; D Document
30 ; S Spooled Document
31 ; X DIFROM
32 ; O ODIF
33 ; B BLOB
34 ; K KIDS
35 ;
36 ; Output:
37 ; XMZR The number of the message containing the answer.
38ANSRMSG(XMDUZ,XMK,XMKZ,XMSUBJ,XMBODY,XMTO,XMINSTR,XMZR) ;
39 N XMZ,XMZREC,XMZSENDR
40 K XMERR,^TMP("XMERR",$J)
41 D CHKMSG^XMXSEC1(XMDUZ,.XMK,.XMKZ,.XMZ,.XMZREC) Q:$D(XMERR)
42 Q:'$$ANSWER^XMXSEC(XMDUZ,XMZ,XMZREC)
43 S:$G(XMSUBJ)="" XMSUBJ=$E($$EZBLD^DIALOG(37006)_$P(XMZREC,U,1),1,65) ; Re:
44 D CRE8XMZ^XMXSEND(XMSUBJ,.XMZR) Q:$D(XMERR)
45 S XMZSENDR=$P(XMZREC,U,2)
46 S:XMZSENDR["@" XMZSENDR=$$REPLYTO1^XMXREPLY(XMZ)
47 D COMPOSE(XMDUZ,XMZ,$P(XMZREC,U,1),XMZSENDR,$P(XMZREC,U,3),XMZR,XMBODY)
48 S XMTO(XMZSENDR)=""
49 S XMINSTR("EXACT")=1 ; Match on exact domain name
50 D ADDRNSND^XMXSEND(XMDUZ,XMZR,.XMTO,.XMINSTR)
51 K XMINSTR("EXACT")
52 Q
53COMPOSE(XMDUZ,XMZ,XMZSUBJ,XMZSENDR,XMZDATE,XMZR,XMBODY) ;
54 D COPY(XMZ,XMZSUBJ,XMZSENDR,XMZDATE,XMZR)
55 ; File XMBODY, with the "append" option
56 D MOVEBODY^XMXSEND(XMZR,XMBODY,"A") ; Put the msg body in place
57 D NETSIG^XMXEDIT(XMDUZ,XMZR)
58 Q
59COPY(XMZO,XMZOSUBJ,XMZOFROM,XMZODATE,XMZ) ; Copy the original msg, putting ">" in front of each line.
60 N I,J
61 D COPYHEAD^XMJMC(XMZO,XMZOSUBJ,XMZOFROM,XMZODATE,XMZ,"A",.J)
62 S J=J+1,^XMB(3.9,XMZ,2,J,0)=">"
63 S I=.999999
64 F S I=$O(^XMB(3.9,XMZO,2,I)) Q:I="" S J=J+1,^XMB(3.9,XMZ,2,J,0)=$E(">"_^(I,0),1,254)
65 S J=J+1,^XMB(3.9,XMZ,2,J,0)=""
66 S J=J+1,^XMB(3.9,XMZ,2,J,0)=""
67 S ^XMB(3.9,XMZ,2,0)="^3.92A^"_J_U_J_U_DT
68 Q
Note: See TracBrowser for help on using the repository browser.