Skip to content

sontek-archive/django-tekextensions

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

admin popups

if using grappeli, copy RelatedObjectLookups.js to your admin_media folder from django's admin media

settings.py

TEMPLATE_CONTEXT_PROCESSORS = (
    'tekextensions.context_processors.admin_media_prefix',
)
INSTALLED_APPS = (
    'tekextensions',
)

urls.py

url(r'^add/(?P<model_name>\w+)/?$', 'tekextensions.views.add_new_model'),

forms.py

override any ModelChoiceField widget with SelectWithPopUp

from tekextensions.widgets import SelectWithPopUp
from django import forms

class CustomForm(forms.Form):
    company = forms.ModelChoiceField(CustomModel.objects, widget=SelectWithPopUp)

About

Re-usable views/templatetags/widgets for django applications

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages