allow product ajax search on description
This commit is contained in:
parent
911f343c97
commit
d5bf9691ee
@ -19,6 +19,7 @@
|
||||
* Copyright (C) 2018 Ferran Marcet <fmarcet@2byte.es>
|
||||
* Copyright (C) 2018 Frédéric France <frederic.france@netlogic.fr>
|
||||
* Copyright (C) 2018 Nicolas ZABOURI <info@inovea-conseil.com>
|
||||
* Copyright (C) 2018 Christophe Battarel <christophe@altairis.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
|
||||
@ -2131,6 +2132,11 @@ class Form
|
||||
if ($i > 0) $sql.=" AND ";
|
||||
$sql.="(p.ref LIKE '".$db->escape($prefix.$crit)."%' OR p.label LIKE '".$db->escape($prefix.$crit)."%'";
|
||||
if (! empty($conf->global->MAIN_MULTILANGS)) $sql.=" OR pl.label LIKE '".$db->escape($prefix.$crit)."%'";
|
||||
if (!empty($conf->global->PRODUCT_AJAX_SEARCH_ON_DESCRIPTION))
|
||||
{
|
||||
$sql.=" OR p.description LIKE '".$db->escape($prefix.$crit)."%'";
|
||||
if (! empty($conf->global->MAIN_MULTILANGS)) $sql.=" OR pl.description LIKE '".$db->escape($prefix.$crit)."%'";
|
||||
}
|
||||
if (! empty($conf->global->MAIN_SEARCH_PRODUCT_BY_FOURN_REF)) $sql.=" OR pfp.ref_fourn LIKE '".$db->escape($prefix.$crit)."%'";
|
||||
$sql.=")";
|
||||
$i++;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user