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.
Problem/Motivation
It is not possible to create a view of workspace entities currently as there's no views data handler defined in the entity annotation. This small addition would be quite useful as it could help building overviews of workspaces, which can be filtered, sorted, etc.
At the moment we require this for example in #3229061: Scheduled publishing of workspaces where we would like to build an overview of scheduled workspaces using views.
Comment | File | Size | Author |
---|---|---|---|
#8 | 3230095-8.patch | 2.4 KB | amateescu |
| |||
#8 | 3230095-8-test-only.patch | 1.77 KB | amateescu |
#2 | views-data-for-workspaces_3230095_2.patch | 650 bytes | s_leu |
Issue fork drupal-3230095
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
s_leu CreditAttribution: s_leu at Tag1 Consulting commentedHere's a patch that applies to both, 9.3.x and 8.9.x and adds a basic views data handler to the workspace entity annotation.
Comment #3
amateescu CreditAttribution: amateescu for Tag1 Consulting commentedLooks good to me!
Comment #4
alexpottI was pondering about test coverage. Obviously we missed this from our initial creation of the entity. I think it would be great to ensure that that workspace views at least are available so that we can be sure that we don't remove this in the future erroneously. The test does not need to do much beyond proving that you can make a view on a workspace as the base entity views data class is well tested already.
Comment #8
amateescu CreditAttribution: amateescu for Tag1 Consulting commentedAdded a quick test :)
Comment #10
longwaveCommitted and pushed 14496b9f6a to 10.1.x. Thanks!
Comment #12
amateescu CreditAttribution: amateescu for Tag1 Consulting commentedThanks, @longwave! This can most likely be backported all the way back to 9.5.x or even 9.4.x, right?
Comment #13
longwaveWell it's a feature and so should technically only go into 10.1.x now we are in release candidate phase, but also I don't see the harm in backporting; leaving open for other committers' opinions.
Comment #14
quietone CreditAttribution: quietone at PreviousNext commentedI think the window of opportunity for backport has passed here. Changing the status to fixed.