Search: Changing search to be more robust

Changes to make search a little more configurable and robust. High level changes:

* The code to convert `search` params to `conditions` now handles existing `$or` criteria correctly
* If the client specifies that the search expression is not a regex using the `searchIsRegex` request param, the search expression is escaped. This defaults to `true` for backwards compatibility.
* The client can specify whether to match whole words or not. The `searchWholeWords` request param defaults to false for backwards compatibility.
* The search mode has been changed to `AND` or `OR`. The default is `OR` for backwards compatibility. The `AND` mode now requires that all terms are present in at least one of the search fields. The previous implementation required that the expression provided appeared in all fields, which is an unlikely scenario.
* Unit tests have been added. Run `npm test` to execute.