bullet_train-super_scaffolding 1.0.36 → 1.0.39
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8c3c71ca0044007dd52267ebd4f349230a570603cf0c36f422c8009a31d4782e
|
4
|
+
data.tar.gz: 68427dec662496dba68dd3892eeef389d68e464c1188cccafd11ed37e62dfe23
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7d4a4a1e0ea47b0e3fdb5cc8aec490176281eb5628ddf73d0188c6a4f482cf98237229b4fea48ea642b2dc161acd4395ff7ae073a2b1093efc84a68b9d8ed37b
|
7
|
+
data.tar.gz: 02bfaa8f516ac9bb9c85d443164939bcbbd16dac8e54521410902dd11a4f177ec600660d1a6c2203346ca8bc5668b057b51de1b97bad587b3ed73db56106e32c
|
@@ -160,6 +160,14 @@ class Scaffolding::ClassNamesTransformer
|
|
160
160
|
parent_in_namespace_class_name.titlecase.pluralize
|
161
161
|
when "Tangible Things"
|
162
162
|
in_namespace_class_name.titlecase.pluralize
|
163
|
+
when "Creative concepts"
|
164
|
+
parent_in_namespace_class_name.titlecase.downcase.capitalize.pluralize
|
165
|
+
when "Tangible things"
|
166
|
+
in_namespace_class_name.titlecase.downcase.capitalize.pluralize
|
167
|
+
when "creative concepts"
|
168
|
+
parent_in_namespace_class_name.titlecase.downcase.pluralize
|
169
|
+
when "tangible things"
|
170
|
+
in_namespace_class_name.titlecase.downcase.pluralize
|
163
171
|
when "creative-concepts"
|
164
172
|
parent_in_namespace_class_name.underscore.gsub(/[\/_]/, "-").pluralize
|
165
173
|
when "tangible-things"
|
@@ -173,6 +181,14 @@ class Scaffolding::ClassNamesTransformer
|
|
173
181
|
parent_in_namespace_class_name.titlecase
|
174
182
|
when "Tangible Thing"
|
175
183
|
in_namespace_class_name.titlecase
|
184
|
+
when "Creative concept"
|
185
|
+
parent_in_namespace_class_name.titlecase.downcase.capitalize
|
186
|
+
when "Tangible thing"
|
187
|
+
in_namespace_class_name.titlecase.downcase.capitalize
|
188
|
+
when "creative concept"
|
189
|
+
parent_in_namespace_class_name.titlecase.downcase
|
190
|
+
when "tangible thing"
|
191
|
+
in_namespace_class_name.titlecase.downcase
|
176
192
|
when "creative-concept"
|
177
193
|
parent_in_namespace_class_name.underscore.gsub(/[\/_]/, "-")
|
178
194
|
when "tangible-thing"
|
@@ -6,6 +6,29 @@ require "scaffolding/class_names_transformer"
|
|
6
6
|
class Scaffolding::Transformer
|
7
7
|
attr_accessor :child, :parent, :parents, :class_names_transformer, :cli_options, :additional_steps, :namespace, :suppress_could_not_find
|
8
8
|
|
9
|
+
def code_for_child_on_parent_show_page
|
10
|
+
end
|
11
|
+
|
12
|
+
def update_models_abstract_class
|
13
|
+
end
|
14
|
+
|
15
|
+
def created_by_reference(created_by_index_name)
|
16
|
+
end
|
17
|
+
|
18
|
+
def approved_by_reference(approved_by_index_name)
|
19
|
+
end
|
20
|
+
|
21
|
+
def permit_parents
|
22
|
+
["Team"]
|
23
|
+
end
|
24
|
+
|
25
|
+
def last_joinable_parent
|
26
|
+
"Team"
|
27
|
+
end
|
28
|
+
|
29
|
+
def update_action_models_abstract_class(targets_n)
|
30
|
+
end
|
31
|
+
|
9
32
|
def initialize(child, parents, cli_options = {})
|
10
33
|
self.child = child
|
11
34
|
self.parent = parents.first
|
@@ -91,6 +114,10 @@ class Scaffolding::Transformer
|
|
91
114
|
"tangible-things",
|
92
115
|
"Creative Concepts",
|
93
116
|
"Tangible Things",
|
117
|
+
"Creative concepts",
|
118
|
+
"Tangible things",
|
119
|
+
"creative concepts",
|
120
|
+
"tangible things",
|
94
121
|
|
95
122
|
# just class name plural.
|
96
123
|
"creative_concept",
|
@@ -99,6 +126,10 @@ class Scaffolding::Transformer
|
|
99
126
|
"tangible-thing",
|
100
127
|
"Creative Concept",
|
101
128
|
"Tangible Thing",
|
129
|
+
"Creative concept",
|
130
|
+
"Tangible thing",
|
131
|
+
"creative concept",
|
132
|
+
"tangible thing",
|
102
133
|
|
103
134
|
# Account namespace vs. others.
|
104
135
|
":account",
|
@@ -1291,6 +1322,8 @@ class Scaffolding::Transformer
|
|
1291
1322
|
scaffold_replace_line_in_file("./app/models/scaffolding/completely_concrete/tangible_thing.rb", transform_string("belongs_to :absolutely_abstract_creative_concept, class_name: \"Scaffolding::AbsolutelyAbstract::CreativeConcept\"\n"), transform_string("belongs_to :absolutely_abstract_creative_concept\n"))
|
1292
1323
|
end
|
1293
1324
|
|
1325
|
+
update_models_abstract_class
|
1326
|
+
|
1294
1327
|
# add user permissions.
|
1295
1328
|
add_ability_line_to_roles_yml
|
1296
1329
|
end
|
@@ -1301,7 +1334,12 @@ class Scaffolding::Transformer
|
|
1301
1334
|
|
1302
1335
|
# add children to the show page of their parent.
|
1303
1336
|
unless cli_options["skip-parent"] || parent == "None"
|
1304
|
-
scaffold_add_line_to_file(
|
1337
|
+
scaffold_add_line_to_file(
|
1338
|
+
"./app/views/account/scaffolding/absolutely_abstract/creative_concepts/show.html.erb",
|
1339
|
+
code_for_child_on_parent_show_page || "<%= render 'account/scaffolding/completely_concrete/tangible_things/index', tangible_things: @creative_concept.completely_concrete_tangible_things, hide_back: true %>",
|
1340
|
+
"<%# 🚅 super scaffolding will insert new children above this line. %>",
|
1341
|
+
prepend: true
|
1342
|
+
)
|
1305
1343
|
end
|
1306
1344
|
|
1307
1345
|
unless cli_options["skip-model"]
|
data/lib/scaffolding.rb
CHANGED
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.0.
|
4
|
+
version: 1.0.39
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Andrew Culver
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-08-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: standard
|
@@ -178,7 +178,7 @@ licenses:
|
|
178
178
|
metadata:
|
179
179
|
homepage_uri: https://github.com/bullet-train-co/bullet_train-super_scaffolding
|
180
180
|
source_code_uri: https://github.com/bullet-train-co/bullet_train-super_scaffolding
|
181
|
-
post_install_message:
|
181
|
+
post_install_message:
|
182
182
|
rdoc_options: []
|
183
183
|
require_paths:
|
184
184
|
- lib
|
@@ -193,8 +193,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
193
193
|
- !ruby/object:Gem::Version
|
194
194
|
version: '0'
|
195
195
|
requirements: []
|
196
|
-
rubygems_version: 3.
|
197
|
-
signing_key:
|
196
|
+
rubygems_version: 3.1.6
|
197
|
+
signing_key:
|
198
198
|
specification_version: 4
|
199
199
|
summary: Bullet Train Super Scaffolding
|
200
200
|
test_files: []
|