mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-02-20 13:46:52 +01:00
Fix: id is lost
This commit is contained in:
parent
1a90eefb86
commit
7148eb584c
|
|
@ -3,7 +3,7 @@
|
|||
* Copyright (C) 2003 Jean-Louis Bergamo <jlb@j1b.org>
|
||||
* Copyright (C) 2004-2010 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copytight (C) 2004 Christophe Combelles <ccomb@free.fr>
|
||||
* Copytight (C) 2005-2009 Regis Houssin <regis@dolibarr.fr>
|
||||
* Copytight (C) 2005-2010 Regis Houssin <regis@dolibarr.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@ if ($_POST["action"] == 'add_paiement')
|
|||
|
||||
if (! $error)
|
||||
{
|
||||
$paiement_id = 0;
|
||||
$paymentid = 0;
|
||||
|
||||
// Read possible payments
|
||||
$amounts = array();
|
||||
|
|
@ -90,9 +90,9 @@ if ($_POST["action"] == 'add_paiement')
|
|||
$paiement->paiementtype = $_POST["paiementtype"];
|
||||
$paiement->num_paiement = $_POST["num_paiement"];
|
||||
$paiement->note = $_POST["note"];
|
||||
$paiement_id = $paiement->create($user);
|
||||
$paymentid = $paiement->create($user);
|
||||
|
||||
if ($paiement_id > 0)
|
||||
if ($paymentid > 0)
|
||||
{
|
||||
// On determine le montant total du paiement
|
||||
$total=0;
|
||||
|
|
@ -136,7 +136,7 @@ if ($_POST["action"] == 'add_paiement')
|
|||
else
|
||||
{
|
||||
$db->rollback();
|
||||
$mesg = "Failed to create payment: paiement_id=$paiement_id ".$db->error();
|
||||
$mesg = "Failed to create payment: paiement_id=$paymentid ".$db->error();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user