Skip to content

Capstone: the team adds and removes its mentors - #2081

Closed
svaka2000 wants to merge 5 commits into
Open-Coding-Society:mainfrom
svaka2000:feat/capstone-mentor-chat
Closed

svaka2000 wants to merge 5 commits into
Open-Coding-Society:mainfrom
svaka2000:feat/capstone-mentor-chat

Conversation

@svaka2000

Copy link
Copy Markdown
Contributor

Under the team chat, a capstone page now lists the team's mentors, and the team can add and remove them.

A group member's view: the chat and the Mentors list with Find a mentor
The mentor's view: the chat and the Mentors list, with no search

  • The Mentors list shows the members Spring marks as mentors in the team's group.
  • A teacher or admin, or a group member who isn't a mentor, can search for mentors a teacher verified and add or remove them. A mentor only sees the list.
  • When Spring refuses a change (for example, the group needs 2 members who aren't mentors first), the Mentors list says why.

How it fits with Darshan's work:

Other notes:

How to try it (with Open-Coding-Society/spring#303):

  1. Sign in as someone in OCS Comm and Cap, open /capstone/communication-system/, search a mentor's name under Mentors and click Add. (A mentor is an account with ROLE_MENTOR.)
  2. Sign in as that mentor and open the page. They see the chat and the list, with no search.

A project post names its team's group in Messages with
capstone_project.team_group and places capstone-team-chat.html where
the chat goes. The page shows that group's chat (Messages'
mountGroupChat) with a link to the group in Messages: to its members,
to a mentor in the group once it has at least 2 members who aren't
mentors, and to teachers and admins. Anyone else gets a note saying
the chat is for the team.

Everyone looks for the group in their own groups first, and only a
teacher who isn't a member searches by name, so a mentor's browser
never calls a route Spring refuses mentors. Without team_group, or on a
Flask-only site, nothing renders. The words are in data/team_chat.yml.
The post names our team's group in Messages, OCS Comm and Cap, as
capstone_project.team_group and places the team chat below the
infograph. Inside the comms-infograph wrapper, infograph.scss would
restyle the chat (every class ending in -title is 2.75rem there).
Spring lists a group to its mentor only once they're in it and it has
2 members who aren't mentors. So the page never got a team that was too
small, the team-too-small note could never show, and a mentor whose own
groups left the team out was told "A member can add you" even when they
were already in the group.

A mentor who doesn't see the chat now gets one note naming both steps,
and the page no longer counts members itself.
Under the team chat, everyone in it sees who mentors the team. A member
who isn't a mentor, or a teacher, can search for verified mentors
(people search, narrowed to ROLE_MENTOR accounts not in the group yet)
and add or remove them through the group's members routes. A mentor
sees the list only. When Spring refuses a change, the panel shows the
page's words for Spring's reason. Names are always set as text.
"Add at least 2 team members" was wrong for a group that already had
one. It now says the group needs at least 2 members who aren't mentors
before it can have a mentor, and that teammates are added in Messages.
@svaka2000

Copy link
Copy Markdown
Contributor Author

Combined into #2091 with the same commits.

@svaka2000 svaka2000 closed this Nov 26, 2026
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