source: FOIAVistA/trunk/r/IFCAP-PRC-PRX--PRCA--PRCN/PRCOVUP2.m@ 1671

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

initial load of FOIAVistA 6/30/08 version

File size: 1.5 KB
Line 
1PRCOVUP2 ;WCAMPUS/-GENERATE MAIL MESSAGE AT END OF CONVERSION ;3/22/95
2 ;;5.1;IFCAP;;Oct 20, 2000
3 ;Per VHA Directive 10-93-142, this routine should not be modified.
4 ;create a message at completion of the vendor upload
5 ;the message will summerize the number of active
6 ;vendors on file and the number that converted
7 ;
8 D:'$D(DT) DT^DICRW ;set DT if undef
9 ;
10 ;PRVTOT = total number of active vendors in last 2 years
11 ;PRVFMS = total number of active vendors that converted(fms code)
12 N I,J,PRVIEN,PRVTOT,PRVFMS,PRVTXT
13 S I=$$FMADD^XLFDT(DT,-730) ;date two years ago from today
14 F S I=$O(^PRC(442,"AB",I)) Q:'I D
15 . S J=0 F S J=$O(^PRC(442,"AB",I,J)) Q:'J S PRVIEN=+$G(^PRC(442,J,1)) I PRVIEN D
16 .. I $D(^PRC(440,PRVIEN,0)) S:'$D(^TMP($J,"PRCOVUP1",PRVIEN)) ^(PRVIEN)=""
17 ; ^TMP($J,"PRCOVUP1",PRVIEN) is the active vendors used last 2 yrs
18 ;
19 S (PRVTOT,PRVFMS)=0
20 S I=0 F S I=$O(^TMP($J,"PRCOVUP1",I)) Q:'I S PRVTOT=PRVTOT+1 D
21 . I $P($G(^PRC(440,I,3)),U,4)]"" S PRVFMS=PRVFMS+1
22 ;
23 S PRVTXT(1)="IFCAP Vendor conversion has run to completion."
24 S PRVTXT(2)=" Summary Statistics"
25 S PRVTXT(3)=" Total number of active vendors on file : "_PRVTOT
26 S PRVTXT(4)=" Total number of active vendors converted : "_PRVFMS
27 ;generate mail message vendor upload complete and give stats
28 S PRCMG=$S('$D(PRCMG):.5,$E(PRCMG,1,2)'="G.":"G."_PRCMG,1:.5)
29 S XMY(PRCMG)="",XMDUZ=.5
30 S XMSUB="IFCAP VENDOR CONVERSION SUMMARY"
31 S XMTEXT="PRVTXT("
32 D ^XMD
33 K XMDUZ,XMSUB,XMY,^TMP($J,"PRCOVUP1")
34 Q
Note: See TracBrowser for help on using the repository browser.