Skip to content

Commit

Permalink
Add shipment gateway id
Browse files Browse the repository at this point in the history
  • Loading branch information
patrick477 committed Jul 4, 2018
1 parent 35b571d commit 81d0ba9
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 0 deletions.
21 changes: 21 additions & 0 deletions src/Entity/ShippingExport.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,11 @@ class ShippingExport implements ShippingExportInterface
*/
protected $shipment;

/**
* @var string
*/
protected $shipmentGatewayId;

/**
* @var ShippingGatewayInterface
*/
Expand Down Expand Up @@ -70,6 +75,22 @@ public function setShipment(?ShipmentInterface $shipment): void
$this->shipment = $shipment;
}

/**
* {@inheritdoc}
*/
public function getShipmentGatewayId(): ?string
{
return $this->shipmentGatewayId;
}

/**
* {@inheritdoc}
*/
public function setShipmentGatewayId(?string $shipmentGatewayId): void
{
$this->shipmentGatewayId = $shipmentGatewayId;
}

/**
* {@inheritdoc}
*/
Expand Down
10 changes: 10 additions & 0 deletions src/Entity/ShippingExportInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,16 @@ public function getShipment(): ?ShipmentInterface;
*/
public function setShipment(?ShipmentInterface $shipment): void;

/**
* @return string|null
*/
public function getShipmentGatewayId(): ?string;

/**
* @param string|null $shipmentGatewayId
*/
public function setShipmentGatewayId(?string $shipmentGatewayId): void;

/**
* @return ShippingGatewayInterface
*/
Expand Down
4 changes: 4 additions & 0 deletions src/Resources/config/doctrine/ShippingExport.orm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,10 @@ BitBag\SyliusShippingExportPlugin\Entity\ShippingExport:
state:
type: string
column: state
shipmentGatewayId:
type: string
coolumn: shipment_gateway_id
nullable: true
oneToOne:
shipment:
targetEntity: Sylius\Component\Core\Model\Shipment
Expand Down

0 comments on commit 81d0ba9

Please sign in to comment.