10👍
✅
You can use one of the few autocomplete apps for Django. Check them at Django Packages.
There’s also django-extensions that have ForeignKeyAutocompleteAdmin
that fit your needs pretty well.
- Changing password in Django Admin
- Registered models do not show up in admin
- Django unable to find MySQLdb python module
12👍
You’re right, Cerin, the cause of the slowdown is because Django is populating the <select>
element with too many options. You might want to use an autocomplete element instead.
Interestingly, Django 2.0 has introduced a new feature on the admin site, called autocomplete_fields
, which I think you will find useful in this case. It uses AJAX.
class ExampleAdmin(models.ModelAdmin):
autocomplete_fields = ['example_field_user']
- Python Django custom template tags register.assignment_tag not working
- Converting a django ValuesQuerySet to a json object
- How can I schedule a Task to execute at a specific time using celery?
- What does it mean for an object to be unscriptable?
- Django. Error message for login form
- Django: WSGIRequest' object has no attribute 'user' on some pages?
- Django queryset __contains case sensitive?
- How to create custom groups in django from group
- Celery – No module named five
- ProgrammingError: relation "django_session" does not exist
Source:stackexchange.com