blocks 1.2.3 → 1.2.4

Sign up to get free protection for your applications and to get access to all the features.
@@ -26,7 +26,9 @@
26
26
  <% table.columns.each do |column| %>
27
27
  <% header_html = options.merge(column.options)[:header_html] %>
28
28
  <% if options.merge(column.options)[:sortable] %>
29
- <% sort_class = params[:order] != column.options[:order].try(:to_s) ? "sorting" : (params[:sort_mode] == "desc" ? "sorting_desc" : "sorting_asc") %>
29
+ <% order = column.options[:order] ? column.options[:order].to_s : column.name.to_s %>
30
+
31
+ <% sort_class = params[:order] != order ? "sorting" : (params[:sort_mode] == "desc" ? "sorting_desc" : "sorting_asc") %>
30
32
  <% header_html = {} if header_html.nil? %>
31
33
  <% header_html[:class] ||= "" %>
32
34
  <% header_html[:class] += " #{sort_class}" %>
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: blocks
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 1.2.3
5
+ version: 1.2.4
6
6
  platform: ruby
7
7
  authors:
8
8
  - Andrew Hunter