Currently the panel_node_form() function has a hard-coded dependency on arg(3) to find the intended layout. This prevents clever devs from doing magical things with drupal_get_form() and drupal_execute(). The attached patch resolves this by allowing the $layout string to be passed along as part of the initial $node object, which seems pretty harmless and efficient.
Ideally I'd rather pass it as an additional argument for the panel_node_form() function, but node_form doesn't really allow this. The param value is there, but the doc for hook_form suggests it's not for this (although some preliminary noodling suggests it could work also).
Anyway, if desired I can try to recalibrate to use $param. However, the existing patch works for both get_form and execute use-cases.
| Comment | File | Size | Author |
|---|---|---|---|
| panels_node_form_layout.patch | 1.16 KB | joshk |
Comments
Comment #1
merlinofchaos commentedCommitted! Thanks for the patch!
Comment #2
Anonymous (not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.