Class: DHLEcommerceAPI::Shipment::ShipmentItem
- Defined in:
- lib/dhl_ecommerce_api/resources/shipment/shipment_item.rb
Overview
Component item
Instance Method Summary collapse
-
#initialize(attributes = {}, persisted = false) ⇒ ShipmentItem
constructor
A new instance of ShipmentItem.
Methods inherited from Base
#account_ids, #attributes_with_account_ids, #custom_key_format, #handle_errors
Constructor Details
#initialize(attributes = {}, persisted = false) ⇒ ShipmentItem
Returns a new instance of ShipmentItem.
6 7 8 9 10 11 12 13 |
# File 'lib/dhl_ecommerce_api/resources/shipment/shipment_item.rb', line 6 def initialize(attributes = {}, persisted = false) status = attributes["response_status"] if status.present? && status["code"] != "200" = status["message_details"].map{|err| err["message_detail"]} handle_errors(status["code"], ) end super end |