Sha256: d790d455bc9ba35e8636e1dfc3691947d9af150bfae26fb6b4d0d2d84481324c
Contents?: true
Size: 404 Bytes
Versions: 15
Compression:
Stored size: 404 Bytes
Contents
module Myreplicator module ApplicationHelper def sortable(column, title = nil) title ||= column.titleize css_class = column == sort_column ? "current #{sort_direction}" : nil direction = column == sort_column && sort_direction == "asc" ? "desc" : "asc" link_to content_tag(:span, title), {:sort => column, :direction => direction}, {:class => css_class} end end end
Version data entries
15 entries across 15 versions & 1 rubygems