Skip to content

Commit

Permalink
Update fournisseur.product.class.php
Browse files Browse the repository at this point in the history
  • Loading branch information
eldy committed Jul 18, 2019
1 parent 5daf031 commit f53f314
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion htdocs/fourn/class/fournisseur.product.class.php
Expand Up @@ -439,7 +439,7 @@ public function update_buyprice($qty, $buyprice, $user, $price_base_type, $fourn

$resql = $this->db->query($sql);
if ($resql) {
$this->product_fourn_price_id = $this->db->last_insert_id(MAIN_DB_PREFIX . "product_fournisseur_price");
$idinserted = $this->db->last_insert_id(MAIN_DB_PREFIX . "product_fournisseur_price");
}
else {
$error++;
Expand All @@ -462,6 +462,7 @@ public function update_buyprice($qty, $buyprice, $user, $price_base_type, $fourn

if (empty($error)) {
$this->db->commit();
$this->product_fourn_price_id = $idinserted;
return $this->product_fourn_price_id;
} else {
$this->db->rollback();
Expand Down

0 comments on commit f53f314

Please sign in to comment.