{{{
class ArticleDetailView(DetailView):
}}}
In the "Generic editing views" (https://docs.djangoproject.com/en/3.1/ref
/class-based-views/generic-
editing/#django.views.generic.edit.CreateView.template_name_suffix) the
example is:
{{{
class AuthorCreate(CreateView):
}}}
(note that there is no `View` after `AuthorCreate`, like it was in the
`ArticleDetailView` example)
I was expecting it to be either:
{{{
class ArticleDetailView(DetailView)
class AuthorCreateView(CreateView)
}}}
or:
{{{
class ArticleDetail(DetailView)
class AuthorCreate(CreateView)
}}}
I'm happy to do a PR of any of the options. I'm slightly inclined for the
second one to keep it short and because usually these classes are in
`views.py`.
--
Ticket URL: <https://code.djangoproject.com/ticket/32271>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
* owner: nobody => Carles Pina Estany
* status: new => assigned
* stage: Unreviewed => Accepted
Comment:
Hi Carles. Yes, OK… 😄 I think this fits under the small cosmetic changes
not needing a ticket. If you'd like to make a PR `Fixed #32271 -- Improved
naming consistency in CBV code examples.` then that would be great.
--
Ticket URL: <https://code.djangoproject.com/ticket/32271#comment:1>
Comment (by Carles Pina Estany):
Thanks Carlton, I'll do it!
--
Ticket URL: <https://code.djangoproject.com/ticket/32271#comment:2>
* needs_better_patch: 0 => 1
* has_patch: 0 => 1
Comment:
[https://github.com/django/django/pull/13869 PR]
Hey Carles. I see you're midway through. 👍 Please uncheck ''Patch needs
improvement'' when it's finished and you're ready for review. Thanks.
--
Ticket URL: <https://code.djangoproject.com/ticket/32271#comment:3>
* owner: Carles Pina Estany => (none)
* status: assigned => new
* easy: 0 => 1
--
Ticket URL: <https://code.djangoproject.com/ticket/32271#comment:4>
Comment (by Jack Aitken):
Replying to [comment:3 Carlton Gibson]:
Hi Carlton, is this still open or does it need work? Happy to help.
> [https://github.com/django/django/pull/13869 PR]
>
> Hey Carles. I see you're midway through. 👍 Please uncheck ''Patch needs
improvement'' when it's finished and you're ready for review. Thanks.
--
Ticket URL: <https://code.djangoproject.com/ticket/32271#comment:5>
Comment (by David Smith):
Hi Jack -- there was work done on the pr I've linked below, but the
comments made on the PR need addressing. If you have capacity to finish
this off that would be great.
https://github.com/django/django/pull/13869
--
Ticket URL: <https://code.djangoproject.com/ticket/32271#comment:6>
Comment (by Jack Aitken):
Replying to [comment:6 David Smith]:
Thanks, David. I've been reviewing the history and it looks like there
were some comments by Mariusz regarding the previous commit. Here's what I
can gather from those comments about what should be left alone:
1. Examples in the tutorials (tutorial04.txt and tutorial05.txt) should be
left alone.
2. HomePageTemplateView should be left as HomePageView.
3. AboutView should remain as AboutView
Otherwise, I can go through the changes that Carles made create a new PR,
if this is all agreeable to you.
--
Ticket URL: <https://code.djangoproject.com/ticket/32271#comment:7>
Comment (by Carles Pina Estany):
Thanks Jack for continuing the PR! Really appreciate the continuation :)
--
Ticket URL: <https://code.djangoproject.com/ticket/32271#comment:8>
Comment (by Jack Aitken):
It's my pleasure, Carles!
PR was made. Here is the link:
[https://github.com/django/django/pull/14069]
--
Ticket URL: <https://code.djangoproject.com/ticket/32271#comment:9>
* needs_better_patch: 1 => 0
* stage: Accepted => Ready for checkin
--
Ticket URL: <https://code.djangoproject.com/ticket/32271#comment:10>
* owner: (none) => Mariusz Felisiak <felisiak.mariusz@…>
* status: new => closed
* resolution: => fixed
Comment:
In [changeset:"5fd4f22d196fbe9913884259ddedad10e6156a44" 5fd4f22]:
{{{
#!CommitTicketReference repository=""
revision="5fd4f22d196fbe9913884259ddedad10e6156a44"
Fixed #32271 -- Improved consistency of docs CBV examples.
Co-Authored-By: Carles Pina i Estany <car...@pina.cat>
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/32271#comment:11>
Comment (by Mariusz Felisiak <felisiak.mariusz@…>):
In [changeset:"9f277c3a7c5c60b749899d46a0aeb0e22c2b3d28" 9f277c3a]:
{{{
#!CommitTicketReference repository=""
revision="9f277c3a7c5c60b749899d46a0aeb0e22c2b3d28"
[3.2.x] Fixed #32271 -- Improved consistency of docs CBV examples.
Co-Authored-By: Carles Pina i Estany <car...@pina.cat>
Backport of 5fd4f22d196fbe9913884259ddedad10e6156a44 from master
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/32271#comment:12>