Skip to content

Organisers can contact members through UI - #3084

Draft
davidmillen50 wants to merge 21 commits into
codebar:masterfrom
davidmillen50:2310-organisers-can-contact-members-through-ui
Draft

davidmillen50 wants to merge 21 commits into
codebar:masterfrom
davidmillen50:2310-organisers-can-contact-members-through-ui

Conversation

@davidmillen50

@davidmillen50 davidmillen50 commented Nov 10, 2026 •

Copy link
Copy Markdown
Contributor

relates to #2310

notes:
the email body text body will take html and render it in the email. Simple_format is used in contact.html.haml and Rails sanitizes simple_format input by default. Any disallowed tags and unsafe attributes should be removed; common formatting html tags may still render.

Access to the contact form (menu item "Contact chapter" and the /admin/chapter_contacts and /admin/chapters/:id/contact routes)

Who has access:

  • admins: all chapters
  • global organisers (the organiser role with no chapter): all chapters
  • chapter organisers: their own chapters only
  • workshop, event and meeting organisers: the chapter(s) their workshop, event or meeting belongs to

Who does not have access (no menu item, and direct URLs redirect to the home page):

  • students
  • coaches
  • regular members with no role
  • logged out visitors
  • banned members, including banned admins and organisers
  • organisers of a different chapter (blocked from other chapters' contact forms)
  • members who have not accepted the terms and conditions (redirected to the terms page first)

Access is enforced by ChapterPolicy#contact? and #contact_index? in every controller action, and the menu item uses the same policy. Covered by policy, controller and feature specs.

Testing

I tested each email group locally and they all sent emails correctly:

  • all chapter members
  • custom list
  • leadership team
  • chapter organisers
  • active in the last month
  • inactive in the last month
  • event rsvp status

tested admin/organiser who hasn't accepted terms and conditions cannot access the contact page ✅

  • students
  • coaches
  • regular members with no role
  • logged out visitors
  • banned members, including banned admins and organisers
  • organisers of a different chapter (blocked from other chapters' contact forms)
  • members who have not accepted the terms and conditions (redirected to the terms page first)

Screenshots
Example of sending to a group
Go to Menu/contact chapter
image
image

image image image image

davidmillen50 and others added 4 commits November 10, 2026 13:48
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
davidmillen50 and others added 17 commits November 10, 2026 14:54
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Block banned members from the chapter contact menu and routes, allow
workshop, event and meeting organisers to contact their chapter, and add
policy, controller and feature coverage for access by role.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…roles

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant