Opened 9 years ago
Last modified 9 years ago
#25473 closed Cleanup/optimization
Docs: 'author-detail' vs 'author_update' — at Version 1
Reported by: | Thomas Güttler | Owned by: | nobody |
---|---|---|---|
Component: | Documentation | Version: | 1.8 |
Severity: | Normal | Keywords: | |
Cc: | gayathri Menakath | Triage Stage: | Accepted |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | yes | UI/UX: | no |
Description (last modified by )
Please use one form to refer to the update-view of
a model.
Here are two: 'author-detail' vs 'author_update'
def get_absolute_url(self): return reverse('author-detail', kwargs={'pk': self.pk})
from https://docs.djangoproject.com/en/1.8/topics/class-based-views/generic-editing/#model-forms
some lines below the above link:
url(r'author/(?P<pk>[0-9]+)/$', AuthorUpdate.as_view(), name='author_update'),
But first: The django core developers should decide which pattern should be used in the docs:
foo-detail or foo_update.
When the decision was made, then all examples in the docs should use this pattern.
Note:
See TracTickets
for help on using tickets.