Skip to content

Commit

Permalink
Update html.form.class.php
Browse files Browse the repository at this point in the history
  • Loading branch information
eldy committed Dec 14, 2018
1 parent 5c9d5bb commit e1baf3a
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions htdocs/core/class/html.form.class.php
Expand Up @@ -2017,12 +2017,15 @@ function select_produits_list($selected='',$htmlname='productid',$filtertype='',
$sql = "SELECT ";
$sql.= $selectFields . $selectFieldsGrouped;

//Product category
$sql.= ", (SELECT ".MAIN_DB_PREFIX."categorie_product.fk_categorie
FROM ".MAIN_DB_PREFIX."categorie_product
WHERE ".MAIN_DB_PREFIX."categorie_product.fk_product=p.rowid
LIMIT 1
if (! empty($conf->global->PRODUCT_SORT_BY_CATEGORY))
{
//Product category
$sql.= ", (SELECT ".MAIN_DB_PREFIX."categorie_product.fk_categorie
FROM ".MAIN_DB_PREFIX."categorie_product
WHERE ".MAIN_DB_PREFIX."categorie_product.fk_product=p.rowid
LIMIT 1
) AS categorie_product_id ";
}

//Price by customer
if (! empty($conf->global->PRODUIT_CUSTOMER_PRICES) && !empty($socid))
Expand Down

0 comments on commit e1baf3a

Please sign in to comment.