Drupal Association members fund grants that make connections all over the world.
Is there a way to prepopulate inline entity form widget with a bundle type via URL?
I would like to add custom menu items to create node with each bundle type in this way:
I have a node type "Request" with a custom entity "Request Object", created within Request through inline entity form widget.
The Request Object is split into four bundles with absolutely different fields.
I can use the widget type "Inline entity form - Multiple values" to let the user select a bundle from dropdown on Request creation form.
But I only need to attach one form of one chosen bundle to each Request, so "Inline entity form - Single value" is more appropriate.
For now when I use the "Inline entity form - Single value" widget - I always get the first bundle form preloaded into my Request form.
I tried all the hooks available in inline_entity_form.api.php to change the attached form attributes concerning Bundle, but did not succeed.
Please, help me find an appropriate way to select an inline entity form bundle via an argument in custom menu link.
I'm sure this usecase could be useful to others. Thank you in advance.