Code Monkey home page Code Monkey logo

django-wishlist's Introduction

django-wishlist

image

Code Health

Generic user wishlists for use with any Django model.

What is it?

Generic user wishlists for shops and the likes.

Status

Alpha. Don't use it, unless you're willing to fix issues. Will be released on PyPI as soon as tested in limited production.

Compatibility

Tested to work with Django 1.4, 1.5 and 1.6 and Python 2.6 as well as 2.7.

Requirements

Please refer to requirements.txt for an updated list of required packages.

Installation

The package is available

To install:

  1. Install the django-wishlist app:

    pip install -e git+https://github.com/dokterbob/django-wishlist.git#egg=django-wishlist
  2. 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'
  3. In urls.py add:

    (r'^/wishlist/', include('wishlist.urls')),
  4. Update the database:

    ./manage.py syncdb

    Note Migrations do not work as the model is dynamically configured.

Usage

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

Tests for pull req's and the master branch are automatically run through Travis CI.

License

This application is released under the GNU Affero General Public License version 3.

django-wishlist's People

Contributors

ahmedsalman avatar dokterbob avatar guidocalvano avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.