Generic user wishlists for use with any Django model.
AGPL-3.0 License
############### django-wishlist ###############
.. image:: https://img.shields.io/pypi/v/django-wishlist.svg :target: https://pypi.python.org/pypi/django-wishlist
.. image:: https://img.shields.io/travis/dokterbob/django-wishlist/master.svg :target: http://travis-ci.org/dokterbob/django-wishlist
.. image:: https://coveralls.io/repos/dokterbob/django-wishlist/badge.svg?branch=master&service=github :target: https://coveralls.io/github/dokterbob/django-wishlist?branch=master
.. image:: https://landscape.io/github/dokterbob/django-wishlist/master/landscape.svg?style=flat :target: https://landscape.io/github/dokterbob/django-wishlist/master :alt: Code Health
Generic user wishlists for shops and the likes.
Alpha. Don't use it, unless you're willing to fix issues. Will be released on PyPI as soon as tested in limited production.
Tested to work with Django 1.8 and 1.9 and Python 2.7.
Please refer to requirements.txt <http://github.com/dokterbob/django-wishlist/blob/master/requirements.txt>
_
for an updated list of required packages.
The package is available
To install:
Install the django-wishlist app::
pip install django-wishlist
In your Django settings:
Add 'wishlist'
to INSTALLED_APPS
.
Configure WISHLIST_ITEM_MODEL
to the model used for wishlist items.
Optionally: add wishlist.context_processors.wishlist_items
to your
TEMPLATE_CONTEXT_PROCESSORS
.
For example::
INSTALLED_APPS = [
...
'wishlist'
...
]
TEMPLATE_CONTEXT_PROCESSORS = [
...
'wishlist.context_processors.wishlist_items',
...
]
WISHLIST_ITEM_MODEL = 'my_webshop.Product'
In urls.py
add::
(r'^/wishlist/', include('wishlist.urls')),
Update the database::
./manage.py migrate
Note Migrations do not work as the model is dynamically configured.
Create a button to add an item to the wishlist simply from within your template.
At the top of the page add::
{% load wishlist_tags %}
And where you want the button add::
{% wishlist_add_form product %}
Where product is the product you want to add to the wishlist.
Tests for pull req's and the master branch are automatically run through
Travis CI <http://travis-ci.org/dokterbob/django-wishlist>
_.
This application is released under the GNU Affero General Public License version 3.