foobara-active-record-type 0.0.10 → 0.0.11
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +5 -0
- data/lib/foobara/active_record_type.rb +2 -0
- data/src/active_record_foobara_methods.rb +13 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0f7d5092a44023063818776cd29a0cacb950adc6a4299959b8de173e8a2bd8af
|
4
|
+
data.tar.gz: e44239f4fecaf4a20abe8d642c53100f32d9a420441fbd30642278f3a5b84c05
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ff9efed87c28bfbe8a559827066d98260994e55bb8566795c84190b60f09420fd5444d070b8dd4c4bdb14b2e8ae7aa1ade09a0f3b1696dc1694ac8085a42ef49
|
7
|
+
data.tar.gz: 6a91b088e7fe7f6f91a32914ed74fdcbf671431fa722de22cfb8cbd70ae69aec04b70be8194a952be270963fc0f72e23bcb3aa8a1bb6feb5f5c46c298c048e6c
|
data/CHANGELOG.md
CHANGED
@@ -22,6 +22,8 @@ module Foobara
|
|
22
22
|
|
23
23
|
ActiveRecord::Base.include ModelAttributeHelpers::Concerns::AttributeHelpers
|
24
24
|
ActiveRecord::Base.include ActiveRecordFoobaraMethods
|
25
|
+
ActiveRecord::Base.include Foobara::DetachedEntity::Concerns::Reflection
|
26
|
+
ActiveRecord::Base.include Foobara::Model::Concerns::Reflection
|
25
27
|
|
26
28
|
if defined?(Foobara::CommandConnectors::RailsCommandConnector)
|
27
29
|
Foobara::CommandConnectors::RailsCommandConnector.default_serializers = [
|
@@ -11,8 +11,20 @@ module Foobara
|
|
11
11
|
{}
|
12
12
|
end
|
13
13
|
|
14
|
+
# TODO: implement this or figure out how to re-use the methods from Entity/Model
|
15
|
+
def foobara_deep_associations
|
16
|
+
# TODO: test this
|
17
|
+
# :nocov:
|
18
|
+
{}
|
19
|
+
# :nocov:
|
20
|
+
end
|
21
|
+
|
22
|
+
def foobara_model_name
|
23
|
+
foobara_type&.scoped_name || Util.non_full_name(self)
|
24
|
+
end
|
25
|
+
|
14
26
|
def foobara_primary_key_attribute
|
15
|
-
primary_key
|
27
|
+
primary_key&.to_sym
|
16
28
|
end
|
17
29
|
|
18
30
|
def foobara_primary_key_type
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: foobara-active-record-type
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.11
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Miles Georgi
|
8
8
|
bindir: bin
|
9
9
|
cert_chain: []
|
10
|
-
date: 2025-01-
|
10
|
+
date: 2025-01-30 00:00:00.000000000 Z
|
11
11
|
dependencies:
|
12
12
|
- !ruby/object:Gem::Dependency
|
13
13
|
name: activerecord
|
@@ -90,7 +90,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
90
90
|
- !ruby/object:Gem::Version
|
91
91
|
version: '0'
|
92
92
|
requirements: []
|
93
|
-
rubygems_version: 3.6.
|
93
|
+
rubygems_version: 3.6.3
|
94
94
|
specification_version: 4
|
95
95
|
summary: Provides a detached entity foobara type for Active Record classes
|
96
96
|
test_files: []
|