Top "Django-models" questions

For questions concerning use of the model class from the web framework Django.

AttributeError: module Django.contrib.auth.views has no attribute

In my Django app useraccounts, I created a Sign-Up form and a model for my Sign-up. However, when I went …

python django django-models django-forms attributeerror
Django ModelForm: What is save(commit=False) used for?

Why would I ever use save(commit=False) instead of just creating a form object from the ModelForm subclass and …

django django-models django-forms
Resize fields in Django Admin

Django tends to fill up horizontal space when adding or editing entries on the admin, but, in some cases, is …

python django django-models django-admin
Django delete FileField

I'm building a web app in Django. I have a model that uploads a file, but I can not delete …

django django-models
Django request to find previous referrer

I am passing the request to the template page.In django template how to pass the last page from which …

django django-models django-templates django-views
Django FileField with upload_to determined at runtime

I'm trying to set up my uploads so that if user joe uploads a file it goes to MEDIA_ROOT/…

python django django-models
Django migrate --fake and --fake-initial explained

I've been a user of Django for about 2 years now and there is a feature I have always been afraid …

django django-models django-migrations
In Django, how does one filter a QuerySet with dynamic field lookups?

Given a class: from django.db import models class Person(models.Model): name = models.CharField(max_length=20) Is it possible, …

python django django-models
Django: add image in an ImageField from image url

please excuse me for my ugly english ;-) Imagine this very simple model : class Photo(models.Model): image = models.ImageField(…

python django urllib django-models
How to show all fields of model in admin page?

here is the models page In this picture, only the title shows up on here, I used: def __unicode__(self): …

django-models django-admin