enum_help 0.0.3 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +0 -1
- data/lib/enum_help/simple_form.rb +1 -1
- data/lib/enum_help/version.rb +1 -1
- metadata +11 -12
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 98a605281147b608465a516bd78579cb5b8a7156
|
4
|
+
data.tar.gz: f280e6fcc1bad17ef18380dcbf6326f52628435f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 83b1174c6c137c9cb2e0088e78f51aba59a48594c4bd336617620db250e3da5c0ddda43f4b9d7aac421ee66c8c2cc4686e8593f8e6fc9ec36c99ba80092d0389
|
7
|
+
data.tar.gz: 1e6ad5f576ce969ec59cc2a9aa368b8d67cf8c56be544411fb63732a56862b43c16562837b27efd040e09faa0d0ee4b44327c3a330218ae687ece458f8ea3d35
|
data/README.md
CHANGED
@@ -18,7 +18,7 @@ module EnumHelp
|
|
18
18
|
super
|
19
19
|
raise "Attribute '#{attribute_name}' has no enum class" unless enum = object.class.send(attribute_name.to_s.pluralize)
|
20
20
|
collect = enum.collect{|k,v| [::I18n.t("enums.#{object.class.to_s.downcase}.#{attribute_name}.#{k}", default: k),k] }
|
21
|
-
collect.unshift [args.last[:prompt],''] if args.last.is_a?(Hash) && args.last[:prompt]
|
21
|
+
# collect.unshift [args.last[:prompt],''] if args.last.is_a?(Hash) && args.last[:prompt]
|
22
22
|
|
23
23
|
if respond_to?(:input_options)
|
24
24
|
input_options[:collection] = collect
|
data/lib/enum_help/version.rb
CHANGED
metadata
CHANGED
@@ -1,52 +1,51 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: enum_help
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Lester Zhao
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-03-
|
11
|
+
date: 2014-03-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- -
|
17
|
+
- - ~>
|
18
18
|
- !ruby/object:Gem::Version
|
19
19
|
version: '1.5'
|
20
20
|
type: :development
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
|
-
- -
|
24
|
+
- - ~>
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '1.5'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: rake
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- -
|
31
|
+
- - '>='
|
32
32
|
- !ruby/object:Gem::Version
|
33
33
|
version: '0'
|
34
34
|
type: :development
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
|
-
- -
|
38
|
+
- - '>='
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '0'
|
41
|
-
description:
|
42
|
-
\ "
|
41
|
+
description: ' Help ActiveRecord::Enum feature to work fine with I18n and simple_form. '
|
43
42
|
email:
|
44
43
|
- zm.backer@gmail.com
|
45
44
|
executables: []
|
46
45
|
extensions: []
|
47
46
|
extra_rdoc_files: []
|
48
47
|
files:
|
49
|
-
-
|
48
|
+
- .gitignore
|
50
49
|
- Gemfile
|
51
50
|
- LICENSE.txt
|
52
51
|
- README.md
|
@@ -67,17 +66,17 @@ require_paths:
|
|
67
66
|
- lib
|
68
67
|
required_ruby_version: !ruby/object:Gem::Requirement
|
69
68
|
requirements:
|
70
|
-
- -
|
69
|
+
- - '>='
|
71
70
|
- !ruby/object:Gem::Version
|
72
71
|
version: '0'
|
73
72
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
74
73
|
requirements:
|
75
|
-
- -
|
74
|
+
- - '>='
|
76
75
|
- !ruby/object:Gem::Version
|
77
76
|
version: '0'
|
78
77
|
requirements: []
|
79
78
|
rubyforge_project:
|
80
|
-
rubygems_version: 2.
|
79
|
+
rubygems_version: 2.0.3
|
81
80
|
signing_key:
|
82
81
|
specification_version: 4
|
83
82
|
summary: Extends of ActiveRecord::Enum, which can used in simple_form and internationalization
|