bullet_train-super_scaffolding 1.31.0 → 1.32.0

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 0aff9afd7bf07a622050638cabf50afc6e483e6cfeb78eee3c2a5a28f80e54ea
4
- data.tar.gz: 6acb7ff802866bfeab7d301841790a218b70452e118f8f6f931afb0d3407dcc7
3
+ metadata.gz: b13f48c43eda622fe8a455cfad1531113a4625b9819afab72aadd29e532c77f3
4
+ data.tar.gz: 020d3cc93dcbf3cfd44d20ce7968be12d45fe5b7f2aba6b5b74747735f725ce2
5
5
  SHA512:
6
- metadata.gz: e40793565b57e1c435e521eeb14063be80dbd4a8701ac3c2cf5ce05180b3869f34e6c544b1f2ec2520b5596e737f9e0e7636487fc25fd260be6c939ce3fa80df
7
- data.tar.gz: 80a540352b20fa1fd360ee20921058cf79af510ea93aeb518efeac43a7432ae3ff1ace6db20b8858f2ccd26705aa90704e6ce56b108a05fa312814bc9660201b
6
+ metadata.gz: 33e4b92f56495613846851ef3b87bf7029bdaff572bafe101b0bb222d77a582ddf73aef48133b71bfa4b66ff1f54c005aaecab403c0c10f41073504b1e4a34dc
7
+ data.tar.gz: 3f14badcc23122e374b772e277b42ec3d065ca4ab51582ab4e706ccf1bb53cc72f13c795c207b1c976447de4b4d3352f77458d262bf6c7e9d17e356f811212f2
@@ -1,5 +1,5 @@
1
1
  module BulletTrain
2
2
  module SuperScaffolding
3
- VERSION = "1.31.0"
3
+ VERSION = "1.32.0"
4
4
  end
5
5
  end
@@ -216,13 +216,13 @@ class Scaffolding::Attribute
216
216
  def default_value
217
217
  case type
218
218
  when "text_field", "password_field", "text_area"
219
- "'Alternative String Value'"
219
+ "\"Alternative String Value\""
220
220
  when "email_field"
221
- "'another.email@test.com'"
221
+ "\"another.email@test.com\""
222
222
  when "phone_field"
223
- "'+19053871234'"
223
+ "\"+19053871234\""
224
224
  when "color_picker"
225
- "'#47E37F'"
225
+ "\"#47E37F\""
226
226
  end
227
227
  end
228
228
 
@@ -1028,17 +1028,17 @@ class Scaffolding::Transformer
1028
1028
 
1029
1029
  assertion = case attribute.type
1030
1030
  when "date_field"
1031
- "assert_equal_or_nil Date.parse(tangible_thing_data['#{attribute.name}']), tangible_thing.#{attribute.name}"
1031
+ "assert_equal_or_nil Date.parse(tangible_thing_data[\"#{attribute.name}\"]), tangible_thing.#{attribute.name}"
1032
1032
  when "date_and_time_field"
1033
- "assert_equal_or_nil DateTime.parse(tangible_thing_data['#{attribute.name}']), tangible_thing.#{attribute.name}"
1033
+ "assert_equal_or_nil DateTime.parse(tangible_thing_data[\"#{attribute.name}\"]), tangible_thing.#{attribute.name}"
1034
1034
  when "file_field"
1035
1035
  if attribute.is_multiple?
1036
- "assert_equal tangible_thing_data['#{attribute.name}'], @tangible_thing.#{attribute.name}.map{|file| rails_blob_path(file)} unless controller.action_name == 'create'"
1036
+ "assert_equal tangible_thing_data[\"#{attribute.name}\"], @tangible_thing.#{attribute.name}.map{|file| rails_blob_path(file)} unless controller.action_name == \"create\""
1037
1037
  else
1038
- "assert_equal tangible_thing_data['#{attribute.name}'], rails_blob_path(@tangible_thing.#{attribute.name}) unless controller.action_name == 'create'"
1038
+ "assert_equal tangible_thing_data[\"#{attribute.name}\"], rails_blob_path(@tangible_thing.#{attribute.name}) unless controller.action_name == \"create\""
1039
1039
  end
1040
1040
  else
1041
- "assert_equal_or_nil tangible_thing_data['#{attribute.name}'], tangible_thing.#{attribute.name}"
1041
+ "assert_equal_or_nil tangible_thing_data[\"#{attribute.name}\"], tangible_thing.#{attribute.name}"
1042
1042
  end
1043
1043
  scaffold_add_line_to_file("./test/controllers/api/v1/scaffolding/completely_concrete/tangible_things_controller_test.rb", assertion, RUBY_NEW_FIELDS_HOOK, prepend: true)
1044
1044
  end
@@ -1366,7 +1366,7 @@ class Scaffolding::Transformer
1366
1366
  # if needed, update the reference to the parent class name in the create_table migration
1367
1367
  current_transformer = Scaffolding::ClassNamesTransformer.new(child, parent, namespace)
1368
1368
  unless current_transformer.parent_variable_name_in_context.pluralize == current_transformer.parent_table_name
1369
- replace_in_file(migration_file_name, "foreign_key: true", "foreign_key: {to_table: '#{current_transformer.parent_table_name}'}")
1369
+ replace_in_file(migration_file_name, "foreign_key: true", "foreign_key: {to_table: \"#{current_transformer.parent_table_name}\"}")
1370
1370
  end
1371
1371
 
1372
1372
  # update the factory generated by `rails g`.
@@ -1406,7 +1406,7 @@ class Scaffolding::Transformer
1406
1406
  unless cli_options["skip-parent"] || parent == "None"
1407
1407
  scaffold_add_line_to_file(
1408
1408
  "./app/views/account/scaffolding/absolutely_abstract/creative_concepts/show.html.erb",
1409
- "<%= render 'account/scaffolding/completely_concrete/tangible_things/index', tangible_things: @creative_concept.completely_concrete_tangible_things, hide_back: true %>",
1409
+ "<%= render \"account/scaffolding/completely_concrete/tangible_things/index\", tangible_things: @creative_concept.completely_concrete_tangible_things, hide_back: true %>",
1410
1410
  "<%# 🚅 super scaffolding will insert new children above this line. %>",
1411
1411
  prepend: true
1412
1412
  )
@@ -1476,7 +1476,7 @@ class Scaffolding::Transformer
1476
1476
 
1477
1477
  unless cli_options["skip-model"]
1478
1478
  scaffold_add_line_to_file("./app/models/scaffolding/completely_concrete/tangible_thing.rb", "def collection\n absolutely_abstract_creative_concept.completely_concrete_tangible_things\nend\n\n", METHODS_HOOK, prepend: true)
1479
- scaffold_add_line_to_file("./app/models/scaffolding/completely_concrete/tangible_thing.rb", "include Sortable\n", CONCERNS_HOOK, prepend: true)
1479
+ scaffold_add_line_to_file("./app/models/scaffolding/completely_concrete/tangible_thing.rb", "include Sortable\n\n", CONCERNS_HOOK, prepend: true)
1480
1480
 
1481
1481
  migration = Dir.glob("db/migrate/*").last
1482
1482
  migration_lines = File.open(migration).readlines
@@ -1486,7 +1486,7 @@ class Scaffolding::Transformer
1486
1486
  end
1487
1487
 
1488
1488
  unless cli_options["skip-controller"]
1489
- scaffold_add_line_to_file("./app/controllers/account/scaffolding/completely_concrete/tangible_things_controller.rb", "include SortableActions\n", "Account::ApplicationController", increase_indent: true)
1489
+ scaffold_add_line_to_file("./app/controllers/account/scaffolding/completely_concrete/tangible_things_controller.rb", "include SortableActions\n\n", "Account::ApplicationController", increase_indent: true)
1490
1490
  end
1491
1491
  end
1492
1492
 
@@ -1637,7 +1637,7 @@ class Scaffolding::Transformer
1637
1637
  end
1638
1638
  if icon_name.present?
1639
1639
  replace_in_file(transform_string("./config/locales/en/scaffolding/completely_concrete/tangible_things.en.yml"), "fal fa-puzzle-piece", icon_name)
1640
- scaffold_add_line_to_file("./app/views/account/shared/_menu.html.erb", "<%= render 'account/scaffolding/completely_concrete/tangible_things/menu_item' %>", "<% # added by super scaffolding. %>")
1640
+ scaffold_add_line_to_file("./app/views/account/shared/_menu.html.erb", "<%= render \"account/scaffolding/completely_concrete/tangible_things/menu_item\" %>", "<% # added by super scaffolding. %>")
1641
1641
  end
1642
1642
  end
1643
1643
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bullet_train-super_scaffolding
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.31.0
4
+ version: 1.32.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andrew Culver