Attachment types¶
An attachment type (fedms_attachment_type config entity) is a
bundle of the fedms_attachment content entity. Attachment types
let you model the categories of artifact that get attached to events
or sessions and that may carry their own task patterns.
Where to manage attachment types¶
1 | |
When to define a new attachment type¶
Define a new attachment type when you have a distinct category of artifact with:
- Its own metadata (fields beyond the default label / description / visibility / assignee).
- Its own task patterns (e.g. "watch the recording", "sign the consent").
- Its own access rules (e.g. some attachments are speaker-only; others are delegate-only).
Examples¶
| Attachment type | Purpose |
|---|---|
| Recording | Video/audio of a session. Used with the Attachment Recording recipe. |
| Signed consent | Legal documents that need a signature workflow. |
| Pre-read pack | Pre-event reading material. |
| Survey response | Captured questionnaire results. |
| Certificate | Issued certificates post-event. |
Out of the box, FedMS ships one attachment type: default.
Customers add more as they need them.
Default attachment fields¶
Every attachment, regardless of type, carries:
label— display name.description(paragraph field) — body content.group— the event or session it belongs to.assignee— one or more users responsible.visibility—private(assignees only),group(group members),public.fedms_task_patterns— task patterns to spawn.
The default type also ships field_video (used by the recipe).
Adding fields to an attachment type¶
The field-management UI is at
/admin/structure/fedms_attachment_types/manage/<type>/fields.
Use the same approach as for event/session types:
- Add the fields you need.
- Configure form and view displays.
- Group fields with
field_groupfor usability.
Task patterns on attachments¶
Attachments are particularly powerful as carriers of task patterns. The pattern says "spawn a task pointing at this attachment for these users". This is how you turn a single attachment into a real workflow — e.g. "everyone needs to watch this recording".
The getReferencingEntities() method on TaskPattern includes
attachments alongside nodes, media, and webforms when looking for
things to spawn tasks for.
Visibility scoping¶
The visibility field on an attachment is read by the
group_members and access
ECA models when deciding whether to show the attachment to a
particular user. Three levels:
private— only the assignees of the attachment can see it.group— any member of the group can see it.public— visible to anyone with access to the group's parent context.
Next steps¶
- Event types — the parent context for attachments.
- Task patterns — what attachments spawn.
- Recipes → Attachment Recording — the recording-specific feature.