Skip to content
Snippets Groups Projects
Commit 8f08d7a1 authored by Christophe Battarel's avatar Christophe Battarel
Browse files

add entity in the unique key for delete

parent e8b92cc2
No related branches found
No related tags found
No related merge requests found
......@@ -212,7 +212,7 @@ class ProductFournisseur extends Product
{
// Delete price for this quantity
$sql = "DELETE FROM ".MAIN_DB_PREFIX."product_fournisseur_price";
$sql.= " WHERE fk_soc = ".$fourn->id." AND ref_fourn = '".$this->db->escape($ref_fourn)."' AND quantity = ".$qty;
$sql.= " WHERE fk_soc = ".$fourn->id." AND ref_fourn = '".$this->db->escape($ref_fourn)."' AND quantity = ".$qty." AND entity = ".$conf->entity;
dol_syslog(get_class($this).'::update_buyprice sql='.$sql);
$resql=$this->db->query($sql);
if ($resql)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment