{ "info": { "author": "Jacob Windsor", "author_email": "jacob.windsor@ymail.com", "bugtrack_url": null, "classifiers": [ "Environment :: Web Environment", "Framework :: Django", "Framework :: Django :: 1.9", "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python", "Programming Language :: Python :: 3.5", "Topic :: Internet :: WWW/HTTP", "Topic :: Internet :: WWW/HTTP :: Dynamic Content" ], "description": "==========\r\nReviewable\r\n==========\r\nReviewable provides simple, customizable reviews for any of your Django models. The templates for each of your reviewable\r\nmodels can be customised with ease.\r\n\r\nQuick Start\r\n-----------\r\n1.\r\n\r\n.. code-block:: bash\r\n\r\n $ pip install django-reviewable\r\n\r\n2. Add \"Reviewable\" to your INSTALLED_APPS setting:\r\n\r\n.. code-block:: python\r\n\r\n INSTALLED_APPS = [\r\n ...\r\n 'Reviewable',\r\n ...\r\n ]\r\n\r\n2. Include the Reviewable URLconf in your projects urls.py:\r\n\r\n.. code-block:: python\r\n\r\n url(r'^reviews/', include('Reviewable.urls', namespace='Reviewable')),\r\n\r\n2. Run ``python manage.py migrate``\r\n\r\n5. Add the mixin ``Reviewable`` to any model you want to be reviewable.\r\n\r\n.. code-block:: python\r\n\r\n ...\r\n from Reviewable.models import Reviewable\r\n ...\r\n\r\n class ReviewableModel(models.Model, Reviewable):\r\n ...\r\n\r\nCustom Templates\r\n----------------\r\nReviewable allows you to customise the templates for each reviewable model. Furthemore, the reviewable object is magically\r\nmade available in the template context.\r\n\r\nFor example:\r\n 1. You have a model called ``Hotel`` in an app called ``Hotel``\r\n 2. You want a custom template for the review creation view\r\n 3. You would add a template in ``Hotel/templates/Hotel`` called ``hotel_review_create.html``\r\n - Note: This the template name has to be in camel case and all lower case\r\n 4. The hotel object is made available in the template context by the usual ``{{ hotel }}`` tag\r\n 5. This can be repeated for templates for all views: ``hotel_review_list.html``, ``hotel_review_update.html``,\r\n ``hotel_review_confirm_delete.html`` and ``hotel_review_detail.html``\r\n\r\nTemplate Tags\r\n-------------\r\n\r\nReviewable provides one simple but useful template inclusion tag that will include controls for your reviewable object.\r\n\r\nTo use this just load in the template tag:\r\n\r\n.. code-block:: python\r\n\r\n {% load reviewable %}\r\n ...\r\n {% show_review_controls reviewable_object %}\r\n\r\nThe template for the inclusion tag is very basic so it is a good idea to override it in the usual Django fashion.\r\nThe name of the template is \"Reviewable/__review_controls.html\".\r\n\r\nPost Delete Signals\r\n-------------------\r\n\r\nDeletion of a reviewable object won't automatically cause a cascade delete of all of the objects reviews. Hence, it\r\nis a good idea to use the post delete signal somewhere in your app as below:\r\n\r\n.. code-block:: python\r\n\r\n from MyApp.models import ReviewableModel\r\n from django.db.models.signals import post_delete\r\n ...\r\n\r\n post_delete.connect(ReviewableModel.delete_reviews, sender=ReviewableModel)\r\n\r\nSettings\r\n--------\r\n\r\nAll settings are shown below with their defaults.\r\n\r\nREVIEW_RATING_CHOICES\r\n+++++++++++++++++++++\r\n\r\n.. code-block:: python\r\n\r\n REVIEW_RATING_CHOICES=(\r\n (1, '1 Star'),\r\n (2, '2 Star'),\r\n (3, '3 Star'),\r\n (4, '4 Star'),\r\n (5, '5 Star')\r\n )\r\n\r\nREVIEW_DELETE_SUCCESS_URL\r\n+++++++++++++++++++++++++\r\n\r\n.. code-block:: python\r\n\r\n REVIEW_DELETE_SUCCESS_URL='/'\r\n\r\nREVIEW_STREAM_ENABLED\r\n+++++++++++++++++++++\r\n\r\nReviewable can utilise GetStream if required. This would mean reviews are automatically published to your GetStream.io\r\nfeed. See https://github.com/GetStream/stream-django for more information\r\n\r\n.. code-block:: python\r\n\r\n REVIEW_STREAM_ENABLED=False\r\n", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/jacobwindsor/django-reviewable", "keywords": null, "license": "MIT License", "maintainer": null, "maintainer_email": null, "name": "django-reviewable", "package_url": "https://pypi.org/project/django-reviewable/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/django-reviewable/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/jacobwindsor/django-reviewable" }, "release_url": "https://pypi.org/project/django-reviewable/0.3.9.2/", "requires_dist": null, "requires_python": null, "summary": "Simple, customizable reviews for any of your Django models", "version": "0.3.9.2" }, "last_serial": 2179773, "releases": { "0.3.9.2": [ { "comment_text": "", "digests": { "md5": "885cdeccf4927adc8f125b1ecedfa492", "sha256": "3690c20a44d68198e7c02d68ee8854f8803dbe54528cd6630b2f8bb5794349e7" }, "downloads": -1, "filename": "django_reviewable-0.3.9.2-py2-none-any.whl", "has_sig": false, "md5_digest": "885cdeccf4927adc8f125b1ecedfa492", "packagetype": "bdist_wheel", "python_version": "2.7", "requires_python": null, "size": 10911, "upload_time": "2016-06-21T22:05:51", "url": "https://files.pythonhosted.org/packages/77/2c/82469238e8cec295bf94242c3c250817c5aa21ab100c69d930a05a277833/django_reviewable-0.3.9.2-py2-none-any.whl" }, { "comment_text": "", "digests": { "md5": "4b8bea2c1971d62aaca062b06e1ffc16", "sha256": "cfdcea00ec43a7b50fdc014a3607d97ffdf1b1f345a696d8899f89b9b293a46f" }, "downloads": -1, "filename": "django-reviewable-0.3.9.2.tar.gz", "has_sig": false, "md5_digest": "4b8bea2c1971d62aaca062b06e1ffc16", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7600, "upload_time": "2016-06-21T22:05:46", "url": "https://files.pythonhosted.org/packages/20/d9/bd51fe46600c3d4d07488e7e6f940fa973b5ef56a875eaf03f61f11c5391/django-reviewable-0.3.9.2.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "885cdeccf4927adc8f125b1ecedfa492", "sha256": "3690c20a44d68198e7c02d68ee8854f8803dbe54528cd6630b2f8bb5794349e7" }, "downloads": -1, "filename": "django_reviewable-0.3.9.2-py2-none-any.whl", "has_sig": false, "md5_digest": "885cdeccf4927adc8f125b1ecedfa492", "packagetype": "bdist_wheel", "python_version": "2.7", "requires_python": null, "size": 10911, "upload_time": "2016-06-21T22:05:51", "url": "https://files.pythonhosted.org/packages/77/2c/82469238e8cec295bf94242c3c250817c5aa21ab100c69d930a05a277833/django_reviewable-0.3.9.2-py2-none-any.whl" }, { "comment_text": "", "digests": { "md5": "4b8bea2c1971d62aaca062b06e1ffc16", "sha256": "cfdcea00ec43a7b50fdc014a3607d97ffdf1b1f345a696d8899f89b9b293a46f" }, "downloads": -1, "filename": "django-reviewable-0.3.9.2.tar.gz", "has_sig": false, "md5_digest": "4b8bea2c1971d62aaca062b06e1ffc16", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7600, "upload_time": "2016-06-21T22:05:46", "url": "https://files.pythonhosted.org/packages/20/d9/bd51fe46600c3d4d07488e7e6f940fa973b5ef56a875eaf03f61f11c5391/django-reviewable-0.3.9.2.tar.gz" } ] }