Code

Opened 5 years ago

Closed 5 years ago

#11454 closed (fixed)

ModelAdmin documentation correction

Reported by: m0nonoke Owned by: nobody
Component: Documentation Version: master
Severity: Keywords: typo
Cc: Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

For the url http://docs.djangoproject.com/en/dev/ref/contrib/admin/#modeladmin-options

The section OTHER METHODS > ModelAdmin.history_view

Code example

class MyModelAdmin(admin.ModelAdmin):

    # A template for a very customized change view:
    change_form_template = 'admin/myapp/extras/openstreetmap_change_form.html'

    def get_osm_info(self):
        # ...

    def change_view(self, request, object_id, extra_context=None):
        my_context = {
            'osm_data': self.get_osm_info(),
        }
        return super(MyModelAdmin, self).change_view(request, object_id,
            extra_context=my_context))

On the last line brackets do not balance.

Attachments (1)

bug-11454.diff (534 bytes) - added by seveas 5 years ago.
Trivial patch

Download all attachments as: .zip

Change History (4)

Changed 5 years ago by seveas

Trivial patch

comment:1 Changed 5 years ago by seveas

  • Has patch set
  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset

comment:2 Changed 5 years ago by timo

  • Keywords typo added
  • milestone 1.0.3 deleted
  • Triage Stage changed from Unreviewed to Ready for checkin
  • Version changed from 1.0 to SVN

comment:3 Changed 5 years ago by russellm

  • Resolution set to fixed
  • Status changed from new to closed

(In [11217]) Fixed #11454 -- Corrected mismatched parenthesis in admin docs. Thanks to seveas for the report.

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.