When I search for Cases, the search results are sortable by clicking on any of the column headings except for Subject and Case Manager. I would like to order the results by Subject - either by clicking on the Subject column heading, or by editing the appopriate php or tpl file so that the results are ordered by Subject by default. Can someone please point me in the right direction for the file(s) which I should edit to change the sort order? Thank you.
1 Answer
I found an answer - by editing the file com_civicrm/civicrm/CRM/Case/Selector/Search.php. I inserted the following line after line 427:
'sort' => 'case_subject',
This makes the Subject column clickable for sorting.
-
You should not be editing the core file. Copy the file to custom PHP directory and then makes changes. More information about custom PHP in this page wiki.civicrm.org/confluence/display/CRMDOC/Directories– GhostCommented Jul 15, 2016 at 12:30