diff --git a/src/Entity/Shipment.php b/src/Entity/Shipment.php index 8985482..3404ace 100644 --- a/src/Entity/Shipment.php +++ b/src/Entity/Shipment.php @@ -123,6 +123,11 @@ class Shipment */ private $taxInformationIndicator; + /** + * @var string + */ + private $locale; + public function __construct() { $this->setShipper(new Shipper()); @@ -610,4 +615,24 @@ public function setTaxInformationIndicator(bool $taxInformationIndicator): self return $this; } + + /** + * @return string + */ + public function getLocale() + { + return $this->locale; + } + + /** + * @param string $locale + * + * @return Shipment + */ + public function setLocale($locale) + { + $this->locale = $locale; + + return $this; + } } diff --git a/src/Shipping.php b/src/Shipping.php index e1ac9cf..0165e06 100644 --- a/src/Shipping.php +++ b/src/Shipping.php @@ -429,6 +429,10 @@ private function createConfirmRequest( if ($receiptSpec) { $container->appendChild($xml->importNode($this->compileReceiptSpecificationNode($receiptSpec), true)); } + + if ($shipment->getLocale()) { + $shipmentNode->appendChild($xml->createElement('Locale', $shipment->getLocale())); + } return $xml->saveXML(); }