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
After #2346273: Allow user to select bundles per entity type on field settings page we can re-factor autocomplete route to use the selection plugin and field settings to show the suggestion.
Proposed resolution
Re-factor autocomplete route
Remaining tasks
Create a patch
User interface changes
None
API changes
N/A
Comment | File | Size | Author |
---|---|---|---|
#2 | Screenshot 2014-12-11 08.24.03.png | 16.4 KB | larowlan |
#1 | 2389599-Re-factor_autocomplete_route.patch | 10.97 KB | jibran |
Comments
Comment #1
jibranrewrite src/DynamicEntityReferenceController.php (70%)
It almost same as
EntityReferenceController
. I terms of security I love this patch cuz it improves a lot.While working on this I realized two things:
EntityReferenceController
DynamicEntityReferenceController
Comment #2
larowlanLooks good to me
Comment #4
jibranThanks for the review and testing. What you think about those two points in #1?
Comment #5
jibranCreated #2391139: Add entity_id to autocomplete route just like EntityReferenceController for #1.1
Comment #6
larowlanI'm all for points in 1 and 2 if you're keen.