tags:

views:

17

answers:

1

I have a model:

class Review(models.Model):
    name = models.CharField(max_length = 50)
    link = models.CharField(max_length = 100)
    book_id = models.IntegerField()
    review_id = models.IntegerField()
    content = models.TextField()
    rating = models.IntegerField()
    author = models.CharField(max_length = 50)

If I open admin http://127.0.0.1:8000/admin/my_app/review/ I'll see the list of records. For each record Django Admin display only one field ('Name' in my case). How Django Admin choise the field to display in the list of records.

Firstly I thinked that it is a first field in my model. I have moved Name-field down in the field list and recreate the database, but there was nothing to change.

+3  A: 

Django calls the __unicode__ method on the model. For configuring the displayed fields in the change list see the detailed documentation!

lazerscience
+1. That is about all there is to it :)
Manoj Govindan