splendeo-generators 0.3.0 → 0.3.1
Sign up to get free protection for your applications and to get access to all the features.
- data/rails_generators/splendeo_layout/templates/config/locales/en.yml +1 -1
- data/rails_generators/splendeo_scaffold/splendeo_scaffold_generator.rb +1 -1
- data/rails_generators/splendeo_scaffold/templates/views/erb/edit.html.erb +2 -2
- data/rails_generators/splendeo_scaffold/templates/views/erb/index.html.erb +4 -4
- data/rails_generators/splendeo_scaffold/templates/views/erb/new.html.erb +1 -1
- data/rails_generators/splendeo_scaffold/templates/views/erb/show.html.erb +3 -3
- data/rails_generators/splendeo_scaffold/templates/views/haml/edit.html.haml +2 -2
- data/rails_generators/splendeo_scaffold/templates/views/haml/index.html.haml +5 -6
- data/rails_generators/splendeo_scaffold/templates/views/haml/new.html.haml +1 -1
- data/rails_generators/splendeo_scaffold/templates/views/haml/show.html.haml +3 -3
- metadata +2 -2
@@ -11,7 +11,7 @@ en:
|
|
11
11
|
|
12
12
|
flash_notice_successfully_created: "Successfully created {{model}}"
|
13
13
|
flash_notice_successfully_destroyed: "Successfully destroyed {{model}}"
|
14
|
-
flash_notice_successfully_updated: "Successfully
|
14
|
+
flash_notice_successfully_updated: "Successfully updated {{model}}"
|
15
15
|
|
16
16
|
# Formtastic buttons
|
17
17
|
formtastic:
|
@@ -144,7 +144,7 @@ class SplendeoScaffoldGenerator < Rails::Generator::Base
|
|
144
144
|
return tab_string + text.rstrip.gsub("\n", "\n#{tab_string}") + "\n"
|
145
145
|
end
|
146
146
|
|
147
|
-
def
|
147
|
+
def render_link(action, options={})
|
148
148
|
if action? action
|
149
149
|
@action = action
|
150
150
|
|
@@ -11,11 +11,11 @@
|
|
11
11
|
<%- for attribute in attributes -%>
|
12
12
|
<td><%%=h <%= singular_name %>.<%= attribute.name %> %></td>
|
13
13
|
<%- end -%>
|
14
|
-
<%=
|
15
|
-
<%=
|
16
|
-
<%=
|
14
|
+
<%= render_link :show, :ident => 3, :tag => :td, :instance_variable => false -%>
|
15
|
+
<%= render_link :edit, :ident => 3, :tag => :td, :instance_variable => false -%>
|
16
|
+
<%= render_link :destroy, :ident => 3, :tag => :td, :instance_variable => false -%>
|
17
17
|
</tr>
|
18
18
|
<%% end %>
|
19
19
|
</table>
|
20
20
|
|
21
|
-
<%=
|
21
|
+
<%= render_link :new, :tag => :p -%>
|
@@ -8,7 +8,7 @@
|
|
8
8
|
<%- end -%>
|
9
9
|
|
10
10
|
<p>
|
11
|
-
<%=
|
12
|
-
<%=
|
13
|
-
<%=
|
11
|
+
<%= render_link :edit, :ident => 1 -%>
|
12
|
+
<%= render_link :destroy, :ident => 1 -%>
|
13
|
+
<%= render_link :index, :ident => 1 -%>
|
14
14
|
</p>
|
@@ -10,10 +10,9 @@
|
|
10
10
|
<%- for attribute in attributes -%>
|
11
11
|
%td= h <%= singular_name %>.<%= attribute.name %>
|
12
12
|
<%- end -%>
|
13
|
-
<%=
|
14
|
-
<%=
|
15
|
-
<%=
|
13
|
+
<%= render_link :show, :ident => 3, :tag => :td, :instance_variable => false -%>
|
14
|
+
<%= render_link :edit, :ident => 3, :tag => :td, :instance_variable => false -%>
|
15
|
+
<%= render_link :destroy, :ident => 3, :tag => :td, :instance_variable => false -%>
|
16
|
+
|
17
|
+
<%= render_link :new, :tag => :p -%>
|
16
18
|
|
17
|
-
<%- if actions? :new -%>
|
18
|
-
<%= link :new, :tag => :p -%>
|
19
|
-
<%- end -%>
|