rogers_scaffold 0.1.2 → 0.1.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.
- checksums.yaml +8 -8
- data/lib/generators/rogers_scaffold/erb/templates/_form.html.erb +14 -2
- data/lib/generators/rogers_scaffold/erb/templates/edit.html.erb +1 -1
- data/lib/generators/rogers_scaffold/erb/templates/index.html.erb +8 -5
- data/lib/generators/rogers_scaffold/erb/templates/new.html.erb +2 -0
- data/lib/generators/rogers_scaffold/erb/templates/show.html.erb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
---
|
|
2
2
|
!binary "U0hBMQ==":
|
|
3
3
|
metadata.gz: !binary |-
|
|
4
|
-
|
|
4
|
+
MDU2MzBhMGQ5YWFlYzk4OWU0NjI2NDJjZjkxYmE1NDVmM2JiYWY5OQ==
|
|
5
5
|
data.tar.gz: !binary |-
|
|
6
|
-
|
|
6
|
+
NTJlZjExNWVlOGZmYmQyNGIzODQ0YTdkYjBkMWNlN2U5MzRiNWMxZA==
|
|
7
7
|
!binary "U0hBNTEy":
|
|
8
8
|
metadata.gz: !binary |-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
MjQ3YzIwNThhOTA1N2Q1ODlhOTdhZGIwN2NjZjcwZDNhNjBmNzA1YmQ4MTQ3
|
|
10
|
+
YzQzMjRjMzU5YWE3M2JiOTE4YmRmMzVkYzZlOTc2NDAzNGY5OTljNWFjOTM5
|
|
11
|
+
ZWU2MGFjYTNmZTIyMTc4MjYyZDE1NjkwNmY3ODUxMzU1MmU1M2M=
|
|
12
12
|
data.tar.gz: !binary |-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
13
|
+
ZmQ3MzZmYjg2NDJiZjg2Mzk2OGZhMmU3ZDQ1NTg4N2M5Y2M5MzY5YjE1MDc2
|
|
14
|
+
YTQ1YTAwOGQ5ZThhZGVkODQwN2YzYWYxNjdkNTZhMzM5NWZlZmE3ZTI4OTll
|
|
15
|
+
YjBlZDNmYTE0NTgwY2ZmYmI5OTY5NDI1ZTRhNWZiMTk0OTc4OTc=
|
|
@@ -1,5 +1,17 @@
|
|
|
1
|
+
<%% if @<%= singular_table_name %>.errors.any? %>
|
|
2
|
+
<div id="error_explanation">
|
|
3
|
+
<h2><%%= pluralize(@<%= singular_table_name %>.errors.count, "error") %> prohibited this <%= singular_table_name %> from being saved:</h2>
|
|
4
|
+
|
|
5
|
+
<ul>
|
|
6
|
+
<%- @<%= singular_table_name %>.errors.full_messages.each do |msg| -%>
|
|
7
|
+
<li><%= msg %></li>
|
|
8
|
+
<%- end -%>
|
|
9
|
+
</ul>
|
|
10
|
+
</div>
|
|
11
|
+
<%% end %>
|
|
12
|
+
|
|
13
|
+
|
|
1
14
|
<%%= simple_form_for(@<%= singular_table_name %>, html: { class: 'form-horizontal' }) do |f| %>
|
|
2
|
-
<%%= f.error_notification %>
|
|
3
15
|
|
|
4
16
|
<div class="form-inputs">
|
|
5
17
|
<%- attributes.each do |attribute| -%>
|
|
@@ -8,7 +20,7 @@
|
|
|
8
20
|
</div>
|
|
9
21
|
|
|
10
22
|
<div class="form-actions">
|
|
11
|
-
<%%= f.
|
|
23
|
+
<%%= f.button :submit, :value=> "#{f.object.new_record? ? "Create <%= singular_table_name %>" : "Update <%= singular_table_name %>"}", :class=>"btn btn-primary" %>
|
|
12
24
|
</div>
|
|
13
25
|
<%% end %>
|
|
14
26
|
|
|
@@ -1,4 +1,8 @@
|
|
|
1
|
-
<h1
|
|
1
|
+
<h1><%= plural_table_name %></h1>
|
|
2
|
+
|
|
3
|
+
<%%= link_to fa_icon("plus-circle",:text=>'New <%= human_name %>'), new_<%= singular_table_name %>_path, :class=>"btn btn-primary btn-large" %>
|
|
4
|
+
|
|
5
|
+
<br>
|
|
2
6
|
|
|
3
7
|
<table class="table table-striped nowrap datatable">
|
|
4
8
|
<thead>
|
|
@@ -6,7 +10,9 @@
|
|
|
6
10
|
<% attributes.reject(&:password_digest?).each do |attribute| -%>
|
|
7
11
|
<th><%= attribute.human_name %></th>
|
|
8
12
|
<% end -%>
|
|
9
|
-
<th
|
|
13
|
+
<th></th>
|
|
14
|
+
<th></th>
|
|
15
|
+
<th></th>
|
|
10
16
|
</tr>
|
|
11
17
|
</thead>
|
|
12
18
|
|
|
@@ -23,6 +29,3 @@
|
|
|
23
29
|
<%% end %>
|
|
24
30
|
</tbody>
|
|
25
31
|
</table>
|
|
26
|
-
|
|
27
|
-
<br>
|
|
28
|
-
<%%= link_to fa_icon("plus-circle",:text=>'New <%= human_name %>'), new_<%= singular_table_name %>_path, :class=>"btn btn-primary btn-large" %>
|
|
@@ -12,5 +12,5 @@
|
|
|
12
12
|
</dl>
|
|
13
13
|
|
|
14
14
|
|
|
15
|
-
<%%= link_to (
|
|
15
|
+
<%%= link_to fa_icon("edit",:text=>"Edit" ), edit_<%= singular_table_name %>_path(@<%= singular_table_name %>),:class=>"btn btn-warning" %>
|
|
16
16
|
<%%= link_to fa_icon("arrow-left",:text=>'Back'), <%= index_helper %>_path,:class=>"btn btn-info" %>
|