Socket
Socket
Sign inDemoInstall

stars-rating

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

stars-rating

Django application to rate objects & stars UI


Maintainers
1

Rating of content with stars UI

Usage

models.py::

from django.db import models
from djangoratings.fields import RatingField
from rating.models import RatingBase


class MyModel(models.Model, RatingBase):
    ...
    rating = RatingField(range=10, allow_anonymous=True, can_change_vote=True)
    rating_field_names = ('rating',)

settings.py::

RATINGS_VOTES_PER_IP = 3 # or whatever

urls.py::

(r'^stars/', include('rating.urls'))

template.html::

{% show_stars object "rating" 0 %}

.. NOTE:: show_stars(context, obj, field_name='rating', big_star=True, disabled=False, extra_class='', extra_success='')

show_stars template tag displays clickable stars to vote for content.

License note

This application contains static files from:

  • jquery.ui.stars (http://orkans-tmp.22web.net/star_rating/);
  • jquery.ui.core and jquery.ui.widget (http://jqueryui.com/)

Written by the development team of Arpaso company: http://arpaso.com

FAQs


Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc