mirror of https://github.com/django/django.git
Exposed model __doc__ in admin docs views which fixes #1408. Thanks, poelzi
git-svn-id: http://code.djangoproject.com/svn/django/trunk@2417 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
eeb848bdbd
commit
b830fa7e78
|
@ -16,6 +16,10 @@
|
|||
<div id="content-main">
|
||||
<h1>{{ summary }}</h1>
|
||||
|
||||
{% if description %}
|
||||
<p>{% filter escape|linebreaksbr %}{% trans description %}{% endfilter %}</p>
|
||||
{% endif %}
|
||||
|
||||
<div class="module">
|
||||
<table class="model">
|
||||
<thead>
|
||||
|
|
|
@ -185,6 +185,7 @@ def model_detail(request, model):
|
|||
return render_to_response('admin_doc/model_detail', {
|
||||
'name': '%s.%s' % (opts.app_label, opts.module_name),
|
||||
'summary': "Fields on %s objects" % opts.verbose_name,
|
||||
'description' : model.__doc__,
|
||||
'fields': fields,
|
||||
}, context_instance=DjangoContext(request))
|
||||
model_detail = staff_member_required(model_detail)
|
||||
|
|
Loading…
Reference in New Issue