final styling of table sorting
This commit is contained in:
@@ -1,7 +1,9 @@
|
||||
module FavoritesHelper
|
||||
def sortable(title, column)
|
||||
direction = column == sort_column && sort_direction == 'asc' ? 'desc' : 'asc'
|
||||
link_to title, :sort => column, :direction => direction
|
||||
link_to :sort => column, :direction => direction do
|
||||
content_tag(:div, title) + sorting_arrow(column)
|
||||
end
|
||||
end
|
||||
|
||||
def sorting_arrow(column)
|
||||
|
||||
Reference in New Issue
Block a user