about summary refs log tree commit diff
path: root/app/models
diff options
context:
space:
mode:
authorThibG <thib@sitedethib.com>2019-11-30 19:53:58 +0100
committerEugen Rochko <eugen@zeonfederated.com>2019-11-30 19:53:58 +0100
commitd8f96028c54bb47e6edddbd936bc8f2301dc9fa3 (patch)
tree2353eca5c958219f2309acfad17db8ab9ed5dce6 /app/models
parentf3a93987b6c3af92aee11fdb4424b8791a67e448 (diff)
Add ability to filter reports by target account domain (#12154)
* Add ability to filter reports by target account domain

* Reword by_target_domain label
Diffstat (limited to 'app/models')
-rw-r--r--app/models/report_filter.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/app/models/report_filter.rb b/app/models/report_filter.rb
index a392d60c3..abf53cbab 100644
--- a/app/models/report_filter.rb
+++ b/app/models/report_filter.rb
@@ -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