foo.updater = request.user ? In each view of Admin? Todd O'Bryan wrote: > You don't want to save the user id explicitly. Your model should be > > updater = models.ForeignKey(User) > > Since you'll be setting the updater (or some other better word) from > within a view, you'll have access to the currently logged-in user. > Just do > > foo.updater = request.user > > and you're good to go. > > Todd > > On Jun 13, 2006, at 7:09 PM, Nuno Mariz wrote: > > >>Ok, I agree. >>But if I want to save the ID of the user logged-in in a field in my >>table, I can't. >> >>Basically in almost of my tables I will have this fields: >>ip (IP Address) >>last_update (Record last update) >>user_id (User id that make the change)
--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users -~----------~----~----~----~------~----~------~--~---