Class: Dhl::Bcs::V2::Location
- Inherits:
-
Object
- Object
- Dhl::Bcs::V2::Location
- Includes:
- Buildable
- Defined in:
- lib/dhl/bcs/v2/location.rb
Overview
a location is one of Address, Packstation, Postfiliale or ParcelShop they have some properties in common
Direct Known Subclasses
Constant Summary collapse
- PROPERTIES =
%i(zip city country country_code state).freeze
Instance Method Summary collapse
Methods included from Buildable
Instance Method Details
#to_soap_hash ⇒ Object
11 12 13 14 15 16 17 18 19 20 21 |
# File 'lib/dhl/bcs/v2/location.rb', line 11 def to_soap_hash { 'cis:zip' => zip, 'cis:city' => city, 'cis:Origin' => {}.tap { |h| h['cis:country'] = country if country h['cis:countryISOCode'] = country_code if country_code h['cis:state'] = state if state } } end |