gettext_simple_rails 0.0.10 → 0.0.11
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 240ddccb870a82b05afc74093bb8d4a26fce9c52
|
4
|
+
data.tar.gz: abe436b6a2032b90a2a3f6760399915b284dcdf9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ac2b37299cc63f38b3d6c594f8d3a1387a339aae74e4085638e7c7214170beaa23eb5aaa90acc4e80638169b31ba7d60df2acabb4d1d3333f4fe80dd06432826
|
7
|
+
data.tar.gz: 237122437aaf1d84c68683cfa5f7d255c573a24795f5a6a15e2310b1e36359c57e0b03aa78ae18ca8c20ab981de0459bf246d75e14d9de21fedb5c8d99d49370
|
@@ -4,6 +4,23 @@ class GettextSimpleRails::Translators::SimpleFormTranslator
|
|
4
4
|
end
|
5
5
|
|
6
6
|
def translations
|
7
|
-
|
7
|
+
@translations = {"simple_form" => {
|
8
|
+
"hints" => {}
|
9
|
+
}}
|
10
|
+
|
11
|
+
hints = @translations["simple_form"]["hints"]
|
12
|
+
|
13
|
+
GettextSimpleRails::ModelInspector.model_classes do |inspector|
|
14
|
+
clazz_snake_name = StringCases.camel_to_snake(inspector.clazz.name)
|
15
|
+
|
16
|
+
clazz_hints = {}
|
17
|
+
hints[clazz_snake_name] = clazz_hints
|
18
|
+
|
19
|
+
inspector.attributes do |attribute|
|
20
|
+
clazz_hints[attribute.name.to_s] = ""
|
21
|
+
end
|
22
|
+
end
|
23
|
+
|
24
|
+
return @translations
|
8
25
|
end
|
9
26
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gettext_simple_rails
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.11
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Kasper Johansen
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-05-
|
11
|
+
date: 2014-05-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|