Tuesday, June 29, 2010

Re: Creating and binding more than one model to a from

On Jun 28, 6:47 pm, thusjanthan <thusjant...@gmail.com> wrote:
> Hi,
>
> I have a Topic class I would like to create a form based on. BUT, I
> want many of these objects so Topics. How do I obtain such a feature.
>
> Suppose my form object is as follows:
>
> class TopicForms(ModelForm):
>     class meta:
>         model = Topic
>         fields = ('topic_id','topic')
>
> I want to display more than one of the topics that is associated to a
> particular object. Suppose its a topic about obama and there are 10
> topics. I want to display all 10 of these. and If they make a change
> to one of them I would like to save that change on submission. I would
> also like to provide additional blank topic fields for end users to
> enter new topics about obama. Any help would be appreciated. I am a
> little confused on the forms area of django.
>
> Nathan.

Sounds a lot like "tagging". Have a look at this:
http://showmedo.com/videotutorials/video?name=1100020&fromSeriesID=110

Even if its not exactly what you want, it may give you some ideas...

--
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 django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

No comments:

Post a Comment