source: WorldVistAEHR/trunk/r/ACCOUNTS_RECEIVABLE-PRCA-PRY-RC/PRCAGD.m@ 1714

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

initial load of WorldVistAEHR

File size: 2.5 KB
RevLine 
[613]1PRCAGD ;WASH-ISC@ALTOONA,PA/CMS-Balance Discrepancy Message ;8/11/93 10:08 AM
2V ;;4.5;Accounts Receivable;;Mar 20, 1995
3 ;;Per VHA Directive 10-93-142, this routine should not be modified.
4 ;SEND (DEBTOR,BILL BALANCE,TRAN BAL,PREV BAL,REPRINT FLAG)
5EN(DEB,BBAL,TBAL,PBAL,BEG,REP) ;balance discrepancy, transmit mailman message
6 N NAM,SSN,XMSUB,XMDUZ,XMTEXT,XMY,X1,X,Y
7 S NAM=$$NAM^RCFN01(DEB),SSN=$$SSN^RCFN01(DEB),XMSUB=$E(NAM,1,16)_" ("_$E(NAM)_$E(SSN,6,9)_") Statement Balance Discrepancy",XMDUZ="AR Package",XMTEXT="X1("
8 I $D(^XMB(3.8,"B","PRCA ERROR")) S XMY("G.PRCA ERROR")=""
9 S Y=DT X ^DD("DD")
10 S X1(1)="***** NOTICE: Patient: "_NAM_" SSN: "_SSN_" statement was not",X1(2)="generated on "_Y_" because of a discrepancy in the account balances"
11 S X1(3)="between the patient statement balance and the Accounts Receivable balance.",X1(4)=""
12 S X1(5)="Accounts Receivable (bills) has a balance of: $ "_$J(BBAL,10,2)
13 S X1(6)="Patient Statement (*amount due) has a balance of: $ "_$J((TBAL+PBAL),10,2)
14 S X1(7)="The difference between these two balances is: $ "_$J((BBAL-(TBAL+PBAL)),10,2),X1(8)=""
15 S Y=BEG X ^DD("DD") S X1(9)="*Previous Statement balance $ "_$J(PBAL,0,2)_$S(Y'=0:"(all activity through "_Y_")",1:"")
16 S X1(10)=" + New Transactions $ "_$J(TBAL,0,2),X1(11)=""
17 S X1(12)="",X1(13)="PLEASE REVIEW ACCOUNT, CORRECT THE DISCREPANCY AND PRINT THE PATIENT'S STATEMENT"
18 S:$G(REP) X1(14)="",X1(15)="*** ERROR OCCURRED FROM USING THE PRINT PATIENT ***",X1(17)="*** STATEMENT/LETTERS OPTION ***"
19 S:'$D(XMY) XMY(.5)="" D ^XMD
20 Q
21REF(DEB,BN,REP) ;Print discrepancy because of unprocessed refund
22 N NAM,SSN,XMSUB,XMDUZ,XMTEXT,XMY,X1,X,Y
23 S NAM=$$NAM^RCFN01(DEB),SSN=$$SSN^RCFN01(DEB),XMSUB=$E(NAM,1,16)_" ("_$E(NAM)_$E(SSN,6,9)_") Statement Refund Discrepancy",XMDUZ="AR Package",XMTEXT="X1("
24 I $D(^XMB(3.8,"B","PRCA ERROR")) S XMY("G.PRCA ERROR")=""
25 S X1(1)="***** NOTICE: Patient: "_NAM_" SSN: "_SSN_" statement did not"
26 S Y=DT X ^DD("DD")
27 S X1(2)="print on "_Y_" because the unprocessed prepayment bill "_$P(^PRCA(430,BN,0),U,1)
28 S X1(3)="is in the status "_$P(^PRCA(430.3,$P(^PRCA(430,BN,0),U,8),0),U,1)_"!"
29 S X1(4)=" "
30 S X1(5)="Please complete the process of the prepayment bill then print the statement"
31 S X1(6)="using the Print Statements/Letters by Date option."
32 S:$G(REP) X1(7)="",X1(8)="*** ERROR OCCURRED FROM USING THE PRINT PATIENT ***",X1(9)="*** STATEMENT/LETTERS OPTION ***"
33 S:'$D(XMY) XMY(.5)="" D ^XMD
34 Q
Note: See TracBrowser for help on using the repository browser.