Class: NewStoreApi::OrderInjectionTenantConfiguration
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- NewStoreApi::OrderInjectionTenantConfiguration
- Defined in:
- lib/new_store_api/models/order_injection_tenant_configuration.rb
Overview
Tenant configuration object.
Instance Attribute Summary collapse
-
#big_sales_order ⇒ OrderInjectionConfigurationBigSalesOrder
The order item limits that determine if the order is routed or is considered a big order and placed on hold.
-
#skip_soft_routing_on_injection ⇒ TrueClass | FalseClass
When set to true, do not do the soft routing for injected orders with a service level identifier.
Class Method Summary collapse
-
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
-
.names ⇒ Object
A mapping from model property names to API property names.
-
.nullables ⇒ Object
An array for nullable fields.
-
.optionals ⇒ Object
An array for optional fields.
Instance Method Summary collapse
-
#initialize(big_sales_order = SKIP, skip_soft_routing_on_injection = SKIP) ⇒ OrderInjectionTenantConfiguration
constructor
A new instance of OrderInjectionTenantConfiguration.
-
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
-
#to_s ⇒ Object
Provides a human-readable string representation of the object.
Methods inherited from BaseModel
#check_for_conflict, #process_additional_properties, #process_array, #process_basic_value, #process_hash, #to_hash, #to_json
Constructor Details
#initialize(big_sales_order = SKIP, skip_soft_routing_on_injection = SKIP) ⇒ OrderInjectionTenantConfiguration
Returns a new instance of OrderInjectionTenantConfiguration.
44 45 46 47 48 49 50 51 |
# File 'lib/new_store_api/models/order_injection_tenant_configuration.rb', line 44 def initialize(big_sales_order = SKIP, skip_soft_routing_on_injection = SKIP) @big_sales_order = big_sales_order unless big_sales_order == SKIP unless skip_soft_routing_on_injection == SKIP @skip_soft_routing_on_injection = skip_soft_routing_on_injection end end |
Instance Attribute Details
#big_sales_order ⇒ OrderInjectionConfigurationBigSalesOrder
The order item limits that determine if the order is routed or is considered a big order and placed on hold.
15 16 17 |
# File 'lib/new_store_api/models/order_injection_tenant_configuration.rb', line 15 def big_sales_order @big_sales_order end |
#skip_soft_routing_on_injection ⇒ TrueClass | FalseClass
When set to true, do not do the soft routing for injected orders with a service level identifier.
20 21 22 |
# File 'lib/new_store_api/models/order_injection_tenant_configuration.rb', line 20 def skip_soft_routing_on_injection @skip_soft_routing_on_injection end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
54 55 56 57 58 59 60 61 62 63 64 65 66 67 |
# File 'lib/new_store_api/models/order_injection_tenant_configuration.rb', line 54 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. if hash['big_sales_order'] big_sales_order = OrderInjectionConfigurationBigSalesOrder.from_hash(hash['big_sales_order']) end skip_soft_routing_on_injection = hash.key?('skip_soft_routing_on_injection') ? hash['skip_soft_routing_on_injection'] : SKIP # Create object from extracted values. OrderInjectionTenantConfiguration.new(big_sales_order, skip_soft_routing_on_injection) end |
.names ⇒ Object
A mapping from model property names to API property names.
23 24 25 26 27 28 29 |
# File 'lib/new_store_api/models/order_injection_tenant_configuration.rb', line 23 def self.names @_hash = {} if @_hash.nil? @_hash['big_sales_order'] = 'big_sales_order' @_hash['skip_soft_routing_on_injection'] = 'skip_soft_routing_on_injection' @_hash end |
.nullables ⇒ Object
An array for nullable fields
40 41 42 |
# File 'lib/new_store_api/models/order_injection_tenant_configuration.rb', line 40 def self.nullables [] end |
.optionals ⇒ Object
An array for optional fields
32 33 34 35 36 37 |
# File 'lib/new_store_api/models/order_injection_tenant_configuration.rb', line 32 def self.optionals %w[ big_sales_order skip_soft_routing_on_injection ] end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
77 78 79 80 81 |
# File 'lib/new_store_api/models/order_injection_tenant_configuration.rb', line 77 def inspect class_name = self.class.name.split('::').last "<#{class_name} big_sales_order: #{@big_sales_order.inspect},"\ " skip_soft_routing_on_injection: #{@skip_soft_routing_on_injection.inspect}>" end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
70 71 72 73 74 |
# File 'lib/new_store_api/models/order_injection_tenant_configuration.rb', line 70 def to_s class_name = self.class.name.split('::').last "<#{class_name} big_sales_order: #{@big_sales_order}, skip_soft_routing_on_injection:"\ " #{@skip_soft_routing_on_injection}>" end |