feat(SearchDoc): Validate "fromid" property in getQueries() method (refs #4935)

If the "fromid" property is not a valid "fromid", then getQueries()
returns bool(false) in order to not perform a search on docread.

The return value for onlycount() has been changed to return -1 when the
query cannot be performed.

Therefore, possible values for onlyCount() are:
- N>0: non-empty result's set
- N=0: empty result's set
- N=-1: when the query cannot be composed or performed
Merge pull request #1308 from eguaj/3.2-A4935

feat(SearchDoc): Validate "fromid" property in getQueries() method (closes #4935)