bullet_train-super_scaffolding 1.1.6 → 1.1.8

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
  SHA256:
3
- metadata.gz: cb214438689ae7ff2053db702cfac614616cd86a6b78f300756ebb8b7ff27fbb
4
- data.tar.gz: bea986de9846ea209a9988980d36a9d2d7b50ac1106f7ae7481c7d5ff0d35e4a
3
+ metadata.gz: dd6d322f764c7b1dec83c0740d014f0371688fc4529aec36c6907834c1d723fe
4
+ data.tar.gz: 5b589a31f1f811c78f50882d5800bad6883223693934a2f22b16a3574c58de7f
5
5
  SHA512:
6
- metadata.gz: b3cd3a2686acef3d59eadd072cfd6a9e75b9193ad2bc6a9194327c5a66e2af533d4db4f88e78f3ac7a5c9124b6e782c0975d13ced244e6edfce7532ce3948382
7
- data.tar.gz: f5ed69853cb581af46bafb327c6c5959015d938d9c77cebd5b4b7643e7d56d972913b085de635bc86d5fd524829988fdf28cee3148dc3dbf94477451d950321c
6
+ metadata.gz: b3c7eab5d90b3900563ba6b3117de6360e89769d014d87a4a50ee65906918200d53b9dbeffa903707b828007d9c61d34cc2b5f4c816e66ccc39ba87a1439cbf5
7
+ data.tar.gz: 0116eca05c6cfbd7677332ea5353a7db5a13e36fb4fa86555ad02ab5850811e1f6932ce07cbc803c6e489facb731ab7b9ebe38e26fe544af4caca07a15dc8e29
@@ -1,18 +1,20 @@
1
1
  <%= form_with model: [:account, (@team unless creative_concept.persisted?), creative_concept], local: true, class: 'form' do |form| %>
2
- <%= render 'account/shared/forms/errors', form: form %>
2
+ <%= render "shared/limits/form", form: form, cancel_path: [:account, @team, :scaffolding, :absolutely_abstract, :creative_concepts] do %>
3
+ <%= render 'account/shared/forms/errors', form: form %>
3
4
 
4
- <% with_field_settings form: form do %>
5
- <%= render 'shared/fields/text_field', method: :name, options: {autofocus: true} %>
6
- <%= render 'shared/fields/text_area', method: :description %>
7
- <%# 🚅 super scaffolding will insert new fields above this line. %>
8
- <% end %>
9
-
10
- <div class="buttons">
11
- <%= form.submit (form.object.persisted? ? t('.buttons.update') : t('.buttons.create')), class: "button" %>
12
- <% if form.object.persisted? %>
13
- <%= link_to t('global.buttons.cancel'), [:account, creative_concept], class: "button-secondary" %>
14
- <% else %>
15
- <%= link_to t('global.buttons.cancel'), [:account, @team, :scaffolding, :absolutely_abstract, :creative_concepts], class: "button-secondary" %>
5
+ <% with_field_settings form: form do %>
6
+ <%= render 'shared/fields/text_field', method: :name, options: {autofocus: true} %>
7
+ <%= render 'shared/fields/text_area', method: :description %>
8
+ <%# 🚅 super scaffolding will insert new fields above this line. %>
16
9
  <% end %>
17
- </div>
10
+
11
+ <div class="buttons">
12
+ <%= form.submit (form.object.persisted? ? t('.buttons.update') : t('.buttons.create')), class: "button" %>
13
+ <% if form.object.persisted? %>
14
+ <%= link_to t('global.buttons.cancel'), [:account, creative_concept], class: "button-secondary" %>
15
+ <% else %>
16
+ <%= link_to t('global.buttons.cancel'), [:account, @team, :scaffolding, :absolutely_abstract, :creative_concepts], class: "button-secondary" %>
17
+ <% end %>
18
+ </div>
19
+ <% end %>
18
20
  <% end %>
@@ -7,6 +7,7 @@
7
7
  <% p.content_for :title, t(".contexts.#{context.class.name.underscore}.header") %>
8
8
  <% p.content_for :description do %>
9
9
  <%= t(".contexts.#{context.class.name.underscore}.#{creative_concepts.any? ? 'description' : 'description_empty'}") %>
10
+ <%= render "shared/limits/index", model: creative_concepts.model %>
10
11
  <% end %>
11
12
 
12
13
  <% if creative_concepts.any? %>
@@ -1,65 +1,64 @@
1
+ <% cancel_path ||= tangible_thing.persisted? ? [:account, tangible_thing] : [:account, @absolutely_abstract_creative_concept, :completely_concrete_tangible_things] %>
2
+
1
3
  <%= form_with model: tangible_thing, url: (tangible_thing.persisted? ? [:account, tangible_thing] : [:account, @absolutely_abstract_creative_concept, :completely_concrete_tangible_things]), local: true, class: 'form' do |form| %>
2
- <%= render 'account/shared/forms/errors', form: form %>
4
+ <%= render "shared/limits/form", form: form, cancel_path: cancel_path do %>
5
+ <%= render 'account/shared/forms/errors', form: form %>
3
6
 
4
- <% with_field_settings form: form do %>
5
- <%# 🚅 skip this section when scaffolding. %>
6
- <%= render 'shared/fields/text_field', method: :text_field_value, options: {autofocus: true} %>
7
+ <% with_field_settings form: form do %>
8
+ <%# 🚅 skip this section when scaffolding. %>
9
+ <%= render 'shared/fields/text_field', method: :text_field_value, options: {autofocus: true} %>
7
10
 
8
- <%= render 'shared/fields/buttons', method: :boolean_button_value %>
11
+ <%= render 'shared/fields/buttons', method: :boolean_button_value %>
9
12
 
10
- <div class="grid grid-cols-1 gap-y gap-x sm:grid-cols-2">
11
- <div class="sm:col-span-1">
12
- <%= render 'shared/fields/buttons', method: :button_value %>
13
- </div>
13
+ <div class="grid grid-cols-1 gap-y gap-x sm:grid-cols-2">
14
+ <div class="sm:col-span-1">
15
+ <%= render 'shared/fields/buttons', method: :button_value %>
16
+ </div>
14
17
 
15
- <div class="sm:col-span-1">
16
- <%= render 'shared/fields/buttons', method: :multiple_button_values, multiple: true %>
18
+ <div class="sm:col-span-1">
19
+ <%= render 'shared/fields/buttons', method: :multiple_button_values, multiple: true %>
20
+ </div>
17
21
  </div>
18
- </div>
19
22
 
20
- <%= render 'shared/fields/color_picker', method: :color_picker_value, options: {color_picker_options: t('scaffolding/completely_concrete/tangible_things.fields.color_picker_value.options')} %>
21
- <%= render 'shared/fields/cloudinary_image', method: :cloudinary_image_value %>
22
- <%= render 'shared/fields/date_field', method: :date_field_value %>
23
- <%= render 'shared/fields/date_and_time_field', method: :date_and_time_field_value %>
24
- <%= render 'shared/fields/email_field', method: :email_field_value %>
25
- <%= render 'shared/fields/file_field', method: :file_field_value %>
23
+ <%= render 'shared/fields/color_picker', method: :color_picker_value, options: {color_picker_options: t('scaffolding/completely_concrete/tangible_things.fields.color_picker_value.options')} %>
24
+ <%= render 'shared/fields/cloudinary_image', method: :cloudinary_image_value %>
25
+ <%= render 'shared/fields/date_field', method: :date_field_value %>
26
+ <%= render 'shared/fields/date_and_time_field', method: :date_and_time_field_value %>
27
+ <%= render 'shared/fields/email_field', method: :email_field_value %>
28
+ <%= render 'shared/fields/file_field', method: :file_field_value %>
26
29
 
27
- <div class="grid grid-cols-1 gap-y gap-x sm:grid-cols-2">
28
- <div class="sm:col-span-1 pr-0 sm:pr-10">
29
- <%= render 'shared/fields/options', method: :option_value %>
30
- </div>
30
+ <div class="grid grid-cols-1 gap-y gap-x sm:grid-cols-2">
31
+ <div class="sm:col-span-1 pr-0 sm:pr-10">
32
+ <%= render 'shared/fields/options', method: :option_value %>
33
+ </div>
31
34
 
32
- <div class="sm:col-span-1 pr-0 sm:pr-10">
33
- <%= render 'shared/fields/options', method: :multiple_option_values, multiple: true %>
35
+ <div class="sm:col-span-1 pr-0 sm:pr-10">
36
+ <%= render 'shared/fields/options', method: :multiple_option_values, multiple: true %>
37
+ </div>
34
38
  </div>
35
- </div>
36
39
 
37
- <%= render 'shared/fields/password_field', method: :password_field_value %>
38
- <%= render 'shared/fields/phone_field', method: :phone_field_value %>
40
+ <%= render 'shared/fields/password_field', method: :password_field_value %>
41
+ <%= render 'shared/fields/phone_field', method: :phone_field_value %>
39
42
 
40
- <div class="grid grid-cols-1 gap-y gap-x sm:grid-cols-2">
41
- <div class="sm:col-span-1">
42
- <%= render 'shared/fields/super_select', method: :super_select_value, other_options: {search: true} %>
43
- </div>
43
+ <div class="grid grid-cols-1 gap-y gap-x sm:grid-cols-2">
44
+ <div class="sm:col-span-1">
45
+ <%= render 'shared/fields/super_select', method: :super_select_value, other_options: {search: true} %>
46
+ </div>
44
47
 
45
- <div class="sm:col-span-1">
46
- <%= render 'shared/fields/super_select', method: :multiple_super_select_values, other_options: {search: true}, html_options: {multiple: true} %>
48
+ <div class="sm:col-span-1">
49
+ <%= render 'shared/fields/super_select', method: :multiple_super_select_values, other_options: {search: true}, html_options: {multiple: true} %>
50
+ </div>
47
51
  </div>
48
- </div>
49
-
50
- <%= render 'shared/fields/text_area', method: :text_area_value %>
51
- <%= render 'shared/fields/trix_editor', method: :action_text_value %>
52
- <%# 🚅 stop any skipping we're doing now. %>
53
- <%# 🚅 super scaffolding will insert new fields above this line. %>
54
- <% end %>
55
52
 
56
- <div class="buttons">
57
- <%= form.submit (form.object.persisted? ? t('.buttons.update') : t('.buttons.create')), class: "button" %>
58
- <% if form.object.persisted? %>
59
- <%= link_to t('global.buttons.cancel'), [:account, tangible_thing], class: "button-secondary" %>
60
- <% else %>
61
- <%= link_to t('global.buttons.cancel'), [:account, @absolutely_abstract_creative_concept, :completely_concrete_tangible_things], class: "button-secondary" %>
53
+ <%= render 'shared/fields/text_area', method: :text_area_value %>
54
+ <%= render 'shared/fields/trix_editor', method: :action_text_value %>
55
+ <%# 🚅 stop any skipping we're doing now. %>
56
+ <%# 🚅 super scaffolding will insert new fields above this line. %>
62
57
  <% end %>
63
- </div>
64
58
 
59
+ <div class="buttons">
60
+ <%= form.submit (form.object.persisted? ? t('.buttons.update') : t('.buttons.create')), class: "button" %>
61
+ <%= link_to t('global.buttons.cancel'), cancel_path, class: "button-secondary" %>
62
+ </div>
63
+ <% end %>
65
64
  <% end %>
@@ -13,6 +13,7 @@
13
13
  <% p.content_for :title, t(".contexts.#{context.class.name.underscore}.header") %>
14
14
  <% p.content_for :description do %>
15
15
  <%= t(".contexts.#{context.class.name.underscore}.description#{"_empty" unless tangible_things.any?}") %>
16
+ <%= render "shared/limits/index", model: tangible_things.model %>
16
17
  <% end %>
17
18
 
18
19
  <% p.content_for :table do %>
@@ -1,5 +1,5 @@
1
1
  module BulletTrain
2
2
  module SuperScaffolding
3
- VERSION = "1.1.6"
3
+ VERSION = "1.1.8"
4
4
  end
5
5
  end
@@ -1086,6 +1086,7 @@ class Scaffolding::Transformer
1086
1086
  #
1087
1087
 
1088
1088
  unless cli_options["skip-api"]
1089
+ # It's OK that this won't be found most of the time.
1089
1090
  scaffold_add_line_to_file(
1090
1091
  "./app/views/api/v1/open_api/scaffolding/completely_concrete/tangible_things/_components.yaml.erb",
1091
1092
  "<%= attribute :#{name} %>",
@@ -1093,6 +1094,7 @@ class Scaffolding::Transformer
1093
1094
  prepend: true
1094
1095
  )
1095
1096
 
1097
+ # It's OK that this won't be found most of the time.
1096
1098
  scaffold_add_line_to_file(
1097
1099
  "./app/views/api/v1/open_api/scaffolding/completely_concrete/tangible_things/_components.yaml.erb",
1098
1100
  "<%= parameter :#{name} %>",
@@ -1284,7 +1286,6 @@ class Scaffolding::Transformer
1284
1286
  "./app/controllers/account/scaffolding/completely_concrete/tangible_things_controller.rb",
1285
1287
  "./app/views/account/scaffolding/completely_concrete/tangible_things",
1286
1288
  "./app/views/api/v1/scaffolding/completely_concrete/tangible_things",
1287
- "./app/views/api/v1/open_api/scaffolding/completely_concrete/tangible_things",
1288
1289
  ("./config/locales/en/scaffolding/completely_concrete/tangible_things.en.yml" unless cli_options["skip-locales"]),
1289
1290
  ("./app/controllers/api/v1/scaffolding/completely_concrete/tangible_things_controller.rb" unless cli_options["skip-api"]),
1290
1291
  ("./test/controllers/api/v1/scaffolding/completely_concrete/tangible_things_controller_test.rb" unless cli_options["skip-api"])
@@ -1354,7 +1355,7 @@ class Scaffolding::Transformer
1354
1355
  # add children to the show page of their parent.
1355
1356
  scaffold_add_line_to_file(
1356
1357
  "./app/views/api/#{BulletTrain::Api.current_version}/open_api/index.yaml.erb",
1357
- "<%= components_for Scaffolding::CompletelyConcrete::TangibleThing %>",
1358
+ "<%= automatic_components_for Scaffolding::CompletelyConcrete::TangibleThing %>",
1358
1359
  "<%# 🚅 super scaffolding will insert new components above this line. %>",
1359
1360
  prepend: true
1360
1361
  )
@@ -1362,7 +1363,7 @@ class Scaffolding::Transformer
1362
1363
  # add children to the show page of their parent.
1363
1364
  scaffold_add_line_to_file(
1364
1365
  "./app/views/api/#{BulletTrain::Api.current_version}/open_api/index.yaml.erb",
1365
- "<%= paths_for Scaffolding::CompletelyConcrete::TangibleThing %>",
1366
+ "<%= automatic_paths_for Scaffolding::CompletelyConcrete::TangibleThing %>",
1366
1367
  "<%# 🚅 super scaffolding will insert new paths above this line. %>",
1367
1368
  prepend: true
1368
1369
  )
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bullet_train-super_scaffolding
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.6
4
+ version: 1.1.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andrew Culver
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-09-08 00:00:00.000000000 Z
11
+ date: 2022-10-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: standard