mirror of
https://github.com/django/django.git
synced 2025-08-04 19:08:28 +00:00
Fixed #26021 -- Applied hanging indentation to docs.
This commit is contained in:
parent
38575b007a
commit
4a4d7f980e
21 changed files with 185 additions and 107 deletions
|
@ -434,8 +434,9 @@ traceback by adding the following to your settings file::
|
|||
|
||||
import warnings
|
||||
warnings.filterwarnings(
|
||||
'error', r"DateTimeField .* received a naive datetime",
|
||||
RuntimeWarning, r'django\.db\.models\.fields')
|
||||
'error', r"DateTimeField .* received a naive datetime",
|
||||
RuntimeWarning, r'django\.db\.models\.fields',
|
||||
)
|
||||
|
||||
Fixtures
|
||||
--------
|
||||
|
|
|
@ -468,8 +468,10 @@ If the string contains exactly one unnamed placeholder, you can interpolate
|
|||
directly with the ``number`` argument::
|
||||
|
||||
class MyForm(forms.Form):
|
||||
error_message = ungettext_lazy("You provided %d argument",
|
||||
"You provided %d arguments")
|
||||
error_message = ungettext_lazy(
|
||||
"You provided %d argument",
|
||||
"You provided %d arguments",
|
||||
)
|
||||
|
||||
def clean(self):
|
||||
# ...
|
||||
|
@ -1817,8 +1819,11 @@ If you need more flexibility, you could also add a new argument to your custom
|
|||
|
||||
def add_arguments(self, parser):
|
||||
super(Command, self).add_arguments(parser)
|
||||
parser.add_argument('--extra-keyword', dest='xgettext_keywords',
|
||||
action='append')
|
||||
parser.add_argument(
|
||||
'--extra-keyword',
|
||||
dest='xgettext_keywords',
|
||||
action='append',
|
||||
)
|
||||
|
||||
def handle(self, *args, **options):
|
||||
xgettext_keywords = options.pop('xgettext_keywords')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue