ibrain-core 0.5.4 → 0.5.6

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: 050bc4db6fe4fbc3f1e26d4a6a829f7273c5eaf9909e2e4049a95edc89a86d32
4
- data.tar.gz: a36659e2f15c4475f6afb8eb9be75b8b61eaabdefab837e618b9e18ca7b3c22b
3
+ metadata.gz: '082ccfa655b3f8a6574a155335e68dc25fc9f122d251a86fe899490d4e71cbfd'
4
+ data.tar.gz: 2d356e73203f168cdcea21030960389eb6865e2554ccd6b04fce5d8d283beb7e
5
5
  SHA512:
6
- metadata.gz: 46c130b0ab4a6227ec4943f068c11245e9133e99cd43c90eedd1dbd6bd86774e1e696962859c59697279673b439213469c44f704a50a5012b7d302ab18de708e
7
- data.tar.gz: deb0d8912bc4ca2eaab7b6194b8ba01dd6149d1e3484ff178979e47acc3968394ca9eb9c9610d0026f10a973bd3d157c36b93d3e284bdae7e70c9b8deb5cd41c
6
+ metadata.gz: 91a864f18e78ff1d4ff9fc5c86cb805291280a40b7239ebc84d3ac7f91fc5dedb6ae8f5a719ea17f1f8c4e9174ba02968771b8539361b27f6b68e376e4199c95
7
+ data.tar.gz: 82ae6d5b5e41e27d7b54cde0c46f1ec754a873ee9a7a5f9f2545f45f568062960e63cd2d75e9f4996347ad70ba81ac80e7995515caaf9c95273835a5f76642b8
@@ -9,7 +9,11 @@ module Ibrain
9
9
  connection_type_class(Ibrain::Types::BaseConnection)
10
10
 
11
11
  field_class ::Ibrain::Types::BaseField
12
- field :gem, String, null: true
12
+ field :graphql_name, String, null: true
13
+
14
+ def graphql_name
15
+ object.class.try(:table_name)
16
+ end
13
17
 
14
18
  protected
15
19
 
@@ -20,10 +24,6 @@ module Ibrain
20
24
  def current_user
21
25
  context.try(:fetch, :current_user)
22
26
  end
23
-
24
- def gem
25
- 'ibrain-core'
26
- end
27
27
  end
28
28
  end
29
29
  end
@@ -0,0 +1,8 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Ibrain
4
+ class MailerService
5
+ def initialize
6
+ end
7
+ end
8
+ end
@@ -1,15 +1,12 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  <% module_namespacing_when_supported do -%>
4
- module Types
5
- module Objects
6
- class <%= type_ruby_name.split('::')[-1] %> < Ibrain::Types::BaseType
7
- implements Ibrain::Interfaces::RecordInterface
4
+ class Types::Objects::<%= type_ruby_name.split('::')[-1] %> < Ibrain::Types::BaseObject
5
+ implements Ibrain::Interfaces::RecordInterface
8
6
 
9
- description '<%= type_ruby_name.split('::')[-1] %>'
10
-
11
- <% normalized_fields.each do |f| %> <%= f.to_ruby %>
12
- <% end %>end
13
- end
14
- end
7
+ description '<%= type_ruby_name.split('::')[-1] %>'
8
+ graphql_name <%= type_model_name %>.table_name
9
+
10
+ <% normalized_fields.each do |f| %> <%= f.to_ruby %>
11
+ <% end %>end
15
12
  <% end -%>
@@ -66,6 +66,10 @@ module Ibrain
66
66
  @type_ruby_name ||= self.class.normalize_type_expression(type_name, mode: :ruby)[0]
67
67
  end
68
68
 
69
+ def type_model_name
70
+ @type_model_name ||= type_name.camelize
71
+ end
72
+
69
73
  # @return [String] The user-provided type name, as a GraphQL name
70
74
  def type_graphql_name
71
75
  @type_graphql_name ||= self.class.normalize_type_expression(type_name, mode: :graphql)[0]
@@ -1,14 +1,14 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Ibrain
4
- VERSION = "0.5.4"
4
+ VERSION = "0.5.6"
5
5
 
6
6
  def self.ibrain_version
7
7
  VERSION
8
8
  end
9
9
 
10
10
  def self.previous_ibrain_minor_version
11
- '0.5.3'
11
+ '0.5.5'
12
12
  end
13
13
 
14
14
  def self.ibrain_gem_version
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
4
+ version: 0.5.6
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-22 00:00:00.000000000 Z
11
+ date: 2022-10-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activerecord-session_store
@@ -214,6 +214,7 @@ files:
214
214
  - app/models/ibrain/role.rb
215
215
  - app/models/ibrain/role_user.rb
216
216
  - app/repositories/ibrain/base_repository.rb
217
+ - app/services/ibrain/mailer_service.rb
217
218
  - config/locales/en.yml
218
219
  - config/locales/jp.yml
219
220
  - config/locales/vi.yml