advanced_haml_scaffold_generator 1.0.5 → 2.0.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 68597275fbe8ab50e518ce1dcffa8e0e064e61d7
4
- data.tar.gz: 7bcc2e58236aaed3a5c82dec74253b02d8440637
3
+ metadata.gz: e21a50c29830fea75bc79a186687a6bc211ba5a9
4
+ data.tar.gz: 251b4a76c48808536d3e64756299a3e3dae6efd5
5
5
  SHA512:
6
- metadata.gz: cab15c4810c826072e88a7522fe6ce5c9b7d9236d7ca3746396fec213172ea2bb158d995f16791fbba39461b2b8f2faa63bbd7c5837884990859060f7b77f92c
7
- data.tar.gz: 4b9dc4371d153bb3ddeee069be2e9c8c1c2001502d4e1e2aac23f4f513850f91e1f0685dd9e54bda8b9f0b9014092b02ee7b08f6231e72f4dcb8648ca47f2000
6
+ metadata.gz: 0de8e5e5efed855c7aa430cdd2c61485d6b81335db2be6637a09b9476a8ac139421dc35302d1dce49f743a5b831979b5cb94abbf0d208083f99367b016c88773
7
+ data.tar.gz: 888c74a2736089e5bc9c4034094fae974983baeac750e9a7fd172bda7bece6ccad6b17410631a118865b4f417bb436f75ce7f947a2d88429e12168ba3f209fa7
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.0.5
1
+ 2.0.0
@@ -2,11 +2,11 @@
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 ruby lib
5
+ # stub: advanced_haml_scaffold_generator 2.0.0 ruby lib
6
6
 
7
7
  Gem::Specification.new do |s|
8
8
  s.name = "advanced_haml_scaffold_generator"
9
- s.version = "1.0.5"
9
+ s.version = "2.0.0"
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"]
@@ -1,5 +1,5 @@
1
1
  <% if Gem::Specification.map(&:name).include?('simple_form') -%>
2
- = simple_form_for(@<%= singular_table_name %>) do |f|
2
+ = simple_form_for(<%= singular_table_name %>) do |f|
3
3
  = f.error_notification
4
4
 
5
5
  .form-inputs
@@ -13,13 +13,13 @@
13
13
  .form-actions
14
14
  = f.button :submit
15
15
  <% else -%>
16
- = form_for(@<%= singular_table_name %>) do |f|
17
- - if @<%= singular_table_name %>.errors.any?
16
+ = form_for(<%= singular_table_name %>) do |f|
17
+ - if <%= singular_table_name %>.errors.any?
18
18
  #error_explanation
19
19
  %h2
20
- = t 'errors.template.header', model: t('.<%= singular_name %>'), count: @<%= singular_name %>.errors.count
20
+ = t 'errors.template.header', model: t('.<%= singular_name %>'), count: <%= singular_name %>.errors.count
21
21
  %ul
22
- - @<%= singular_table_name %>.errors.full_messages.each do |msg|
22
+ - <%= singular_table_name %>.errors.full_messages.each do |msg|
23
23
  %li= msg
24
24
 
25
25
  <% for attribute in attributes -%>
@@ -10,4 +10,5 @@
10
10
  = link_to t('back'), <%= plural_name %>_path, class: 'index'
11
11
  = link_to t('show'), @<%= singular_name %>, class: 'show'
12
12
  <% end -%>
13
- = render 'form'
13
+
14
+ = render 'form', <%= singular_table_name %>: @<%= singular_table_name %>
@@ -7,4 +7,4 @@
7
7
  %p= link_to t('back'), <%= index_helper %>_path, class: 'index'
8
8
  <% end -%>
9
9
 
10
- = render 'form'
10
+ = render 'form', <%= singular_table_name %>: @<%= singular_table_name %>
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: advanced_haml_scaffold_generator
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.5
4
+ version: 2.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dmitri Koulikoff