Fix missing amount in table of prelevement
This commit is contained in:
parent
ccced09113
commit
21d9b00fce
@ -325,7 +325,7 @@ class Stripe extends CommonObject
|
|||||||
*/
|
*/
|
||||||
public function getPaymentIntent($amount, $currency_code, $tag, $description = '', $object = null, $customer = null, $key = null, $status = 0, $usethirdpartyemailforreceiptemail = 0, $mode = 'automatic', $confirmnow = false, $payment_method = null, $off_session = 0, $noidempotency_key = 0)
|
public function getPaymentIntent($amount, $currency_code, $tag, $description = '', $object = null, $customer = null, $key = null, $status = 0, $usethirdpartyemailforreceiptemail = 0, $mode = 'automatic', $confirmnow = false, $payment_method = null, $off_session = 0, $noidempotency_key = 0)
|
||||||
{
|
{
|
||||||
global $conf;
|
global $conf, $user;
|
||||||
|
|
||||||
dol_syslog("getPaymentIntent", LOG_INFO, 1);
|
dol_syslog("getPaymentIntent", LOG_INFO, 1);
|
||||||
|
|
||||||
@ -486,8 +486,8 @@ class Stripe extends CommonObject
|
|||||||
if (!$paymentintentalreadyexists)
|
if (!$paymentintentalreadyexists)
|
||||||
{
|
{
|
||||||
$now = dol_now();
|
$now = dol_now();
|
||||||
$sql = "INSERT INTO ".MAIN_DB_PREFIX."prelevement_facture_demande (date_demande, fk_user_demande, ext_payment_id, fk_facture, sourcetype, entity, ext_payment_site)";
|
$sql = "INSERT INTO ".MAIN_DB_PREFIX."prelevement_facture_demande (date_demande, fk_user_demande, ext_payment_id, fk_facture, sourcetype, entity, ext_payment_site, amount)";
|
||||||
$sql .= " VALUES ('".$this->db->idate($now)."', '0', '".$this->db->escape($paymentintent->id)."', ".$object->id.", '".$this->db->escape($object->element)."', ".$conf->entity.", '".$service."')";
|
$sql .= " VALUES ('".$this->db->idate($now)."', ".$user->id.", '".$this->db->escape($paymentintent->id)."', ".$object->id.", '".$this->db->escape($object->element)."', ".$conf->entity.", '".$service."', ".$amount.")";
|
||||||
$resql = $this->db->query($sql);
|
$resql = $this->db->query($sql);
|
||||||
if (!$resql)
|
if (!$resql)
|
||||||
{
|
{
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user