mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2026-01-24 17:53:17 +01:00
FIX error managent and db transaction balance
This commit is contained in:
@@ -2903,13 +2903,12 @@ class Commande extends CommonOrder
|
||||
{
|
||||
$error = 0;
|
||||
|
||||
$this->db->begin();
|
||||
|
||||
if ($this->billed)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
$this->db->begin();
|
||||
|
||||
$sql = 'UPDATE '.MAIN_DB_PREFIX.'commande SET facture = 1';
|
||||
$sql .= ' WHERE rowid = '.$this->id.' AND fk_statut > '.self::STATUS_DRAFT;
|
||||
|
||||
Reference in New Issue
Block a user