diff options
author | Azul <azul@leap.se> | 2014-07-05 13:10:50 +0200 |
---|---|---|
committer | Azul <azul@leap.se> | 2014-07-09 13:26:36 +0200 |
commit | 9d83092405745f6d1b07a57fd8d2aa8e9bffd9fa (patch) | |
tree | e8ad9a5044131ce4bdeb52bd52e990d199c6d066 /engines/support/app/helpers/auto_tickets_path_helper.rb | |
parent | c8fc45c21d72837d5a6bd41ffca18b3ac52a305f (diff) |
minor: cleanup some links
only submit the params that differ from the defaults
Diffstat (limited to 'engines/support/app/helpers/auto_tickets_path_helper.rb')
-rw-r--r-- | engines/support/app/helpers/auto_tickets_path_helper.rb | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/engines/support/app/helpers/auto_tickets_path_helper.rb b/engines/support/app/helpers/auto_tickets_path_helper.rb index 5638222..c26aac7 100644 --- a/engines/support/app/helpers/auto_tickets_path_helper.rb +++ b/engines/support/app/helpers/auto_tickets_path_helper.rb @@ -45,10 +45,8 @@ module AutoTicketsPathHelper private def ticket_view_options - hsh = {} - hsh[:open_status] = params[:open_status] if params[:open_status] && !params[:open_status].empty? - hsh[:sort_order] = params[:sort_order] if params[:sort_order] && !params[:sort_order].empty? - hsh + hash = params.slice(:open_status, :sort_order) + hash.reject {|k,v| v.blank?} end end |