summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--app/controllers/application_controller.rb1
-rw-r--r--changelogs/unreleased/1801-allow-event_filter-to-be-set-in-the-url.yml5
2 files changed, 6 insertions, 0 deletions
diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb
index fb2808edf47..81b538b97ba 100644
--- a/app/controllers/application_controller.rb
+++ b/app/controllers/application_controller.rb
@@ -275,6 +275,7 @@ class ApplicationController < ActionController::Base
def event_filter
# Split using comma to maintain backward compatibility Ex/ "filter1,filter2"
filters = cookies['event_filter'].split(',')[0] if cookies['event_filter'].present?
+ filters = params[:event_filter].split(',')[0] if params[:event_filter].present?
@event_filter ||= EventFilter.new(filters)
end
diff --git a/changelogs/unreleased/1801-allow-event_filter-to-be-set-in-the-url.yml b/changelogs/unreleased/1801-allow-event_filter-to-be-set-in-the-url.yml
new file mode 100644
index 00000000000..4ceaa7e3139
--- /dev/null
+++ b/changelogs/unreleased/1801-allow-event_filter-to-be-set-in-the-url.yml
@@ -0,0 +1,5 @@
+---
+title: "Allow events filter to be set in the URL in addition to cookie"
+merge_request: 21557
+author: Igor @igas
+type: added