[rt-users] Add custom field to default search query

Kevin Falcone falcone at bestpractical.com
Fri Aug 19 10:34:53 EDT 2011


On Fri, Aug 19, 2011 at 03:13:23PM +0200, Lars Braeuer wrote:
> the default search form on every page only allows to search through standard fields, but not through
> custom fields.
> 
> Is there any way, like hacking an (sql) query, to include just one custom field with the standard
> search?
> 
> I.e. we are tracking the customer ID in one of these fields. We would like to include it in the
> standard search, without having to use the advanced search feature, which takes time. It's also not
> applicable to setup saved searches, as we want to remain totally dynamic.

I'm assuming that you're on RT4 since you didn't specify, this code
changed dramatically between 3.8 and 4.

You probably want to override HandleSubject to search Subject and the
CF, or add your own item to @GUESS in lib/RT/Search/Googleish.pm

-kevin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 195 bytes
Desc: not available
URL: <http://lists.bestpractical.com/pipermail/rt-users/attachments/20110819/40619227/attachment.sig>


More information about the rt-users mailing list