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.
Create an example search plugin for the Content Entity Example for integrating custom entity data into the core search system.
Comment | File | Size | Author |
---|---|---|---|
#7 | example-search-plugin-2643048-7-D8.patch | 35.64 KB | kentr |
#3 | example-search-plugin-2643048-3-D8.patch | 33.3 KB | kentr |
|
Comments
Comment #2
kentr CreditAttribution: kentr as a volunteer commentedComment #3
kentr CreditAttribution: kentr as a volunteer commentedComment #4
jkopel CreditAttribution: jkopel commentedPatch intalls cleanly.
Should probably include some documentation indicating what the plugin does at content_entity_example_contact/list and also indicate that one has to add a search page for "content entity example contacts" in order to make use of the plugin.
The patch introduces an error when creating search pages in the UI (for any entity type).
To reproduce:
1. Apply patch
2. Enable content_entity_example
3. Add a search page
This seems to happen regardless of which entity type I try to add a search page for.
The pages do get created, and the plugin/search seems to work just fine once the page is there.
Comment #5
Mile23Could we make this into a separate module which depends on content_entity_example?
That way we can do a better job of illustrating only one thing with each module.
Comment #6
kentr CreditAttribution: kentr as a volunteer commentedGood point.
Comment #7
kentr CreditAttribution: kentr as a volunteer commentedThis patch:
search_plugin_example
.content_entity_example_contact/list
.I couldn't reproduce the error mentioned in #4 when testing on core `8.0.3`.
Comment #9
kentr CreditAttribution: kentr as a volunteer commentedI don't know why the patch failed testing. In manual testing, it applied and worked as expected without introducing errors.
Unassigning myself from the issue until I have more time to work on it.
Comment #10
Mile23It seems some of this patch made its way to https://www.drupal.org/docs/8/api/entity-api/making-the-content-entity-s... (or vice-versa).