Class: SolidusBacktracs::Configuration

Inherits:
Object
  • Object
show all
Defined in:
lib/solidus_backtracs/configuration.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfiguration

Returns a new instance of Configuration.



38
39
40
41
42
43
44
45
46
47
48
49
# File 'lib/solidus_backtracs/configuration.rb', line 38

def initialize
  @api_batch_size = 100
  @api_sync_threshold = 7.days
  @error_handler = ->(_error, _extra = {}) {
    Rails.logger.error "#{error.inspect} (#{extra.inspect})"
  }
  @api_shipment_matcher = proc do |backtracs_order, shipments|
    shipments.find { |shipment| shipment.number == backtracs_order['orderNumber'] }
  end

  @shipment_notice_class = 'SolidusBacktracs::ShipmentNotice'
end

Instance Attribute Details

#api_baseObject

Returns the value of attribute api_base.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def api_base
  @api_base
end

#api_batch_sizeObject

Returns the value of attribute api_batch_size.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def api_batch_size
  @api_batch_size
end

#api_keyObject

Returns the value of attribute api_key.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def api_key
  @api_key
end

#api_retriesObject

Returns the value of attribute api_retries.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def api_retries
  @api_retries
end

#api_secretObject

Returns the value of attribute api_secret.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def api_secret
  @api_secret
end

#api_shipment_matcherObject

Returns the value of attribute api_shipment_matcher.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def api_shipment_matcher
  @api_shipment_matcher
end

#api_shipment_serializerObject

Returns the value of attribute api_shipment_serializer.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def api_shipment_serializer
  @api_shipment_serializer
end

#api_sync_thresholdObject

Returns the value of attribute api_sync_threshold.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def api_sync_threshold
  @api_sync_threshold
end

#authentication_passwordObject

Returns the value of attribute authentication_password.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def authentication_password
  @authentication_password
end

#authentication_usernameObject

Returns the value of attribute authentication_username.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def authentication_username
  @authentication_username
end

#capture_at_notificationObject

Returns the value of attribute capture_at_notification.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def capture_at_notification
  @capture_at_notification
end

#default_carrierObject

Returns the value of attribute default_carrier.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def default_carrier
  @default_carrier
end

#default_property_nameObject

Returns the value of attribute default_property_name.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def default_property_name
  @default_property_name
end

#default_rma_typeObject

Returns the value of attribute default_rma_type.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def default_rma_type
  @default_rma_type
end

#default_rp_locationObject

Returns the value of attribute default_rp_location.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def default_rp_location
  @default_rp_location
end

#default_ship_methodObject

Returns the value of attribute default_ship_method.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def default_ship_method
  @default_ship_method
end

#default_statusObject

Returns the value of attribute default_status.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def default_status
  @default_status
end

#error_handlerObject

Returns the value of attribute error_handler.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def error_handler
  @error_handler
end

#export_canceled_shipmentsObject

Returns the value of attribute export_canceled_shipments.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def export_canceled_shipments
  @export_canceled_shipments
end

#proxy_addressObject

Returns the value of attribute proxy_address.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def proxy_address
  @proxy_address
end

#proxy_passwordObject

Returns the value of attribute proxy_password.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def proxy_password
  @proxy_password
end

#proxy_portObject

Returns the value of attribute proxy_port.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def proxy_port
  @proxy_port
end

#proxy_usernameObject

Returns the value of attribute proxy_username.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def proxy_username
  @proxy_username
end

#shipment_notice_classObject

Returns the value of attribute shipment_notice_class.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def shipment_notice_class
  @shipment_notice_class
end

#shippable_skusObject

Returns the value of attribute shippable_skus.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def shippable_skus
  @shippable_skus
end

#sku_mapObject

Returns the value of attribute sku_map.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def sku_map
  @sku_map
end

#ssl_encryptedObject

Returns the value of attribute ssl_encrypted.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def ssl_encrypted
  @ssl_encrypted
end

#webhook_passwordObject

Returns the value of attribute webhook_password.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def webhook_password
  @webhook_password
end

#webhook_usernameObject

Returns the value of attribute webhook_username.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def webhook_username
  @webhook_username
end

#weight_unitsObject

Returns the value of attribute weight_units.



5
6
7
# File 'lib/solidus_backtracs/configuration.rb', line 5

def weight_units
  @weight_units
end