Re: Form field with suggestions rather than binding choices

2012-08-29 Thread Giuseppe Saviano
On Wed, Aug 29, 2012 at 4:17 PM, Vikas Rawal wrote: > I want to have a field in which the drop-down menu lists some > suggestions that the user may choose from, or if nothing suits, the > user may enter something other than what is available on the menu. I think you should use a properly modified

Re: ListView and Deleteview

2015-02-02 Thread Giuseppe Saviano
> views.py: > > def PozoList(ListView): > model = Pozo > template_name = 'cuencas/edicioncuenca.html' > Is your view a function or a class? -- $ gpg --recv-key da5098a7 -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe fr

Re: Problem when getting the ID of the record just created

2014-10-13 Thread Giuseppe Saviano
On Mon, Oct 13, 2014 at 3:13 PM, Daniel Grace wrote: > Hi, > I have problem when getting the ID of the record just created. > > class CreateFlow(CreateView): > model = Flow > fields = ['state'] > template_name = 'create_flow.html' > def form_valid(self, form): > user = User

Re: Problem when getting the ID of the record just created

2014-10-13 Thread Giuseppe Saviano
> User.objects.get(pk=self.request.user.id) because request.user is your > user object. > it's self.request.user - sorry. But the sense is the same: you don't need User.objects.get -- $ gpg --recv-key da5098a7 -- You received this message because you are subscribed to the Google Groups "Djang