mirror of
https://github.com/django/django.git
synced 2025-08-04 02:48:35 +00:00
Fixed docs build with sphinxcontrib-spelling 7.5.0+.
sphinxcontrib-spelling 7.5.0+ includes captions of figures in the set of nodes for which the text is checked.
This commit is contained in:
parent
1058fc7023
commit
ac90529cc5
31 changed files with 128 additions and 127 deletions
|
@ -24,7 +24,7 @@ Let's see how this works by reordering the fields on the edit form. Replace
|
|||
the ``admin.site.register(Question)`` line with:
|
||||
|
||||
.. code-block:: python
|
||||
:caption: polls/admin.py
|
||||
:caption: ``polls/admin.py``
|
||||
|
||||
from django.contrib import admin
|
||||
|
||||
|
@ -53,7 +53,7 @@ And speaking of forms with dozens of fields, you might want to split the form
|
|||
up into fieldsets:
|
||||
|
||||
.. code-block:: python
|
||||
:caption: polls/admin.py
|
||||
:caption: ``polls/admin.py``
|
||||
|
||||
from django.contrib import admin
|
||||
|
||||
|
@ -87,7 +87,7 @@ There are two ways to solve this problem. The first is to register ``Choice``
|
|||
with the admin just as we did with ``Question``:
|
||||
|
||||
.. code-block:: python
|
||||
:caption: polls/admin.py
|
||||
:caption: ``polls/admin.py``
|
||||
|
||||
from django.contrib import admin
|
||||
|
||||
|
@ -121,7 +121,7 @@ Remove the ``register()`` call for the ``Choice`` model. Then, edit the ``Questi
|
|||
registration code to read:
|
||||
|
||||
.. code-block:: python
|
||||
:caption: polls/admin.py
|
||||
:caption: ``polls/admin.py``
|
||||
|
||||
from django.contrib import admin
|
||||
|
||||
|
@ -168,7 +168,7 @@ tabular way of displaying inline related objects. To use it, change the
|
|||
``ChoiceInline`` declaration to read:
|
||||
|
||||
.. code-block:: python
|
||||
:caption: polls/admin.py
|
||||
:caption: ``polls/admin.py``
|
||||
|
||||
class ChoiceInline(admin.TabularInline):
|
||||
#...
|
||||
|
@ -200,7 +200,7 @@ tuple of field names to display, as columns, on the change list page for the
|
|||
object:
|
||||
|
||||
.. code-block:: python
|
||||
:caption: polls/admin.py
|
||||
:caption: ``polls/admin.py``
|
||||
|
||||
class QuestionAdmin(admin.ModelAdmin):
|
||||
# ...
|
||||
|
@ -210,7 +210,7 @@ For good measure, let's also include the ``was_published_recently()`` method
|
|||
from :doc:`Tutorial 2 </intro/tutorial02>`:
|
||||
|
||||
.. code-block:: python
|
||||
:caption: polls/admin.py
|
||||
:caption: ``polls/admin.py``
|
||||
|
||||
class QuestionAdmin(admin.ModelAdmin):
|
||||
# ...
|
||||
|
@ -232,7 +232,7 @@ You can improve that by using the :func:`~django.contrib.admin.display`
|
|||
decorator on that method (in :file:`polls/models.py`), as follows:
|
||||
|
||||
.. code-block:: python
|
||||
:caption: polls/models.py
|
||||
:caption: ``polls/models.py``
|
||||
|
||||
from django.contrib import admin
|
||||
|
||||
|
@ -310,7 +310,7 @@ Open your settings file (:file:`mysite/settings.py`, remember) and add a
|
|||
:setting:`DIRS <TEMPLATES-DIRS>` option in the :setting:`TEMPLATES` setting:
|
||||
|
||||
.. code-block:: python
|
||||
:caption: mysite/settings.py
|
||||
:caption: ``mysite/settings.py``
|
||||
|
||||
TEMPLATES = [
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue