Problem/Motivation
Right now EntityReferenceItem hardcodes dependencies from the DefaultSelection selection handler. Concretely, is using the DefaultSelection handler target_bundles
to build a list of dependencies, regardless of what effective handler is used by that field. But there are other selection handlers not extending DefaultSelection, like ViewsSelection (or even custom selection handlers) that have no target_bundles
setting (that belongs only to DefaultSelection). Those selection handlers are exposing other settings that are creating dependencies. Such dependencies are ignored when EntityReferenceItem calculates the field configuration dependencies. For example an entity reference field that uses a ViewsSelection selection handler should depend on the view that is configured in the field configuration. But right now in HEAD is not adding that view as dependency.
Proposed resolution
Copy ERItem changes to DERItem once #2786841: Entity reference fields should add selection handler config dependencies is fixed.
Remaining tasks
#2786841: Entity reference fields should add selection handler config dependencies
User interface changes
None
API changes
None
Comment | File | Size | Author |
---|---|---|---|
#4 | add_tests_for-2458353-4.patch | 2.8 KB | jibran |
Comments
Comment #1
jibranFirst pass.
Comment #2
jibranComment #3
jibranAdded the function in 27bc319 only needs tests now.
Comment #4
jibranCan't test it until we fix #2555027: Support non-numeric entity ID's.
Comment #5
jibran#2555027: Support non-numeric entity ID's is fixed.
Comment #6
jibranComment #7
jibranThe original issue is fixed in #2766187-34: Allow config entity references thanks to @jhedstrom. Let's rescope this issue to fix core ER issue #2786841: Entity reference fields should add selection handler config dependencies.
Comment #8
jibran