I've been trying for two weeks to implement the highly regarded 
django-ratings with zero success.

I've followed all directions, which are not that detailed, and cannot 
figure out how to actually present a means for a user to submit a rating 
with the template.

There are no directions on how to load template tags associated with it, so 
it resulted in errore. After looking through the code, it appears "ratings" 
was the proper way to load the tags within the template, so I employed that.

I added 'djangoratings' to settings.py.

The following to my model:

    rating = RatingField(range=5)

I also did the following to urls.py:

from djangoratings.views import AddRatingFromModel

    url(r'rate-my-post/(?P<object_id>\d*)/(?P<score>\d*)/', 
AddRatingFromModel(), {
        'app_label': 'report',
        'model': 'story',
        'field_name': 'rating',
    }),

Added this to the template:

{% rating_by_user user on story.rating as vote %}

And nothing appears. No means for the user to vote. Nothing.

I cannot figure out what may be wrong here and after two weeks of tweaking 
and trying different methods, nothing works.

If anyone has an idea of what is required to present some interface for a 
user to vote using this app, I would be extremely grateful.




-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/django-users/-/MPTvcHpbZ5QJ.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.

Reply via email to