-- HikaShop version -- : 3.5.1
-- Joomla version -- : 3.8.11
When creating a newsletter and inserting hikashop products with language tags, when you click on preview/send the language does not change. We looked at the function _replaceProduct (line 817) in the acymailing hikashop plugin file.
We see in line 850 the product values are assigned to the varFields. However the translation takes place in the next block of code starting in line 854. To get is working we had to invert the code so it becomes
$translationHelper = hikashop_get('helper.translation');
f($translationHelper->isMulti(true, false)) $this->acypluginsHelper->translateItem($product, $tag, 'hikashop_product');
$varFields = array();
foreach($product as $fieldName => $oneField){
$varFields['{'.$fieldName.'}'] = $oneField;
}
This way the product values are translated first before they are assigned to the $varFields