Class: EPlat::Mapping::Bigcommerce::V3::Metafield
- Inherits:
-
EPlat::Mapping::Base
- Object
- EPlat::Mapping::Base
- EPlat::Mapping::Bigcommerce::V3::Metafield
- Defined in:
- lib/e_plat/mapping/bigcommerce/v_3/metafield.rb
Constant Summary
Constants inherited from EPlat::Mapping::Base
EPlat::Mapping::Base::DEFAULT_VALUES
Instance Attribute Summary
Attributes inherited from EPlat::Mapping::Base
#resource, #virtual_collection
Instance Method Summary collapse
Methods inherited from EPlat::Mapping::Base
#aliases, #e_plat_key_to, #initialize, #inspect, #keys_aliased_to_native_keys, #mappable_keys, #mappings, #native_key_to, #native_setter, #to_e_plat_keys, #to_native_keys, #via_native_attributes_where_possible, virtual_collection
Methods included from RequestBodyRoot
#include_root_in_request_body?
Constructor Details
This class inherits a constructor from EPlat::Mapping::Base
Instance Method Details
#native_attribute_aliases ⇒ Object
26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 |
# File 'lib/e_plat/mapping/bigcommerce/v_3/metafield.rb', line 26 def native_attribute_aliases super.concat([ { existing_entry: {native_key: "id", e_plat_key: "id"} }, { existing_entry: {native_key: "key", e_plat_key: "key"} }, { existing_entry: {native_key: "value", e_plat_key: "value"} }, { existing_entry: {native_key: "namespace", e_plat_key: "namespace"} }, { existing_entry: {native_key: "description", e_plat_key: "description"} }, { alias_attribute: {native_key: "date_created", e_plat_key: "created_at"} }, { alias_attribute: {native_key: "date_modified",e_plat_key: "updated_at"} }, { alias_attribute: {native_key: "resource_type",e_plat_key: "owner_resource"} }, { alias_attribute: {native_key: "resource_id", e_plat_key: "owner_id"} } ]) end |
#native_attributes ⇒ Object
11 12 13 14 15 16 17 18 19 20 21 22 23 24 |
# File 'lib/e_plat/mapping/bigcommerce/v_3/metafield.rb', line 11 def native_attributes super.concat([ "id", "key", "value", "namespace", "permission_set", "resource_type", "resource_id", "description", "date_created", "date_modified" ]) end |
#native_top_key ⇒ Object
7 8 9 |
# File 'lib/e_plat/mapping/bigcommerce/v_3/metafield.rb', line 7 def native_top_key "data" end |