phpmentoring / webapp

PHP Mentoring matching website
http://php-mentoring.org/
MIT License
46 stars 30 forks source link

Ability to make requests to "Be My Mentor" and "Be My Apprentice" #33

Open jmichaelward opened 9 years ago

jmichaelward commented 9 years ago

I don't see this listed among the open or closed issues, so I wanted to document it here for posterity.

@dragonmantank mentioned in IRC that he wants to add the ability for an Apprentice to request someone to be their Mentor, and conversely, for a Mentor to request someone to be their Apprentice.

Based on what I've seen in the codebase thus far, we'll need to add a migration to store data about a user's Mentors and Apprentices, as I understand a Mentor can have many Apprentices and vice versa. Additionally (and this requires further clarification/discussion), I suspect that we want to add a button to a user's profile page that allows for the "Be My Mentor" or "Be My Apprentice" action to be made, depending on the page that's being viewed. Thus, some questions:

  1. Should a new Conversation be the result of the user's action of clicking the request button?
  2. If so, should the user be able to send any extra information along with their request, such as an introductory message?
  3. Will this interaction require modification of the Conversations tables?
dragonmantank commented 9 years ago
  1. I think it should generate a new conversation. Worse case they won't use it, but I completely see the use case where an apprentice hasn't talked with the mentor before, so a new conversation of like "X wants to be your apprentice/mentor" would be appropriate.
  2. That makes sense. When they click the request button, have them enter a message and that will just be the initial conversation message.
  3. I don't think so, because we're just injecting a text message into the conversation table, which it already handles. We're just creating a conversation in a different place than the conversation page.