At the moment, when searching for initiatives, we match the search term only with the description of the first role of each person, ignoring all role titles and all the other roles. This is a bit broken. This PR includes all roles - and their titles - in the search. It also refactors the search code a bit to make the changes then a lot simpler.
Setup
Add multiple roles to one person. Add unique words in the description of the roles.
Testing
Make sure that the initiative can be found by unique words in either the role titles or descriptions.
Issue
This is in response to a customer request: https://app.intercom.com/a/inbox/q3x5lnhp/inbox/shared/all/conversation/106323200011155?view=List (internal)
Description
At the moment, when searching for initiatives, we match the search term only with the description of the first role of each person, ignoring all role titles and all the other roles. This is a bit broken. This PR includes all roles - and their titles - in the search. It also refactors the search code a bit to make the changes then a lot simpler.
Setup
Add multiple roles to one person. Add unique words in the description of the roles.
Testing
Make sure that the initiative can be found by unique words in either the role titles or descriptions.