{ "info": { "author": "Andrey Novikov", "author_email": "novikov@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Framework :: Django", "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python", "Programming Language :: Python :: 2", "Programming Language :: Python :: 3" ], "description": "# Rated reviews application for Django\n\n[![Build Status](https://travis-ci.com/andreynovikov/django-rated-reviews.svg?branch=master)](https://travis-ci.com/andreynovikov/django-rated-reviews)\n[![Documentation Status](https://img.shields.io/readthedocs/django-rated-reviews.svg?style=flat)](https://readthedocs.org/projects/django-rated-reviews/)\n[![GitHub release](https://img.shields.io/github/release/andreynovikov/django-rated-reviews.svg)](https://github.com/andreynovikov/django-rated-reviews/releases/latest)\n[![PyPI release](https://img.shields.io/pypi/v/django-rated-reviews.svg)](https://pypi.org/project/django-rated-reviews/)\n[![Python version](https://img.shields.io/pypi/pyversions/django-rated-reviews.svg)](https://pypi.org/project/django-rated-reviews/)\n[![GitHub issues](https://img.shields.io/github/issues/andreynovikov/django-rated-reviews.svg)](https://github.com/andreynovikov/django-rated-reviews/issues)\n[![Code quality](https://img.shields.io/codacy/grade/fe2c36bbb12344318d0523148ae8e725.svg)](https://www.codacy.com/app/novikov/django-rated-reviews)\n[![Coverage](https://img.shields.io/codacy/coverage/fe2c36bbb12344318d0523148ae8e725.svg)](https://www.codacy.com/app/novikov/django-rated-reviews)\n[![GitHub license](https://img.shields.io/github/license/andreynovikov/django-rated-reviews.svg)](LICENSE)\n\nRated reviews is derived from [Django \u201cexcontrib\u201d Comments](https://github.com/django/django-contrib-comments/) and can be used to attach reviews with rating to any model. The core difference from comments is that user can provide only one review per item. Rating is expressed by a number and by default visualized with stars. However, it can be changed to whatever you want. Rating grades are also configurable.\n\nOptionally rating can be weighted. For instance, you can designate experts whose rating would be more valuable. Alternatively, add weight to reviews of real byers of sold product.\n\n## Requirements\n\n* Python 2.7+ or Python 3.3+\n* Django 1.11+\n\n## Installation\n\nInstall ```django-rated-reviews``` using pip:\n\n```shell\npip install django-rated-reviews\n```\n\nAdd ```reviews``` to ```INSTALLED_APPS```. Example:\n\n```python\nINSTALLED_APPS = (\n ...\n 'reviews',\n ...\n)\n```\n\nRun ```manage.py migrate``` so that Django will create the review tables.\n\nAdd the reviews app\u2019s URLs to your project\u2019s urls.py:\n\n```python\nurlpatterns = [\n ...\n url(r'^reviews/', include('reviews.urls')),\n ...\n]\n```\n\nUse the review template tags to embed reviews in your templates.\n\n## Customization\n\nAll configuration settings are optional.\n\n#### REVIEW_MAX_LENGTH\n\nThe maximum length of the review comment field, in characters. Comments longer than this will be rejected. Defaults to ```3000```.\n\n#### REVIEW_PUBLISH_UNMODERATED\n\nIf ```False``` (default) reviews are not published until they are moderated in admin. If user modifies existing review it is considered unmoderated again.\n\n#### REVIEW_COMPOSE_TIMEOUT\n\nThe maximum review form timeout in seconds. The default value is ```2 * 60 * 60``` (2 hours).\n\n#### REVIEW_RATING_CHOICES\n\nCustom rating choices, each represented by one star (currently the maximum supported number is 10). Default choices are:\n\n```python\nREVIEW_RATING_CHOICES = (\n ('1', _('Terrible')),\n ('2', _('Poor')),\n ('3', _('Average')),\n ('4', _('Very Good')),\n ('5', _('Excellent')),\n)\n```\n\n#### REVIEW_SHOW_RATING_TEXT\n\nIf ```True``` (default) rating text (as specified by choices) is displayed next to rating stars. \n\n#### REVIEW_ALLOW_PROFANITIES\n\nIf ```False``` review comment is checked against words in ```PROFANITIES_LIST```. If it contains any of the words, review is rejected.\n\n#### REVIEW_ADMIN_LINK_SYMBOL\n\nReview admin exposes a link to review on a web site. By default it is shown as ▶. It can be changed to any other symbol or text,\ne.g. if Font Awesome is attached to admin the following setting can be used: ```''```.\n\n#### REVIEW_APP\n\nCustom reviews app can be set that will define custom ```ReviewForm```, ```Review``` model or rating weight system.\n\n### Examples\n\n#### Custom rating weight definition\n\n```python\ndef get_review_user_weight(user, target):\n if user.has_perm('reviews.can_moderate'):\n return 50\n from .models import Product, Order\n if isinstance(target, Product):\n count = Order.objects.filter(user=user.pk,\n item__product=target.pk,\n status=Order.STATUS_DONE\n ).count()\n if count > 0:\n return 10\n return 1\n```\n\n## Credits\n\nApplication code is derived from [Django \u201cexcontrib\u201d Comments](https://github.com/django/django-contrib-comments/).\n\nRating widget uses [star-rating.js library](https://github.com/pryley/star-rating.js) by Paul Ryley.\n\n\n", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/andreynovikov/django-rated-reviews/tree/master", "keywords": "", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "django-rated-reviews", "package_url": "https://pypi.org/project/django-rated-reviews/", "platform": "", "project_url": "https://pypi.org/project/django-rated-reviews/", "project_urls": { "Homepage": "https://github.com/andreynovikov/django-rated-reviews/tree/master", "Source": "https://github.com/andreynovikov/django-rated-reviews/", "Tracker": "https://github.com/andreynovikov/django-rated-reviews/issues" }, "release_url": "https://pypi.org/project/django-rated-reviews/0.6.0/", "requires_dist": [ "Django (>=1.11)" ], "requires_python": "", "summary": "Rated reviews for Django", "version": "0.6.0" }, "last_serial": 5754242, "releases": { "0.2.0": [ { "comment_text": "", "digests": { "md5": "2e8fdc50d9914836dbac9aa35e49861e", "sha256": "5ee44a25091b68beb62799b77bbe646f237d4ec2be3ce3308847229ebc7fc84c" }, "downloads": -1, "filename": "django_rated_reviews-0.2.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "2e8fdc50d9914836dbac9aa35e49861e", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 48995, "upload_time": "2019-02-06T17:32:15", "url": "https://files.pythonhosted.org/packages/1f/07/afd6dfe9b8e117d573ccf37509a4ee7535f1d9643e577bee904e741714d3/django_rated_reviews-0.2.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "7b0b58cc19732c5b900a91067e70eea4", "sha256": "8497add1eb1ff7fd70ca5eadff9737330d5924d575d07fbf58c41b41fe9633c1" }, "downloads": -1, "filename": "django-rated-reviews-0.2.0.tar.gz", "has_sig": false, "md5_digest": "7b0b58cc19732c5b900a91067e70eea4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 32757, "upload_time": "2019-02-06T17:32:17", "url": "https://files.pythonhosted.org/packages/29/7f/d20aad1c80108b40117d2c27d7442810fe6165d8a6d6d274dfdc1089d483/django-rated-reviews-0.2.0.tar.gz" } ], "0.3.0": [ { "comment_text": "", "digests": { "md5": "03b978f510205330c06b0ffe18169309", "sha256": "39f585c4a7c99e3c0b1f0a00ff5b93be31a5604303546e3bdbc612a982d4aad4" }, "downloads": -1, "filename": "django_rated_reviews-0.3.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "03b978f510205330c06b0ffe18169309", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 50726, "upload_time": "2019-04-03T10:35:29", "url": "https://files.pythonhosted.org/packages/4f/0b/36fa570bf35a77343a3d0da087df52b8aefa220436e87ff655015d666602/django_rated_reviews-0.3.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "26457b1d90e9818ccae173950d22f318", "sha256": "bbb15d2f483d9e226d08d7695ba5964153f31845058dac541a97d38b8aba53f9" }, "downloads": -1, "filename": "django-rated-reviews-0.3.0.tar.gz", "has_sig": false, "md5_digest": "26457b1d90e9818ccae173950d22f318", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 37854, "upload_time": "2019-04-03T10:35:30", "url": "https://files.pythonhosted.org/packages/50/82/49e2d01128b16745f3765f9a31f52479006ce9306dbc8d5d2f506e5653f7/django-rated-reviews-0.3.0.tar.gz" } ], "0.6.0": [ { "comment_text": "", "digests": { "md5": "e260dbdb780cf198437eeb7f6cf97a25", "sha256": "fb6613d3222a422d66460582a935e3597c07b77f4a757672585158d320b13b2c" }, "downloads": -1, "filename": "django_rated_reviews-0.6.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "e260dbdb780cf198437eeb7f6cf97a25", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 52283, "upload_time": "2019-08-29T15:32:10", "url": "https://files.pythonhosted.org/packages/7a/16/29a4989fc621a95a155195f0037eb0e39838e079772c71bbc9afb947051b/django_rated_reviews-0.6.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "893e851d3d7745d523d12d11a19927a8", "sha256": "426d77d14d03c42ba9ee833ff69b71f6b264e966aad202dcad48a7f3abd5a0a4" }, "downloads": -1, "filename": "django-rated-reviews-0.6.0.tar.gz", "has_sig": false, "md5_digest": "893e851d3d7745d523d12d11a19927a8", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 39079, "upload_time": "2019-08-29T15:32:12", "url": "https://files.pythonhosted.org/packages/cd/7b/818b0652695f9925ee1f19a209df7c70917d31e1ebb1fd6fc3c0424d42ce/django-rated-reviews-0.6.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "e260dbdb780cf198437eeb7f6cf97a25", "sha256": "fb6613d3222a422d66460582a935e3597c07b77f4a757672585158d320b13b2c" }, "downloads": -1, "filename": "django_rated_reviews-0.6.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "e260dbdb780cf198437eeb7f6cf97a25", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 52283, "upload_time": "2019-08-29T15:32:10", "url": "https://files.pythonhosted.org/packages/7a/16/29a4989fc621a95a155195f0037eb0e39838e079772c71bbc9afb947051b/django_rated_reviews-0.6.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "893e851d3d7745d523d12d11a19927a8", "sha256": "426d77d14d03c42ba9ee833ff69b71f6b264e966aad202dcad48a7f3abd5a0a4" }, "downloads": -1, "filename": "django-rated-reviews-0.6.0.tar.gz", "has_sig": false, "md5_digest": "893e851d3d7745d523d12d11a19927a8", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 39079, "upload_time": "2019-08-29T15:32:12", "url": "https://files.pythonhosted.org/packages/cd/7b/818b0652695f9925ee1f19a209df7c70917d31e1ebb1fd6fc3c0424d42ce/django-rated-reviews-0.6.0.tar.gz" } ] }