Invoices are fully paid, but the Payment Status field displays Partially Paid.

Salesforce Billing

Last updated 14 days ago ·Reference W-5217603 ·Reported By 18 users

In Review

Invoices that are fully paid will sometimes show the Payment Status field = 'Partially Paid'.

Enter a Payment Allocation against a posted $25.00 invoice for $24.99999. This will display as $25.00 on the UI for the Payment Allocation record. It will also show as $25.00 on the Invoice and in the developer console for the Invoice. It will show as 24.99999 in the developer console for the Payment Allocation record. This will also show the Invoice as Partially Paid.

Rather than reporting on or selecting on the field blng__PaymentStatus__c = 'Paid', you can use blng__Balance__c < 0.01.

Fixing the underlying record by just entering 25.00 is not possible due to a managed package validation on posted transactions. However, there is some code we have developed that can do this. To see the effect of the Half_Up rounding method, see this document:

The following code will update the Amount on the Payment Allocation by rounding up the value to 2 decimal places. Use your Payment Allocation record id instead of 'a3Uxxxxxxxxxxxx'
Please test in Sandbox first. Note that the 'disable' in the script is only for the current transaction and it will not effect other users/transactions.

list<blng__PaymentAllocationInvoiceLine__c> listofPaymentAllocation = [SELECT blng__Amount__c FROM blng__PaymentAllocationInvoiceLine__c WHERE Id = 'a3Uxxxxxxxxxxxx'];
for(blng__PaymentAllocationInvoiceLine__c pa : listofPaymentAllocation) {
pa.blng__Amount__c = pa.blng__Amount__c.setScale(2, System.RoundingMode.HALF_UP);
update listofPaymentAllocation;

Updated the workaround to provide a way to fix the underlying problem

Any unreleased services, features, statuses, or dates referenced in this or other public statements are not currently available and may not be delivered on time or at all. Customers who purchase our services should make their purchase decisions based upon features that are currently available.