Updated #321
Problem/Motivation
Part of #1823450: [Meta] Convert core listings to Views. This also helps solve problems for #1978904: Convert comment_admin() to a Controller and #1946348: Convert all of confirm_form() in comment.admin.inc to the new form interface which currently needs special handling for confirm delete forms.
Proposed resolution
Converting the admin/content/comment* page to a view with operations would keep it more inline with the rest of core listing pages.
Remaining tasks
Review.
Manual testing.
User interface changes
Before Empty
After Empty
Before With Comment
After With Comment
API changes
- Not exactly a API change but if Views module is enable then comment admin page is replaced by a view.
- Adds
StringFormatter::getEntityUrl()
so that comment entity can be linked to permalink URL. - Adds comment delete action.
- Adds update hook to enable the comment admin view and comment delete action.
- Adds comment_permalink formatter and changes default comment subject formatter to comment_permalink.
- Adds commented_entity views field plugin to use the static cache of entity storage controller.
- Removes commented entity relationship from comment views data as it is a multiple entity reference field and we can't add relationship to all commented entities.
- Adds comment bulk form views field plugin.
- Removes admin controller class.
- And adds a lot of tests.