Class: ForestAdminDatasourceToolkit::Schema::Relations::ManyToOneSchema
- Inherits:
-
ForestAdminDatasourceToolkit::Schema::RelationSchema
- Object
- ForestAdminDatasourceToolkit::Schema::RelationSchema
- ForestAdminDatasourceToolkit::Schema::Relations::ManyToOneSchema
- Defined in:
- lib/forest_admin_datasource_toolkit/schema/relations/many_to_one_schema.rb
Instance Attribute Summary collapse
-
#foreign_key ⇒ Object
Returns the value of attribute foreign_key.
-
#foreign_key_target ⇒ Object
Returns the value of attribute foreign_key_target.
Attributes inherited from ForestAdminDatasourceToolkit::Schema::RelationSchema
Instance Method Summary collapse
-
#initialize(foreign_key:, foreign_key_target:, foreign_collection:) ⇒ ManyToOneSchema
constructor
A new instance of ManyToOneSchema.
Constructor Details
#initialize(foreign_key:, foreign_key_target:, foreign_collection:) ⇒ ManyToOneSchema
7 8 9 10 11 |
# File 'lib/forest_admin_datasource_toolkit/schema/relations/many_to_one_schema.rb', line 7 def initialize(foreign_key:, foreign_key_target:, foreign_collection:) super(foreign_collection, 'ManyToOne') @foreign_key = foreign_key @foreign_key_target = foreign_key_target end |
Instance Attribute Details
#foreign_key ⇒ Object
Returns the value of attribute foreign_key.
5 6 7 |
# File 'lib/forest_admin_datasource_toolkit/schema/relations/many_to_one_schema.rb', line 5 def foreign_key @foreign_key end |
#foreign_key_target ⇒ Object
Returns the value of attribute foreign_key_target.
5 6 7 |
# File 'lib/forest_admin_datasource_toolkit/schema/relations/many_to_one_schema.rb', line 5 def foreign_key_target @foreign_key_target end |