bullet_train-super_scaffolding 1.29.0 → 1.30.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 +4 -4
- data/lib/bullet_train/super_scaffolding/version.rb +1 -1
- data/lib/scaffolding/transformer.rb +19 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f8cee89effdc4329321ba0709c21cc2ac2af45c15643cf86a15118c73d80e538
|
4
|
+
data.tar.gz: 45c046644f762aeb3f64d3e90f9364e653bb47660a5d1486b58e523a5c95d297
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ecb369388be2ff1126b6b1193aa4eba0432e1bb0e11616b0c4cb523a3048e3706e9e58cb04fb45ab822f702b18056529d1555cb34b633a0bc0c296eeda946a7b
|
7
|
+
data.tar.gz: d1ef2e4c91feb4b769f0d30c744a518579e31d28eca6cde7662a33d4fe0260a4f31b3c3efac5d5a7cbd282780036ac54720b3b9f96563d99f07f6941ba3ce56f
|
@@ -1454,7 +1454,25 @@ class Scaffolding::Transformer
|
|
1454
1454
|
|
1455
1455
|
# add sortability.
|
1456
1456
|
if cli_options["sortable"]
|
1457
|
-
scaffold_replace_line_in_file(
|
1457
|
+
scaffold_replace_line_in_file(
|
1458
|
+
"./app/views/account/scaffolding/completely_concrete/tangible_things/_index.html.erb",
|
1459
|
+
transform_string("<tbody data-controller=\"sortable\" data-sortable-reorder-path-value=\"<%= url_for [:reorder, :account, context, collection] %>\">"),
|
1460
|
+
"<tbody>"
|
1461
|
+
)
|
1462
|
+
|
1463
|
+
# TODO: Is looking for particular markup valid here, or should we add new hooks to the files?
|
1464
|
+
scaffold_add_line_to_file(
|
1465
|
+
"./app/views/account/scaffolding/completely_concrete/tangible_things/_index.html.erb",
|
1466
|
+
"<th class=\"w-6\"></th>",
|
1467
|
+
"<%= render \"shared/tables/select_all\" %>",
|
1468
|
+
prepend: true
|
1469
|
+
)
|
1470
|
+
scaffold_add_line_to_file(
|
1471
|
+
"./app/views/account/scaffolding/completely_concrete/tangible_things/_tangible_thing.html.erb",
|
1472
|
+
"<td data-sortable-target=\"handle\" class=\"cursor-grab active:cursor-grabbing\"><i class=\"ti ti-menu opacity-25 group-hover:opacity-100\"></i></td>",
|
1473
|
+
"<%= render \"shared/tables/checkbox\", object: tangible_thing %>",
|
1474
|
+
prepend: true
|
1475
|
+
)
|
1458
1476
|
|
1459
1477
|
unless cli_options["skip-model"]
|
1460
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)
|