django-chosen

Django FormFields using the Chosen JavaScript plugin for jQuery
Download

django-chosen Ranking & Summary

Advertisement

  • Rating:
  • License:
  • BSD License
  • Price:
  • FREE
  • Publisher Name:
  • Frankie Dintino
  • Publisher web site:
  • https://github.com/theatlantic/

django-chosen Tags


django-chosen Description

django-chosen is a Django app that makes available Django FormFields that uses the Chosen JavaScript plugin. It was created by developers at The Atlantic.InstallationThe recommended way to install from source is with pip: pip install -e git+git://github.com/theatlantic/django-chosen.git#egg=django-chosenIf the source is already checked out, use setuptools: python setup.py installUsagedjango-chosen makes the following fields and widget available:Fields:- ChosenChoiceField- ChosenModelChoiceField- ChosenMultipleChoiceField- ChosenModelMultipleChoiceFieldWidgets:- ChosenSelect- ChosenSelectMultipleThe django-chosen fields can be passed an optional kwarg overlay that overrides the text which appears when no option is selected in the dropdown.Examplefrom django import formsfrom chosen import forms as chosenformsclass BookForm(forms.Form): name = forms.CharField(max_length=100) quality = chosenforms.ChosenChoiceField(overlay="Select book quality...", choices=(('New', 'new'), ('Used', 'used'))) authors = chosenforms.ChosenModelMultipleChoiceField(queryset=Author.objects.all())Product's homepage


django-chosen Related Software