Quicksearch by id

Published
2011-09-02 11:34
Written by

One of the items we didn't get to at the code sprint was a quicksearch by id that bypasses search results pages and takes you directly to the page in question, e.g. a case id or a contribution/invoice id.

I ended up just coding a drupal block that was client-specific that just searches for case id but that some people might find useful. You can find it at http://svn.civicrm.org/php/trunk/drupal/modules/physicianhealthbc/physicianhealthbc.module and just look at the last 4 functions in that file.

Optionally you can also add in some CSS to make the block look/fit better:

#block-physicianhealthbc-0 div#edit-caseid-wrapper {
float:left;
margin-right:3px;
margin-top:0;
}

Filed under

Comments

you can use the contactListQuery hook to do that. use the context param to limit its usage to the main quicksearch, and then rebuild the queries to include your additional fields.