public static function getManufacturersByIds($cids)
{
$db = Factory::getDBO();
if ($cids != '') {
//cids is string separated by comma
$query = 'SELECT a.id FROM #__phocacart_manufacturers AS a' . ' LEFT JOIN #__phocacart_products AS p ON a.id = p.manufacturer_id' . ' WHERE p.id IN (' . $cids . ')' . ' ORDER BY a.id';
$db->setQuery($query);
$tags = $db->loadColumn();
$tags = array_unique($tags);
return $tags;
}
return array();
}