anaf_habtm 0.0.87 → 0.0.88

Sign up to get free protection for your applications and to get access to all the features.
data/anaf_habtm.gemspec CHANGED
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{anaf_habtm}
8
- s.version = "0.0.87"
8
+ s.version = "0.0.88"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Tyler Gannon"]
@@ -126,13 +126,13 @@ module AnafHabtm
126
126
  def search_on(*cols)
127
127
  class_eval "def self.search_columns; #{cols.map{|t| t.to_s}.to_ary.inspect}; end;"
128
128
  class_eval do
129
- # scope :search, lambda{|str|
130
- # items = like_condition(str.downcase)
131
- # if scopes.has_key?(:search_mod)
132
- # items = items.search_mod
133
- # end
134
- # items
135
- # }
129
+ scope :search, lambda{|str|
130
+ items = like_condition(str.downcase)
131
+ if scopes.has_key?(:search_mod)
132
+ items = items.search_mod
133
+ end
134
+ items
135
+ }
136
136
  scope :with_name, lambda{|str|
137
137
  equals_condition(str.downcase).limit(1)
138
138
  }
@@ -24,13 +24,13 @@ module AnafHabtm
24
24
 
25
25
  def tfwac(f, field, controller, opts={})
26
26
  opts["data-auto-complete"]='tf'
27
- opts["data-auto-complete-url"]=eval("#{controller.to_s.underscore.tableize}_path(:format=>:json)")
27
+ opts["data-auto-complete-url"]=eval("\"#{controller.to_s.underscore.tableize}_path(:format=>:json)\"")
28
28
  f.text_field field, opts
29
29
  end
30
30
 
31
31
  def text_area_with_auto_complete(f, field, controller, opts={})
32
32
  opts["data-auto-complete"]='ta'
33
- opts["data-auto-complete-url"]=eval("#{controller.to_s.underscore.tableize}_path(:format=>:json)")
33
+ opts["data-auto-complete-url"]=eval("\"#{controller.to_s.underscore.tableize}_path(:format=>:json)\"")
34
34
  f.text_area field, opts
35
35
  end
36
36
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: anaf_habtm
3
3
  version: !ruby/object:Gem::Version
4
- hash: 177
4
+ hash: 175
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 0
9
- - 87
10
- version: 0.0.87
9
+ - 88
10
+ version: 0.0.88
11
11
  platform: ruby
12
12
  authors:
13
13
  - Tyler Gannon