"Even field module
Has plugins extending it.
Beats huge form alters."
Needs some work, ER plugins are for two things: behaviours and selection, behaviours define how the relationship is made or to react on ER CRUD, for instance ER ships with a taxonomy behavior plugin that updates taxonomy_build_node_index whenever a term id is added to a node, to mimic term reference field.
Selection plugins are to modify the selection form settings and widget, what I'll demonstrate is how I needed to provide a plugin for Commerce Coupon module, that has a field for coupon code but the id (target id) is different, so I needed to provide a diferent label for the autocomplete widget: http://drupalcode.org/project/commerce_coupon.git/blob/refs/heads/7.x-1.x:/plugins/selection/EntityReference_SelectionHandler_Generic_commerce_coupon.class.php
Current entity reference haiku:
"Even field module Has plugins extending it. Beats huge form alters."
Needs some work, ER plugins are for two things: behaviours and selection, behaviours define how the relationship is made or to react on ER CRUD, for instance ER ships with a taxonomy behavior plugin that updates taxonomy_build_node_index whenever a term id is added to a node, to mimic term reference field. Selection plugins are to modify the selection form settings and widget, what I'll demonstrate is how I needed to provide a plugin for Commerce Coupon module, that has a field for coupon code but the id (target id) is different, so I needed to provide a diferent label for the autocomplete widget: http://drupalcode.org/project/commerce_coupon.git/blob/refs/heads/7.x-1.x:/plugins/selection/EntityReference_SelectionHandler_Generic_commerce_coupon.class.php