Fixed various minor doc typos / references.
This commit is contained in:
parent
ab431fbd4f
commit
67f9f385aa
|
@ -1707,9 +1707,9 @@ class InlineModelAdmin(BaseModelAdmin):
|
|||
"""
|
||||
Options for inline editing of ``model`` instances.
|
||||
|
||||
Provide ``name`` to specify the attribute name of the ``ForeignKey`` from
|
||||
``model`` to its parent. This is required if ``model`` has more than one
|
||||
``ForeignKey`` to its parent.
|
||||
Provide ``fk_name`` to specify the attribute name of the ``ForeignKey``
|
||||
from ``model`` to its parent. This is required if ``model`` has more than
|
||||
one ``ForeignKey`` to its parent.
|
||||
"""
|
||||
model = None
|
||||
fk_name = None
|
||||
|
@ -1771,8 +1771,8 @@ class InlineModelAdmin(BaseModelAdmin):
|
|||
# Take the custom ModelForm's Meta.exclude into account only if the
|
||||
# InlineModelAdmin doesn't define its own.
|
||||
exclude.extend(self.form._meta.exclude)
|
||||
# if exclude is an empty list we use None, since that's the actual
|
||||
# default
|
||||
# If exclude is an empty list we use None, since that's the actual
|
||||
# default.
|
||||
exclude = exclude or None
|
||||
can_delete = self.can_delete and self.has_delete_permission(request, obj)
|
||||
defaults = {
|
||||
|
|
|
@ -209,7 +209,7 @@ class Command(BaseCommand):
|
|||
field_type = 'TextField'
|
||||
field_notes.append('This field type is a guess.')
|
||||
|
||||
# This is a hook for DATA_TYPES_REVERSE to return a tuple of
|
||||
# This is a hook for data_types_reverse to return a tuple of
|
||||
# (field_type, field_params_dict).
|
||||
if type(field_type) is tuple:
|
||||
field_type, new_params = field_type
|
||||
|
|
|
@ -2144,7 +2144,7 @@ class ManyToManyField(RelatedField):
|
|||
|
||||
def _get_path_info(self, direct=False):
|
||||
"""
|
||||
Called by both direct an indirect m2m traversal.
|
||||
Called by both direct and indirect m2m traversal.
|
||||
"""
|
||||
pathinfos = []
|
||||
int_model = self.rel.through
|
||||
|
|
|
@ -930,7 +930,7 @@ def _get_foreign_key(parent_model, model, fk_name=None, can_fail=False):
|
|||
"""
|
||||
Finds and returns the ForeignKey from model to parent if there is one
|
||||
(returns None if can_fail is True and no such field exists). If fk_name is
|
||||
provided, assume it is the name of the ForeignKey field. Unles can_fail is
|
||||
provided, assume it is the name of the ForeignKey field. Unless can_fail is
|
||||
True, an exception is raised if there is no ForeignKey from model to
|
||||
parent_model.
|
||||
"""
|
||||
|
|
|
@ -795,7 +795,7 @@ storing a string.
|
|||
|
||||
If :meth:`.get_internal_type` returns a string that is not known to Django for
|
||||
the database backend you are using -- that is, it doesn't appear in
|
||||
``django.db.backends.<db_name>.creation.DATA_TYPES`` -- the string will still be
|
||||
``django.db.backends.<db_name>.creation.data_types`` -- the string will still be
|
||||
used by the serializer, but the default :meth:`.db_type` method will return
|
||||
``None``. See the documentation of :meth:`.db_type` for reasons why this might be
|
||||
useful. Putting a descriptive string in as the type of the field for the
|
||||
|
|
Loading…
Reference in New Issue