[613] | 1 | RCDPDPLU ;WISC/RFJ-deposit profile utilities ;1 Jun 99
|
---|
| 2 | ;;4.5;Accounts Receivable;**114,173**;Mar 20, 1995
|
---|
| 3 | ;;Per VHA Directive 10-93-142, this routine should not be modified.
|
---|
| 4 | Q
|
---|
| 5 | ;
|
---|
| 6 | ;
|
---|
| 7 | CHECKDEP(DEPTDA) ; check the deposit to stop edit/change if approved
|
---|
| 8 | ; return 0^message to stop edit/change
|
---|
| 9 | ; 1 to continue
|
---|
| 10 | N MESSAGE,RECTDA,RESULT
|
---|
| 11 | ;
|
---|
| 12 | ; already confirmed, status = 3 confirmed
|
---|
| 13 | I $P($G(^RCY(344.1,DEPTDA,0)),"^",12)=3 Q "0^Deposit has been confirmed."
|
---|
| 14 | ; lockbox
|
---|
| 15 | S RECTDA=$O(^RCY(344,"AD",$P(^RCY(344.1,DEPTDA,0),"^"),0))
|
---|
| 16 | I RECTDA,$P($G(^RC(341.1,+$P($G(^RCY(344,RECTDA,0)),"^",4),0)),"^",2)=12 Q "0^Lockbox type deposit."
|
---|
| 17 | I RECTDA,$$EDILB^RCDPEU(RECTDA)=1 Q "0^EDI Lockbox type deposit."
|
---|
| 18 | ; open
|
---|
| 19 | Q 1
|
---|
| 20 | ;
|
---|
| 21 | ;
|
---|
| 22 | LOCKDEP(DEPTDA) ; lock the deposit, call only from listmanager options
|
---|
| 23 | ; if deposit not passed, return 2
|
---|
| 24 | I 'DEPTDA Q 2
|
---|
| 25 | N RESULT
|
---|
| 26 | S RESULT=1
|
---|
| 27 | L +^RCY(344.1,DEPTDA):5
|
---|
| 28 | I '$T D
|
---|
| 29 | . S VALMSG="Another user is editing the deposit."
|
---|
| 30 | . D WRITE^RCDPRPLU(VALMSG)
|
---|
| 31 | . S RESULT=0
|
---|
| 32 | Q RESULT
|
---|
| 33 | ;
|
---|
| 34 | ;
|
---|
| 35 | MAILMSG(RCDEPTDA,ACTION) ; mail a message to supervisor key holders
|
---|
| 36 | N %,LINE,VALMHDR,VALMSG,XMDUZ,XMZ,YY
|
---|
| 37 | K ^TMP($J,"RCDPDPLU")
|
---|
| 38 | S LINE=0
|
---|
| 39 | ;
|
---|
| 40 | ; ---- start build mailman message ----
|
---|
| 41 | D SETLINE("Sent to: PRCAY PAYMENT SUP security key holders")
|
---|
| 42 | D SETLINE(" ")
|
---|
| 43 | ;
|
---|
| 44 | ; build the header line
|
---|
| 45 | D HDR^RCDPDPLM
|
---|
| 46 | F %=1:1 Q:'$D(VALMHDR(%)) D SETLINE(VALMHDR(%))
|
---|
| 47 | ;
|
---|
| 48 | D SETLINE(" ")
|
---|
| 49 | D SETLINE("This deposit was confirmed and the following action occurred:")
|
---|
| 50 | D SETLINE(" ACTION: "_ACTION)
|
---|
| 51 | D SETLINE(" BY: "_$P(^VA(200,DUZ,0),"^"))
|
---|
| 52 | ; ---- end build mailman message ----
|
---|
| 53 | ;
|
---|
| 54 | S XMSUB="Deposit Processing Audit"
|
---|
| 55 | S XMDUZ="Accounts Receivable Package"
|
---|
| 56 | S XMTEXT="^TMP($J,""RCDPDPLU"","
|
---|
| 57 | S %=0 F S %=$O(^XUSEC("PRCAY PAYMENT SUP",%)) Q:'% S XMY(%)=""
|
---|
| 58 | D ^XMD
|
---|
| 59 | K ^TMP($J,"RCDPDPLU")
|
---|
| 60 | Q
|
---|
| 61 | ;
|
---|
| 62 | ;
|
---|
| 63 | SETLINE(MESSAGE) ; set the line for the mail message
|
---|
| 64 | S LINE=LINE+1
|
---|
| 65 | S ^TMP($J,"RCDPDPLU",LINE)=MESSAGE
|
---|
| 66 | Q
|
---|