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.
It would be good to use default views instead of the hard coded listing pages like the webform submissions listing (webform_results_submissions).
It would make it easy for administrators to modify the listings.
Comment | File | Size | Author |
---|---|---|---|
#5 | webform_views_dependency-2036805.patch | 326 bytes | quicksketch |
Comments
Comment #1
quicksketchThanks for opening this issue, I've been thinking about doing this in the 4.x branch, though it will mean that Views (and CTools) become a dependency for Webform. I don't think that's a problem, especially with the majority of both modules built into Drupal 8 core.
Although it's an issue to follow-up on this one, I'd like end-users to be able to add/remove columns for components for individual webform listing pages. The main submissions listing page just isn't very helpful showing usernames for example if only anonymous users fill out the forms. I imagine this would be implemented as a special field type in Views, but I haven't figured out exactly how that would work yet.
This relates to #1589582: Add checkbox on the webform result page so user can select multiple result and delete them (Views Bulk Operation style) pretty heavily also.
Comment #2
rooby CreditAttribution: rooby commentedYour anonymous user example is exactly why I went looking for this.
I think it would be one of the more common use cases.
Comment #3
quicksketchI think a good first step is simply requiring CTools and Views as dependencies for Webform 4.x, even if we're not using them yet. That enables us to add these pages as views later.
Comment #4
bharata CreditAttribution: bharata commentedI would think that this brilliant move would also open the door for the much desired ability to "score" webform results.
For example, with a series of true/false questions the total number of true responses could now easily be added up using Views calculate function.
There are TONS of other applications coming to mind related to this functionality.
Comment #5
quicksketchAlthough I'm sad the effect this has on the modules page (lots more module dependencies being listed), I think making Webform depend on Views is the right move and it will enable us to convert listings later. So for now I've committed this patch as a stop-gap to allow us to move to a final release and convert listings to Views later.
Comment #7
fenstrat#5 needs porting to 8.x-4.x.
Comment #8
fenstratCommitted and pushed to 8.x-4.x.
Moving back to Active as the dependency is only the first step here.
Comment #10
DanChadwick CreditAttribution: DanChadwick commentedEven though this is the older issue, there is more discussion about removing hard-coded tables in the related issue.