Re: Proposal for simplifying part of the GCBV API slightly.

2013-05-12 Thread Tom Christie
Right now that ticket's just got a cautious +0 against it. I still think this would be a small step in the right direction of presenting a slightly simpler GCBV API, but unless there's any further support I'm inclined to give the ticket a few more days and then close it. On Thursday, 2 May 2013

Re: Proposal for simplifying part of the GCBV API slightly.

2013-05-02 Thread Tom Christie
I've created ticket #20432 for this proposal. I don't know if it needs to go to 'design decision needed', but if it gets approved I'll plan to work on it at the DjangoCon sprints, aiming for the 1.6 alpha. Tom On Monday, 22 April 2013 14:40:09

Re: Proposal for simplifying part of the GCBV API slightly.

2013-04-22 Thread Andrew Ingram
The original use case for pk_url_kwarg and slug_url_kwargs was something like this: /(?P[\w-]*)/ - DetailView /(?P[\w-]*)/another-resource/ - Scoped ListView /(?P[\w-]*)/another-resource/(?P[\w-]*) - Scoped DetailView In this case, the Scoped ListView and Scoped DetailView would both inherit a

Re: Proposal for simplifying part of the GCBV API slightly.

2013-04-22 Thread Tom Christie
Hi Calvin, I can think of a few reasons. > - you've changed models or fields internally through migrations, but need > to continue supporting old URLs. > - you don't like the internal name to be exposed > - you have different models but want to expose a consistent URL pattern. Those attributes

Re: Proposal for simplifying part of the GCBV API slightly.

2013-04-22 Thread Calvin Spealman
On Apr 22, 2013 7:15 AM, "Tom Christie" wrote: > > I'd be interested to know what you folks think of this proposal. > > SingleObjectMixin currently exposes these three attributes and one method all dealing with queryset filter arguments... > > * pk_url_kwarg = 'pk' > *

Proposal for simplifying part of the GCBV API slightly.

2013-04-22 Thread Tom Christie
I'd be interested to know what you folks think of this proposal. SingleObjectMixin currently exposes these three attributes and one method all dealing with queryset filter arguments... * pk_url_kwarg = 'pk' * slug_field = 'slug' * slug_url_kwarg = 'slug' * get_slug_field() I was wondering if