Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Currently a Rules event is being invoked at the end of webform_workflow_transition(). While this is great for those who use Rules, I don't see any way for other code to run on state transition.
I'd like to see a hook invoked there for custom modules to implement.
Comment | File | Size | Author |
---|---|---|---|
#5 | webform_workflow-invoke_transition_hook-2775815-5.patch | 1.48 KB | lambic |
| |||
#3 | webform_workflow-invoke_transition_hook-2775815-2.patch | 1.2 KB | dtarc |
Comments
Comment #2
dtarc CreditAttribution: dtarc at Affinity Bridge commentedHere's a patch.
Comment #3
dtarc CreditAttribution: dtarc at Affinity Bridge commentedHere's a better patch
Comment #4
pjcdawkins CreditAttribution: pjcdawkins as a volunteer commentedComment #5
lambic CreditAttribution: lambic commentedThis hook was giving us problems when anything triggers token replacement, as that triggers a submission render, which tries to build the state form and ends up doing a redirect that kills everything. This patch addresses that by not rendering the form if the format is 'text'.