combo_box 0.0.6 → 0.0.7
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/lib/combo_box/action_controller.rb +1 -0
- data/lib/combo_box/generator.rb +1 -2
- metadata +8 -8
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.0.
|
1
|
+
0.0.7
|
@@ -76,6 +76,7 @@ module ComboBox
|
|
76
76
|
if [String, Symbol].include?(model.class)
|
77
77
|
model = model.to_s.classify.constantize
|
78
78
|
end
|
79
|
+
return unless model.table_exists?
|
79
80
|
generator = Generator::Base.new(self, action_name, model, options)
|
80
81
|
class_eval(generator.controller_action, "#{__FILE__}:#{__LINE__}")
|
81
82
|
# ActionView::Base.send(:class_eval, generator.view_code, "#{__FILE__}:#{__LINE__}")
|
data/lib/combo_box/generator.rb
CHANGED
@@ -9,7 +9,6 @@ module ComboBox
|
|
9
9
|
# @@count = 0
|
10
10
|
|
11
11
|
def initialize(model, name, options={})
|
12
|
-
return unless model.table_exists?
|
13
12
|
@model = model
|
14
13
|
@name = name.to_s
|
15
14
|
@filter = options.delete(:filter) || "%X%"
|
@@ -21,7 +20,7 @@ module ComboBox
|
|
21
20
|
end
|
22
21
|
klass = klass.reflections[reflection.to_sym].class_name.constantize
|
23
22
|
reflection.to_sym
|
24
|
-
end
|
23
|
+
end || []
|
25
24
|
@column = foreign_model.columns_hash[@name]
|
26
25
|
end
|
27
26
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: combo_box
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.7
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -13,7 +13,7 @@ date: 2012-01-24 00:00:00.000000000Z
|
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rails
|
16
|
-
requirement: &
|
16
|
+
requirement: &16108240 !ruby/object:Gem::Requirement
|
17
17
|
none: false
|
18
18
|
requirements:
|
19
19
|
- - ~>
|
@@ -21,10 +21,10 @@ dependencies:
|
|
21
21
|
version: '3'
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
|
-
version_requirements: *
|
24
|
+
version_requirements: *16108240
|
25
25
|
- !ruby/object:Gem::Dependency
|
26
26
|
name: jquery-rails
|
27
|
-
requirement: &
|
27
|
+
requirement: &16107280 !ruby/object:Gem::Requirement
|
28
28
|
none: false
|
29
29
|
requirements:
|
30
30
|
- - ! '>='
|
@@ -32,10 +32,10 @@ dependencies:
|
|
32
32
|
version: '0'
|
33
33
|
type: :runtime
|
34
34
|
prerelease: false
|
35
|
-
version_requirements: *
|
35
|
+
version_requirements: *16107280
|
36
36
|
- !ruby/object:Gem::Dependency
|
37
37
|
name: jeweler
|
38
|
-
requirement: &
|
38
|
+
requirement: &16106440 !ruby/object:Gem::Requirement
|
39
39
|
none: false
|
40
40
|
requirements:
|
41
41
|
- - ~>
|
@@ -43,7 +43,7 @@ dependencies:
|
|
43
43
|
version: 1.6.4
|
44
44
|
type: :development
|
45
45
|
prerelease: false
|
46
|
-
version_requirements: *
|
46
|
+
version_requirements: *16106440
|
47
47
|
description: Adds helpers for Rails views and controller in order to manage 'dynamic
|
48
48
|
select'. It uses jQuery UI as support for inobtrusive use in forms. It's not the
|
49
49
|
classic Autocompleter, its use is limited to belongs_to reflections.
|
@@ -82,7 +82,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
82
82
|
version: '0'
|
83
83
|
segments:
|
84
84
|
- 0
|
85
|
-
hash: -
|
85
|
+
hash: -3255549222173850358
|
86
86
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
87
87
|
none: false
|
88
88
|
requirements:
|