group_blocks ECA model¶
Source: eca.eca.group_blocks.yml
Purpose: Renders group-context blocks that the dashboard and group pages depend on — "new subgroup", "new content", "new member" entry-point tiles.
Events the model listens to¶
| Plugin | Label |
|---|---|
eca_render:block |
Block: new subgroup |
eca_render:block |
Block: new content |
eca_render:block |
Block: new member |
Entities & contexts touched¶
block(rendered as ECA-driven blocks viaeca_render:block)groupcontext (the block decisions read the current group)
Why it exists¶
The FedMS dashboard surfaces action tiles for the most common operations a logged-in user can perform on the group they are viewing (create a subgroup, add content, invite a member). Visibility and link targets are driven by the user's role inside the group, which is exactly what ECA can express declaratively.
Editing notes / gotchas¶
- Block placement on the page is config (
block.block.*), not ECA. ECA controls content and visibility. Coordinate edits across both layers. - These blocks are referenced by
dashboard.dashboard.fedmsand by the groupdefaultview mode. If a tile disappears unexpectedly, check the permissions chain (group role → ECA condition → block visibility). - Don't hard-code role names in the model — use the role IDs and
let
roles_permissions.ymldefine labels.
Related issues¶
fedms/components/federation#19— Add content to groups.fedms/components/federation#35— Dashboard.
See also¶
- event_groups, session_groups — these models register the forms that the "new X" tiles link to.
- group_members — the "new member" tile drives into this flow.