Problem/Motivation
In #3252386: Use PHP attributes instead of doctrine annotations we added support for attribute based plugin discovery.
As part of that issue we converted block and action plugins.
This issue is to convert \Drupal\views\Annotation\ViewsRow
plugins to use Attributes.
To do that we need #3421008: Convert ViewsExposedForm plugin discovery to attributes first. This issue is postponed on that.
Proposed resolution
- Add a class to represent the new Attribute - Example
- Update the plugin manager constructor to include both the attribute and annotation class names - example
- Convert all plugins that use the annotation to use the new attribute - example
Remaining tasks
User interface changes
API changes
Data model changes
Release notes snippet
Issue fork drupal-3420999
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
larowlanComment #3
larowlanComment #4
larowlanComment #5
alexpottComment #8
sorlov CreditAttribution: sorlov at Skilld commentedComment #9
sorlov CreditAttribution: sorlov at Skilld commentedComment #10
smustgrave CreditAttribution: smustgrave at Mobomo commentedMR appears to have a failure. May need a rebase
Comment #11
sorlov CreditAttribution: sorlov at Skilld commentedComment #12
mstrelan CreditAttribution: mstrelan at PreviousNext commentedSame suggestions as #3426961-10: Convert ViewsSort plugin discovery to attributes
Comment #13
sorlov CreditAttribution: sorlov at Skilld commentedpreviously, ViewsRow annotation extends ViewsPluginAnnotationBase, not ViewsHandlerAnnotationBase
so we don't need to use PluginID here
Comment #14
smustgrave CreditAttribution: smustgrave at Mobomo commentedSearched for @ViewsRow and all 13 instances were converted
Seems the suggestion of using PluginID has been addressed.
Tests are green now.
Comment #15
alexpottCommitted and pushed 7184e9458c to 11.x and 498ce9e1a1 to 10.3.x. Thanks!