rich_table_component 0.0.16 → 0.0.17
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/rich_table_component/version.rb +1 -1
- data/lib/rich_table_component.rb +5 -5
- metadata +2 -2
data/lib/rich_table_component.rb
CHANGED
@@ -512,13 +512,13 @@ module RichTableComponent
|
|
512
512
|
respond_to do |format|
|
513
513
|
case act
|
514
514
|
when :create
|
515
|
-
flash[:notice] ||= "#{obj.class.name.tableize}
|
515
|
+
flash[:notice] ||= "#{t(obj.class.name.tableize.singularize)} #{t('was_successfully_created')}."
|
516
516
|
format.html { redirect_to controller: obj.class.name.tableize, action: :edit, id: obj.id }
|
517
517
|
when :update
|
518
|
-
flash[:notice] ||= "#{obj.class.name.tableize}
|
518
|
+
flash[:notice] ||= "#{t(obj.class.name.tableize.singularize)} #{t('was_successfully_updated')}."
|
519
519
|
format.html { redirect_to controller: obj.class.name.tableize, action: :edit, id: obj.id }
|
520
520
|
when :destroy
|
521
|
-
flash[:notice] ||= "#{obj.class.name.tableize}
|
521
|
+
flash[:notice] ||= "#{t(obj.class.name.tableize.singularize)} #{t('was_successfully_deleted')}."
|
522
522
|
format.html { redirect_to controller: obj.class.name.tableize, action: :index }
|
523
523
|
else
|
524
524
|
format.html # index.html.erb
|
@@ -556,10 +556,10 @@ module RichTableComponent
|
|
556
556
|
def format_remote(format, act = action_name, obj = instance_variable_get("@#{controller_name}"), html_redirect = nil)
|
557
557
|
case act
|
558
558
|
when :create
|
559
|
-
flash[:notice] ||= "#{obj.class.name.tableize}
|
559
|
+
flash[:notice] ||= "#{t(obj.class.name.tableize.singularize)} #{t('was_successfully_created')}."
|
560
560
|
format.html { redirect_to controller: obj.class.name.tableize, action: html_redirect.presence || :edit, id: obj.id }
|
561
561
|
when :update
|
562
|
-
flash[:notice] ||= "#{obj.class.name.tableize}
|
562
|
+
flash[:notice] ||= "#{t(obj.class.name.tableize.singularize)} #{t('was_successfully_updated')}."
|
563
563
|
format.html { redirect_to controller: obj.class.name.tableize, action: html_redirect.presence || :edit, id: obj.id }
|
564
564
|
else
|
565
565
|
format.html { render action: act }
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rich_table_component
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.17
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-03-
|
12
|
+
date: 2013-03-08 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: sass-rails
|