Add ability to filter reports by target account domain (#12154)

* Add ability to filter reports by target account domain

* Reword by_target_domain label
This commit is contained in:
ThibG
2019-11-30 19:53:58 +01:00
committed by Eugen Rochko
parent f3a93987b6
commit d8f96028c5
5 changed files with 20 additions and 2 deletions

View File

@ -19,6 +19,8 @@ class ReportFilter
def scope_for(key, value)
case key.to_sym
when :by_target_domain
Report.where(target_account: Account.where(domain: value))
when :resolved
Report.resolved
when :account_id