gauze 0.0.5 → 0.0.6

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 714ba17d4effef3630da04ca15666c44c21b5012
4
- data.tar.gz: a7c07c9cddb3a4664cff85eeec4fa52adcb4d302
3
+ metadata.gz: 225d09f51569d3affeafc03f6ed31329d2f62eab
4
+ data.tar.gz: 071d007dcc6f90649a0fb021e4a8a30c618f6db6
5
5
  SHA512:
6
- metadata.gz: d82d231d298f61324cdc3e50c36d9c4d44271af3620d6747bd960d56446977ee4654a4c856fbc7371c96e63df45e2629548aea2ba6effbfa762ea313ee7353d2
7
- data.tar.gz: 1900ee37463aff73f5bfc5803f792cf7d6a910cbad977d38965c6d60c0174e646e63d6c99803446b4d7efa6acff20fe318066d94313152b0217b77e737db173b
6
+ metadata.gz: 3c7f20a66409dfed9f8b7104a94dd91a9eeee352d351ab0754f846ad992097a68b642eae5c61257348569ff8a5c32fdd091af212af49c00fe588ecdb468ebf5c
7
+ data.tar.gz: 0595b67cec62a0e1b10218947815700d2866d71cba8f1879a120ed5339b45891946e94ed251ed8ea4205cdd97dd8e171b3d405a909d134e91bf33e764f26ccd1
@@ -79,7 +79,15 @@ module Gauze
79
79
  _arel_column = @resource.arel_table[sort_column[:column]]
80
80
  end
81
81
 
82
- query.order(_arel_column.method(sort_direction).call).group(_arel_column)
82
+ #Apple the column with the sort direction
83
+ query = query.order(_arel_column.method(sort_direction).call)
84
+
85
+ if query.group_values.length > 0
86
+ query = query.group(_arel_column)
87
+ end
88
+
89
+
90
+ return query
83
91
  end
84
92
 
85
93
  private
@@ -1,3 +1,3 @@
1
1
  module Gauze
2
- VERSION = "0.0.5"
2
+ VERSION = "0.0.6"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gauze
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.5
4
+ version: 0.0.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Chris Ostrowski