ibrain-core 0.5.0 → 0.5.2
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: f233bcfda710916773bb711e76dfb17dbed7422903582e485aa4b74bd16b70a0
|
4
|
+
data.tar.gz: 77b84c056f155144027fdf4383cece09f7846413c0c1148630396e05ca76979f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7d7b3295584d532c7056bd8c42f9f0912a1a57415f055d8e779ed0e7379fd3677ab2e481d5336c7378ec380223177fef9f9f695f6d4ec5884f8535eedccfbfc8
|
7
|
+
data.tar.gz: 31df17fd32e208faf2e517e8cc9fdedd4bed1e937a7352ac5e883f9359c81ec9682b1970aab5726a9863107eeb96e20129c9c487eaaba0f1522c973773dc7539
|
@@ -9,8 +9,7 @@ module Ibrain
|
|
9
9
|
connection_type_class(Ibrain::Types::BaseConnection)
|
10
10
|
|
11
11
|
field_class ::Ibrain::Types::BaseField
|
12
|
-
|
13
|
-
field :name, String, null: true
|
12
|
+
field :table_name, String, null: true
|
14
13
|
|
15
14
|
protected
|
16
15
|
|
@@ -21,6 +20,10 @@ module Ibrain
|
|
21
20
|
def current_user
|
22
21
|
context.try(:fetch, :current_user)
|
23
22
|
end
|
23
|
+
|
24
|
+
def table_name
|
25
|
+
object.class.try(:table_name)
|
26
|
+
end
|
24
27
|
end
|
25
28
|
end
|
26
29
|
end
|
@@ -3,10 +3,12 @@
|
|
3
3
|
module Ibrain
|
4
4
|
module Types
|
5
5
|
class BaseType < BaseObject
|
6
|
-
|
7
|
-
|
6
|
+
class << self
|
7
|
+
def graphql_name(name = "")
|
8
|
+
return name if name.present?
|
8
9
|
|
9
|
-
|
10
|
+
self.name.demodulize.gsub('Type', '').classify.constantize.table_name
|
11
|
+
end
|
10
12
|
end
|
11
13
|
end
|
12
14
|
end
|
data/lib/ibrain/core/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ibrain-core
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.5.
|
4
|
+
version: 0.5.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tai Nguyen Van
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-09-
|
11
|
+
date: 2022-09-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activerecord-session_store
|
@@ -294,7 +294,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
294
294
|
- !ruby/object:Gem::Version
|
295
295
|
version: '0'
|
296
296
|
requirements: []
|
297
|
-
rubygems_version: 3.
|
297
|
+
rubygems_version: 3.3.20
|
298
298
|
signing_key:
|
299
299
|
specification_version: 4
|
300
300
|
summary: Its Core is an sso authen gem for Ruby on Rails.
|