Vendor rating not working for Hikamarket

  • Posts: 27
  • Thank you received: 0
8 years 7 months ago #234189

-- url of the page with the problem -- : s339467542.domenastandartowa.pl/db2/
-- HikaShop version -- : 2.6.1
-- HikaMarket version -- : 1.6.7
-- Joomla version -- : 3.5
-- PHP version -- : 5.6
-- Browser(s) name and version -- : All
-- Error-message(debug-mod must be tuned on) -- : Vendor rating not working for Hikamarket vendor page

Hi Jarome

I would like to report an issue. On the vendor page I have enabled "Vote and comment". This works for both hikashop product and hikamarket vendor page.
On product page it seems to work correctly. On Vendor page the rating (stars) are not saved and when I refresh the page it is gone.


I tried to see how it is done on You demo but thre the rating is not activated.
demo.hikashop.com/index.php/en/hikamarket/vendor-page

On my page You can see it here:
s339467542.domenastandartowa.pl/db2/inde...rzedawca-wszystkiego

Thank You for help
Tim

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
8 years 7 months ago #234233

Hi,

The page you linked does not allow to vote so I cannot perform any test (and analyze) in your website.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

  • Posts: 27
  • Thank you received: 0
8 years 7 months ago #234261

Hi Jarome

I have enabled voting and comments for "public" but if you want to log in the user and pswd is "guest"
Please go ahead.
Also - You can check on Your demo page - if it does not work I think it does not work for all installations.

If You need logon data for backend I have already created user for You "HikaSupport" in one of my previous tickets.

Thank you
Tim

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
8 years 7 months ago #234324

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,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.
Last edit: 8 years 7 months ago by Jerome.

Please Log in or Create an account to join the conversation.

  • Posts: 27
  • Thank you received: 0
8 years 7 months ago #234369

Hi Jarome

Thank You very much for help and such a quick reaction. I applied the changes but it is still not working.
Here is what I did.
1. Modified market.php as described in Your email.
2. Downloaded and installed file: com_hikashop_business_v2.6.1_2016-03-26_15-03-43

Maybe You could send me the market.php? This would at sure make sure that I did no mistake there?

Thank You
Tim

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
8 years 7 months ago #234375

Hi,

It would be easier if I could have an FTP access so I can apply the patch and test directly that the all system is working fine.
And if you can also provide a super-admin account ; I would be able to see the content in the database in the same time ; but it should be ok without.

Please use the "contact us" form for such kind of private information.
By including a link to that forum thread, the support team will assign directly the message to me.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

  • Posts: 27
  • Thank you received: 0
8 years 7 months ago #234390

Hi Jerome
I have send all the logon details. Thank You for help.
T

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
8 years 7 months ago #234428

Hi,

I am sorry but the FTP account is not working.
I don't know if my IP has been block or else ; but I can't make a connection with your FTP server.
And even if the backend access is working ; it does not provide me the right interface to perform some debugging on the HikaShop vote system.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

  • Posts: 27
  • Thank you received: 0
8 years 7 months ago #234484

Hi Jerome

Very strange - I have check it few time in different location and the FTP is working. Please find attached a file with FTP settings for filezilla - I hope it will help. If not please let me know and we will figure out something.


Cheers
Tim

Last edit: 8 years 7 months ago by Jerome. Reason: removing attached image

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
8 years 7 months ago #234523

Hi,

I finally figured it out the issue with the FTP ; your server have a partial IPv6 support but the FTP port seems to only response in IPv4.

I fixed the patch ; the votes are now saved correctly.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

  • Posts: 27
  • Thank you received: 0
8 years 7 months ago #234525

Great - Thank You very much Jerome
it is working now.
Cheers
Tim

Please Log in or Create an account to join the conversation.

  • Posts: 5
  • Thank you received: 0
8 years 6 months ago #238342

Joomla 3.5.1
Hikashop starter 2.6.2
Hikamarket 1.6.7
PHP 5.5.48

Same issue here, I added rating for my products (only users who bought can rate), ratings diplay fine at product page but at vendor page neither ratings nor commets load. See for example:

talentwerf.co.za/index.php/all-vendors/v.../show/2-vendor-alpha

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
8 years 6 months ago #238345

Hi,

Did you apply all previous patches mentioned in that thread ?
I see that you have a very recent HikaShop 2.6.2 package so you have all patches for the HikaShop part.

If so, please also add the function in the "market" plugin.

	public function onAfterVoteCreate(&$element, $return_data) {
		$this->onAfterVoteUpdate($element, $return_data);
	}
The best is to paste it just before the "onAfterVoteUpdate" function, and have such code :
public function onAfterVoteCreate(&$element, $return_data) {
	$this->onAfterVoteUpdate($element, $return_data);
}

public function onAfterVoteUpdate(&$element, $return_data) {

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

  • Posts: 5
  • Thank you received: 0
8 years 6 months ago #238418

I applied all changes you suggested and still felt no :( joy :(

I am attaching the market plugin for review

Last edit: 8 years 6 months ago by Jerome. Reason: remove attachment

Please Log in or Create an account to join the conversation.

  • Posts: 5
  • Thank you received: 0
8 years 6 months ago #238480

Hello Hikashop Dev,

Our situation is kind of very urgent, can you kindly help us with this asap? We are a team of Dev and this is our ongoing work.

Thanks,
Avi

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
8 years 6 months ago #238502

Hi,

Yesterday I updated the HikaShop demo website in order to test the issue.
I was able to reproduce it but it was late and I had to eat and sleep.
In that time I didn't feel that I should notice you that I got some clues and that I think some patches are missing in the HikaShop 2.6.2 release (that I should have in the dev-release of HikaShop 2.6.3)

It requires some investigations and for what I could see, it should be related to HikaShop and not to the HikaMarket patches.
HikaShop 2.6.2 changed a lot of things in the vote system and unfortunately, the HikaShop team did not warn me of that so I could correctly test and improve HikaMarket.

I am always answering asap and you can be sure that I'm doing as fast as I can.
As you know I'm working on a new release of HikaMarket so I want to be sure that what HikaShop 2.6.2 as broke in the vote system won't be break anymore with new HikaMarket release.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
8 years 6 months ago #238519

Hi,

With HikaShop 2.6.2 ; I was able to see the problem but with HikaShop 2.6.3, the problem is fixed.
I saw with Nicolas and they want to release that new version soon, it is almost finished but they will wait beginning of next week (to do not perform a release during the French Joomla day).

So, the patches in HikaMarket are there but there is some patches missing in HikaShop 2.6.2 for the vote system.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

  • Posts: 5
  • Thank you received: 0
8 years 6 months ago #238523

I understand the whole software may take a while to be ready, but could you send me the respective files related to this problem to fix it? Please

I always praised Hikashop and how you go beyond your duty to help users. Please show once again it's true.

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
8 years 6 months ago #238524

Hi,

Please see that directly with the HikaShop support team.
I know that there is already a forum thread, in the HikaShop forum section, for the issue on the vendor votes.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

  • Posts: 427
  • Thank you received: 19
8 years 6 months ago #238598

Fix

File Attachment:

File Name: Fix.zip
File Size:10 KB


The only problem is that not refreshed the page after the vote and comment.

Attachments:
Last edit: 8 years 6 months ago by neo191987.
The following user(s) said Thank You: Jerome

Please Log in or Create an account to join the conversation.

Moderators: Obsidev
Time to create page: 0.113 seconds
Powered by Kunena Forum