Skip to content

Commit

Permalink
Merge pull request #6201 from ZitaNemeckova/order
Browse files Browse the repository at this point in the history
Sort Requester dropdown by label

(cherry picked from commit bbb0f38)

Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1767660
  • Loading branch information
mzazrivec authored and simaishi committed Oct 31, 2019
1 parent 4bdd524 commit c364cff
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/controllers/miq_request_controller.rb
Expand Up @@ -386,7 +386,7 @@ def opts_users

if approver?
# list all requesters
[label_value_hash_with_all(requesters), 'all']
[label_value_hash_with_all(requesters).sort_by { |object| object[:label] }, 'all']
elsif requesters.value?(current_user.name)
# list just the current user
[[{:value => current_user.id, :label => current_user.name}], current_user.id]
Expand Down

0 comments on commit c364cff

Please sign in to comment.