Differences
This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision | |||
|
en:modifications:search-custom-productfields-during-productsearch [2015/02/06 15:31] swarnat |
en:modifications:search-custom-productfields-during-productsearch [2015/02/06 15:32] (current) swarnat |
||
|---|---|---|---|
| Line 31: | Line 31: | ||
| $query = 'SELECT label, crmid, setype, createdtime FROM vtiger_crmentity | $query = 'SELECT label, crmid, setype, createdtime FROM vtiger_crmentity | ||
| INNER JOIN vtiger_products ON vtiger_products.productid = vtiger_crmentity.crmid | INNER JOIN vtiger_products ON vtiger_products.productid = vtiger_crmentity.crmid | ||
| - | INNER JOIN vtiger_productcf ON | + | INNER JOIN vtiger_productcf ON vtiger_products.productid = vtiger_productcf.productid |
| - | vtiger_products.productid = vtiger_productcf.productid WHERE (label LIKE ? OR cf_645 LIKE ?) AND vtiger_crmentity.deleted = 0 | + | WHERE (label LIKE ? OR cf_645 LIKE ?) AND vtiger_crmentity.deleted = 0 |
| AND vtiger_products.discontinued = 1 AND setype = ?'; | AND vtiger_products.discontinued = 1 AND setype = ?'; | ||
| $params[] = "%$searchKey%"; | $params[] = "%$searchKey%"; | ||