vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.8 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=235)
-   -   Add-On Releases - [AJAX] Helpful Answers - Post Rating System (plus many sub-features) (https://vborg.vbsupport.ru/showthread.php?t=204117)

cooltechie 08-05-2009 04:29 AM

Quote:

Originally Posted by Ted S (Post 1861592)
Sorry about that. I installed the mod and ran a quick test to get past the database errors.

Also think I found the bug causing the duplicate posts. The short explination, I wasn't checking for a record on the post and was recreating it even if you already had votes. This is a bad thing and made duplicate posts show up. It's been fixed.

Just be sure not to re-run this script once it's complete, you'll reimport vote records.

Thanks for working through all the annoying bugs. :up:

I'm a bit confused now that you mentioned not to re-run this script. Is there a check put in place so that it won't reimport if it exist? Should I run it or should I wait?

Was hoping to completely convert over to HA, but for now, we are feeding 'thanks' into vbexperience system to generate stats via their CDP addon which allows to score members based on their activites. Since HA is not listed as a CDP addon, will need both systems until CDP addon is available.

Can this be done?
HA to only show status without 'voting'
HA to coexist with THANKS and a nightly run of ha_import.php

Hope that all makes sense.

Ted S 08-05-2009 04:54 AM

Interesting need.

The script will only import a vote once per user but let me dig in a little deeper and see if that would cause any problems and if so, how I can make sure it all works ok.

Ted S 08-05-2009 05:23 AM

1 Attachment(s)
Ok cooltechie, I think I've got the script you need.

Basically I've written a combination of the import routine and the recalculate votes routine such that thank you posts are reviewed, new votes are added and old ones are skipped. This builds the vote database up properly paving the way to clear the master post records (which tell the post how many people voted up/down). Finally we rebuild all of those master records off the raw votes.

This should be something you can run every 24 hours or 24 seconds. Just keep in mind that there are a lot of queries involved as this is litterally checking every post to update the thankyous and rebuild the master vote record.

cooltechie 08-05-2009 03:41 PM

Quote:

Originally Posted by Ted S (Post 1861637)
Ok cooltechie, I think I've got the script you need.

Basically I've written a combination of the import routine and the recalculate votes routine such that thank you posts are reviewed, new votes are added and old ones are skipped. This builds the vote database up properly paving the way to clear the master post records (which tell the post how many people voted up/down). Finally we rebuild all of those master records off the raw votes.

This should be something you can run every 24 hours or 24 seconds. Just keep in mind that there are a lot of queries involved as this is litterally checking every post to update the thankyous and rebuild the master vote record.

Sorry, should I use ha_import.php first and then ha_import_clean.php after that?

tpearl5 08-05-2009 07:32 PM

Quote:

Originally Posted by Ted S (Post 1861572)
Must have missed this or just lost my mind but I take it this is a new feature request... Please link/ explain.

https://vborg.vbsupport.ru/showthrea...62#post1849562

tpearl5 08-05-2009 07:36 PM

I noticed another small bug - when quick replying to a thread, helpful_answers_mosthelp_post shows up under the new reply.

sockwater 08-05-2009 07:41 PM

Quote:

Originally Posted by Ted S (Post 1860840)
Soft deleting votes is possible but you start to get into more and more variables to check things adding to the queries. I'm not sure it's worth the overhead, even small overhead, for the limited times where it applies.

Here are 2 options:

1. Add a separate table to store the id of any vote that is "soft-deleted". That way current code would stay the same, and only the top helpful posts page would check it.

2. Leave votes intact when hard/soft deleting a post, and clean them out with a daily cron job. That way if you soft-delete a post and go right back and restore it, it would still have its votes.

Ted S 08-05-2009 07:46 PM

No, just use ha_import_clean.php. It's written specifically to do what you need.

Ted S 08-05-2009 07:55 PM

Quote:

Originally Posted by tpearl5 (Post 1862113)

Ahh yes. I still need to build this in for an admin update.

Saviour 08-05-2009 10:41 PM

Quote:

Originally Posted by Ted S (Post 1861571)
Beta release 10 has been posted. This is a small bug fix to address issues with WOL, New Installs and a few other reported issues as well as to allow the notifications system to be turned off.

Hopefully this will be the final beta (cross fingers) before the stable is posted.

I use this mod...only with my Articles forum. WOL is still not working for the helpfulanswers.php page. Still displays Unknown location...


All times are GMT. The time now is 09:34 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.02046 seconds
  • Memory Usage 1,745KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (6)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (4)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete