Metadata-Version: 1.0
Name: django-popcorn
Version: 0.1.0
Summary: Add-another pop-ups a la django-admin.
Home-page: https://github.com/alixedi/django_popcorn
Author: Ali Zaidi
Author-email: alixedi@gmail.com
License: BSD
Description: =============================
        django_popcorn
        =============================
        
        .. image:: https://badge.fury.io/py/django_popcorn.png
            :target: http://badge.fury.io/py/django_popcorn
            
        .. image:: https://travis-ci.org/alixedi/django_popcorn.png?branch=master
                :target: https://travis-ci.org/alixedi/django_popcorn
        
        .. image:: https://pypip.in/d/django_popcorn/badge.png
                :target: https://crate.io/packages/django_popcorn?version=latest
        
        
        Add-another pop-ups a la django-admin.
        
        Installation
        ------------
        
        Get it from the cheeseshop: ::
        
            pip install django_coffee_table
        
        
        Usage
        -----
        
        Read on: 
        
        1. Include the following in your `INSTALLED_APPS` settings: ::
        
            'popcorn',
            'reform',
            'bootstrap_toolkit',
            'widget_tweaks',
        
        2. Uncomment `django.contrib.admin` in the `INSTALLED_APPS` settings.
        
        3. Add this to your settings.py (If you do not already have it): ::
        
            TEMPLATE_CONTEXT_PROCESSORS = (
                "django.contrib.auth.context_processors.auth",
                "django.core.context_processors.debug",
                "django.core.context_processors.i18n",
                "django.core.context_processors.media",
                "django.core.context_processors.static",
                "django.contrib.messages.context_processors.messages",
                "django.core.context_processors.request",
                "popcorn.context_processors.admin_media_prefix",
            )
        
        4. Add the following to your base.html template: ::
        
            <script src="{{ ADMIN_MEDIA_PREFIX }}js/admin/RelatedObjectLookups.js"></script>
        
        5. Write a few views - use PopcornMixin for popup views: ::
        
            class CreateUser(CreateView):
                model = User
        
            class PopcornGroup(PopcornMixin, CreateView):
                model = Group
        
            class PopcornPermission(PopcornMixin, CreateView):
                model = Permission 
        
        6. Use the utility function to generate popcorn urls: ::
        
            urlpatterns += get_popcorn_urls([PopcornGroup, PopcornPermission])
        
        7. Render your forms using the `boostrap_toolkit's` as_bootstrap filter: :: 
        
            {{ form|as_bootstrap }}
        
        8. Check out the demo project for a working implementation.
        
        
        
        History
        -------
        
        0.1.0 (2013-12-2)
        ++++++++++++++++++
        
        * First release on PyPI.
Keywords: django_popcorn
Platform: UNKNOWN
Classifier: Development Status :: 2 - Pre-Alpha
Classifier: Framework :: Django
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: BSD License
Classifier: Natural Language :: English
Classifier: Programming Language :: Python :: 2
Classifier: Programming Language :: Python :: 2.6
Classifier: Programming Language :: Python :: 2.7
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.3
