Thanks. That's not quite what I need though because it looks like the
IDs for his records are entered free-form in a single text field and
then processed manually. What I need is exactly what the admin
interface does for "edit_inline" records. I have a form with multiple
records (either being added or edited) that all have the same parent
object. The parent object already exists regardless of whether I'm
adding or editing the related "edit_inline" records. I think I can use
a ChangeManipulator for the parent object type to  add or edit the
child records but I'm not sure how to access these related objects in
the ChangeManipulator, either in my views.py or in my template file.


Malcolm Tredinnick wrote:
> On Fri, 2006-06-16 at 07:19 +0000, char wrote:
> > I need to create an AddManipulator and a ChangeManipulator that can
> > handle ForeignKey fields in the same way that the admin pages work with
> > edit_inline fields but I'm not sure how to do this. Is there a sample
> > anywhere that shows how to do this?
>
> I'm not entirely sure what you are asking for here. But if you mean an
> example of where data for two (related) models are entered on the same
> form and then the manipulator saves to each model, have a look at this
> writeup Ian Holsman did last year:
>
>         http://feh.holsman.net/articles/2005/10/18/django-custommanipulators
>
> It may need a little bit of tweaking to work with the current codebase
> (in particular, the "new_data.setlist(...)" call needs to be updated),
> but it should give you the idea. Combine that with the information in
> the "Database API reference" documentation (particularly, creating new
> objects and assigning related objects) and you should be set.
> 
> Regards,
> Malcolm


--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to