Fix var not initialized
This commit is contained in:
parent
46e8692620
commit
07fb29f0c4
@ -937,8 +937,6 @@ class Invoices extends DolibarrApi
|
|||||||
throw new RestException(401, 'Access not allowed for login '.DolibarrApiAccess::$user->login);
|
throw new RestException(401, 'Access not allowed for login '.DolibarrApiAccess::$user->login);
|
||||||
}
|
}
|
||||||
|
|
||||||
$request_data = (object) $payment_data;
|
|
||||||
|
|
||||||
if (! empty($conf->banque->enabled)) {
|
if (! empty($conf->banque->enabled)) {
|
||||||
if(empty($accountid)) {
|
if(empty($accountid)) {
|
||||||
throw new RestException(400, 'Account ID is mandatory');
|
throw new RestException(400, 'Account ID is mandatory');
|
||||||
@ -962,6 +960,10 @@ class Invoices extends DolibarrApi
|
|||||||
$resteapayer = price2num($this->invoice->total_ttc - $totalpaye - $totalcreditnotes - $totaldeposits, 'MT');
|
$resteapayer = price2num($this->invoice->total_ttc - $totalpaye - $totalcreditnotes - $totaldeposits, 'MT');
|
||||||
|
|
||||||
$this->db->begin();
|
$this->db->begin();
|
||||||
|
|
||||||
|
$amounts = array();
|
||||||
|
$multicurrency_amounts = array();
|
||||||
|
|
||||||
// Clean parameters amount if payment is for a credit note
|
// Clean parameters amount if payment is for a credit note
|
||||||
if ($this->invoice->type == Facture::TYPE_CREDIT_NOTE) {
|
if ($this->invoice->type == Facture::TYPE_CREDIT_NOTE) {
|
||||||
$resteapayer = price2num($resteapayer,'MT');
|
$resteapayer = price2num($resteapayer,'MT');
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user