I have two custom entities, Foo and Bar. Bar has a has_one relationship with Foo through an entity_reference column.

I'd like an admin page that combines the forms of both entities. Ideally it would look something like:

Edit Foo

Name: ...
Description: ...


Name        Description        val1        val2
bar1        ...                ...         ...
bar2        ...                ...         ...
bar3        ...                ...         ...

[ add bar ]

[ save ]    [ delete ]

Ideally there would be inline Bar editing.

At the moment I have custom entities set up to use _entity_form and so they are edited on separate pages. This isn't ideal given their relationship. What's the best approach for combining forms in this way?

Many thanks.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.