diff options
| author | Stan Hu <stanhu@gmail.com> | 2015-10-06 09:57:13 -0700 |
|---|---|---|
| committer | Stan Hu <stanhu@gmail.com> | 2015-10-07 07:21:50 -0700 |
| commit | dfbbc80611fbdafe6f5ed809f98fc63987d104a6 (patch) | |
| tree | 00a5f131e4b54c14162fc2a89cc2cca1a73512c9 /app/helpers | |
| parent | cc8c91a1183ebfc5bb252f5e7f3f09fc20546476 (diff) | |
| download | gitlab-ce-dfbbc80611fbdafe6f5ed809f98fc63987d104a6.tar.gz | |
Support filtering by "Any" milestone or issue and fix "No Milestone" and "No Label" filters
Closes #2619
Closes https://github.com/gitlabhq/gitlabhq/issues/9631
Diffstat (limited to 'app/helpers')
| -rw-r--r-- | app/helpers/labels_helper.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/app/helpers/labels_helper.rb b/app/helpers/labels_helper.rb index 8036303851b..662ace367b9 100644 --- a/app/helpers/labels_helper.rb +++ b/app/helpers/labels_helper.rb @@ -93,7 +93,9 @@ module LabelsHelper end def project_labels_options(project) - options_from_collection_for_select(project.labels, 'name', 'name', params[:label_name]) + labels = project.labels.to_a + labels.unshift(Label::None) + options_from_collection_for_select(labels, 'name', 'name', params[:label_name]) end # Required for Gitlab::Markdown::LabelReferenceFilter |
