CRM-13920 add "any" option to getCaseActivityQuery and use when checking...

... case perms for user