Hi,
Thanks.
I was able to reproduce your issue in my local website and I found 6 bugs in the vote system of HikaShop 2.6.1.
I submitted a patch in order to fix these problems in HikaShop and make the vote triggers work again.
But, because the vote structure changed ; if you apply the HikaShop patch without applying a patch in HikaMarket, you will have some SQL errors in HikaShop.
So, you will have to modify the plugin "plugins/hikashop/market/market.php" and replace
if($vendor) {
$currentElement->vote_type = 'vendor';
$currentElement->vote_ref_id = $element->vote_ref_id;
$currentElement->average_score = $vendor->vendor_average_score;
$currentElement->total_vote = $vendor->vendor_total_vote;
}
By
if(!$vendor) {
$do = false;
return;
}
$currentElement->vote_type = 'vendor';
$currentElement->vote_ref_id = (int)$element->vote_ref_id;
Then
public function onAfterVoteUpdate(&$element) {
By
public function onAfterVoteUpdate(&$element, $return_data) {
And finally
if(!isset($element->average_score) || !isset($element->total_vote))
return;
$vendor = new stdClass();
$vendor->vendor_id = (int)$element->vote_ref_id;
$vendor->vendor_average_score = hikamarket::toFloat($element->average_score);
$vendor->vendor_total_vote = (int)$element->total_vote;
By
$vendor = new stdClass();
$vendor->vendor_id = (int)$element->vote_ref_id;
$vendor->vendor_average_score = (float)hikamarket::toFloat($return_data['average']);
$vendor->vendor_total_vote = (int)$return_data['total'];
Once the modifications applied, you should be able to re-download the HikaShop 2.6.1 package with the patches I made for them.
Regards,