hsph-reports-related changes

See https://github.com/dimagi/core-hq/commit/dcf11a8d7fa52880ab82be1f9414394bffb79dea

This isn't dependent on any hsph reports changes.

I haven't tested filtering by an individual user/owner for the case list because I don't have any form submissions linked with a non-unknown user locally.  However, when not filtering the case list, it actually gets all of the user_ids for the domain and passes them as the user_ids to CasePaginator, so I'd consider that sufficient evidence that the {terms: } query works.