Ticket #10111: 10111.patch

File 10111.patch, 997 bytes (added by medhat, 16 years ago)

I finally found the models in the modelforms page

  • django/trunk/docs/ref/contrib/admin.txt

     
    810810============================
    811811
    812812The admin interface has the ability to edit models on the same page as a
    813 parent model. These are called inlines. You can add them to a model by
    814 specifying them in a ``ModelAdmin.inlines`` attribute::
     813parent model. These are called inlines. Suppose you have these two models::
    815814
     815     class Author(models.Model):
     816        name = models.CharField(max_length=100)
     817
     818     class Book(models.Model):
     819        author = models.ForeignKey(Author)
     820        title = models.CharField(max_length=100)
     821
     822You can edit the books authored by an author on the author page. You add
     823inlines to a model by specifying them in a ``ModelAdmin.inlines``::
     824
    816825    class BookInline(admin.TabularInline):
    817826        model = Book
    818827
Back to Top