source: WorldVistAEHR/trunk/r/LIBRARY-LBR-LBRS/LBRYSEND.m@ 1604

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

initial load of WorldVistAEHR

File size: 1.7 KB
Line 
1LBRYSEND ;SSI/ALA - SEND TRANSACTIONS TO FORUM ;[ 04/19/2000 10:44 AM ]
2 ;;2.5;LIBRARY;**8,11**;Mar 11, 1996
3 ;
4 K ^TMP("LBRY")
5 S STN=$P(^DIC(4,$P(^XMB(1,1,"XUS"),U,17),99),U),REF=" "
6 ;
7 S N=""
8 F S N=$O(^LBRY(682.1,"AC","W",N)) Q:N="" D
9 . S LBRYTYP=$$GET1^DIQ(682.1,N,1,"E")
10 . D CR
11 K N,IN,J,M,NUM,REF,STN,JDT,JTM
12 Q
13 ;
14CR ; Create UTILITY global for transaction
15 S JDTM=$$NOW^XLFDT(),NUM=10000
16 S JDT=$$JDN^LBRYUTL($P(JDTM,".")),JTM=$P(JDTM,".",2) K JDTM
17 S ^TMP("LBRY",NUM,0)="LIB^"_STN_"^^"_LBRYTYP_U_JDT_U_JTM_U_REF_"^001^001^001^|"
18 ;
19 ; If LTF
20 I LBRYTYP="LTF" D
21 . S M=0 D NN
22 ;
23 Q
24 ;
25NN S M=$O(^LBRY(682.1,N,M))
26 I M'>0 S NUM=NUM+1,^TMP("LBRY",NUM,0)="$",XMSUB="LOCAL SERIAL TITLE REQUEST" D XM Q
27 I M<6,$G(^LBRY(682.1,N,M))'="" D
28 . S IN=$S(M=1:"TI",1:"T"_M)
29 . S NUM=NUM+1,^TMP("LBRY",NUM,0)=IN_U_^LBRY(682.1,N,M)
30 . I M=1 S $P(^TMP("LBRY",NUM,0),U,6,7)=N
31 I M=6,$D(^LBRY(682.1,N,M))'=0 D
32 . S IN="T5",J=0 F S J=$O(^LBRY(682.1,N,M,J)) Q:J'>0 S NUM=NUM+1,^TMP("LBRY",NUM,0)=IN_U_J_U_^LBRY(682.1,N,M,J,0)
33 I M=7,$D(^LBRY(682.1,N,M))'=0 D
34 . S IN="T6",J=0 F S J=$O(^LBRY(682.1,N,M,J)) Q:J="" S NUM=NUM+1,^TMP("LBRY",NUM,0)=IN_U_J_U_^LBRY(682.1,N,M,J,0)
35 G NN
36 ;
37XM ; Take all transactions waiting for transmission and pass
38 ; them to MailMan for transmission to FORUM
39 S TRNSM=$S($G(^XMB("NETNAME"))["SENTIENT":"VISTA.SENTIENTCONSULT.COM",1:"FORUM.VA.GOV")
40 S XMDUZ=^XMB("NETNAME"),XMY("S.LBRYFSRV@"_TRNSM)=""
41 S XMTEXT="^TMP(""LBRY"","
42 D ^XMD
43 ;
44 ; Delete messages
45 I XMZ'<1 D ; If message # returns from last send - then delete it.
46 .S XMSER="S.LBRYSRV" D REMSBMSG^XMA1C K XMSER
47 ;
48 S DIC="^LBRY(682.1,",DIE=DIC,DA=N,DR="2///^S X=""T""" D ^DIE
49 K ^TMP("LBRY"),TRNSM,XMZ
50 Q
Note: See TracBrowser for help on using the repository browser.