-- HikaShop version -- : 5.0.0
-- Joomla version -- : 4.4.0
-- PHP version -- : 8.1
Hi
I have a PHP function that returns a product from Hikashop based on the product id.
The relevant code is:
if (!@include_once (rtrim(JPATH_ADMINISTRATOR, DS) . DS . 'components' . DS . 'com_hikashop' . DS . 'helpers' . DS . 'helper.php')) {
return false;
}
// Product
$productClass = hikashop_get('class.product');
$product = $productClass->getProduct($id);
However, the returned product object from $productClass->getProduct($id) is not "complete" when I compare it to what I see directly in a product listing view. E.g. it does not contains any badges.
Does Hikashop have a way to enrich the product object with badges?
Merci