Skip to content

Commit

Permalink
feat: add the possibility to export region
Browse files Browse the repository at this point in the history
  • Loading branch information
RichardPerdaan committed Nov 8, 2021
1 parent a12b9a6 commit a29925c
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 0 deletions.
26 changes: 26 additions & 0 deletions src/Model/Consignment/AbstractConsignment.php
Original file line number Diff line number Diff line change
Expand Up @@ -230,6 +230,12 @@ abstract class AbstractConsignment
*/
public $city;

/**
* @internal
* @var string
*/
public $region;

/**
* @internal
* @var string
Expand Down Expand Up @@ -780,6 +786,26 @@ public function getCity()
return $this->city;
}

/**
* @return string|null
*/
public function getRegion(): ?string
{
return $this->region;
}

/**
* @param string $region
*
* @return self
*/
public function setRegion(string $region): self
{
$this->region = $region;

return $this;
}

/**
* The address city
* Required: Yes.
Expand Down
1 change: 1 addition & 0 deletions src/Services/ConsignmentEncode.php
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,7 @@ private function encodeBase(): self
'person' => $consignment->getPerson(),
'postal_code' => $consignment->getPostalCode(),
'city' => (string) $consignment->getCity(),
'region' => (string) $consignment->getRegion(),
'email' => (string) $consignment->getEmail(),
'phone' => (string) $consignment->getPhone(),
],
Expand Down

0 comments on commit a29925c

Please sign in to comment.