advanced_haml_scaffold_generator 1.0.0 → 1.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/VERSION +1 -1
- data/advanced_haml_scaffold_generator.gemspec +4 -4
- data/lib/rails/generators/haml/scaffold/templates/_form.html.haml +16 -3
- data/lib/rails/generators/haml/scaffold/templates/index.html.haml +5 -5
- data/lib/rails/generators/haml/scaffold/templates/show.html.haml +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: cf51f5b2fc19b3588d4d1d4c366ae2f41acdf250
|
4
|
+
data.tar.gz: c88f027dd82a051cfc43983130473a56e4e1c8c5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 289531db9a7097a1bb588c991226992a013f0c8189d55489375e0c0736e87f6339eed96b2c15c919b762f2e0d830994286034aef5d5884b6c9967be4a3b6b6d6
|
7
|
+
data.tar.gz: ad4d9b499e2cd555821f1e74da58b06cbf0b14c33e634256663c5be078c79edb5930d2d738f9b38f663e111ff44ba31fb785e02e88f2d80a403c23f78b7653ed
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.0.
|
1
|
+
1.0.1
|
@@ -2,16 +2,16 @@
|
|
2
2
|
# DO NOT EDIT THIS FILE DIRECTLY
|
3
3
|
# Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
|
4
4
|
# -*- encoding: utf-8 -*-
|
5
|
-
# stub: advanced_haml_scaffold_generator 1.0.
|
5
|
+
# stub: advanced_haml_scaffold_generator 1.0.1 ruby lib
|
6
6
|
|
7
7
|
Gem::Specification.new do |s|
|
8
8
|
s.name = "advanced_haml_scaffold_generator"
|
9
|
-
s.version = "1.0.
|
9
|
+
s.version = "1.0.1"
|
10
10
|
|
11
11
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
12
12
|
s.require_paths = ["lib"]
|
13
13
|
s.authors = ["Dmitri Koulikoff"]
|
14
|
-
s.date = "
|
14
|
+
s.date = "2015-02-20"
|
15
15
|
s.description = "Extention of the haml generator that generates templates with the use of i18n, cancan and WiceGrid, adds classes to buttons and uses :title helper"
|
16
16
|
s.email = "dima@koulikoff.ru"
|
17
17
|
s.extra_rdoc_files = [
|
@@ -40,7 +40,7 @@ Gem::Specification.new do |s|
|
|
40
40
|
]
|
41
41
|
s.homepage = "http://github.com/dima4p/advanced_haml_scaffold_generator"
|
42
42
|
s.licenses = ["MIT"]
|
43
|
-
s.rubygems_version = "2.
|
43
|
+
s.rubygems_version = "2.4.5"
|
44
44
|
s.summary = "Extention of the haml generator that is aware of i18n and so forth"
|
45
45
|
|
46
46
|
if s.respond_to? :specification_version then
|
@@ -4,7 +4,10 @@
|
|
4
4
|
|
5
5
|
.form-inputs
|
6
6
|
<%- attributes.each do |attribute| -%>
|
7
|
-
= f.<%= attribute.reference? ? :association : :input %> :<%= attribute.
|
7
|
+
= f.<%= attribute.reference? ? :association : :input %> :<%= attribute.column_name %>
|
8
|
+
<% if attribute.password_digest? -%>
|
9
|
+
= f.input :password_confirmation
|
10
|
+
<% end -%>
|
8
11
|
<%- end -%>
|
9
12
|
|
10
13
|
.form-actions
|
@@ -21,9 +24,19 @@
|
|
21
24
|
|
22
25
|
<% for attribute in attributes -%>
|
23
26
|
.field
|
24
|
-
|
27
|
+
<% if attribute.password_digest? -%>
|
28
|
+
= f.label :password
|
29
|
+
%br
|
30
|
+
= f.password_field :password
|
31
|
+
.field
|
32
|
+
= f.label :password_confirmation
|
25
33
|
%br
|
26
|
-
= f
|
34
|
+
= f.password_field :password_confirmation
|
35
|
+
<% else -%>
|
36
|
+
= f.label :<%= attribute.column_name %>
|
37
|
+
%br
|
38
|
+
= f.<%= attribute.field_type %> :<%= attribute.column_name %>
|
39
|
+
<% end -%>
|
27
40
|
<% end -%>
|
28
41
|
|
29
42
|
.actions
|
@@ -10,7 +10,7 @@
|
|
10
10
|
<% if defined? Wice::WiceGrid -%>
|
11
11
|
- if @grid
|
12
12
|
= grid @grid do |g|
|
13
|
-
<% for attribute in attributes -%>
|
13
|
+
<% for attribute in attributes.reject(&:password_digest?) -%>
|
14
14
|
<% if attribute.reference? -%>
|
15
15
|
- g.column name: <%= class_name %>.human_attribute_name(:<%= attribute.name %>),
|
16
16
|
:attribute => '<%= attribute.name %>_id' do |<%= singular_table_name %>|
|
@@ -47,7 +47,7 @@
|
|
47
47
|
%table
|
48
48
|
%thead
|
49
49
|
%tr
|
50
|
-
<% for attribute in attributes -%>
|
50
|
+
<% for attribute in attributes.reject(&:password_digest?) -%>
|
51
51
|
%th= <%= class_name %>.human_attribute_name :<%= attribute.name %>
|
52
52
|
<% end -%>
|
53
53
|
%th{:colspan => 3}= t 'actions'
|
@@ -55,7 +55,7 @@
|
|
55
55
|
%tbody
|
56
56
|
- @<%= plural_table_name %>.each do |<%= singular_table_name %>|
|
57
57
|
%tr{ :class => cycle(:odd, :even) }
|
58
|
-
<% for attribute in attributes -%>
|
58
|
+
<% for attribute in attributes.reject(&:password_digest?) -%>
|
59
59
|
<% if attribute.reference? -%>
|
60
60
|
%td= <%= singular_table_name %>.<%= attribute.name %>.try :name
|
61
61
|
<% else -%>
|
@@ -85,7 +85,7 @@
|
|
85
85
|
%table
|
86
86
|
%thead
|
87
87
|
%tr
|
88
|
-
<% for attribute in attributes -%>
|
88
|
+
<% for attribute in attributes.reject(&:password_digest?) -%>
|
89
89
|
%th= <%= class_name %>.human_attribute_name :<%= attribute.name %>
|
90
90
|
<% end -%>
|
91
91
|
%th{:colspan => 3}= t 'actions'
|
@@ -93,7 +93,7 @@
|
|
93
93
|
%tbody
|
94
94
|
- @<%= plural_table_name %>.each do |<%= singular_table_name %>|
|
95
95
|
%tr{ :class => cycle(:odd, :even) }
|
96
|
-
<% for attribute in attributes -%>
|
96
|
+
<% for attribute in attributes.reject(&:password_digest?) -%>
|
97
97
|
<% if attribute.reference? -%>
|
98
98
|
%td= <%= singular_table_name %>.<%= attribute.name %>.try :name
|
99
99
|
<% else -%>
|
@@ -12,7 +12,7 @@
|
|
12
12
|
<% end -%>
|
13
13
|
|
14
14
|
%dl
|
15
|
-
<% for attribute in attributes -%>
|
15
|
+
<% for attribute in attributes.reject(&:password_digest?) -%>
|
16
16
|
%dt= <%= class_name %>.human_attribute_name :<%= attribute.name %>
|
17
17
|
<% if attribute.reference? -%>
|
18
18
|
%dd= @<%= singular_table_name %>.<%= attribute.name %>.try :name
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: advanced_haml_scaffold_generator
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dmitri Koulikoff
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2015-02-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rspec
|
@@ -127,7 +127,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
127
127
|
version: '0'
|
128
128
|
requirements: []
|
129
129
|
rubyforge_project:
|
130
|
-
rubygems_version: 2.
|
130
|
+
rubygems_version: 2.4.5
|
131
131
|
signing_key:
|
132
132
|
specification_version: 4
|
133
133
|
summary: Extention of the haml generator that is aware of i18n and so forth
|