eca_field_widget_actions
3 sites
Security covered
ECA Field Widget Actions
How it works
Integrates ECA with the Field Widget Actions module, allowing you to build custom field widget action buttons powered by ECA models.
How it works
The Field Widget Actions module attaches action buttons to form fields -- for example a "Suggest" button next to a text field. This module bridges those buttons to ECA so you can define what happens when a button is clicked using an ECA model instead of custom code.
- Create an ECA model with the ECA Field Widget event.
- The module automatically registers a Field Widget Action plugin for that model. It appears in the list of available actions for any field widget.
- When a user clicks the action button on a form, the ECA event fires with the current entity, field name, and field index as context.
- Your ECA model evaluates conditions and executes actions -- for example calling an external API or processing the entity's existing field values.
- Use the Set field widget value action to return a value (or a list of suggestions) back to the field widget.
This is useful for content suggestions, AI-powered field filling, data lookups, or any scenario where a field value should be computed on demand.