translation_rails 0.0.2 → 0.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/README.md
CHANGED
@@ -3,14 +3,18 @@ translation-rails
|
|
3
3
|
|
4
4
|
include translation_center use it
|
5
5
|
|
6
|
-
|
6
|
+
Setup:
|
7
7
|
|
8
8
|
gem 'translation_center', :git => "https://github.com/jypandjio/translation_center"
|
9
9
|
|
10
10
|
gem 'translation_rails'
|
11
11
|
|
12
|
+
rails g translation_rails:install
|
13
|
+
|
12
14
|
rake db:migrate
|
13
15
|
|
16
|
+
rake translation_rails:add_lang[en]
|
17
|
+
|
14
18
|
To migrate translations from TranslationCenter database to yaml files
|
15
19
|
|
16
20
|
rake translation_center:db2yaml
|
data/app/controllers/{application_controller.rb → translation_rails/application_controller.rb}
RENAMED
@@ -1,5 +1,6 @@
|
|
1
1
|
class ApplicationController
|
2
2
|
layout "translation_rails/application"
|
3
|
+
before_filter :get_original_layout
|
3
4
|
|
4
5
|
def self.layout(layout, conditions={})
|
5
6
|
unless layout.to_s == "translation_rails/application"
|
@@ -17,7 +18,6 @@ class ApplicationController
|
|
17
18
|
@original_layout || "translation_rails/application"
|
18
19
|
end
|
19
20
|
|
20
|
-
before_filter :get_original_layout
|
21
21
|
|
22
22
|
def get_original_layout
|
23
23
|
@layout_name = self.class.original_layout
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: translation_rails
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.3
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -51,7 +51,7 @@ extensions: []
|
|
51
51
|
extra_rdoc_files: []
|
52
52
|
files:
|
53
53
|
- app/assets/stylesheets/application.css
|
54
|
-
- app/controllers/application_controller.rb
|
54
|
+
- app/controllers/translation_rails/application_controller.rb
|
55
55
|
- app/models/manager.rb
|
56
56
|
- app/views/layouts/translation_rails/application.html.erb
|
57
57
|
- config/initializers/app_config.rb
|