Try this http://code.djangoproject.com/wiki/CookBookThreadlocalsAndUser
On Jun 17, 6:02 am, saxon75 <[EMAIL PROTECTED]> wrote:
> I'm working on a CMS application and had a question about
> automatically setting certain model fields.
>
> Suppose I have the following model (this is simplified from
On Jun 16, 9:46 pm, "Ronny Haryanto" <[EMAIL PROTECTED]> wrote:
> Another way (which I personally prefer because it's more explicit and
> clear), is to do it in the view. Don't show the author field in the
> form, because we want to automatically add it before saving.
>
> def add_item(request):
>
On Tue, Jun 17, 2008 at 9:02 AM, saxon75 <[EMAIL PROTECTED]> wrote:
> I'm working on a CMS application and had a question about
> automatically setting certain model fields.
>
> Suppose I have the following model (this is simplified from the actual
> application):
>
> class Item(models.Model):
>
On Tue, Jun 17, 2008 at 9:02 AM, saxon75 <[EMAIL PROTECTED]> wrote:
>
> I'm working on a CMS application and had a question about
> automatically setting certain model fields.
>
> Suppose I have the following model (this is simplified from the actual
> application):
>
> class Item(models.Model):
>
I'm working on a CMS application and had a question about
automatically setting certain model fields.
Suppose I have the following model (this is simplified from the actual
application):
class Item(models.Model):
author = models.ForeignKey(User)
created = models.DateTimeField()
title
5 matches
Mail list logo