On Sep 30, 7:39 am, Alex Koshelev <[EMAIL PROTECTED]> wrote:
> If you what to provide some init state for form - use `initial` param

I tried to use the 'intial' param, however,

i = {'title':'Old news'}
a = Article.objects.get(title='Big news')
f = ArticleForm(initial=i, instance=a)

In [50]: f.initial
Out[50]: {'title':'Old news'}

In [51]: f.is_valid()
Out[51]: False

In [52]: f.errors
Out[52]: {}





--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to