Re: How to get user ID and ID of newly created record in a CreateView?

2014-10-13 Thread Daniel Grace
I made a different approach after getting help, which I now have working: https://groups.google.com/forum/#!topic/django-users/eYDfCEZ0eQQ On Monday, 13 October 2014 14:45:09 UTC+1, Collin Anderson wrote: > > Hi Daniel, > > Interesting. Could you post a traceback? > > Thanks, > Collin > > -- You

Re: How to get user ID and ID of newly created record in a CreateView?

2014-10-13 Thread Collin Anderson
Hi Daniel, Interesting. Could you post a traceback? Thanks, Collin -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscr...@googlegroups.com. T

Re: How to get user ID and ID of newly created record in a CreateView?

2014-10-12 Thread Daniel Grace
I get the error: 'CreateFlow' object has no attribute 'user' How do I get the id of the record just created? -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to dja

Re: How to get user ID and ID of newly created record in a CreateView?

2014-10-10 Thread Daniel Roseman
On Friday, 10 October 2014 19:03:49 UTC+1, Daniel Grace wrote: > > Hi, I am using a CreateView. I want to create some related data on a > table ("Log" model), so I need the ID of the record being created for the > related field (see "flow" below). Also I need the ID of the user creating > the

How to get user ID and ID of newly created record in a CreateView?

2014-10-10 Thread Daniel Grace
Hi, I am using a CreateView. I want to create some related data on a table ("Log" model), so I need the ID of the record being created for the related field (see "flow" below). Also I need the ID of the user creating the record. Something like the following: from django.utils import timezone