rails-simple-search 0.9.8 → 0.9.9

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. checksums.yaml +7 -7
  2. data/README.rdoc +3 -1
  3. data/lib/rails-simple-search.rb +10 -0
  4. metadata +20 -29
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
- ---
2
- SHA1:
3
- metadata.gz: 1fa87087dc4f0c9095a6e1e393ba3a697124ac0b
4
- data.tar.gz: 04a6a6e9efeeb75a451b0e0a934af16c61ceca6a
5
- SHA512:
6
- metadata.gz: 05cca30064e8497ebac3d6b01058f8dfa4f5bd9e1e7da1017db3b5acebc3c06dfd770392149a5d7a26b6d3496888e3bf11cea758174ed2ca9d9fb1cae690ac8b
7
- data.tar.gz: c5072f099210ab82d751ee2220c64a29298fd338e885ce48066a8c4b87f60650fc3e814289d09821f21acde36b69292f1730449301ffc893060ebe46319b8667
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 3e88221b8313697ba9e198b4a768defc66733034
4
+ data.tar.gz: 0579f33f52fb69245e96328017c8d3bced2d8344
5
+ SHA512:
6
+ metadata.gz: 57c7fd37e38bbc25cc5004cb86d7d1509f15c346e4dede7c5abd2926cf26e8256be9cddc69d79a79e97ebc102f7f77185072cf60f21faec0262683ead8a6c775
7
+ data.tar.gz: 41317a99ef9e9a258711124983688b9623096eedeb266fe446a154f4b2df9c575b6359f46f2d54a118feb27f7051b067e5b593114d1b6036d18b869f8e4337b9
@@ -75,7 +75,9 @@ For rails 2.x.x applications, you might want to use the version 0.9.0.
75
75
 
76
76
  From version 0.9.1 to 0.9.7, Rails 3 is supported.
77
77
 
78
- From version 0.9.8 on, this gem started to support Rails 4. Version 0.9.8 is tested under Rails 4.1.1.
78
+ From version 0.9.8 on, this gem started to support Rails 4. Version 0.9.8 is tested under Rails 4.1.1, and version 0.9.9 fixed an issue under
79
+ Rails 4.2.
80
+
79
81
 
80
82
  There is a real demo application which you can download and run immediately: https://github.com/yzhanginwa/demo_app_for_rails_simple_search
81
83
 
@@ -8,6 +8,13 @@ module RailsSimpleSearch
8
8
  :limit => 1000,
9
9
  :per_page => 20
10
10
  }
11
+
12
+ module FixModelName
13
+ def model_name
14
+ ActiveModel::Name.new(self.class)
15
+ end
16
+ end
17
+
11
18
  class Base
12
19
  def self.inherited(subclass)
13
20
  class << subclass
@@ -16,6 +23,9 @@ module RailsSimpleSearch
16
23
  ActiveModel::Name.new(self)
17
24
  end
18
25
  end
26
+
27
+ # to fix an issues in rails 4.2
28
+ subclass.send(:include, RailsSimpleSearch::FixModelName)
19
29
  end
20
30
 
21
31
  def initialize(model_class, criteria={}, config={})
metadata CHANGED
@@ -1,55 +1,46 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: rails-simple-search
3
- version: !ruby/object:Gem::Version
4
- version: 0.9.8
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.9.9
5
5
  platform: ruby
6
- authors:
6
+ authors:
7
7
  - Yi Zhang
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
-
12
- date: 2014-06-28 00:00:00 Z
11
+ date: 2015-04-18 00:00:00.000000000 Z
13
12
  dependencies: []
14
-
15
- description: rails-simple-search is a light and easy to use gem. It could help developers quickly build a search page.
13
+ description: rails-simple-search is a light and easy to use gem. It could help developers
14
+ quickly build a search page.
16
15
  email: yzhang.wa@gmail.com
17
16
  executables: []
18
-
19
17
  extensions: []
20
-
21
18
  extra_rdoc_files: []
22
-
23
- files:
19
+ files:
24
20
  - README.rdoc
25
21
  - lib/rails-simple-search.rb
26
22
  - lib/sql_handler.rb
27
23
  homepage: http://github.com/yzhanginwa/rails-simple-search
28
24
  licenses: []
29
-
30
25
  metadata: {}
31
-
32
26
  post_install_message:
33
27
  rdoc_options: []
34
-
35
- require_paths:
28
+ require_paths:
36
29
  - lib
37
- required_ruby_version: !ruby/object:Gem::Requirement
38
- requirements:
39
- - &id001
40
- - ">="
41
- - !ruby/object:Gem::Version
42
- version: "0"
43
- required_rubygems_version: !ruby/object:Gem::Requirement
44
- requirements:
45
- - *id001
30
+ required_ruby_version: !ruby/object:Gem::Requirement
31
+ requirements:
32
+ - - ">="
33
+ - !ruby/object:Gem::Version
34
+ version: '0'
35
+ required_rubygems_version: !ruby/object:Gem::Requirement
36
+ requirements:
37
+ - - ">="
38
+ - !ruby/object:Gem::Version
39
+ version: '0'
46
40
  requirements: []
47
-
48
41
  rubyforge_project:
49
- rubygems_version: 2.1.10
42
+ rubygems_version: 2.2.0
50
43
  signing_key:
51
44
  specification_version: 4
52
45
  summary: A very simple and light get to quick build search function in rails
53
46
  test_files: []
54
-
55
- has_rdoc: