BigW Consortium Gitlab

_sort_dropdown.html.haml 1.5 KB
Newer Older
1
.dropdown.inline.prepend-left-10
2
  %button.dropdown-toggle.btn{type: 'button', 'data-toggle' => 'dropdown'}
3
    %span.light
4
    - if @sort.present?
5
      = sort_options_hash[@sort]
6
    - else
7
      = sort_title_recently_created
8
    %b.caret
9
  %ul.dropdown-menu.dropdown-menu-align-right.dropdown-menu-sort
10
    %li
Thijs Wouters committed
11 12
      = link_to page_filter_path(sort: sort_value_priority) do
        = sort_title_priority
13
      = link_to page_filter_path(sort: sort_value_recently_created) do
14
        = sort_title_recently_created
15
      = link_to page_filter_path(sort: sort_value_oldest_created) do
16
        = sort_title_oldest_created
17
      = link_to page_filter_path(sort: sort_value_recently_updated) do
18
        = sort_title_recently_updated
19
      = link_to page_filter_path(sort: sort_value_oldest_updated) do
20
        = sort_title_oldest_updated
21 22 23 24
      = link_to page_filter_path(sort: sort_value_milestone_soon) do
        = sort_title_milestone_soon
      = link_to page_filter_path(sort: sort_value_milestone_later) do
        = sort_title_milestone_later
Phil Hughes committed
25
      - if controller.controller_name == 'issues' || controller.action_name == 'issues'
Rémy Coutable committed
26 27 28 29
        = link_to page_filter_path(sort: sort_value_due_date_soon) do
          = sort_title_due_date_soon
        = link_to page_filter_path(sort: sort_value_due_date_later) do
          = sort_title_due_date_later
30 31 32 33
      = link_to page_filter_path(sort: sort_value_upvotes) do
        = sort_title_upvotes
      = link_to page_filter_path(sort: sort_value_downvotes) do
        = sort_title_downvotes