diff options
author | Rémy Coutable <remy@rymai.me> | 2016-07-28 15:58:45 +0000 |
---|---|---|
committer | Rémy Coutable <remy@rymai.me> | 2016-07-28 15:58:45 +0000 |
commit | b24ccd4a67f60731ce2eb6be0129e8cf7228263d (patch) | |
tree | 88c19b63e63a44fe39c12e83e3a68a0795f645fe /app/views/projects/branches | |
parent | 273bea975baabfbdcd831a0ff525f2ace48fb750 (diff) | |
parent | 94e6d51ec047fbf01cae2814003bba7ee2ff8546 (diff) | |
download | gitlab-ce-b24ccd4a67f60731ce2eb6be0129e8cf7228263d.tar.gz |
Merge branch '20308-fix-title-that-is-show-in-the-dropdown-toggle-button-on-projects-branches' into 'master'
Fix the title of the toggle dropdown button
## What does this MR do?
Fix the dropdown-button toggle displaying the correctly title.
## Are there points in the code the reviewer needs to double check?
See if the title is displaying correctly and if the code is acceptable.
## Why was this MR needed?
When you choose `Last updated` it should display the title `Last updated` instead of `Recently updated`. This fix makes this correctly displays the title.
## What are the relevant issue numbers?
Closes #20308.
## Screenshots (if relevant)

## Does this MR meet the acceptance criteria?
- [x] [CHANGELOG](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CHANGELOG) entry added
- Tests
- [x] All builds are passing
- [x] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides)
- [x] Branch has no merge conflicts with `master` (if you do - rebase it please)
- [x] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits)
See merge request !5515
Diffstat (limited to 'app/views/projects/branches')
-rw-r--r-- | app/views/projects/branches/index.html.haml | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/app/views/projects/branches/index.html.haml b/app/views/projects/branches/index.html.haml index cb190d121c2..e889f29c816 100644 --- a/app/views/projects/branches/index.html.haml +++ b/app/views/projects/branches/index.html.haml @@ -14,18 +14,15 @@ .dropdown.inline %button.dropdown-toggle.btn{type: 'button', 'data-toggle' => 'dropdown'} %span.light - - if params[:sort].present? - = params[:sort].humanize - - else - Name + = projects_sort_options_hash[@sort] %b.caret %ul.dropdown-menu.dropdown-menu-align-right %li - = link_to filter_branches_path(sort: nil) do + = link_to filter_branches_path(sort: sort_value_name) do = sort_title_name - = link_to filter_branches_path(sort: 'recently_updated') do + = link_to filter_branches_path(sort: sort_value_recently_updated) do = sort_title_recently_updated - = link_to filter_branches_path(sort: 'last_updated') do + = link_to filter_branches_path(sort: sort_value_oldest_updated) do = sort_title_oldest_updated - if can? current_user, :push_code, @project |