source: WorldVistAEHR/trunk/r/PHARMACY_BENEFITS_MANAGEMENT-PSU/PSUAA2.m@ 1361

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

initial load of WorldVistAEHR

File size: 1.4 KB
RevLine 
[613]1PSUAA2 ;BIR/RDC - ALLERGY/ADVERSE EVENT Mail Messages; 23 FEB 2004
2 ;;4.0;PHARMACY BENEFITS MANAGEMENT;;MARCH, 2005
3 ;
4 ; Reference to file #4.3 supported by DBIA 2496
5 ;
6EN1 ;ENtry point for ALLERGY/ADVERSE EVENT Mail Message
7 ;
8 S DOMSG=""
9 S XMCHAN=1
10 S XMDUZ=DUZ
11 S MSGTOT=$G(^XTMP("PSU_"_PSUJOB,"PSUAA","MSGTCNT"))
12 S:MSGTOT="" MSGTOT=1
13 S LINECNT=$G(^XTMP("PSU_"_PSUJOB,"PSUAA","LINECNT"))
14 S:LINECNT=0 LINECNT=1
15 ; ** SET THE HEADER DATA
16 S X=$$VALI^PSUTL(4.3,1,217)
17 S PSUVFAC=+$$VAL^PSUTL(4,X,99)
18 ;
19 S X=PSUVFAC,DIC=40.8,DIC(0)="X",D="C" D IX^DIC
20 S X=+Y S PSUVDIV=$$VAL^PSUTL(40.8,X,.01)
21 ;
22 I $G(PSUMASF)!$G(PSUDUZ)!$G(PSUPBMG) S DOMSG=1 D
23 . I '$D(^XTMP("PSU_"_PSUJOB,"PSUAA","MSGTCNT")) D Q ; quit - no data
24 .. S CURMSG=1
25 .. S XMSUB="V. 4.0 PBMAA"_" "_PSUMON_" "_CURMSG_"/"_MSGTOT_" "_PSUVFAC_" "_PSUVDIV
26 .. S ^XTMP("PSU_"_PSUJOB,"PSUAA","ERR",1)="No data to report"
27 .. S XMTEXT="^XTMP(""PSU_"_PSUJOB_""",""PSUAA"",""ERR"","
28 .. M XMY=PSUXMYS1
29 .. D ^XMD
30 . ; ** there are messages - send them **
31 . F CURMSG=1:1:MSGTOT D
32 .. S XMSUB="V. 4.0 PBMAA"_" "_PSUMON_" "_CURMSG_"/"_MSGTOT_" "_PSUVFAC_" "_PSUVDIV
33 .. S XMTEXT="^XTMP(""PSU_"_PSUJOB_""",""PSUAA"","_CURMSG_","
34 .. M XMY=PSUXMYH
35 .. D ^XMD
36 I DOMSG D ; ** CONFIRMATION MESSAGE **
37 . S ^XTMP("PSU_"_PSUJOB,"CONFIRM",PSUVFAC,11,"L")=LINECNT
38 . S ^XTMP("PSU_"_PSUJOB,"CONFIRM",PSUVFAC,11,"M")=MSGTOT
39 ;
40 Q
41 ;
Note: See TracBrowser for help on using the repository browser.