infopark_fiona_connector 7.0.1.5.2.3.rc5 → 7.0.1.5.2.4.rc2

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: a758ecfed1d6c530c1ae32e5f893f07283905d44027ee8edbd138c8cc51047a2
4
- data.tar.gz: 8706ba3ec80d4356d2cffb52414c34f264211b2f8adc0328faac2dd665b9bef4
3
+ metadata.gz: 4033836b63cfbad47bd2835a09b26bf7b19e835ff423aeed71821447b04a8a84
4
+ data.tar.gz: 9260afd8b7276ee1181e1a407f22f3c8f904a9342d95864f474d394a7e7c4117
5
5
  SHA512:
6
- metadata.gz: 15962ebaa0a711d6f2ec3a0e23b661d17cb42e04815e116bde12047ac772914999eebcb74b03c3685906fa5a57de9bb63f1f0bc64ed5498e57e1a2a621963b09
7
- data.tar.gz: a323ffab660d396984fd2f9384114c3544807bddf1a0a3117d83ba0d155016b907cb3ce0fe489e158685c04873bec6e3bb6bcecf833e83d463725ab1f114faee
6
+ metadata.gz: 946656deb308c91a2cc09863302262ff1279c1fa106d1d79785470f8d5836c5fca532d0d808967f3629c106292618f4b0c4e13223d4ead671b9d32b3294eb0d1
7
+ data.tar.gz: 5983af97c3fb3bff2484a8801cf6c0329f3e4c4476b4dd3b8cdd87bf8ba21c85240da73aedba572d8e42a75253787e45e79e1084a251652ebbeaf5855774452b
@@ -134,7 +134,7 @@ module RailsConnector
134
134
 
135
135
  def has_attribute(key)
136
136
  key = key.to_sym
137
- return true if predefined_attribute?(key)
137
+ return true if object.class::PREDEFINED_ATTRIBUTES.include?(key.to_s)
138
138
 
139
139
  blob_dict.key?(key) || attr_defs.key?(key) || class_defined_attributes.key?(key)
140
140
  end
@@ -73,6 +73,11 @@ module RailsConnector
73
73
  end
74
74
  end
75
75
 
76
+ def self.reinitialize_attributes
77
+ reset_obj_class_def
78
+ initialize_attributes
79
+ end
80
+
76
81
  def self.delegate_attributes
77
82
  PREDEFINED_ATTRIBUTES.each do |attribute|
78
83
  delegate attribute, to: :attr_dict
@@ -122,7 +127,7 @@ module RailsConnector
122
127
  end
123
128
 
124
129
  def self.reset_reflections
125
- has_many :children, class_name: "Obj", foreign_key: "parent_obj_id"
130
+ has_many :children, class_name: "Obj", foreign_key: "parent_obj_id", validate: false
126
131
  belongs_to :parent, class_name: "Obj", foreign_key: "parent_obj_id"
127
132
  end
128
133
 
@@ -502,18 +507,6 @@ module RailsConnector
502
507
  @mime_type ||= compute_mime_type
503
508
  end
504
509
 
505
- def respond_to?(method_id, include_private = false)
506
- if super
507
- true
508
- elsif %w(_attr_dict _attr_defs _attr_values).include?(method_id.to_s)
509
- # prevent infinite recursion when calling "attr_*" below,
510
- # since rails checks the absence of an "_attr_*" method internally
511
- false
512
- else
513
- attr_dict.respond_to?(method_id)
514
- end
515
- end
516
-
517
510
  private
518
511
 
519
512
  def fiona_fields
@@ -37,6 +37,16 @@ module RailsConnector
37
37
  true
38
38
  end
39
39
 
40
+ def attribute_for_inspect(attr_name)
41
+ value = read_attribute(attr_name)
42
+
43
+ if value.is_a?(RailsConnector::LinkList)
44
+ value.destination_objects.map(&:to_s)
45
+ else
46
+ super
47
+ end
48
+ end
49
+
40
50
  class << self
41
51
  # The prefix of the table name is determined by using the instance name followed by an underscore.
42
52
  # Set the instance_name in your environment to the CMS instance name (defaults to 'default').
@@ -133,6 +133,10 @@ module RailsConnector
133
133
  end
134
134
  alias_method :obj_class_def, :obj_class_definition
135
135
 
136
+ def reset_obj_class_def
137
+ @obj_class_definition = nil
138
+ end
139
+
136
140
  # RailsConnector::AbstractObj returns false, everything else true.
137
141
  # TODO: RailsConnector::AbstractObj does not exist here
138
142
  def is_custom_ruby_class?
@@ -1,7 +1,7 @@
1
1
  module RailsConnector
2
2
  module Version
3
3
  def self.get
4
- "7.0.1.5.2.3.rc5"
4
+ "7.0.1.5.2.4.rc2"
5
5
  end
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: infopark_fiona_connector
3
3
  version: !ruby/object:Gem::Version
4
- version: 7.0.1.5.2.3.rc5
4
+ version: 7.0.1.5.2.4.rc2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Infopark AG
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-07-16 00:00:00.000000000 Z
11
+ date: 2020-08-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails