Merge pull request #9368 from atm-ph/fix_7.0_search_company_by_code

Fix search company by code
This commit is contained in:
Laurent Destailleur 2018-09-01 14:42:32 +02:00 committed by GitHub
commit fe7a0c894f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1102,8 +1102,9 @@ class Form
if (count($scrit) > 1) $sql.=")";
if (! empty($conf->barcode->enabled))
{
$sql .= " OR s.barcode LIKE '".$this->db->escape($filterkey)."%'";
$sql .= " OR s.barcode LIKE '".$this->db->escape($prefix.$filterkey)."%'";
}
$sql.= " OR s.code_client LIKE '".$this->db->escape($prefix.$filterkey)."%' OR s.code_fournisseur LIKE '".$this->db->escape($prefix.$filterkey)."%'";
$sql.=")";
}
$sql.=$this->db->order("nom","ASC");