Hi,
I have created a webform called “Event Registration”.
I also created a content type “Event” with a webform field referencing the “Event Registration” webform.
Then I created some "Event" nodes and submitted some submissions. The webform results was tracking the “submitted to” very well.
I created a views page “Latest Events” that lists all the events (with event title field and the webform field).
The problem is:
when I use the views page to submit an “Event Registration” webform, the form is submitting, but when I check the webform submission “webform/manage/event_registeration/results/submissions” the “SUBMITTED TO” section is blank.
Also when I check Data (YAML) of the result, I found those also blank (entity_type: '' , entity_id: '') whereas the other submissions from normal nodes (The Event content type nodes) display “SUBMITTED TO” data properly (entity_type: node , entity_id: '113').
Another issue that I think it might be related to the previous one:
the webforms in views page (the previous page) do not receive [webform_submission:] tokens (like [webform_submission:node:nid], '[webform_submission:source-entity]', tec …) as default value for webform elements.
I hope I could make this clear.
Thanks for your help.
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | webform_fields_used_in-2859351-3.patch | 824 bytes | jrockowitz |
Comments
Comment #2
jrockowitz commentedThis is very difficult edge case.
A webform looks at the current page for the source entity. A View can't be a source entity.
You could try to...
I will look into passing the source entity to the submission form for the webform field.
I might be able to fix this but I am not promising anything.
Comment #3
jrockowitz commentedMaybe the attached patch will solve your problem.
Comment #5
jrockowitz commentedI committed the patch. Please download and review the latest dev release.
Comment #6
isamir commentedWorks perfectly.
Thank you Jacob for your quick reply, quick fix, and your great work in webform (one of the most complete and powerful modules in Drupal).
Also thanks for your awesome screencasts.
waiting for ajax support addition :)