plutonium 0.15.16 → 0.15.18
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: 101dea0b2a6fa8d1cc3fcf5d16f5ab1d932efd7ab90fa9d23561c78bfa3af777
|
4
|
+
data.tar.gz: dc712fdd97f6783eec587fb8ad5066326be59c93f603027e11410e7f9d66ed7a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a0e86bf5065b802c8808ac2704a134cf8cdbc6730602fc29864d34e163599e71c981c8f3a0730d3de9270ba37b9698c5ff58acfba8558318a760c3bfde1804fa
|
7
|
+
data.tar.gz: ad31b7f1e0ca7dd07c249bfceed34ff136bd7dda5b8815786a443882da9fd8dd8429355e175afce71a488de7639324c866a794196a24bf57c6085c6dc112c139
|
@@ -15,10 +15,13 @@ module Pu
|
|
15
15
|
|
16
16
|
def start
|
17
17
|
source_feature = select_feature msg: "Select source feature"
|
18
|
-
source_module = (source_feature == "main_app") ? "
|
18
|
+
source_module = (source_feature == "main_app") ? "ApplicationRecord" : "#{source_feature.camelize}::ResourceRecord"
|
19
19
|
|
20
20
|
Plutonium.eager_load_rails!
|
21
|
-
available_resources = source_module.constantize.descendants.
|
21
|
+
available_resources = source_module.constantize.descendants.reject do |model|
|
22
|
+
next true if model.abstract_class?
|
23
|
+
next true if source_module == "ApplicationRecord" && model.ancestors.any? { |ancestor| ancestor.to_s.end_with?("::ResourceRecord") }
|
24
|
+
end.map(&:to_s).sort
|
22
25
|
error "No resources found" if available_resources.blank?
|
23
26
|
selected_resources = prompt.multi_select("Select resources", available_resources)
|
24
27
|
|
@@ -6,8 +6,8 @@ module Plutonium
|
|
6
6
|
include Phlex::Rails::Helpers::CSPMetaTag
|
7
7
|
include Phlex::Rails::Helpers::CSRFMetaTags
|
8
8
|
include Phlex::Rails::Helpers::FaviconLinkTag
|
9
|
-
include Phlex::Rails::Helpers::
|
10
|
-
include Phlex::Rails::Helpers::
|
9
|
+
include Phlex::Rails::Helpers::StylesheetLinkTag
|
10
|
+
include Phlex::Rails::Helpers::JavascriptIncludeTag
|
11
11
|
|
12
12
|
def view_template(&)
|
13
13
|
doctype
|
data/lib/plutonium/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: plutonium
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.15.
|
4
|
+
version: 0.15.18
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Stefan Froelich
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-11-
|
11
|
+
date: 2024-11-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: zeitwerk
|