Rails acts_as_rateable plugin... 2

Posted by Steve Longdo Thu, 09 Feb 2006 19:25:00 GMT

I've gotten quite a bit done on rating. Models can now use the act_as_rateable plugin to track rating information. I've written ActionView Helpers to implement a star rating system and a very cool 1..10 style bar. I've done some preliminary studying of integration with the sciptaculous_slider rails plugin as well.

Remaining todo items include:
  • Rake task to copy images the helpers use to public/images directory.
  • Rake task to setup database tables for storing rating info.
  • Convert the SQL file I've been using into a Migrations style script.
  • Increase Unit Testing coverage.
  • Tying in a rate method on ActionControllers...
This last item is giving me pause though. I was wanting to include a simple rating_controller with the plugin and have it automatically register its route via the init.rb file. I sought out help from the Rails mailing list, but no one could help helped. I may pursue a rake task for adding the route into the routes.rb file. I think this isn't nearly as cool as self-registering a route within the init.rb file, but I haven't had any luck with the methods I have tried so far.

Update: Everytime I post about progress I have made here I find something wrong in my code. I need to re-examine how the view gets updated, somewhere along the way I broke this...
Trackbacks

Use the following link to trackback from your own site:
http://www.stevelongdo.com/articles/trackback/74

Comments

Leave a response

  1. Martin 25 days later:
    Hi there, Is this ready yet - I NEED IT! Good work! Martin
  2. Steve Longdo 25 days later:
    Work on this has stalled. Primarily over concerns about whether or not is appropriate/possible for a plugin to participate in Rails Routing. I've been discussing it with several RoR big names. The mostly seem to be against the idea of a plugin doing this. I may pursue continuing this work as a Rails Engine instead. I've talked with James Adam about what kinds of things would need to happen to make a RatingEngine work. Hopefully I will have more news on this soon...
Comments