- FBFHLU ;OIFO/SAB-FPPS HL UTILITIES ;08/24/2003
- ;;3.5;FEE BASIS;**61**;JULY 18, 2003
- ;;Per VHA Directive 10-93-142, this routine should not be modified.
- Q
- ;
- PAYMETH(FBCKNO) ; payment method extrinsic function
- ; input
- ; FBCHNO - check number
- ; result is string value
- ; CC, EFT, CHK
- ;
- I $G(FBCKNO)="" Q "" ; no check number
- I $E(FBCKNO,1,2)="CC" Q "CC" ; credit card payment
- I $L(FBCKNO)<8 Q "EFT" ; electronic funds transfer
- Q "CHK" ; all other are paper check
- ;
- POST(FBAAIN,FBFLAG,FBMSG) ; Post Exception/Warning
- ; input
- ; FBAAIN - invoice number
- ; FBFLAG - flag (E or W) for (E)xception or (W)arning
- ; exceptions will prevent transmit of invoice to FPPS
- ; warnings will not prevent transmit
- ; FBMSG - text of message
- ;
- N FBI
- ; determine last seq number used for invoice
- S FBI=$O(^TMP($J,"FB"_FBFLAG,FBAAIN," "),-1)
- ; post new message
- S ^TMP($J,"FB"_FBFLAG,FBAAIN,FBI+1)=FBMSG
- Q
- ;
- STANO(FBBATCH) ; station number extrinsic function
- ; Input
- ; FBBATCH - ien of entry in FEE BASIS BATCH (#161.7) file
- ; Returns station number or NULL value
- ;
- N FBRET,FBY
- S FBRET=""
- I $G(FBBATCH) D
- . S FBY=$G(^FBAA(161.7,FBBATCH,0))
- . S FBRET=$$SUB^FBAAUTL5(+$P(FBY,U,8)_"-"_$P(FBY,U,2))
- . Q:FBRET]"" ; have value from IFCAP API
- . ; else get from Institution file based on fee site parameters
- . S FBRET=$$GET1^DIQ(161.4,"1,","27:99")
- Q FBRET
- ;
- LAST(FBAAIN) ; function to return last entry in file 163.5 for invoice
- ; input
- ; FBAAIN - invoice number
- ; result is string with ien of last entry in file or null
- N FBRET
- S FBRET=""
- I $G(FBAAIN) S FBRET=$O(^FBHL(163.5,"B",FBAAIN," "),-1)
- Q FBRET
- ;
- ;FBFHLU
- --- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HFBFHLU 1728 printed Mar 13, 2025@21:03:18 Page 2
- FBFHLU ;OIFO/SAB-FPPS HL UTILITIES ;08/24/2003
- +1 ;;3.5;FEE BASIS;**61**;JULY 18, 2003
- +2 ;;Per VHA Directive 10-93-142, this routine should not be modified.
- +3 QUIT
- +4 ;
- PAYMETH(FBCKNO) ; payment method extrinsic function
- +1 ; input
- +2 ; FBCHNO - check number
- +3 ; result is string value
- +4 ; CC, EFT, CHK
- +5 ;
- +6 ; no check number
- IF $GET(FBCKNO)=""
- QUIT ""
- +7 ; credit card payment
- IF $EXTRACT(FBCKNO,1,2)="CC"
- QUIT "CC"
- +8 ; electronic funds transfer
- IF $LENGTH(FBCKNO)<8
- QUIT "EFT"
- +9 ; all other are paper check
- QUIT "CHK"
- +10 ;
- POST(FBAAIN,FBFLAG,FBMSG) ; Post Exception/Warning
- +1 ; input
- +2 ; FBAAIN - invoice number
- +3 ; FBFLAG - flag (E or W) for (E)xception or (W)arning
- +4 ; exceptions will prevent transmit of invoice to FPPS
- +5 ; warnings will not prevent transmit
- +6 ; FBMSG - text of message
- +7 ;
- +8 NEW FBI
- +9 ; determine last seq number used for invoice
- +10 SET FBI=$ORDER(^TMP($JOB,"FB"_FBFLAG,FBAAIN," "),-1)
- +11 ; post new message
- +12 SET ^TMP($JOB,"FB"_FBFLAG,FBAAIN,FBI+1)=FBMSG
- +13 QUIT
- +14 ;
- STANO(FBBATCH) ; station number extrinsic function
- +1 ; Input
- +2 ; FBBATCH - ien of entry in FEE BASIS BATCH (#161.7) file
- +3 ; Returns station number or NULL value
- +4 ;
- +5 NEW FBRET,FBY
- +6 SET FBRET=""
- +7 IF $GET(FBBATCH)
- Begin DoDot:1
- +8 SET FBY=$GET(^FBAA(161.7,FBBATCH,0))
- +9 SET FBRET=$$SUB^FBAAUTL5(+$PIECE(FBY,U,8)_"-"_$PIECE(FBY,U,2))
- +10 ; have value from IFCAP API
- if FBRET]""
- QUIT
- +11 ; else get from Institution file based on fee site parameters
- +12 SET FBRET=$$GET1^DIQ(161.4,"1,","27:99")
- End DoDot:1
- +13 QUIT FBRET
- +14 ;
- LAST(FBAAIN) ; function to return last entry in file 163.5 for invoice
- +1 ; input
- +2 ; FBAAIN - invoice number
- +3 ; result is string with ien of last entry in file or null
- +4 NEW FBRET
- +5 SET FBRET=""
- +6 IF $GET(FBAAIN)
- SET FBRET=$ORDER(^FBHL(163.5,"B",FBAAIN," "),-1)
- +7 QUIT FBRET
- +8 ;
- +9 ;FBFHLU