David
I think the solution is to look at the admindocs source and tweak it to
do what you want and submit a patch.
The target audience for admindocs is template authors. This means you
are possibly trying to make admindocs do something it wasn't designed to
do. I don't mean your specific problem because I think template authors
do need to see the inheriting model docstring. Rather, it is possible
you want admindocs for developer documentation.
I discovered this recently when a patch I submitted was rejected on
those grounds. I wanted to see model methods with args documented but
that takes admindocs away from its objectives. Template authors can't
use arguments when using model methods.
Mike
On 11/11/2012 1:15am, David Simmons wrote:
Hi
I'm using Django 1.4.2. I have a base model:
class Account(models.Model):
account_id = models.CharField(max_length=10, unique=True)
name = models.CharField(max_length=50)
balance = models.DecimalField(max_digits=20, decimal_places=2)
and I have child model that inherits from the base model:
class BankAccount(Account):
"""
Stores an instance of a Bank Account.
"""
bank_name = models.CharField(max_length=50)
sort_code = models.CharField(max_length=8)
The details of the BankAccount show up in the Admin Docs but the doc string
describing the BankAccount does not. Am I doing something wrong?
many thanks for your help
Dave
--
You received this message because you are subscribed to the Google
Groups "Django users" group.
To view this discussion on the web visit
https://groups.google.com/d/msg/django-users/-/28407o7fHOoJ.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/django-users?hl=en.
--
You received this message because you are subscribed to the Google Groups "Django
users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/django-users?hl=en.