I would like to create a many many relationship, as per the tutorials. So far so good.
I'll use class Mentor from https://docs.silverstripe.org/en/3/tutorials/dataobject_relationship_management/ to illustrate my idea.
What if there are different types of Mentors? Each mentor has a set skill. Some mentors have business skills, some have communication skills, etc. How would those different types be represented in such a way that when a mentor is added, their specific skill can be nominated?
The reason I ask this, is because I wish to be able to create various types that have secret information that should be used in a template, but someone using the many to many relationship doesn't need to worry about.
So for example: Mentor has a property called code.
In BusinessMentor it is set to 12A, and in CommunicationMentor it is set to 45C. Every Mentor who is a BusinessMentor has this code 12A. Every Mentor who is a CommunicationMentor has the code 45C.
When people are selecting Mentor's for the project in the CMS user interface, they don't need to worry about the underlying code, they just find the Mentor name and use that.
But that code is accessible in a template. Should the code be a DataObject itself?
Any ideas?