-
|
Hello! For example, make the example below display as both were Parameters? Thanks! class Repository(MasterModel):
"""
Collection of content.
Fields:
name (models.TextField): The repository name.
pulp_labels (HStoreField): Dictionary of string values.
description (models.TextField): An optional description.
next_version (models.PositiveIntegerField): A record of the next version number to be
created.
retain_repo_versions (models.PositiveIntegerField): Number of repo versions to keep
user_hidden (models.BooleanField): Whether to expose this repo to users via the API
Relations:
content (models.ManyToManyField): Associated content.
remote (models.ForeignKeyField): Associated remote
pulp_domain (models.ForeignKeyField): The domain the Repository is a part of.
""" |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
|
The solution right now would be to update your docstrings like this: class Repository(MasterModel):
"""
Collection of content.
Parameters: Fields:
name (models.TextField): The repository name.
pulp_labels (HStoreField): Dictionary of string values.
description (models.TextField): An optional description.
next_version (models.PositiveIntegerField): A record of the next version number to be
created.
retain_repo_versions (models.PositiveIntegerField): Number of repo versions to keep
user_hidden (models.BooleanField): Whether to expose this repo to users via the API
Parameters: Relations:
content (models.ManyToManyField): Associated content.
remote (models.ForeignKeyField): Associated remote
pulp_domain (models.ForeignKeyField): The domain the Repository is a part of.
"""A maybe better solution would be to allow users to define aliases indeed 🙂 That would probably be implemented as a Griffe extension (new hooks needed!), and for sponsors only. Is it a well known and used convention in the Django community? |
Beta Was this translation helpful? Give feedback.
The solution right now would be to update your docstrings like this: