All Projects → chhantyal → Taggit Selectize

chhantyal / Taggit Selectize

Licence: bsd-3-clause
Auto-complete/auto-suggestion for django-taggit (django-taggit + selectize.js)

Programming Languages

javascript
184084 projects - #8 most used programming language
python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Taggit Selectize

Django Ledger
A bookkeeping & financial analysis engine for the Django Framework. UNDER ACTIVE DEVELOPMENT & NOT STABLE YET.
Stars: ✭ 253 (+301.59%)
Mutual labels:  django-application, django
E Commerce 2 django
Guest register, user register, user login, user logout, account home page, product view history, change password, reset password, change name, send activation email when register, resend activation email, add shipping address, add billing address, add nickname to the addresses, edit shipping address, edit billing address, view list of your addresses, reuse shipping addresses when order products, reuse billing addresses when ordeer products, show sales analytics if staff or admin only using -chart.js-, get analytics data with Ajax, receive marketing email, change if user will receive marketing email or not by admin, send contact message with Ajax, products list, product detail, download product detail as a PDF file, download digital product files -if the user purchased that digital product only-, orders list, list of digital products files, order detail, download order detail as a PDF file, verify order ownership with Ajax -to secure order detail page-, show cart products, add or remove product from cart, checkout page, thanks page when order placed successfully, add or reuse payment method, add or reuse payment method with Ajax, search products by title, search products by description, search products by price, search products by tag title, write tags for products -by admin only-, auto fill contact email, full name if user logged in.
Stars: ✭ 20 (-68.25%)
Mutual labels:  django-application, django
Django Easy Audit
Yet another Django audit log app, hopefully the simplest one.
Stars: ✭ 289 (+358.73%)
Mutual labels:  django-application, django
Niji
A pluggable Django forum APP
Stars: ✭ 173 (+174.6%)
Mutual labels:  django-application, django
Algo Phantoms Backend
💻 Algo-Phantoms-Backend is an Application that provides pathways and quizzes along with a code editor to help you towards your DSA journey.📰🔥 This repository contains the REST APIs of the application.✨
Stars: ✭ 36 (-42.86%)
Mutual labels:  django-application, django
College Erp
A college management system built using Django framework. It is designed for interactions between students and teachers. Features include attendance, marks and time table.
Stars: ✭ 187 (+196.83%)
Mutual labels:  django-application, django
Djangoforbeginners
Source code for Django For Beginners
Stars: ✭ 527 (+736.51%)
Mutual labels:  django-application, django
Django Dersleri
YouTube Django Dersleri için proje kaynak kodu
Stars: ✭ 135 (+114.29%)
Mutual labels:  django-application, django
Django Djeddit
Minimalistic Reddit clone developed as a Django reusable app
Stars: ✭ 32 (-49.21%)
Mutual labels:  django-application, django
Django Spectator
A Django app to track book reading, and event going.
Stars: ✭ 28 (-55.56%)
Mutual labels:  django-application, django
Django Settings Export
Access Django settings from templates the right way™
Stars: ✭ 167 (+165.08%)
Mutual labels:  django-application, django
Django Preferences
Django app allowing users to set app specific preferences through the admin interface.
Stars: ✭ 51 (-19.05%)
Mutual labels:  django-application, django
Patchman
Patchman is a Linux Patch Status Monitoring System
Stars: ✭ 163 (+158.73%)
Mutual labels:  django-application, django
Django Rest Registration
User-related REST API based on the awesome Django REST Framework
Stars: ✭ 240 (+280.95%)
Mutual labels:  django-application, django
Django mail admin
The one and only django app to receive & send mail with templates and multiple configurations.
Stars: ✭ 140 (+122.22%)
Mutual labels:  django-application, django
Meethub
This is a Python/Django based event management system. A meetup clone.
Stars: ✭ 411 (+552.38%)
Mutual labels:  django-application, django
Django Lockdown
Lock down a Django site or individual views, with configurable preview authorization
Stars: ✭ 123 (+95.24%)
Mutual labels:  django-application, django
Hsreplay.net
🔶 Unleash your Potential!
Stars: ✭ 132 (+109.52%)
Mutual labels:  django-application, django
Djangorestframework Book
Django REST framework 3 中文文档, API参考, 最佳实践指南
Stars: ✭ 28 (-55.56%)
Mutual labels:  django-application, django
Django Rename App
A Django Management Command to rename existing Django Applications.
Stars: ✭ 38 (-39.68%)
Mutual labels:  django-application, django

taggit-selectize

Auto-complete/auto-suggestion for django-taggit.

django-taggit + selectize.js

taggit-selectize demo screenshot

With django-taggit, you can attach tags in any Django models. However, user experience is not that good as it uses comma to separate multiple tags in same form field, and resulting in duplicate tags eg. Himalaya vs. Himalayas, Sublime-Text vs. Sublime Text etc. And you probably want auto-complete/auto-suggest feature when user types some characters in tag field. Thanks to selectize.js, we got that covered :)

Features

  • Supports Django 1.8.x and Django 1.9.x
  • Supports >=Python2.7 and >=Python3.4
  • Simple installation, selectize.js 0.12.1 included
  • Will use jQuery install included in Django admin, no installation of jQuery needed
  • Will use custom jQuery object if it is installed, though
  • Themed to match new Django 1.9 flat theme
  • Exposes many selectize.js configuration options to your settings.py
  • Supports multiple TaggableManagers in a single model

Quickstart

Install taggit-selectize:

pip install taggit-selectize

Usage

  1. Put taggit_selectize in settings:

    INSTALLED_APPS = (
        'django.contrib.admin',
        ...
        ...
        'taggit',
        'taggit_selectize',
    )
    
  2. Configured Taggit in your Django settings to use a custom string-to-tag parser that doesn't parse on spaces to match the functionality of Selectize.js, and a custom tag joiner that supports configurable delimiters.

    TAGGIT_TAGS_FROM_STRING = 'taggit_selectize.utils.parse_tags'
    TAGGIT_STRING_FROM_TAGS = 'taggit_selectize.utils.join_tags'
    
  3. Update urls.py.

    urlpatterns = [
        ...
    
        url(r'^taggit/', include('taggit_selectize.urls')),
        url(r'^admin/', include(admin.site.urls)),
        ...
    ]
    
  4. Use the TaggableManager from taggit_selectize (instead of taggit) in your models.

    from taggit_selectize.managers import TaggableManager
    
    class MyModel(models.Model):
        tags = TaggableManager()
    

Configuration

In your settings.py (these are defaults):

TAGGIT_SELECTIZE = {
    'MINIMUM_QUERY_LENGTH': 2,
    'RECOMMENDATION_LIMIT': 10,
    'CSS_FILENAMES': ("taggit_selectize/css/selectize.django.css",),
    'JS_FILENAMES': ("taggit_selectize/js/selectize.js",),
    'DIACRITICS': True,
    'CREATE': True,
    'PERSIST': True,
    'OPEN_ON_FOCUS': True,
    'HIDE_SELECTED': True,
    'CLOSE_AFTER_SELECT': False,
    'LOAD_THROTTLE': 300,
    'PRELOAD': False,
    'ADD_PRECEDENCE': False,
    'SELECT_ON_TAB': False,
    'REMOVE_BUTTON': False,
    'RESTORE_ON_BACKSPACE': False,
    'DRAG_DROP': False,
    'DELIMITER': ','
}

MINIMUM_QUERY_LENGTH

The minimum number of characters the user needs to type to cause an AJAX request to hit the server for autocompletion. Default: 2

RECOMMENDATION_LIMIT

The maximum number of results to return to the user for recommendation. Default: 10

CSS_FILENAMES

A tuple of CSS files to include on any page that has the taggit-selectize widget on it. Default: ("taggit_selectize/css/selectize.django.css",)

JS_FILENAMES

A tuple of JS files to include on any page that has the taggit-selectize widget on it. Default: ("taggit_selectize/js/selectize.js",)

DIACRITICS, CREATE, PERSIST, OPEN_ON_FOCUS, HIDE_SELECTED, CLOSE_AFTER_SELECT, LOAD_THROTTLE, PRELOAD, ADD_PRECEDENCE, SELECT_ON_TAB

Options that are passed directly to selectize.js. Please see the selectize.js documentation for explanation

REMOVE_BUTTON

Adds a remove button to each tag item by including the 'remove_button' plugin.

RESTORE_ON_BACKSPACE

Adds the 'restore_on_backspace' plugin to selectize.js.

DRAG_DROP

Adds the 'drag_drop' plugin to selectize.js. WARNING: This requires JQuery UI (Sortable) to be installed. If it's not, then selectize.js will throw an error in the console and refuse to run.

DELIMITER

Set the delimiter between tags, for example, ';' or '|'. Make sure you have set up the custom TAGGIT_STRING_FROM_TAGS for this to work properly with Taggit. Default is comma, ','.

Demo app

There is demo app included example_app.

  1. cd example_app
  2. python manage.py migrate
  3. python manage.py runserver

Login username: admin password: admin

Versions

  1. 0.x Initial release with Django 1.5 - 1.8 support. Latest upload on this series is 0.1.2. Use this if you need old Django support.

  2. 1.x Release with Django 1.9 support.

  3. 2.x This version might introduce backward incompatibility. It improves the way it works (widget instead of admin overrride) and adds many new features Thanks a ton to Nathan.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].