Error when validating payment

I think this is a bug.

When I go to pay a supplier invoice and insert the value I was billed by the supplier in the ‘Payment amount, original currency’ form text field the value is checked against the equivalent value in euros and throws an error stating:

Attention, the payment amount of one or more bills is higher then the outstanding amount to pay.
Edit your entry, otherwise confirm and consider creating a credit note for the excess received for each overpaid invoice.

For example I have an invoice of let’s say 1000 dollars to pay. The equivalent in Euros is 938.
When I input the value 1000 in the original currency place the error is triggered.

When I input 938 in the same field the error is not triggered.

Any help?

OK I just went after this error and in file:
htdocs\fourn\facture\paiement.php

on line 186 where it says

$multicurrency_amountsresttopay[$cursorfacid] = price2num($tmpinvoice->total_ttc - $tmpinvoice->getSommePaiement(1));

it should read

$multicurrency_amountsresttopay[$cursorfacid] = price2num($tmpinvoice->multicurrency_total_ttc - $tmpinvoice->getSommePaiement(1));

This is on Dolibarr version 15.0.1

Would someone put this on github and make this change please if it has not been resolved yet in the newer versions?
I don’t know how to do that.

Has this been done already?

Hello,

Thanks for solution.

I have created the issue on GitHub : BUG : Error when validating supplier payment · Issue #21772 · Dolibarr/dolibarr · GitHub
And the FIX : FIX #21772 by ksar-ksar · Pull Request #21773 · Dolibarr/dolibarr · GitHub

1 Like