diff options
author | Luke Bennett <lukeeeebennettplus@gmail.com> | 2016-09-23 15:18:33 +0100 |
---|---|---|
committer | Luke Bennett <lukeeeebennettplus@gmail.com> | 2016-10-07 14:25:20 +0100 |
commit | 443619300d067a83cbd53872635c2c3cfd1f6655 (patch) | |
tree | 34bb64513e6741d08a3311d12f4f243027ac7e6a /app/helpers/issuables_helper.rb | |
parent | 49d6ca6267034149a63b8648215ed0a73126de3f (diff) | |
download | gitlab-ce-443619300d067a83cbd53872635c2c3cfd1f6655.tar.gz |
Added `issuable_filters_present` to check for active filters before rendering the reset button22457-reset-filters-button-should-be-invisible-when-no-filters-are-active
Added tests
Diffstat (limited to 'app/helpers/issuables_helper.rb')
-rw-r--r-- | app/helpers/issuables_helper.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/app/helpers/issuables_helper.rb b/app/helpers/issuables_helper.rb index 692fadd505f..03b2db1bc91 100644 --- a/app/helpers/issuables_helper.rb +++ b/app/helpers/issuables_helper.rb @@ -124,6 +124,10 @@ module IssuablesHelper end end + def issuable_filters_present + params[:search] || params[:author_id] || params[:assignee_id] || params[:milestone_title] || params[:label_name] + end + def issuables_count_for_state(issuable_type, state) issuables_finder = public_send("#{issuable_type}_finder") issuables_finder.params[:state] = state |