Quick Search won't consider custom field groups
Overview
Quick search menu allow to select searchable custom fields but won't identify them by group
Reproduction steps
- Add two groups for custom fields, any name, ex. group_1, group_2
- For each of them add field with the same name "customnumber", searchable
- Fill that field with random values for diffrent users
- Edit quick search panel and pick one of that fields
- Use quick search panel in menu
Current behaviour
It won't find matching records for group_1.customnumber or group_2.customnumber, it will always be the same field group_2.customnumber. Reason: \CRM_Admin_Page_AJAX::getSearchOptions won't have info about custom field group, so it is searching only by name
CRM_Core_DAO::getFieldValue('CRM_Core_DAO_CustomField', substr($key, 7), 'id', 'name')
Expected behaviour
Search for group_1.customnumber or group_2.customnumber depending of which will be selected in quicksearch panel