Class: ErpIntegration::CustomerShipmentReturn

Inherits:
Resource
  • Object
show all
Defined in:
lib/erp_integration/customer_shipment_return.rb

Overview

The ‘ErpIntegration::CustomerShipmentReturn` exposes an uniformed API for interaction with third-party ERP vendors.

Instance Attribute Summary collapse

Attributes inherited from Resource

#raw_api_response

Instance Method Summary collapse

Methods inherited from Resource

adapter, adapter_klass, adapter_path, adapter_type, #assign_attributes, #initialize, #method_missing, resource_name, respond_to_missing?

Methods included from Resources::Persistence

#destroy, included, #persisted?, #update

Methods included from Resources::Validations

#errors, #valid?, #validate_with

Constructor Details

This class inherits a constructor from ErpIntegration::Resource

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class ErpIntegration::Resource

Instance Attribute Details

#aes_itnObject

Returns the value of attribute aes_itn.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def aes_itn
  @aes_itn
end

#attachmentsObject

Returns the value of attribute attachments.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def attachments
  @attachments
end

#available_carrier_servicesObject

Returns the value of attribute available_carrier_services.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def available_carrier_services
  @available_carrier_services
end

#carrierObject

Returns the value of attribute carrier.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def carrier
  @carrier
end

#carrier_billing_accountObject

Returns the value of attribute carrier_billing_account.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def 
  @carrier_billing_account
end

#carrier_cost_methodObject

Returns the value of attribute carrier_cost_method.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def carrier_cost_method
  @carrier_cost_method
end

#carrier_duties_accountObject

Returns the value of attribute carrier_duties_account.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def 
  @carrier_duties_account
end

#carrier_serviceObject

Returns the value of attribute carrier_service.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def carrier_service
  @carrier_service
end

#channelsObject

Returns the value of attribute channels.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def channels
  @channels
end

#companyObject

Returns the value of attribute company.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def company
  @company
end

#contents_explanationObject

Returns the value of attribute contents_explanation.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def contents_explanation
  @contents_explanation
end

#contents_typeObject

Returns the value of attribute contents_type.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def contents_type
  @contents_type
end

#costObject

Returns the value of attribute cost.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def cost
  @cost
end

#cost_currencyObject

Returns the value of attribute cost_currency.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def cost_currency
  @cost_currency
end

#cost_currency_digitsObject

Returns the value of attribute cost_currency_digits.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def cost_currency_digits
  @cost_currency_digits
end

#create_dateObject

Returns the value of attribute create_date.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def create_date
  @create_date
end

#create_uidObject

Returns the value of attribute create_uid.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def create_uid
  @create_uid
end

#customerObject

Returns the value of attribute customer.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def customer
  @customer
end

#customer_locationObject

Returns the value of attribute customer_location.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def customer_location
  @customer_location
end

#customs_itemsObject

Returns the value of attribute customs_items.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def customs_items
  @customs_items
end

#delivery_addressObject

Returns the value of attribute delivery_address.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def delivery_address
  @delivery_address
end

#delivery_modeObject

Returns the value of attribute delivery_mode.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def delivery_mode
  @delivery_mode
end

#done_byObject

Returns the value of attribute done_by.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def done_by
  @done_by
end

#duties_tax_idObject

Returns the value of attribute duties_tax_id.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def duties_tax_id
  @duties_tax_id
end

#duties_tax_id_typeObject

Returns the value of attribute duties_tax_id_type.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def duties_tax_id_type
  @duties_tax_id_type
end

#eel_pfcObject

Returns the value of attribute eel_pfc.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def eel_pfc
  @eel_pfc
end

#effective_dateObject

Returns the value of attribute effective_date.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def effective_date
  @effective_date
end

#eori_numberObject

Returns the value of attribute eori_number.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def eori_number
  @eori_number
end

#idObject

Returns the value of attribute id.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def id
  @id
end

#incoming_movesObject

Returns the value of attribute incoming_moves.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def incoming_moves
  @incoming_moves
end

#inventory_movesObject

Returns the value of attribute inventory_moves.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def inventory_moves
  @inventory_moves
end

#is_international_shippingObject

Returns the value of attribute is_international_shipping.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def is_international_shipping
  @is_international_shipping
end

#is_shippoObject

Returns the value of attribute is_shippo.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def is_shippo
  @is_shippo
end

#last_modificationObject

Returns the value of attribute last_modification.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def last_modification
  @last_modification
end

#license_platesObject

Returns the value of attribute license_plates.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def license_plates
  @license_plates
end

#messagesObject

Returns the value of attribute messages.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def messages
  @messages
end

#metadataObject

Returns the value of attribute metadata.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def 
  @metadata
end

#movesObject

Returns the value of attribute moves.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def moves
  @moves
end

#numberObject

Returns the value of attribute number.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def number
  @number
end

#originsObject

Returns the value of attribute origins.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def origins
  @origins
end

#packagesObject

Returns the value of attribute packages.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def packages
  @packages
end

#planned_dateObject

Returns the value of attribute planned_date.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def planned_date
  @planned_date
end

#private_notesObject

Returns the value of attribute private_notes.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def private_notes
  @private_notes
end

#public_notesObject

Returns the value of attribute public_notes.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def public_notes
  @public_notes
end

#putaway_byObject

Returns the value of attribute putaway_by.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def putaway_by
  @putaway_by
end

#rec_blurbObject

Returns the value of attribute rec_blurb.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def rec_blurb
  @rec_blurb
end

#rec_nameObject

Returns the value of attribute rec_name.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def rec_name
  @rec_name
end

#received_byObject

Returns the value of attribute received_by.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def received_by
  @received_by
end

#referenceObject

Returns the value of attribute reference.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def reference
  @reference
end

#require_customsObject

Returns the value of attribute require_customs.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def require_customs
  @require_customs
end

#root_packagesObject

Returns the value of attribute root_packages.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def root_packages
  @root_packages
end

#salesObject

Returns the value of attribute sales.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def sales
  @sales
end

#sent_to_3pl_atObject

Returns the value of attribute sent_to_3pl_at.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def sent_to_3pl_at
  @sent_to_3pl_at
end

#shipping_instructionsObject

Returns the value of attribute shipping_instructions.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def shipping_instructions
  @shipping_instructions
end

#shipping_manifestObject

Returns the value of attribute shipping_manifest.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def shipping_manifest
  @shipping_manifest
end

#sscc_codeObject

Returns the value of attribute sscc_code.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def sscc_code
  @sscc_code
end

#stateObject

Returns the value of attribute state.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def state
  @state
end

#total_customs_valueObject

Returns the value of attribute total_customs_value.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def total_customs_value
  @total_customs_value
end

#tpl_statusObject

Returns the value of attribute tpl_status.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def tpl_status
  @tpl_status
end

#tracking_numberObject

Returns the value of attribute tracking_number.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def tracking_number
  @tracking_number
end

#tsvObject

Returns the value of attribute tsv.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def tsv
  @tsv
end

#warehouseObject

Returns the value of attribute warehouse.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def warehouse
  @warehouse
end

#warehouse_inputObject

Returns the value of attribute warehouse_input.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def warehouse_input
  @warehouse_input
end

#warehouse_storageObject

Returns the value of attribute warehouse_storage.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def warehouse_storage
  @warehouse_storage
end

#warehouse_typeObject

Returns the value of attribute warehouse_type.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def warehouse_type
  @warehouse_type
end

#weightObject

Returns the value of attribute weight.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def weight
  @weight
end

#weight_digitsObject

Returns the value of attribute weight_digits.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def weight_digits
  @weight_digits
end

#weight_uomObject

Returns the value of attribute weight_uom.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def weight_uom
  @weight_uom
end

#weight_uom_symbolObject

Returns the value of attribute weight_uom_symbol.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def weight_uom_symbol
  @weight_uom_symbol
end

#write_dateObject

Returns the value of attribute write_date.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def write_date
  @write_date
end

#write_uidObject

Returns the value of attribute write_uid.



7
8
9
# File 'lib/erp_integration/customer_shipment_return.rb', line 7

def write_uid
  @write_uid
end

Instance Method Details

#create_default_package(id) ⇒ Object

Generate a default package for a ErpIntegration::CustomerShipmentReturn.

Parameters:



32
33
34
# File 'lib/erp_integration/customer_shipment_return.rb', line 32

def create_default_package(id)
  self.class.adapter.create_default_package(id)
end

#create_package(id, options) ⇒ Object

Create a package for a ErpIntegration::CustomerShipmentReturn.

Parameters:



40
41
42
# File 'lib/erp_integration/customer_shipment_return.rb', line 40

def create_package(id, options)
  self.class.adapter.create_package(id, options)
end

#generate_shipping_label(id) ⇒ Object

Generate a shipping label for a ErpIntegration::CustomerShipmentReturn.

Parameters:



25
26
27
# File 'lib/erp_integration/customer_shipment_return.rb', line 25

def generate_shipping_label(id)
  self.class.adapter.generate_shipping_label(id)
end

#mark_as_done!(id) ⇒ Object

TODO: We don’t need to send the id here as is part of the object. Fix this and the rest of the methods doing the same

SBE-965



56
57
58
# File 'lib/erp_integration/customer_shipment_return.rb', line 56

def mark_as_done!(id)
  self.class.adapter.mark_as_done!(id)
end

#receive!(id) ⇒ Object

Mark a CustomerShipmentRetun as received.

Parameters:



47
48
49
# File 'lib/erp_integration/customer_shipment_return.rb', line 47

def receive!(id)
  self.class.adapter.receive!(id)
end